com.japisoft.xmlpad.editor
Interface Editor

All Known Implementing Classes:
DefaultEditor

public interface Editor

This Editor is a contract for editing any node. An editor has two roles : - Decide if this editor accept a node - Edit it using an EditorContext state

Important element : This editor is not an XMLEditor but only and add-one for editing a particular node. This is useful when you want a custom editor better adatper to user need

Author:
(c) 2003 JAPISOFT / Alexandre Brillant
See Also:
EditorContext

Method Summary
 boolean accept(com.japisoft.fastparser.node.SimpleNode node)
           
 void edit(EditorContext context)
          Edit a particular text context.
 

Method Detail

accept

public boolean accept(com.japisoft.fastparser.node.SimpleNode node)
Returns:
true when this editor accepts to edit this node

edit

public void edit(EditorContext context)
Edit a particular text context. This context contains the current text and node to edit. You must call the setResult once you terminate the custom editing part. If you don't want to edit it, just write a null result.

Parameters:
context - Editing context