/** * Setter function for string type. */ protected function setString($property, $value, $nullable = false) { if ($value === null) { if ($nullable) { $this->{$property} = null; } else { $this->warn("Null value given for '{$property}' property. Expected a string. Property not changed."); } } else { try { $value = LoggerOptionConverter::toStringEx($value); $this->{$property} = LoggerOptionConverter::substConstants($value); } catch (Exception $ex) { $value = var_export($value, true); $this->warn("Invalid value given for '{$property}' property: [{$value}]. Expected a string. Property not changed."); } } }