de.fzj.unicore.wsrflite
Class ResourcePropertyBase<XMLType,BackingType>

java.lang.Object
  extended by de.fzj.unicore.wsrflite.ResourcePropertyBase<XMLType,BackingType>
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
ResourceProperty

public abstract class ResourcePropertyBase<XMLType,BackingType>
extends Object
implements Serializable

A resource property encapsulates some state, making it possible to expose this state as a WS-Resource.

Author:
schuller
See Also:
Serialized Form

Field Summary
protected  WSRFInstance parentWSResource
          a reference to the "parent" resource
 
Constructor Summary
ResourcePropertyBase(WSRFInstance resource)
           
 
Method Summary
 BackingType getProperty()
          get the property as a java object
(optional, return null if not applicable)
abstract  XMLType[] getXml()
          get the XML representation of this property.
 boolean isReadOnly()
          is this a readonly property?
 void setProperty(BackingType setTo)
          set the property as a java object
 void setResource(WSRFInstance resource)
           
 ResourcePropertyBase<XMLType,?> update()
          update the property
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

parentWSResource

protected transient WSRFInstance parentWSResource
a reference to the "parent" resource

Constructor Detail

ResourcePropertyBase

public ResourcePropertyBase(WSRFInstance resource)
Method Detail

setResource

public void setResource(WSRFInstance resource)

update

public ResourcePropertyBase<XMLType,?> update()
                                       throws Exception
update the property

Returns:
the updated property (i.e. this)
Throws:
Exception

getXml

public abstract XMLType[] getXml()
get the XML representation of this property.

Returns:
an array of XmlObject

getProperty

public BackingType getProperty()
get the property as a java object
(optional, return null if not applicable)

Returns:
the "backing" Object

setProperty

public void setProperty(BackingType setTo)
set the property as a java object


isReadOnly

public boolean isReadOnly()
is this a readonly property?

Returns:
true if the property is read-only


Copyright © 2010. All Rights Reserved.