Package sk.antons.json.impl
Class JsonAttributeImpl
- java.lang.Object
-
- sk.antons.json.impl.JsonAttributeImpl
-
- All Implemented Interfaces:
JsonGroup,JsonMember,JsonAttribute
public class JsonAttributeImpl extends Object implements JsonAttribute, JsonGroup, JsonMember
- Author:
- antons
-
-
Constructor Summary
Constructors Constructor Description JsonAttributeImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description JsonObjectImplgroup()booleanisDescendantOf(JsonValue parent)intmemberIndex(JsonMember m)JsonStringLiteralImplname()Name literal of json attributevoidremove()Removes this attribute from parent object.voidsetGroup(JsonGroup group)voidsetName(JsonStringLiteralImpl name)voidsetValue(JsonValue value)JsonValuevalue()Value of json attribute.
-
-
-
Method Detail
-
name
public JsonStringLiteralImpl name()
Description copied from interface:JsonAttributeName literal of json attribute- Specified by:
namein interfaceJsonAttribute- Returns:
- attribute name literal
-
value
public JsonValue value()
Description copied from interface:JsonAttributeValue of json attribute.- Specified by:
valuein interfaceJsonAttribute- Returns:
- attribute value
-
setName
public void setName(JsonStringLiteralImpl name)
-
setValue
public void setValue(JsonValue value)
-
group
public JsonObjectImpl group()
- Specified by:
groupin interfaceJsonMember
-
setGroup
public void setGroup(JsonGroup group)
- Specified by:
setGroupin interfaceJsonMember
-
memberIndex
public int memberIndex(JsonMember m)
- Specified by:
memberIndexin interfaceJsonGroup
-
remove
public void remove()
Description copied from interface:JsonAttributeRemoves this attribute from parent object.- Specified by:
removein interfaceJsonAttribute
-
isDescendantOf
public boolean isDescendantOf(JsonValue parent)
- Specified by:
isDescendantOfin interfaceJsonGroup
-
-