ch.qos.cal10n.verifier
Interface IMessageCodeVerifier

All Known Implementing Classes:
MessageCodeVerifier

public interface IMessageCodeVerifier

An interface for verifying that given an enum type, the keys match those found in the corresponding resource bundles.

See also MessageCodeVerifier for a concrete implementation.

Author:
Ceki Gülcü

Method Summary
 Class<? extends Enum<?>> getEnumType()
          Get the of enum type that this verifier is related to to.
 String getEnumTypeAsStr()
          Get the name of enum type to this verifier is related to to.
 String[] getLocaleNames()
          Get the locales specified in the enumType (via annotations)
 String getResourceBundleName()
          Get the name of the resource bundle specified in the enumType (via annotations)
 List<String> typeIsolatedVerify(Locale locale)
          Same as verify(Locale) except that the return type is List.
 List<Cal10nError> verify(Locale locale)
          Verify that the keys defined in the enumClass match those found in the resource bundle corresponding to a certain locale
 List<Cal10nError> verifyAllLocales()
          Verify that the keys defined in the enumClass match those found in the corresponding resource bundle for all locales declared in the enum type via the @LocaleNames annotation.
 

Method Detail

getEnumType

Class<? extends Enum<?>> getEnumType()
Get the of enum type that this verifier is related to to.

Returns:

getEnumTypeAsStr

String getEnumTypeAsStr()
Get the name of enum type to this verifier is related to to.

Returns:

verify

List<Cal10nError> verify(Locale locale)
Verify that the keys defined in the enumClass match those found in the resource bundle corresponding to a certain locale

Parameters:
locale -
Returns:

verifyAllLocales

List<Cal10nError> verifyAllLocales()
Verify that the keys defined in the enumClass match those found in the corresponding resource bundle for all locales declared in the enum type via the @LocaleNames annotation.

Parameters:
locale -
Returns:

typeIsolatedVerify

List<String> typeIsolatedVerify(Locale locale)
Same as verify(Locale) except that the return type is List.

Parameters:
locale -
Returns:

getLocaleNames

String[] getLocaleNames()
Get the locales specified in the enumType (via annotations)

Returns:

getResourceBundleName

String getResourceBundleName()
Get the name of the resource bundle specified in the enumType (via annotations)

Returns:


Copyright © 2009 QOS.ch. All Rights Reserved.