Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
CityDoctor
CityDoctor2
Commits
3f3f5672
Commit
3f3f5672
authored
Apr 15, 2025
by
Riegel
Browse files
Refactor: Implement prepareForChecking with Visitor
parent
67214f92
Changes
29
Hide whitespace changes
Inline
Side-by-side
CityDoctorParent/CityDoctorModel/src/main/java/de/hft/stuttgart/citydoctor2/datastructure/ReliefObject.java
View file @
3f3f5672
...
@@ -75,13 +75,6 @@ public class ReliefObject extends CityObject {
...
@@ -75,13 +75,6 @@ public class ReliefObject extends CityObject {
return
new
ReliefObject
(
feature
);
return
new
ReliefObject
(
feature
);
}
}
@Override
public
void
prepareForChecking
()
{
for
(
TinObject
component
:
components
)
{
component
.
prepareForChecking
();
}
}
@Override
@Override
public
void
clearMetaInformation
()
{
public
void
clearMetaInformation
()
{
for
(
TinObject
component
:
components
)
{
for
(
TinObject
component
:
components
)
{
...
...
CityDoctorParent/CityDoctorModel/src/main/java/de/hft/stuttgart/citydoctor2/datastructure/Storey.java
View file @
3f3f5672
...
@@ -85,14 +85,6 @@ public class Storey extends AbstractBuildingSubdivision {
...
@@ -85,14 +85,6 @@ public class Storey extends AbstractBuildingSubdivision {
return
false
;
return
false
;
}
}
@Override
public
void
prepareForChecking
()
{
super
.
prepareForChecking
();
for
(
BuildingUnit
buildingUnit
:
buildingUnits
)
{
buildingUnit
.
prepareForChecking
();
}
}
@Override
@Override
public
void
clearMetaInformation
()
{
public
void
clearMetaInformation
()
{
super
.
clearMetaInformation
();
super
.
clearMetaInformation
();
...
...
CityDoctorParent/CityDoctorModel/src/main/java/de/hft/stuttgart/citydoctor2/datastructure/TopLevelTransportFeature.java
View file @
3f3f5672
...
@@ -173,16 +173,6 @@ public class TopLevelTransportFeature extends TransportationSpace {
...
@@ -173,16 +173,6 @@ public class TopLevelTransportFeature extends TransportationSpace {
return
"TopLevelTransportFeature [id="
+
getGmlId
()
+
"]"
;
return
"TopLevelTransportFeature [id="
+
getGmlId
()
+
"]"
;
}
}
@Override
public
void
prepareForChecking
()
{
super
.
prepareForChecking
();
for
(
TransportSection
section
:
sections
)
{
section
.
prepareForChecking
();
}
for
(
TransportSection
section
:
intersections
)
{
section
.
prepareForChecking
();
}
}
@Override
@Override
public
void
clearMetaInformation
()
{
public
void
clearMetaInformation
()
{
...
...
CityDoctorParent/CityDoctorModel/src/main/java/de/hft/stuttgart/citydoctor2/datastructure/TrafficSpaceObject.java
View file @
3f3f5672
...
@@ -155,13 +155,6 @@ public class TrafficSpaceObject extends TransportationObject {
...
@@ -155,13 +155,6 @@ public class TrafficSpaceObject extends TransportationObject {
return
"TransportationSpaceObject [id="
+
getGmlId
()
+
"]"
;
return
"TransportationSpaceObject [id="
+
getGmlId
()
+
"]"
;
}
}
@Override
public
void
prepareForChecking
()
{
super
.
prepareForChecking
();
for
(
TrafficAreaObject
tao
:
trafficAreas
)
{
tao
.
prepareForChecking
();
}
}
@Override
@Override
public
void
clearMetaInformation
()
{
public
void
clearMetaInformation
()
{
...
...
CityDoctorParent/CityDoctorModel/src/main/java/de/hft/stuttgart/citydoctor2/datastructure/TransportationSpace.java
View file @
3f3f5672
...
@@ -193,16 +193,6 @@ public abstract class TransportationSpace extends TransportationObject {
...
@@ -193,16 +193,6 @@ public abstract class TransportationSpace extends TransportationObject {
return
"TransportationSpace [id="
+
getGmlId
()
+
"]"
;
return
"TransportationSpace [id="
+
getGmlId
()
+
"]"
;
}
}
@Override
public
void
prepareForChecking
()
{
super
.
prepareForChecking
();
for
(
TrafficSpaceObject
to
:
trafficSpaces
)
{
to
.
prepareForChecking
();
}
for
(
TrafficSpaceObject
to
:
auxTrafficSpaces
)
{
to
.
prepareForChecking
();
}
}
@Override
@Override
public
void
clearMetaInformation
()
{
public
void
clearMetaInformation
()
{
...
...
CityDoctorParent/CityDoctorModel/src/main/java/de/hft/stuttgart/citydoctor2/datastructure/Tunnel.java
View file @
3f3f5672
...
@@ -128,14 +128,6 @@ public class Tunnel extends AbstractTunnel {
...
@@ -128,14 +128,6 @@ public class Tunnel extends AbstractTunnel {
}
}
}
}
@Override
public
void
prepareForChecking
()
{
super
.
prepareForChecking
();
for
(
TunnelPart
tp
:
tunnelParts
)
{
tp
.
prepareForChecking
();
}
}
@Override
@Override
public
void
fillValues
(
Copyable
original
,
CopyHandler
handler
)
{
public
void
fillValues
(
Copyable
original
,
CopyHandler
handler
)
{
super
.
fillValues
(
original
,
handler
);
super
.
fillValues
(
original
,
handler
);
...
...
CityDoctorParent/CityDoctorModel/src/main/java/de/hft/stuttgart/citydoctor2/datastructure/TunnelConstructiveElement.java
View file @
3f3f5672
...
@@ -218,13 +218,6 @@ public class TunnelConstructiveElement extends CityObject {
...
@@ -218,13 +218,6 @@ public class TunnelConstructiveElement extends CityObject {
return
boundarySurfaceList
;
return
boundarySurfaceList
;
}
}
@Override
public
void
prepareForChecking
()
{
super
.
prepareForChecking
();
for
(
BoundarySurface
bs
:
boundarySurfaceList
)
{
bs
.
prepareForChecking
();
}
}
@Override
@Override
public
void
clearMetaInformation
()
{
public
void
clearMetaInformation
()
{
...
...
CityDoctorParent/CityDoctorModel/src/main/java/de/hft/stuttgart/citydoctor2/datastructure/WaterObject.java
View file @
3f3f5672
...
@@ -170,12 +170,5 @@ public class WaterObject extends CityObject {
...
@@ -170,12 +170,5 @@ public class WaterObject extends CityObject {
}
}
}
}
@Override
public
void
prepareForChecking
()
{
super
.
prepareForChecking
();
for
(
BoundarySurface
bs
:
boundarySurfaceList
)
{
bs
.
prepareForChecking
();
}
}
}
}
CityDoctorParent/CityDoctorModel/src/main/java/de/hft/stuttgart/citydoctor2/utils/visitors/PrepareForCheckingVisitor.java
0 → 100644
View file @
3f3f5672
package
de.hft.stuttgart.citydoctor2.utils.visitors
;
import
de.hft.stuttgart.citydoctor2.check.AbstractCheck
;
import
de.hft.stuttgart.citydoctor2.datastructure.Geometry
;
import
de.hft.stuttgart.citydoctor2.datastructure.LinearRing
;
import
de.hft.stuttgart.citydoctor2.datastructure.Polygon
;
public
class
PrepareForCheckingVisitor
extends
AbstractCheck
{
@Override
public
void
check
(
Geometry
geom
)
{
geom
.
updateEdgesAndVertices
();
}
@Override
public
void
check
(
Polygon
poly
)
{
poly
.
prepareLowMemoryUsageMode
();
}
@Override
public
void
check
(
LinearRing
ring
)
{
ring
.
prepareLowMemoryUsageMode
();
}
}
Prev
1
2
Next
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment