public final class

Logs

extends Object
java.lang.Object
   ↳ org.eclipse.sisu.reflect.Logs

Class Overview

Utility methods for dealing with internal debug and warning messages.

Set -Dorg.eclipse.sisu.debug=true to send debug to the console.

Summary

Fields
public static final boolean DEBUG_ENABLED
public static final String NEW_LINE
Public Methods
static void catchThrowable(Throwable problem)
Helper method for catching Throwables; severe errors such as ThreadDeath are always re-thrown.
static void debug(String format, Object arg1, Object arg2)
Logs a debug message; uses "{}" format anchors.
static String identityToString(Object object)
Returns an identity string for the given object.
static void throwUnchecked(Throwable problem)
Helper method for throwing Throwables; checked exceptions are wrapped as ProvisionExceptions.
static String toString(Injector injector)
Returns a string representation of the given Injector.
static String toString(Module module)
Returns a string representation of the given Module.
static void warn(String format, Object arg1, Object arg2)
Logs a warning message; uses "{}" format anchors.
[Expand]
Inherited Methods
From class java.lang.Object

Fields

public static final boolean DEBUG_ENABLED

public static final String NEW_LINE

Public Methods

public static void catchThrowable (Throwable problem)

Helper method for catching Throwables; severe errors such as ThreadDeath are always re-thrown.

Parameters
problem The problem

public static void debug (String format, Object arg1, Object arg2)

Logs a debug message; uses "{}" format anchors. Pass Throwables in last parameter for special handling.

Parameters
format The debug message format
arg1 First object to format
arg2 Second object to format

public static String identityToString (Object object)

Returns an identity string for the given object.

Parameters
object The object
Returns
  • Identity string of the object.

public static void throwUnchecked (Throwable problem)

Helper method for throwing Throwables; checked exceptions are wrapped as ProvisionExceptions.

Parameters
problem The problem

public static String toString (Injector injector)

Returns a string representation of the given Injector.

Parameters
injector The injector
Returns
  • String representation of the injector.

public static String toString (Module module)

Returns a string representation of the given Module.

Parameters
module The module
Returns
  • String representation of the module.

public static void warn (String format, Object arg1, Object arg2)

Logs a warning message; uses "{}" format anchors. Pass Throwables in last parameter for special handling.

Parameters
format The warning message format
arg1 First object to format
arg2 Second object to format