pub struct NewProject {
pub name: String,
pub width: u32,
pub height: u32,
}
Expand description
Defines all form data required for creating a new project.
Fields§
§name: String
The human-friendly name of the project.
width: u32
The width in grid cells of the map.
height: u32
The height in grid cells of the map.
Trait Implementations§
Source§impl Debug for NewProject
impl Debug for NewProject
Source§impl Default for NewProject
impl Default for NewProject
Source§fn default() -> NewProject
fn default() -> NewProject
Returns the “default value” for a type. Read more
Source§impl RenderableDialog for NewProject
impl RenderableDialog for NewProject
Source§impl Validate for NewProject
impl Validate for NewProject
Source§fn validate_into(
&self,
__garde_user_ctx: &Self::Context,
__garde_path: &mut dyn FnMut() -> Path,
__garde_report: &mut Report,
)
fn validate_into( &self, __garde_user_ctx: &Self::Context, __garde_path: &mut dyn FnMut() -> Path, __garde_report: &mut Report, )
Validates
Self
, aggregating all validation errors into Report
.§fn validate(&self) -> Result<(), Report>where
Self::Context: Default,
fn validate(&self) -> Result<(), Report>where
Self::Context: Default,
Validates
Self
, returning an Err
with an aggregate of all errors if
the validation failed. Read more§fn validate_with(&self, ctx: &Self::Context) -> Result<(), Report>
fn validate_with(&self, ctx: &Self::Context) -> Result<(), Report>
Validates
Self
, returning an Err
with an aggregate of all errors if
the validation failed. Read moreAuto Trait Implementations§
impl Freeze for NewProject
impl RefUnwindSafe for NewProject
impl Send for NewProject
impl Sync for NewProject
impl Unpin for NewProject
impl UnwindSafe for NewProject
Blanket Implementations§
§impl<T, U> AsBindGroupShaderType<U> for T
impl<T, U> AsBindGroupShaderType<U> for T
§fn as_bind_group_shader_type(&self, _images: &RenderAssets<GpuImage>) -> U
fn as_bind_group_shader_type(&self, _images: &RenderAssets<GpuImage>) -> U
Return the
T
[ShaderType
] for self
. When used in [AsBindGroup
]
derives, it is safe to assume that all images in self
exist.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<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Converts
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
, which can then be
downcast
into Box<dyn ConcreteType>
where ConcreteType
implements Trait
.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Converts
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
, which can then be further
downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Converts
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Converts
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.§impl<T> DowncastSend for T
impl<T> DowncastSend for T
§impl<T> FromWorld for Twhere
T: Default,
impl<T> FromWorld for Twhere
T: Default,
§fn from_world(_world: &mut World) -> T
fn from_world(_world: &mut World) -> T
Creates Self
using default()
.
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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§impl<T> NoneValue for Twhere
T: Default,
impl<T> NoneValue for Twhere
T: Default,
type NoneType = T
§fn null_value() -> T
fn null_value() -> T
The none-equivalent value.