Package com.atlan.samples.loaders.models
Class ContainerDetails
- java.lang.Object
-
- com.atlan.samples.loaders.models.AssetDetails
-
- com.atlan.samples.loaders.models.ContainerDetails
-
public class ContainerDetails extends AssetDetails
Utility class for capturing the full details provided about a table.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classContainerDetails.ContainerDetailsBuilder<C extends ContainerDetails,B extends ContainerDetails.ContainerDetailsBuilder<C,B>>-
Nested classes/interfaces inherited from class com.atlan.samples.loaders.models.AssetDetails
AssetDetails.AssetDetailsBuilder<C extends AssetDetails,B extends AssetDetails.AssetDetailsBuilder<C,B>>
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringCOL_CONTAINERstatic java.lang.StringCOL_CONTAINER_TYPE
-
Constructor Summary
Constructors Modifier Constructor Description protectedContainerDetails(ContainerDetails.ContainerDetailsBuilder<?,?> b)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ContainerDetails.ContainerDetailsBuilder<?,?>builder()protected booleancanEqual(java.lang.Object other)booleanequals(java.lang.Object o)static ContainerDetailsgetFromRow(java.util.Map<ConnectionDetails,java.lang.String> connectionCache, java.util.Map<java.lang.String,java.lang.String> row, java.lang.String delim)Build up details about the container on the provided row.java.lang.StringgetIdentity()Retrieve the unique identity of this asset for deduplication across rows.java.lang.StringgetName()static java.lang.StringgetQualifiedName(java.util.Map<ConnectionDetails,java.lang.String> connectionCache, java.util.Map<java.lang.String,java.lang.String> row)Construct a container's qualifiedName from the row of data and cache of connections.java.lang.StringgetSchemaQualifiedName()java.lang.StringgetType()inthashCode()java.lang.StringtoString()static java.util.Set<java.lang.String>upsert(java.util.Map<java.lang.String,ContainerDetails> containers, int batchSize, boolean updateOnly)Create containers in bulk, if they do not exist, or update them if they do (idempotent).-
Methods inherited from class com.atlan.samples.loaders.models.AssetDetails
appendAtlanTags, getAnnouncementMessage, getAnnouncementTitle, getAnnouncementType, getAtlanTags, getBoolean, getCertificate, getCertificateStatusMessage, getDescription, getFromRow, getMissingFields, getMultiValuedList, getOwnerGroups, getOwnerUsers, getRequiredEmptyFields, isStub, selectivelyUpdateCustomMetadata
-
-
-
-
Field Detail
-
COL_CONTAINER
public static final java.lang.String COL_CONTAINER
- See Also:
- Constant Field Values
-
COL_CONTAINER_TYPE
public static final java.lang.String COL_CONTAINER_TYPE
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ContainerDetails
protected ContainerDetails(ContainerDetails.ContainerDetailsBuilder<?,?> b)
-
-
Method Detail
-
getIdentity
public java.lang.String getIdentity()
Retrieve the unique identity of this asset for deduplication across rows.- Specified by:
getIdentityin classAssetDetails- Returns:
- String giving the unique identity of the asset
-
getQualifiedName
public static java.lang.String getQualifiedName(java.util.Map<ConnectionDetails,java.lang.String> connectionCache, java.util.Map<java.lang.String,java.lang.String> row)
Construct a container's qualifiedName from the row of data and cache of connections.- Parameters:
connectionCache- cache of connectionsrow- of data- Returns:
- the qualifiedName for the container on that row of data
-
getFromRow
public static ContainerDetails getFromRow(java.util.Map<ConnectionDetails,java.lang.String> connectionCache, java.util.Map<java.lang.String,java.lang.String> row, java.lang.String delim)
Build up details about the container on the provided row.- Parameters:
connectionCache- a cache of connections that have first been resolved across the spreadsheetrow- a row of data from the spreadsheet, as a map from column name to valuedelim- delimiter used in cells that can contain multiple values- Returns:
- the container details for that row
-
upsert
public static java.util.Set<java.lang.String> upsert(java.util.Map<java.lang.String,ContainerDetails> containers, int batchSize, boolean updateOnly)
Create containers in bulk, if they do not exist, or update them if they do (idempotent).- Parameters:
containers- the set of containers to ensure existbatchSize- maximum number of containers to create per batchupdateOnly- if true, only attempt to update existing assets, otherwise allow assets to be created as well- Returns:
- qualifiedNames of all parent schemas in which assets were created or updated
-
builder
public static ContainerDetails.ContainerDetailsBuilder<?,?> builder()
-
getSchemaQualifiedName
public java.lang.String getSchemaQualifiedName()
-
getName
public java.lang.String getName()
-
getType
public java.lang.String getType()
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classAssetDetails
-
canEqual
protected boolean canEqual(java.lang.Object other)
- Overrides:
canEqualin classAssetDetails
-
hashCode
public int hashCode()
- Overrides:
hashCodein classAssetDetails
-
toString
public java.lang.String toString()
- Overrides:
toStringin classAssetDetails
-
-