Examples of addItemProperty()


Examples of com.vaadin.data.Item.addItemProperty()

    @Test
    public void passesFilter_containsLikeQueryOnStringEqualToValueMinusOneCharAtTheEnd_shouldFail() {
        Like like = new Like("test", "%foo%");

        Item item = new PropertysetItem();
        item.addItemProperty("test", new ObjectProperty<String>("fo"));

        Assert.assertFalse(like.passesFilter("id", item));
    }

    @Test
View Full Code Here

Examples of com.vaadin.data.Item.addItemProperty()

    @Test
    public void passesFilter_beginsWithLikeQueryOnStringBeginningWithValue_shouldSucceed() {
        Like like = new Like("test", "foo%");

        Item item = new PropertysetItem();
        item.addItemProperty("test", new ObjectProperty<String>("foobar"));

        Assert.assertTrue(like.passesFilter("id", item));
    }

    @Test
View Full Code Here

Examples of com.vaadin.data.util.PropertysetItem.addItemProperty()

        date.setLocale(new Locale("fi", "fi"));
        date.setShowISOWeekNumbers(true);
        row.addComponent(date);

        PropertysetItem item = new PropertysetItem();
        item.addItemProperty("date", new ObjectProperty<Date>(getDefaultDate()));

        FormLayout form = new FormLayout();
        form.setMargin(false);

        FieldGroup binder = new FieldGroup(item);
View Full Code Here

Examples of com.vaadin.data.util.PropertysetItem.addItemProperty()

    public static final String PROPERTY_1_ID = "property 1";
    public static final String PROPERTY_2_ID = "property 2";

    private void loadItems() {
        final PropertysetItem item1 = new PropertysetItem();
        item1.addItemProperty(PROPERTY_1_ID, new ObjectProperty<String>(
                "value 1", String.class));
        item1.addItemProperty(PROPERTY_2_ID, new ObjectProperty<String>(
                "name 1", String.class));
        items.put(ITEM_1_ID, item1);
View Full Code Here

Examples of com.vaadin.data.util.PropertysetItem.addItemProperty()

    private void loadItems() {
        final PropertysetItem item1 = new PropertysetItem();
        item1.addItemProperty(PROPERTY_1_ID, new ObjectProperty<String>(
                "value 1", String.class));
        item1.addItemProperty(PROPERTY_2_ID, new ObjectProperty<String>(
                "name 1", String.class));
        items.put(ITEM_1_ID, item1);

        final PropertysetItem item2 = new PropertysetItem();
        item2.addItemProperty(PROPERTY_1_ID, new ObjectProperty<String>(
View Full Code Here

Examples of com.vaadin.data.util.PropertysetItem.addItemProperty()

        item1.addItemProperty(PROPERTY_2_ID, new ObjectProperty<String>(
                "name 1", String.class));
        items.put(ITEM_1_ID, item1);

        final PropertysetItem item2 = new PropertysetItem();
        item2.addItemProperty(PROPERTY_1_ID, new ObjectProperty<String>(
                "value 2", String.class));
        item2.addItemProperty(PROPERTY_2_ID, new ObjectProperty<String>(
                "name 2", String.class));
        items.put(ITEM_2_ID, item2);
    }
View Full Code Here

Examples of com.vaadin.data.util.PropertysetItem.addItemProperty()

        items.put(ITEM_1_ID, item1);

        final PropertysetItem item2 = new PropertysetItem();
        item2.addItemProperty(PROPERTY_1_ID, new ObjectProperty<String>(
                "value 2", String.class));
        item2.addItemProperty(PROPERTY_2_ID, new ObjectProperty<String>(
                "name 2", String.class));
        items.put(ITEM_2_ID, item2);
    }

    @Override
View Full Code Here

Examples of com.vaadin.data.util.PropertysetItem.addItemProperty()

    public static final String PROPERTY_2_ID = "property 2";

    private void loadItems() {
        for (int i = 1; i < 15; i++) {
            final PropertysetItem item = new PropertysetItem();
            item.addItemProperty(PROPERTY_1_ID, new ObjectProperty<String>(
                    "value " + i, String.class));
            item.addItemProperty(PROPERTY_2_ID, new ObjectProperty<String>(
                    "name " + i, String.class));
            items.put(String.valueOf(i), item);
        }
View Full Code Here

Examples of com.vaadin.data.util.PropertysetItem.addItemProperty()

    private void loadItems() {
        for (int i = 1; i < 15; i++) {
            final PropertysetItem item = new PropertysetItem();
            item.addItemProperty(PROPERTY_1_ID, new ObjectProperty<String>(
                    "value " + i, String.class));
            item.addItemProperty(PROPERTY_2_ID, new ObjectProperty<String>(
                    "name " + i, String.class));
            items.put(String.valueOf(i), item);
        }
    }
View Full Code Here

Examples of com.vaadin.data.util.PropertysetItem.addItemProperty()

    }

    @Test
    public void perfectMatchPriority() {
        PropertysetItem item = new PropertysetItem();
        item.addItemProperty("first_name", new ObjectProperty<String>(
                "Not this"));
        item.addItemProperty("firstName", new ObjectProperty<String>("This"));

        class MyForm extends FormLayout {
            TextField firstName = new TextField("First name");
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.