Example usage for com.liferay.portal.kernel.util IntegerWrapper getValue

List of usage examples for com.liferay.portal.kernel.util IntegerWrapper getValue

Introduction

In this page you can find the example usage for com.liferay.portal.kernel.util IntegerWrapper getValue.

Prototype

public int getValue() 

Source Link

Usage

From source file:blade.servicebuilder.service.persistence.test.FooPersistenceTest.java

License:Open Source License

@Test
public void testActionableDynamicQuery() throws Exception {
    final IntegerWrapper count = new IntegerWrapper();

    ActionableDynamicQuery actionableDynamicQuery = FooLocalServiceUtil.getActionableDynamicQuery();

    actionableDynamicQuery.setPerformActionMethod(new ActionableDynamicQuery.PerformActionMethod<Foo>() {
        @Override//from  w  w w . j a v a 2  s.c o m
        public void performAction(Foo foo) {
            Assert.assertNotNull(foo);

            count.increment();
        }
    });

    actionableDynamicQuery.performActions();

    Assert.assertEquals(count.getValue(), _persistence.countAll());
}

From source file:ch.inofix.referencemanager.service.persistence.test.ReferencePersistenceTest.java

License:Open Source License

@Test
public void testActionableDynamicQuery() throws Exception {
    final IntegerWrapper count = new IntegerWrapper();

    ActionableDynamicQuery actionableDynamicQuery = ReferenceLocalServiceUtil.getActionableDynamicQuery();

    actionableDynamicQuery.setPerformActionMethod(new ActionableDynamicQuery.PerformActionMethod<Reference>() {
        @Override/*from w w w  .j a v  a2s  .  co  m*/
        public void performAction(Reference reference) {
            Assert.assertNotNull(reference);

            count.increment();
        }
    });

    actionableDynamicQuery.performActions();

    Assert.assertEquals(count.getValue(), _persistence.countAll());
}

From source file:com.bemis.portal.customer.service.persistence.test.CustomerLocationPersistenceTest.java

License:Open Source License

@Test
public void testActionableDynamicQuery() throws Exception {
    final IntegerWrapper count = new IntegerWrapper();

    ActionableDynamicQuery actionableDynamicQuery = CustomerLocationLocalServiceUtil
            .getActionableDynamicQuery();

    actionableDynamicQuery/*from  w  w w  .  jav  a2s.c o  m*/
            .setPerformActionMethod(new ActionableDynamicQuery.PerformActionMethod<CustomerLocation>() {
                @Override
                public void performAction(CustomerLocation customerLocation) {
                    Assert.assertNotNull(customerLocation);

                    count.increment();
                }
            });

    actionableDynamicQuery.performActions();

    Assert.assertEquals(count.getValue(), _persistence.countAll());
}

From source file:com.bemis.portal.inventory.service.persistence.test.InventoryPersistenceTest.java

License:Open Source License

@Test
public void testActionableDynamicQuery() throws Exception {
    final IntegerWrapper count = new IntegerWrapper();

    ActionableDynamicQuery actionableDynamicQuery = InventoryLocalServiceUtil.getActionableDynamicQuery();

    actionableDynamicQuery.setPerformActionMethod(new ActionableDynamicQuery.PerformActionMethod<Inventory>() {
        @Override/*  w ww  . ja  v  a2s.  com*/
        public void performAction(Inventory inventory) {
            Assert.assertNotNull(inventory);

            count.increment();
        }
    });

    actionableDynamicQuery.performActions();

    Assert.assertEquals(count.getValue(), _persistence.countAll());
}

From source file:com.bemis.portal.order.service.persistence.test.OrderPersistenceTest.java

License:Open Source License

@Test
public void testActionableDynamicQuery() throws Exception {
    final IntegerWrapper count = new IntegerWrapper();

    ActionableDynamicQuery actionableDynamicQuery = OrderLocalServiceUtil.getActionableDynamicQuery();

    actionableDynamicQuery.setPerformActionMethod(new ActionableDynamicQuery.PerformActionMethod<Order>() {
        @Override/*from  w  ww .  j a va2s .c om*/
        public void performAction(Order order) {
            Assert.assertNotNull(order);

            count.increment();
        }
    });

    actionableDynamicQuery.performActions();

    Assert.assertEquals(count.getValue(), _persistence.countAll());
}

From source file:com.bemis.portal.order.service.persistence.test.OrderRequestPersistenceTest.java

License:Open Source License

@Test
public void testActionableDynamicQuery() throws Exception {
    final IntegerWrapper count = new IntegerWrapper();

    ActionableDynamicQuery actionableDynamicQuery = OrderRequestLocalServiceUtil.getActionableDynamicQuery();

    actionableDynamicQuery/*w w w .  j ava  2  s  . c o  m*/
            .setPerformActionMethod(new ActionableDynamicQuery.PerformActionMethod<OrderRequest>() {
                @Override
                public void performAction(OrderRequest orderRequest) {
                    Assert.assertNotNull(orderRequest);

                    count.increment();
                }
            });

    actionableDynamicQuery.performActions();

    Assert.assertEquals(count.getValue(), _persistence.countAll());
}

From source file:com.bemis.portal.shipment.service.persistence.test.ShipmentPersistenceTest.java

License:Open Source License

@Test
public void testActionableDynamicQuery() throws Exception {
    final IntegerWrapper count = new IntegerWrapper();

    ActionableDynamicQuery actionableDynamicQuery = ShipmentLocalServiceUtil.getActionableDynamicQuery();

    actionableDynamicQuery.setPerformActionMethod(new ActionableDynamicQuery.PerformActionMethod<Shipment>() {
        @Override//from   ww w .j  a v  a 2 s  .  c o  m
        public void performAction(Shipment shipment) {
            Assert.assertNotNull(shipment);

            count.increment();
        }
    });

    actionableDynamicQuery.performActions();

    Assert.assertEquals(count.getValue(), _persistence.countAll());
}

From source file:com.liferay.adaptive.media.image.service.persistence.test.AdaptiveMediaImageEntryPersistenceTest.java

License:Open Source License

@Test
public void testActionableDynamicQuery() throws Exception {
    final IntegerWrapper count = new IntegerWrapper();

    ActionableDynamicQuery actionableDynamicQuery = AdaptiveMediaImageEntryLocalServiceUtil
            .getActionableDynamicQuery();

    actionableDynamicQuery/*  w  w w  .ja va  2s. c o  m*/
            .setPerformActionMethod(new ActionableDynamicQuery.PerformActionMethod<AdaptiveMediaImageEntry>() {
                @Override
                public void performAction(AdaptiveMediaImageEntry adaptiveMediaImageEntry) {
                    Assert.assertNotNull(adaptiveMediaImageEntry);

                    count.increment();
                }
            });

    actionableDynamicQuery.performActions();

    Assert.assertEquals(count.getValue(), _persistence.countAll());
}

From source file:com.liferay.adaptive.media.image.service.persistence.test.AMImageEntryPersistenceTest.java

License:Open Source License

@Test
public void testActionableDynamicQuery() throws Exception {
    final IntegerWrapper count = new IntegerWrapper();

    ActionableDynamicQuery actionableDynamicQuery = AMImageEntryLocalServiceUtil.getActionableDynamicQuery();

    actionableDynamicQuery/*w  w w . j  av a2  s.co  m*/
            .setPerformActionMethod(new ActionableDynamicQuery.PerformActionMethod<AMImageEntry>() {
                @Override
                public void performAction(AMImageEntry amImageEntry) {
                    Assert.assertNotNull(amImageEntry);

                    count.increment();
                }
            });

    actionableDynamicQuery.performActions();

    Assert.assertEquals(count.getValue(), _persistence.countAll());
}

From source file:com.liferay.asset.category.property.service.persistence.test.AssetCategoryPropertyPersistenceTest.java

License:Open Source License

@Test
public void testActionableDynamicQuery() throws Exception {
    final IntegerWrapper count = new IntegerWrapper();

    ActionableDynamicQuery actionableDynamicQuery = AssetCategoryPropertyLocalServiceUtil
            .getActionableDynamicQuery();

    actionableDynamicQuery/*from  w w w .  j a v a2s .  co m*/
            .setPerformActionMethod(new ActionableDynamicQuery.PerformActionMethod<AssetCategoryProperty>() {
                @Override
                public void performAction(AssetCategoryProperty assetCategoryProperty) {
                    Assert.assertNotNull(assetCategoryProperty);

                    count.increment();
                }
            });

    actionableDynamicQuery.performActions();

    Assert.assertEquals(count.getValue(), _persistence.countAll());
}