pub struct Workspace { /* fields omitted */ }
Extracts a string slice containing the entire String
.
Basic usage:
let s = String::from("foo");
assert_eq!("foo", s.as_str());
Returns this String
's capacity, in bytes.
Basic usage:
let s = String::with_capacity(10);
assert!(s.capacity() >= 10);
Returns a byte slice of this String
's contents.
The inverse of this method is from_utf8
.
Basic usage:
let s = String::from("hello");
assert_eq!(&[104, 101, 108, 108, 111], s.as_bytes());
Returns the length of this String
, in bytes.
Basic usage:
let a = String::from("foo");
assert_eq!(a.len(), 3);
Returns true
if this String
has a length of zero.
Returns false
otherwise.
Basic usage:
let mut v = String::new();
assert!(v.is_empty());
v.push('a');
assert!(!v.is_empty());
Performs copy-assignment from source
. Read more
Formats the value using the given formatter. Read more
The resulting type after dereferencing.
The associated error which can be returned from parsing.
Parses a string s
to return a value of this type. Read more
Creates owned data from borrowed data, usually by cloning. Read more
🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more
🔬 This is a nightly-only experimental API. (try_from
)
The type returned in the event of a conversion error.
🔬 This is a nightly-only experimental API. (try_from
)
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more
🔬 This is a nightly-only experimental API. (try_from
)
The type returned in the event of a conversion error.
🔬 This is a nightly-only experimental API. (try_from
)
🔬 This is a nightly-only experimental API. (get_type_id
)
this method will likely be replaced by an associated static
Convert self
to an expression for Diesel's query builder. Read more
Convert &self
to an expression for Diesel's query builder. Read more