#[non_exhaustive]pub struct PackageDescriptionBuilder { /* private fields */ }
Expand description
A builder for PackageDescription
.
Implementations§
source§impl PackageDescriptionBuilder
impl PackageDescriptionBuilder
sourcepub fn format(self, input: PackageFormat) -> Self
pub fn format(self, input: PackageFormat) -> Self
A format that specifies the type of the package.
sourcepub fn set_format(self, input: Option<PackageFormat>) -> Self
pub fn set_format(self, input: Option<PackageFormat>) -> Self
A format that specifies the type of the package.
sourcepub fn get_format(&self) -> &Option<PackageFormat>
pub fn get_format(&self) -> &Option<PackageFormat>
A format that specifies the type of the package.
sourcepub fn namespace(self, input: impl Into<String>) -> Self
pub fn namespace(self, input: impl Into<String>) -> Self
The namespace of the package. The package component that specifies its namespace depends on its type. For example:
-
The namespace of a Maven package version is its
groupId
. -
The namespace of an npm or Swift package version is its
scope
. -
The namespace of a generic package is its
namespace
. -
Python, NuGet, and Ruby package versions do not contain a corresponding component, package versions of those formats do not have a namespace.
sourcepub fn set_namespace(self, input: Option<String>) -> Self
pub fn set_namespace(self, input: Option<String>) -> Self
The namespace of the package. The package component that specifies its namespace depends on its type. For example:
-
The namespace of a Maven package version is its
groupId
. -
The namespace of an npm or Swift package version is its
scope
. -
The namespace of a generic package is its
namespace
. -
Python, NuGet, and Ruby package versions do not contain a corresponding component, package versions of those formats do not have a namespace.
sourcepub fn get_namespace(&self) -> &Option<String>
pub fn get_namespace(&self) -> &Option<String>
The namespace of the package. The package component that specifies its namespace depends on its type. For example:
-
The namespace of a Maven package version is its
groupId
. -
The namespace of an npm or Swift package version is its
scope
. -
The namespace of a generic package is its
namespace
. -
Python, NuGet, and Ruby package versions do not contain a corresponding component, package versions of those formats do not have a namespace.
sourcepub fn origin_configuration(self, input: PackageOriginConfiguration) -> Self
pub fn origin_configuration(self, input: PackageOriginConfiguration) -> Self
The package origin configuration for the package.
sourcepub fn set_origin_configuration(
self,
input: Option<PackageOriginConfiguration>,
) -> Self
pub fn set_origin_configuration( self, input: Option<PackageOriginConfiguration>, ) -> Self
The package origin configuration for the package.
sourcepub fn get_origin_configuration(&self) -> &Option<PackageOriginConfiguration>
pub fn get_origin_configuration(&self) -> &Option<PackageOriginConfiguration>
The package origin configuration for the package.
sourcepub fn build(self) -> PackageDescription
pub fn build(self) -> PackageDescription
Consumes the builder and constructs a PackageDescription
.
Trait Implementations§
source§impl Clone for PackageDescriptionBuilder
impl Clone for PackageDescriptionBuilder
source§fn clone(&self) -> PackageDescriptionBuilder
fn clone(&self) -> PackageDescriptionBuilder
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for PackageDescriptionBuilder
impl Debug for PackageDescriptionBuilder
source§impl Default for PackageDescriptionBuilder
impl Default for PackageDescriptionBuilder
source§fn default() -> PackageDescriptionBuilder
fn default() -> PackageDescriptionBuilder
source§impl PartialEq for PackageDescriptionBuilder
impl PartialEq for PackageDescriptionBuilder
source§fn eq(&self, other: &PackageDescriptionBuilder) -> bool
fn eq(&self, other: &PackageDescriptionBuilder) -> bool
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for PackageDescriptionBuilder
Auto Trait Implementations§
impl Freeze for PackageDescriptionBuilder
impl RefUnwindSafe for PackageDescriptionBuilder
impl Send for PackageDescriptionBuilder
impl Sync for PackageDescriptionBuilder
impl Unpin for PackageDescriptionBuilder
impl UnwindSafe for PackageDescriptionBuilder
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
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>
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>
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