/* (non-Javadoc)
@see es.upm.dit.gsi.beast.platform.Connector#stopPlatform()
968090
@Override
    public void stopPlatform() {
        try {
            for (Entry<String, AgentController> e : this.createdAgents
                    .entrySet()) {
                AgentController ac = e.getValue();
                ac.kill();
            }
            for (Entry<String, ContainerController> e : this.platformContainers
                    .entrySet()) {
                ContainerController cc = e.getValue();
                cc.kill();
            }
            this.mainContainer.kill();
            this.runtime.shutDown();
        } catch (Exception e) {
            logger.warning("Warning shuting down JADE platform: "
                    + e.getMessage());
        }
    }
1206507
public void stop() {
		if (!PlatformUI.isWorkbenchRunning())
			return;
		final IWorkbench workbench = PlatformUI.getWorkbench();
		final Display display = workbench.getDisplay();
		display.syncExec(new Runnable() {
			public void run() {
				if (!display.isDisposed())
					workbench.close();
			}
		});
	}
289394
@InterfaceAudience.Public
    public void stop() {

        if (runningState.get() == false) {
            Log.d(Log.TAG_QUERY, "%s: stop() called, but runningState is already false.  Ignoring.", this);
            return;
        } else {
            Log.d(Log.TAG_QUERY, "%s: stop() called", this);
            runningState.set(false);
        }

        if (observing) {
            observing = false;
            getDatabase().removeChangeListener(this);
        }

        // slight diversion from iOS version -- cancel the queryFuture
        // regardless of the willUpdate value, since there can be an update in flight
        // with willUpdate set to false.  was needed to make testLiveQueryStop() unit test pass.
        if (queryFuture != null) {
            boolean cancelled = queryFuture.cancel(true);
            Log.v(Log.TAG_QUERY, "%s: cancelled queryFuture %s, returned: %s", this, queryFuture, cancelled);
        }

        if (rerunUpdateFuture != null) {
            boolean cancelled = rerunUpdateFuture.cancel(true);
            Log.d(Log.TAG_QUERY, "%s: cancelled rerunUpdateFuture %s, returned: %s", this, rerunUpdateFuture, cancelled);
        }

    }
602017
public void stop(final GeometryArrayFunction callback) {
		started = false;
		service.stop();
		if (callback != null) {
			calculate(new GeometryArrayFunction() {

				public void execute(Geometry[] geometries) {
					callback.execute(geometries);
					splitLine = null;
					eventBus.fireEvent(new GeometrySplitStopEvent(geometry));
				}
			});
		} else {
			eventBus.fireEvent(new GeometrySplitStopEvent(geometry));
			splitLine = null;
		}
	}
964175
private void stopProcessEngine(String serviceName, PlatformServiceContainer serviceContainer) {

    try {
      serviceContainer.stopService(serviceName);
    }
    catch(Exception e) {
      LOG.exceptionWhileStopping("Process Engine", serviceName, e);
    }

  }
1200459
@SuppressWarnings("WeakerAccess")
    public synchronized void stop() {
        if (isRunning()) {
            running.set(false);
            MetadataFinder.getInstance().removeMetadataProvider(metadataProvider);
            for (Database database : databases.values()) {
                //noinspection ResultOfMethodCallIgnored
                database.sourceFile.delete();
            }
            databases.clear();
        }
    }
1121690
@Override
    public void stop(BundleContext bc) throws Exception {
        RuntimeDelegate.setInstance(null);
        if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
            Tr.debug(tc, "stop", bc);
        }
    }
1111778
public synchronized void stop() {
    Preconditions.checkState(notifListener != null, "logger has not been started");
    for (GarbageCollectorMXBean mbean : ManagementFactory.getGarbageCollectorMXBeans()) {
      if (mbean instanceof NotificationEmitter) {
        final NotificationEmitter emitter = (NotificationEmitter) mbean;
        try {
          emitter.removeNotificationListener(notifListener);
        } catch (ListenerNotFoundException e) {
          LOGGER.warn("could not remove gc listener", e);
        }
      }
    }
    notifListener = null;
  }
120152
@Override
    public void stop()
                    throws SISessionUnavailableException, SISessionDroppedException,
                    SIResourceException, SIConnectionLostException,
                    SIErrorException
    {
        if (TraceComponent.isAnyTracingEnabled() && CoreSPIConsumerSession.tc.isEntryEnabled())
            SibTr.entry(CoreSPIConsumerSession.tc, "stop", this);

        //stop the LCP
        _localConsumerPoint.stop();

        if (TraceComponent.isAnyTracingEnabled() && CoreSPIConsumerSession.tc.isEntryEnabled())
            SibTr.exit(CoreSPIConsumerSession.tc, "stop");
    }
1330899
public void stop() {
		try {
			this.monitor.stop();

		} catch( final Exception e ) {
			this.logger.warning("Cannot stop template watcher");
			Utils.logException(this.logger, e);
		}
	}
808332
@Override
    public void stop(BundleContext ctx) throws Exception {
        // Unregister the EclipseLinke provider
        if (elSvcReg != null) {
            elSvcReg.unregister();
            elSvcReg = null;
        }
    }
1210949
public synchronized void stop() {

        _coreMonitor.unregister();

        for (ServiceReg<FileMonitor> reg : _monitors.values()) {
            reg.unregister();
        }

        _monitors.clear();

        // Tidy up old location if we built it
        tidyUpMonitoredDirectory(createdMonitoredDir.get(), monitoredDirectory.get());
    }
957560
public void stop() {
        final boolean trace = TraceComponent.isAnyTracingEnabled();

        // Stop accepting work
        stopped = true;

        // Cancel futures for submitted work
        for (Future<Void> future = futures.poll(); future != null; future = futures.poll())
            if (!future.isDone() && future.cancel(true))
                if (trace && tc.isDebugEnabled())
                    Tr.debug(this, tc, "canceled", future);

        // Release running work
        for (Work work = runningWork.poll(); work != null; work = runningWork.poll()) {
            if (trace && tc.isDebugEnabled())
                Tr.debug(this, tc, "release", work);
            work.release();
        }
    }
1308688
public void stop(BundleContext bc) throws Exception {
		if (httpService != null) {
			bc.ungetService(httpServiceRef);
			httpServiceRef = null;
			httpService = null;
		}
	}
730647
void stopIfNecessary() {
    synchronized (lock) {
      if (goAway && !stopped && streams.size() == 0) {
        stopped = true;
      } else {
        return;
      }
    }
    listener.transportTerminated();
  }
309241
public final synchronized void stop() {
		LaunchingMessageKind.IJMX0003.format();
		unRegisterMBeans();

		try {
			if (this.jmxConnectorServer != null) {
				this.jmxConnectorServer.stop();
			}
		} catch (IOException e1) {
			// Do nothing
		}
		try {
			UnicastRemoteObject.unexportObject(register, true);
		} catch (NoSuchObjectException e) {
			// Do nothing
		}
	}
371549
@Override
    public final void stop() {
        if (DynamicTasks.getTaskQueuingContext() != null) {
            doStop();
        } else {
            Task<?> task = Tasks.builder().name("stop").body(new Runnable() {
                public void run() {
                    doStop();
                }
            }).build();
            Entities.submit(this, task).getUnchecked();
        }
    }