src/snac/server/validation/validators/IDValidator.php
/**
     * Validate a Source
     *
     * @param \snac\data\Source $source Source to validate
     * @param mixed $context optional Any context information needed for validation
     * @return boolean true if valid, false otherwise
     */
Validate a Source
@param \snac\data\Source $source Source to validate
@param mixed $context optional Any context information needed for validation
@return boolean true if valid, false otherwise
Validate a Source @param \ snac \ data \ Source $source Source to validate @param mixed $context optional Any context information needed for validation @return boolean true if valid false otherwise
public function validateSource($source, $context=null) {
        $preID = "";
        $list = $this->constellation->getSources();
        if ($context != null) {
            $list = array($context->getCitation());
            $preID = $context->getID() . ":";
        }
        return $this->validateGenericWithLanguage($source, $list, "source", $preID);
    }
public function validateSource ( $ source , $ context = null ) { $ preID = " " ; $ list = $ this -> constellation -> getSources ( ) ; if ( $ context != null ) { $ list = array ( $ context -> getCitation ( ) ) ; $ preID = $ context -> getID ( ) . " : " ; } return $ this -> validateGenericWithLanguage ( $ source , $ list , " source " , $ preID ) ; }
Validate a Source
 @param \snac\data\Source $source Source to validate
 @param mixed $context optional Any context information needed for validation
 @return boolean true if valid, false otherwise
Validate a Source @param \ snac \ data \ Source $source Source to validate @param mixed $context optional Any context information needed for validation @return boolean true if valid false otherwise
// Get sources from the constellation // If there is a context (only an SCM object), use that (in list form) instead, and add pre-id