Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
34 changed files
with
643 additions
and
348 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
parameters: | ||
level: 6 | ||
reportUnmatchedIgnoredErrors: false | ||
paths: | ||
- src | ||
- tests | ||
ignoreErrors: | ||
- | ||
message: '#Method .* has no return typehint specified#' | ||
path: tests/ | ||
- | ||
message: '#Method .* has parameter .* with no typehint specified#' | ||
path: tests/ | ||
- | ||
message: '#Method .* has parameter .* with no value type specified in iterable type array#' | ||
path: tests/ | ||
- | ||
message: '#Method .* return type has no value type specified in iterable type array#' | ||
path: tests/ | ||
- | ||
message: '#PHPDoc tag @param has invalid value \(.*\): Unexpected token ".*", expected type at offset .*#' | ||
path: tests/ | ||
- '#Call to static method .* on trait .*#' | ||
- '#Access to static property .* on trait .*#' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,36 @@ | ||
<?php | ||
namespace morphos; | ||
|
||
use RuntimeException; | ||
|
||
abstract class BaseInflection implements Cases | ||
{ | ||
public static function isMutable($name) | ||
{ | ||
/** | ||
* @abstract | ||
* @param string $name | ||
* @return bool | ||
*/ | ||
public static function isMutable($name) { | ||
throw new RuntimeException('Not implemented'); | ||
} | ||
|
||
public static function getCases($name) | ||
{ | ||
/** | ||
* @abstract | ||
* @param string $name | ||
* @return string[] | ||
* @phpstan-return array<string, string> | ||
*/ | ||
public static function getCases($name) { | ||
throw new RuntimeException('Not implemented'); | ||
} | ||
|
||
public static function getCase($name, $case) | ||
{ | ||
/** | ||
* @abstract | ||
* @param string $name | ||
* @param string $case | ||
* @return string | ||
*/ | ||
public static function getCase($name, $case) { | ||
throw new RuntimeException('Not implemented'); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,42 @@ | ||
<?php | ||
namespace morphos; | ||
|
||
use RuntimeException; | ||
|
||
abstract class BasePluralization | ||
{ | ||
public static function pluralize($word, $count = 2) | ||
{ | ||
/** | ||
* @abstract | ||
* @param string $word | ||
* @param int $count | ||
* | ||
* @return string | ||
*/ | ||
public static function pluralize($word, $count = 2) { | ||
throw new RuntimeException('Not implemented'); | ||
} | ||
|
||
public static function getCase($word, $case, $animateness = false) | ||
{ | ||
/** | ||
* @abstract | ||
* @param string $word | ||
* @param string $case | ||
* @param bool $animateness | ||
* | ||
* @return string | ||
*/ | ||
public static function getCase($word, $case, $animateness = false) { | ||
throw new RuntimeException('Not implemented'); | ||
} | ||
|
||
public static function getCases($word, $animateness = false) | ||
{ | ||
/** | ||
* @abstract | ||
* @param string $word | ||
* @param bool $animateness | ||
* | ||
* @return string[] | ||
* @phpstan-return array<string, string> | ||
*/ | ||
public static function getCases($word, $animateness = false) { | ||
throw new RuntimeException('Not implemented'); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.