de.soldin.gt2jump.cts
Class UndoableSetGeometry

java.lang.Object
  extended byjavax.swing.undo.AbstractUndoableEdit
      extended byde.soldin.gt2jump.cts.UndoableSetGeometry
All Implemented Interfaces:
Collection, Serializable, UndoableEdit

public class UndoableSetGeometry
extends AbstractUndoableEdit
implements Collection

The UndoableSetGeometry is a implementation of a Collection, as well as a AbstractUndoableEdit. The purpose is to have an undoable swing component for modifying geometries.

With these capabilities joined it can act as a container for multiple UndoableSetGeometry objects, which can be executed in a batch and as a single action.

Attention: This class differs from UndoableSetGeometry as it specializes in applying CSSettings on the appropriate layer. So the more generic one is UndoableSetGeometry.

See Also:
Serialized Form

Constructor Summary
UndoableSetGeometry(String name)
           
UndoableSetGeometry(String prefix, String name)
           
UndoableSetGeometry(String prefix, String name, CSSetting css)
           
 
Method Summary
 boolean add(Object o)
           
 boolean add(UndoableSetGeometry t)
           
 boolean addAll(Collection c)
           
 void clear()
           
 boolean contains(Object o)
           
 boolean containsAll(Collection c)
           
 void execute()
           
 com.vividsolutions.jts.geom.Geometry getGeom(com.vividsolutions.jump.feature.Feature in_feature)
           
 String getName_prefix()
           
 String getName()
           
 String getPresentationName()
           
 String getRedoPresentationName()
           
 String getUndoPresentationName()
           
 boolean isEmpty()
           
 Iterator iterator()
           
 void redo()
           
 boolean remove(Object o)
           
 boolean removeAll(Collection c)
           
 boolean retainAll(Collection c)
           
 void setGeom(com.vividsolutions.jump.feature.Feature feature, com.vividsolutions.jts.geom.Geometry geom)
           
 void setName_prefix(String string)
           
 int size()
           
 Object[] toArray()
           
 Object[] toArray(Object[] a)
           
 void undo()
           
 void unexecute()
           
 
Methods inherited from class javax.swing.undo.AbstractUndoableEdit
addEdit, canRedo, canUndo, die, isSignificant, replaceEdit, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.Collection
equals, hashCode
 

Constructor Detail

UndoableSetGeometry

public UndoableSetGeometry(String name)

UndoableSetGeometry

public UndoableSetGeometry(String prefix,
                           String name)

UndoableSetGeometry

public UndoableSetGeometry(String prefix,
                           String name,
                           CSSetting css)
Method Detail

redo

public void redo()
Specified by:
redo in interface UndoableEdit

undo

public void undo()
Specified by:
undo in interface UndoableEdit

getPresentationName

public String getPresentationName()
Specified by:
getPresentationName in interface UndoableEdit

getUndoPresentationName

public String getUndoPresentationName()
Specified by:
getUndoPresentationName in interface UndoableEdit

getRedoPresentationName

public String getRedoPresentationName()
Specified by:
getRedoPresentationName in interface UndoableEdit

execute

public void execute()

unexecute

public void unexecute()

getName

public String getName()

getName_prefix

public String getName_prefix()

setName_prefix

public void setName_prefix(String string)

setGeom

public void setGeom(com.vividsolutions.jump.feature.Feature feature,
                    com.vividsolutions.jts.geom.Geometry geom)

getGeom

public com.vividsolutions.jts.geom.Geometry getGeom(com.vividsolutions.jump.feature.Feature in_feature)

add

public boolean add(UndoableSetGeometry t)

size

public int size()
Specified by:
size in interface Collection

clear

public void clear()
Specified by:
clear in interface Collection

isEmpty

public boolean isEmpty()
Specified by:
isEmpty in interface Collection

toArray

public Object[] toArray()
Specified by:
toArray in interface Collection

add

public boolean add(Object o)
Specified by:
add in interface Collection

contains

public boolean contains(Object o)
Specified by:
contains in interface Collection

remove

public boolean remove(Object o)
Specified by:
remove in interface Collection

addAll

public boolean addAll(Collection c)
Specified by:
addAll in interface Collection

containsAll

public boolean containsAll(Collection c)
Specified by:
containsAll in interface Collection

removeAll

public boolean removeAll(Collection c)
Specified by:
removeAll in interface Collection

retainAll

public boolean retainAll(Collection c)
Specified by:
retainAll in interface Collection

iterator

public Iterator iterator()
Specified by:
iterator in interface Collection

toArray

public Object[] toArray(Object[] a)
Specified by:
toArray in interface Collection