Giter VIP home page Giter VIP logo

agnostic-savior_java's Introduction

Agnostic Savior (Java)

What is it?

Agnostic Savior is a simple scheme for saving and loading Object Oriented data in a programming language agnostic JSON format.

What is it Useful For?

Porting Mostly. For example, say you want to port some java program or library into another language. Ideally, you'd like to test to make sure that results of the Java program are the same as the results of your port, or vice-versa. You could of course do this reductively, making sure that every part behaves as intended, thereby presumably ensuring that the whole does as well, but when the whole doesn't regardless, it might be helpful to check a whole save state in the original against a whole state in your port.

Beyond that, it's probably useful if you want to save and load stuff from and into your Java program, but don't want to spend a lot of time figuring out a structure for a file format. (You could, of course, also use the Java Serializable class. This library is for situations where you'd prefer not to).

I'm Sold. How do I use it?

To every class you want to save, implement the `Saveable` interface offered by this library. To each class implementing the `Saveable` interface, add the following method

@Override
makeSaveable(Savemanager s) { 
  someObjectThisDependsOn.makeSaveable(s); 
  someOtherObjectThisDependsOn.makeSaveable(s);
  anotherObjectThisDependsOn.makeSaveable(s); 
  s.addToSaveState(this); 
}

agnostic-savior_java's People

Contributors

egjoni avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.