Package datahub.client.patch
Class AbstractMultiFieldPatchBuilder<T extends AbstractMultiFieldPatchBuilder<T>>
- java.lang.Object
-
- datahub.client.patch.AbstractMultiFieldPatchBuilder<T>
-
- Direct Known Subclasses:
DataFlowInfoPatchBuilder
,DataJobInfoPatchBuilder
,DatasetPropertiesPatchBuilder
,EditableSchemaMetadataPatchBuilder
,GlobalTagsPatchBuilder
,GlossaryTermsPatchBuilder
,OwnershipPatchBuilder
,UpstreamLineagePatchBuilder
public abstract class AbstractMultiFieldPatchBuilder<T extends AbstractMultiFieldPatchBuilder<T>> extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
OP_KEY
static java.lang.String
PATH_KEY
protected java.util.List<org.apache.commons.lang3.tuple.ImmutableTriple<java.lang.String,java.lang.String,com.fasterxml.jackson.databind.JsonNode>>
pathValues
protected com.linkedin.common.urn.Urn
targetEntityUrn
static java.lang.String
VALUE_KEY
-
Constructor Summary
Constructors Constructor Description AbstractMultiFieldPatchBuilder()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description com.linkedin.mxe.MetadataChangeProposal
build()
Builder methodprotected com.linkedin.mxe.GenericAspect
buildPatch()
Overrides basic behavior to construct multiple patches based on propertiesprotected abstract java.lang.String
getAspectName()
The aspect name associated with this builderprotected abstract java.lang.String
getEntityType()
Returns the String representation of the Entity type associated with this aspectprotected java.util.List<org.apache.commons.lang3.tuple.ImmutableTriple<java.lang.String,java.lang.String,com.fasterxml.jackson.databind.JsonNode>>
getPathValues()
Constructs a list of Op, Path, Value triples to create as patches.T
urn(com.linkedin.common.urn.Urn urn)
Sets the target entity urn to be updated by this patch
-
-
-
Field Detail
-
OP_KEY
public static final java.lang.String OP_KEY
- See Also:
- Constant Field Values
-
VALUE_KEY
public static final java.lang.String VALUE_KEY
- See Also:
- Constant Field Values
-
PATH_KEY
public static final java.lang.String PATH_KEY
- See Also:
- Constant Field Values
-
pathValues
protected java.util.List<org.apache.commons.lang3.tuple.ImmutableTriple<java.lang.String,java.lang.String,com.fasterxml.jackson.databind.JsonNode>> pathValues
-
targetEntityUrn
protected com.linkedin.common.urn.Urn targetEntityUrn
-
-
Method Detail
-
build
public com.linkedin.mxe.MetadataChangeProposal build()
Builder method- Returns:
- a
MetadataChangeProposal
constructed from the builder's properties
-
urn
public T urn(com.linkedin.common.urn.Urn urn)
Sets the target entity urn to be updated by this patch- Parameters:
urn
- The target entity whose aspect is to be patched by this update- Returns:
- this PatchBuilder subtype's instance
-
getAspectName
protected abstract java.lang.String getAspectName()
The aspect name associated with this builder- Returns:
- aspect name
-
getEntityType
protected abstract java.lang.String getEntityType()
Returns the String representation of the Entity type associated with this aspect- Returns:
- entity type name
-
buildPatch
protected com.linkedin.mxe.GenericAspect buildPatch()
Overrides basic behavior to construct multiple patches based on properties- Returns:
- a JsonPatch wrapped by GenericAspect
-
getPathValues
protected java.util.List<org.apache.commons.lang3.tuple.ImmutableTriple<java.lang.String,java.lang.String,com.fasterxml.jackson.databind.JsonNode>> getPathValues()
Constructs a list of Op, Path, Value triples to create as patches. Not idempotent and should not be called more than once- Returns:
- list of patch precursor triples
-
-