Examples of Hints


Examples of org.geotools.factory.Hints

            @SuppressWarnings("rawtypes") final FeatureSource featureSource,
            final ProgressListener taskProgress) {

        final Query query = new Query();
        CoordinateSequenceFactory coordSeq = new PackedCoordinateSequenceFactory();
        query.getHints().add(new Hints(Hints.JTS_COORDINATE_SEQUENCE_FACTORY, coordSeq));
        workTree.insert(path, featureSource, query, taskProgress);

    }
View Full Code Here

Examples of org.geotools.factory.Hints

        @Override
        public Integer call() throws Exception {

            final Query query = new Query();
            CoordinateSequenceFactory coordSeq = new PackedCoordinateSequenceFactory();
            query.getHints().add(new Hints(Hints.JTS_COORDINATE_SEQUENCE_FACTORY, coordSeq));
            query.setStartIndex(offset);
            if (limit != null && limit.intValue() > 0) {
                query.setMaxFeatures(limit);
            }
            FeatureCollection collection = source.getFeatures(query);
View Full Code Here

Examples of org.geotools.factory.Hints

            FeatureSource<SimpleFeatureType, SimpleFeature> featureSource = _featureSourceFactory
                    .getFeatureSource();
            CoordinateReferenceSystem sourceCRS = featureSource.getInfo().getCRS();

            Hints hints = new Hints(Hints.FORCE_LONGITUDE_FIRST_AXIS_ORDER, Boolean.TRUE);
            CRSAuthorityFactory factory = ReferencingFactoryFinder.getCRSAuthorityFactory("EPSG",
                    hints);
            CoordinateReferenceSystem worldCRS = factory
                    .createCoordinateReferenceSystem("EPSG:4326");
View Full Code Here

Examples of org.geotools.factory.Hints

    String[] codes;
    Hints hints;

    protected void connect() throws Exception {
        super.connect();
        hints = new Hints(Hints.CACHE_POLICY, "none");    
        hints.put(Hints.AUTHORITY_MAX_ACTIVE, new Integer(MAX_WORKERS));
        if (datasource == null) {
            fail("no datasource available");
        }
        wrappedDataSource = new BasicDataSource(){
View Full Code Here

Examples of org.geotools.factory.Hints

    private OracleDialectEpsgFactory factory;
   
    protected void connect() throws Exception {
        super.connect();
        Hints hints = new Hints(Hints.CACHE_POLICY, "none");    
        factory = new OracleDialectEpsgFactory(hints, datasource.getConnection());
    }
View Full Code Here

Examples of org.geotools.factory.Hints

        super.connect();
        Map config = new HashMap();
        config.put( Hints.CACHE_POLICY,"none");
        //config.put( Hints.EPSG_DATA_SOURCE, datasource );
        config.put( Hints.EPSG_DATA_SOURCE, "jdbc/EPSG" );
        Hints hints = new Hints( config );
        mediator = new OracleDialectEpsgMediator( hints );
       
        //mediator = new OracleDialectEpsgMediator(80, hints, datasource);
    }
View Full Code Here

Examples of org.geotools.factory.Hints

    protected void connect() throws Exception {
        super.connect();
        if( fixture == null ) return; // we are not online - skip test
       
        wrappedDS = (BasicDataSource) datasource;
        hints = new Hints(Hints.CACHE_POLICY, "none");    
        hints.put(Hints.AUTHORITY_MAX_ACTIVE, new Integer(MAX_WORKERS));       
       
        mediator = new OracleDialectEpsgMediator(80, hints, datasource);
        codes = getCodes();
    }
View Full Code Here

Examples of org.geotools.factory.Hints

        return reader;
    }

    private GeometryFactory getGeometryFactory(final Hints queryHints) {
        // setup the geometry factory according to the hints
        final Hints hints;
        if (queryHints == null) {
            hints = GeoTools.getDefaultHints();
        } else {
            hints = queryHints;
        }

        GeometryFactory gf = (GeometryFactory) hints.get(Hints.JTS_GEOMETRY_FACTORY);

        if (gf == null) {
            PrecisionModel pm = (PrecisionModel) hints.get(Hints.JTS_PRECISION_MODEL);
            if (pm == null) {
                pm = new PrecisionModel();
            }
            Integer SRID = (Integer) hints.get(Hints.JTS_SRID);
            int srid = SRID == null ? 0 : SRID.intValue();
            Integer dimension = (Integer) hints.get(Hints.COORDINATE_DIMENSION);
            CoordinateSequenceFactory csFactory = (CoordinateSequenceFactory) hints
                    .get(Hints.JTS_COORDINATE_SEQUENCE_FACTORY);
            if (csFactory == null) {
                if (dimension == null || dimension <= 3) {
                    csFactory = CoordinateArraySequenceFactory.instance();
                } else {
View Full Code Here

Examples of org.geotools.factory.Hints

     *
     * @param hints
     * @return FilterFactory
     */
    static FilterFactory2 filterFactory(Map map){
        Hints hints = null;
        if( map instanceof Hints){
            hints = (Hints) map;
        }       
      return CommonFactoryFinder.getFilterFactory2( hints );
    }
View Full Code Here

Examples of org.geotools.factory.Hints

            return;
        }
       
        if (factory == null) {
            factory = (ThreadedEpsgFactory) ReferencingFactoryFinder.getCRSAuthorityFactory("EPSG",
                        new Hints(Hints.CRS_AUTHORITY_FACTORY, ThreadedEpsgFactory.class));
            extensive |= TestData.isExtensiveTest();
            if (verbose) {
                System.out.print("Database version: ");
                System.out.println(factory.getImplementationHints().get(Hints.VERSION));
            }
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.