pub struct Property { /* private fields */ }Expand description
Each ECHONET-Lite object has properties. Property represents an ECHONET-Lite property in an ECHONET-Lite object.
Implementations§
Source§impl Property
impl Property
pub fn new() -> Property
pub fn set_code(&mut self, code: u8) -> &mut Self
pub fn code(&self) -> u8
pub fn set_name(&mut self, name: String) -> &mut Self
pub fn name(&self) -> &String
pub fn set_data_type(&mut self, typ: String) -> &mut Self
pub fn data_type(&self) -> &String
pub fn set_capacity(&mut self, capacity: usize) -> &mut Self
pub fn capacity(&self) -> usize
pub fn set_read_attribute(&mut self, attr: PropertyRule) -> &mut Self
pub fn read_attribute(&self) -> PropertyRule
pub fn set_write_attribute(&mut self, attr: PropertyRule) -> &mut Self
pub fn write_attribute(&self) -> PropertyRule
pub fn set_anno_attribute(&mut self, attr: PropertyRule) -> &mut Self
pub fn anno_attribute(&self) -> PropertyRule
pub fn is_read_required(&self) -> bool
pub fn is_write_required(&self) -> bool
pub fn is_announce_required(&self) -> bool
pub fn is_readable(&self) -> bool
pub fn is_writable(&self) -> bool
pub fn is_announceable(&self) -> bool
pub fn is_readonly(&self) -> bool
pub fn is_writeonly(&self) -> bool
pub fn size(&self) -> usize
pub fn set_data(&mut self, data: &[u8]) -> &mut Self
pub fn set_byte_data(&mut self, v: u8) -> &mut Self
pub fn set_bytes_data(&mut self, data: &[u8]) -> &mut Self
pub fn set_int_data(&mut self, val: u32, byte_size: usize) -> &mut Self
pub fn add_data(&mut self, data: &[u8]) -> &mut Self
pub fn data(&self) -> &Vec<u8> ⓘ
pub fn data_as_bytes(&self) -> &[u8] ⓘ
pub fn data_as_byte(&self) -> u8
pub fn data_as_int(&self) -> u32
pub fn equals_data(&self, data: &[u8]) -> bool
pub fn add_enum(&mut self, e: PropertyEnum) -> bool
pub fn enums(&self) -> Values<'_, u32, PropertyEnum>
pub fn find_enum(&self, code: u32) -> Option<&PropertyEnum>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Property
impl RefUnwindSafe for Property
impl Send for Property
impl Sync for Property
impl Unpin for Property
impl UnwindSafe for Property
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