本文整理汇总了PHP中Parameter::getOriginalName方法的典型用法代码示例。如果您正苦于以下问题:PHP Parameter::getOriginalName方法的具体用法?PHP Parameter::getOriginalName怎么用?PHP Parameter::getOriginalName使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Parameter
的用法示例。
在下文中一共展示了Parameter::getOriginalName方法的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: getItemErrorMessage
/**
* @see ItemParameterCriterion::getItemErrorMessage
*/
protected function getItemErrorMessage(Parameter $parameter)
{
global $wgLang;
if ($this->lowerBound == $this->upperBound) {
return wfMsgExt('validator-error-invalid-length', 'parsemag', $parameter->getOriginalName(), $wgLang->formatNum($this->lowerBound));
} else {
return wfMsgExt('validator-error-invalid-length-range', 'parsemag', $parameter->getOriginalName(), $wgLang->formatNum($this->lowerBound), $wgLang->formatNum($this->upperBound));
}
}
示例2: getFullListErrorMessage
/**
* Gets an internationalized error message to construct a ValidationError with
* when the criteria validation failed. (for list values when all values are invalid)
*
* @param Parameter $parameter
*
* @since 0.4
*
* @return string
*/
protected function getFullListErrorMessage(Parameter $parameter)
{
return wfMsgExt('validator-error-problem', 'parsemag', $parameter->getOriginalName());
}
示例3: getFullListErrorMessage
/**
* @see ItemParameterCriterion::getFullListErrorMessage
*/
protected function getFullListErrorMessage(Parameter $parameter)
{
global $wgLang;
return wfMsgExt('validation-error-no-non-numerics', 'parsemag', $parameter->getOriginalName());
}
示例4: getFullListErrorMessage
/**
* @see ItemParameterCriterion::getFullListErrorMessage
*/
protected function getFullListErrorMessage(Parameter $parameter)
{
return wfMsgExt('validator_list_error_must_be_integer', 'parsemag', $parameter->getOriginalName());
}
示例5: getFullListErrorMessage
/**
* @see ItemParameterCriterion::getFullListErrorMessage
*/
protected function getFullListErrorMessage( Parameter $parameter ) {
return wfMsgExt( 'validator-list-error-invalid-regex', 'parsemag', $parameter->getOriginalName(), $this->pattern );
}
示例6: getFullListErrorMessage
/**
* @see ItemParameterCriterion::getFullListErrorMessage
*/
protected function getFullListErrorMessage( Parameter $parameter ) {
return wfMsgExt( 'validator_list_error_empty_argument', 'parsemag', $parameter->getOriginalName() );
}
示例7: getFullListErrorMessage
/**
* @see ItemParameterCriterion::getFullListErrorMessage
*/
protected function getFullListErrorMessage(Parameter $parameter)
{
$msg = 'validator_list_error_must_be_' . ($this->hasToExist ? 'existing_' : '') . 'title';
return wfMsgExt($msg, 'parsemag', $parameter->getOriginalName());
}
示例8: getFullListErrorMessage
/**
* @see ItemParameterCriterion::getFullListErrorMessage
*/
protected function getFullListErrorMessage( Parameter $parameter ) {
global $wgLang;
$originalCount = count( $this->allowedValues );
if ( $originalCount > 15 ) {
$allowedValues = array_slice( $this->allowedValues, 0, 13 );
$omitCount = $originalCount - count( $allowedValues );
return wfMsgExt(
'validator-list-error-accepts-only-omitted',
'parsemag',
$parameter->getOriginalName(),
$wgLang->listToText( $allowedValues ),
count( $allowedValues ),
$wgLang->formatNum( $omitCount )
);
}
else {
return wfMsgExt(
'validator-list-error-accepts-only',
'parsemag',
$parameter->getOriginalName(),
$wgLang->listToText( $this->allowedValues ),
count( $this->allowedValues ),
$parameter->getValue()
);
}
}
示例9: getItemErrorMessage
/**
* @see ItemParameterCriterion::getItemErrorMessage
*/
protected function getItemErrorMessage(Parameter $parameter)
{
return wfMsgExt("validation-error-invalid-{$this->dimension}", 'parsemag', $parameter->getOriginalName());
}
示例10: getFullListErrorMessage
/**
* @see ItemParameterCriterion::getFullListErrorMessage
*/
protected function getFullListErrorMessage(Parameter $parameter)
{
global $wgLang;
return wfMsgExt('validator_list_error_invalid_range', 'parsemag', $parameter->getOriginalName(), $wgLang->formatNum($this->lowerBound), $wgLang->formatNum($this->upperBound));
}
示例11: getItemErrorMessage
/**
* Gets an internationalized error message to construct a ValidationError with
* when the criteria validation failed. (for non-list values)
*
* @param Parameter $parameter
*
* @since 0.4
*
* @return string
*/
protected function getItemErrorMessage(Parameter $parameter)
{
return wfMsgExt('validation-error-invalid-line-param', 'parsemag', $parameter->getOriginalName());
}
示例12: getFullListErrorMessage
/**
* @see ItemParameterCriterion::getFullListErrorMessage
*/
protected function getFullListErrorMessage(Parameter $parameter)
{
return wfMessage('validation-error-invalid-layers', $parameter->getOriginalName())->parse();
}