pub struct DeclarativePackage {
pub meta: PackageMetadata,
pub properties: PackageProperties,
pub addons: HashMap<String, DeclarativeAddon>,
pub relations: DeclarativePackageRelations,
pub conditional_rules: Vec<DeclarativeConditionalRule>,
}
Expand description
Structure for a declarative / JSON package
Fields§
§meta: PackageMetadata
Metadata for the package
properties: PackageProperties
Properties for the package
addons: HashMap<String, DeclarativeAddon>
Addons that the package installs
relations: DeclarativePackageRelations
Relationships with other packages
conditional_rules: Vec<DeclarativeConditionalRule>
Changes to conditionally apply to the package
Implementations§
Source§impl DeclarativePackage
impl DeclarativePackage
Sourcepub fn improve_generation(&mut self)
pub fn improve_generation(&mut self)
Improve a generated package by inferring certain fields
Trait Implementations§
Source§impl Clone for DeclarativePackage
impl Clone for DeclarativePackage
Source§fn clone(&self) -> DeclarativePackage
fn clone(&self) -> DeclarativePackage
Returns a duplicate of the value. Read more
1.0.0 · 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 DeclarativePackage
impl Debug for DeclarativePackage
Source§impl Default for DeclarativePackage
impl Default for DeclarativePackage
Source§fn default() -> DeclarativePackage
fn default() -> DeclarativePackage
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for DeclarativePackagewhere
DeclarativePackage: Default,
impl<'de> Deserialize<'de> for DeclarativePackagewhere
DeclarativePackage: Default,
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 DeclarativePackage
impl RefUnwindSafe for DeclarativePackage
impl Send for DeclarativePackage
impl Sync for DeclarativePackage
impl Unpin for DeclarativePackage
impl UnwindSafe for DeclarativePackage
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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