pub struct File {
pub per_file: HashSet<Flag>,
pub per_contract: HashSet<Flag>,
}Expand description
The solc --standard-json output file selection.
Fields§
§per_file: HashSet<Flag>The per-file output selections.
per_contract: HashSet<Flag>The per-contract output selections, common for all contracts.
Only the “all” (*) wildcard is available for robustness reasons.
Implementations§
Source§impl File
impl File
Sourcepub fn new(flags: Vec<SelectionFlag>) -> Self
pub fn new(flags: Vec<SelectionFlag>) -> Self
Creates the selection for all contracts with arbitrary flags.
Sourcepub fn new_required_for_codegen() -> Self
pub fn new_required_for_codegen() -> Self
Creates the selection required by our compilation process.
Sourcepub fn new_required_for_tests() -> Self
pub fn new_required_for_tests() -> Self
Creates the selection required for test compilation (includes EVM bytecode).
Sourcepub fn extend(&mut self, other: Self) -> &mut Self
pub fn extend(&mut self, other: Self) -> &mut Self
Extends the output selection with another one.
Sourcepub fn selection_to_prune(&self) -> Self
pub fn selection_to_prune(&self) -> Self
Returns flags that were not explicitly requested by the user.
These flags are used to prune JSON output before returning it, removing any output that was automatically added but not requested.
Sourcepub fn contains(&self, flag: SelectionFlag) -> bool
pub fn contains(&self, flag: SelectionFlag) -> bool
Checks whether the flag is requested.
Sourcepub fn contains_any(&self, flags: &[SelectionFlag]) -> bool
pub fn contains_any(&self, flags: &[SelectionFlag]) -> bool
Checks whether any of the flags is requested.
Sourcepub fn requests_codegen(&self) -> bool
pub fn requests_codegen(&self) -> bool
Checks whether code generation is requested.