|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.novell.nds.dirxml.shimhost.ShimState
public class ShimState
Encapsulation of "driver state" information stored on behalf of application shims.
Field Summary | |
---|---|
static int |
DRIVER
Parameter value for getState() method indicating DriverShim state. |
static int |
PUBLISHER
Parameter value for getState() method indicating PublicationShim state. |
static int |
SUBSCRIBER
Parameter value for getState() method indicating SubscriptionShim state. |
static String |
TAG_SHIM_STATE
Tag name of "shim-state" element. |
Constructor Summary | |
---|---|
ShimState()
Construct an empty ShimState instance. |
|
ShimState(Element shimState)
Construct a ShimState instance from a <shim-state> element. |
Method Summary | |
---|---|
Element |
getDriverState()
Get the DriverShim state. |
Element |
getPublisherState()
Get the PublicationShim state |
Element |
getState(int which)
Return state for one of the shims. |
Element |
getSubscriberState()
Get the SubscriptionShim state |
boolean |
hasBeenModified()
Return true if this instance has been modified. |
void |
resetModified()
Reset the modified flag for this instance such that hasBeenModified()
will return false . |
void |
serializeXML(OutputStream os)
Serialize the shim state data as an XML document. |
void |
setDriverState(Element newDriverState)
Set the DriverShim state. |
void |
setPublisherState(Element newPublisherState)
Set the PublicationShim state. |
void |
setSubscriberState(Element newSubscriberState)
Set the SubscriptionShim state. |
Element |
toXML(Node parent)
Construct an XML representation of this ShimState instance
Note that the act of creating an XML representation does not reset this instance's
modified flag. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String TAG_SHIM_STATE
public static final int DRIVER
DriverShim
state.
getState(int)
,
Constant Field Valuespublic static final int SUBSCRIBER
SubscriptionShim
state.
getState(int)
,
Constant Field Valuespublic static final int PUBLISHER
PublicationShim
state.
getState(int)
,
Constant Field ValuesConstructor Detail |
---|
public ShimState()
ShimState
instance.
public ShimState(Element shimState)
ShimState
instance from a <shim-state> element.
shimState
- <shim-state> elementMethod Detail |
---|
public boolean hasBeenModified()
true
if this instance has been modified.
The instance is considered to have been modified if a change was made
that affects the persistent representation since:
resetModified()
was last called
hasBeenModified
in interface ConfigElement
true
or false
resetModified()
,
toXML(org.w3c.dom.Node)
public void resetModified()
hasBeenModified()
will return false
.
resetModified
in interface ConfigElement
hasBeenModified()
public Element toXML(Node parent)
ShimState
instance
Note that the act of creating an XML representation does not reset this instance's
modified flag. It must be reset by calling resetModified()
.
toXML
in interface ConfigElement
parent
- Node
under which to build XML representation
hasBeenModified()
,
resetModified()
public void serializeXML(OutputStream os) throws IOException
os
- OutputStream
to which to serialize.
IOException
- if error occurs writing to OutputStream
public Element getState(int which) throws IllegalArgumentException
which
- DRIVER
, SUBSCRIBER
, or PUBLISHER
Element
IllegalArgumentException
- if which
is incorrectpublic Element getDriverState()
DriverShim
state.
public void setDriverState(Element newDriverState) throws IllegalArgumentException
DriverShim
state.
newDriverState
- <driver-state element
IllegalArgumentException
- if parameter doesn't have
the correct name, or is null
.public Element getSubscriberState()
SubscriptionShim
state
public void setSubscriberState(Element newSubscriberState) throws IllegalArgumentException
SubscriptionShim
state.
newSubscriberState
- <subscriber-state element
IllegalArgumentException
- if parameter doesn't have
the correct name, or is null
.public Element getPublisherState()
PublicationShim
state
public void setPublisherState(Element newPublisherState) throws IllegalArgumentException
PublicationShim
state.
newPublisherState
- <publisher-state element
IllegalArgumentException
- if parameter doesn't have
the correct name, or is null
.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |