Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create an annotation system for block versioning #19

Open
magicDGS opened this issue Sep 15, 2017 · 0 comments
Open

Create an annotation system for block versioning #19

magicDGS opened this issue Sep 15, 2017 · 0 comments

Comments

@magicDGS
Copy link
Owner

After #18, we should create an annotation to indicate in block interfaces/implementations which methods are allowed for each version. Some ideas:

  • Interface methods specific for some version should have an annotation to provide the allowed versions for it. Programmatically, an API user can get the methods allowed for the block-version: the getVersion method from the block can be compared to the annotation versions; if the annotation is not present, all the versions can call the method.
  • Implementations for concrete blocks may contain an annotation for methods that are forbidden, because they may fail if they are called.
  • The implementation for the latest version of a concrete block should have another annotation, to be able to find the latest implementation. New files should be written always using the latest version of every block. The rest of the implementation is for backwards-compatibility with previous formats (reading and maintaining the format of the block if copied).

More ideas will come, but this is once the project is a bit more mature...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant