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
Answertopia.com

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

  




 

 


Eclipse PDE
Release 3.5

org.eclipse.pde.core
Interface IEditable

All Known Subinterfaces:
IEditableModel

public interface IEditable

Models that implement this interface indicate that they can be changed. When a model is changed, it becomes 'dirty'. This state can either be reset (in case of a 'false alarm' or naturally set to false as a result of saving the changes. Models that implement this interface are expected to be able to save in ASCII file format (e.g. XML).

Since:
2.0
Restriction:
This interface is not intended to be implemented by clients.
Restriction:
This interface is not intended to be extended by clients.

Method Summary
 boolean isDirty ()
          Tests whether the model has been changed from the last clean state.
 boolean isEditable ()
          Tests whether the model marked as editable can be edited.
 void save ( PrintWriter writer)
          Saves the model into the provided writer.
 void setDirty (boolean dirty)
          Sets the dirty flag of the model.
 

Method Detail

isEditable

boolean isEditable()
Tests whether the model marked as editable can be edited. Even though a model is generally editable, it can me marked as read-only because some condition prevents it from changing state (for example, the underlying resource is locked). While read-only models can never be changed, editable models can go in and out editable state during their life cycle.

Returns:
true if model can be modified, false otherwise.

isDirty

boolean isDirty()
Tests whether the model has been changed from the last clean state.

Returns:
true if the model has been changed and need saving

save

void save(
PrintWriter writer)
Saves the model into the provided writer. The assumption is that the model can be persisted in an ASCII output stream (for example, an XML file). This method should clear the 'dirty' flag when done.

Parameters:
writer - an object that should be used to write ASCII representation of the model

setDirty

void setDirty(boolean dirty)
Sets the dirty flag of the model. This method is normally not intended to be used outside the model. Most often, a dirty model should be saved to clear the flag.

Parameters:
dirty - a new value for the 'dirty' flag

Eclipse PDE
Release 3.5

Copyright (c) IBM Corp. and others 2000, 2008. All Rights Reserved.

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