pub struct TrainingParameterDesc<'a> { /* private fields */ }Expand description
Runtime-thread descriptor for one session-visible parameter.
Implementations§
Source§impl<'a> TrainingParameterDesc<'a>
impl<'a> TrainingParameterDesc<'a>
Sourcepub fn mutable(
name: impl Into<String>,
parameter_class: TrainingParameterClass,
kind: TrainingValueKind,
get: impl Fn() -> TrainingValue + 'a,
set: impl FnMut(&TrainingValue) -> Result<()> + 'a,
) -> Self
pub fn mutable( name: impl Into<String>, parameter_class: TrainingParameterClass, kind: TrainingValueKind, get: impl Fn() -> TrainingValue + 'a, set: impl FnMut(&TrainingValue) -> Result<()> + 'a, ) -> Self
Describe a mutable parameter and its runtime-thread accessors.
Sourcepub fn immutable(
name: impl Into<String>,
kind: TrainingValueKind,
get: impl Fn() -> TrainingValue + 'a,
) -> Self
pub fn immutable( name: impl Into<String>, kind: TrainingValueKind, get: impl Fn() -> TrainingValue + 'a, ) -> Self
Describe an immutable observable parameter.
Sourcepub fn numeric_range(self, minimum: f64, maximum: f64) -> Self
pub fn numeric_range(self, minimum: f64, maximum: f64) -> Self
Declare an inclusive numeric range.
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for TrainingParameterDesc<'a>
impl<'a> !Send for TrainingParameterDesc<'a>
impl<'a> !Sync for TrainingParameterDesc<'a>
impl<'a> !UnwindSafe for TrainingParameterDesc<'a>
impl<'a> Forget for TrainingParameterDesc<'a>
impl<'a> Freeze for TrainingParameterDesc<'a>where
*const u8 is !null: Freeze,
PhantomData<u8>: Freeze,
*const dyn Fn() -> TrainingValue + 'a is !null: Freeze,
PhantomData<dyn Fn() -> TrainingValue + 'a>: Freeze,
*const dyn FnMut(&TrainingValue) -> Result<(), Error> + 'a is !null: Freeze,
PhantomData<dyn FnMut(&TrainingValue) -> Result<(), Error> + 'a>: Freeze,
impl<'a> Move for TrainingParameterDesc<'a>
impl<'a> Unpin for TrainingParameterDesc<'a>
impl<'a> UnsafeUnpin for TrainingParameterDesc<'a>where
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
*const dyn Fn() -> TrainingValue + 'a is !null: UnsafeUnpin,
PhantomData<dyn Fn() -> TrainingValue + 'a>: UnsafeUnpin,
*const dyn FnMut(&TrainingValue) -> Result<(), Error> + 'a is !null: UnsafeUnpin,
PhantomData<dyn FnMut(&TrainingValue) -> Result<(), Error> + 'a>: UnsafeUnpin,
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