Examples of PriceSummaryDocument


Examples of org.apache.xmlbeans.samples.enumeration.schemaenum.pricesummary.PriceSummaryDocument

        // and use it to print what the sample received.
        PurchaseOrderDocument poDoc = thisSample.parseXml(args[0]);
        System.out.println("Received XML: \n\n" + poDoc.toString());

        // Print the summarized items in XML based on a different schema.
        PriceSummaryDocument summaryDoc = thisSample.summarizeItems(poDoc);
        System.out.println("Summarized items: \n\n" + summaryDoc.toString());

        // Print a simple non-XML list of items by threshold.
        String sortedItems = thisSample.sortByThreshold(summaryDoc);
        System.out.println("Sorted items: \n" + sortedItems);
View Full Code Here

Examples of org.apache.xmlbeans.samples.enumeration.schemaenum.pricesummary.PriceSummaryDocument

    {
        PurchaseOrderDocument.PurchaseOrder po = poDoc.getPurchaseOrder();

        // Create a new instance of the PriceSummary schema. This is the document
        // the code creates, extracting values from the purchase order.
        PriceSummaryDocument summaryDoc = PriceSummaryDocument.Factory.newInstance();
        PriceSummaryDocument.PriceSummary summary = summaryDoc.addNewPriceSummary();

        // Create <price> elements to hold <item> elements according to their
        // price threshold.
        PriceType priceZero = summary.addNewPrice();
        PriceType priceTen = summary.addNewPrice();
View Full Code Here

Examples of org.apache.xmlbeans.samples.enumeration.schemaenum.pricesummary.PriceSummaryDocument

        boolean exampleIsValid = sample.validateXml(poDoc);
        assert exampleIsValid;

        // Create a new document that summarizes the PO doc.
        PriceSummaryDocument summaryDoc = sample.summarizeItems(poDoc);

        boolean summaryIsValid = sample.validateXml(summaryDoc);
        assert summaryIsValid;

        // Create a summary of the items based on price.
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.