Remote Systems
v6.4.1

com.ibm.etools.systems.model.impl
Class SystemResourceChangeEvent

java.lang.Object
  extended byjava.util.EventObject
      extended bycom.ibm.etools.systems.model.impl.SystemResourceChangeEvent
All Implemented Interfaces:
ISystemResourceChangeEvent, ISystemResourceChangeEvents, Serializable

public class SystemResourceChangeEvent
extends EventObject
implements ISystemResourceChangeEvent

Event object sent to SystemResourceChangeListeners when a remote system object is created, changed, removed, etc.

See Also:
ISystemResourceChangeEvents, Serialized Form

Field Summary
static String copyright
           
 
Fields inherited from class java.util.EventObject
source
 
Fields inherited from interface com.ibm.etools.systems.model.ISystemResourceChangeEvents
EVENT_ADD, EVENT_ADD_FILTER_REFERENCE, EVENT_ADD_FILTERSTRING_REFERENCE, EVENT_ADD_MANY, EVENT_ADD_RELATIVE, EVENT_CHANGE_CHILDREN, EVENT_CHANGE_FILTER_REFERENCE, EVENT_CHANGE_FILTERSTRING_REFERENCE, EVENT_COLLAPSE_ALL, EVENT_COLLAPSE_SELECTED, EVENT_COMMAND_FINISHED, EVENT_COMMAND_HISTORY_UPDATE, EVENT_COMMAND_MESSAGE, EVENT_COMMAND_RUN, EVENT_COMMAND_SHELL_FINISHED, EVENT_COMMAND_SHELL_REMOVED, EVENT_COMPILE_COMMAND_RUN, EVENT_DELETE, EVENT_DELETE_FILTER_REFERENCE, EVENT_DELETE_FILTERSTRING_REFERENCE, EVENT_DELETE_MANY, EVENT_EXPAND_SELECTED, EVENT_ICON_CHANGE, EVENT_MOVE_FILTER_REFERENCES, EVENT_MOVE_FILTERSTRING_REFERENCES, EVENT_MOVE_MANY, EVENT_MUST_COLLAPSE, EVENT_PROPERTY_CHANGE, EVENT_PROPERTYSHEET_UPDATE, EVENT_REFRESH, EVENT_REFRESH_REMOTE, EVENT_REFRESH_SELECTED, EVENT_REFRESH_SELECTED_FILTER, EVENT_REFRESH_SELECTED_PARENT, EVENT_RENAME, EVENT_RENAME_FILTER_REFERENCE, EVENT_REPLACE_CHILDREN, EVENT_REVEAL_AND_SELECT, EVENT_SEARCH_FINISHED, EVENT_SELECT, EVENT_SELECT_EXPAND, EVENT_SELECT_REMOTE, PROPERTYSHEET_UPDATE_EVENT
 
Constructor Summary
SystemResourceChangeEvent(Object[] source, int type, Object parent)
          Constructor for SystemResourceChangeEvent when the source is multipe resources.
SystemResourceChangeEvent(Object source, int type, Object parent)
          Constructor for SystemResourceChangeEvent.
 
Method Summary
 Object getGrandParent()
          Return the grand parent of the object added or removed.
 Object[] getMultiSource()
          For multi-target events, return the array of source targets.
 Viewer getOriginatingViewer()
          Get the originating viewer.
 Object getParent()
          Return the parent of the object added or removed.
 int getPosition()
          Return the position value.
 Object getRelativePrevious()
          For relative add events, return the previous node this is being added after
 int getType()
          Return the type of the event (add, change, remove, rename, change, property change).
 Item getViewerItem()
          Get the viewer Item of the currently selected object.
 void setGrandParent(Object grandparent)
          Set the grand parent of the object added or removed.
 void setOriginatingViewer(Viewer viewer)
          Set the originating viewer.
 void setParent(Object parent)
          Set the parent
 void setPosition(int position)
          Set the position value.
 void setRelativePrevious(Object previousObject)
          For relative add events, set the previous node this is being added after
 void setType(int type)
          Set the type
 void setViewerItem(Item item)
          Set the viewer Item of the currently selected object.
 
Methods inherited from class java.util.EventObject
getSource, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.ibm.etools.systems.model.ISystemResourceChangeEvent
getSource
 

Field Detail

copyright

public static final String copyright
See Also:
Constant Field Values
Constructor Detail

SystemResourceChangeEvent

public SystemResourceChangeEvent(Object source,
                                 int type,
                                 Object parent)
Constructor for SystemResourceChangeEvent.

Parameters:
source - The object that was added,deleted,renamed,changed.
type - The type of event, one of ISystemChangeEvent constants.
parent - The parent of the object that was added or deleted.
See Also:
ISystemResourceChangeEvents

SystemResourceChangeEvent

public SystemResourceChangeEvent(Object[] source,
                                 int type,
                                 Object parent)
Constructor for SystemResourceChangeEvent when the source is multipe resources.

Parameters:
source - The array of objects that were added,deleted,renamed,changed.
type - The type of event, one of ISystemChangeEvent constants.
parent - The parent of the object that was added or deleted.
See Also:
ISystemResourceChangeEvents
Method Detail

getMultiSource

public Object[] getMultiSource()
For multi-target events, return the array of source targets.

Specified by:
getMultiSource in interface ISystemResourceChangeEvent

getParent

public Object getParent()
Return the parent of the object added or removed.

Specified by:
getParent in interface ISystemResourceChangeEvent
Returns:
an object identifying the parent of the source of this event
See Also:
ISystemResourceChangeEvent.getParent()

setParent

public void setParent(Object parent)
Set the parent

Specified by:
setParent in interface ISystemResourceChangeEvent

getGrandParent

public Object getGrandParent()
Return the grand parent of the object added or removed.

Specified by:
getGrandParent in interface ISystemResourceChangeEvent
Returns:
an object identifying the grandparent of the source of this event
See Also:
ISystemResourceChangeEvent.getParent()

setGrandParent

public void setGrandParent(Object grandparent)
Set the grand parent of the object added or removed.


getPosition

public int getPosition()
Return the position value. Used in ADD events.

Specified by:
getPosition in interface ISystemResourceChangeEvent
Returns:
position to add the new item to. A negative number indicates an append operation

setPosition

public void setPosition(int position)
Set the position value. Used in ADD events.

Specified by:
setPosition in interface ISystemResourceChangeEvent
Parameters:
position - zero-based position to insert the new item. A negative number indicates an append operation

setViewerItem

public void setViewerItem(Item item)
Set the viewer Item of the currently selected object. This is a clue when we want to expand and select only the specific instance of this widget in this view.

Specified by:
setViewerItem in interface ISystemResourceChangeEvent

getType

public int getType()
Return the type of the event (add, change, remove, rename, change, property change).

Specified by:
getType in interface ISystemResourceChangeEvent
Returns:
a type that is one of the constants in this interface
See Also:
ISystemResourceChangeEvents, ISystemResourceChangeEvent, ISystemResourceChangeEvent.getType()

setType

public void setType(int type)
Set the type

Specified by:
setType in interface ISystemResourceChangeEvent
See Also:
ISystemResourceChangeEvents

getRelativePrevious

public Object getRelativePrevious()
For relative add events, return the previous node this is being added after

Specified by:
getRelativePrevious in interface ISystemResourceChangeEvent

setRelativePrevious

public void setRelativePrevious(Object previousObject)
For relative add events, set the previous node this is being added after

Specified by:
setRelativePrevious in interface ISystemResourceChangeEvent

setOriginatingViewer

public void setOriginatingViewer(Viewer viewer)
Set the originating viewer. For some events, this allows responding viewers to decide if the event applies to them

Specified by:
setOriginatingViewer in interface ISystemResourceChangeEvent

getOriginatingViewer

public Viewer getOriginatingViewer()
Get the originating viewer. For some events, this allows responding viewers to decide if the event applies to them

Specified by:
getOriginatingViewer in interface ISystemResourceChangeEvent

getViewerItem

public Item getViewerItem()
Get the viewer Item of the currently selected object. This is a clue when we want to expand and select only the specific instance of this widget in this view.

Specified by:
getViewerItem in interface ISystemResourceChangeEvent

Remote Systems
v6.4.1

Copyright © 2005 IBM Corp. All Rights Reserved.

Note: This documentation is for part of an interim API that is still under development and expected to change significantly before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.