Skip to content
GitLab
Explore
Projects
Groups
Snippets
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
CityDoctor
CityDoctor2
Commits
30f13b06
Commit
30f13b06
authored
3 weeks ago
by
Riegel
Browse files
Options
Download
Email Patches
Plain Diff
Docs: Add Javadoc
parent
1cf6605c
master
dev
dev_gui_features_zip_loading
archive/dev_gui_features_zip_loading
2 merge requests
!28
Version 3.17.0 Release
,
!26
Add ZIP-archive support
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
CityDoctorParent/CityDoctorModel/src/main/java/de/hft/stuttgart/citydoctor2/zip/CityGmlZipEntryFile.java
+2
-2
...de/hft/stuttgart/citydoctor2/zip/CityGmlZipEntryFile.java
CityDoctorParent/CityDoctorModel/src/main/java/de/hft/stuttgart/citydoctor2/zip/MalformedZipFileException.java
+3
-0
.../stuttgart/citydoctor2/zip/MalformedZipFileException.java
CityDoctorParent/Extensions/CityDoctorGUI/src/main/java/de/hft/stuttgart/citydoctor2/gui/CheckDialog.java
+5
-0
...in/java/de/hft/stuttgart/citydoctor2/gui/CheckDialog.java
CityDoctorParent/Extensions/CityDoctorGUI/src/main/java/de/hft/stuttgart/citydoctor2/gui/ZipEntryManager.java
+3
-4
...ava/de/hft/stuttgart/citydoctor2/gui/ZipEntryManager.java
with
13 additions
and
6 deletions
+13
-6
CityDoctorParent/CityDoctorModel/src/main/java/de/hft/stuttgart/citydoctor2/zip/CityGmlZipEntryFile.java
+
2
-
2
View file @
30f13b06
...
...
@@ -42,7 +42,7 @@ public class CityGmlZipEntryFile implements AutoCloseable {
*/
public
InputStream
getInputStream
()
throws
IOException
{
if
(
closed
){
throw
new
IOException
(
"
Stream
closed"
);
throw
new
IOException
(
"
CityGmlZipEntryFile
closed"
);
}
return
zip
.
getInputStream
(
zipEntry
);
}
...
...
@@ -54,7 +54,7 @@ public class CityGmlZipEntryFile implements AutoCloseable {
*/
public
long
getFileSize
()
throws
IOException
{
if
(
closed
){
throw
new
IOException
(
"
Stream
closed"
);
throw
new
IOException
(
"
CityGmlZipEntryFile
closed"
);
}
if
(
cgmlZipEntry
.
getFileSize
()
==
-
1L
)
{
if
(
zipEntry
.
getSize
()
==
-
1
)
{
...
...
This diff is collapsed.
Click to expand it.
CityDoctorParent/CityDoctorModel/src/main/java/de/hft/stuttgart/citydoctor2/zip/MalformedZipFileException.java
+
3
-
0
View file @
30f13b06
...
...
@@ -2,6 +2,9 @@ package de.hft.stuttgart.citydoctor2.zip;
import
java.util.zip.ZipException
;
/**
* Signals that a ZIP-file is corrupted and couldn't be parsed.
*/
public
class
MalformedZipFileException
extends
ZipException
{
public
MalformedZipFileException
()
{
...
...
This diff is collapsed.
Click to expand it.
CityDoctorParent/Extensions/CityDoctorGUI/src/main/java/de/hft/stuttgart/citydoctor2/gui/CheckDialog.java
+
5
-
0
View file @
30f13b06
...
...
@@ -316,6 +316,11 @@ public class CheckDialog {
showZipArchiveOptions
(
false
);
}
/**
* Shows the option panel for ZIP-Archive checking and enables the ZIP-Archive checking mode for this dialog.
*
* @param enabled
*/
public
void
showZipArchiveOptions
(
boolean
enabled
)
{
zipArchiveOptionsVBox
.
setDisable
(!
enabled
);
zipArchiveOptionsVBox
.
setVisible
(
enabled
);
...
...
This diff is collapsed.
Click to expand it.
CityDoctorParent/Extensions/CityDoctorGUI/src/main/java/de/hft/stuttgart/citydoctor2/gui/ZipEntryManager.java
+
3
-
4
View file @
30f13b06
...
...
@@ -34,6 +34,9 @@ import java.io.IOException;
import
java.io.InputStream
;
import
java.util.function.Predicate
;
/**
* This class implements a GUI for managing a loaded {@link CityGmlZipArchive} in CityDoctor.
*/
public
class
ZipEntryManager
{
private
static
final
Logger
logger
=
LogManager
.
getLogger
(
ZipEntryManager
.
class
);
...
...
@@ -217,10 +220,6 @@ public class ZipEntryManager {
}
CityGmlZipEntry
entry
=
entryList
.
getSelectionModel
().
getSelectedItem
().
getEntry
();
if
(
entry
.
getErrorType
()
!=
null
)
{
/**
* Button should be disabled when an erroneous entry gets selected.
* Silently fail in case an erroneous entry is somehow selected on Action.
*/
logger
.
debug
(
"IllegalState: loadBtn was pressed while an erroneous entry was selected"
);
populateZipEntryList
(
selectedIndex
);
return
;
...
...
This diff is collapsed.
Click to expand it.
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
Menu
Explore
Projects
Groups
Snippets