Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
CityDoctor
CityDoctor2
Commits
358dfea5
Commit
358dfea5
authored
May 16, 2023
by
Matthias Betz
Browse files
Add option to not store quality ade
parent
63f5261a
Changes
3
Hide whitespace changes
Inline
Side-by-side
CityDoctorParent/CityDoctorModel/src/main/java/de/hft/stuttgart/citydoctor2/datastructure/CityDoctorModel.java
View file @
358dfea5
...
...
@@ -123,11 +123,18 @@ public class CityDoctorModel {
water
.
stream
()).
flatMap
(
co
->
co
);
}
public
void
saveAs
(
String
file
)
throws
CityDoctorWriteException
{
public
void
saveAs
(
String
file
,
boolean
saveQualityAde
)
throws
CityDoctorWriteException
{
if
(
file
.
endsWith
(
".off"
))
{
exportAsOff
(
file
);
}
else
{
ValidationPlan
tempPlan
=
plan
;
if
(!
saveQualityAde
)
{
setValidated
(
null
);
}
exportAsGML
(
file
);
if
(!
saveQualityAde
)
{
setValidated
(
tempPlan
);
}
}
}
...
...
CityDoctorParent/CityDoctorModel/src/test/java/de/hft/stuttgart/citydoctor2/datastructure/CityDoctorModelTest.java
View file @
358dfea5
...
...
@@ -140,7 +140,7 @@ public class CityDoctorModelTest {
b
.
setGmlObject
(
gmlBuilding
);
model
.
addBuilding
(
b
);
File
saveFile
=
folder
.
newFile
();
model
.
saveAs
(
saveFile
.
getAbsolutePath
());
model
.
saveAs
(
saveFile
.
getAbsolutePath
()
,
true
);
assertTrue
(
saveFile
.
exists
());
assertTrue
(
saveFile
.
length
()
>
0
);
...
...
@@ -206,7 +206,7 @@ public class CityDoctorModelTest {
b
.
setGmlObject
(
gmlBuilding
);
model
.
addBuilding
(
b
);
File
saveFile
=
folder
.
newFile
();
model
.
saveAs
(
saveFile
.
getAbsolutePath
());
model
.
saveAs
(
saveFile
.
getAbsolutePath
()
,
true
);
assertTrue
(
saveFile
.
exists
());
assertTrue
(
saveFile
.
length
()
>
0
);
...
...
CityDoctorParent/CityDoctorValidation/src/main/java/de/hft/stuttgart/citydoctor2/CityDoctorValidation.java
View file @
358dfea5
...
...
@@ -176,7 +176,7 @@ public class CityDoctorValidation {
Checker
c
=
new
Checker
(
config
,
model
);
c
.
runChecks
(
xmlOutput
,
pdfOutput
,
null
);
if
(
outputFile
!=
null
)
{
model
.
saveAs
(
outputFile
);
model
.
saveAs
(
outputFile
,
true
);
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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