pub struct Vypers {
pub path_to_code: Vec<PathBuf>,
pub bytecode: Option<Vec<String>>,
pub abi: Vec<PathBuf>,
pub venv: Option<PathBuf>,
}Expand description
Represents multiple vyper contracts
Fields§
§path_to_code: Vec<PathBuf>§bytecode: Option<Vec<String>>§abi: Vec<PathBuf>§venv: Option<PathBuf>Implementations§
Source§impl Vypers
impl Vypers
Sourcepub fn with_all(
paths: Vec<PathBuf>,
abi_paths: Vec<PathBuf>,
venv: Option<PathBuf>,
) -> Self
pub fn with_all( paths: Vec<PathBuf>, abi_paths: Vec<PathBuf>, venv: Option<PathBuf>, ) -> Self
Constructor function that takes in the paths to your vyper contracts and the _desired paths/{names}.json for your ABIs
pub fn new(paths: Vec<PathBuf>) -> Self
pub fn in_dir(path: PathBuf) -> Option<Vypers>
pub async fn in_workspace(path: PathBuf) -> Option<Vypers>
pub fn with_venv(paths: Vec<PathBuf>, venv: &Path) -> Self
pub fn set_venv(self, venv: PathBuf) -> Vypers
pub fn get_vyper(&self) -> String
pub fn get_pip(&self) -> String
Sourcepub async fn compile_many(&mut self) -> Result<(), VyperErrors>
pub async fn compile_many(&mut self) -> Result<(), VyperErrors>
Compile multiple vyper contracts concurrently on new threads, updates the ABI field in Vypers
Sourcepub async fn compile_many_ver(&mut self, ver: Evm) -> Result<(), VyperErrors>
pub async fn compile_many_ver(&mut self, ver: Evm) -> Result<(), VyperErrors>
Compile multiple vyper contracts concurrently on new threads, updates the ABI field in Vypers. Ver arg is for specifying EVM version to compile each contract to.
Sourcepub async fn gen_abi_many(&mut self) -> Result<(), VyperErrors>
pub async fn gen_abi_many(&mut self) -> Result<(), VyperErrors>
Generates ABIs for each vyper contract concurrently
pub async fn get_abi_many(&self) -> Result<Vec<Value>, VyperErrors>
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Vypers
impl<'de> Deserialize<'de> for Vypers
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Ord for Vypers
impl Ord for Vypers
Source§impl PartialOrd for Vypers
impl PartialOrd for Vypers
impl Eq for Vypers
impl StructuralPartialEq for Vypers
Auto Trait Implementations§
impl Freeze for Vypers
impl RefUnwindSafe for Vypers
impl Send for Vypers
impl Sync for Vypers
impl Unpin for Vypers
impl UnwindSafe for Vypers
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
Mutably borrows from an owned value. Read more