Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 


Eclipse Platform
Release 3.5

org.eclipse.ui
Class SaveablesLifecycleEvent

java.lang.Object
  extended by 

java.util.EventObject
      extended by 
org.eclipse.ui.SaveablesLifecycleEvent
All Implemented Interfaces:
Serializable

public class SaveablesLifecycleEvent
extends EventObject

Event object describing a change to a set of Saveable objects.

Since:
3.2
See Also:
Serialized Form

Field Summary
static int DIRTY_CHANGED
          Event type constant specifying that the dirty state of the given saveables has changed.
static int POST_CLOSE
          Event type constant specifying that the given saveables have been closed.
static int POST_OPEN
          Event type constant specifying that the given saveables have been opened.
static int PRE_CLOSE
          Event type constant specifying that the given saveables are about to be closed.
 
Fields inherited from class java.util. EventObject
source
 
Constructor Summary
SaveablesLifecycleEvent ( Object source, int eventType, Saveable[] saveables, boolean force)
          Creates a new SaveablesLifecycleEvent.
 
Method Summary
 int getEventType ()
          Returns the eventType, currently one of POST_OPEN, PRE_CLOSE, POST_CLOSE, DIRTY_CHANGED.
  Saveable[] getSaveables ()
          Returns the affected saveables.
 boolean isForce ()
          Sets the force flag.
 boolean isVeto ()
          Returns the veto.
 void setVeto (boolean veto)
           
 
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
 

Field Detail

POST_OPEN

public static final int POST_OPEN
Event type constant specifying that the given saveables have been opened.

See Also:
Constant Field Values

PRE_CLOSE

public static final int PRE_CLOSE
Event type constant specifying that the given saveables are about to be closed. Listeners may veto the closing if isForce() is false.

See Also:
Constant Field Values

POST_CLOSE

public static final int POST_CLOSE
Event type constant specifying that the given saveables have been closed.

See Also:
Constant Field Values

DIRTY_CHANGED

public static final int DIRTY_CHANGED
Event type constant specifying that the dirty state of the given saveables has changed.

See Also:
Constant Field Values
Constructor Detail

SaveablesLifecycleEvent

public SaveablesLifecycleEvent(
Object source,
                               int eventType,
                               
Saveable[] saveables,
                               boolean force)
Creates a new SaveablesLifecycleEvent.

Parameters:
source - The source of the event. If an ISaveablesSource notifies about changes to the saveables returned by ISaveablesSource.getSaveables(), the source must be the ISaveablesSource object.
eventType - the event type, currently one of POST_OPEN, PRE_CLOSE, POST_CLOSE, DIRTY_CHANGED
saveables - The affected saveables
force - true if the event type is PRE_CLOSE and this is a closed force that cannot be canceled.
Method Detail

getEventType

public int getEventType()
Returns the eventType, currently one of POST_OPEN, PRE_CLOSE, POST_CLOSE, DIRTY_CHANGED. Listeners should silently ignore unknown event types since new event types might be added in the future.

Returns:
the eventType

getSaveables

public 
Saveable[] getSaveables()
Returns the affected saveables.

Returns:
the saveables

isVeto

public boolean isVeto()
Returns the veto. This value is ignored for POST_OPEN,POST_CLOSE, and DIRTY_CHANGED.

Returns:
Returns the veto.

setVeto

public void setVeto(boolean veto)
Parameters:
veto - The veto to set.

isForce

public boolean isForce()
Sets the force flag. This value is ignored for POST_OPEN, POST_CLOSE, and DIRTY_CHANGED.

Returns:
Returns the force.

Eclipse Platform
Release 3.5

Guidelines for using Eclipse APIs.

Copyright (c) Eclipse contributors and others 2000, 2008. All rights reserved.


 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire