pub struct EcucTextualParamValue(/* private fields */);
Expand description
The EcucTextualParamValue
holds a string value and can represent a enumeration,
string, multi-line string, function name or linker symbol parameter definition.
Implementations§
Source§impl EcucTextualParamValue
impl EcucTextualParamValue
Sourcepub fn set_definition<T: EcucParamDef>(
&self,
definition: &T,
) -> Result<(), AutosarAbstractionError>
pub fn set_definition<T: EcucParamDef>( &self, definition: &T, ) -> Result<(), AutosarAbstractionError>
set the parameter definition reference
Sourcepub fn definition(&self) -> Option<EcucParameterDef>
pub fn definition(&self) -> Option<EcucParameterDef>
get the parameter definition
This function returns the definition as an EcucParameterDef
enum, which
could contain either an EcucStringParamDef
, EcucMultiStringParamDef
,
EcucFunctionNameDef
or EcucLinkerSymbolDef
.
If the definition is not loaded, use definition_ref()
instead.
Sourcepub fn definition_ref(&self) -> Option<String>
pub fn definition_ref(&self) -> Option<String>
get the parameter definition reference as a string
This function is an alternative to definition()
; it is useful when the
referenced definition is not loaded and can’t be resolved.
Sourcepub fn set_value(&self, value: &str) -> Result<(), AutosarAbstractionError>
pub fn set_value(&self, value: &str) -> Result<(), AutosarAbstractionError>
set the textual value
Sourcepub fn set_index(
&self,
index: Option<u64>,
) -> Result<(), AutosarAbstractionError>
pub fn set_index( &self, index: Option<u64>, ) -> Result<(), AutosarAbstractionError>
set the index of the parameter
If the parameter definition has requiresIndex
set to true
, then the parameter
must have an index. Otherwise the index is meaningless.
Sourcepub fn index(&self) -> Option<u64>
pub fn index(&self) -> Option<u64>
get the index of the parameter
If the parameter definition has requiresIndex
set to true
, then the parameter
must have an index. Otherwise the index is meaningless.
Sourcepub fn set_is_auto_value(
&self,
is_auto_value: Option<bool>,
) -> Result<(), AutosarAbstractionError>
pub fn set_is_auto_value( &self, is_auto_value: Option<bool>, ) -> Result<(), AutosarAbstractionError>
set the isAutoValue flag
If the parameter definition has withAuto
set to true
, then the parameter is allowed to have an auto value.
Sourcepub fn is_auto_value(&self) -> Option<bool>
pub fn is_auto_value(&self) -> Option<bool>
get the isAutoValue flag
If the parameter definition has withAuto
set to true
, then the parameter is allowed to have an auto value.
Trait Implementations§
Source§impl Clone for EcucTextualParamValue
impl Clone for EcucTextualParamValue
Source§fn clone(&self) -> EcucTextualParamValue
fn clone(&self) -> EcucTextualParamValue
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for EcucTextualParamValue
impl Debug for EcucTextualParamValue
Source§impl From<EcucTextualParamValue> for Element
impl From<EcucTextualParamValue> for Element
Source§fn from(val: EcucTextualParamValue) -> Self
fn from(val: EcucTextualParamValue) -> Self
Source§impl Hash for EcucTextualParamValue
impl Hash for EcucTextualParamValue
Source§impl PartialEq for EcucTextualParamValue
impl PartialEq for EcucTextualParamValue
Source§impl TryFrom<Element> for EcucTextualParamValue
impl TryFrom<Element> for EcucTextualParamValue
impl Eq for EcucTextualParamValue
impl StructuralPartialEq for EcucTextualParamValue
Auto Trait Implementations§
impl Freeze for EcucTextualParamValue
impl !RefUnwindSafe for EcucTextualParamValue
impl Send for EcucTextualParamValue
impl Sync for EcucTextualParamValue
impl Unpin for EcucTextualParamValue
impl !UnwindSafe for EcucTextualParamValue
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.