Package com.iver.cit.gvsig.fmap.drivers

Examples of com.iver.cit.gvsig.fmap.drivers.DBLayerDefinition


    public void open(Connection con, String tableName, String geomFieldName)
            throws DriverException {
        VectorialDBAdapter adapter = new VectorialDBAdapter();
        PostGisDriver driver = new PostGisDriver();
        DBLayerDefinition layerDef = new DBLayerDefinition();
        layerDef.setFieldGeometry(geomFieldName);
        try {
            layerDef.setFieldID(getPKNames(con, tableName));
            layerDef.setFieldNames(getFieldNames(con, "select * from "
                    + tableName + " where false"));
        } catch (SQLException e) {
            throw new DriverException(e);
        }
        layerDef.setTableName(tableName);
        layerDef.setWhereClause("");
        layerDef.setWorkingArea(null);
        driver.setData(con, layerDef);
        adapter.setDriver(driver);
        adapter.start();
        setDriver(driver);
        super.open(adapter);
View Full Code Here

TOP

Related Classes of com.iver.cit.gvsig.fmap.drivers.DBLayerDefinition

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.