Interface ClassificationApi
public interface ClassificationApi
-
Method Summary
Modifier and TypeMethodDescriptionAdds newClassification
.Changes givenClassification
.Job
classificationJob
(ClassifyRequest classifyRequest) Deprecated.Job
Deprecated.classifyAsset
(UUID id) Starts a job that classifies assets by external service based on sample data.classifyAssets
(ClassifyRequest classifyRequest) Starts a job that classifies assets by external service based on sample data.PagedResponse
<Classification> Finds all theClassification
s matching given search criteria.getClassification
(UUID classificationId) Finds theClassification
with given id.getClassifications
(GetDataClassesRequestParams requestParams) Finds all theClassification
s with given ids.mergeClassifications
(String targetClassificationName, List<UUID> classificationIds) Searches for all the relations between classifications mentioned in classificationIds and changes the assets to be related to targetClassification instead.void
removeClassification
(UUID classificationId) RemovesClassification
with given id.void
removeClassifications
(List<UUID> classificationsIds) Removes allClassification
s with given ids.
-
Method Details
-
findClassifications
Finds all theClassification
s matching given search criteria.- Parameters:
request
- search criteria specifying what classifications to search for- Returns:
- classifications matching given criteria.
-
getClassification
Finds theClassification
with given id.- Parameters:
classificationId
- id of classification- Returns:
- classification with given id.
-
getClassifications
Finds all theClassification
s with given ids.- Parameters:
requestParams
- request object used to filter classifications- Returns:
- classifications with given ids.
-
addClassification
Adds newClassification
.- Parameters:
request
- parameters to create newClassification
- Returns:
- newly created
Classification
-
changeClassification
Changes givenClassification
.- Parameters:
request
- parameters to changeClassification
- Returns:
- changed
Classification
or null if couldn't fulfill the request
-
removeClassification
RemovesClassification
with given id.WARNING: This will also remove all ClassificationMatches that are joined with this Classification!
- Parameters:
classificationId
- ID ofClassification
to remove
-
removeClassifications
Removes allClassification
s with given ids.WARNING: This will also remove all ClassificationMatches that are joined with these Classifications!
- Parameters:
classificationsIds
- IDs ofClassification
s to remove
-
classify
Deprecated.Starts a job that classifies assets by external service based on sample data. The assets that can be classified must be of type : Column, Table, Schema or Data Set. In all cases columns are the ones being classified (all columns related to given assets).- Parameters:
id
- UUID of asset- Returns:
- started job
-
classifyAsset
Starts a job that classifies assets by external service based on sample data. The assets that can be classified must be of type : Column, Table, Schema or Data Set. In all cases columns are the ones being classified (all columns related to given assets).- Parameters:
id
- UUID of asset- Returns:
- UUID of started job
-
classificationJob
Deprecated.Starts a job that classifies assets by external service based on sample data. The assets that can be classified must be of type : Column, Table, Schema or Data Set. In all cases columns are the ones being classified (all columns related to given assets).- Parameters:
classifyRequest
- request containing data of assets to classify- Returns:
- classification job that is running the classification process.
- Throws:
ApiIllegalArgumentException
- when no assetIds provided
-
classifyAssets
Starts a job that classifies assets by external service based on sample data. The assets that can be classified must be of type : Column, Table, Schema or Data Set. In all cases columns are the ones being classified (all columns related to given assets).- Parameters:
classifyRequest
- request containing data of assets to classify- Returns:
- classification job that is running the classification process.
- Throws:
ApiIllegalArgumentException
- when no assetIds provided
-
mergeClassifications
List<ClassificationMatch> mergeClassifications(String targetClassificationName, List<UUID> classificationIds) Searches for all the relations between classifications mentioned in classificationIds and changes the assets to be related to targetClassification instead. After that, it removes all the classes from classificationIds list. Only UserDefinedClassifications can be part of classifications which are going to be merged. It is related to the fact that CollibrainClassification cannot be deleted.- Parameters:
targetClassificationName
- - the name of the target classification, which all the assets will be related to. If classification does not exist yet, it will be created. Can be either UserDefined or Collibrain.classificationIds
- - the list of the classifications which will be merged into target classification and removed. Only UserDefined classifications are allowed.- Returns:
- The list of all the ClassificationMatch objects which are assigned to the target classification of the merge.
-