Revision 2786 org.gvsig.vectorediting/trunk/org.gvsig.vectorediting/org.gvsig.vectorediting.lib/org.gvsig.vectorediting.lib.prov/org.gvsig.vectorediting.lib.prov.split/src/main/java/org/gvsig/vectorediting/lib/prov/split/operation/ArcSplitOperation.java
ArcSplitOperation.java | ||
---|---|---|
32 | 32 |
import org.gvsig.fmap.geom.GeometryManager; |
33 | 33 |
import org.gvsig.fmap.geom.aggregate.MultiCurve; |
34 | 34 |
import org.gvsig.fmap.geom.aggregate.MultiPoint; |
35 |
import org.gvsig.fmap.geom.complex.Complex; |
|
35 | 36 |
import org.gvsig.fmap.geom.exception.CreateGeometryException; |
36 | 37 |
import org.gvsig.fmap.geom.operation.GeometryOperationException; |
37 | 38 |
import org.gvsig.fmap.geom.operation.GeometryOperationNotSupportedException; |
... | ... | |
73 | 74 |
|
74 | 75 |
if (intersections == null) { |
75 | 76 |
return geometryToBeSplitted; |
76 |
} else if (intersections instanceof Point) { |
|
77 |
} |
|
78 |
|
|
79 |
if (intersections instanceof Complex) { |
|
80 |
intersections = ((Complex) intersections).createAggregate( |
|
81 |
Geometry.TYPES.MULTIPOINT, |
|
82 |
(Geometry t) -> t.getGeometryType().getType() == Geometry.TYPES.MULTIPOINT || t.getGeometryType().getType() == Geometry.TYPES.POINT |
|
83 |
); |
|
84 |
} |
|
85 |
|
|
86 |
if (intersections instanceof Point) { |
|
77 | 87 |
|
78 | 88 |
if(isClosed(arcToBeSplitted)){ // Closed arcs can be splitted by one point |
79 | 89 |
return arcToBeSplitted; |
Also available in: Unified diff