jtulach@8: package impl; jtulach@8: import api.API; jtulach@8: jtulach@8: // BEGIN: theory.binary.constants.impl jtulach@8: public class Impl extends API { jtulach@8: protected void init(int version) throws IllegalStateException { jtulach@8: if (version != API.VERSION) { jtulach@8: throw new IllegalStateException("Not the right API version error!"); jtulach@8: } jtulach@8: } jtulach@8: // END: theory.binary.constants.impl jtulach@8: jtulach@8: public static void main(String[] args) { jtulach@8: System.err.println("main expects version: " + API.VERSION); jtulach@8: new Impl(); jtulach@8: System.err.println("done for version: " + API.VERSION); jtulach@8: } jtulach@8: }