MCPcopy Create free account
hub / github.com/apache/mesos / names

Method names

src/java/src/org/apache/mesos/state/AbstractState.java:174–217  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

172 }
173
174 public Future<Iterator<String>> names() {
175 if (!MesosNativeLibrary.version().before(MESOS_2161_JIRA_FIX_VERSION)) {
176 return new NamesFuture();
177 }
178
179 // TODO(jmlvanre): Deprecate anonymous future in 0.24 (MESOS-2161).
180 final long future = __names(); // Asynchronously start the operation.
181 return new Future<Iterator<String>>() {
182 @Override
183 public boolean cancel(boolean mayInterruptIfRunning) {
184 if (mayInterruptIfRunning) {
185 return __names_cancel(future);
186 }
187 return false; // Should not interrupt and already running (or finished).
188 }
189
190 @Override
191 public boolean isCancelled() {
192 return __names_is_cancelled(future);
193 }
194
195 @Override
196 public boolean isDone() {
197 return __names_is_done(future);
198 }
199
200 @Override
201 public Iterator<String> get() throws InterruptedException,
202 ExecutionException {
203 return __names_get(future);
204 }
205
206 @Override
207 public Iterator<String> get(long timeout, TimeUnit unit)
208 throws InterruptedException, ExecutionException, TimeoutException {
209 return __names_get_timeout(future, timeout, unit);
210 }
211
212 @Override
213 protected void finalize() {
214 __names_finalize(future);
215 }
216 };
217 }
218
219 protected native void finalize();
220

Callers

nothing calls this directly

Calls 2

__namesMethod · 0.95
versionMethod · 0.80

Tested by

no test coverage detected