Class DiscoveryAssetCatalogStore
- java.lang.Object
-
- org.odpi.openmetadata.frameworks.discovery.DiscoveryAssetCatalogStore
-
public abstract class DiscoveryAssetCatalogStore extends Object
DiscoveryAssetCatalogStore provides access to the asset catalog to enable it to step through the assets available in the asset catalog.
-
-
Field Summary
Fields Modifier and Type Field Description protected intmaxPageSizeprotected StringuserId
-
Constructor Summary
Constructors Constructor Description DiscoveryAssetCatalogStore(String userId, int maxPageSize)Constructor sets the max page size which is used by the caller to ensure they do not ask for too many assets at once.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract List<String>findAssets(String searchString, int startFrom, int pageSize)Return the list of assets that have the search string somewhere in their properties.abstract List<String>getAssets(int startFrom, int pageSize)Return the next set of assets to process.abstract List<String>getAssetsByEndpoint(String networkAddress, int startFrom, int pageSize)Return the list of assets that have the same endpoint address.abstract List<String>getAssetsByName(String name, int startFrom, int pageSize)Return the list of matching assets that have the supplied name as either the qualified name or display name.abstract List<String>getAssetsByQualifiedName(String name, int startFrom, int pageSize)Return the assets with the same qualified name.intgetMaxPageSize()Return the maximum number of assets that can be returned by getAssets().
-
-
-
Field Detail
-
userId
protected String userId
-
maxPageSize
protected int maxPageSize
-
-
Constructor Detail
-
DiscoveryAssetCatalogStore
public DiscoveryAssetCatalogStore(String userId, int maxPageSize)
Constructor sets the max page size which is used by the caller to ensure they do not ask for too many assets at once.- Parameters:
userId- calling usermaxPageSize- maximum number of assets that can be returned on a single request.
-
-
Method Detail
-
getMaxPageSize
public int getMaxPageSize()
Return the maximum number of assets that can be returned by getAssets().- Returns:
- integer
-
getAssets
public abstract List<String> getAssets(int startFrom, int pageSize) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Return the next set of assets to process.- Parameters:
startFrom- starting point of the querypageSize- maximum number of results to return- Returns:
- list of unique identifiers for matching assets
- Throws:
InvalidParameterException- one of the parameters is not recognizedUserNotAuthorizedException- the user is not authorized to access the asset and/or connectionPropertyServerException- there was a problem in the store whether the asset/connection properties are kept.
-
getAssetsByQualifiedName
public abstract List<String> getAssetsByQualifiedName(String name, int startFrom, int pageSize) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Return the assets with the same qualified name. If all is well there should be only one returned.- Parameters:
name- the qualified name to query onstartFrom- place to start in querypageSize- number of results to return- Returns:
- list of unique identifiers for matching assets
- Throws:
InvalidParameterException- one of the parameters is not recognizedUserNotAuthorizedException- the user is not authorized to access the asset and/or connectionPropertyServerException- there was a problem in the store whether the asset/connection properties are kept.
-
getAssetsByName
public abstract List<String> getAssetsByName(String name, int startFrom, int pageSize) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Return the list of matching assets that have the supplied name as either the qualified name or display name. This is an exact match retrieval.- Parameters:
name- name to query forstartFrom- place to start in querypageSize- number of results to return- Returns:
- list of unique identifiers for matching assets
- Throws:
InvalidParameterException- one of the parameters is not recognizedUserNotAuthorizedException- the user is not authorized to access the asset and/or connectionPropertyServerException- there was a problem in the store whether the asset/connection properties are kept.
-
findAssets
public abstract List<String> findAssets(String searchString, int startFrom, int pageSize) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Return the list of assets that have the search string somewhere in their properties. The search string may be a regular expression.- Parameters:
searchString- value to search forstartFrom- place to start in querypageSize- number of results to return- Returns:
- list of unique identifiers for matching assets
- Throws:
InvalidParameterException- one of the parameters is not recognizedUserNotAuthorizedException- the user is not authorized to access the asset and/or connectionPropertyServerException- there was a problem in the store whether the asset/connection properties are kept.
-
getAssetsByEndpoint
public abstract List<String> getAssetsByEndpoint(String networkAddress, int startFrom, int pageSize) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Return the list of assets that have the same endpoint address.- Parameters:
networkAddress- address to query onstartFrom- place to start in querypageSize- number of results to return- Returns:
- list of unique identifiers for matching assets
- Throws:
InvalidParameterException- one of the parameters is not recognizedUserNotAuthorizedException- the user is not authorized to access the asset and/or connectionPropertyServerException- there was a problem in the store whether the asset/connection properties are kept.
-
-