helpers/class.Utils.php
static public function isQtiFile(Variable $variable, $considerNull = true) {
        
        $correctBaseType = $variable->getBaseType() === BaseType::FILE;
        $correctCardinality = $variable->getCardinality() === Cardinality::SINGLE;
        $nullConsideration = ($considerNull === true) ? true : $variable->getValue() !== null;
        
        return $correctBaseType === true && $correctCardinality === true && $nullConsideration === true;
    }
static public function isQtiFile(Variable $variable, $considerNull = true) {
        
        $correctBaseType = $variable->getBaseType() === BaseType::FILE;
        $correctCardinality = $variable->getCardinality() === Cardinality::SINGLE;
        $nullConsideration = ($considerNull === true) ? true : $variable->getValue() !== null;
        
        return $correctBaseType === true && $correctCardinality === true && $nullConsideration === true;
    }
Whether or not a given QTI Variable contains a QTI File value.

@param Variable $variable
@param boolean $considerNull Whether or not to consider File variables containing NULL variables.
@return boolean