Struct mdbook::config::jsonconfig::JsonConfig
[−]
[src]
pub struct JsonConfig {
pub src: Option<PathBuf>,
pub dest: Option<PathBuf>,
pub title: Option<String>,
pub author: Option<String>,
pub description: Option<String>,
pub theme_path: Option<PathBuf>,
pub google_analytics: Option<String>,
}The JSON configuration is deprecated and will be removed in the near future. Please migrate to the TOML configuration.
Fields
src: Option<PathBuf>
dest: Option<PathBuf>
title: Option<String>
description: Option<String>
theme_path: Option<PathBuf>
google_analytics: Option<String>
Methods
impl JsonConfig[src]
Returns a JsonConfig from a JSON string
let json = r#"{ "title": "Some title", "dest": "htmlbook" }"#; let config = JsonConfig::from_json(&json).expect("Should parse correctly"); assert_eq!(config.title, Some(String::from("Some title"))); assert_eq!(config.dest, Some(PathBuf::from("htmlbook")));
Trait Implementations
impl Debug for JsonConfig[src]
impl Clone for JsonConfig[src]
fn clone(&self) -> JsonConfig
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0
Performs copy-assignment from source. Read more
impl PartialEq for JsonConfig[src]
fn eq(&self, __arg_0: &JsonConfig) -> bool
This method tests for self and other values to be equal, and is used by ==. Read more
fn ne(&self, __arg_0: &JsonConfig) -> bool
This method tests for !=.