Commaaa2
This commit is contained in:
@@ -36,10 +36,8 @@ interface MessageCatalogueInterface
|
||||
* Gets the messages within a given domain.
|
||||
*
|
||||
* If $domain is null, it returns all messages.
|
||||
*
|
||||
* @param string $domain The domain name
|
||||
*/
|
||||
public function all(string $domain = null): array;
|
||||
public function all(?string $domain = null): array;
|
||||
|
||||
/**
|
||||
* Sets a message translation.
|
||||
@@ -47,6 +45,8 @@ interface MessageCatalogueInterface
|
||||
* @param string $id The message id
|
||||
* @param string $translation The messages translation
|
||||
* @param string $domain The domain name
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function set(string $id, string $translation, string $domain = 'messages');
|
||||
|
||||
@@ -79,6 +79,8 @@ interface MessageCatalogueInterface
|
||||
*
|
||||
* @param array $messages An array of translations
|
||||
* @param string $domain The domain name
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function replace(array $messages, string $domain = 'messages');
|
||||
|
||||
@@ -87,6 +89,8 @@ interface MessageCatalogueInterface
|
||||
*
|
||||
* @param array $messages An array of translations
|
||||
* @param string $domain The domain name
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function add(array $messages, string $domain = 'messages');
|
||||
|
||||
@@ -94,6 +98,8 @@ interface MessageCatalogueInterface
|
||||
* Merges translations from the given Catalogue into the current one.
|
||||
*
|
||||
* The two catalogues must have the same locale.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function addCatalogue(self $catalogue);
|
||||
|
||||
@@ -102,6 +108,8 @@ interface MessageCatalogueInterface
|
||||
* only when the translation does not exist.
|
||||
*
|
||||
* This is used to provide default translations when they do not exist for the current locale.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function addFallbackCatalogue(self $catalogue);
|
||||
|
||||
@@ -119,6 +127,8 @@ interface MessageCatalogueInterface
|
||||
|
||||
/**
|
||||
* Adds a resource for this collection.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function addResource(ResourceInterface $resource);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user