Package com.linecorp.centraldogma.common
Class MergedEntry<T>
java.lang.Object
com.linecorp.centraldogma.common.MergedEntry<T>
- Type Parameters:
T
- the content type. It isJsonNode
because only JSON merge is currently supported.
- All Implemented Interfaces:
ContentHolder<T>
A merged entry in a repository.
-
Method Summary
Modifier and TypeMethodDescriptioncontent()
Returns the content.Returns the prettified textual representation of the specified content.Returns the textual representation of the specified content.boolean
int
hashCode()
static <T> MergedEntry
<T> Returns a newly-createdMergedEntry
.static <T> MergedEntry
<T> Returns a newly-createdMergedEntry
.paths()
Returns the paths which participated to compose theMergedEntry
.revision()
Returns theRevision
of thisMergedEntry
.toString()
type()
Returns theEntryType
of the content.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.linecorp.centraldogma.common.ContentHolder
contentAsJson, contentAsJson
-
Method Details
-
of
Returns a newly-createdMergedEntry
.- Type Parameters:
T
- the content type. It isJsonNode
because only JSON merge is currently supported.- Parameters:
revision
- the revision of theMergedEntry
type
- the type of theMergedEntry
content
- the content of theMergedEntry
paths
- the paths which participated to compose theMergedEntry
-
of
public static <T> MergedEntry<T> of(Revision revision, EntryType type, T content, Iterable<String> paths) Returns a newly-createdMergedEntry
.- Type Parameters:
T
- the content type. It isJsonNode
because only JSON merge is currently supported.- Parameters:
revision
- the revision of theMergedEntry
type
- the type of theMergedEntry
content
- the content of theMergedEntry
paths
- the paths which participated to compose theMergedEntry
-
revision
Returns theRevision
of thisMergedEntry
. -
type
Description copied from interface:ContentHolder
Returns theEntryType
of the content.- Specified by:
type
in interfaceContentHolder<T>
-
content
Description copied from interface:ContentHolder
Returns the content.- Specified by:
content
in interfaceContentHolder<T>
-
paths
Returns the paths which participated to compose theMergedEntry
. -
contentAsText
Description copied from interface:ContentHolder
Returns the textual representation of the specified content.- Specified by:
contentAsText
in interfaceContentHolder<T>
-
contentAsPrettyText
Description copied from interface:ContentHolder
Returns the prettified textual representation of the specified content. Only aTreeNode
is prettified currently.- Specified by:
contentAsPrettyText
in interfaceContentHolder<T>
-
hashCode
public int hashCode() -
equals
-
toString
-