Examples of Signal


Examples of sun.misc.Signal

   */
  public IrqHandler(String name, Interrupted handler) throws IOException {
    this.handler = handler;
    this.name = name;
    try {
      Signal.handle(new Signal(name), this);
    } catch (IllegalArgumentException e) {
      throw new IOException(
        "Could not set handler for signal \"" + name + "\"."
        + "This can happen if the JVM has the -Xrs set.",
        e);
View Full Code Here

Examples of sun.misc.Signal

            @Override
            public void handle(Signal sig) {
                interruptHook.handleInterrupt(console);
            }
        };
        original = Signal.handle(new Signal("INT"), handler);
    }
View Full Code Here

Examples of sun.misc.Signal

        };
        original = Signal.handle(new Signal("INT"), handler);
    }

    public void removeInterrupt() {
        Signal.handle(new Signal("INT"), original);
    }
View Full Code Here

Examples of sun.misc.Signal

        SignalHandler handler = new SignalHandler () {
            public void handle(Signal sig) {
                interruptHook.handleInterrupt(console);
            }
        };
        Signal.handle(new Signal("INT"), handler);
    }
View Full Code Here

Examples of sun.misc.Signal

   *          returning -1
   * @return 0 if ok
   */
  public int processLine(String line, boolean allowInterupting) {
    SignalHandler oldSignal = null;
    Signal interupSignal = null;

    if (allowInterupting) {
      // Remember all threads that were running at the time we started line processing.
      // Hook up the custom Ctrl+C handler while processing this line
      interupSignal = new Signal("INT");
      oldSignal = Signal.handle(interupSignal, new SignalHandler() {
        private final Thread cliThread = Thread.currentThread();
        private boolean interruptRequested;

        @Override
View Full Code Here

Examples of sun.misc.Signal

    {
        this(parseConfig(configurationURL));
        _configFile = configurationURL;
        try
        {
            Signal sig = new sun.misc.Signal("HUP");
            sun.misc.Signal.handle(sig, this);
        }
        catch (Exception e)
        {
            _logger.info("Signal HUP not supported for OS: " + System.getProperty("os.name"));
View Full Code Here

Examples of sun.misc.Signal

   *          returning -1
   * @return
   */
  public int processLine(String line, boolean allowInterupting) {
    SignalHandler oldSignal = null;
    Signal interupSignal = null;

    if (allowInterupting) {
      // Remember all threads that were running at the time we started line processing.
      // Hook up the custom Ctrl+C handler while processing this line
      interupSignal = new Signal("INT");
      oldSignal = Signal.handle(interupSignal, new SignalHandler() {
        private final Thread cliThread = Thread.currentThread();
        private boolean interruptRequested;

        @Override
View Full Code Here

Examples of sun.misc.Signal

      public void handle(Signal arg0) {       
        ERT.print_all_stack_traces();
      }
    };
   
    sun.misc.Signal.handle(new Signal("HUP"), handler);
   
    OTPMain.main(ra.toArray(new String[ra.size()]));
  }
View Full Code Here

Examples of sun.misc.Signal

    private BundleContext bundleContext;
    private SignalHandler previous;

    public void start(BundleContext context) throws Exception {
        bundleContext = context;
        previous = sun.misc.Signal.handle(new Signal(SIGNAL), this);
    }
View Full Code Here

Examples of sun.misc.Signal

        bundleContext = context;
        previous = sun.misc.Signal.handle(new Signal(SIGNAL), this);
    }

    public void stop(BundleContext context) throws Exception {
        sun.misc.Signal.handle(new Signal(SIGNAL), previous);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.