JSON
JSON
Represents the application configuration.
serialize(integer $format = self::JSON) : string
Serialize the current data collection.
integer | $format | an integer representing one of the allowed formats |
the serialization format is invalid
the error occurred while serializing the collection in json format
the collection serialized
deserialize(string|array|\Gishiki\Algorithms\Collections\CollectionInterface $message, integer $format = self::JSON) : \Gishiki\Algorithms\Collections\SerializableCollection
Deserialize the given data collection and create a serializable data collection.
string|array|\Gishiki\Algorithms\Collections\CollectionInterface | $message | the string containing the serialized data or the array of data |
integer | $format | an integer representing one of the allowed formats |
the error preventing the data deserialization
the deserialization result
loadFromFile(string|null $filename = null) : \Gishiki\Core\Configuration
Parse the given configuration file.
Read the given file in JSON format and produce a Configuration from it, where placeholders have been replaced with correct values.
string|null | $filename | the name of the file to be used or null for default |
the given file cannot be found
the parsed configuration