Class SASCatalogGuid
- java.lang.Object
-
- org.odpi.openmetadata.connector.sas.repository.connector.model.SASCatalogGuid
-
public class SASCatalogGuid extends java.lang.ObjectCaptures the meaning and translation of the various components of an SAS GUID. This is necessary to cover those scenarios where an instance is generated for SAS, because what is a single instance in SAS is actually represented as multiple instances in OMRS. As a result, the GUIDs for these generated entities will require some prefixing to allow them to be properly handled.
-
-
Constructor Summary
Constructors Constructor Description SASCatalogGuid(java.lang.String SASCatalogGuid, java.lang.String prefix)Create a new SAS GUID that has a prefix (for an OMRS instance type that does not actually exist in Apache SAS, but is generated from another instance type in SAS)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object obj)static SASCatalogGuidfromGuid(java.lang.String guidToConvert)Attempt to create a new SAS GUID from the provided GUID.java.lang.StringgetGeneratedPrefix()Retrieve the generated prefix component of this SAS GUID, if it is for a generated instance (or null if the instance is not generated).java.lang.StringgetSASCatalogGuid()Retrieve the SAS GUID.inthashCode()booleanisGeneratedInstanceGuid()Indicates whether this SAS GUID represents a generated instance (true) or not (false).java.lang.StringtoString()Turn this SAS GUID into a unique String representation of the GUID.
-
-
-
Constructor Detail
-
SASCatalogGuid
public SASCatalogGuid(java.lang.String SASCatalogGuid, java.lang.String prefix)Create a new SAS GUID that has a prefix (for an OMRS instance type that does not actually exist in Apache SAS, but is generated from another instance type in SAS)- Parameters:
SASCatalogGuid- the GUID of the SAS assetprefix- the prefix to use to uniquely identify this generated instance's GUID
-
-
Method Detail
-
toString
public java.lang.String toString()
Turn this SAS GUID into a unique String representation of the GUID. The string representation will be something like the following: database_schema@5e74232d-92df-4b81-a401-b100dbfea73a:RDBST!6662c0f2.ee6a64fe.o1h6eveh1.gbvjvq0.ols3j6.0oadmdn8gknhjvmojr3pt- Overrides:
toStringin classjava.lang.Object- Returns:
- String
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
fromGuid
public static SASCatalogGuid fromGuid(java.lang.String guidToConvert)
Attempt to create a new SAS GUID from the provided GUID.- Parameters:
guidToConvert- the SAS GUID representation of the provided GUID, or null if it does not appear to be a valid SAS GUID- Returns:
- SASCatalogGuid
-
getGeneratedPrefix
public java.lang.String getGeneratedPrefix()
Retrieve the generated prefix component of this SAS GUID, if it is for a generated instance (or null if the instance is not generated).- Returns:
- String
-
isGeneratedInstanceGuid
public boolean isGeneratedInstanceGuid()
Indicates whether this SAS GUID represents a generated instance (true) or not (false).- Returns:
- boolean
-
getSASCatalogGuid
public java.lang.String getSASCatalogGuid()
Retrieve the SAS GUID.- Returns:
- String
-
-