Skip to content

Commit 43ece88

Browse files
authored
Remove duplicate interface (#237)
1 parent 8e390b9 commit 43ece88

3 files changed

Lines changed: 28 additions & 117 deletions

File tree

src/main/java/com/esri/core/geometry/DirtyFlags.java

Lines changed: 0 additions & 64 deletions
This file was deleted.

src/main/java/com/esri/core/geometry/EditShape.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -718,7 +718,7 @@ Geometry getGeometry(int geometry) {
718718

719719
mp_impl.setPathFlagsStreamRef(pathFlags);
720720
mp_impl.setPathStreamRef(parts);
721-
mp_impl.notifyModified(DirtyFlags.dirtyAll);
721+
mp_impl.notifyModified(MultiVertexGeometryImpl.DirtyFlags.DirtyAll);
722722
} else if (gt == Geometry.GeometryType.MultiPoint) {
723723
MultiPointImpl mp_impl = (MultiPointImpl) geom._getImpl();
724724
VertexDescription description = geom.getDescription();
@@ -751,7 +751,7 @@ Geometry getGeometry(int geometry) {
751751
mp_impl.setAttributeStreamRef(semantics, dst_stream);
752752
}
753753

754-
mp_impl.notifyModified(DirtyFlags.dirtyAll);
754+
mp_impl.notifyModified(MultiVertexGeometryImpl.DirtyFlags.DirtyAll);
755755
} else {
756756
assert (false);
757757
}

src/main/java/com/esri/core/geometry/MultiVertexGeometryImpl.java

Lines changed: 26 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -63,52 +63,34 @@ public interface GeometryXSimple {
6363
protected abstract void _verifyStreamsImpl();
6464

6565
public interface DirtyFlags {
66-
public static final int DirtyIsKnownSimple = 1; // !<0 when IsWeakSimple
67-
// flag is valid
68-
public static final int IsWeakSimple = 2; // !<when DirtyIsKnownSimple
69-
// is 0, this flag indicates
70-
// whether the geometry is
71-
// weak simple or not
72-
public static final int IsStrongSimple = 4;
73-
public static final int DirtyOGCFlags = 8; // !<OGCFlags are set by
74-
// Simplify or WKB/WKT
75-
// import.
76-
77-
public static final int DirtyVerifiedStreams = 32; // < at least one
78-
// stream is
79-
// unverified
80-
public static final int DirtyExactIntervals = 64; // < exact envelope is
81-
// dirty
82-
public static final int DirtyLooseIntervals = 128;
83-
public static final int DirtyIntervals = DirtyExactIntervals
84-
| DirtyLooseIntervals; // <
85-
// loose
86-
// and
87-
// dirty
88-
// envelopes
89-
// are
90-
// loose
91-
public static final int DirtyIsEnvelope = 256; // < the geometry is not
92-
// known to be an
93-
// envelope
94-
public static final int DirtyLength2D = 512; // < the geometry length
95-
// needs update
96-
// update
97-
public static final int DirtyRingAreas2D = 1024; // <
98-
// m_cachedRingAreas2D
99-
// need update
100-
public static final int DirtyCoordinates = DirtyIsKnownSimple
66+
/**0 when IsWeakSimple flag is valid*/
67+
int DirtyIsKnownSimple = 1;
68+
/**when DirtyIsKnownSimple is 0, this flag indicates whether the geometry is weak simple or not*/
69+
int IsWeakSimple = 2;
70+
int IsStrongSimple = 4;
71+
/**OGCFlags are set by Simplify or WKB/WKT import.*/
72+
int DirtyOGCFlags = 8;
73+
/** At least one stream is unverified*/
74+
int DirtyVerifiedStreams = 32;
75+
/** exact envelope is dirty*/
76+
int DirtyExactIntervals = 64;
77+
/** loose envelope is dirty*/
78+
int DirtyLooseIntervals = 128;
79+
/** loose and dirty envelopes are dirty */
80+
int DirtyIntervals = DirtyExactIntervals
81+
| DirtyLooseIntervals;
82+
/**the geometry is not known to be an envelope*/
83+
int DirtyIsEnvelope = 256;
84+
/** The geometry length needs update*/
85+
int DirtyLength2D = 512;
86+
/** m_cachedRingAreas2D need update*/
87+
int DirtyRingAreas2D = 1024;
88+
int DirtyCoordinates = DirtyIsKnownSimple
10189
| DirtyIntervals | DirtyIsEnvelope | DirtyLength2D
10290
| DirtyRingAreas2D | DirtyOGCFlags;
103-
public static final int DirtyAllInternal = 0xFFFF; // there has been no
104-
// change to the
105-
// streams from
106-
// outside.
107-
public static final int DirtyAll = 0xFFFFFF; // there has been a change
108-
// to one of attribute
109-
// streams from the
110-
// outside.
111-
91+
int DirtyAllInternal = 0xFFFF;
92+
/** There has been a change to one of attribute streams from the outside.*/
93+
int DirtyAll = 0xFFFFFF;
11294
}
11395

11496
/**
@@ -169,10 +151,6 @@ protected void throwIfEmpty() {
169151
protected int m_flagsMask;
170152
protected double m_simpleTolerance;
171153

172-
// HEADER DEFINED
173-
174-
// Cpp
175-
// Checked vs. Jan 11, 2011
176154
public MultiVertexGeometryImpl() {
177155
m_flagsMask = DirtyFlags.DirtyAllInternal;
178156
m_pointCount = 0;
@@ -186,9 +164,6 @@ public void getPointByVal(int index, Point dst) {
186164
// TODO
187165
throw new GeometryException("index out of bounds");
188166

189-
// _ASSERT(!IsEmpty());
190-
// _ASSERT(m_vertexAttributes != null);
191-
192167
_verifyAllStreams();
193168

194169
Point outPoint = dst;

0 commit comments

Comments
 (0)