Struct fj::models::ModelMetadata
source · pub struct ModelMetadata {
pub name: String,
pub description: Option<String>,
pub arguments: Vec<ArgumentMetadata>,
}
Expand description
Metadata about a crate::models::Model
.
Fields§
§name: String
A short, human-friendly name used to identify this model.
description: Option<String>
A description of what this model does.
arguments: Vec<ArgumentMetadata>
Arguments that the model uses when calculating its geometry.
Implementations§
source§impl ModelMetadata
impl ModelMetadata
sourcepub fn with_description(self, description: impl Into<String>) -> Self
pub fn with_description(self, description: impl Into<String>) -> Self
Set the ModelMetadata::description
.
sourcepub fn with_argument(self, arg: impl Into<ArgumentMetadata>) -> Self
pub fn with_argument(self, arg: impl Into<ArgumentMetadata>) -> Self
Add an argument to the ModelMetadata::arguments
list.
As a convenience, string literals can be automatically converted into
ArgumentMetadata
with no description or default value.
Trait Implementations§
source§impl Clone for ModelMetadata
impl Clone for ModelMetadata
source§fn clone(&self) -> ModelMetadata
fn clone(&self) -> ModelMetadata
Returns a copy 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 ModelMetadata
impl Debug for ModelMetadata
source§impl PartialEq<ModelMetadata> for ModelMetadata
impl PartialEq<ModelMetadata> for ModelMetadata
source§fn eq(&self, other: &ModelMetadata) -> bool
fn eq(&self, other: &ModelMetadata) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.