public function setToleranceMode($toleranceMode)
    {
        if (in_array($toleranceMode, ToleranceMode::asArray(), true)) {
            $this->toleranceMode = $toleranceMode;
        } else {
            $msg = "The toleranceMode argument must be a value from the ToleranceMode enumeration, '" . $toleranceMode . "' given.";
            throw new InvalidArgumentException($msg);
        }
    }
public function setToleranceMode($toleranceMode)
    {
        if (in_array($toleranceMode, ToleranceMode::asArray(), true)) {
            $this->toleranceMode = $toleranceMode;
        } else {
            $msg = "The toleranceMode argument must be a value from the ToleranceMode enumeration, '" . $toleranceMode . "' given.";
            throw new InvalidArgumentException($msg);
        }
    }
public function setToleranceMode ( $ toleranceMode ) { if ( in_array ( $ toleranceMode , ToleranceMode :: asArray ( ) , true ) ) { $ this -> toleranceMode = $ toleranceMode ; } else { $ msg = "The toleranceMode argument must be a value from the ToleranceMode enumeration, '" . $ toleranceMode . "' given." ; throw new InvalidArgumentException ( $ msg ) ; } }
Set the tolerance mode.

@param integer $toleranceMode A value from the ToleranceMode enumeration.
@throws \InvalidArgumentException If $toleranceMode is not a value from the ToleranceMode enumeration.
Set the tolerance mode .