HierarchicalTextResource

org.beangle.commons.text.i18n.HierarchicalTextResource
class HierarchicalTextResource(clazz: Class[_], locale: Locale, registry: TextBundleRegistry, formater: TextFormater) extends DefaultTextResource

Attributes

Graph
Supertypes
trait TextResource
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

final protected def findMessage(clazz: Class[_], key: String, checked: Set[String]): String
  • Look for message in aClass' class hierarchy.

  • Look for the message in a resource bundle for aClass

  • If not found, look for the message in a resource bundle for any implemented interface

  • If not found, traverse up the Class' hierarchy and repeat from the first sub-step

Attributes

final protected def findPackageMessage(className: String, key: String, checkedSet: Set[String]): String
override protected def get(key: String): Option[String]

Attributes

Definition Classes
final protected def getClassMessage(className: String, key: String): String

Gets the message from the named resource bundle.

Gets the message from the named resource bundle.

Attributes

final protected def getPackageMessage(packageName: String, key: String): String

Gets the message from the named resource bundle.

Gets the message from the named resource bundle.

Attributes

Inherited methods

def apply(key: String): Option[String]

Gets a message based on a message key, or null if no message is found.

Gets a message based on a message key, or null if no message is found.

Value parameters

key

the resource bundle key that is to be searched for

Attributes

Returns

the message as found in the resource bundle, or null if none is found.

Inherited from:
DefaultTextResource
def apply(key: String, defaultValue: String, args: Any*): String

getText.

getText.

Attributes

Inherited from:
DefaultTextResource
def isKeyAsDefault(): Boolean

Attributes

Inherited from:
DefaultTextResource
def setKeyAsDefault(keyAsDefault: Boolean): Unit

Attributes

Inherited from:
DefaultTextResource

Inherited fields

protected var keyAsDefault: Boolean

Attributes

Inherited from:
DefaultTextResource