All Downloads are FREE. Search and download functionalities are using the official Maven repository.

jflex.exceptions.SilentExit Maven / Gradle / Ivy

Go to download

JFlex is a lexical analyzer generator (also known as scanner generator) for Java™, written in Java.

There is a newer version: 1.8.2
Show newest version
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
 * JFlex 1.8.0                                                             *
 * Copyright (C) 1998-2018  Gerwin Klein                     *
 * All rights reserved.                                                    *
 *                                                                         *
 * License: BSD                                                            *
 *                                                                         *
 * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */

package jflex.exceptions;

/**
 * Signals a silent exit (no statistics printout).
 *
 * @author Gerwin Klein
 * @version JFlex 1.8.0
 */
public class SilentExit extends Exception {

  /** Program exit code if this exception is taken */
  private final int exitCode;

  /**
   * SilentExit with specified program exit code.
   *
   * @param exitCode a int.
   */
  public SilentExit(int exitCode) {
    this.exitCode = exitCode;
  }

  /** SilentExit with default exit code 1. */
  public SilentExit() {
    this(1);
  }

  /**
   * The exit code of this SilentExit exception.
   *
   * @return a int.
   */
  public int exitCode() {
    return exitCode;
  }

  /** Serialisation */
  private static final long serialVersionUID = 8288632239818668902L;
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy