source/Spiral/ODM/Configs/ODMConfig.php 1 location
|
@@ 83-90 (lines=8) @@
|
| 80 |
|
* @param string $mutator |
| 81 |
|
* @return string |
| 82 |
|
*/ |
| 83 |
|
public function mutatorAlias($mutator) |
| 84 |
|
{ |
| 85 |
|
if (!is_string($mutator) || !isset($this->config['mutatorAliases'][$mutator])) { |
| 86 |
|
return $mutator; |
| 87 |
|
} |
| 88 |
|
|
| 89 |
|
return $this->config['mutatorAliases'][$mutator]; |
| 90 |
|
} |
| 91 |
|
|
| 92 |
|
/** |
| 93 |
|
* Get list of mutators associated with given type. |
source/Spiral/ORM/Configs/ORMConfig.php 1 location
|
@@ 57-64 (lines=8) @@
|
| 54 |
|
* @param string $mutator |
| 55 |
|
* @return string |
| 56 |
|
*/ |
| 57 |
|
public function mutatorAlias($mutator) |
| 58 |
|
{ |
| 59 |
|
if (!is_string($mutator) || !isset($this->config['mutatorAliases'][$mutator])) { |
| 60 |
|
return $mutator; |
| 61 |
|
} |
| 62 |
|
|
| 63 |
|
return $this->config['mutatorAliases'][$mutator]; |
| 64 |
|
} |
| 65 |
|
|
| 66 |
|
/** |
| 67 |
|
* Get list of mutators associated with given type. |
source/Spiral/Validation/Configs/ValidatorConfig.php 1 location
|
@@ 44-52 (lines=9) @@
|
| 41 |
|
* @param mixed $condition |
| 42 |
|
* @return mixed |
| 43 |
|
*/ |
| 44 |
|
public function resolveCondition($condition) |
| 45 |
|
{ |
| 46 |
|
if (is_string($condition) && isset($this->config['aliases'][$condition])) { |
| 47 |
|
//Condition were aliased |
| 48 |
|
$condition = $this->config['aliases'][$condition]; |
| 49 |
|
} |
| 50 |
|
|
| 51 |
|
return $condition; |
| 52 |
|
} |
| 53 |
|
|
| 54 |
|
/** |
| 55 |
|
* @param string $checker |