Skip to main content

Artifacts

Struct Artifacts 

Source
pub struct Artifacts {
    pub proc: Option<Arc<DaggerSessionProc>>,
    pub selection: Selection,
    pub graphql_client: DynGraphQLClient,
}

Fields§

§proc: Option<Arc<DaggerSessionProc>>§selection: Selection§graphql_client: DynGraphQLClient

Implementations§

Source§

impl Artifacts

Source

pub async fn id(&self) -> Result<Id, DaggerError>

A unique identifier for this Artifacts.

Source

pub async fn as_expertise(&self) -> Result<Vec<Expertise>, DaggerError>

Convert the selection to expertise without running the functions. Each must take one LLM! argument and return LLM!; any other arguments must be optional or auto-filled. Agent arguments receive the agent that owns the conversation. A module load failure fails with its load error.

Source

pub async fn as_generators(&self) -> Result<Vec<Generator>, DaggerError>

Convert the selection to Generators without running them. Fail if any artifact is not a Generator. Module load failures are skipped: generating can repair them.

Source

pub async fn as_checks(&self) -> Result<Vec<Check>, DaggerError>

Convert the selection to Checks. Fail if any artifact is not a Check. A module load failure is a Check that fails with its load error. Does not apply command filters or run the checks.

Source

pub async fn as_changesets(&self) -> Result<Vec<Changeset>, DaggerError>

Convert the selection to Changesets. Fail if any artifact is not a Changeset; a module load failure fails with its load error. Does not apply command filters.

Source

pub async fn as_services(&self) -> Result<Vec<Service>, DaggerError>

Convert the selection to Services. Fail if any artifact is not a Service; a module load failure fails with its load error. Does not apply command filters or start the services.

Source

pub async fn path_definitions(&self) -> Result<Vec<ArtifactPath>, DaggerError>

List selected schema paths, including empty collections. Does not read runtime values. Applies type keys and collection presence; collection key values require items.

§Arguments
  • opt - optional argument, see inner type for documentation, use _opts to use
Source

pub async fn path_definitions_opts<'a>( &self, opts: ArtifactsPathDefinitionsOpts<'a>, ) -> Result<Vec<ArtifactPath>, DaggerError>

List selected schema paths, including empty collections. Does not read runtime values. Applies type keys and collection presence; collection key values require items.

§Arguments
  • opt - optional argument, see inner type for documentation, use _opts to use
Source

pub async fn dimension_definitions( &self, ) -> Result<Vec<ArtifactDimension>, DaggerError>

List dimensions on the selected schema paths, including empty collections. Does not read runtime values.

Source

pub async fn values(&self) -> Result<Vec<ArtifactResult>, DaggerError>

Evaluate the selection in parallel, retaining each result and error.

§Arguments
  • opt - optional argument, see inner type for documentation, use _opts to use
Source

pub async fn values_opts( &self, opts: ArtifactsValuesOpts, ) -> Result<Vec<ArtifactResult>, DaggerError>

Evaluate the selection in parallel, retaining each result and error.

§Arguments
  • opt - optional argument, see inner type for documentation, use _opts to use
Source

pub async fn modules(&self) -> Result<Vec<Module>, DaggerError>

List the modules represented in this selection without evaluating artifact values.

Source

pub async fn types(&self) -> Result<Vec<TypeDef>, DaggerError>

List concrete type definitions represented in this selection, sorted by name with no duplicates.

Source

pub fn filter_directives(&self, directives: Vec<impl Into<String>>) -> Artifacts

Keep artifacts with any listed directive. Does not filter by type or workspace settings.

§Arguments
  • opt - optional argument, see inner type for documentation, use _opts to use
Source

pub fn filter_directives_opts( &self, directives: Vec<impl Into<String>>, opts: ArtifactsFilterDirectivesOpts, ) -> Artifacts

Keep artifacts with any listed directive. Does not filter by type or workspace settings.

§Arguments
  • opt - optional argument, see inner type for documentation, use _opts to use
Source

pub fn filter_parent_types(&self, types: Vec<impl Into<String>>) -> Artifacts

Keep artifacts whose immediate parent has any listed object type. Artifacts without a typed parent do not match.

§Arguments
  • opt - optional argument, see inner type for documentation, use _opts to use
Source

pub fn filter_parent_types_opts( &self, types: Vec<impl Into<String>>, opts: ArtifactsFilterParentTypesOpts, ) -> Artifacts

Keep artifacts whose immediate parent has any listed object type. Artifacts without a typed parent do not match.

§Arguments
  • opt - optional argument, see inner type for documentation, use _opts to use
Source

pub fn filter_parent_directives( &self, directives: Vec<impl Into<String>>, ) -> Artifacts

Keep artifacts whose immediate parent has any listed directive. Artifacts without a parent do not match.

§Arguments
  • opt - optional argument, see inner type for documentation, use _opts to use
Source

pub fn filter_parent_directives_opts( &self, directives: Vec<impl Into<String>>, opts: ArtifactsFilterParentDirectivesOpts, ) -> Artifacts

Keep artifacts whose immediate parent has any listed directive. Artifacts without a parent do not match.

§Arguments
  • opt - optional argument, see inner type for documentation, use _opts to use
Source

pub fn with_artifacts(&self, artifacts: impl IntoID<Id>) -> Artifacts

Combine two selections, keeping each workspace address once. Different addresses remain distinct even if they return the same object.

Source

pub fn without_uri(&self, uri: impl Into<String>) -> Artifacts

Remove artifacts selected by a DAG address.

Source

pub fn filter_types(&self, types: Vec<impl Into<String>>) -> Artifacts

Keep artifacts of any listed concrete GraphQL type.

§Arguments
  • opt - optional argument, see inner type for documentation, use _opts to use
Source

pub fn filter_types_opts( &self, types: Vec<impl Into<String>>, opts: ArtifactsFilterTypesOpts, ) -> Artifacts

Keep artifacts of any listed concrete GraphQL type.

§Arguments
  • opt - optional argument, see inner type for documentation, use _opts to use
Source

pub fn filter_path(&self, path: Vec<impl Into<String>>) -> Artifacts

Match one complete, ordered field sequence exactly.

Source

pub fn filter_path_pattern(&self, pattern: impl Into<String>) -> Artifacts

Keep paths that match a glob pattern. A literal path matches exactly. Both module-qualified and workspace main paths match.

Source

pub fn filter_dimensions(&self, dimensions: Vec<impl Into<String>>) -> Artifacts

Keep artifacts selected through any listed dimension.

Source

pub fn filter_dimension_keys( &self, dimension: impl Into<String>, keys: Vec<impl Into<String>>, ) -> Artifacts

Keep artifacts with any listed key in this dimension.

Source

pub fn filter_uri(&self, uri: impl Into<String>) -> Artifacts

Apply a DAG address as one filter: the chain of path, type, and dimension-key filters it encodes. The scheme is optional. The path may be a pattern; an empty path selects all artifacts. A module that failed to load keeps its load failure when the module could hold what the address selects, as with every filter (see Artifacts).

§Arguments
  • uri - A DAG address: [dag[+]://][][?=&…]
Source

pub async fn dimensions(&self) -> Result<Vec<String>, DaggerError>

List dimension identifiers represented in this selection, sorted with no duplicates.

Source

pub async fn dimension_keys( &self, dimension: impl Into<String>, ) -> Result<Vec<String>, DaggerError>

List keys represented in this selection for the given dimension, sorted with no duplicates.

Source

pub async fn dimension_items( &self, dimension: impl Into<String>, ) -> Result<Vec<Artifact>, DaggerError>

List collection items represented in this selection for the given dimension. Preserve parent keys and remove duplicate item addresses. Does not evaluate item values.

Source

pub async fn items(&self) -> Result<Vec<Artifact>, DaggerError>

Enumerate complete artifacts without evaluating their values.

Source

pub fn one(&self) -> Artifact

Require exactly one artifact; fail if there are zero or multiple matches. Several matches are listed, one address per line.

Source

pub async fn uri(&self) -> Result<String, DaggerError>

The DAG address that selects this whole selection: filterUri(uri) selects the same set.

Trait Implementations§

Source§

impl Clone for Artifacts

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl IntoID<Id> for Artifacts

Source§

fn into_id( self, ) -> Pin<Box<dyn Future<Output = Result<Id, DaggerError>> + Send>>

Source§

impl Loadable for Artifacts

Source§

fn graphql_type() -> &'static str

The GraphQL type name (e.g. "Container").
Source§

fn from_query( proc: Option<Arc<DaggerSessionProc>>, selection: Selection, graphql_client: DynGraphQLClient, ) -> Self

Construct this type from a query selection.
Source§

impl Node for Artifacts

Source§

fn id(&self) -> impl Future<Output = Result<Id, DaggerError>> + Send

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self> ⓘ

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self> ⓘ

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
where F: FnOnce(&Self) -> bool,

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
Source§

impl<T> PolicyExt for T
where T: ?Sized,

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘ
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more