Resource.InternalType, Resource.Type| Constructor and Description |
|---|
ResourceImpl(Resource.Type type)
Create a resource of the given type.
|
ResourceImpl(Resource resource)
Copy constructor
|
ResourceImpl(Resource resource,
Set<String> propertyIds)
Construct a resource from the given resource, setting only the properties
that are found in the given set of property and category ids.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addCategory(String id)
Add an empty category to this resource.
|
boolean |
equals(Object o) |
Map<String,Map<String,Object>> |
getPropertiesMap()
Obtain the properties contained by this group in a map structure.
|
Object |
getPropertyValue(String id)
Get a property value for the given property id from this resource.
|
Resource.Type |
getType()
Get the resource type.
|
int |
hashCode() |
void |
setProperty(String id,
Object value)
Set a property value for the given property id on this resource.
|
String |
toString() |
public ResourceImpl(Resource.Type type)
type - the resource typepublic ResourceImpl(Resource resource)
resource - the resource to copypublic ResourceImpl(Resource resource, Set<String> propertyIds)
resource - the resource to copypropertyIds - the set of requested property and category idspublic Resource.Type getType()
Resourcepublic Map<String,Map<String,Object>> getPropertiesMap()
ResourcegetPropertiesMap in interface Resourcepublic void setProperty(String id, Object value)
ResourcesetProperty in interface Resourceid - the property idvalue - the valuepublic void addCategory(String id)
ResourceaddCategory in interface Resourceid - the category idpublic Object getPropertyValue(String id)
ResourcegetPropertyValue in interface Resourceid - the property idCopyright © 2022 Apache Software Foundation. All rights reserved.