Package org.apache.cayenne.ashwood

Examples of org.apache.cayenne.ashwood.AshwoodEntitySorter


                binder.bindList(Constants.SERVER_DEFAULT_TYPES_LIST);
                binder.bindList(Constants.SERVER_USER_TYPES_LIST);       
                binder.bindList(Constants.SERVER_TYPE_FACTORIES_LIST);
               
                binder.bind(EventManager.class).toInstance(eventManager);
                binder.bind(EntitySorter.class).toInstance(new AshwoodEntitySorter());
                binder.bind(ResourceLocator.class).toInstance(locator);
                binder.bind(ConfigurationNameMapper.class).to(
                        DefaultConfigurationNameMapper.class);
                binder.bind(DataChannelDescriptorMerger.class).to(
                        DefaultDataChannelDescriptorMerger.class);
View Full Code Here


        Module testModule = new Module() {

            public void configure(Binder binder) {
                binder.bind(EventManager.class).toInstance(eventManager);
                binder.bind(EntitySorter.class).toInstance(new AshwoodEntitySorter());
                binder.bind(ResourceLocator.class).toInstance(locator);
                binder.bind(RuntimeProperties.class).toInstance(testProperties);
                binder.bind(ConfigurationNameMapper.class).to(
                        DefaultConfigurationNameMapper.class);
                binder.bind(DataChannelDescriptorLoader.class).toInstance(testLoader);
View Full Code Here

        this.dataSetFactory = dataSetFactory;
        this.resources = resources;
        this.domain = new UnitTestDomain("domain");
        domain.setEventManager(new DefaultEventManager(2));
        domain.setEntitySorter(new AshwoodEntitySorter());
       
        for (DataMap map : maps) {
            initNode(map);
        }
    }
View Full Code Here

            maps[i] = new MapLoader().loadDataMap(in);
        }

        this.domain = new DataDomain("temp");
        domain.setEventManager(new DefaultEventManager(2));
        domain.setEntitySorter(new AshwoodEntitySorter());
        domain.setQueryCache(new MapQueryCache(50));

        try {
            for (DataMap map : maps) {
                initNode(map);
View Full Code Here

            }
        }

        // sort table list
        if (tables.size() > 1) {
            EntitySorter sorter = new AshwoodEntitySorter();
            sorter.setEntityResolver(new EntityResolver(Collections.singleton(map)));
            sorter.sortDbEntities(tables, false);
        }

        this.dbEntitiesInInsertOrder = tables;
        this.dbEntitiesRequiringAutoPK = tablesWithAutoPk;
    }
View Full Code Here

            return;
        }

        // sort entities for insertion
        List sorted = new ArrayList(entities);
        EntitySorter sorter = new AshwoodEntitySorter();
        sorter.setEntityResolver(new EntityResolver(destinationNode.getDataMaps()));
        sorter.sortDbEntities(sorted, false);

        if (cleaningDestination) {
            // reverse insertion order for deletion
            List entitiesInDeleteOrder = new ArrayList(sorted.size());
            entitiesInDeleteOrder.addAll(sorted);
View Full Code Here

            maps[i] = new MapLoader().loadDataMap(in);
        }

        this.domain = new DataDomain("temp");
        domain.setEventManager(new DefaultEventManager(2));
        domain.setEntitySorter(new AshwoodEntitySorter());
        domain.setQueryCache(new MapQueryCache(50));

        try {
            for (DataMap map : maps) {
                initNode(map);
View Full Code Here

                binder.bindList(Constants.SERVER_DEFAULT_TYPES_LIST);
                binder.bindList(Constants.SERVER_USER_TYPES_LIST);       
                binder.bindList(Constants.SERVER_TYPE_FACTORIES_LIST);
               
                binder.bind(EventManager.class).toInstance(eventManager);
                binder.bind(EntitySorter.class).toInstance(new AshwoodEntitySorter());
                binder.bind(ResourceLocator.class).toInstance(locator);
                binder.bind(ConfigurationNameMapper.class).to(
                        DefaultConfigurationNameMapper.class);
                binder.bind(DataChannelDescriptorMerger.class).to(
                        DefaultDataChannelDescriptorMerger.class);
View Full Code Here

TOP

Related Classes of org.apache.cayenne.ashwood.AshwoodEntitySorter

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.