JBoss Logging I18n Tools 1.0.0.Beta7

org.jboss.logging
Interface Annotations

All Known Implementing Classes:
BaseAnnotations

public interface Annotations

Defines the annotations and annotation values used to generate the concrete classes from the annotated interfaces.

Author:
James R. Perkins - 19.Feb.2011

Nested Class Summary
static class Annotations.FormatType
          The message format type.
 
Method Summary
 Class<? extends Annotation> cause()
          Returns the cause annotation class.
 Class<? extends Annotation> formatWith()
          Returns the format with annotation class.
 boolean hasMessageId(ExecutableElement method)
          Checks to see if the method has a message id.
 boolean inheritsMessageId(ExecutableElement method)
          Checks to see if the method should inherit the message id from a different method if applicable.
 String loggerMethod(ExecutableElement method, Annotations.FormatType formatType)
          Returns the logger method name to use.
 String logLevel(ExecutableElement method)
          Returns the log level enum.
 Class<? extends Annotation> logMessage()
          Returns the log message annotation class.
 Class<? extends Annotation> message()
          Returns the message annotation class.
 Class<? extends Annotation> messageBundle()
          Returns the message bundle annotation class.
 Annotations.FormatType messageFormat(ExecutableElement method)
          Returns the method format type.
 int messageId(ExecutableElement method)
          Returns the message id.
 Class<? extends Annotation> messageLogger()
          Returns the message logger annotation class.
 String messageValue(ExecutableElement method)
          Returns the message value for the method.
 String projectCode(TypeElement intf)
          The project code from the interface.
 

Method Detail

cause

Class<? extends Annotation> cause()
Returns the cause annotation class.

Returns:
the cause annotation.

formatWith

Class<? extends Annotation> formatWith()
Returns the format with annotation class.

Returns:
the format with annotation.

logMessage

Class<? extends Annotation> logMessage()
Returns the log message annotation class.

Returns:
the log message annotation.

message

Class<? extends Annotation> message()
Returns the message annotation class.

Returns:
the message annotation.

messageBundle

Class<? extends Annotation> messageBundle()
Returns the message bundle annotation class.

Returns:
the message bundle annotation.

messageLogger

Class<? extends Annotation> messageLogger()
Returns the message logger annotation class.

Returns:
the message logger annotation.

messageFormat

Annotations.FormatType messageFormat(ExecutableElement method)
Returns the method format type.

Parameters:
method - the method with the Message annotation.
Returns:
the format type of the message or null if the format type was not found.

projectCode

String projectCode(TypeElement intf)
The project code from the interface.

Parameters:
intf - the interface to find the project code on.
Returns:
the project code or null if one was not found.

hasMessageId

boolean hasMessageId(ExecutableElement method)
Checks to see if the method has a message id.

Parameters:
method - the method to check.
Returns:
true if the message id was found, otherwise false.

inheritsMessageId

boolean inheritsMessageId(ExecutableElement method)
Checks to see if the method should inherit the message id from a different method if applicable.

Parameters:
method - the method to check.
Returns:
true if the message id should be inherited, otherwise false.

messageId

int messageId(ExecutableElement method)
Returns the message id.

Parameters:
method - the method to check.
Returns:
the message id or 0 if one was not found.

messageValue

String messageValue(ExecutableElement method)
Returns the message value for the method.

Parameters:
method - the method to check.
Returns:
the message for the method, if no method found null is returned.

loggerMethod

String loggerMethod(ExecutableElement method,
                    Annotations.FormatType formatType)
Returns the logger method name to use.

Parameters:
method - the method used to determine the log method.
formatType - the format type for the method.
Returns:
the name of the logger method.

logLevel

String logLevel(ExecutableElement method)
Returns the log level enum. For example Logger.Level.INFO.

Parameters:
method - the method used to determine the log method.
Returns:
the log level.

JBoss Logging I18n Tools 1.0.0.Beta7

Copyright © 2011 JBoss, a division of Red Hat, Inc.. All Rights Reserved.