public abstract class ParentAbsence<Parent extends Dynamic> extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
ParentAbsence.Barren<P extends Dynamic & alexh.weak.Describer> |
static class |
ParentAbsence.Empty<P extends Dynamic & alexh.weak.Describer> |
| Modifier and Type | Field and Description |
|---|---|
static String |
ARROW |
protected Object |
key |
protected Parent |
parent |
| Constructor and Description |
|---|
ParentAbsence(Parent parent,
Object key) |
| Modifier and Type | Method and Description |
|---|---|
default <T> T |
as(Class<T> type)
As
Weak.asObject() casting to input type, and providing a better message in the exceptional case |
Object |
asObject()
Returns inner value implicitly asserting that the value is not absent, ie
Weak.isPresent() is true |
Stream<Dynamic> |
children() |
protected abstract String |
describeIssue(LinkedList<Object> ascendingMarkedKeyChain,
Object parentKey) |
String |
describeIssue(List<Object> childKeys) |
boolean |
equals(Object o) |
static alexh.weak.DynamicChild |
from(Dynamic parent,
Object key,
Object val) |
Dynamic |
get(Object key)
Returns a dynamic wrapping the immediate child of this instance with the input key,
or a dynamic representing the lack of such a child.
|
int |
hashCode() |
boolean |
isPresent()
Returns if this instance wraps a non-null value.
|
Dynamic |
key()
Returns Weak instance wrapping the key for this node.
|
static alexh.weak.DynamicChild |
key(Dynamic parent,
Object key) |
Dynamic |
parent() |
Parent |
parent() |
String |
toString() |
clone, finalize, getClass, notify, notifyAll, wait, wait, waitallChildren, allChildrenBreadthFirst, allChildrenDepthFirst, children, dget, from, get, keypublic static final String ARROW
protected final Parent extends Dynamic parent
protected final Object key
protected abstract String describeIssue(LinkedList<Object> ascendingMarkedKeyChain, Object parentKey)
public final String describeIssue(List<Object> childKeys)
childKeys - all child keys of this empty child in ascending orderpublic Dynamic get(Object key)
Dynamickey - child keypublic Object asObject()
WeakWeak.isPresent() is truepublic Dynamic parent()
public <T> T as(Class<T> type)
DynamicWeak.asObject() casting to input type, and providing a better message in the exceptional casepublic Parent parent()
public Dynamic key()
DynamicWeak.asObject()
Top-level Dynamic objects have the key value Dynamic.ROOT_KEYpublic boolean isPresent()
WeakWeak.asObject() will not throwpublic Stream<Dynamic> children()
Copyright © 2017. All rights reserved.