Skip to content

Refactored amidst.mojangapi.file#331

Merged
stefandollase merged 48 commits into
masterfrom
refactored-amidst.mojangapi.file
Jun 2, 2017
Merged

Refactored amidst.mojangapi.file#331
stefandollase merged 48 commits into
masterfrom
refactored-amidst.mojangapi.file

Conversation

@stefandollase
Copy link
Copy Markdown
Contributor

This splits the classes in amidst.mojangapi.file into:

  • simple data abstraction classes to hold json, directory or nbt information, these contain no domain logic
  • service classes for the domain logic
  • facade classes to provide a clean interface to users of the package

This also replaces the meaningless class MojangApi by more meaningful classes.

Finally, the version list download mechanism has been reworked, so when Amidst is started initially, the local version list is used and the download of the up-to-date remote version list is started. As soon as the remote version list is available, it will be used instead. This prevents Amidst from "hanging" on startup when it has to wait for a server response.


This should not interfere too much with #169, since most of the changes are in different classes. However, the package amidst.mojangapi.file.json.filter does not really belong into the amidst.mojangapi.file package, since the seed search json file format is not provided by Mojang. Instead, we should probably create a separate package amidst.seedsearch which contains all seed search related stuff. I did not do this in this PR to prevent conflicts with #169.

... instead of the MojangApiParsingException. This enables the usage of the JsonReader to parse json that was not provided by Mojang.
... not sure if it was implicitly required before
@stefandollase stefandollase added this to the v4.3 milestone Jun 2, 2017
@stefandollase stefandollase self-assigned this Jun 2, 2017
@stefandollase stefandollase merged commit 5012b08 into master Jun 2, 2017
@stefandollase stefandollase deleted the refactored-amidst.mojangapi.file branch June 2, 2017 14:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant