Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## avrora
Class Avrora

    java.lang.Object
      avrora.Avrora

public class Avrora
extends java.lang.Object

The `Avrora` class contains several utilities relating to exceptions and errors within Avrora.

Nested Class Summary
`static class` | `Avrora.Error` The `Error` class is the base class of all errors in Avrora.
`static class` | `Avrora.InternalError` The `InternalError` class is a class of errors corresponding to exceptional conditions within Avrora.
`static class` | `Avrora.Unexpected` The `Unexpected` class wraps an unexpected exception that may happen during execution.

Constructor Summary
`Avrora()`

Method Summary
`static Avrora.InternalError` | `failure(java.lang.String s)` The `failure()` method is a utility that constructs a `InternalError` instance with the specified message.
`static Avrora.Unexpected` | `unexpected(java.lang.Throwable t)` The `unexpected()` method is a utility method that wraps an unexpected exception so that it can be throw again and reported later.
`static Avrora.InternalError` | `unimplemented()` The `unimplemented()` method is a utility that constructs a `InternalError` instance.
`static void` | `userError(java.lang.String s)` The `userError()` method constructs and throws an error in situations that are likely due to user error.
`static void` | `userError(java.lang.String s, java.lang.String p)` The `userError()` method constructs and throws an error in situations that are likely due to user error.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### Avrora

    public Avrora()

Method Detail

### unimplemented

    public static Avrora.InternalError unimplemented()

  The `unimplemented()` method is a utility that constructs a `InternalError` instance. This is called from methods or classes with unimplemented functionality for documentation and fail-fast purposes.

  Returns:
    an instance of the `Avrora.InternalError` class that specifies that this functionality is not yet implemented

### failure

    public static Avrora.InternalError failure(java.lang.String s)

  The `failure()` method is a utility that constructs a `InternalError` instance with the specified message. It is useful for internal error conditions and defensive programming.

  Returns:
    an instance of the `Avrora.InternalError` class with the specified error message

### unexpected

    public static Avrora.Unexpected unexpected(java.lang.Throwable t)

  The `unexpected()` method is a utility method that wraps an unexpected exception so that it can be throw again and reported later. This is useful for code that does IO but does not want to handle IO exceptions, for example.

  Parameters:
    `t` - the throwable that was encountered
  Returns:
    a new instance of the `Unexpected` class that wraps up the thrown exception

### userError

    public static void userError(java.lang.String s)

  The `userError()` method constructs and throws an error in situations that are likely due to user error. This is useful for files that are not found, an incorrect option value, etc.

  Parameters:
    `s` - the message for the user

### userError

    public static void userError(java.lang.String s,
                                 java.lang.String p)

  The `userError()` method constructs and throws an error in situations that are likely due to user error. This is useful for files that are not found, an incorrect option value, etc.

  Parameters:
    `s` - the message for the user
    `p` - the parameter to the message, automatically put in quotes

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD