nominal_api/conjure/objects/storage/writer/api/
string_point.rs1#[derive(
2 Debug,
3 Clone,
4 conjure_object::serde::Serialize,
5 conjure_object::serde::Deserialize,
6 PartialEq,
7 Eq,
8 PartialOrd,
9 Ord,
10 Hash
11)]
12#[serde(crate = "conjure_object::serde")]
13#[conjure_object::private::staged_builder::staged_builder]
14#[builder(crate = conjure_object::private::staged_builder, update, inline)]
15pub struct StringPoint {
16 #[builder(
17 custom(type = super::super::super::super::api::Timestamp, convert = Box::new)
18 )]
19 #[serde(rename = "timestamp")]
20 timestamp: Box<super::super::super::super::api::Timestamp>,
21 #[builder(into)]
22 #[serde(rename = "value")]
23 value: String,
24}
25impl StringPoint {
26 #[inline]
28 pub fn new(
29 timestamp: super::super::super::super::api::Timestamp,
30 value: impl Into<String>,
31 ) -> Self {
32 Self::builder().timestamp(timestamp).value(value).build()
33 }
34 #[inline]
35 pub fn timestamp(&self) -> &super::super::super::super::api::Timestamp {
36 &*self.timestamp
37 }
38 #[inline]
39 pub fn value(&self) -> &str {
40 &*self.value
41 }
42}