MCPcopy Create free account
hub / github.com/MTrop/DoomTools / Context

Class Context

template/UtilityMain.java:90–121  ·  view source on GitHub ↗

Program context.

Source from the content-addressed store, hash-verified

88 * Program context.
89 */
90 private static class Context implements Callable<Integer>
91 {
92 private Options options;
93
94 private Context(Options options)
95 {
96 this.options = options;
97 }
98
99 @Override
100 public Integer call()
101 {
102 if (options.help)
103 {
104 splash(options.stdout);
105 usage(options.stdout);
106 options.stdout.println();
107 help(options.stdout);
108 return ERROR_NONE;
109 }
110
111 if (options.version)
112 {
113 splash(options.stdout);
114 return ERROR_NONE;
115 }
116
117 // TODO: Finish.
118
119 return ERROR_NONE;
120 }
121 }
122
123 /**
124 * Reads command line arguments and sets options.

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected