edu.wisc.trace.urcsdk.client.uisocket.types
Class AbstractUISocketElement

java.lang.Object
  extended by edu.wisc.trace.urcsdk.client.uisocket.types.AbstractUISocketElement
All Implemented Interfaces:
IUISocketElement, java.lang.Cloneable
Direct Known Subclasses:
UISocketCommand, UISocketConstant, UISocketNotification, UISocketVariable

public abstract class AbstractUISocketElement
extends java.lang.Object
implements IUISocketElement

AbstractUISocketElement is an abstract implementation of the IUISocketElement interface. It provides for the common functionality all UI Socket Elements require. Created on: Sep 7, 2004

Version:
$Revision: 1.21 $
Author:
Andrew Martin, Trace R&D Center

Field Summary
protected  java.util.Set<IUISocketElement> dependents
           
protected  java.lang.String id
           
protected  IInteractor interactor
           
protected  java.util.List<ISocketElementListener> listeners
          List of ISocketElementListener's
protected  java.util.logging.Logger logger
           
protected  UISocketDocument parent
           
protected  ElementRef ref
           
protected  boolean secret
           
protected  boolean sensitive
           
protected  ClientSession session
           
protected  java.lang.String sessionId
           
protected  XSDSimpleType simpleType
           
protected  UISocketMirror socket
           
protected  SocketDependency socketDependency
           
protected  java.util.Set<IUISocketElement> supports
           
protected  boolean timeout
           
protected  java.lang.String type
           
protected  java.lang.Object value
           
 
Constructor Summary
AbstractUISocketElement()
          Creates a new AbstractUISocketElement instance.
AbstractUISocketElement(UISocketDocument parent, UISocketMirror socket, org.w3c.dom.Element rootElement)
          Creates a new AbstractUISocketElement instance.
AbstractUISocketElement(UISocketMirror socket)
          Creates a new AbstractUISocketElement instance.
 
Method Summary
 void checkDependencies()
           
 void checkDependents()
           
 java.lang.Object clone()
          Returnes a copy of the object
 IResource getAccessKey(UserPreferences prefs)
           
 java.util.Set<IUISocketElement> getDependents()
           
 IResource getHelp()
           
 java.lang.String getId()
          Returns the Id of the UISocketElement
 IInteractor getInteractor()
           
 java.util.List<java.lang.String> getKeywords(UserPreferences prefs)
           
 IResource getLabel()
           
 UISocketDocument getParent()
           
 ElementRef getRef()
           
 IResource getResource(java.lang.String name)
           
 boolean getSecret()
           
 ClientSession getSession()
           
 UISocketMirror getSocket()
           
 SocketDependency getSocketDependency()
           
 java.util.Set<IUISocketElement> getSupports()
           
 java.lang.String getType()
          Returns the type of this element.
 java.lang.Object getValue()
          Returns the current value of this element.
 XSDSimpleType getXSDSimpleType()
           
abstract  boolean isWritable()
          Returns true if this element is writable.
 void parse(org.w3c.dom.Element rootElement)
          Parses the given element for the data required to create a UISocketElement
 void registerDependent(IUISocketElement socketElement)
           
 void registerSupport(IUISocketElement socketElement)
           
 void setInteractor(IInteractor interactor)
           
 void setListener(ISocketElementListener listener)
           
 void setParent(UISocketDocument parent)
           
 void setSession(ClientSession session)
           
 void setSessionId(java.lang.String sessionId)
           
 void setSocket(UISocketMirror socket)
           
 void setValue(java.lang.String value)
           
 boolean setValueRequest(java.lang.String value)
           
 void setXSDSimpleType(XSDSimpleType simpleType)
           
 java.lang.String toString()
          Returns a String representation of this object.
 void updateValue()
           
abstract  java.lang.Object validate(java.lang.String value)
           
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface edu.wisc.trace.urcsdk.client.uisocket.types.IUISocketElement
isExecutable, isReadable
 

Field Detail

dependents

protected java.util.Set<IUISocketElement> dependents

id

protected java.lang.String id

listeners

protected java.util.List<ISocketElementListener> listeners
List of ISocketElementListener's


logger

protected java.util.logging.Logger logger

parent

protected UISocketDocument parent

ref

protected ElementRef ref

secret

protected boolean secret

sensitive

protected boolean sensitive

session

protected ClientSession session

sessionId

protected java.lang.String sessionId

socket

protected UISocketMirror socket

socketDependency

protected SocketDependency socketDependency

supports

protected java.util.Set<IUISocketElement> supports

timeout

protected boolean timeout

type

protected java.lang.String type

value

protected java.lang.Object value

simpleType

protected XSDSimpleType simpleType

interactor

protected IInteractor interactor
Constructor Detail

AbstractUISocketElement

public AbstractUISocketElement()
Creates a new AbstractUISocketElement instance.


AbstractUISocketElement

public AbstractUISocketElement(UISocketMirror socket)
Creates a new AbstractUISocketElement instance.

Parameters:
socket - an UISocket value

AbstractUISocketElement

public AbstractUISocketElement(UISocketDocument parent,
                               UISocketMirror socket,
                               org.w3c.dom.Element rootElement)
                        throws UrcException
Creates a new AbstractUISocketElement instance.

Parameters:
parent - an UISocketDocument value
socket - an UISocket value
rootElement - an Element value
Throws:
UrcException - if an error occurs
Method Detail

clone

public java.lang.Object clone()
Description copied from interface: IUISocketElement
Returnes a copy of the object

Specified by:
clone in interface IUISocketElement
Overrides:
clone in class java.lang.Object
Returns:
an Object value

getAccessKey

public IResource getAccessKey(UserPreferences prefs)

getDependents

public java.util.Set<IUISocketElement> getDependents()

getHelp

public IResource getHelp()

getId

public java.lang.String getId()
Description copied from interface: IUISocketElement
Returns the Id of the UISocketElement

Specified by:
getId in interface IUISocketElement
Returns:
a String value

getKeywords

public java.util.List<java.lang.String> getKeywords(UserPreferences prefs)

getLabel

public IResource getLabel()

getParent

public UISocketDocument getParent()

getRef

public ElementRef getRef()

getResource

public IResource getResource(java.lang.String name)

getSocket

public UISocketMirror getSocket()

getSocketDependency

public SocketDependency getSocketDependency()

getSupports

public java.util.Set<IUISocketElement> getSupports()

getType

public java.lang.String getType()
Description copied from interface: IUISocketElement
Returns the type of this element.

Specified by:
getType in interface IUISocketElement
Returns:
a String value

getValue

public java.lang.Object getValue()
Description copied from interface: IUISocketElement
Returns the current value of this element.

Specified by:
getValue in interface IUISocketElement
Returns:
an Object value

isWritable

public abstract boolean isWritable()
Description copied from interface: IUISocketElement
Returns true if this element is writable.

Specified by:
isWritable in interface IUISocketElement
Returns:
a boolean value

parse

public void parse(org.w3c.dom.Element rootElement)
           throws UrcException
Description copied from interface: IUISocketElement
Parses the given element for the data required to create a UISocketElement

Specified by:
parse in interface IUISocketElement
Parameters:
rootElement - the Element object to parse
Throws:
UrcException - if an error occurs

registerDependent

public void registerDependent(IUISocketElement socketElement)

registerSupport

public void registerSupport(IUISocketElement socketElement)

setListener

public void setListener(ISocketElementListener listener)

setParent

public void setParent(UISocketDocument parent)

setSessionId

public void setSessionId(java.lang.String sessionId)

setSocket

public void setSocket(UISocketMirror socket)

setValue

public void setValue(java.lang.String value)

updateValue

public void updateValue()
                 throws UrcException
Throws:
UrcException

validate

public abstract java.lang.Object validate(java.lang.String value)

setValueRequest

public boolean setValueRequest(java.lang.String value)
                        throws UrcException
Throws:
UrcException

checkDependencies

public void checkDependencies()

toString

public java.lang.String toString()
Description copied from interface: IUISocketElement
Returns a String representation of this object.

Specified by:
toString in interface IUISocketElement
Overrides:
toString in class java.lang.Object
Returns:
a String value

checkDependents

public void checkDependents()

getSession

public ClientSession getSession()

setSession

public void setSession(ClientSession session)

getSecret

public boolean getSecret()

setXSDSimpleType

public void setXSDSimpleType(XSDSimpleType simpleType)

getXSDSimpleType

public XSDSimpleType getXSDSimpleType()

getInteractor

public IInteractor getInteractor()

setInteractor

public void setInteractor(IInteractor interactor)


Copyright © 2006 Trace R&D Center, University of Wisconsin-Madison. All Rights Reserved.