/** * Converts the comparison value used in the constructor to one which can be compared against that returned * by the relevant model. * * @param $rawComparisonValue * @param Collection $list * @return mixed */ protected final function getTransformedComparisonValue($rawComparisonValue, Collection $list) { $exampleObject = SolutionSchema::getModel($list->getModelClassName()); $columnSchema = $exampleObject->getColumnSchemaForColumnReference($this->columnName); if ($columnSchema != null) { $closure = $columnSchema->getTransformIntoModelData(); if ($closure !== null) { $rawComparisonValue = $closure($rawComparisonValue); } } return $rawComparisonValue; }