[][src]Function bdrck::configuration::new

pub fn new<T: Clone + Serialize + DeserializeOwned + Send + 'static>(
    id: Identifier,
    default: T,
    custom_path: Option<&Path>
) -> Result<()>

new initializes a new configuration singleton with the given identifer, default set of configuration values, and custom disk persistence path (optional). An error might occur if determining the persistence path to use fails, or if deserializing the previously persisted configuration (if any) fails.