public class Namespace extends JsonObject
http://getcomposer.org/doc/04-schema.md#psr-0propertiessortOrderchangeSupport| Constructor and Description |
|---|
Namespace() |
Namespace(String namespacename,
String path) |
| Modifier and Type | Method and Description |
|---|---|
void |
add(String path) |
void |
addPaths(UniqueJsonArray paths) |
protected Object |
buildJson() |
void |
clear()
Clears the paths from this namespace
|
Namespace |
clone() |
boolean |
equals(Object obj) |
String |
getFirst()
Returns the path and if there are more than one, returns the first one.
|
String |
getNamespace()
Returns the name.
|
protected List<String> |
getOwnProperties() |
UniqueJsonArray |
getPaths() |
boolean |
has(String path)
Returns whether the given property is present.
|
void |
remove(String path)
Removes a path from the namespace
|
void |
removeAll() |
void |
setNamespace(String namespace)
Sets the name.
|
int |
size() |
cloneProperties, getAsArray, getAsBoolean, getAsFloat, getAsInteger, getAsObject, getAsRaw, getAsString, initialize, is, isArray, isObject, setdoParse, get, parseField, setappendSortOrder, fromJson, fromJson, fromJson, fromJson, getFieldByName, getFieldName, getFieldNames, getFields, getJsonValue, listen, toJsonaddPropertyChangeListener, addPropertyChangeListener, firePropertyChange, removePropertyChangeListener, removePropertyChangeListenerprotected Object buildJson()
buildJson in class AbstractJsonObject<JsonValue>protected List<String> getOwnProperties()
getOwnProperties in class AbstractJsonObject<JsonValue>public String getNamespace()
public void setNamespace(String namespace)
name - the name to setpublic void add(String path)
public boolean has(String path)
AbstractJsonObjecthas in class AbstractJsonObject<JsonValue>path - the property to look fortrue property presentfalse property not presentpublic void clear()
clear in interface JsonCollectionclear in class AbstractJsonObject<JsonValue>public void addPaths(UniqueJsonArray paths)
public String getFirst()
public UniqueJsonArray getPaths()
public void remove(String path)
remove in class AbstractJsonObject<JsonValue>path - the propertypublic void removeAll()
public int size()
size in interface JsonCollectionsize in class AbstractJsonObject<JsonValue>Copyright © 2014. All rights reserved.