com.supermap.services.components.impl

Class DataImpl

  • java.lang.Object
    • com.supermap.services.components.impl.DataImpl
    • Constructor Summary

      Constructors 
      Constructor and Description
      DataImpl()
      The default constructor.
      DataImpl(DataContext context)
      Constructs a DataImpl object according to the context of a data service component.
    • Method Summary

      Methods 
      Modifier and Type Method and Description
      AttachmentInfo addAttachment(java.lang.String datasourceName, java.lang.String datasetName, int featureId, Attachment attachment)
      Related to the attachment for feature.
      EditResult addFeatures(java.lang.String datasourceName, java.lang.String datasetName, java.util.List<Feature> targetFeatures)
      Adds a set of features of the same type to a specified dataset.
      void batchAddFeatures(java.lang.String datasourceName, java.lang.String datasetName, java.util.List<Feature> targetFeatures)
      Adds elements in batch, the performance is higher than the addFeatures interface when adding massive features.
      boolean clearFeatures(java.lang.String datasourceName, java.lang.String datasetName)
      Clears the features in a specified dataset.
      boolean containsDataset(java.lang.String datasourceName, java.lang.String datasetName)
      Determines whether a specified datasource contains a specified dataset.
      java.util.List<Geometry> coordtransfer(Geometry[] geometry, PrjCoordSys sourcePrjCoorSys, PrjCoordSys targetPrjCoordSys)
      According to the target coordinate system, converting the geographic object collection coordinate system
      boolean copyDataset(java.lang.String srcDatasourceName, java.lang.String srcDatasetName, java.lang.String destDatasourceName, java.lang.String destDatasetName)
      Copies a replication of a specified dataset.
      boolean createDataset(java.lang.String dataSourceName, DatasetInfo datasetInfo)
      Creates a new dataset in a specified datasource according to the dataset information.
      boolean deleteAttachment(java.lang.String datasourceName, java.lang.String datasetName, int featureId, int id)
      Delete the attachment related to feature.
      boolean deleteDataset(java.lang.String datasourceName, java.lang.String datasetName)
      Removes a dataset from a specified datasource according to the dataset information.
      EditResult deleteFeatures(java.lang.String datasourceName, QueryParameter queryParameter)
      Specifies the data source to remove the feature via sql.
      EditResult deleteFeatures(java.lang.String datasourceName, java.lang.String datasetName, int[] ids)
      Deletes features from a specified dataset.
      void dispose()
      Releases the resources used by this data service component.
      protected void finalize()
      Releases the resources used by this data service component.
      Attachment getAttachement(java.lang.String datasourceName, java.lang.String datasetName, int featureId, int id)
      Gets the attachment data according to the attachment ID.
      java.util.List<AttachmentInfo> getAttachmentInfos(java.lang.String datasourceName, java.lang.String datasetName, int featureId)
      Gets the attachment info list related to feature.
      DatasetInfo getDatasetInfo(java.lang.String datasourceName, java.lang.String datasetName)
      Gets the information of a specified dataset in a given datasource.
      java.util.List<DatasetInfo> getDatasetInfos(java.lang.String datasourceName)
      Gets information about all the datasets in a specified datasource.
      java.util.List<java.lang.String> getDatasetNames(java.lang.String datasourceName)
      Gets all dataset names for the current data source.
      DatasourceInfo getDatasourceInfo(java.lang.String datasourceName)
      Gets information about a specified datasource.
      java.util.List<DatasourceInfo> getDatasourceInfos()
      Gets information about all the datasources corresponding to the current data service component.
      java.util.List<DomainInfo> getDomainInfos(java.lang.String datasourceName, java.lang.String datasetName)
      The new dataset information.
      GetFeatureResult getFeature(GetFeatureParameters parameters)
      Query and return the feature results.
      java.util.List<Feature> getFeature(java.lang.String datasourceName, QueryParameter queryParam)
      Gets features by a SQL query condition.
      java.util.List<Feature> getFeature(java.lang.String datasourceName, QueryParameter queryParam, int maxFeatures)
      Gets features by a SQL query condition.
      java.util.List<Feature> getFeature(java.lang.String datasourceName, java.lang.String datasetName, Geometry geometry, double bufferDistance, java.lang.String[] fields)
      Gets the features that fall within a buffer of a specified geometric object and meet a certain attribute filter condition.
      java.util.List<Feature> getFeature(java.lang.String datasourceName, java.lang.String datasetName, Geometry geometry, double bufferDistance, java.lang.String attributeFilter, java.lang.String[] fields)
      Gets the features that fall within a buffer of a specified geometric object and meet a certain attribute filter condition.
      java.util.List<Feature> getFeature(java.lang.String datasourceName, java.lang.String datasetName, Geometry geometry, SpatialQueryMode spatialQueryMode, java.lang.String[] fields)
      Gets the features that satisfy certain spatial query mode on a specified geometric object.
      java.util.List<Feature> getFeature(java.lang.String datasourceName, java.lang.String datasetName, Geometry geometry, SpatialQueryMode spatialQueryMode, java.lang.String attributeFilter, java.lang.String[] fields)
      Gets the features that satisfy certain spatial query mode on a specified geometric object and meet a certain attribute filter condition.
      java.util.List<Feature> getFeature(java.lang.String datasourceName, java.lang.String datasetName, int[] ids, java.lang.String[] fields)
      Gets features with specified IDs in a specified dataset.
      java.util.List<Feature> getFeature(java.lang.String datasourceName, java.lang.String datasetName, int[] ids, java.lang.String[] fields, int fromIndex, int toIndex)
      Gets the feature in the specified data set according to the specified feature ID in the way of supporting paging.
      java.util.List<Feature> getFeature(java.lang.String datasourceName, java.lang.String datasetName, Rectangle2D bounds, java.lang.String[] fields)
      Gets the features that fall within a specified space and meet a certain attribute filter condition.
      java.util.List<Feature> getFeature(java.lang.String datasourceName, java.lang.String datasetName, Rectangle2D bounds, java.lang.String attributeFilter, java.lang.String[] fields)
      Gets the features that fall within a specified space and meet a certain attribute filter condition.
      FeatureMetadata getFeatureMetadata(java.lang.String datasourceName, java.lang.String datasetName, int featureId)
      Gets the feature meta info.
      java.util.List<FieldInfo> getFieldInfos(java.lang.String datasourceName, java.lang.String datasetName)
      Get all the field info of the specified dataset.
      GridValue getGridValue(java.lang.String datasourceName, java.lang.String datasetName, Point2D point2d)
      Gets the grid value of the specified coordinate in a grid dataset.
      GridValues getGridValues(java.lang.String datasourceName, java.lang.String datasetName, Geometry geometry)
      Gets the grid value matrix within a specified rectangle.
      ImageValue getImageValue(java.lang.String datasourceName, java.lang.String datasetName, Point2D point2d)
      Gets the pixel value of the specified coordinate in a image dataset.
      ImageValues getImageValues(java.lang.String datasourceName, java.lang.String datasetName, Geometry geometry)
      Gets the grid value matrix within a specified rectangle.
      boolean isDisableQueryCache()
      Whether to enable caching when performing data query
      boolean renameDataset(java.lang.String datasourceName, java.lang.String oldName, java.lang.String newName)
      Modifies the name of a specified dataset.
      void setComponentContext(ComponentContext context)
      Sets the service component context.
      double statistic(java.lang.String datasourceName, java.lang.String datasetName, int fieldIndex, StatisticMode statisticMode)
      Calculates statistics on a specified field of a dataset based on a specified statistical mode.
      double statistic(java.lang.String datasourceName, java.lang.String datasetName, java.lang.String fieldName, StatisticMode statisticMode)
      Calculates statistics on a specified field of a dataset based on a specified statistical mode.
      boolean supportAttachments(java.lang.String datasourceName, java.lang.String datasetName)
      Whether the dataset attachment is enable.
      boolean supportFeatureMetadatas(java.lang.String datasourceName, java.lang.String datasetName)
      Whether this dataset feature supports the metadata info.
      void updateDatasetInfo(java.lang.String datasourceName, java.lang.String datasetName, DatasetInfo newDatasetInfo)
      Updates information about a specified dataset in a given datasource.
      void updateDatasourceInfo(java.lang.String datasourceName, DatasourceInfo newDatasourceInfo)
      Updates the original datasource info with new datasource info.
      EditResult updateFeatures(java.lang.String datasourceName, java.lang.String datasetName, java.util.List<Feature> targetFeatures)
      Updates features in a specified dataset.
      void updateFieldInfos(java.lang.String datasourceName, java.lang.String datasetName, java.util.List<FieldInfo> newFiledInfos)
      Updates the field information in a specified dataset.
      • Methods inherited from class java.lang.Object

        clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • DataImpl

        public DataImpl()
        

        The default constructor.

      • DataImpl

        public DataImpl(DataContext context)
                 throws DataException
        

        Constructs a DataImpl object according to the context of a data service component.

        Parameters:
        context - The context information of a given data service component.
        Throws:
        DataException - A data service component exception thrown when the config parameter is null).
    • Method Detail

      • createDataset

        public boolean createDataset(java.lang.String dataSourceName,
                            DatasetInfo datasetInfo)
                              throws DataException
        

        Creates a new dataset in a specified datasource according to the dataset information.

        Specified by:
        createDataset in interface Data
        Parameters:
        dataSourceName - The list of datasource names.
        datasetInfo - The dataset information.
        Returns:
        true if the dataset is successfully created; false otherwise.
        Throws:
        DataException - A data service component exception.
      • deleteDataset

        public boolean deleteDataset(java.lang.String datasourceName,
                            java.lang.String datasetName)
                              throws DataException
        

        Removes a dataset from a specified datasource according to the dataset information.

        Specified by:
        deleteDataset in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        Returns:
        true if the dataset is successfully deleted; false otherwise.
        Throws:
        DataException - A data service component exception.
      • copyDataset

        public boolean copyDataset(java.lang.String srcDatasourceName,
                          java.lang.String srcDatasetName,
                          java.lang.String destDatasourceName,
                          java.lang.String destDatasetName)
                            throws DataException
        

        Copies a replication of a specified dataset.

        Copies a replication of a specified dataset from specified datasource to target datasource and saves it with a specified name.

        Specified by:
        copyDataset in interface Data
        Parameters:
        srcDatasourceName - The source datasource name.
        srcDatasetName - The source dataset name.
        destDatasourceName - The target datasource name.
        destDatasetName - The target dataset name.
        Returns:
        true if the dataset is successfully copied; false otherwise.
        Throws:
        DataException - A data service component exception.
      • renameDataset

        public boolean renameDataset(java.lang.String datasourceName,
                            java.lang.String oldName,
                            java.lang.String newName)
                              throws DataException
        

        Modifies the name of a specified dataset.

        Specified by:
        renameDataset in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        oldName - The name of the dataset to be modified.
        newName - New name.
        Returns:
        true if the dataset is successfully modified; false otherwise.
        Throws:
        DataException - A data service component exception.
      • containsDataset

        public boolean containsDataset(java.lang.String datasourceName,
                              java.lang.String datasetName)
                                throws DataException
        

        Determines whether a specified datasource contains a specified dataset.

        Specified by:
        containsDataset in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        Returns:
        true if the given datasource contains the specified dataset; false otherwise.
        Throws:
        DataException - A data service component exception.
      • addFeatures

        public EditResult addFeatures(java.lang.String datasourceName,
                             java.lang.String datasetName,
                             java.util.List<Feature> targetFeatures)
                               throws DataException
        

        Adds a set of features of the same type to a specified dataset.

        Every dataset in SuperMap has a type (DatasetType). A dataset can be a point, a line, or a region dataset. The features in a dataset are of the same type with the dataset. For instance, the features stored in a point dataset must be point features. Therefore, a feature added to a dataset must be of the same type with that dataset.

        Specified by:
        addFeatures in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        targetFeatures - The list of features to be added. The features must be of the same type.
        Returns:
        The edited result.
        Throws:
        DataException - A data service component exception.
      • batchAddFeatures

        public void batchAddFeatures(java.lang.String datasourceName,
                            java.lang.String datasetName,
                            java.util.List<Feature> targetFeatures)
                              throws DataException
        

        Adds elements in batch, the performance is higher than the addFeatures interface when adding massive features. But the result doesn't show the detailed failure messages, such as the IDs of the features that are added failed.

        Specified by:
        batchAddFeatures in interface Data
        Parameters:
        datasourceName -
        datasetName -
        targetFeatures -
        Throws:
        DataException
        Since:
        6.1.3
      • deleteFeatures

        public EditResult deleteFeatures(java.lang.String datasourceName,
                                java.lang.String datasetName,
                                int[] ids)
                                  throws DataException
        

        Deletes features from a specified dataset.

        Specified by:
        deleteFeatures in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        ids - The IDs of the features to be deleted.
        Returns:
        The edited result.
        Throws:
        DataException - A data service component exception.
      • deleteFeatures

        public EditResult deleteFeatures(java.lang.String datasourceName,
                                QueryParameter queryParameter)
                                  throws DataException
        
        Description copied from interface: Data

        Specifies the data source to remove the feature via sql.

        Specified by:
        deleteFeatures in interface Data
        Parameters:
        datasourceName - the name of the datasource.
        Returns:
        edit the results.
        Throws:
        DataException - Data service component exception information.
      • updateFeatures

        public EditResult updateFeatures(java.lang.String datasourceName,
                                java.lang.String datasetName,
                                java.util.List<Feature> targetFeatures)
                                  throws DataException
        

        Updates features in a specified dataset.

        targetFeatures is used to set the expected features after update, of which the IDs should be identical with the IDs of the features to be updated. The update process is finding out the feature to be updated with the ID from the targetFeatures first, then updating the source feature with the targetFeature.

        Specified by:
        updateFeatures in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        targetFeatures - The list of new features whose IDs are the same with those of the features to be updated.
        Returns:
        The edited result.
        Throws:
        DataException - A data service component exception.
      • clearFeatures

        public boolean clearFeatures(java.lang.String datasourceName,
                            java.lang.String datasetName)
                              throws DataException
        

        Clears the features in a specified dataset.

        Specified by:
        clearFeatures in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        Returns:
        true if the features are successfully cleared; false otherwise.
        Throws:
        DataException - A data service component exception.
      • getFeature

        public java.util.List<Feature> getFeature(java.lang.String datasourceName,
                                         java.lang.String datasetName,
                                         int[] ids,
                                         java.lang.String[] fields)
                                           throws DataException
        

        Gets features with specified IDs in a specified dataset.

        Specified by:
        getFeature in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        ids - The feature IDs.
        fields - An array of fields to be returned. When the parameter is null, all fields are returned.
        Returns:
        The list of features.
        Throws:
        DataException - A data service component exception.
      • getFeature

        public java.util.List<Feature> getFeature(java.lang.String datasourceName,
                                         java.lang.String datasetName,
                                         Rectangle2D bounds,
                                         java.lang.String[] fields)
                                           throws DataException
        

        Gets the features that fall within a specified space and meet a certain attribute filter condition.

        Specified by:
        getFeature in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        bounds - The specified query bounds.
        fields - The array of fields to be returned. All the fields are returned if this parameter is null.
        Returns:
        The list of features.
        Throws:
        DataException - Data service component exception information.
      • getFeature

        public java.util.List<Feature> getFeature(java.lang.String datasourceName,
                                         java.lang.String datasetName,
                                         Rectangle2D bounds,
                                         java.lang.String attributeFilter,
                                         java.lang.String[] fields)
                                           throws DataException
        

        Gets the features that fall within a specified space and meet a certain attribute filter condition.

        Specified by:
        getFeature in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        bounds - The specified query bounds.
        attributeFilter - The attribute query filter.
        fields - The array of fields to be returned. All the fields are returned if this parameter is null.
        Returns:
        The list of features.
        Throws:
        DataException
      • getFeature

        public java.util.List<Feature> getFeature(java.lang.String datasourceName,
                                         java.lang.String datasetName,
                                         Geometry geometry,
                                         double bufferDistance,
                                         java.lang.String[] fields)
                                           throws DataException
        

        Gets the features that fall within a buffer of a specified geometric object and meet a certain attribute filter condition.

        Specified by:
        getFeature in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        geometry - The geometric object.
        bufferDistance - The buffer distance and the unit is the coordUnit of current dataset.
        fields - An array of fields to be returned. When the parameter is null, all fields are returned.
        Returns:
        The list of features.
        Throws:
        DataException - A data service component exception.
      • getFeature

        public java.util.List<Feature> getFeature(java.lang.String datasourceName,
                                         java.lang.String datasetName,
                                         Geometry geometry,
                                         double bufferDistance,
                                         java.lang.String attributeFilter,
                                         java.lang.String[] fields)
                                           throws DataException
        

        Gets the features that fall within a buffer of a specified geometric object and meet a certain attribute filter condition.

        Specified by:
        getFeature in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        geometry - The geometric object.
        bufferDistance - The buffer distance and the unit is the coordUnit of current dataset.
        attributeFilter - The attribute filter condition. For example, fieldValue < 100, name like '%Hotel%'
        fields - An array of fields to be returned. When the parameter is null, all fields are returned.
        Returns:
        The list of features.
        Throws:
        DataException - A data service component exception.
      • getFeature

        public java.util.List<Feature> getFeature(java.lang.String datasourceName,
                                         java.lang.String datasetName,
                                         Geometry geometry,
                                         SpatialQueryMode spatialQueryMode,
                                         java.lang.String[] fields)
                                           throws DataException
        

        Gets the features that satisfy certain spatial query mode on a specified geometric object.

        Specified by:
        getFeature in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        geometry - The specified Geometric object.
        spatialQueryMode - The spatial query mode.
        fields - An array of fields to be returned. When the parameter is null, all fields are returned.
        Returns:
        The list of features.
        Throws:
        DataException - A data service component exception.
      • getFeature

        public java.util.List<Feature> getFeature(java.lang.String datasourceName,
                                         java.lang.String datasetName,
                                         Geometry geometry,
                                         SpatialQueryMode spatialQueryMode,
                                         java.lang.String attributeFilter,
                                         java.lang.String[] fields)
                                           throws DataException
        

        Gets the features that satisfy certain spatial query mode on a specified geometric object and meet a certain attribute filter condition.

        Specified by:
        getFeature in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        geometry - The geometric object.
        spatialQueryMode - The spatial query mode.
        attributeFilter - Attribute filter condition.
        fields - An array of fields to be returned. When the parameter is null, all fields are returned.
        Returns:
        The list of features.
        Throws:
        DataException - A data service component exception.
      • getFeature

        public java.util.List<Feature> getFeature(java.lang.String datasourceName,
                                         QueryParameter queryParam)
                                           throws DataException
        

        Gets features by a SQL query condition.

        Specified by:
        getFeature in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        queryParam - Query parameter.
        Returns:
        The list of features.
        Throws:
        DataException - A data service component exception.
      • getFeature

        public java.util.List<Feature> getFeature(java.lang.String datasourceName,
                                         QueryParameter queryParam,
                                         int maxFeatures)
                                           throws DataException
        

        Gets features by a SQL query condition.

        Specified by:
        getFeature in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        queryParam - Query parameter.
        maxFeatures - The maximum features to be returned.
        Returns:
        The list of features.
        Throws:
        DataException - A data service component exception.
      • getDatasourceInfos

        public java.util.List<DatasourceInfo> getDatasourceInfos()
                                                          throws DataException
        

        Gets information about all the datasources corresponding to the current data service component.

        Specified by:
        getDatasourceInfos in interface Data
        Returns:
        The list of datasource information.
        Throws:
        DataException - A data service component exception.
      • getDatasourceInfo

        public DatasourceInfo getDatasourceInfo(java.lang.String datasourceName)
                                         throws DataException
        

        Gets information about a specified datasource.

        Specified by:
        getDatasourceInfo in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        Returns:
        Datasource info.
        Throws:
        DataException - A data service component exception.
      • updateDatasourceInfo

        public void updateDatasourceInfo(java.lang.String datasourceName,
                                DatasourceInfo newDatasourceInfo)
                                  throws DataException
        

        Updates the original datasource info with new datasource info.

        Specified by:
        updateDatasourceInfo in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        newDatasourceInfo - The new datasource info.
        Throws:
        DataException - A data service component exception.
      • getDatasetInfos

        public java.util.List<DatasetInfo> getDatasetInfos(java.lang.String datasourceName)
                                                    throws DataException
        

        Gets information about all the datasets in a specified datasource.

        Specified by:
        getDatasetInfos in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        Returns:
        The list of dataset information.
        Throws:
        DataException - A data service component exception.
      • getDatasetInfo

        public DatasetInfo getDatasetInfo(java.lang.String datasourceName,
                                 java.lang.String datasetName)
                                   throws DataException
        

        Gets the information of a specified dataset in a given datasource.

        Specified by:
        getDatasetInfo in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        Returns:
        The dataset information.
        Throws:
        DataException - A data service component exception.
      • updateDatasetInfo

        public void updateDatasetInfo(java.lang.String datasourceName,
                             java.lang.String datasetName,
                             DatasetInfo newDatasetInfo)
                               throws DataException
        

        Updates information about a specified dataset in a given datasource.

        Specified by:
        updateDatasetInfo in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The name of the dataset to be updated.
        newDatasetInfo - The dataset information.
        Throws:
        DataException - A data service component exception.
      • getDomainInfos

        public java.util.List<DomainInfo> getDomainInfos(java.lang.String datasourceName,
                                                java.lang.String datasetName)
                                                  throws DataException
        

        The new dataset information.

        Specified by:
        getDomainInfos in interface Data
        Parameters:
        datasourceName - The datasource name.
        datasetName - The dataset name.
        Returns:
        Domain information collection.
        Throws:
        DataException
      • getFieldInfos

        public java.util.List<FieldInfo> getFieldInfos(java.lang.String datasourceName,
                                              java.lang.String datasetName)
                                                throws DataException
        

        Get all the field info of the specified dataset.

        Specified by:
        getFieldInfos in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        Returns:
        Field info list.
        Throws:
        DataException - A data service component exception.
      • getGridValue

        public GridValue getGridValue(java.lang.String datasourceName,
                             java.lang.String datasetName,
                             Point2D point2d)
                               throws DataException
        

        Gets the grid value of the specified coordinate in a grid dataset.

        Specified by:
        getGridValue in interface Data
        Parameters:
        datasoruceName -
        datasetName -
        Returns:
        Throws:
        DataException
        Since:
        8.1.1
      • getGridValues

        public GridValues getGridValues(java.lang.String datasourceName,
                               java.lang.String datasetName,
                               Geometry geometry)
                                 throws DataException
        
        Gets the grid value matrix within a specified rectangle.
        Specified by:
        getGridValues in interface Data
        Parameters:
        datasourceName -
        datasetName -
        bounds -
        Returns:
        Throws:
        DataException
      • getImageValue

        public ImageValue getImageValue(java.lang.String datasourceName,
                               java.lang.String datasetName,
                               Point2D point2d)
                                 throws DataException
        

        Gets the pixel value of the specified coordinate in a image dataset.

        Specified by:
        getImageValue in interface Data
        Parameters:
        datasoruceName -
        datasetName -
        Returns:
        Throws:
        DataException
        Since:
        8.1.1
      • getImageValues

        public ImageValues getImageValues(java.lang.String datasourceName,
                                 java.lang.String datasetName,
                                 Geometry geometry)
                                   throws DataException
        
        Gets the grid value matrix within a specified rectangle.
        Specified by:
        getImageValues in interface Data
        Parameters:
        datasourceName -
        datasetName -
        bounds -
        Returns:
        Throws:
        DataException
      • updateFieldInfos

        public void updateFieldInfos(java.lang.String datasourceName,
                            java.lang.String datasetName,
                            java.util.List<FieldInfo> newFiledInfos)
                              throws DataException
        

        Updates the field information in a specified dataset.

        A field can be added, deleted, or modified by using this method.All the fields (except the SuperMap system fields) in a dataset are replaced with new fields.

        If SuperMap data are used, the alias of the SuperMap system fields cannot be updated.

        Specified by:
        updateFieldInfos in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        newFiledInfos - The new field information. If SuperMap data are used, the SuperMap system fields cannot be included in this information list.
        Throws:
        DataException - A data service component exception.
      • statistic

        public double statistic(java.lang.String datasourceName,
                       java.lang.String datasetName,
                       int fieldIndex,
                       StatisticMode statisticMode)
                         throws DataException
        

        Calculates statistics on a specified field of a dataset based on a specified statistical mode.

        Specified by:
        statistic in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        fieldIndex - The field index.
        statisticMode - The statistical mode.
        Returns:
        The statistic result.
        Throws:
        DataException - A data service component exception.
      • statistic

        public double statistic(java.lang.String datasourceName,
                       java.lang.String datasetName,
                       java.lang.String fieldName,
                       StatisticMode statisticMode)
                         throws DataException
        

        Calculates statistics on a specified field of a dataset based on a specified statistical mode.

        Specified by:
        statistic in interface Data
        Parameters:
        datasourceName - The list of datasource names.
        datasetName - The dataset name.
        fieldName - The name of the specified field.
        statisticMode - The statistical mode.
        Returns:
        The statistic result.
        Throws:
        DataException - A data service component exception.
      • dispose

        public void dispose()
        

        Releases the resources used by this data service component.

        Specified by:
        dispose in interface Disposable
      • getAttachement

        public Attachment getAttachement(java.lang.String datasourceName,
                                java.lang.String datasetName,
                                int featureId,
                                int id)
        
        Description copied from interface: AttachmentAndMetadata

        Gets the attachment data according to the attachment ID.

        Specified by:
        getAttachement in interface AttachmentAndMetadata
        id - Attachment ID
        Returns:
      • deleteAttachment

        public boolean deleteAttachment(java.lang.String datasourceName,
                               java.lang.String datasetName,
                               int featureId,
                               int id)
        
        Description copied from interface: AttachmentAndMetadata

        Delete the attachment related to feature.

        Specified by:
        deleteAttachment in interface AttachmentAndMetadata
        Returns:
      • supportFeatureMetadatas

        public boolean supportFeatureMetadatas(java.lang.String datasourceName,
                                      java.lang.String datasetName)
        
        Description copied from interface: AttachmentAndMetadata

        Whether this dataset feature supports the metadata info.

        Specified by:
        supportFeatureMetadatas in interface AttachmentAndMetadata
        Returns:
      • finalize

        protected void finalize()
                         throws java.lang.Throwable
        

        Releases the resources used by this data service component.

        Overrides:
        finalize in class java.lang.Object
        Throws:
        java.lang.Throwable
      • getDatasetNames

        public java.util.List<java.lang.String> getDatasetNames(java.lang.String datasourceName)
                                                         throws DataException
        
        Description copied from interface: Data

        Gets all dataset names for the current data source.

        Specified by:
        getDatasetNames in interface Data
        Parameters:
        datasourceName - the name of the datasource.
        Returns:
        A list of dataset names.
        Throws:
        DataException
      • getFeature

        public java.util.List<Feature> getFeature(java.lang.String datasourceName,
                                         java.lang.String datasetName,
                                         int[] ids,
                                         java.lang.String[] fields,
                                         int fromIndex,
                                         int toIndex)
                                           throws DataException
        
        Description copied from interface: Data

        Gets the feature in the specified data set according to the specified feature ID in the way of supporting paging.

        Specified by:
        getFeature in interface Data
        Parameters:
        datasourceName - the name of the datasource.
        datasetName - the dataset name.
        ids - Feature ID.
        fields - An array of fields to be returned. When the parameter is null, all fields are returned.
        fromIndex - The minimum index number for the result of the paging
        toIndex - The maximum index number for the result of the paging
        Returns:
        feature list.
        Throws:
        DataException - Data service component exception information.
      • isDisableQueryCache

        public boolean isDisableQueryCache()
        
        Description copied from interface: Data
        Whether to enable caching when performing data query
        Specified by:
        isDisableQueryCache in interface Data
        Returns: