Struct ethers_solc::ProjectCompileOutput [−][src]
pub struct ProjectCompileOutput<T: ArtifactOutput> { /* fields omitted */ }
Expand description
The outcome of Project::compile
Implementations
pub fn from_compiler_output(
compiler_output: CompilerOutput,
ignored_error_codes: Vec<u64>
) -> Self
pub fn from_compiler_output_and_cache(
compiler_output: CompilerOutput,
cache: BTreeMap<PathBuf, T::Artifact>,
ignored_error_codes: Vec<u64>
) -> Self
Get the (merged) solc compiler output
use std::collections::BTreeMap;
use ethers_solc::artifacts::Contract;
use ethers_solc::Project;
let project = Project::builder().build().unwrap();
let contracts: BTreeMap<String, Contract> =
project.compile().unwrap().output().contracts_into_iter().collect();
Combine two outputs
Whether this type does not contain compiled contracts
Whether this type has a compiler output
Whether there were errors
All artifacts together with their contract name
Example
use std::collections::BTreeMap;
use ethers_solc::artifacts::CompactContract;
use ethers_solc::Project;
let project = Project::builder().build().unwrap();
let contracts: BTreeMap<String, CompactContract> = project.compile().unwrap().into_artifacts().collect();
Trait Implementations
impl<T: Default + ArtifactOutput> Default for ProjectCompileOutput<T> where
T::Artifact: Default,
impl<T: Default + ArtifactOutput> Default for ProjectCompileOutput<T> where
T::Artifact: Default,
Returns the “default value” for a type. Read more
impl<T: PartialEq + ArtifactOutput> PartialEq<ProjectCompileOutput<T>> for ProjectCompileOutput<T> where
T::Artifact: PartialEq,
impl<T: PartialEq + ArtifactOutput> PartialEq<ProjectCompileOutput<T>> for ProjectCompileOutput<T> where
T::Artifact: PartialEq,
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
Auto Trait Implementations
impl<T> RefUnwindSafe for ProjectCompileOutput<T> where
<T as ArtifactOutput>::Artifact: RefUnwindSafe,
impl<T> Send for ProjectCompileOutput<T> where
<T as ArtifactOutput>::Artifact: Send,
impl<T> Sync for ProjectCompileOutput<T> where
<T as ArtifactOutput>::Artifact: Sync,
impl<T> Unpin for ProjectCompileOutput<T>
impl<T> UnwindSafe for ProjectCompileOutput<T> where
<T as ArtifactOutput>::Artifact: RefUnwindSafe,
Blanket Implementations
Mutably borrows from an owned value. Read more
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more