Class SplitIntersectedGraphArcsCommand<A extends org.eclipse.emf.ecore.EObject,AC extends org.eclipse.emf.ecore.EObject,AN extends org.eclipse.emf.ecore.EObject,ABP extends org.eclipse.emf.ecore.EObject,N extends org.eclipse.emf.ecore.EObject,NC extends org.eclipse.emf.ecore.EObject>
java.lang.Object
org.eclipse.emf.common.command.AbstractCommand
org.eclipse.emf.common.command.CompoundCommand
com.amalgamasimulation.graphicaleditor.commands.GraphicalEditorCompoundCommand
com.amalgamasimulation.graphicaleditor.commands.SplitIntersectedGraphArcsCommand<A,AC,AN,ABP,N,NC>
- All Implemented Interfaces:
org.eclipse.emf.common.command.Command
public class SplitIntersectedGraphArcsCommand<A extends org.eclipse.emf.ecore.EObject,AC extends org.eclipse.emf.ecore.EObject,AN extends org.eclipse.emf.ecore.EObject,ABP extends org.eclipse.emf.ecore.EObject,N extends org.eclipse.emf.ecore.EObject,NC extends org.eclipse.emf.ecore.EObject>
extends GraphicalEditorCompoundCommand
-
Nested Class Summary
Nested classes/interfaces inherited from class org.eclipse.emf.common.command.AbstractCommand
org.eclipse.emf.common.command.AbstractCommand.NonDirtying -
Field Summary
FieldsFields inherited from class com.amalgamasimulation.graphicaleditor.commands.GraphicalEditorCompoundCommand
initialized, redrawRestrictionManager, restrictRedrawFields inherited from class org.eclipse.emf.common.command.CompoundCommand
commandList, LAST_COMMAND_ALL, MERGE_COMMAND_ALL, resultIndexFields inherited from class org.eclipse.emf.common.command.AbstractCommand
description, isExecutable, isPrepared, label -
Constructor Summary
ConstructorsConstructorDescriptionSplitIntersectedGraphArcsCommand(InfiniteCanvasViewer viewer, BiPredicate<A, N> canSplitArcByNodePredicate) SplitIntersectedGraphArcsCommand(InfiniteCanvasViewer viewer, BiPredicate<A, N> canSplitArcByNodePredicate, double intersectionDistance) -
Method Summary
Modifier and TypeMethodDescriptionintvoidvoidsplitMineSegment(A arc, AbstractArcPart<A, AC, AN, ABP> dummyPart, AbstractNodePart<N, NC> nodePart, int entryIndex) voidsplitMineSegment(A arc, AbstractArcPart<A, AC, AN, ABP> dummyPart, AbstractNodePart<N, NC> nodePart, int entryIndex, Map<ABP, Double[]> bendpointCoordsCache) Methods inherited from class com.amalgamasimulation.graphicaleditor.commands.GraphicalEditorCompoundCommand
canExecute, canUndo, execute, redo, undoMethods inherited from class org.eclipse.emf.common.command.CompoundCommand
append, appendAndExecute, appendIfCanExecute, dispose, getAffectedObjects, getCommandList, getDescription, getLabel, getMergedAffectedObjectsCollection, getMergedResultCollection, getResult, getResultIndex, isEmpty, prepare, toString, unwrapMethods inherited from class org.eclipse.emf.common.command.AbstractCommand
chain, setDescription, setLabel
-
Field Details
-
DEFAULT_INTERSECTION_DISTANCE
public static double DEFAULT_INTERSECTION_DISTANCE
-
-
Constructor Details
-
SplitIntersectedGraphArcsCommand
public SplitIntersectedGraphArcsCommand(InfiniteCanvasViewer viewer, BiPredicate<A, N> canSplitArcByNodePredicate) -
SplitIntersectedGraphArcsCommand
public SplitIntersectedGraphArcsCommand(InfiniteCanvasViewer viewer, BiPredicate<A, N> canSplitArcByNodePredicate, double intersectionDistance)
-
-
Method Details
-
initialize
public void initialize()- Specified by:
initializein classGraphicalEditorCompoundCommand
-
splitMineSegment
public void splitMineSegment(A arc, AbstractArcPart<A, AC, AN, ABP> dummyPart, AbstractNodePart<N, NC> nodePart, int entryIndex) -
splitMineSegment
-
getSplittedSegmentsCount
public int getSplittedSegmentsCount() -
getViewer
-