Package org.apache.tapestry.form

Examples of org.apache.tapestry.form.ListEditMap


        assertNull(m.getValue());
    }

    public void testMarkDeleted()
    {
        ListEditMap m = create();

        m.setKey("page");

        assertEquals(false, m.isDeleted());

        m.setDeleted(true);

        assertEquals(true, m.isDeleted());

        checkList("all values", new Object[]
        { BeanLifecycle.REQUEST, BeanLifecycle.PAGE, BeanLifecycle.RENDER }, m.getAllValues());

        checkList("undeleted values", new Object[]
        { BeanLifecycle.REQUEST, BeanLifecycle.RENDER }, m.getValues());

        checkList("deleted keys", new Object[]
        { "page" }, m.getDeletedKeys());
    }
View Full Code Here


    public abstract void setPublisher(Publisher publisher);

    public void synchronizePublisher(IRequestCycle cycle)
    {
        ListEditMap map = getListEditMap();

        Publisher publisher = (Publisher) map.getValue();

        if (publisher == null)
        {
            setError(getMessage("out-of-date"));
            throw new PageRedirectException(this);
View Full Code Here

            {
                vengine.rmiFailure(getMessage("read-failure"), ex, i++);
            }
        }

        ListEditMap map = new ListEditMap();

        int count = Tapestry.size(publishers);

        for (i = 0; i < count; i++)
            map.add(publishers[i].getId(), publishers[i]);

        setListEditMap(map);
    }
View Full Code Here

    public void processForm(IRequestCycle cycle)
    {
        if (isInError())
            return;

        ListEditMap map = getListEditMap();
        List updateList = map.getValues();
        List deletedIds = map.getDeletedKeys();

        Publisher[] updated = (Publisher[]) updateList.toArray(new Publisher[updateList.size()]);

        Integer[] deleted =
            deletedIds == null
View Full Code Here

    public abstract void setPublisher(Publisher publisher);

    public void synchronizePublisher(IRequestCycle cycle)
    {
        ListEditMap map = getListEditMap();

        Publisher publisher = (Publisher) map.getValue();

        if (publisher == null)
        {
            setError(getMessage("out-of-date"));
            throw new PageRedirectException(this);
View Full Code Here

            {
                vengine.rmiFailure(getMessage("read-failure"), ex, i++);
            }
        }

        ListEditMap map = new ListEditMap();

        int count = Tapestry.size(publishers);

        for (i = 0; i < count; i++)
            map.add(publishers[i].getId(), publishers[i]);

        setListEditMap(map);
    }
View Full Code Here

    public void processForm(IRequestCycle cycle)
    {
        if (isInError())
            return;

        ListEditMap map = getListEditMap();
        List updateList = map.getValues();
        List deletedIds = map.getDeletedKeys();

        Publisher[] updated = (Publisher[]) updateList.toArray(new Publisher[updateList.size()]);

        Integer[] deleted =
            deletedIds == null
View Full Code Here

    public abstract void setPublisher(Publisher publisher);

    public void synchronizePublisher(IRequestCycle cycle)
    {
        ListEditMap map = getListEditMap();

        Publisher publisher = (Publisher) map.getValue();

        if (publisher == null)
        {
            setError(getMessage("out-of-date"));
            throw new PageRedirectException(this);
View Full Code Here

            {
                vengine.rmiFailure(getMessage("read-failure"), ex, i++);
            }
        }

        ListEditMap map = new ListEditMap();

        int count = Tapestry.size(publishers);

        for (i = 0; i < count; i++)
            map.add(publishers[i].getId(), publishers[i]);

        setListEditMap(map);
    }
View Full Code Here

    public void processForm(IRequestCycle cycle)
    {
        if (isInError())
            return;

        ListEditMap map = getListEditMap();
        List updateList = map.getValues();
        List deletedIds = map.getDeletedKeys();

        Publisher[] updated = (Publisher[]) updateList.toArray(new Publisher[updateList.size()]);

        Integer[] deleted = deletedIds == null ? null : (Integer[]) deletedIds
                .toArray(new Integer[deletedIds.size()]);
View Full Code Here

TOP

Related Classes of org.apache.tapestry.form.ListEditMap

Copyright © 2018 www.massapicom. 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.