ch.qos.cal10n.verifier
Class MessageKeyVerifier

java.lang.Object
  extended by ch.qos.cal10n.verifier.MessageKeyVerifier
All Implemented Interfaces:
IMessageKeyVerifier

public class MessageKeyVerifier
extends java.lang.Object
implements IMessageKeyVerifier

Given an enum class, verify that the resource bundles corresponding to a given locale contains the correct keys.

Author:
Ceki Gulcu

Constructor Summary
MessageKeyVerifier(java.lang.Class<? extends java.lang.Enum<?>> enumClass)
           
MessageKeyVerifier(java.lang.String enumTypeAsStr)
           
 
Method Summary
 java.lang.String getBaseName()
          Get the base name for the resource bundle family as specified in the enumType (via annotations)
 java.lang.Class<? extends java.lang.Enum<?>> getEnumType()
          Get the of enum type that this verifier is related to to.
 java.lang.String getEnumTypeAsStr()
          Get the name of enum type to this verifier is related to to.
 java.lang.String[] getLocaleNames()
          Get the locales specified in the enumType (via annotations)
 java.util.List<java.lang.String> typeIsolatedVerify(java.util.Locale locale)
          Same as IMessageKeyVerifier.verify(Locale) except that the return type is List.
 java.util.List<Cal10nError> verify(java.util.Locale locale)
          Verify that the keys defined in the enumClass match those found in the resource bundle corresponding to a certain locale
 java.util.List<Cal10nError> verifyAllLocales()
          Verify all declared locales in one step.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MessageKeyVerifier

public MessageKeyVerifier(java.lang.Class<? extends java.lang.Enum<?>> enumClass)

MessageKeyVerifier

public MessageKeyVerifier(java.lang.String enumTypeAsStr)
Method Detail

getEnumType

public java.lang.Class<? extends java.lang.Enum<?>> getEnumType()
Description copied from interface: IMessageKeyVerifier
Get the of enum type that this verifier is related to to.

Specified by:
getEnumType in interface IMessageKeyVerifier
Returns:

getEnumTypeAsStr

public java.lang.String getEnumTypeAsStr()
Description copied from interface: IMessageKeyVerifier
Get the name of enum type to this verifier is related to to.

Specified by:
getEnumTypeAsStr in interface IMessageKeyVerifier
Returns:

verify

public java.util.List<Cal10nError> verify(java.util.Locale locale)
Description copied from interface: IMessageKeyVerifier
Verify that the keys defined in the enumClass match those found in the resource bundle corresponding to a certain locale

Specified by:
verify in interface IMessageKeyVerifier
Returns:

typeIsolatedVerify

public java.util.List<java.lang.String> typeIsolatedVerify(java.util.Locale locale)
Description copied from interface: IMessageKeyVerifier
Same as IMessageKeyVerifier.verify(Locale) except that the return type is List.

Specified by:
typeIsolatedVerify in interface IMessageKeyVerifier
Returns:

verifyAllLocales

public java.util.List<Cal10nError> verifyAllLocales()
Verify all declared locales in one step.

Specified by:
verifyAllLocales in interface IMessageKeyVerifier
Returns:

getLocaleNames

public java.lang.String[] getLocaleNames()
Description copied from interface: IMessageKeyVerifier
Get the locales specified in the enumType (via annotations)

Specified by:
getLocaleNames in interface IMessageKeyVerifier
Returns:

getBaseName

public java.lang.String getBaseName()
Description copied from interface: IMessageKeyVerifier
Get the base name for the resource bundle family as specified in the enumType (via annotations)

Specified by:
getBaseName in interface IMessageKeyVerifier
Returns:


Copyright © 2009-2010 QOS.ch. All Rights Reserved.