pub struct FunctionLibrary {
pub name: String,
pub version: String,
pub description: String,
pub functions: Vec<FunctionPackage>,
pub dependencies: Vec<String>,
}Expand description
Function library for managing collections of functions
Fields§
§name: StringLibrary name
version: StringLibrary version
description: StringLibrary description
functions: Vec<FunctionPackage>Functions in the library
dependencies: Vec<String>Library dependencies
Implementations§
Source§impl FunctionLibrary
impl FunctionLibrary
Sourcepub fn new(name: String, version: String, description: String) -> Self
pub fn new(name: String, version: String, description: String) -> Self
Create a new function library
Sourcepub fn add_function(&mut self, package: FunctionPackage)
pub fn add_function(&mut self, package: FunctionPackage)
Add a function to the library
Sourcepub fn add_dependency(&mut self, dependency: String)
pub fn add_dependency(&mut self, dependency: String)
Add a dependency to the library
Sourcepub fn deploy_all(&self, manager: &FunctionDeploymentManager) -> Result<()>
pub fn deploy_all(&self, manager: &FunctionDeploymentManager) -> Result<()>
Deploy all functions in the library
Sourcepub fn list_functions(&self) -> Vec<String>
pub fn list_functions(&self) -> Vec<String>
List function names in the library
Trait Implementations§
Source§impl Clone for FunctionLibrary
impl Clone for FunctionLibrary
Source§fn clone(&self) -> FunctionLibrary
fn clone(&self) -> FunctionLibrary
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FunctionLibrary
impl Debug for FunctionLibrary
Source§impl<'de> Deserialize<'de> for FunctionLibrary
impl<'de> Deserialize<'de> for FunctionLibrary
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
Auto Trait Implementations§
impl Freeze for FunctionLibrary
impl RefUnwindSafe for FunctionLibrary
impl Send for FunctionLibrary
impl Sync for FunctionLibrary
impl Unpin for FunctionLibrary
impl UnsafeUnpin for FunctionLibrary
impl UnwindSafe for FunctionLibrary
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more