Examples of OrderMonetaryAmountImpl


Examples of de.zalando.sprocwrapper.example.OrderMonetaryAmountImpl

    }

    @Test
    public void testMonetaryValue() {
        BigDecimal b = new BigDecimal("123.124");
        int i = exampleSProcService.createOrder("order2", new OrderMonetaryAmountImpl(b, "EUR"));

        Order o = exampleSProcService.getOrders(i);

        assertEquals(o.amount.getAmount().compareTo(b), 0);
    }
View Full Code Here

Examples of de.zalando.sprocwrapper.example.OrderMonetaryAmountImpl

        AddressPojo addr = new AddressPojo();
        addr.setCustomerId(1);
        addr.setStreet("Main Street");
        addr.setNumber("23");

        Order o = new Order("order3", new OrderMonetaryAmountImpl(b, "EUR"), addr);
        o.positions = Arrays.asList(new OrderPosition(new OrderMonetaryAmountImpl(c, "EUR"),
                    new OrderMonetaryAmountImpl(d, "EUR"), addr));

        int i = exampleSProcService.createOrder(o);

        o = exampleSProcService.getOrders(i);
View Full Code Here

Examples of de.zalando.sprocwrapper.example.OrderMonetaryAmountImpl

    @Test
    public void testEmptyOptionalValues() {
        BigDecimal b = new BigDecimal("12.34");
        BigDecimal c = new BigDecimal("45.67");

        Order o = new Order("order4", new OrderMonetaryAmountImpl(b, "EUR"));
        o.positions = Arrays.asList(new OrderPosition(new OrderMonetaryAmountImpl(c, "EUR")));

        int i = exampleSProcService.createOrder(o);

        o = exampleSProcService.getOrders(i);
View Full Code Here

Examples of de.zalando.sprocwrapper.example.OrderMonetaryAmountImpl

    public OrderMonetaryAmount unmarshalFromDbNode(final DbResultNode dbResultNode) {
        List<DbResultNode> dbResultNodeList = dbResultNode.getChildren();
        BigDecimal amount = new BigDecimal(dbResultNodeList.get(0).getValue());
        String currency = dbResultNodeList.get(1).getValue();

        return new OrderMonetaryAmountImpl(amount, currency);
    }
View Full Code Here

Examples of de.zalando.sprocwrapper.example.OrderMonetaryAmountImpl

    private static final Logger LOG = LoggerFactory.getLogger(OrderMonetaryAmountTransformer.class);

    @Override
    public OrderMonetaryAmount unmarshalFromDb(final String value) {
        LOG.info(value);
        return new OrderMonetaryAmountImpl();
    }
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.