Package com.vladsch.flexmark.util.ast
Class NodeRepository<T>
- java.lang.Object
-
- com.vladsch.flexmark.util.ast.NodeRepository<T>
-
- All Implemented Interfaces:
java.util.Map<java.lang.String,T>
- Direct Known Subclasses:
AbbreviationRepository
,EnumeratedReferenceRepository
,FootnoteRepository
,MacroDefinitionRepository
,ReferenceRepository
,ZzzzzzRepository
public abstract class NodeRepository<T> extends java.lang.Object implements java.util.Map<java.lang.String,T>
-
-
Constructor Summary
Constructors Constructor Description NodeRepository(@Nullable KeepType keepType)
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description void
clear()
boolean
containsKey(@NotNull java.lang.Object o)
boolean
containsValue(java.lang.Object o)
@NotNull java.util.Set<java.util.Map.Entry<java.lang.String,T>>
entrySet()
boolean
equals(java.lang.Object o)
T
get(@NotNull java.lang.Object o)
abstract @NotNull DataKey<? extends NodeRepository<T>>
getDataKey()
T
getFromRaw(@NotNull java.lang.CharSequence rawKey)
abstract @NotNull DataKey<KeepType>
getKeepDataKey()
abstract @NotNull java.util.Set<T>
getReferencedElements(Node parent)
@NotNull java.util.Collection<T>
getValues()
int
hashCode()
boolean
isEmpty()
@NotNull java.util.Set<java.lang.String>
keySet()
@NotNull java.lang.String
normalizeKey(@NotNull java.lang.CharSequence key)
T
put(@NotNull java.lang.String s, T t)
void
putAll(@NotNull java.util.Map<? extends java.lang.String,? extends T> map)
T
putRawKey(@NotNull java.lang.CharSequence key, T t)
T
remove(@NotNull java.lang.Object o)
int
size()
static <T> boolean
transferReferences(@NotNull NodeRepository<T> destination, @NotNull NodeRepository<T> included, boolean onlyIfUndefined, @Nullable java.util.Map<java.lang.String,java.lang.String> referenceIdMap)
@NotNull java.util.List<T>
values()
protected void
visitNodes(@NotNull Node parent, @NotNull java.util.function.Consumer<Node> runnable, @NotNull java.lang.Class<? extends Node>... classes)
-
-
-
Constructor Detail
-
NodeRepository
public NodeRepository(@Nullable @Nullable KeepType keepType)
-
-
Method Detail
-
getDataKey
@NotNull public abstract @NotNull DataKey<? extends NodeRepository<T>> getDataKey()
-
getReferencedElements
@NotNull public abstract @NotNull java.util.Set<T> getReferencedElements(Node parent)
-
visitNodes
@SafeVarargs protected final void visitNodes(@NotNull @NotNull Node parent, @NotNull @NotNull java.util.function.Consumer<Node> runnable, @NotNull @NotNull java.lang.Class<? extends Node>... classes)
-
normalizeKey
@NotNull public @NotNull java.lang.String normalizeKey(@NotNull @NotNull java.lang.CharSequence key)
-
getFromRaw
@Nullable public T getFromRaw(@NotNull @NotNull java.lang.CharSequence rawKey)
-
getValues
@NotNull public @NotNull java.util.Collection<T> getValues()
-
transferReferences
public static <T> boolean transferReferences(@NotNull @NotNull NodeRepository<T> destination, @NotNull @NotNull NodeRepository<T> included, boolean onlyIfUndefined, @Nullable @Nullable java.util.Map<java.lang.String,java.lang.String> referenceIdMap)
-
put
@Nullable public T put(@NotNull @NotNull java.lang.String s, @NotNull T t)
- Specified by:
put
in interfacejava.util.Map<java.lang.String,T>
-
putAll
public void putAll(@NotNull @NotNull java.util.Map<? extends java.lang.String,? extends T> map)
- Specified by:
putAll
in interfacejava.util.Map<java.lang.String,T>
-
remove
@Nullable public T remove(@NotNull @NotNull java.lang.Object o)
- Specified by:
remove
in interfacejava.util.Map<java.lang.String,T>
-
clear
public void clear()
- Specified by:
clear
in interfacejava.util.Map<java.lang.String,T>
-
size
public int size()
- Specified by:
size
in interfacejava.util.Map<java.lang.String,T>
-
isEmpty
public boolean isEmpty()
- Specified by:
isEmpty
in interfacejava.util.Map<java.lang.String,T>
-
containsKey
public boolean containsKey(@NotNull @NotNull java.lang.Object o)
- Specified by:
containsKey
in interfacejava.util.Map<java.lang.String,T>
-
containsValue
public boolean containsValue(java.lang.Object o)
- Specified by:
containsValue
in interfacejava.util.Map<java.lang.String,T>
-
get
@Nullable public T get(@NotNull @NotNull java.lang.Object o)
- Specified by:
get
in interfacejava.util.Map<java.lang.String,T>
-
keySet
@NotNull public @NotNull java.util.Set<java.lang.String> keySet()
- Specified by:
keySet
in interfacejava.util.Map<java.lang.String,T>
-
values
@NotNull public @NotNull java.util.List<T> values()
- Specified by:
values
in interfacejava.util.Map<java.lang.String,T>
-
entrySet
@NotNull public @NotNull java.util.Set<java.util.Map.Entry<java.lang.String,T>> entrySet()
- Specified by:
entrySet
in interfacejava.util.Map<java.lang.String,T>
-
equals
public boolean equals(java.lang.Object o)
- Specified by:
equals
in interfacejava.util.Map<java.lang.String,T>
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Specified by:
hashCode
in interfacejava.util.Map<java.lang.String,T>
- Overrides:
hashCode
in classjava.lang.Object
-
-