org.apache.muse.ws.resource.properties.schema
Class OpenPropertiesSchema

java.lang.Object
  extended by org.apache.muse.ws.resource.properties.schema.OpenPropertiesSchema
All Implemented Interfaces:
ResourcePropertiesSchema

public final class OpenPropertiesSchema
extends Object
implements ResourcePropertiesSchema

OpenPropertiesSchema is a ResourcePropertiesSchema that has no restrictions on any of its properties - all operations are allowed, and no values have limits. This class is a singleton because a restriction-less schema is the same no matter what properties are defined.

Author:
Dan Jemiolo (danj)

Field Summary
 
Fields inherited from interface org.apache.muse.ws.resource.properties.schema.ResourcePropertiesSchema
UNBOUNDED
 
Method Summary
 WsResourceCapability getCapability(QName property)
           
 QName getElementName()
           
static OpenPropertiesSchema getInstance()
           
 int getMaxOccurs(QName property)
           
 int getMinOccurs(QName property)
           
 Collection getPropertyNames()
           
 QName getPropertyTypeName(QName property)
           
 boolean hasCapability(QName property)
           
 boolean hasProperty(QName property)
           
 boolean isMaxUnbounded(QName property)
           
 boolean isNillable(QName property)
           
 void setCapability(QName property, WsResourceCapability capability)
          Maps the property to the capability so that users can later determine which capability should be used for servicing read/write requests against the property.
 void setElementName(QName wsrpName)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static OpenPropertiesSchema getInstance()
Returns:
The singleton instance of this class.

getCapability

public WsResourceCapability getCapability(QName property)
Specified by:
getCapability in interface ResourcePropertiesSchema
Returns:
The capability that defines the resource property, or null if the property does not exist.

getElementName

public QName getElementName()
Specified by:
getElementName in interface ResourcePropertiesSchema
Returns:
The name of the schema element representing the WSRP document.

getMaxOccurs

public int getMaxOccurs(QName property)
Specified by:
getMaxOccurs in interface ResourcePropertiesSchema
Returns:
ResourcePropertiesSchema.UNBOUNDED

getMinOccurs

public int getMinOccurs(QName property)
Specified by:
getMinOccurs in interface ResourcePropertiesSchema
Returns:
zero (0)

getPropertyNames

public Collection getPropertyNames()
Specified by:
getPropertyNames in interface ResourcePropertiesSchema
Returns:
An empty collection.

getPropertyTypeName

public QName getPropertyTypeName(QName property)
Specified by:
getPropertyTypeName in interface ResourcePropertiesSchema
Returns:
null

hasCapability

public boolean hasCapability(QName property)
Specified by:
hasCapability in interface ResourcePropertiesSchema

hasProperty

public boolean hasProperty(QName property)
Specified by:
hasProperty in interface ResourcePropertiesSchema
Returns:
true

isMaxUnbounded

public boolean isMaxUnbounded(QName property)
Specified by:
isMaxUnbounded in interface ResourcePropertiesSchema
Returns:
true

isNillable

public boolean isNillable(QName property)
Specified by:
isNillable in interface ResourcePropertiesSchema
Returns:
true

setCapability

public void setCapability(QName property,
                          WsResourceCapability capability)
Description copied from interface: ResourcePropertiesSchema
Maps the property to the capability so that users can later determine which capability should be used for servicing read/write requests against the property.

Specified by:
setCapability in interface ResourcePropertiesSchema

setElementName

public void setElementName(QName wsrpName)
Specified by:
setElementName in interface ResourcePropertiesSchema
Parameters:
wsrpName - The name of the schema element representing the WSRP document.


Copyright © 2005-2011 Apache Web Services - Muse. All Rights Reserved.