private static function transformValue($value) {
        if (gettype($value) === 'object') {

            if ($value instanceof QtiFile) {
                return taoQtiCommon_helpers_Utils::qtiFileToString($value);
            }
            else {
                return $value->__toString();
            }
        }
        else {
            return $value;
        }
    }