Struct redstone::protocol::data_package::DataPackage
pub struct DataPackage {
pub timestamp: u64,
pub signer_address: b256,
pub data_points: Vec<DataPoint>,
}Fields
timestamp: u64signer_address: b256data_points: VecTrait Implementations
impl Eq for DataPackage
impl Eq for DataPackage
fn eq(self, other: Self) -> bool
fn neq(self, other: Self) -> bool
fn neq(self, other: Self) -> bool
Evaluates if two values of the same type are not equal.
Additional Information
This function is inherited when eq() is implemented.
Arguments
other: [Self] - The value of the same type.
Returns
- [bool] -
trueif the two values are not equal, otherwisefalse.
Examples
struct MyStruct {
val: u64,
}
impl Eq for MyStruct {
fn eq(self, other: Self) -> bool {
self.val == other.val
}
}
fn foo() {
let struct1 = MyStruct { val: 10 };
let struct2 = MyStruct { val: 2 };
let result = struct1 != struct2;
assert(result);
}