Now a REAL lib
This commit is contained in:
1
doc/toml/all.html
Normal file
1
doc/toml/all.html
Normal file
File diff suppressed because one or more lines are too long
11
doc/toml/datetime/enum.Offset.html
Normal file
11
doc/toml/datetime/enum.Offset.html
Normal file
@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta http-equiv="refresh" content="0;URL=../../toml/value/enum.Offset.html">
|
||||
<title>Redirection</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>Redirecting to <a href="../../toml/value/enum.Offset.html">../../toml/value/enum.Offset.html</a>...</p>
|
||||
<script>location.replace("../../toml/value/enum.Offset.html" + location.search + location.hash);</script>
|
||||
</body>
|
||||
</html>
|
||||
11
doc/toml/datetime/struct.Date.html
Normal file
11
doc/toml/datetime/struct.Date.html
Normal file
@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta http-equiv="refresh" content="0;URL=../../toml/value/struct.Date.html">
|
||||
<title>Redirection</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>Redirecting to <a href="../../toml/value/struct.Date.html">../../toml/value/struct.Date.html</a>...</p>
|
||||
<script>location.replace("../../toml/value/struct.Date.html" + location.search + location.hash);</script>
|
||||
</body>
|
||||
</html>
|
||||
11
doc/toml/datetime/struct.Datetime.html
Normal file
11
doc/toml/datetime/struct.Datetime.html
Normal file
@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta http-equiv="refresh" content="0;URL=../../toml/value/struct.Datetime.html">
|
||||
<title>Redirection</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>Redirecting to <a href="../../toml/value/struct.Datetime.html">../../toml/value/struct.Datetime.html</a>...</p>
|
||||
<script>location.replace("../../toml/value/struct.Datetime.html" + location.search + location.hash);</script>
|
||||
</body>
|
||||
</html>
|
||||
11
doc/toml/datetime/struct.DatetimeParseError.html
Normal file
11
doc/toml/datetime/struct.DatetimeParseError.html
Normal file
@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta http-equiv="refresh" content="0;URL=../../toml/value/struct.DatetimeParseError.html">
|
||||
<title>Redirection</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>Redirecting to <a href="../../toml/value/struct.DatetimeParseError.html">../../toml/value/struct.DatetimeParseError.html</a>...</p>
|
||||
<script>location.replace("../../toml/value/struct.DatetimeParseError.html" + location.search + location.hash);</script>
|
||||
</body>
|
||||
</html>
|
||||
11
doc/toml/datetime/struct.Time.html
Normal file
11
doc/toml/datetime/struct.Time.html
Normal file
@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta http-equiv="refresh" content="0;URL=../../toml/value/struct.Time.html">
|
||||
<title>Redirection</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>Redirecting to <a href="../../toml/value/struct.Time.html">../../toml/value/struct.Time.html</a>...</p>
|
||||
<script>location.replace("../../toml/value/struct.Time.html" + location.search + location.hash);</script>
|
||||
</body>
|
||||
</html>
|
||||
4
doc/toml/de/fn.from_slice.html
Normal file
4
doc/toml/de/fn.from_slice.html
Normal file
@ -0,0 +1,4 @@
|
||||
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Deserializes a byte slice into a type."><meta name="keywords" content="rust, rustlang, rust-lang, from_slice"><title>from_slice in toml::de - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" type="text/css" href="../../normalize.css"><link rel="stylesheet" type="text/css" href="../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../ayu.css" disabled><link rel="stylesheet" type="text/css" href="../../dark.css" disabled><link rel="stylesheet" type="text/css" href="../../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../../storage.js"></script><script defer src="sidebar-items.js"></script><script defer src="../../main.js"></script><noscript><link rel="stylesheet" href="../../noscript.css"></noscript><link rel="alternate icon" type="image/png" href="../../favicon-16x16.png"><link rel="alternate icon" type="image/png" href="../../favicon-32x32.png"><link rel="icon" type="image/svg+xml" href="../../favicon.svg"></head><body class="rustdoc fn"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle">☰</button><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"></h2></nav><nav class="sidebar"><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In toml::de</a></h2></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../toml/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><div id="help-button" title="help" tabindex="-1"><button type="button">?</button></div><div id="settings-menu" tabindex="-1"><a href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></div></form></nav></div><section id="main-content" class="content"><div class="main-heading"><h1 class="fqn"><span class="in-band">Function <a href="../index.html">toml</a>::<wbr><a href="index.html">de</a>::<wbr><a class="fn" href="#">from_slice</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/toml/de.rs.html#32-40">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>pub fn from_slice<'de, T>(bytes: &'de [<a class="primitive" href="https://doc.rust-lang.org/1.64.0/std/primitive.u8.html">u8</a>]) -> <a class="enum" href="https://doc.rust-lang.org/1.64.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, <a class="struct" href="struct.Error.html" title="struct toml::de::Error">Error</a>> <span class="where fmt-newline">where<br> T: <a class="trait" href="../../serde/de/trait.Deserialize.html" title="trait serde::de::Deserialize">Deserialize</a><'de>, </span></code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Deserializes a byte slice into a type.</p>
|
||||
<p>This function will attempt to interpret <code>bytes</code> as UTF-8 data and then
|
||||
deserialize <code>T</code> from the TOML document provided.</p>
|
||||
</div></details></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="toml" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.64.0 (a55dd71d5 2022-09-19)" ></div></body></html>
|
||||
27
doc/toml/de/fn.from_str.html
Normal file
27
doc/toml/de/fn.from_str.html
Normal file
@ -0,0 +1,27 @@
|
||||
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Deserializes a string into a type."><meta name="keywords" content="rust, rustlang, rust-lang, from_str"><title>from_str in toml::de - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" type="text/css" href="../../normalize.css"><link rel="stylesheet" type="text/css" href="../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../ayu.css" disabled><link rel="stylesheet" type="text/css" href="../../dark.css" disabled><link rel="stylesheet" type="text/css" href="../../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../../storage.js"></script><script defer src="sidebar-items.js"></script><script defer src="../../main.js"></script><noscript><link rel="stylesheet" href="../../noscript.css"></noscript><link rel="alternate icon" type="image/png" href="../../favicon-16x16.png"><link rel="alternate icon" type="image/png" href="../../favicon-32x32.png"><link rel="icon" type="image/svg+xml" href="../../favicon.svg"></head><body class="rustdoc fn"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle">☰</button><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"></h2></nav><nav class="sidebar"><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In toml::de</a></h2></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../toml/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><div id="help-button" title="help" tabindex="-1"><button type="button">?</button></div><div id="settings-menu" tabindex="-1"><a href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></div></form></nav></div><section id="main-content" class="content"><div class="main-heading"><h1 class="fqn"><span class="in-band">Function <a href="../index.html">toml</a>::<wbr><a href="index.html">de</a>::<wbr><a class="fn" href="#">from_str</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/toml/de.rs.html#73-81">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>pub fn from_str<'de, T>(s: &'de <a class="primitive" href="https://doc.rust-lang.org/1.64.0/std/primitive.str.html">str</a>) -> <a class="enum" href="https://doc.rust-lang.org/1.64.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, <a class="struct" href="struct.Error.html" title="struct toml::de::Error">Error</a>> <span class="where fmt-newline">where<br> T: <a class="trait" href="../../serde/de/trait.Deserialize.html" title="trait serde::de::Deserialize">Deserialize</a><'de>, </span></code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Deserializes a string into a type.</p>
|
||||
<p>This function will attempt to interpret <code>s</code> as a TOML document and
|
||||
deserialize <code>T</code> from the document.</p>
|
||||
<h2 id="examples"><a href="#examples">Examples</a></h2>
|
||||
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">use</span> <span class="ident">serde_derive::Deserialize</span>;
|
||||
|
||||
<span class="attribute">#[<span class="ident">derive</span>(<span class="ident">Deserialize</span>)]</span>
|
||||
<span class="kw">struct</span> <span class="ident">Config</span> {
|
||||
<span class="ident">title</span>: <span class="ident">String</span>,
|
||||
<span class="ident">owner</span>: <span class="ident">Owner</span>,
|
||||
}
|
||||
|
||||
<span class="attribute">#[<span class="ident">derive</span>(<span class="ident">Deserialize</span>)]</span>
|
||||
<span class="kw">struct</span> <span class="ident">Owner</span> {
|
||||
<span class="ident">name</span>: <span class="ident">String</span>,
|
||||
}
|
||||
|
||||
<span class="kw">let</span> <span class="ident">config</span>: <span class="ident">Config</span> <span class="op">=</span> <span class="ident">toml::from_str</span>(<span class="string">r#"
|
||||
title = 'TOML Example'
|
||||
|
||||
[owner]
|
||||
name = 'Lisa'
|
||||
"#</span>).<span class="ident">unwrap</span>();
|
||||
|
||||
<span class="macro">assert_eq!</span>(<span class="ident">config</span>.<span class="ident">title</span>, <span class="string">"TOML Example"</span>);
|
||||
<span class="macro">assert_eq!</span>(<span class="ident">config</span>.<span class="ident">owner</span>.<span class="ident">name</span>, <span class="string">"Lisa"</span>);</code></pre></div>
|
||||
</div></details></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="toml" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.64.0 (a55dd71d5 2022-09-19)" ></div></body></html>
|
||||
9
doc/toml/de/index.html
Normal file
9
doc/toml/de/index.html
Normal file
@ -0,0 +1,9 @@
|
||||
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Deserializing TOML into Rust structures."><meta name="keywords" content="rust, rustlang, rust-lang, de"><title>toml::de - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" type="text/css" href="../../normalize.css"><link rel="stylesheet" type="text/css" href="../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../ayu.css" disabled><link rel="stylesheet" type="text/css" href="../../dark.css" disabled><link rel="stylesheet" type="text/css" href="../../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../../storage.js"></script><script defer src="../../main.js"></script><noscript><link rel="stylesheet" href="../../noscript.css"></noscript><link rel="alternate icon" type="image/png" href="../../favicon-16x16.png"><link rel="alternate icon" type="image/png" href="../../favicon-32x32.png"><link rel="icon" type="image/svg+xml" href="../../favicon.svg"></head><body class="rustdoc mod"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle">☰</button><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"></h2></nav><nav class="sidebar"><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"><a href="#">Module de</a></h2><div class="sidebar-elems"><section><div class="block"><ul><li><a href="#structs">Structs</a></li><li><a href="#functions">Functions</a></li></ul></div></section></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../toml/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><div id="help-button" title="help" tabindex="-1"><button type="button">?</button></div><div id="settings-menu" tabindex="-1"><a href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></div></form></nav></div><section id="main-content" class="content"><div class="main-heading"><h1 class="fqn"><span class="in-band">Module <a href="../index.html">toml</a>::<wbr><a class="mod" href="#">de</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/toml/de.rs.html#1-2256">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Deserializing TOML into Rust structures.</p>
|
||||
<p>This module contains all the Serde support for deserializing TOML documents
|
||||
into Rust structures. Note that some top-level functions here are also
|
||||
provided at the top of the crate.</p>
|
||||
</div></details><h2 id="structs" class="small-section-header"><a href="#structs">Structs</a></h2><div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.Deserializer.html" title="toml::de::Deserializer struct">Deserializer</a></div><div class="item-right docblock-short"><p>Deserialization implementation for TOML.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.Error.html" title="toml::de::Error struct">Error</a></div><div class="item-right docblock-short"><p>Errors that can occur when deserializing a type.</p>
|
||||
</div></div></div><h2 id="functions" class="small-section-header"><a href="#functions">Functions</a></h2><div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.from_slice.html" title="toml::de::from_slice fn">from_slice</a></div><div class="item-right docblock-short"><p>Deserializes a byte slice into a type.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.from_str.html" title="toml::de::from_str fn">from_str</a></div><div class="item-right docblock-short"><p>Deserializes a string into a type.</p>
|
||||
</div></div></div></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="toml" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.64.0 (a55dd71d5 2022-09-19)" ></div></body></html>
|
||||
1
doc/toml/de/sidebar-items.js
Normal file
1
doc/toml/de/sidebar-items.js
Normal file
@ -0,0 +1 @@
|
||||
window.SIDEBAR_ITEMS = {"fn":[["from_slice","Deserializes a byte slice into a type."],["from_str","Deserializes a string into a type."]],"struct":[["Deserializer","Deserialization implementation for TOML."],["Error","Errors that can occur when deserializing a type."]]};
|
||||
83
doc/toml/de/struct.Deserializer.html
Normal file
83
doc/toml/de/struct.Deserializer.html
Normal file
File diff suppressed because one or more lines are too long
51
doc/toml/de/struct.Error.html
Normal file
51
doc/toml/de/struct.Error.html
Normal file
File diff suppressed because one or more lines are too long
121
doc/toml/index.html
Normal file
121
doc/toml/index.html
Normal file
@ -0,0 +1,121 @@
|
||||
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="A serde-compatible TOML-parsing library"><meta name="keywords" content="rust, rustlang, rust-lang, toml"><title>toml - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" type="text/css" href="../normalize.css"><link rel="stylesheet" type="text/css" href="../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../ayu.css" disabled><link rel="stylesheet" type="text/css" href="../dark.css" disabled><link rel="stylesheet" type="text/css" href="../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../storage.js"></script><script defer src="../crates.js"></script><script defer src="../main.js"></script><noscript><link rel="stylesheet" href="../noscript.css"></noscript><link rel="alternate icon" type="image/png" href="../favicon-16x16.png"><link rel="alternate icon" type="image/png" href="../favicon-32x32.png"><link rel="icon" type="image/svg+xml" href="../favicon.svg"></head><body class="rustdoc mod crate"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle">☰</button><a class="sidebar-logo" href="../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../rust-logo.svg" alt="logo"></div></a><h2 class="location"></h2></nav><nav class="sidebar"><a class="sidebar-logo" href="../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../rust-logo.svg" alt="logo"></div></a><h2 class="location"><a href="#">Crate toml</a></h2><div class="sidebar-elems"><div class="block"><ul><li class="version">Version 0.5.10</li><li><a id="all-types" href="all.html">All Items</a></li></ul></div><section><div class="block"><ul><li><a href="#reexports">Re-exports</a></li><li><a href="#modules">Modules</a></li><li><a href="#macros">Macros</a></li><li><a href="#structs">Structs</a></li></ul></div></section></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../toml/index.html"><img class="rust-logo" src="../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><div id="help-button" title="help" tabindex="-1"><button type="button">?</button></div><div id="settings-menu" tabindex="-1"><a href="../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../wheel.svg"></a></div></div></form></nav></div><section id="main-content" class="content"><div class="main-heading"><h1 class="fqn"><span class="in-band">Crate <a class="mod" href="#">toml</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../src/toml/lib.rs.html#1-176">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>A <a href="https://serde.rs/">serde</a>-compatible <a href="https://github.com/toml-lang/toml">TOML</a>-parsing library</p>
|
||||
<p>TOML itself is a simple, ergonomic, and readable configuration format:</p>
|
||||
<div class="example-wrap"><pre class="language-toml"><code>[package]
|
||||
name = "toml"
|
||||
version = "0.4.2"
|
||||
authors = ["Alex Crichton <alex@alexcrichton.com>"]
|
||||
|
||||
[dependencies]
|
||||
serde = "1.0"</code></pre></div>
|
||||
<p>The TOML format tends to be relatively common throughout the Rust community
|
||||
for configuration, notably being used by <a href="https://crates.io/">Cargo</a>, Rust’s package manager.</p>
|
||||
<h3 id="toml-values"><a href="#toml-values">TOML values</a></h3>
|
||||
<p>A value in TOML is represented with the <a href="value/enum.Value.html" title="Value"><code>Value</code></a> enum in this crate:</p>
|
||||
|
||||
<div class='information'><div class='tooltip ignore'>ⓘ</div></div><div class="example-wrap"><pre class="rust rust-example-rendered ignore"><code><span class="kw">pub</span> <span class="kw">enum</span> <span class="ident">Value</span> {
|
||||
<span class="ident">String</span>(<span class="ident">String</span>),
|
||||
<span class="ident">Integer</span>(<span class="ident">i64</span>),
|
||||
<span class="ident">Float</span>(<span class="ident">f64</span>),
|
||||
<span class="ident">Boolean</span>(<span class="ident">bool</span>),
|
||||
<span class="ident">Datetime</span>(<span class="ident">Datetime</span>),
|
||||
<span class="ident">Array</span>(<span class="ident">Array</span>),
|
||||
<span class="ident">Table</span>(<span class="ident">Table</span>),
|
||||
}</code></pre></div>
|
||||
<p>TOML is similar to JSON with the notable addition of a <a href="value/struct.Datetime.html" title="Datetime"><code>Datetime</code></a>
|
||||
type. In general, TOML and JSON are interchangeable in terms of
|
||||
formats.</p>
|
||||
<h3 id="parsing-toml"><a href="#parsing-toml">Parsing TOML</a></h3>
|
||||
<p>The easiest way to parse a TOML document is via the <a href="value/enum.Value.html" title="Value"><code>Value</code></a> type:</p>
|
||||
|
||||
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">use</span> <span class="ident">toml::Value</span>;
|
||||
|
||||
<span class="kw">let</span> <span class="ident">value</span> <span class="op">=</span> <span class="string">"foo = 'bar'"</span>.<span class="ident">parse</span>::<span class="op"><</span><span class="ident">Value</span><span class="op">></span>().<span class="ident">unwrap</span>();
|
||||
|
||||
<span class="macro">assert_eq!</span>(<span class="ident">value</span>[<span class="string">"foo"</span>].<span class="ident">as_str</span>(), <span class="prelude-val">Some</span>(<span class="string">"bar"</span>));</code></pre></div>
|
||||
<p>The <a href="value/enum.Value.html" title="Value"><code>Value</code></a> type implements a number of convenience methods and
|
||||
traits; the example above uses <a href="https://doc.rust-lang.org/1.64.0/core/str/traits/trait.FromStr.html" title="FromStr"><code>FromStr</code></a> to parse a <a href="https://doc.rust-lang.org/1.64.0/std/primitive.str.html" title="str"><code>str</code></a> into a
|
||||
<a href="value/enum.Value.html" title="Value"><code>Value</code></a>.</p>
|
||||
<h3 id="deserialization-and-serialization"><a href="#deserialization-and-serialization">Deserialization and Serialization</a></h3>
|
||||
<p>This crate supports <a href="https://serde.rs/"><code>serde</code></a> 1.0 with a number of
|
||||
implementations of the <code>Deserialize</code>, <code>Serialize</code>, <code>Deserializer</code>, and
|
||||
<code>Serializer</code> traits. Namely, you’ll find:</p>
|
||||
<ul>
|
||||
<li><code>Deserialize for Value</code></li>
|
||||
<li><code>Serialize for Value</code></li>
|
||||
<li><code>Deserialize for Datetime</code></li>
|
||||
<li><code>Serialize for Datetime</code></li>
|
||||
<li><code>Deserializer for de::Deserializer</code></li>
|
||||
<li><code>Serializer for ser::Serializer</code></li>
|
||||
<li><code>Deserializer for Value</code></li>
|
||||
</ul>
|
||||
<p>This means that you can use Serde to deserialize/serialize the
|
||||
<a href="value/enum.Value.html" title="Value"><code>Value</code></a> type as well as the <a href="value/struct.Datetime.html" title="Datetime"><code>Datetime</code></a> type in this crate. You can also
|
||||
use the <a href="de/struct.Deserializer.html" title="Deserializer"><code>Deserializer</code></a>, <a href="ser/struct.Serializer.html" title="Serializer"><code>Serializer</code></a>, or <a href="value/enum.Value.html" title="Value"><code>Value</code></a> type itself to act as
|
||||
a deserializer/serializer for arbitrary types.</p>
|
||||
<p>An example of deserializing with TOML is:</p>
|
||||
|
||||
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">use</span> <span class="ident">serde_derive::Deserialize</span>;
|
||||
|
||||
<span class="attribute">#[<span class="ident">derive</span>(<span class="ident">Deserialize</span>)]</span>
|
||||
<span class="kw">struct</span> <span class="ident">Config</span> {
|
||||
<span class="ident">ip</span>: <span class="ident">String</span>,
|
||||
<span class="ident">port</span>: <span class="prelude-ty">Option</span><span class="op"><</span><span class="ident">u16</span><span class="op">></span>,
|
||||
<span class="ident">keys</span>: <span class="ident">Keys</span>,
|
||||
}
|
||||
|
||||
<span class="attribute">#[<span class="ident">derive</span>(<span class="ident">Deserialize</span>)]</span>
|
||||
<span class="kw">struct</span> <span class="ident">Keys</span> {
|
||||
<span class="ident">github</span>: <span class="ident">String</span>,
|
||||
<span class="ident">travis</span>: <span class="prelude-ty">Option</span><span class="op"><</span><span class="ident">String</span><span class="op">></span>,
|
||||
}
|
||||
|
||||
<span class="kw">fn</span> <span class="ident">main</span>() {
|
||||
<span class="kw">let</span> <span class="ident">config</span>: <span class="ident">Config</span> <span class="op">=</span> <span class="ident">toml::from_str</span>(<span class="string">r#"
|
||||
ip = '127.0.0.1'
|
||||
|
||||
[keys]
|
||||
github = 'xxxxxxxxxxxxxxxxx'
|
||||
travis = 'yyyyyyyyyyyyyyyyy'
|
||||
"#</span>).<span class="ident">unwrap</span>();
|
||||
|
||||
<span class="macro">assert_eq!</span>(<span class="ident">config</span>.<span class="ident">ip</span>, <span class="string">"127.0.0.1"</span>);
|
||||
<span class="macro">assert_eq!</span>(<span class="ident">config</span>.<span class="ident">port</span>, <span class="prelude-val">None</span>);
|
||||
<span class="macro">assert_eq!</span>(<span class="ident">config</span>.<span class="ident">keys</span>.<span class="ident">github</span>, <span class="string">"xxxxxxxxxxxxxxxxx"</span>);
|
||||
<span class="macro">assert_eq!</span>(<span class="ident">config</span>.<span class="ident">keys</span>.<span class="ident">travis</span>.<span class="ident">as_ref</span>().<span class="ident">unwrap</span>(), <span class="string">"yyyyyyyyyyyyyyyyy"</span>);
|
||||
}</code></pre></div>
|
||||
<p>You can serialize types in a similar fashion:</p>
|
||||
|
||||
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">use</span> <span class="ident">serde_derive::Serialize</span>;
|
||||
|
||||
<span class="attribute">#[<span class="ident">derive</span>(<span class="ident">Serialize</span>)]</span>
|
||||
<span class="kw">struct</span> <span class="ident">Config</span> {
|
||||
<span class="ident">ip</span>: <span class="ident">String</span>,
|
||||
<span class="ident">port</span>: <span class="prelude-ty">Option</span><span class="op"><</span><span class="ident">u16</span><span class="op">></span>,
|
||||
<span class="ident">keys</span>: <span class="ident">Keys</span>,
|
||||
}
|
||||
|
||||
<span class="attribute">#[<span class="ident">derive</span>(<span class="ident">Serialize</span>)]</span>
|
||||
<span class="kw">struct</span> <span class="ident">Keys</span> {
|
||||
<span class="ident">github</span>: <span class="ident">String</span>,
|
||||
<span class="ident">travis</span>: <span class="prelude-ty">Option</span><span class="op"><</span><span class="ident">String</span><span class="op">></span>,
|
||||
}
|
||||
|
||||
<span class="kw">fn</span> <span class="ident">main</span>() {
|
||||
<span class="kw">let</span> <span class="ident">config</span> <span class="op">=</span> <span class="ident">Config</span> {
|
||||
<span class="ident">ip</span>: <span class="string">"127.0.0.1"</span>.<span class="ident">to_string</span>(),
|
||||
<span class="ident">port</span>: <span class="prelude-val">None</span>,
|
||||
<span class="ident">keys</span>: <span class="ident">Keys</span> {
|
||||
<span class="ident">github</span>: <span class="string">"xxxxxxxxxxxxxxxxx"</span>.<span class="ident">to_string</span>(),
|
||||
<span class="ident">travis</span>: <span class="prelude-val">Some</span>(<span class="string">"yyyyyyyyyyyyyyyyy"</span>.<span class="ident">to_string</span>()),
|
||||
},
|
||||
};
|
||||
|
||||
<span class="kw">let</span> <span class="ident">toml</span> <span class="op">=</span> <span class="ident">toml::to_string</span>(<span class="kw-2">&</span><span class="ident">config</span>).<span class="ident">unwrap</span>();
|
||||
}</code></pre></div>
|
||||
</div></details><h2 id="reexports" class="small-section-header"><a href="#reexports">Re-exports</a></h2><div class="item-table"><div class="item-row"><div class="item-left import-item" id="reexport.Value"><code>pub use crate::value::<a class="enum" href="value/enum.Value.html" title="enum toml::value::Value">Value</a>;</code></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left import-item" id="reexport.to_string"><code>pub use crate::ser::<a class="fn" href="ser/fn.to_string.html" title="fn toml::ser::to_string">to_string</a>;</code></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left import-item" id="reexport.to_string_pretty"><code>pub use crate::ser::<a class="fn" href="ser/fn.to_string_pretty.html" title="fn toml::ser::to_string_pretty">to_string_pretty</a>;</code></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left import-item" id="reexport.to_vec"><code>pub use crate::ser::<a class="fn" href="ser/fn.to_vec.html" title="fn toml::ser::to_vec">to_vec</a>;</code></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left import-item" id="reexport.Serializer"><code>pub use crate::ser::<a class="struct" href="ser/struct.Serializer.html" title="struct toml::ser::Serializer">Serializer</a>;</code></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left import-item" id="reexport.from_slice"><code>pub use crate::de::<a class="fn" href="de/fn.from_slice.html" title="fn toml::de::from_slice">from_slice</a>;</code></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left import-item" id="reexport.from_str"><code>pub use crate::de::<a class="fn" href="de/fn.from_str.html" title="fn toml::de::from_str">from_str</a>;</code></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left import-item" id="reexport.Deserializer"><code>pub use crate::de::<a class="struct" href="de/struct.Deserializer.html" title="struct toml::de::Deserializer">Deserializer</a>;</code></div><div class="item-right docblock-short"></div></div></div><h2 id="modules" class="small-section-header"><a href="#modules">Modules</a></h2><div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="mod" href="de/index.html" title="toml::de mod">de</a></div><div class="item-right docblock-short"><p>Deserializing TOML into Rust structures.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="mod" href="map/index.html" title="toml::map mod">map</a></div><div class="item-right docblock-short"><p>A map of String to toml::Value.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="mod" href="ser/index.html" title="toml::ser mod">ser</a></div><div class="item-right docblock-short"><p>Serializing Rust structures into TOML.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="mod" href="value/index.html" title="toml::value mod">value</a></div><div class="item-right docblock-short"><p>Definition of a TOML value</p>
|
||||
</div></div></div><h2 id="macros" class="small-section-header"><a href="#macros">Macros</a></h2><div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="macro" href="macro.toml.html" title="toml::toml macro">toml</a></div><div class="item-right docblock-short"><p>Construct a <a href="value/enum.Value.html"><code>toml::Value</code></a> from TOML syntax.</p>
|
||||
</div></div></div><h2 id="structs" class="small-section-header"><a href="#structs">Structs</a></h2><div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.Spanned.html" title="toml::Spanned struct">Spanned</a></div><div class="item-right docblock-short"><p>A spanned value, indicating the range at which it is defined in the source.</p>
|
||||
</div></div></div></section></div></main><div id="rustdoc-vars" data-root-path="../" data-current-crate="toml" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.64.0 (a55dd71d5 2022-09-19)" ></div></body></html>
|
||||
11
doc/toml/macro.toml!.html
Normal file
11
doc/toml/macro.toml!.html
Normal file
@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta http-equiv="refresh" content="0;URL=macro.toml.html">
|
||||
<title>Redirection</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>Redirecting to <a href="macro.toml.html">macro.toml.html</a>...</p>
|
||||
<script>location.replace("macro.toml.html" + location.search + location.hash);</script>
|
||||
</body>
|
||||
</html>
|
||||
24
doc/toml/macro.toml.html
Normal file
24
doc/toml/macro.toml.html
Normal file
@ -0,0 +1,24 @@
|
||||
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Construct a `toml::Value` from TOML syntax."><meta name="keywords" content="rust, rustlang, rust-lang, toml"><title>toml in toml - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" type="text/css" href="../normalize.css"><link rel="stylesheet" type="text/css" href="../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../ayu.css" disabled><link rel="stylesheet" type="text/css" href="../dark.css" disabled><link rel="stylesheet" type="text/css" href="../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../storage.js"></script><script defer src="sidebar-items.js"></script><script defer src="../main.js"></script><noscript><link rel="stylesheet" href="../noscript.css"></noscript><link rel="alternate icon" type="image/png" href="../favicon-16x16.png"><link rel="alternate icon" type="image/png" href="../favicon-32x32.png"><link rel="icon" type="image/svg+xml" href="../favicon.svg"></head><body class="rustdoc macro"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle">☰</button><a class="sidebar-logo" href="../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../rust-logo.svg" alt="logo"></div></a><h2 class="location"></h2></nav><nav class="sidebar"><a class="sidebar-logo" href="../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../rust-logo.svg" alt="logo"></div></a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In toml</a></h2></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../toml/index.html"><img class="rust-logo" src="../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><div id="help-button" title="help" tabindex="-1"><button type="button">?</button></div><div id="settings-menu" tabindex="-1"><a href="../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../wheel.svg"></a></div></div></form></nav></div><section id="main-content" class="content"><div class="main-heading"><h1 class="fqn"><span class="in-band">Macro <a href="index.html">toml</a>::<wbr><a class="macro" href="#">toml</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../src/toml/macros.rs.html#30-37">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><div class="example-wrap"><pre class="rust macro"><code><span class="macro">macro_rules!</span> <span class="ident">toml</span> {
|
||||
($(<span class="macro-nonterminal">$</span><span class="macro-nonterminal">toml</span>:<span class="ident">tt</span>)<span class="op">+</span>) => { ... };
|
||||
}</code></pre></div>
|
||||
</div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Construct a <a href="value/enum.Value.html"><code>toml::Value</code></a> from TOML syntax.</p>
|
||||
|
||||
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">let</span> <span class="ident">cargo_toml</span> <span class="op">=</span> <span class="macro">toml::toml!</span> {
|
||||
[<span class="ident">package</span>]
|
||||
<span class="ident">name</span> <span class="op">=</span> <span class="string">"toml"</span>
|
||||
<span class="ident">version</span> <span class="op">=</span> <span class="string">"0.4.5"</span>
|
||||
<span class="ident">authors</span> <span class="op">=</span> [<span class="string">"Alex Crichton <alex@alexcrichton.com>"</span>]
|
||||
|
||||
[<span class="ident">badges</span>]
|
||||
<span class="ident">travis</span><span class="op">-</span><span class="ident">ci</span> <span class="op">=</span> { <span class="ident">repository</span> <span class="op">=</span> <span class="string">"alexcrichton/toml-rs"</span> }
|
||||
|
||||
[<span class="ident">dependencies</span>]
|
||||
<span class="ident">serde</span> <span class="op">=</span> <span class="string">"1.0"</span>
|
||||
|
||||
[<span class="ident">dev</span><span class="op">-</span><span class="ident">dependencies</span>]
|
||||
<span class="ident">serde_derive</span> <span class="op">=</span> <span class="string">"1.0"</span>
|
||||
<span class="ident">serde_json</span> <span class="op">=</span> <span class="string">"1.0"</span>
|
||||
};
|
||||
|
||||
<span class="macro">println!</span>(<span class="string">"{:#?}"</span>, <span class="ident">cargo_toml</span>);</code></pre></div>
|
||||
</div></details></section></div></main><div id="rustdoc-vars" data-root-path="../" data-current-crate="toml" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.64.0 (a55dd71d5 2022-09-19)" ></div></body></html>
|
||||
25
doc/toml/map/enum.Entry.html
Normal file
25
doc/toml/map/enum.Entry.html
Normal file
File diff suppressed because one or more lines are too long
14
doc/toml/map/index.html
Normal file
14
doc/toml/map/index.html
Normal file
@ -0,0 +1,14 @@
|
||||
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="A map of String to toml::Value."><meta name="keywords" content="rust, rustlang, rust-lang, map"><title>toml::map - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" type="text/css" href="../../normalize.css"><link rel="stylesheet" type="text/css" href="../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../ayu.css" disabled><link rel="stylesheet" type="text/css" href="../../dark.css" disabled><link rel="stylesheet" type="text/css" href="../../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../../storage.js"></script><script defer src="../../main.js"></script><noscript><link rel="stylesheet" href="../../noscript.css"></noscript><link rel="alternate icon" type="image/png" href="../../favicon-16x16.png"><link rel="alternate icon" type="image/png" href="../../favicon-32x32.png"><link rel="icon" type="image/svg+xml" href="../../favicon.svg"></head><body class="rustdoc mod"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle">☰</button><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"></h2></nav><nav class="sidebar"><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"><a href="#">Module map</a></h2><div class="sidebar-elems"><section><div class="block"><ul><li><a href="#structs">Structs</a></li><li><a href="#enums">Enums</a></li></ul></div></section></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../toml/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><div id="help-button" title="help" tabindex="-1"><button type="button">?</button></div><div id="settings-menu" tabindex="-1"><a href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></div></form></nav></div><section id="main-content" class="content"><div class="main-heading"><h1 class="fqn"><span class="in-band">Module <a href="../index.html">toml</a>::<wbr><a class="mod" href="#">map</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/toml/map.rs.html#9-595">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>A map of String to toml::Value.</p>
|
||||
<p>By default the map is backed by a <a href="https://doc.rust-lang.org/std/collections/struct.BTreeMap.html"><code>BTreeMap</code></a>. Enable the <code>preserve_order</code>
|
||||
feature of toml-rs to use <a href="https://docs.rs/linked-hash-map/*/linked_hash_map/struct.LinkedHashMap.html"><code>LinkedHashMap</code></a> instead.</p>
|
||||
</div></details><h2 id="structs" class="small-section-header"><a href="#structs">Structs</a></h2><div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.IntoIter.html" title="toml::map::IntoIter struct">IntoIter</a></div><div class="item-right docblock-short"><p>An owning iterator over a toml::Map’s entries.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.Iter.html" title="toml::map::Iter struct">Iter</a></div><div class="item-right docblock-short"><p>An iterator over a toml::Map’s entries.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.IterMut.html" title="toml::map::IterMut struct">IterMut</a></div><div class="item-right docblock-short"><p>A mutable iterator over a toml::Map’s entries.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.Keys.html" title="toml::map::Keys struct">Keys</a></div><div class="item-right docblock-short"><p>An iterator over a toml::Map’s keys.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.Map.html" title="toml::map::Map struct">Map</a></div><div class="item-right docblock-short"><p>Represents a TOML key/value type.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.OccupiedEntry.html" title="toml::map::OccupiedEntry struct">OccupiedEntry</a></div><div class="item-right docblock-short"><p>An occupied Entry. It is part of the <a href="enum.Entry.html"><code>Entry</code></a> enum.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.VacantEntry.html" title="toml::map::VacantEntry struct">VacantEntry</a></div><div class="item-right docblock-short"><p>A vacant Entry. It is part of the <a href="enum.Entry.html"><code>Entry</code></a> enum.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.Values.html" title="toml::map::Values struct">Values</a></div><div class="item-right docblock-short"><p>An iterator over a toml::Map’s values.</p>
|
||||
</div></div></div><h2 id="enums" class="small-section-header"><a href="#enums">Enums</a></h2><div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="enum" href="enum.Entry.html" title="toml::map::Entry enum">Entry</a></div><div class="item-right docblock-short"><p>A view into a single entry in a map, which may either be vacant or occupied.
|
||||
This enum is constructed from the <a href="struct.Map.html#method.entry"><code>entry</code></a> method on <a href="struct.Map.html"><code>Map</code></a>.</p>
|
||||
</div></div></div></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="toml" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.64.0 (a55dd71d5 2022-09-19)" ></div></body></html>
|
||||
1
doc/toml/map/sidebar-items.js
Normal file
1
doc/toml/map/sidebar-items.js
Normal file
@ -0,0 +1 @@
|
||||
window.SIDEBAR_ITEMS = {"enum":[["Entry","A view into a single entry in a map, which may either be vacant or occupied. This enum is constructed from the `entry` method on `Map`."]],"struct":[["IntoIter","An owning iterator over a toml::Map’s entries."],["Iter","An iterator over a toml::Map’s entries."],["IterMut","A mutable iterator over a toml::Map’s entries."],["Keys","An iterator over a toml::Map’s keys."],["Map","Represents a TOML key/value type."],["OccupiedEntry","An occupied Entry. It is part of the `Entry` enum."],["VacantEntry","A vacant Entry. It is part of the `Entry` enum."],["Values","An iterator over a toml::Map’s values."]]};
|
||||
139
doc/toml/map/struct.IntoIter.html
Normal file
139
doc/toml/map/struct.IntoIter.html
Normal file
File diff suppressed because one or more lines are too long
139
doc/toml/map/struct.Iter.html
Normal file
139
doc/toml/map/struct.Iter.html
Normal file
File diff suppressed because one or more lines are too long
139
doc/toml/map/struct.IterMut.html
Normal file
139
doc/toml/map/struct.IterMut.html
Normal file
File diff suppressed because one or more lines are too long
139
doc/toml/map/struct.Keys.html
Normal file
139
doc/toml/map/struct.Keys.html
Normal file
File diff suppressed because one or more lines are too long
75
doc/toml/map/struct.Map.html
Normal file
75
doc/toml/map/struct.Map.html
Normal file
File diff suppressed because one or more lines are too long
20
doc/toml/map/struct.OccupiedEntry.html
Normal file
20
doc/toml/map/struct.OccupiedEntry.html
Normal file
File diff suppressed because one or more lines are too long
17
doc/toml/map/struct.VacantEntry.html
Normal file
17
doc/toml/map/struct.VacantEntry.html
Normal file
File diff suppressed because one or more lines are too long
139
doc/toml/map/struct.Values.html
Normal file
139
doc/toml/map/struct.Values.html
Normal file
File diff suppressed because one or more lines are too long
54
doc/toml/ser/enum.Error.html
Normal file
54
doc/toml/ser/enum.Error.html
Normal file
File diff suppressed because one or more lines are too long
13
doc/toml/ser/fn.tables_last.html
Normal file
13
doc/toml/ser/fn.tables_last.html
Normal file
File diff suppressed because one or more lines are too long
32
doc/toml/ser/fn.to_string.html
Normal file
32
doc/toml/ser/fn.to_string.html
Normal file
@ -0,0 +1,32 @@
|
||||
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Serialize the given data structure as a String of TOML."><meta name="keywords" content="rust, rustlang, rust-lang, to_string"><title>to_string in toml::ser - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" type="text/css" href="../../normalize.css"><link rel="stylesheet" type="text/css" href="../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../ayu.css" disabled><link rel="stylesheet" type="text/css" href="../../dark.css" disabled><link rel="stylesheet" type="text/css" href="../../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../../storage.js"></script><script defer src="sidebar-items.js"></script><script defer src="../../main.js"></script><noscript><link rel="stylesheet" href="../../noscript.css"></noscript><link rel="alternate icon" type="image/png" href="../../favicon-16x16.png"><link rel="alternate icon" type="image/png" href="../../favicon-32x32.png"><link rel="icon" type="image/svg+xml" href="../../favicon.svg"></head><body class="rustdoc fn"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle">☰</button><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"></h2></nav><nav class="sidebar"><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In toml::ser</a></h2></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../toml/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><div id="help-button" title="help" tabindex="-1"><button type="button">?</button></div><div id="settings-menu" tabindex="-1"><a href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></div></form></nav></div><section id="main-content" class="content"><div class="main-heading"><h1 class="fqn"><span class="in-band">Function <a href="../index.html">toml</a>::<wbr><a href="index.html">ser</a>::<wbr><a class="fn" href="#">to_string</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/toml/ser.rs.html#85-92">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>pub fn to_string<T: ?<a class="trait" href="https://doc.rust-lang.org/1.64.0/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>>(value: <a class="primitive" href="https://doc.rust-lang.org/1.64.0/std/primitive.reference.html">&</a>T) -> <a class="enum" href="https://doc.rust-lang.org/1.64.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><<a class="struct" href="https://doc.rust-lang.org/1.64.0/alloc/string/struct.String.html" title="struct alloc::string::String">String</a>, <a class="enum" href="enum.Error.html" title="enum toml::ser::Error">Error</a>> <span class="where fmt-newline">where<br> T: <a class="trait" href="../../serde/ser/trait.Serialize.html" title="trait serde::ser::Serialize">Serialize</a>, </span></code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Serialize the given data structure as a String of TOML.</p>
|
||||
<p>Serialization can fail if <code>T</code>’s implementation of <code>Serialize</code> decides to
|
||||
fail, if <code>T</code> contains a map with non-string keys, or if <code>T</code> attempts to
|
||||
serialize an unsupported datatype such as an enum, tuple, or tuple struct.</p>
|
||||
<h2 id="examples"><a href="#examples">Examples</a></h2>
|
||||
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">use</span> <span class="ident">serde_derive::Serialize</span>;
|
||||
|
||||
<span class="attribute">#[<span class="ident">derive</span>(<span class="ident">Serialize</span>)]</span>
|
||||
<span class="kw">struct</span> <span class="ident">Config</span> {
|
||||
<span class="ident">database</span>: <span class="ident">Database</span>,
|
||||
}
|
||||
|
||||
<span class="attribute">#[<span class="ident">derive</span>(<span class="ident">Serialize</span>)]</span>
|
||||
<span class="kw">struct</span> <span class="ident">Database</span> {
|
||||
<span class="ident">ip</span>: <span class="ident">String</span>,
|
||||
<span class="ident">port</span>: <span class="ident">Vec</span><span class="op"><</span><span class="ident">u16</span><span class="op">></span>,
|
||||
<span class="ident">connection_max</span>: <span class="ident">u32</span>,
|
||||
<span class="ident">enabled</span>: <span class="ident">bool</span>,
|
||||
}
|
||||
|
||||
<span class="kw">let</span> <span class="ident">config</span> <span class="op">=</span> <span class="ident">Config</span> {
|
||||
<span class="ident">database</span>: <span class="ident">Database</span> {
|
||||
<span class="ident">ip</span>: <span class="string">"192.168.1.1"</span>.<span class="ident">to_string</span>(),
|
||||
<span class="ident">port</span>: <span class="macro">vec!</span>[<span class="number">8001</span>, <span class="number">8002</span>, <span class="number">8003</span>],
|
||||
<span class="ident">connection_max</span>: <span class="number">5000</span>,
|
||||
<span class="ident">enabled</span>: <span class="bool-val">false</span>,
|
||||
},
|
||||
};
|
||||
|
||||
<span class="kw">let</span> <span class="ident">toml</span> <span class="op">=</span> <span class="ident">toml::to_string</span>(<span class="kw-2">&</span><span class="ident">config</span>).<span class="ident">unwrap</span>();
|
||||
<span class="macro">println!</span>(<span class="string">"{}"</span>, <span class="ident">toml</span>)</code></pre></div>
|
||||
</div></details></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="toml" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.64.0 (a55dd71d5 2022-09-19)" ></div></body></html>
|
||||
4
doc/toml/ser/fn.to_string_pretty.html
Normal file
4
doc/toml/ser/fn.to_string_pretty.html
Normal file
File diff suppressed because one or more lines are too long
5
doc/toml/ser/fn.to_vec.html
Normal file
5
doc/toml/ser/fn.to_vec.html
Normal file
File diff suppressed because one or more lines are too long
25
doc/toml/ser/index.html
Normal file
25
doc/toml/ser/index.html
Normal file
@ -0,0 +1,25 @@
|
||||
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Serializing Rust structures into TOML."><meta name="keywords" content="rust, rustlang, rust-lang, ser"><title>toml::ser - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" type="text/css" href="../../normalize.css"><link rel="stylesheet" type="text/css" href="../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../ayu.css" disabled><link rel="stylesheet" type="text/css" href="../../dark.css" disabled><link rel="stylesheet" type="text/css" href="../../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../../storage.js"></script><script defer src="../../main.js"></script><noscript><link rel="stylesheet" href="../../noscript.css"></noscript><link rel="alternate icon" type="image/png" href="../../favicon-16x16.png"><link rel="alternate icon" type="image/png" href="../../favicon-32x32.png"><link rel="icon" type="image/svg+xml" href="../../favicon.svg"></head><body class="rustdoc mod"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle">☰</button><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"></h2></nav><nav class="sidebar"><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"><a href="#">Module ser</a></h2><div class="sidebar-elems"><section><div class="block"><ul><li><a href="#structs">Structs</a></li><li><a href="#enums">Enums</a></li><li><a href="#functions">Functions</a></li></ul></div></section></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../toml/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><div id="help-button" title="help" tabindex="-1"><button type="button">?</button></div><div id="settings-menu" tabindex="-1"><a href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></div></form></nav></div><section id="main-content" class="content"><div class="main-heading"><h1 class="fqn"><span class="in-band">Module <a href="../index.html">toml</a>::<wbr><a class="mod" href="#">ser</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/toml/ser.rs.html#1-1853">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Serializing Rust structures into TOML.</p>
|
||||
<p>This module contains all the Serde support for serializing Rust structures
|
||||
into TOML documents (as strings). Note that some top-level functions here
|
||||
are also provided at the top of the crate.</p>
|
||||
<p>Note that the TOML format has a restriction that if a table itself contains
|
||||
tables, all keys with non-table values must be emitted first. This is
|
||||
typically easy to ensure happens when you’re defining a <code>struct</code> as you can
|
||||
reorder the fields manually, but when working with maps (such as <code>BTreeMap</code>
|
||||
or <code>HashMap</code>) this can lead to serialization errors. In those situations you
|
||||
may use the <code>tables_last</code> function in this module like so:</p>
|
||||
|
||||
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="attribute">#[<span class="ident">derive</span>(<span class="ident">Serialize</span>)]</span>
|
||||
<span class="kw">struct</span> <span class="ident">Manifest</span> {
|
||||
<span class="ident">package</span>: <span class="ident">Package</span>,
|
||||
<span class="attribute">#[<span class="ident">serde</span>(<span class="ident">serialize_with</span> <span class="op">=</span> <span class="string">"toml::ser::tables_last"</span>)]</span>
|
||||
<span class="ident">dependencies</span>: <span class="ident">HashMap</span><span class="op"><</span><span class="ident">String</span>, <span class="ident">Dependency</span><span class="op">></span>,
|
||||
}</code></pre></div>
|
||||
</div></details><h2 id="structs" class="small-section-header"><a href="#structs">Structs</a></h2><div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.Serializer.html" title="toml::ser::Serializer struct">Serializer</a></div><div class="item-right docblock-short"><p>Serialization implementation for TOML.</p>
|
||||
</div></div></div><h2 id="enums" class="small-section-header"><a href="#enums">Enums</a></h2><div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="enum" href="enum.Error.html" title="toml::ser::Error enum">Error</a></div><div class="item-right docblock-short"><p>Errors that can occur when serializing a type.</p>
|
||||
</div></div></div><h2 id="functions" class="small-section-header"><a href="#functions">Functions</a></h2><div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.tables_last.html" title="toml::ser::tables_last fn">tables_last</a></div><div class="item-right docblock-short"><p>Convenience function to serialize items in a map in an order valid with
|
||||
TOML.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.to_string.html" title="toml::ser::to_string fn">to_string</a></div><div class="item-right docblock-short"><p>Serialize the given data structure as a String of TOML.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.to_string_pretty.html" title="toml::ser::to_string_pretty fn">to_string_pretty</a></div><div class="item-right docblock-short"><p>Serialize the given data structure as a “pretty” String of TOML.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.to_vec.html" title="toml::ser::to_vec fn">to_vec</a></div><div class="item-right docblock-short"><p>Serialize the given data structure as a TOML byte vector.</p>
|
||||
</div></div></div></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="toml" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.64.0 (a55dd71d5 2022-09-19)" ></div></body></html>
|
||||
1
doc/toml/ser/sidebar-items.js
Normal file
1
doc/toml/ser/sidebar-items.js
Normal file
@ -0,0 +1 @@
|
||||
window.SIDEBAR_ITEMS = {"enum":[["Error","Errors that can occur when serializing a type."]],"fn":[["tables_last","Convenience function to serialize items in a map in an order valid with TOML."],["to_string","Serialize the given data structure as a String of TOML."],["to_string_pretty","Serialize the given data structure as a “pretty” String of TOML."],["to_vec","Serialize the given data structure as a TOML byte vector."]],"struct":[["Serializer","Serialization implementation for TOML."]]};
|
||||
144
doc/toml/ser/struct.Serializer.html
Normal file
144
doc/toml/ser/struct.Serializer.html
Normal file
File diff suppressed because one or more lines are too long
1
doc/toml/sidebar-items.js
Normal file
1
doc/toml/sidebar-items.js
Normal file
@ -0,0 +1 @@
|
||||
window.SIDEBAR_ITEMS = {"macro":[["toml","Construct a `toml::Value` from TOML syntax."]],"mod":[["de","Deserializing TOML into Rust structures."],["map","A map of String to toml::Value."],["ser","Serializing Rust structures into TOML."],["value","Definition of a TOML value"]],"struct":[["Spanned","A spanned value, indicating the range at which it is defined in the source."]]};
|
||||
11
doc/toml/spanned/struct.Spanned.html
Normal file
11
doc/toml/spanned/struct.Spanned.html
Normal file
@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta http-equiv="refresh" content="0;URL=../../toml/struct.Spanned.html">
|
||||
<title>Redirection</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>Redirecting to <a href="../../toml/struct.Spanned.html">../../toml/struct.Spanned.html</a>...</p>
|
||||
<script>location.replace("../../toml/struct.Spanned.html" + location.search + location.hash);</script>
|
||||
</body>
|
||||
</html>
|
||||
61
doc/toml/struct.Spanned.html
Normal file
61
doc/toml/struct.Spanned.html
Normal file
File diff suppressed because one or more lines are too long
37
doc/toml/value/enum.Offset.html
Normal file
37
doc/toml/value/enum.Offset.html
Normal file
File diff suppressed because one or more lines are too long
161
doc/toml/value/enum.Value.html
Normal file
161
doc/toml/value/enum.Value.html
Normal file
File diff suppressed because one or more lines are too long
13
doc/toml/value/index.html
Normal file
13
doc/toml/value/index.html
Normal file
@ -0,0 +1,13 @@
|
||||
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Definition of a TOML value"><meta name="keywords" content="rust, rustlang, rust-lang, value"><title>toml::value - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" type="text/css" href="../../normalize.css"><link rel="stylesheet" type="text/css" href="../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../ayu.css" disabled><link rel="stylesheet" type="text/css" href="../../dark.css" disabled><link rel="stylesheet" type="text/css" href="../../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../../storage.js"></script><script defer src="../../main.js"></script><noscript><link rel="stylesheet" href="../../noscript.css"></noscript><link rel="alternate icon" type="image/png" href="../../favicon-16x16.png"><link rel="alternate icon" type="image/png" href="../../favicon-32x32.png"><link rel="icon" type="image/svg+xml" href="../../favicon.svg"></head><body class="rustdoc mod"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle">☰</button><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"></h2></nav><nav class="sidebar"><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"><a href="#">Module value</a></h2><div class="sidebar-elems"><section><div class="block"><ul><li><a href="#reexports">Re-exports</a></li><li><a href="#structs">Structs</a></li><li><a href="#enums">Enums</a></li><li><a href="#traits">Traits</a></li><li><a href="#types">Type Definitions</a></li></ul></div></section></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../toml/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><div id="help-button" title="help" tabindex="-1"><button type="button">?</button></div><div id="settings-menu" tabindex="-1"><a href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></div></form></nav></div><section id="main-content" class="content"><div class="main-heading"><h1 class="fqn"><span class="in-band">Module <a href="../index.html">toml</a>::<wbr><a class="mod" href="#">value</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/toml/value.rs.html#1-1081">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Definition of a TOML value</p>
|
||||
</div></details><h2 id="reexports" class="small-section-header"><a href="#reexports">Re-exports</a></h2><div class="item-table"><div class="item-row"><div class="item-left import-item" id="reexport.Entry"><code>pub use crate::map::<a class="enum" href="../map/enum.Entry.html" title="enum toml::map::Entry">Entry</a>;</code></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left import-item" id="reexport.Map"><code>pub use crate::map::<a class="struct" href="../map/struct.Map.html" title="struct toml::map::Map">Map</a>;</code></div><div class="item-right docblock-short"></div></div></div><h2 id="structs" class="small-section-header"><a href="#structs">Structs</a></h2><div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.Date.html" title="toml::value::Date struct">Date</a></div><div class="item-right docblock-short"><p>A parsed TOML date value</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.Datetime.html" title="toml::value::Datetime struct">Datetime</a></div><div class="item-right docblock-short"><p>A parsed TOML datetime value</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.DatetimeParseError.html" title="toml::value::DatetimeParseError struct">DatetimeParseError</a></div><div class="item-right docblock-short"><p>Error returned from parsing a <code>Datetime</code> in the <code>FromStr</code> implementation.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.Time.html" title="toml::value::Time struct">Time</a></div><div class="item-right docblock-short"><p>A parsed TOML time value</p>
|
||||
</div></div></div><h2 id="enums" class="small-section-header"><a href="#enums">Enums</a></h2><div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="enum" href="enum.Offset.html" title="toml::value::Offset enum">Offset</a></div><div class="item-right docblock-short"><p>A parsed TOML time offset</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="enum" href="enum.Value.html" title="toml::value::Value enum">Value</a></div><div class="item-right docblock-short"><p>Representation of a TOML value.</p>
|
||||
</div></div></div><h2 id="traits" class="small-section-header"><a href="#traits">Traits</a></h2><div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="trait" href="trait.Index.html" title="toml::value::Index trait">Index</a></div><div class="item-right docblock-short"><p>Types that can be used to index a <code>toml::Value</code></p>
|
||||
</div></div></div><h2 id="types" class="small-section-header"><a href="#types">Type Definitions</a></h2><div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="type" href="type.Array.html" title="toml::value::Array type">Array</a></div><div class="item-right docblock-short"><p>Type representing a TOML array, payload of the <code>Value::Array</code> variant</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="type" href="type.Table.html" title="toml::value::Table type">Table</a></div><div class="item-right docblock-short"><p>Type representing a TOML table, payload of the <code>Value::Table</code> variant.
|
||||
By default it is backed by a BTreeMap, enable the <code>preserve_order</code> feature
|
||||
to use a LinkedHashMap instead.</p>
|
||||
</div></div></div></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="toml" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.64.0 (a55dd71d5 2022-09-19)" ></div></body></html>
|
||||
1
doc/toml/value/sidebar-items.js
Normal file
1
doc/toml/value/sidebar-items.js
Normal file
@ -0,0 +1 @@
|
||||
window.SIDEBAR_ITEMS = {"enum":[["Offset","A parsed TOML time offset"],["Value","Representation of a TOML value."]],"struct":[["Date","A parsed TOML date value"],["Datetime","A parsed TOML datetime value"],["DatetimeParseError","Error returned from parsing a `Datetime` in the `FromStr` implementation."],["Time","A parsed TOML time value"]],"trait":[["Index","Types that can be used to index a `toml::Value`"]],"type":[["Array","Type representing a TOML array, payload of the `Value::Array` variant"],["Table","Type representing a TOML table, payload of the `Value::Table` variant. By default it is backed by a BTreeMap, enable the `preserve_order` feature to use a LinkedHashMap instead."]]};
|
||||
37
doc/toml/value/struct.Date.html
Normal file
37
doc/toml/value/struct.Date.html
Normal file
File diff suppressed because one or more lines are too long
85
doc/toml/value/struct.Datetime.html
Normal file
85
doc/toml/value/struct.Datetime.html
Normal file
File diff suppressed because one or more lines are too long
25
doc/toml/value/struct.DatetimeParseError.html
Normal file
25
doc/toml/value/struct.DatetimeParseError.html
Normal file
File diff suppressed because one or more lines are too long
45
doc/toml/value/struct.Time.html
Normal file
45
doc/toml/value/struct.Time.html
Normal file
File diff suppressed because one or more lines are too long
6
doc/toml/value/trait.Index.html
Normal file
6
doc/toml/value/trait.Index.html
Normal file
@ -0,0 +1,6 @@
|
||||
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Types that can be used to index a `toml::Value`"><meta name="keywords" content="rust, rustlang, rust-lang, Index"><title>Index in toml::value - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" type="text/css" href="../../normalize.css"><link rel="stylesheet" type="text/css" href="../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../ayu.css" disabled><link rel="stylesheet" type="text/css" href="../../dark.css" disabled><link rel="stylesheet" type="text/css" href="../../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../../storage.js"></script><script defer src="sidebar-items.js"></script><script defer src="../../main.js"></script><noscript><link rel="stylesheet" href="../../noscript.css"></noscript><link rel="alternate icon" type="image/png" href="../../favicon-16x16.png"><link rel="alternate icon" type="image/png" href="../../favicon-32x32.png"><link rel="icon" type="image/svg+xml" href="../../favicon.svg"></head><body class="rustdoc trait"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle">☰</button><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"></h2></nav><nav class="sidebar"><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"><a href="#">Index</a></h2><div class="sidebar-elems"><section><div class="block"><h3 class="sidebar-title"><a href="#foreign-impls">Implementations on Foreign Types</a></h3><ul><li><a href="#impl-Index-for-%26%27s%20T">&'s T</a></li><li><a href="#impl-Index-for-String">String</a></li><li><a href="#impl-Index-for-str">str</a></li><li><a href="#impl-Index-for-usize">usize</a></li></ul></div><div class="block"><h3 class="sidebar-title"><a href="#implementors">Implementors</a></h3></div></section><h2 class="location"><a href="index.html">In toml::value</a></h2></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../toml/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><div id="help-button" title="help" tabindex="-1"><button type="button">?</button></div><div id="settings-menu" tabindex="-1"><a href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></div></form></nav></div><section id="main-content" class="content"><div class="main-heading"><h1 class="fqn"><span class="in-band">Trait <a href="../index.html">toml</a>::<wbr><a href="index.html">value</a>::<wbr><a class="trait" href="#">Index</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/toml/value.rs.html#312-317">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust trait"><code>pub trait Index: Sealed { }</code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Types that can be used to index a <code>toml::Value</code></p>
|
||||
<p>Currently this is implemented for <code>usize</code> to index arrays and <code>str</code> to index
|
||||
tables.</p>
|
||||
<p>This trait is sealed and not intended for implementation outside of the
|
||||
<code>toml</code> crate.</p>
|
||||
</div></details><h2 id="foreign-impls" class="small-section-header">Implementations on Foreign Types<a href="#foreign-impls" class="anchor"></a></h2><section id="impl-Index-for-usize" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/toml/value.rs.html#328-342">source</a></span><a href="#impl-Index-for-usize" class="anchor"></a><h3 class="code-header in-band">impl <a class="trait" href="trait.Index.html" title="trait toml::value::Index">Index</a> for <a class="primitive" href="https://doc.rust-lang.org/1.64.0/std/primitive.usize.html">usize</a></h3></section><section id="impl-Index-for-str" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/toml/value.rs.html#344-358">source</a></span><a href="#impl-Index-for-str" class="anchor"></a><h3 class="code-header in-band">impl <a class="trait" href="trait.Index.html" title="trait toml::value::Index">Index</a> for <a class="primitive" href="https://doc.rust-lang.org/1.64.0/std/primitive.str.html">str</a></h3></section><section id="impl-Index-for-String" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/toml/value.rs.html#360-368">source</a></span><a href="#impl-Index-for-String" class="anchor"></a><h3 class="code-header in-band">impl <a class="trait" href="trait.Index.html" title="trait toml::value::Index">Index</a> for <a class="struct" href="https://doc.rust-lang.org/1.64.0/alloc/string/struct.String.html" title="struct alloc::string::String">String</a></h3></section><section id="impl-Index-for-%26%27s%20T" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/toml/value.rs.html#370-381">source</a></span><a href="#impl-Index-for-%26%27s%20T" class="anchor"></a><h3 class="code-header in-band">impl<'s, T: ?<a class="trait" href="https://doc.rust-lang.org/1.64.0/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>> <a class="trait" href="trait.Index.html" title="trait toml::value::Index">Index</a> for <a class="primitive" href="https://doc.rust-lang.org/1.64.0/std/primitive.reference.html">&'s </a>T <span class="where fmt-newline">where<br> T: <a class="trait" href="trait.Index.html" title="trait toml::value::Index">Index</a>, </span></h3></section><h2 id="implementors" class="small-section-header">Implementors<a href="#implementors" class="anchor"></a></h2><div class="item-list" id="implementors-list"></div><script type="text/javascript" src="../../implementors/toml/value/trait.Index.js" data-ignore-extern-crates="std,alloc" async></script></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="toml" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.64.0 (a55dd71d5 2022-09-19)" ></div></body></html>
|
||||
2
doc/toml/value/type.Array.html
Normal file
2
doc/toml/value/type.Array.html
Normal file
@ -0,0 +1,2 @@
|
||||
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Type representing a TOML array, payload of the `Value::Array` variant"><meta name="keywords" content="rust, rustlang, rust-lang, Array"><title>Array in toml::value - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" type="text/css" href="../../normalize.css"><link rel="stylesheet" type="text/css" href="../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../ayu.css" disabled><link rel="stylesheet" type="text/css" href="../../dark.css" disabled><link rel="stylesheet" type="text/css" href="../../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../../storage.js"></script><script defer src="sidebar-items.js"></script><script defer src="../../main.js"></script><noscript><link rel="stylesheet" href="../../noscript.css"></noscript><link rel="alternate icon" type="image/png" href="../../favicon-16x16.png"><link rel="alternate icon" type="image/png" href="../../favicon-32x32.png"><link rel="icon" type="image/svg+xml" href="../../favicon.svg"></head><body class="rustdoc type"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle">☰</button><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"></h2></nav><nav class="sidebar"><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"><a href="#">Array</a></h2><div class="sidebar-elems"><h2 class="location"><a href="index.html">In toml::value</a></h2></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../toml/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><div id="help-button" title="help" tabindex="-1"><button type="button">?</button></div><div id="settings-menu" tabindex="-1"><a href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></div></form></nav></div><section id="main-content" class="content"><div class="main-heading"><h1 class="fqn"><span class="in-band">Type Definition <a href="../index.html">toml</a>::<wbr><a href="index.html">value</a>::<wbr><a class="type" href="#">Array</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/toml/value.rs.html#40">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust typedef"><code>pub type Array = <a class="struct" href="https://doc.rust-lang.org/1.64.0/alloc/vec/struct.Vec.html" title="struct alloc::vec::Vec">Vec</a><<a class="enum" href="enum.Value.html" title="enum toml::value::Value">Value</a>>;</code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Type representing a TOML array, payload of the <code>Value::Array</code> variant</p>
|
||||
</div></details></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="toml" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.64.0 (a55dd71d5 2022-09-19)" ></div></body></html>
|
||||
4
doc/toml/value/type.Table.html
Normal file
4
doc/toml/value/type.Table.html
Normal file
@ -0,0 +1,4 @@
|
||||
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Type representing a TOML table, payload of the `Value::Table` variant. By default it is backed by a BTreeMap, enable the `preserve_order` feature to use a LinkedHashMap instead."><meta name="keywords" content="rust, rustlang, rust-lang, Table"><title>Table in toml::value - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" type="text/css" href="../../normalize.css"><link rel="stylesheet" type="text/css" href="../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../ayu.css" disabled><link rel="stylesheet" type="text/css" href="../../dark.css" disabled><link rel="stylesheet" type="text/css" href="../../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../../storage.js"></script><script defer src="sidebar-items.js"></script><script defer src="../../main.js"></script><noscript><link rel="stylesheet" href="../../noscript.css"></noscript><link rel="alternate icon" type="image/png" href="../../favicon-16x16.png"><link rel="alternate icon" type="image/png" href="../../favicon-32x32.png"><link rel="icon" type="image/svg+xml" href="../../favicon.svg"></head><body class="rustdoc type"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle">☰</button><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"></h2></nav><nav class="sidebar"><a class="sidebar-logo" href="../../toml/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"><a href="#">Table</a></h2><div class="sidebar-elems"><h2 class="location"><a href="index.html">In toml::value</a></h2></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../toml/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><div id="help-button" title="help" tabindex="-1"><button type="button">?</button></div><div id="settings-menu" tabindex="-1"><a href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></div></form></nav></div><section id="main-content" class="content"><div class="main-heading"><h1 class="fqn"><span class="in-band">Type Definition <a href="../index.html">toml</a>::<wbr><a href="index.html">value</a>::<wbr><a class="type" href="#">Table</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/toml/value.rs.html#45">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust typedef"><code>pub type Table = <a class="struct" href="../map/struct.Map.html" title="struct toml::map::Map">Map</a><<a class="struct" href="https://doc.rust-lang.org/1.64.0/alloc/string/struct.String.html" title="struct alloc::string::String">String</a>, <a class="enum" href="enum.Value.html" title="enum toml::value::Value">Value</a>>;</code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Type representing a TOML table, payload of the <code>Value::Table</code> variant.
|
||||
By default it is backed by a BTreeMap, enable the <code>preserve_order</code> feature
|
||||
to use a LinkedHashMap instead.</p>
|
||||
</div></details></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="toml" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.64.0 (a55dd71d5 2022-09-19)" ></div></body></html>
|
||||
Reference in New Issue
Block a user