sk.uniba.euromath.editor.textEditor
Class TextEditPartFactory

java.lang.Object
  extended by sk.uniba.euromath.editor.xmlEditor.XMLEditPartFactory
      extended by sk.uniba.euromath.editor.textEditor.TextEditPartFactory
All Implemented Interfaces:
org.eclipse.gef.EditPartFactory

public class TextEditPartFactory
extends XMLEditPartFactory

Author:
Martin Kollar 28.9.2005

Field Summary
protected  CaretManager caretManager
          Manager that cares about Caret
 
Constructor Summary
TextEditPartFactory(XMLAccess xmlAccess, CaretManager cManager, org.eclipse.gef.GraphicalViewer graphicalViewer)
          Constructor.
 
Method Summary
 void clearIdLastContainerMap()
          Clears map containing last created container for id of node
 org.eclipse.gef.EditPart createEditPart(org.eclipse.gef.EditPart context, Object model)
          Creates TextEditPart for ITextLocator, sets container for it and updates visual info or call super for another model.
protected  TextEditPart createTextEditPart(ITextLocator figure)
          Creates edit part expected for ITextLocator figure.
 org.eclipse.gef.GraphicalViewer getGraphicalViewer()
           
 Map<String,TextPieceContainer> getIdLastContainerMap()
          Map containing last created container for id of node.
 sk.baka.ikslibs.ids.IDManager getIdManager()
          Returns id manager.
protected  XMLAccess getXmlAccess()
           
 
Methods inherited from class sk.uniba.euromath.editor.xmlEditor.XMLEditPartFactory
getVisualInfo, updateVisualInfo
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

caretManager

protected final CaretManager caretManager
Manager that cares about Caret

Constructor Detail

TextEditPartFactory

public TextEditPartFactory(XMLAccess xmlAccess,
                           CaretManager cManager,
                           org.eclipse.gef.GraphicalViewer graphicalViewer)
Constructor.

Parameters:
xmlAccess - xml access instance
cManager - CaretManager
graphicalViewer - graphical viewer reference
Method Detail

getIdManager

public sk.baka.ikslibs.ids.IDManager getIdManager()
Returns id manager.

Returns:
manager of node's ids

getXmlAccess

protected XMLAccess getXmlAccess()
Returns:
Returns the xmlAccess.

createTextEditPart

protected TextEditPart createTextEditPart(ITextLocator figure)
Creates edit part expected for ITextLocator figure. This implementation creates TextEditPart. If is expected another edit part extended from TextEditPart, override.

Parameters:
figure - ITextLocator figure
Returns:
edit part for figure

createEditPart

public org.eclipse.gef.EditPart createEditPart(org.eclipse.gef.EditPart context,
                                               Object model)
Creates TextEditPart for ITextLocator, sets container for it and updates visual info or call super for another model.

Specified by:
createEditPart in interface org.eclipse.gef.EditPartFactory
Overrides:
createEditPart in class XMLEditPartFactory
Parameters:
context - parent EditPart
model - figure for which editPart should be created

getGraphicalViewer

public org.eclipse.gef.GraphicalViewer getGraphicalViewer()
Returns:
Returns the graphicalViewer.

getIdLastContainerMap

public Map<String,TextPieceContainer> getIdLastContainerMap()
Map containing last created container for id of node.

Returns:
map:

clearIdLastContainerMap

public void clearIdLastContainerMap()
Clears map containing last created container for id of node



Copyright © 2003-2006 null. All Rights Reserved.