ucar.unidata.collab
Class SharableImpl

java.lang.Object
  extended by ucar.unidata.collab.SharableImpl
All Implemented Interfaces:
Sharable
Direct Known Subclasses:
AnimationWidget, DataSourceImpl, DisplayControlBase, Flythrough, PropertiedThing, ViewManager

public class SharableImpl
extends Object
implements Sharable

Version:
$Revision: 1.12 $Date: 2005/10/06 15:19:37 $
Author:
Jeff McWhirter

Constructor Summary
SharableImpl()
          _more_
SharableImpl(boolean sharing)
          _more_
SharableImpl(Object group, boolean sharing)
          _more_
 
Method Summary
 void applySharableProperties()
          _more_
 void doShare(Object dataId, Object data)
          Share the data identified by dataId with both internal and external objects.
 void doShare(Object dataId, Object[] data)
          Share the data identified by dataId with both internal and external objects.
 void doShareExternal(Object dataId, Object data)
          Share the data identified by dataId with only external (to the jvm) objects.
 void doShareInternal(Object dataId, Object data)
          Share the data identified by dataId with only internal (to the jvm) objects.
 Long getReceiveShareTime(Object dataId)
          Get the last time this object rcvd the share
 JComponent getSharablePropertiesComponent()
          _more_
 Object getShareGroup()
          _more_
 boolean getSharing()
          _more_
 String getUniqueId()
          _more_
protected  void initSharable()
          Initialize this sharable.
 void receiveShareData(Sharable from, Object dataId, Object[] data)
          _more_
 void removeSharable()
          _more_
 void setReceiveShareTime(Object dataId, Long time)
          Record the time when this object rcvd the share
 void setShareGroup(Object shareGroup)
          _more_
 void setSharing(boolean sharing)
          _more_
 void setUniqueId(String id)
          _more_
 void showSharableDialog()
          _more_
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SharableImpl

public SharableImpl()
_more_


SharableImpl

public SharableImpl(boolean sharing)
_more_

Parameters:
sharing -

SharableImpl

public SharableImpl(Object group,
                    boolean sharing)
_more_

Parameters:
group -
sharing -
Method Detail

showSharableDialog

public void showSharableDialog()
_more_


getSharablePropertiesComponent

public JComponent getSharablePropertiesComponent()
_more_

Returns:
_more_

applySharableProperties

public void applySharableProperties()
_more_


initSharable

protected void initSharable()
Initialize this sharable. Add it into the SharableManager.


getSharing

public boolean getSharing()
_more_

Specified by:
getSharing in interface Sharable
Returns:
_more_

setSharing

public void setSharing(boolean sharing)
_more_

Parameters:
sharing -

getShareGroup

public Object getShareGroup()
_more_

Specified by:
getShareGroup in interface Sharable
Returns:
_more_

removeSharable

public void removeSharable()
_more_


setShareGroup

public void setShareGroup(Object shareGroup)
_more_

Parameters:
shareGroup -

receiveShareData

public void receiveShareData(Sharable from,
                             Object dataId,
                             Object[] data)
_more_

Specified by:
receiveShareData in interface Sharable
Parameters:
from -
dataId -
data -

getReceiveShareTime

public Long getReceiveShareTime(Object dataId)
Get the last time this object rcvd the share

Specified by:
getReceiveShareTime in interface Sharable
Parameters:
dataId - data id
Returns:
last time or null

setReceiveShareTime

public void setReceiveShareTime(Object dataId,
                                Long time)
Record the time when this object rcvd the share

Specified by:
setReceiveShareTime in interface Sharable
Parameters:
dataId - data id
time - time

doShare

public void doShare(Object dataId,
                    Object[] data)
Share the data identified by dataId with both internal and external objects.

Parameters:
dataId - Identifies the attribute that is being shared
data - The array of data that is being shared

doShare

public void doShare(Object dataId,
                    Object data)
Share the data identified by dataId with both internal and external objects.

Parameters:
dataId - Identifies the attribute that is being shared
data - The data that is being shared

doShareExternal

public void doShareExternal(Object dataId,
                            Object data)
Share the data identified by dataId with only external (to the jvm) objects. i.e., only share with other objects on other jvms through the collaboration mechanism.

Parameters:
dataId - Identifies the attribute that is being shared
data - The data that is being shared

doShareInternal

public void doShareInternal(Object dataId,
                            Object data)
Share the data identified by dataId with only internal (to the jvm) objects.

Parameters:
dataId -
data -

getUniqueId

public String getUniqueId()
_more_

Specified by:
getUniqueId in interface Sharable
Returns:
_more_

setUniqueId

public void setUniqueId(String id)
_more_

Parameters:
id -