Class AssetExternalIdentifiers
- java.lang.Object
-
- org.odpi.openmetadata.frameworks.connectors.properties.AssetPropertyElementBase
-
- org.odpi.openmetadata.frameworks.connectors.properties.AssetPropertyBase
-
- org.odpi.openmetadata.frameworks.connectors.properties.AssetPropertyIteratorBase
-
- org.odpi.openmetadata.frameworks.connectors.properties.AssetExternalIdentifiers
-
- All Implemented Interfaces:
Serializable,Iterator<AssetExternalIdentifier>
public abstract class AssetExternalIdentifiers extends AssetPropertyIteratorBase implements Iterator<AssetExternalIdentifier>
ExternalIdentifiers supports an iterator over a list of external identifiers. Callers can use it to step through the list just once. If they want to parse the list again, they could use the copy/clone constructor to create a new iterator.- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class org.odpi.openmetadata.frameworks.connectors.properties.AssetPropertyIteratorBase
pagingIterator
-
Fields inherited from class org.odpi.openmetadata.frameworks.connectors.properties.AssetPropertyBase
parentAsset
-
-
Constructor Summary
Constructors Constructor Description AssetExternalIdentifiers(AssetDescriptor parentAsset, int totalElementCount, int maxCacheSize)Typical Constructor creates an iterator with the supplied list of elements.AssetExternalIdentifiers(AssetDescriptor parentAsset, AssetExternalIdentifiers template)Copy/clone constructor.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected AssetPropertyBasecloneElement(AssetDescriptor parentAsset, AssetPropertyBase template)Provides a concrete implementation of cloneElement for the specific iterator type.protected abstract AssetExternalIdentifierscloneIterator(AssetDescriptor parentAsset)Clones this iterator.booleanhasNext()The iterator can only be used once to step through the elements.AssetExternalIdentifiernext()Return the next element in the iteration.voidremove()Remove the current element in the iterator.StringtoString()Standard toString method.-
Methods inherited from class org.odpi.openmetadata.frameworks.connectors.properties.AssetPropertyIteratorBase
getCachedList, getElementCount
-
Methods inherited from class org.odpi.openmetadata.frameworks.connectors.properties.AssetPropertyBase
equals, getParentAsset, getParentAssetName, getParentAssetTypeName, hashCode
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Iterator
forEachRemaining
-
-
-
-
Constructor Detail
-
AssetExternalIdentifiers
public AssetExternalIdentifiers(AssetDescriptor parentAsset, int totalElementCount, int maxCacheSize)
Typical Constructor creates an iterator with the supplied list of elements.- Parameters:
parentAsset- descriptor of parent assettotalElementCount- the total number of elements to process. A negative value is converted to 0.maxCacheSize- maximum number of elements that should be retrieved from the property server and cached in the element list at any one time. If a number less than one is supplied, 1 is used.
-
AssetExternalIdentifiers
public AssetExternalIdentifiers(AssetDescriptor parentAsset, AssetExternalIdentifiers template)
Copy/clone constructor. Used to reset iterator element pointer to 0;- Parameters:
parentAsset- descriptor of parent assettemplate- type-specific iterator to copy; null to create an empty iterator
-
-
Method Detail
-
cloneElement
protected AssetPropertyBase cloneElement(AssetDescriptor parentAsset, AssetPropertyBase template)
Provides a concrete implementation of cloneElement for the specific iterator type.- Specified by:
cloneElementin classAssetPropertyIteratorBase- Parameters:
parentAsset- descriptor of parent assettemplate- object to clone- Returns:
- new cloned object.
-
cloneIterator
protected abstract AssetExternalIdentifiers cloneIterator(AssetDescriptor parentAsset)
Clones this iterator.- Parameters:
parentAsset- descriptor of parent asset- Returns:
- new cloned object.
-
hasNext
public boolean hasNext()
The iterator can only be used once to step through the elements. This method returns a boolean to indicate if it has got to the end of the list yet.- Specified by:
hasNextin interfaceIterator<AssetExternalIdentifier>- Returns:
- boolean indicating whether there are more elements.
-
next
public AssetExternalIdentifier next()
Return the next element in the iteration.- Specified by:
nextin interfaceIterator<AssetExternalIdentifier>- Returns:
- ExternalIdentifier next element object that has been cloned.
-
remove
public void remove()
Remove the current element in the iterator. (Null implementation since this iterator works off of cached elements from the property (metadata) server.)- Specified by:
removein interfaceIterator<AssetExternalIdentifier>
-
-