Skip to content

Commit

Permalink
Merge pull request #13 from abbadon1334/refactor-plurals
Browse files Browse the repository at this point in the history
Refactor plurals
  • Loading branch information
abbadon1334 committed Jul 15, 2019
2 parents 49a2bea + 75a8f99 commit 42b441f
Show file tree
Hide file tree
Showing 107 changed files with 4,175 additions and 1,891 deletions.
Binary file not shown.
Binary file not shown.
Binary file modified docs/.doctrees/api/I18Next/Exception/index.doctree
Binary file not shown.
Binary file modified docs/.doctrees/api/I18Next/Locale.doctree
Binary file not shown.
Binary file modified docs/.doctrees/api/I18Next/Locale/Processor.doctree
Binary file not shown.
Binary file not shown.
Binary file modified docs/.doctrees/api/I18Next/Locale/Processor/Value.doctree
Binary file not shown.
Binary file modified docs/.doctrees/api/I18Next/Locale/Processor/index.doctree
Binary file not shown.
Binary file modified docs/.doctrees/api/I18Next/Locale/Translations.doctree
Binary file not shown.
Binary file modified docs/.doctrees/api/I18Next/TranslatorStatic.doctree
Binary file not shown.
Binary file modified docs/.doctrees/api/index-namespaces-all.doctree
Binary file not shown.
Binary file modified docs/.doctrees/environment.pickle
Binary file not shown.
28 changes: 24 additions & 4 deletions docs/_sources/api/I18Next/Locale.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,18 @@ Methods

.. php:method:: public __construct( $code)
.. rst-class:: phpdoc-description

| Locale constructor\.

:Source:
`src/I18Next/Locale.php#22 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale.php#L22>`_
`src/I18Next/Locale.php#33 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale.php#L33>`_


:Parameters:
* **$code** (string)




Expand All @@ -54,7 +63,7 @@ Methods
.. php:method:: public load( $path, $use_filename_as_namespace, ...$namespace_priority)
:Source:
`src/I18Next/Locale.php#36 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale.php#L36>`_
`src/I18Next/Locale.php#47 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale.php#L47>`_


:Parameters:
Expand All @@ -72,9 +81,16 @@ Methods
.. php:method:: public process( $key, $parameters=null, $context=null)
:Source:
`src/I18Next/Locale.php#41 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale.php#L41>`_
`src/I18Next/Locale.php#59 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale.php#L59>`_


:Parameters:
* **$key** (string)
* **$parameters** (array | null)
* **$context** (string | null)


:Returns: string | null



Expand All @@ -83,8 +99,12 @@ Methods
.. php:method:: public setLoaderFormat( $format)
:Source:
`src/I18Next/Locale.php#46 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale.php#L46>`_
`src/I18Next/Locale.php#67 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale.php#L67>`_


:Parameters:
* **$format** (string)




Expand Down
13 changes: 11 additions & 2 deletions docs/_sources/api/I18Next/Locale/Processor.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,18 @@ Methods

.. php:method:: public __construct( $translations)
.. rst-class:: phpdoc-description

| Processor constructor\.

:Source:
`src/I18Next/Locale/Processor.php#24 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Processor.php#L24>`_
`src/I18Next/Locale/Processor.php#29 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Processor.php#L29>`_


:Parameters:
* **$translations** (:any:`I18Next\\Locale\\Translations <I18Next\\Locale\\Translations>`)




Expand All @@ -57,7 +66,7 @@ Methods
.. php:method:: public process( $key, $parameters=null, $context=null)
:Source:
`src/I18Next/Locale/Processor.php#38 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Processor.php#L38>`_
`src/I18Next/Locale/Processor.php#43 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Processor.php#L43>`_


:Parameters:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,19 @@ Methods

.. php:method:: public __construct( $translations)
.. rst-class:: phpdoc-description

| AbstractProcessor constructor\.

:Source:
`src/I18Next/Locale/Processor/AbstractProcessor.php#17 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Processor/AbstractProcessor.php#L17>`_
`src/I18Next/Locale/Processor/AbstractProcessor.php#22 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Processor/AbstractProcessor.php#L22>`_


:Parameters:
* **$translations** (:any:`I18Next\\Locale\\Translations <I18Next\\Locale\\Translations>`)





8 changes: 7 additions & 1 deletion docs/_sources/api/I18Next/Locale/Processor/Value.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,15 @@ Methods
.. php:method:: public processValue( &$found_key, $parameters)
:Source:
`src/I18Next/Locale/Processor/Value.php#14 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Processor/Value.php#L14>`_
`src/I18Next/Locale/Processor/Value.php#20 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Processor/Value.php#L20>`_


:Parameters:
* **$found_key** (string | null)
* **$parameters** (array | null)


:Returns: string | null



9 changes: 9 additions & 0 deletions docs/_sources/api/I18Next/Locale/Processor/index.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,15 @@ Processor
\\I18Next\\Locale\\Processor


Namespaces
----------

.. toctree::
:maxdepth: 1

Key <Key/index>


Classes
-------

Expand Down
30 changes: 20 additions & 10 deletions docs/_sources/api/I18Next/Locale/Translations.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Translations
:Source:
`src/I18Next/Locale/Translations.php#15 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Translations.php#L15>`_
`src/I18Next/Locale/Translations.php#19 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Translations.php#L19>`_

:Used traits:
:php:trait:`atk4\\core\\ConfigTrait`
Expand All @@ -30,11 +30,11 @@ Methods
~~~~~~~

* :php:meth:`public load\($path, $use\_filename\_as\_namespace, $namespace\_priority\)<I18Next\\Locale\\Translations::load\(\)>`
* :php:meth:`private loadSingle\($path\)<I18Next\\Locale\\Translations::loadSingle\(\)>`
* :php:meth:`public useFilenameAsNamespace\($enabled\)<I18Next\\Locale\\Translations::useFilenameAsNamespace\(\)>`
* :php:meth:`private setNamespacePriority\($namespace\_priority\)<I18Next\\Locale\\Translations::setNamespacePriority\(\)>`
* :php:meth:`private processKeyVariation\($processorClass, $key, $value\)<I18Next\\Locale\\Translations::processKeyVariation\(\)>`
* :php:meth:`private afterReadProcessForKeyCounters\(\)<I18Next\\Locale\\Translations::afterReadProcessForKeyCounters\(\)>`
* :php:meth:`private processForCounterKey\($key\_plural\_definition, $key, $value\)<I18Next\\Locale\\Translations::processForCounterKey\(\)>`
* :php:meth:`private processForIntervalKey\($key\_plural\_definition, $key, $value\)<I18Next\\Locale\\Translations::processForIntervalKey\(\)>`
* :php:meth:`private afterReadProcessForKeyDeepInline\(\)<I18Next\\Locale\\Translations::afterReadProcessForKeyDeepInline\(\)>`
* :php:meth:`private afterReadAddNamespaceIfNeeded\($config, $namespace\)<I18Next\\Locale\\Translations::afterReadAddNamespaceIfNeeded\(\)>`
* :php:meth:`public useNamespaces\(\)<I18Next\\Locale\\Translations::useNamespaces\(\)>`
Expand All @@ -48,15 +48,15 @@ Properties
.. php:attr:: protected static namespace_priority
:Source:
`src/I18Next/Locale/Translations.php#23 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Translations.php#L23>`_
`src/I18Next/Locale/Translations.php#27 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Translations.php#L27>`_

:Type: string[]


.. php:attr:: protected static use_filename_as_namespace
:Source:
`src/I18Next/Locale/Translations.php#26 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Translations.php#L26>`_
`src/I18Next/Locale/Translations.php#30 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Translations.php#L30>`_

:Type: bool

Expand All @@ -69,7 +69,7 @@ Methods
.. php:method:: public load( $path, $use_filename_as_namespace, ...$namespace_priority)
:Source:
`src/I18Next/Locale/Translations.php#41 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Translations.php#L41>`_
`src/I18Next/Locale/Translations.php#45 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Translations.php#L45>`_


:Parameters:
Expand All @@ -87,9 +87,13 @@ Methods
.. php:method:: public useFilenameAsNamespace( $enabled)
:Source:
`src/I18Next/Locale/Translations.php#77 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Translations.php#L77>`_
`src/I18Next/Locale/Translations.php#97 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Translations.php#L97>`_


:Parameters:
* **$enabled** (bool | null)





Expand All @@ -98,9 +102,10 @@ Methods
.. php:method:: public useNamespaces()
:Source:
`src/I18Next/Locale/Translations.php#243 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Translations.php#L243>`_
`src/I18Next/Locale/Translations.php#197 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Translations.php#L197>`_


:Returns: bool



Expand All @@ -109,9 +114,10 @@ Methods
.. php:method:: public getNamespaceRanked()
:Source:
`src/I18Next/Locale/Translations.php#248 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Translations.php#L248>`_
`src/I18Next/Locale/Translations.php#205 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Translations.php#L205>`_


:Returns: string[]



Expand All @@ -120,9 +126,13 @@ Methods
.. php:method:: public setLoaderFormat( $format)
:Source:
`src/I18Next/Locale/Translations.php#253 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Translations.php#L253>`_
`src/I18Next/Locale/Translations.php#213 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/Locale/Translations.php#L213>`_


:Parameters:
* **$format** (string)





24 changes: 12 additions & 12 deletions docs/_sources/api/I18Next/TranslatorStatic.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ TranslatorStatic
:Source:
`src/I18Next/TranslatorStatic.php#14 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L14>`_
`src/I18Next/TranslatorStatic.php#13 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L13>`_



Expand Down Expand Up @@ -48,7 +48,7 @@ Methods
.. php:method:: public static instance()
:Source:
`src/I18Next/TranslatorStatic.php#19 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L19>`_
`src/I18Next/TranslatorStatic.php#18 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L18>`_



Expand All @@ -59,7 +59,7 @@ Methods
.. php:method:: public static setTranslationsPath( $path)
:Source:
`src/I18Next/TranslatorStatic.php#33 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L33>`_
`src/I18Next/TranslatorStatic.php#32 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L32>`_


:Parameters:
Expand All @@ -75,7 +75,7 @@ Methods
.. php:method:: public static setNamespacePriority( ...$namespace_priority)
:Source:
`src/I18Next/TranslatorStatic.php#43 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L43>`_
`src/I18Next/TranslatorStatic.php#42 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L42>`_


:Parameters:
Expand All @@ -91,7 +91,7 @@ Methods
.. php:method:: public static useFilenameAsNamespace( $enabled)
:Source:
`src/I18Next/TranslatorStatic.php#53 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L53>`_
`src/I18Next/TranslatorStatic.php#52 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L52>`_


:Parameters:
Expand All @@ -107,7 +107,7 @@ Methods
.. php:method:: public static setLanguagePrimary( $language_code)
:Source:
`src/I18Next/TranslatorStatic.php#65 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L65>`_
`src/I18Next/TranslatorStatic.php#64 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L64>`_


:Parameters:
Expand All @@ -131,7 +131,7 @@ Methods
.. php:method:: public static addLanguage( $code)
:Source:
`src/I18Next/TranslatorStatic.php#77 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L77>`_
`src/I18Next/TranslatorStatic.php#76 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L76>`_


:Parameters:
Expand All @@ -155,7 +155,7 @@ Methods
.. php:method:: public static setLanguageFallback( $fallback_code)
:Source:
`src/I18Next/TranslatorStatic.php#89 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L89>`_
`src/I18Next/TranslatorStatic.php#88 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L88>`_


:Parameters:
Expand All @@ -176,10 +176,10 @@ Methods

.. rst-class:: public static

.. php:method:: public static _( $key, $parameters=NULL, $context=NULL, $locale=NULL)
.. php:method:: public static _( $key, $parameters=null, $context=null, $locale=null)
:Source:
`src/I18Next/TranslatorStatic.php#102 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L102>`_
`src/I18Next/TranslatorStatic.php#101 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L101>`_


:Parameters:
Expand All @@ -199,11 +199,11 @@ Methods
.. rst-class:: phpdoc-description

| Register global function \_
| Register global function \_\.

:Source:
`src/I18Next/TranslatorStatic.php#110 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L110>`_
`src/I18Next/TranslatorStatic.php#109 <https://github.com/abbadon1334/atk4-i18next-php/blob/master/src/I18Next/TranslatorStatic.php#L109>`_



Expand Down
1 change: 1 addition & 0 deletions docs/_sources/api/index-namespaces-all.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ Namespaces
\I18Next\Exception <I18Next/Exception/index>
\I18Next\Locale <I18Next/Locale/index>
\I18Next\Locale\Processor <I18Next/Locale/Processor/index>
\I18Next\Locale\Processor\Key <I18Next/Locale/Processor/Key/index>
\I18Next\atk4 <I18Next/atk4/index>
\atk4\core <atk4/core/index>

Expand Down
Loading

0 comments on commit 42b441f

Please sign in to comment.