pub struct Rustdoc {
cmd: Command,
}
Fields§
§cmd: Command
Implementations§
Source§impl Rustdoc
impl Rustdoc
Sourcepub fn env_remove<K>(&mut self, key: K) -> &mut Self
pub fn env_remove<K>(&mut self, key: K) -> &mut Self
Remove an environmental variable.
Sourcepub fn arg<S>(&mut self, arg: S) -> &mut Self
pub fn arg<S>(&mut self, arg: S) -> &mut Self
Generic command argument provider. Prefer specific helper methods if possible. Note that for some executables, arguments might be platform specific. For C/C++ compilers, arguments might be platform and compiler specific.
Sourcepub fn args<V, S>(&mut self, args: V) -> &mut Self
pub fn args<V, S>(&mut self, args: V) -> &mut Self
Generic command arguments provider. Prefer specific helper methods if possible. Note that for some executables, arguments might be platform specific. For C/C++ compilers, arguments might be platform and compiler specific.
Sourcepub fn stdin<T: Into<Stdio>>(&mut self, cfg: T) -> &mut Self
pub fn stdin<T: Into<Stdio>>(&mut self, cfg: T) -> &mut Self
Configuration for the child process’s standard input (stdin) handle.
Sourcepub fn stdout<T: Into<Stdio>>(&mut self, cfg: T) -> &mut Self
pub fn stdout<T: Into<Stdio>>(&mut self, cfg: T) -> &mut Self
Configuration for the child process’s standard output (stdout) handle.
Sourcepub fn stderr<T: Into<Stdio>>(&mut self, cfg: T) -> &mut Self
pub fn stderr<T: Into<Stdio>>(&mut self, cfg: T) -> &mut Self
Configuration for the child process’s standard error (stderr) handle.
Sourcepub fn inspect<I>(&mut self, inspector: I) -> &mut Self
pub fn inspect<I>(&mut self, inspector: I) -> &mut Self
Inspect what the underlying Command
is up to the
current construction.
Sourcepub fn run(&mut self) -> CompletedProcess
pub fn run(&mut self) -> CompletedProcess
Run the constructed command and assert that it is successfully run.
Sourcepub fn run_fail(&mut self) -> CompletedProcess
pub fn run_fail(&mut self) -> CompletedProcess
Run the constructed command and assert that it does not successfully run.
Sourcepub fn run_unchecked(&mut self) -> CompletedProcess
pub fn run_unchecked(&mut self) -> CompletedProcess
Run the command but do not check its exit status.
Only use if you explicitly don’t care about the exit status.
Prefer to use Self::run
and Self::run_fail
whenever possible.
Sourcepub fn current_dir<P: AsRef<Path>>(&mut self, path: P) -> &mut Self
pub fn current_dir<P: AsRef<Path>>(&mut self, path: P) -> &mut Self
Set the path where the command will be run.
Source§impl Rustdoc
impl Rustdoc
Sourcepub fn extern_<P: AsRef<Path>>(
&mut self,
crate_name: &str,
path: P,
) -> &mut Self
pub fn extern_<P: AsRef<Path>>( &mut self, crate_name: &str, path: P, ) -> &mut Self
Specify where an external library is located.
Sourcepub fn arg_file<P: AsRef<Path>>(&mut self, path: P) -> &mut Self
pub fn arg_file<P: AsRef<Path>>(&mut self, path: P) -> &mut Self
Given a path
, pass @{path}
to rustdoc
as an
arg file.
Sourcepub fn stdin_buf<I: AsRef<[u8]>>(&mut self, input: I) -> &mut Self
pub fn stdin_buf<I: AsRef<[u8]>>(&mut self, input: I) -> &mut Self
Specify a stdin input buffer.
Sourcepub fn target<S: AsRef<str>>(&mut self, target: S) -> &mut Self
pub fn target<S: AsRef<str>>(&mut self, target: S) -> &mut Self
Specify the target triple, or a path to a custom target json spec file.
Sourcepub fn crate_type(&mut self, crate_type: &str) -> &mut Self
pub fn crate_type(&mut self, crate_type: &str) -> &mut Self
Specify the crate type.
Sourcepub fn crate_name<S: AsRef<OsStr>>(&mut self, name: S) -> &mut Self
pub fn crate_name<S: AsRef<OsStr>>(&mut self, name: S) -> &mut Self
Specify the crate name.
Sourcepub fn library_search_path<P: AsRef<Path>>(&mut self, path: P) -> &mut Self
pub fn library_search_path<P: AsRef<Path>>(&mut self, path: P) -> &mut Self
Add a directory to the library search path. It corresponds to the -L
rustdoc option.
Sourcepub fn output_format(&mut self, format: &str) -> &mut Self
pub fn output_format(&mut self, format: &str) -> &mut Self
Specify the output format.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Rustdoc
impl !RefUnwindSafe for Rustdoc
impl Send for Rustdoc
impl Sync for Rustdoc
impl Unpin for Rustdoc
impl !UnwindSafe for Rustdoc
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 312 bytes