|
RSE Release 3.4 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.rse.core.events.SystemRemoteChangeEvent
public class SystemRemoteChangeEvent
For listeners interested in changes with remote resources. These events are
designed to state what the change to the resource was, not to optimize those
events for a GUI (eg, a delete event versus a refresh event).
In RSE 3.0, the concept of Operation type was added (See
setOperation(String)
and the new Constructors, and the oldNames
property was extended from a single String into a String array.
Constructor Summary | |
---|---|
SystemRemoteChangeEvent()
Constructor you shouldn't use unless you intend to call the setters |
|
SystemRemoteChangeEvent(int eventType,
Object resource,
Object resourceParent,
ISubSystem subsystem)
Constructor for non-rename event |
|
SystemRemoteChangeEvent(int eventType,
Object resource,
Object resourceParent,
ISubSystem subsystem,
String[] oldNames)
Constructor for a rename event. |
|
SystemRemoteChangeEvent(String operation,
int eventType,
Object resource,
Object resourceParent,
ISubSystem subsystem)
Constructor for non-rename event |
|
SystemRemoteChangeEvent(String operation,
int eventType,
Object resource,
Object resourceParent,
ISubSystem subsystem,
String[] oldNames)
Constructor for a rename event. |
Method Summary | |
---|---|
int |
getEventType()
Get the event type, such as ISystemRemoteChangeEvents.SYSTEM_REMOTE_RESOURCE_CREATED . |
String[] |
getOldNames()
Get the old name of the resource, in the event of a resource rename. |
String |
getOperation()
Returns the operation of this event if it's not implied by the event itself. |
Object |
getOriginatingViewer()
Get the originating viewer from which this remote resource change event comes from. |
Object |
getResource()
Get the resource that this event applies to It must either be the binary object of the resource, or the absolute name of the resource, or List of absoluteNames. |
Object |
getResourceParent()
Get the parent remote object for the affected remote object. |
ISubSystem |
getSubSystem()
Get the subsystem in which this resource resides. |
void |
setEventType(int eventType)
Reset the event type |
void |
setOldNames(String[] oldNames)
Reset the old names on a rename, move or copy event |
void |
setOperation(String operation)
|
void |
setOriginatingViewer(Object originatingViewer)
Set the originating viewer. |
void |
setResource(Object resource)
Reset the resource |
void |
setResourceParent(Object resourceParent)
Reset the resource's remote resource parent |
void |
setSubSystem(ISubSystem subsystem)
Reset the subsystem |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SystemRemoteChangeEvent(int eventType, Object resource, Object resourceParent, ISubSystem subsystem)
eventType
- - one of the constants from ISystemRemoteChangeEvents
resource
- - the remote resource object, or absolute name of the resource as would be given by calling getAbsoluteName on its remote adapter,
or List of absoluteNamesresourceParent
- - the remote resource's parent object, or absolute name, if that is known. If it is non-null, this will aid in refreshing occurences of that parent.subsystem
- - the subsystem which contains this remote resource. This allows the search for impacts to be
limited to subsystems of the same parent factory, and to connections with the same hostname as the subsystem's connection.public SystemRemoteChangeEvent(int eventType, Object resource, Object resourceParent, ISubSystem subsystem, String[] oldNames)
eventType
- - one of the constants from
ISystemRemoteChangeEvents
resource
- - the remote resource object, or absolute name of the
resource as would be given by calling getAbsoluteName on its
remote adapter, or List of absoluteNamesresourceParent
- - the remote resource's parent object, or absolute
name, if that is known. If it is non-null, this will aid in
refreshing occurrences of that parent.subsystem
- - the subsystem which contains this remote resource.
This allows the search for impacts to be limited to subsystems
of the same parent factory, and to connections with the same
hostname as the subsystem's connection.oldNames
- - on a rename, copy or move operation, these are the
absolute names of the resources prior to the operationpublic SystemRemoteChangeEvent(String operation, int eventType, Object resource, Object resourceParent, ISubSystem subsystem)
operation
- - the operation for which this event was fired. From
ISystemRemoteChangeEvents.SYSTEM_REMOTE_OPERATION_COPY
and related String constantseventType
- - one of the constants from
ISystemRemoteChangeEvents
resource
- - the remote resource object, or absolute name of the
resource as would be given by calling getAbsoluteName on its
remote adapter, or List of absoluteNamesresourceParent
- - the remote resource's parent object, or absolute
name, if that is known. If it is non-null, this will aid in
refreshing occurrences of that parent.subsystem
- - the subsystem which contains this remote resource.
This allows the search for impacts to be limited to subsystems
of the same parent factory, and to connections with the same
hostname as the subsystem's connection.public SystemRemoteChangeEvent(String operation, int eventType, Object resource, Object resourceParent, ISubSystem subsystem, String[] oldNames)
operation
- - the operation for which this event was fired. From
ISystemRemoteChangeEvents.SYSTEM_REMOTE_OPERATION_COPY
and related String constantseventType
- - one of the constants from
ISystemRemoteChangeEvents
resource
- - the remote resource object, or absolute name of the
resource as would be given by calling getAbsoluteName on its
remote adapter, or List of absoluteNamesresourceParent
- - the remote resource's parent object, or absolute
name, if that is known. If it is non-null, this will aid in
refreshing occurrences of that parent.subsystem
- - the subsystem which contains this remote resource.
This allows the search for impacts to be limited to subsystems
of the same parent factory, and to connections with the same
hostname as the subsystem's connection.oldNames
- - on a rename, copy or move operation, these are the
absolute names of the resources prior to the operationpublic SystemRemoteChangeEvent()
Method Detail |
---|
public void setEventType(int eventType)
public void setResource(Object resource)
public void setResourceParent(Object resourceParent)
public void setSubSystem(ISubSystem subsystem)
public void setOldNames(String[] oldNames)
public int getEventType()
ISystemRemoteChangeEvents.SYSTEM_REMOTE_RESOURCE_CREATED
.
getEventType
in interface ISystemRemoteChangeEvent
ISystemRemoteChangeEvents
public Object getResource()
getResource
in interface ISystemRemoteChangeEvent
public Object getResourceParent()
getResourceParent
in interface ISystemRemoteChangeEvent
null
if not applicable.public ISubSystem getSubSystem()
getSubSystem
in interface ISystemRemoteChangeEvent
public String[] getOldNames()
getOldNames
in interface ISystemRemoteChangeEvent
null
if not applicable.public void setOriginatingViewer(Object originatingViewer)
public Object getOriginatingViewer()
public void setOperation(String operation)
operation
- from
ISystemRemoteChangeEvents.SYSTEM_REMOTE_OPERATION_COPY
and related String constantspublic String getOperation()
getOperation
in interface ISystemRemoteChangeEvent
ISystemRemoteChangeEvents.SYSTEM_REMOTE_OPERATION_COPY
,
ISystemRemoteChangeEvents.SYSTEM_REMOTE_OPERATION_MOVE
|
RSE Release 3.4 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |