Class RelatedTablesExtension
java.lang.Object
mil.nga.geopackage.extension.BaseExtension
mil.nga.geopackage.extension.related.RelatedTablesCoreExtension
mil.nga.geopackage.extension.related.RelatedTablesExtension
Related Tables extension
- Since:
- 3.0.1
-
Field Summary
Fields inherited from class mil.nga.geopackage.extension.related.RelatedTablesCoreExtension
EXTENSION_AUTHOR, EXTENSION_DEFINITION, EXTENSION_NAME, EXTENSION_NAME_NO_AUTHORFields inherited from class mil.nga.geopackage.extension.BaseExtension
extensionsDao, geoPackage -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintcountMappings(String table, long id) Count the number of mappings to the table and idintcountMappingsToBase(String baseTable, long baseId) Count the number of mappings to the base table and idintcountMappingsToBase(Collection<ExtendedRelation> extendedRelations, long baseId) Count the number of mappings in the extended relations to the base idintcountMappingsToBase(ExtendedRelation extendedRelation, long baseId) Count the number of mappings in the extended relation to the base idintcountMappingsToRelated(String relatedTable, long relatedId) Count the number of mappings to the related table and idintcountMappingsToRelated(Collection<ExtendedRelation> extendedRelations, long relatedId) Count the number of mappings in the extended relations to the related idintcountMappingsToRelated(ExtendedRelation extendedRelation, long relatedId) Count the number of mappings in the extended relation to the related idintdeleteMappings(String table, long id) Delete mappings to the table and idintdeleteMappingsToBase(String baseTable, long baseId) Delete mappings to the base table and idintdeleteMappingsToBase(Collection<ExtendedRelation> extendedRelations, long baseId) Delete mappings in the extended relations to the base idintdeleteMappingsToBase(ExtendedRelation extendedRelation, long baseId) Delete mappings in the extended relation to the base idintdeleteMappingsToRelated(String relatedTable, long relatedId) Delete mappings to the related table and idintdeleteMappingsToRelated(Collection<ExtendedRelation> extendedRelations, long relatedId) Delete mappings in the extended relations to the related idintdeleteMappingsToRelated(ExtendedRelation extendedRelation, long relatedId) Delete mappings in the extended relation to the related idgetMappingDao(String tableName) Get a User Mapping DAO from a table namegetMappingDao(ExtendedRelation extendedRelation) Get a User Mapping DAO from an extended relationgetMappingsForBase(String tableName, long baseId) Get the related id mappings for the base idgetMappingsForBase(ExtendedRelation extendedRelation, long baseId) Get the related id mappings for the base idgetMappingsForRelated(String tableName, long relatedId) Get the base id mappings for the related idgetMappingsForRelated(ExtendedRelation extendedRelation, long relatedId) Get the base id mappings for the related idgetMediaDao(String tableName) Get a related media table DAOgetMediaDao(ExtendedRelation extendedRelation) Get a related media table DAOgetMediaDao(MediaTable mediaTable) Get a related media table DAOgetSimpleAttributesDao(String tableName) Get a related simple attributes table DAOgetSimpleAttributesDao(ExtendedRelation extendedRelation) Get a related simple attributes table DAOgetSimpleAttributesDao(SimpleAttributesTable simpleAttributesTable) Get a related simple attributes table DAOgetUserDao(String tableName) Get a User Custom DAO from a table namebooleanhasMapping(String table, long id) Determine if a mapping to the table and id existsbooleanhasMapping(String tableName, long baseId, long relatedId) Determine if the base id and related id mapping existsbooleanhasMappingToBase(String baseTable, long baseId) Determine if a mapping to the base table and id existsbooleanhasMappingToBase(Collection<ExtendedRelation> extendedRelations, long baseId) Determine if a mapping in the extended relations to the base id existsbooleanhasMappingToBase(ExtendedRelation extendedRelation, long baseId) Determine if a mapping in the extended relation to the base id existsbooleanhasMappingToRelated(String relatedTable, long relatedId) Determine if a mapping to the related table and id existsbooleanhasMappingToRelated(Collection<ExtendedRelation> extendedRelations, long relatedId) Determine if a mapping in the extended relations to the related id existsbooleanhasMappingToRelated(ExtendedRelation extendedRelation, long relatedId) Determine if a mapping in the extended relation to the related id existsMethods inherited from class mil.nga.geopackage.extension.related.RelatedTablesCoreExtension
addAttributesRelationship, addAttributesRelationship, addAttributesRelationship, addAttributesRelationship, addFeaturesRelationship, addFeaturesRelationship, addMediaRelationship, addMediaRelationship, addRelationship, addRelationship, addRelationship, addRelationship, addRelationship, addRelationship, addRelationship, addRelationship, addRelationship, addRelationship, addRelationship, addRelationship, addSimpleAttributesRelationship, addSimpleAttributesRelationship, addTilesRelationship, addTilesRelationship, addTilesRelationship, addTilesRelationship, buildRelationName, createExtendedRelationsTable, createRelatedTable, createUserMappingTable, createUserMappingTable, getBaseTableRelations, getExtendedRelationsDao, getExtendedRelationsDao, getExtendedRelationsDao, getPrimaryKeyColumnName, getRelatedTableRelations, getRelations, getRelations, getRelations, getRelations, getRelationships, getTableRelations, has, has, hasBaseTableRelations, hasRelatedTableRelations, hasRelations, hasRelations, hasRelations, hasRelations, hasTableRelations, removeExtension, removeRelationship, removeRelationship, removeRelationship, removeRelationship, removeRelationships, removeRelationshipsWithMappingTable, setContentsMethods inherited from class mil.nga.geopackage.extension.BaseExtension
createDao, get, getExtensions, getExtensions, getExtensionsDao, getOrCreate, has, has, verifyWritable
-
Constructor Details
-
RelatedTablesExtension
Constructor- Parameters:
geoPackage- GeoPackage
-
-
Method Details
-
getGeoPackage
- Overrides:
getGeoPackagein classBaseExtension
-
getUserDao
Get a User Custom DAO from a table name- Parameters:
tableName- table name- Returns:
- user custom dao
-
getMappingDao
Get a User Mapping DAO from a table name- Parameters:
tableName- mapping table name- Returns:
- user mapping dao
-
getMediaDao
Get a related media table DAO- Parameters:
tableName- media table name- Returns:
- media DAO
-
getSimpleAttributesDao
Get a related simple attributes table DAO- Parameters:
tableName- simple attributes table name- Returns:
- simple attributes DAO
-
getMappingsForBase
Get the related id mappings for the base id- Parameters:
tableName- mapping table namebaseId- base id- Returns:
- IDs representing the matching related IDs
-
getMappingsForRelated
Get the base id mappings for the related id- Parameters:
tableName- mapping table namerelatedId- related id- Returns:
- IDs representing the matching base IDs
-
hasMapping
Determine if the base id and related id mapping exists- Parameters:
tableName- mapping table namebaseId- base idrelatedId- related id- Returns:
- true if mapping exists
- Since:
- 3.2.0
-
countMappingsToBase
Count the number of mappings to the base table and id- Parameters:
baseTable- base table namebaseId- base id- Returns:
- mappings count
- Throws:
SQLException- upon failure- Since:
- 6.3.0
-
hasMappingToBase
Determine if a mapping to the base table and id exists- Parameters:
baseTable- base table namebaseId- base id- Returns:
- true if mapping exists
- Throws:
SQLException- upon failure- Since:
- 6.3.0
-
countMappingsToBase
Count the number of mappings in the extended relations to the base id- Parameters:
extendedRelations- extended relationsbaseId- base id- Returns:
- mappings count
- Since:
- 6.3.0
-
hasMappingToBase
Determine if a mapping in the extended relations to the base id exists- Parameters:
extendedRelations- extended relationsbaseId- base id- Returns:
- true if mapping exists
- Since:
- 6.3.0
-
deleteMappingsToBase
Delete mappings to the base table and id- Parameters:
baseTable- base table namebaseId- base id- Returns:
- rows deleted
- Throws:
SQLException- upon failure- Since:
- 6.3.0
-
deleteMappingsToBase
public int deleteMappingsToBase(Collection<ExtendedRelation> extendedRelations, long baseId) throws SQLException Delete mappings in the extended relations to the base id- Parameters:
extendedRelations- extended relationsbaseId- base id- Returns:
- rows deleted
- Throws:
SQLException- upon failure- Since:
- 6.3.0
-
countMappingsToRelated
Count the number of mappings to the related table and id- Parameters:
relatedTable- related table namerelatedId- related id- Returns:
- mappings count
- Throws:
SQLException- upon failure- Since:
- 6.3.0
-
hasMappingToRelated
Determine if a mapping to the related table and id exists- Parameters:
relatedTable- related table namerelatedId- related id- Returns:
- true if mapping exists
- Throws:
SQLException- upon failure- Since:
- 6.3.0
-
countMappingsToRelated
Count the number of mappings in the extended relations to the related id- Parameters:
extendedRelations- extended relationsrelatedId- related id- Returns:
- mappings count
- Since:
- 6.3.0
-
hasMappingToRelated
Determine if a mapping in the extended relations to the related id exists- Parameters:
extendedRelations- extended relationsrelatedId- related id- Returns:
- true if mapping exists
- Since:
- 6.3.0
-
deleteMappingsToRelated
Delete mappings to the related table and id- Parameters:
relatedTable- related table namerelatedId- related id- Returns:
- rows deleted
- Throws:
SQLException- upon failure- Since:
- 6.3.0
-
deleteMappingsToRelated
public int deleteMappingsToRelated(Collection<ExtendedRelation> extendedRelations, long relatedId) throws SQLException Delete mappings in the extended relations to the related id- Parameters:
extendedRelations- extended relationsrelatedId- related id- Returns:
- rows deleted
- Throws:
SQLException- upon failure- Since:
- 6.3.0
-
countMappings
Count the number of mappings to the table and id- Parameters:
table- table nameid- table id- Returns:
- mappings count
- Throws:
SQLException- upon failure- Since:
- 6.3.0
-
hasMapping
Determine if a mapping to the table and id exists- Parameters:
table- table nameid- table id- Returns:
- true if mapping exists
- Throws:
SQLException- upon failure- Since:
- 6.3.0
-
deleteMappings
Delete mappings to the table and id- Parameters:
table- table nameid- table id- Returns:
- rows deleted
- Throws:
SQLException- upon failure- Since:
- 6.3.0
-