Class GeoPackageTableCreator

    • Constructor Detail

      • GeoPackageTableCreator

        public GeoPackageTableCreator​(GeoPackageCoreConnection db)
        Constructor
        Parameters:
        db - db connection
      • GeoPackageTableCreator

        public GeoPackageTableCreator​(GeoPackageCore geoPackage)
        Constructor
        Parameters:
        geoPackage - GeoPackage
        Since:
        4.0.0
    • Method Detail

      • getScript

        public static String getScript​(String property)
        Get the database script name for the property
        Parameters:
        property - property name
        Returns:
        script name
        Since:
        3.3.0
      • readScript

        public static List<String> readScript​(String property)
        Read the SQL Script and parse the statements for the property
        Parameters:
        property - property name
        Returns:
        statements
        Since:
        4.0.0
      • readScript

        public static List<String> readScript​(String pathProperty,
                                              String property)
        Read the SQL Script and parse the statements for the property
        Parameters:
        pathProperty - path property
        property - property name
        Returns:
        statements
        Since:
        4.0.0
      • readSQLScript

        public static List<String> readSQLScript​(String sqlScript)
        Read the SQL Script and parse the statements
        Parameters:
        sqlScript - SQL script property file name
        Returns:
        statements
        Since:
        3.3.0
      • readSQLScript

        public static List<String> readSQLScript​(String property,
                                                 String sqlScript)
        Read the SQL Script and parse the statements
        Parameters:
        property - path property
        sqlScript - SQL script property file name
        Returns:
        statements
        Since:
        4.0.0
      • createSpatialReferenceSystem

        public int createSpatialReferenceSystem()
        Create Spatial Reference System table and views
        Returns:
        executed statements
      • createContents

        public int createContents()
        Create Contents table
        Returns:
        executed statements
      • createGeometryColumns

        public int createGeometryColumns()
        Create Geometry Columns table
        Returns:
        executed statements
      • createTileMatrixSet

        public int createTileMatrixSet()
        Create Tile Matrix Set table
        Returns:
        executed statements
      • createTileMatrix

        public int createTileMatrix()
        Create Tile Matrix table
        Returns:
        executed statements
      • createExtensions

        public int createExtensions()
        Create Extensions table
        Returns:
        executed statements
      • createDataColumns

        public int createDataColumns()
        Create Data Columns table
        Returns:
        executed statements
      • createDataColumnConstraints

        public int createDataColumnConstraints()
        Create Data Column Constraints table
        Returns:
        executed statements
      • createMetadata

        public int createMetadata()
        Create Metadata table
        Returns:
        executed statements
      • createMetadataReference

        public int createMetadataReference()
        Create Metadata Reference table
        Returns:
        executed statements
      • createGriddedCoverage

        public int createGriddedCoverage()
        Create the Tiled Gridded Coverage Data Coverage extension table
        Returns:
        executed statements
        Since:
        1.2.1
      • createGriddedTile

        public int createGriddedTile()
        Create the Tiled Gridded Coverage Data Tile extension table
        Returns:
        executed statements
        Since:
        1.2.1
      • createExtendedRelations

        public int createExtendedRelations()
        Create the Extended Relations table
        Returns:
        executed statements
        Since:
        3.0.1
      • execScript

        public int execScript()
        Execute the database script name
        Returns:
        executed statements
        Since:
        4.0.0
      • execScript

        public int execScript​(String property)
        Execute the database script name for the property
        Parameters:
        property - property name
        Returns:
        executed statements
        Since:
        4.0.0
      • execScript

        public int execScript​(String propertyPath,
                              String property)
        Execute the database script name for the property
        Parameters:
        propertyPath - table creator property path
        property - property name
        Returns:
        executed statements
        Since:
        4.0.0
      • execSQLScript

        public int execSQLScript​(String sqlScript)
        Execute the SQL Script
        Parameters:
        sqlScript - SQL script property file name
        Returns:
        executed statements
        Since:
        3.3.0
      • execSQLScript

        public int execSQLScript​(String property,
                                 String sqlScript)
        Execute the SQL Script
        Parameters:
        property - table creator property path
        sqlScript - SQL script property file name
        Returns:
        executed statements
        Since:
        4.0.0
      • getProperty

        public String getProperty()
        Get the table creator property path
        Returns:
        property path or null
        Since:
        4.0.0
      • getAuthor

        public String getAuthor()
        Get the table creator author
        Returns:
        author or null
        Since:
        4.0.0
      • getName

        public String getName()
        Get the table creator name
        Returns:
        name or null
        Since:
        4.0.0
      • createTable

        public <TColumn extends UserColumn> void createTable​(UserTable<TColumn> table)
        Create the user defined table
        Type Parameters:
        TColumn - column type
        Parameters:
        table - user table
      • createRequired

        public void createRequired()
        Create the minimum required GeoPackage tables
      • dropTable

        public void dropTable​(String table)
        Drop the table if it exists
        Parameters:
        table - table name
        Since:
        1.1.5
      • dropView

        public void dropView​(String view)
        Drop the view if it exists
        Parameters:
        view - view name
        Since:
        4.0.0