![]() |
Bearsampp 2026.9.23
|
Public Member Functions | |
| _addFailure ($field, $reason) | |
| _addWarning ($field, $reason) | |
| _validateFilelist () | |
| _validPackageName ($name) | |
| getFailures () | |
| setPackageFile (&$pf) | |
| validate ($state=null) | |
| validateChangelog () | |
| validateDate () | |
| validateDependencies () | |
| validateDeps () | |
| validateDescription () | |
| validateFilelist () | |
| validateLicense () | |
| validateMainFilelist () | |
| validateMaintainers () | |
| validateNotes () | |
| validatePackageName () | |
| validateReleaseFilelist () | |
| validateStability () | |
| validateState () | |
| validateSummary () | |
| validateTime () | |
| validateVersion () | |
| validPackageName ($name, $validatepackagename=false) | |
Static Public Member Functions | |
| static | getValidStates () |
| static | validGroupName ($name) |
| static | validState ($state) |
| static | validVersion ($ver) |
Data Fields | |
| $_failures = array('error' => array(), 'warning' => array()) | |
| $_packagexml | |
| $_state = PEAR_VALIDATE_NORMAL | |
| $packageregex = _PEAR_COMMON_PACKAGE_NAME_PREG | |
Definition at line 38 of file Validate.php.
| _addFailure | ( | $field, | |
| $reason ) |
@access private
Definition at line 137 of file Validate.php.
Referenced by validateDate(), validatePackageName(), validateStability(), validateState(), validateTime(), validateVersion(), and PEAR_Validator_PECL\validateVersion().
| _addWarning | ( | $field, | |
| $reason ) |
@access private
Definition at line 145 of file Validate.php.
Referenced by validateDate(), validatePackageName(), PEAR_Validator_PECL\validatePackageName(), and validateVersion().
| _validateFilelist | ( | ) |
for package.xml 1.0 only @access private
Definition at line 579 of file Validate.php.
| _validPackageName | ( | $name | ) |
Override this method to handle validation of normal package names
| string |
Definition at line 62 of file Validate.php.
Referenced by validPackageName().
| getFailures | ( | ) |
Definition at line 150 of file Validate.php.
References $_failures.
|
static |
Get a list of valid stability levels
Definition at line 109 of file Validate.php.
Referenced by validateStability(), and validateState().
| setPackageFile | ( | & | $pf | ) |
| PEAR_PackageFile_v1|PEAR_PackageFile_v2 |
Definition at line 129 of file Validate.php.
| validate | ( | $state = null | ) |
| int | one of the PEAR_VALIDATE_* constants |
Definition at line 160 of file Validate.php.
References validateChangelog(), validateDate(), validateDeps(), validateDescription(), validateFilelist(), validateLicense(), validateMainFilelist(), validateMaintainers(), validateNotes(), validatePackageName(), validateReleaseFilelist(), validateStability(), validateState(), validateSummary(), validateTime(), and validateVersion().
| validateChangelog | ( | ) |
@access protected
Definition at line 605 of file Validate.php.
Referenced by validate().
| validateDate | ( | ) |
@access protected
Definition at line 436 of file Validate.php.
References _addFailure(), _addWarning(), PEAR_VALIDATE_NORMAL, and PEAR_VALIDATE_PACKAGING.
Referenced by validate().
| validateDependencies | ( | ) |
for package.xml 2.0 only - channels can't use package.xml 1.0 @access protected
Definition at line 570 of file Validate.php.
| validateDeps | ( | ) |
@access protected
Definition at line 621 of file Validate.php.
Referenced by validate().
| validateDescription | ( | ) |
@access protected
Definition at line 545 of file Validate.php.
Referenced by validate().
| validateFilelist | ( | ) |
@access protected
Definition at line 613 of file Validate.php.
Referenced by validate().
| validateLicense | ( | ) |
@access protected
Definition at line 553 of file Validate.php.
Referenced by validate().
| validateMainFilelist | ( | ) |
for package.xml 2.0 only @access protected
Definition at line 588 of file Validate.php.
Referenced by validate().
| validateMaintainers | ( | ) |
@access protected
Definition at line 426 of file Validate.php.
Referenced by validate().
| validateNotes | ( | ) |
@access protected
Definition at line 561 of file Validate.php.
Referenced by validate().
| validatePackageName | ( | ) |
@access protected
Reimplemented in PEAR_Validator_PECL.
Definition at line 196 of file Validate.php.
References _addFailure(), _addWarning(), PEAR_VALIDATE_NORMAL, PEAR_VALIDATE_PACKAGING, and validPackageName().
Referenced by validate().
| validateReleaseFilelist | ( | ) |
for package.xml 2.0 only @access protected
Definition at line 597 of file Validate.php.
Referenced by validate().
| validateStability | ( | ) |
@access protected
Definition at line 512 of file Validate.php.
References _addFailure(), getValidStates(), and validState().
Referenced by validate().
| validateState | ( | ) |
@access protected
Definition at line 493 of file Validate.php.
References _addFailure(), getValidStates(), and validState().
Referenced by validate().
| validateSummary | ( | ) |
@access protected
Definition at line 537 of file Validate.php.
Referenced by validate().
| validateTime | ( | ) |
@access protected
Definition at line 463 of file Validate.php.
References $result, _addFailure(), and PEAR_VALIDATE_NORMAL.
Referenced by validate().
| validateVersion | ( | ) |
@access protected
Reimplemented in PEAR_Validator_PECL.
Definition at line 241 of file Validate.php.
References _addFailure(), _addWarning(), PEAR_VALIDATE_PACKAGING, and validVersion().
Referenced by validate().
|
static |
This validates a bundle name, and bundle names must conform to the PEAR naming convention, so the method is final and static.
| string | @final |
Definition at line 88 of file Validate.php.
References _PEAR_COMMON_PACKAGE_NAME_PREG.
Referenced by PEAR_PackageFile_v2_Validator\_validateDependencies(), and PEAR_Registry\parsePackageName().
| validPackageName | ( | $name, | |
| $validatepackagename = false ) |
| string | package name to validate |
| string | name of channel-specific validation package @final |
Definition at line 72 of file Validate.php.
References _validPackageName().
Referenced by validatePackageName().
|
static |
Determine whether $state represents a valid stability level
| string |
Definition at line 99 of file Validate.php.
Referenced by validateStability(), and validateState().
|
static |
Determine whether a version is a properly formatted version number that can be used by version_compare
| string |
Definition at line 121 of file Validate.php.
References PEAR_COMMON_PACKAGE_VERSION_PREG.
Referenced by validateVersion().
| $_failures = array('error' => array(), 'warning' => array()) |
Definition at line 54 of file Validate.php.
Referenced by getFailures().
| $_packagexml |
Definition at line 44 of file Validate.php.
| $_state = PEAR_VALIDATE_NORMAL |
Definition at line 48 of file Validate.php.
| $packageregex = _PEAR_COMMON_PACKAGE_NAME_PREG |
Definition at line 40 of file Validate.php.