pub struct SetVariableResult {
pub attribute_status: SetVariableStatus,
pub component: Component,
pub variable: Variable,
pub attribute_type: Option<Attribute>,
pub attribute_status_info: Option<StatusInfo>,
pub custom_data: Option<CustomData>,
}Expand description
The OCPP 2.1 SetVariableResult data type.
Fields§
§attribute_status: SetVariableStatusThe attributeStatus member.
component: ComponentThe component member.
variable: VariableThe variable member.
attribute_type: Option<Attribute>The attributeType member.
attribute_status_info: Option<StatusInfo>The attributeStatusInfo member.
custom_data: Option<CustomData>The customData member.
Implementations§
Source§impl SetVariableResult
impl SetVariableResult
Sourcepub fn new(
attribute_status: SetVariableStatus,
component: Component,
variable: Variable,
) -> Self
pub fn new( attribute_status: SetVariableStatus, component: Component, variable: Variable, ) -> Self
Creates a SetVariableResult from its required fields.
Sourcepub fn with_attribute_type(self, value: Attribute) -> Self
pub fn with_attribute_type(self, value: Attribute) -> Self
Sets the optional attributeType field.
Sourcepub fn with_attribute_status_info(self, value: StatusInfo) -> Self
pub fn with_attribute_status_info(self, value: StatusInfo) -> Self
Sets the optional attributeStatusInfo field.
Sourcepub fn with_custom_data(self, value: CustomData) -> Self
pub fn with_custom_data(self, value: CustomData) -> Self
Sets the optional customData field.
Trait Implementations§
Source§impl Clone for SetVariableResult
impl Clone for SetVariableResult
Source§fn clone(&self) -> SetVariableResult
fn clone(&self) -> SetVariableResult
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 SetVariableResult
impl Debug for SetVariableResult
Source§impl<'de> Deserialize<'de> for SetVariableResult
impl<'de> Deserialize<'de> for SetVariableResult
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for SetVariableResult
impl PartialEq for SetVariableResult
Source§impl Serialize for SetVariableResult
impl Serialize for SetVariableResult
impl StructuralPartialEq for SetVariableResult
Source§impl Validate for SetVariableResult
impl Validate for SetVariableResult
Source§fn validate_at(&self, path: &mut ValidationPath, out: &mut Violations)
fn validate_at(&self, path: &mut ValidationPath, out: &mut Violations)
Appends this value’s violations to
out, relative to path.Auto Trait Implementations§
impl Freeze for SetVariableResult
impl RefUnwindSafe for SetVariableResult
impl Send for SetVariableResult
impl Sync for SetVariableResult
impl Unpin for SetVariableResult
impl UnsafeUnpin for SetVariableResult
impl UnwindSafe for SetVariableResult
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