forked from proxmox-mirrors/proxmox
![]() When writing an #[api] function, one can now access default values by parameter name (see test_default_option in tests/options.rs): #[api(...)] pub fn func(value: Option<isize>) { println!( "value: {}", value.unwrap_or(api_get_default!("value")), ); } Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com> |
||
---|---|---|
.. | ||
api1.rs | ||
api2.rs | ||
ext-schema.rs | ||
int-limits.rs | ||
options.rs | ||
types.rs |