public static class Resource.Nested extends Resource
This class should never be directly instantiated. Always use of(com.liferay.apio.architect.resource.Resource.Item, java.lang.String)
method to create a new instance.
Resource.GenericParent, Resource.Id, Resource.Item, Resource.Nested, Resource.Paged
Constructor and Description |
---|
Nested(Resource.Item parentItem,
java.lang.String name) |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj) |
Resource.Item |
getParentItem()
The resource's parent
Resource.Item |
int |
hashCode() |
static Resource.Nested |
of(Resource.Item parentItem,
java.lang.String name)
|
java.lang.String |
toString() |
Resource.Nested |
withParentId(Resource.Id id)
Copies the current
Resource.Nested by setting a value for the parent's
ID attribute. |
public Nested(Resource.Item parentItem, java.lang.String name)
public static Resource.Nested of(Resource.Item parentItem, java.lang.String name)
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public Resource.Item getParentItem()
Resource.Item
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public Resource.Nested withParentId(Resource.Id id)
Resource.Nested
by setting a value for the parent's
ID
attribute. A shallow reference
equality check is used to prevent copying of the same value by
returning this
.id
- the new IDthis
object