METHODS

Constructors

$class->new( %options )
Option Default

rules

{}

rules => HASH

Attributes

$obj->rules

Returns a HASH to the simplified context maps.

Action

$obj->ctxtFor( $message, $lang, [$context] )

Returns a pair of the MSGID stripped from context markup, and the context evaluated into the msgctxt string. The $message is a Log::Report::Message object. The $context is the default context for a certain textdomain.

  my ($msgid, $msgctxt) = $context->ctxtFor($msg, $lang, $context);
$obj->expand( $msgid, $language, %options )

Expand the context settings into all possible combinations which need translations in the PO file. This may depend on the $language. The $msgid is used in error messages.

$obj->needDecode( $source, STRING|ARRAY|HASH|LIST )
$class->needDecode( $source, STRING|ARRAY|HASH|LIST )

Converts the context settings passed with the MSGID, into a HASH which will be matched to the context providers.