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 Platform
Release 3.5

org.eclipse.compare
Interface IEditableContent

All Known Implementing Classes:
DocumentRangeNode, ResourceNode, StructureRootNode

public interface IEditableContent

Common interface for objects with editable contents. Typically it is implemented by objects that also implement the IStreamContentAccessor interface.

Clients may implement this interface.

Note that implementing IEditableContent does not automatically mean that it is editable. An object is only editable if it implements IEditableContent and the isEditable method returns true.

See Also:
IStreamContentAccessor

Method Summary
 boolean isEditable ()
          Returns true if this object can be modified.
  ITypedElement replace ( ITypedElement dest, ITypedElement src)
          This method is called on a parent to add or remove a child, or to copy the contents of a child.
 void setContent (byte[] newContent)
          Replaces the current content with the given new bytes.
 

Method Detail

isEditable

boolean isEditable()
Returns true if this object can be modified. If it returns false the other methods of this API must not be called.

Returns:
true if this object can be modified

setContent

void setContent(byte[] newContent)
Replaces the current content with the given new bytes.

Parameters:
newContent - this new contents replaces the old contents

replace


ITypedElement replace(
ITypedElement dest,
                      
ITypedElement src)
This method is called on a parent to add or remove a child, or to copy the contents of a child. What to do is encoded in the two arguments as follows:
add: dest == null src != null
remove: dest != null src == null
copy: dest != null src != null

Parameters:
dest - the existing child of this object to be replaced; if null a new child can be added.
src - the new child to be added or replaced; if null an existing child can be removed.
Returns:
the argument dest

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