Class SharableImpl

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

public class SharableImpl extends Object implements Sharable
Author:
Jeff McWhirter
  • Constructor Details

    • SharableImpl

      public SharableImpl()
      Instantiates a new sharable impl.
    • SharableImpl

      public SharableImpl(boolean sharing)
      Instantiates a new sharable impl.
      Parameters:
      sharing - the sharing
    • SharableImpl

      public SharableImpl(Object group, boolean sharing)
      Instantiates a new sharable impl.
      Parameters:
      group - the group
      sharing - the sharing
  • Method Details

    • showSharableDialog

      public void showSharableDialog()
      Show sharable dialog.
    • getSharablePropertiesComponent

      public JComponent getSharablePropertiesComponent()
      Gets the sharable properties component.
      Returns:
      the sharable properties component
    • applySharableProperties

      public void applySharableProperties()
      Apply sharable properties.
    • initSharable

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

      public boolean getSharing()
      Gets the sharing.
      Specified by:
      getSharing in interface Sharable
      Returns:
      the sharing
    • setSharing

      public void setSharing(boolean sharing)
      Sets the sharing.
      Parameters:
      sharing - the new sharing
    • getShareGroup

      public Object getShareGroup()
      Gets the share group.
      Specified by:
      getShareGroup in interface Sharable
      Returns:
      the share group
    • removeSharable

      public void removeSharable()
      Removes the sharable.
    • setShareGroup

      public void setShareGroup(Object shareGroup)
      Sets the share group.
      Parameters:
      shareGroup - the new share group
    • receiveShareData

      public void receiveShareData(Sharable from, Object dataId, Object[] data)
      Receive share data.
      Specified by:
      receiveShareData in interface Sharable
      Parameters:
      from - the from
      dataId - the data id
      data - the 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 - the data id
      data - the data
    • getUniqueId

      public String getUniqueId()
      Gets the unique id.
      Specified by:
      getUniqueId in interface Sharable
      Returns:
      the unique id
    • setUniqueId

      public void setUniqueId(String id)
      Sets the unique id.
      Parameters:
      id - the new unique id