1 #![allow(unused_variables, non_upper_case_globals, non_snake_case, unused_unsafe, non_camel_case_types, dead_code, clippy::all)] 2 #[repr(transparent)] 3 #[derive(:: std :: cmp :: PartialEq, :: std :: cmp :: Eq, :: std :: clone :: Clone, :: std :: fmt :: Debug)] 4 pub struct DateTimeFormatter(::windows::runtime::IInspectable); 5 impl DateTimeFormatter { 6 #[cfg(feature = "Foundation_Collections")] Languages(&self) -> ::windows::runtime::Result<super::super::Foundation::Collections::IVectorView<::windows::runtime::HSTRING>>7 pub fn Languages(&self) -> ::windows::runtime::Result<super::super::Foundation::Collections::IVectorView<::windows::runtime::HSTRING>> { 8 let this = self; 9 unsafe { 10 let mut result__: ::windows::runtime::RawPtr = ::std::mem::zeroed(); 11 (::windows::runtime::Interface::vtable(this).6)(::std::mem::transmute_copy(this), &mut result__).from_abi::<super::super::Foundation::Collections::IVectorView<::windows::runtime::HSTRING>>(result__) 12 } 13 } GeographicRegion(&self) -> ::windows::runtime::Result<::windows::runtime::HSTRING>14 pub fn GeographicRegion(&self) -> ::windows::runtime::Result<::windows::runtime::HSTRING> { 15 let this = self; 16 unsafe { 17 let mut result__: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING> = ::std::mem::zeroed(); 18 (::windows::runtime::Interface::vtable(this).7)(::std::mem::transmute_copy(this), &mut result__).from_abi::<::windows::runtime::HSTRING>(result__) 19 } 20 } Calendar(&self) -> ::windows::runtime::Result<::windows::runtime::HSTRING>21 pub fn Calendar(&self) -> ::windows::runtime::Result<::windows::runtime::HSTRING> { 22 let this = self; 23 unsafe { 24 let mut result__: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING> = ::std::mem::zeroed(); 25 (::windows::runtime::Interface::vtable(this).8)(::std::mem::transmute_copy(this), &mut result__).from_abi::<::windows::runtime::HSTRING>(result__) 26 } 27 } Clock(&self) -> ::windows::runtime::Result<::windows::runtime::HSTRING>28 pub fn Clock(&self) -> ::windows::runtime::Result<::windows::runtime::HSTRING> { 29 let this = self; 30 unsafe { 31 let mut result__: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING> = ::std::mem::zeroed(); 32 (::windows::runtime::Interface::vtable(this).9)(::std::mem::transmute_copy(this), &mut result__).from_abi::<::windows::runtime::HSTRING>(result__) 33 } 34 } NumeralSystem(&self) -> ::windows::runtime::Result<::windows::runtime::HSTRING>35 pub fn NumeralSystem(&self) -> ::windows::runtime::Result<::windows::runtime::HSTRING> { 36 let this = self; 37 unsafe { 38 let mut result__: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING> = ::std::mem::zeroed(); 39 (::windows::runtime::Interface::vtable(this).10)(::std::mem::transmute_copy(this), &mut result__).from_abi::<::windows::runtime::HSTRING>(result__) 40 } 41 } SetNumeralSystem<'a, Param0: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>>(&self, value: Param0) -> ::windows::runtime::Result<()>42 pub fn SetNumeralSystem<'a, Param0: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>>(&self, value: Param0) -> ::windows::runtime::Result<()> { 43 let this = self; 44 unsafe { (::windows::runtime::Interface::vtable(this).11)(::std::mem::transmute_copy(this), value.into_param().abi()).ok() } 45 } 46 #[cfg(feature = "Foundation_Collections")] Patterns(&self) -> ::windows::runtime::Result<super::super::Foundation::Collections::IVectorView<::windows::runtime::HSTRING>>47 pub fn Patterns(&self) -> ::windows::runtime::Result<super::super::Foundation::Collections::IVectorView<::windows::runtime::HSTRING>> { 48 let this = self; 49 unsafe { 50 let mut result__: ::windows::runtime::RawPtr = ::std::mem::zeroed(); 51 (::windows::runtime::Interface::vtable(this).12)(::std::mem::transmute_copy(this), &mut result__).from_abi::<super::super::Foundation::Collections::IVectorView<::windows::runtime::HSTRING>>(result__) 52 } 53 } Template(&self) -> ::windows::runtime::Result<::windows::runtime::HSTRING>54 pub fn Template(&self) -> ::windows::runtime::Result<::windows::runtime::HSTRING> { 55 let this = self; 56 unsafe { 57 let mut result__: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING> = ::std::mem::zeroed(); 58 (::windows::runtime::Interface::vtable(this).13)(::std::mem::transmute_copy(this), &mut result__).from_abi::<::windows::runtime::HSTRING>(result__) 59 } 60 } 61 #[cfg(feature = "Foundation")] Format<'a, Param0: ::windows::runtime::IntoParam<'a, super::super::Foundation::DateTime>>(&self, value: Param0) -> ::windows::runtime::Result<::windows::runtime::HSTRING>62 pub fn Format<'a, Param0: ::windows::runtime::IntoParam<'a, super::super::Foundation::DateTime>>(&self, value: Param0) -> ::windows::runtime::Result<::windows::runtime::HSTRING> { 63 let this = self; 64 unsafe { 65 let mut result__: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING> = ::std::mem::zeroed(); 66 (::windows::runtime::Interface::vtable(this).14)(::std::mem::transmute_copy(this), value.into_param().abi(), &mut result__).from_abi::<::windows::runtime::HSTRING>(result__) 67 } 68 } IncludeYear(&self) -> ::windows::runtime::Result<YearFormat>69 pub fn IncludeYear(&self) -> ::windows::runtime::Result<YearFormat> { 70 let this = self; 71 unsafe { 72 let mut result__: YearFormat = ::std::mem::zeroed(); 73 (::windows::runtime::Interface::vtable(this).15)(::std::mem::transmute_copy(this), &mut result__).from_abi::<YearFormat>(result__) 74 } 75 } IncludeMonth(&self) -> ::windows::runtime::Result<MonthFormat>76 pub fn IncludeMonth(&self) -> ::windows::runtime::Result<MonthFormat> { 77 let this = self; 78 unsafe { 79 let mut result__: MonthFormat = ::std::mem::zeroed(); 80 (::windows::runtime::Interface::vtable(this).16)(::std::mem::transmute_copy(this), &mut result__).from_abi::<MonthFormat>(result__) 81 } 82 } IncludeDayOfWeek(&self) -> ::windows::runtime::Result<DayOfWeekFormat>83 pub fn IncludeDayOfWeek(&self) -> ::windows::runtime::Result<DayOfWeekFormat> { 84 let this = self; 85 unsafe { 86 let mut result__: DayOfWeekFormat = ::std::mem::zeroed(); 87 (::windows::runtime::Interface::vtable(this).17)(::std::mem::transmute_copy(this), &mut result__).from_abi::<DayOfWeekFormat>(result__) 88 } 89 } IncludeDay(&self) -> ::windows::runtime::Result<DayFormat>90 pub fn IncludeDay(&self) -> ::windows::runtime::Result<DayFormat> { 91 let this = self; 92 unsafe { 93 let mut result__: DayFormat = ::std::mem::zeroed(); 94 (::windows::runtime::Interface::vtable(this).18)(::std::mem::transmute_copy(this), &mut result__).from_abi::<DayFormat>(result__) 95 } 96 } IncludeHour(&self) -> ::windows::runtime::Result<HourFormat>97 pub fn IncludeHour(&self) -> ::windows::runtime::Result<HourFormat> { 98 let this = self; 99 unsafe { 100 let mut result__: HourFormat = ::std::mem::zeroed(); 101 (::windows::runtime::Interface::vtable(this).19)(::std::mem::transmute_copy(this), &mut result__).from_abi::<HourFormat>(result__) 102 } 103 } IncludeMinute(&self) -> ::windows::runtime::Result<MinuteFormat>104 pub fn IncludeMinute(&self) -> ::windows::runtime::Result<MinuteFormat> { 105 let this = self; 106 unsafe { 107 let mut result__: MinuteFormat = ::std::mem::zeroed(); 108 (::windows::runtime::Interface::vtable(this).20)(::std::mem::transmute_copy(this), &mut result__).from_abi::<MinuteFormat>(result__) 109 } 110 } IncludeSecond(&self) -> ::windows::runtime::Result<SecondFormat>111 pub fn IncludeSecond(&self) -> ::windows::runtime::Result<SecondFormat> { 112 let this = self; 113 unsafe { 114 let mut result__: SecondFormat = ::std::mem::zeroed(); 115 (::windows::runtime::Interface::vtable(this).21)(::std::mem::transmute_copy(this), &mut result__).from_abi::<SecondFormat>(result__) 116 } 117 } ResolvedLanguage(&self) -> ::windows::runtime::Result<::windows::runtime::HSTRING>118 pub fn ResolvedLanguage(&self) -> ::windows::runtime::Result<::windows::runtime::HSTRING> { 119 let this = self; 120 unsafe { 121 let mut result__: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING> = ::std::mem::zeroed(); 122 (::windows::runtime::Interface::vtable(this).22)(::std::mem::transmute_copy(this), &mut result__).from_abi::<::windows::runtime::HSTRING>(result__) 123 } 124 } ResolvedGeographicRegion(&self) -> ::windows::runtime::Result<::windows::runtime::HSTRING>125 pub fn ResolvedGeographicRegion(&self) -> ::windows::runtime::Result<::windows::runtime::HSTRING> { 126 let this = self; 127 unsafe { 128 let mut result__: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING> = ::std::mem::zeroed(); 129 (::windows::runtime::Interface::vtable(this).23)(::std::mem::transmute_copy(this), &mut result__).from_abi::<::windows::runtime::HSTRING>(result__) 130 } 131 } 132 #[cfg(feature = "Foundation")] FormatUsingTimeZone<'a, Param0: ::windows::runtime::IntoParam<'a, super::super::Foundation::DateTime>, Param1: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>>(&self, datetime: Param0, timezoneid: Param1) -> ::windows::runtime::Result<::windows::runtime::HSTRING>133 pub fn FormatUsingTimeZone<'a, Param0: ::windows::runtime::IntoParam<'a, super::super::Foundation::DateTime>, Param1: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>>(&self, datetime: Param0, timezoneid: Param1) -> ::windows::runtime::Result<::windows::runtime::HSTRING> { 134 let this = &::windows::runtime::Interface::cast::<IDateTimeFormatter2>(self)?; 135 unsafe { 136 let mut result__: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING> = ::std::mem::zeroed(); 137 (::windows::runtime::Interface::vtable(this).6)(::std::mem::transmute_copy(this), datetime.into_param().abi(), timezoneid.into_param().abi(), &mut result__).from_abi::<::windows::runtime::HSTRING>(result__) 138 } 139 } CreateDateTimeFormatter<'a, Param0: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>>(formattemplate: Param0) -> ::windows::runtime::Result<DateTimeFormatter>140 pub fn CreateDateTimeFormatter<'a, Param0: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>>(formattemplate: Param0) -> ::windows::runtime::Result<DateTimeFormatter> { 141 Self::IDateTimeFormatterFactory(|this| unsafe { 142 let mut result__: ::windows::runtime::RawPtr = ::std::mem::zeroed(); 143 (::windows::runtime::Interface::vtable(this).6)(::std::mem::transmute_copy(this), formattemplate.into_param().abi(), &mut result__).from_abi::<DateTimeFormatter>(result__) 144 }) 145 } 146 #[cfg(feature = "Foundation_Collections")] CreateDateTimeFormatterLanguages<'a, Param0: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>, Param1: ::windows::runtime::IntoParam<'a, super::super::Foundation::Collections::IIterable<::windows::runtime::HSTRING>>>(formattemplate: Param0, languages: Param1) -> ::windows::runtime::Result<DateTimeFormatter>147 pub fn CreateDateTimeFormatterLanguages<'a, Param0: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>, Param1: ::windows::runtime::IntoParam<'a, super::super::Foundation::Collections::IIterable<::windows::runtime::HSTRING>>>(formattemplate: Param0, languages: Param1) -> ::windows::runtime::Result<DateTimeFormatter> { 148 Self::IDateTimeFormatterFactory(|this| unsafe { 149 let mut result__: ::windows::runtime::RawPtr = ::std::mem::zeroed(); 150 (::windows::runtime::Interface::vtable(this).7)(::std::mem::transmute_copy(this), formattemplate.into_param().abi(), languages.into_param().abi(), &mut result__).from_abi::<DateTimeFormatter>(result__) 151 }) 152 } 153 #[cfg(feature = "Foundation_Collections")] CreateDateTimeFormatterContext<'a, Param0: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>, Param1: ::windows::runtime::IntoParam<'a, super::super::Foundation::Collections::IIterable<::windows::runtime::HSTRING>>, Param2: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>, Param3: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>, Param4: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>>( formattemplate: Param0, languages: Param1, geographicregion: Param2, calendar: Param3, clock: Param4, ) -> ::windows::runtime::Result<DateTimeFormatter>154 pub fn CreateDateTimeFormatterContext<'a, Param0: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>, Param1: ::windows::runtime::IntoParam<'a, super::super::Foundation::Collections::IIterable<::windows::runtime::HSTRING>>, Param2: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>, Param3: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>, Param4: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>>( 155 formattemplate: Param0, 156 languages: Param1, 157 geographicregion: Param2, 158 calendar: Param3, 159 clock: Param4, 160 ) -> ::windows::runtime::Result<DateTimeFormatter> { 161 Self::IDateTimeFormatterFactory(|this| unsafe { 162 let mut result__: ::windows::runtime::RawPtr = ::std::mem::zeroed(); 163 (::windows::runtime::Interface::vtable(this).8)(::std::mem::transmute_copy(this), formattemplate.into_param().abi(), languages.into_param().abi(), geographicregion.into_param().abi(), calendar.into_param().abi(), clock.into_param().abi(), &mut result__).from_abi::<DateTimeFormatter>(result__) 164 }) 165 } CreateDateTimeFormatterDate(yearformat: YearFormat, monthformat: MonthFormat, dayformat: DayFormat, dayofweekformat: DayOfWeekFormat) -> ::windows::runtime::Result<DateTimeFormatter>166 pub fn CreateDateTimeFormatterDate(yearformat: YearFormat, monthformat: MonthFormat, dayformat: DayFormat, dayofweekformat: DayOfWeekFormat) -> ::windows::runtime::Result<DateTimeFormatter> { 167 Self::IDateTimeFormatterFactory(|this| unsafe { 168 let mut result__: ::windows::runtime::RawPtr = ::std::mem::zeroed(); 169 (::windows::runtime::Interface::vtable(this).9)(::std::mem::transmute_copy(this), yearformat, monthformat, dayformat, dayofweekformat, &mut result__).from_abi::<DateTimeFormatter>(result__) 170 }) 171 } CreateDateTimeFormatterTime(hourformat: HourFormat, minuteformat: MinuteFormat, secondformat: SecondFormat) -> ::windows::runtime::Result<DateTimeFormatter>172 pub fn CreateDateTimeFormatterTime(hourformat: HourFormat, minuteformat: MinuteFormat, secondformat: SecondFormat) -> ::windows::runtime::Result<DateTimeFormatter> { 173 Self::IDateTimeFormatterFactory(|this| unsafe { 174 let mut result__: ::windows::runtime::RawPtr = ::std::mem::zeroed(); 175 (::windows::runtime::Interface::vtable(this).10)(::std::mem::transmute_copy(this), hourformat, minuteformat, secondformat, &mut result__).from_abi::<DateTimeFormatter>(result__) 176 }) 177 } 178 #[cfg(feature = "Foundation_Collections")] CreateDateTimeFormatterDateTimeLanguages<'a, Param7: ::windows::runtime::IntoParam<'a, super::super::Foundation::Collections::IIterable<::windows::runtime::HSTRING>>>(yearformat: YearFormat, monthformat: MonthFormat, dayformat: DayFormat, dayofweekformat: DayOfWeekFormat, hourformat: HourFormat, minuteformat: MinuteFormat, secondformat: SecondFormat, languages: Param7) -> ::windows::runtime::Result<DateTimeFormatter>179 pub fn CreateDateTimeFormatterDateTimeLanguages<'a, Param7: ::windows::runtime::IntoParam<'a, super::super::Foundation::Collections::IIterable<::windows::runtime::HSTRING>>>(yearformat: YearFormat, monthformat: MonthFormat, dayformat: DayFormat, dayofweekformat: DayOfWeekFormat, hourformat: HourFormat, minuteformat: MinuteFormat, secondformat: SecondFormat, languages: Param7) -> ::windows::runtime::Result<DateTimeFormatter> { 180 Self::IDateTimeFormatterFactory(|this| unsafe { 181 let mut result__: ::windows::runtime::RawPtr = ::std::mem::zeroed(); 182 (::windows::runtime::Interface::vtable(this).11)(::std::mem::transmute_copy(this), yearformat, monthformat, dayformat, dayofweekformat, hourformat, minuteformat, secondformat, languages.into_param().abi(), &mut result__).from_abi::<DateTimeFormatter>(result__) 183 }) 184 } 185 #[cfg(feature = "Foundation_Collections")] CreateDateTimeFormatterDateTimeContext<'a, Param7: ::windows::runtime::IntoParam<'a, super::super::Foundation::Collections::IIterable<::windows::runtime::HSTRING>>, Param8: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>, Param9: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>, Param10: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>>( yearformat: YearFormat, monthformat: MonthFormat, dayformat: DayFormat, dayofweekformat: DayOfWeekFormat, hourformat: HourFormat, minuteformat: MinuteFormat, secondformat: SecondFormat, languages: Param7, geographicregion: Param8, calendar: Param9, clock: Param10, ) -> ::windows::runtime::Result<DateTimeFormatter>186 pub fn CreateDateTimeFormatterDateTimeContext<'a, Param7: ::windows::runtime::IntoParam<'a, super::super::Foundation::Collections::IIterable<::windows::runtime::HSTRING>>, Param8: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>, Param9: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>, Param10: ::windows::runtime::IntoParam<'a, ::windows::runtime::HSTRING>>( 187 yearformat: YearFormat, 188 monthformat: MonthFormat, 189 dayformat: DayFormat, 190 dayofweekformat: DayOfWeekFormat, 191 hourformat: HourFormat, 192 minuteformat: MinuteFormat, 193 secondformat: SecondFormat, 194 languages: Param7, 195 geographicregion: Param8, 196 calendar: Param9, 197 clock: Param10, 198 ) -> ::windows::runtime::Result<DateTimeFormatter> { 199 Self::IDateTimeFormatterFactory(|this| unsafe { 200 let mut result__: ::windows::runtime::RawPtr = ::std::mem::zeroed(); 201 (::windows::runtime::Interface::vtable(this).12)(::std::mem::transmute_copy(this), yearformat, monthformat, dayformat, dayofweekformat, hourformat, minuteformat, secondformat, languages.into_param().abi(), geographicregion.into_param().abi(), calendar.into_param().abi(), clock.into_param().abi(), &mut result__).from_abi::<DateTimeFormatter>(result__) 202 }) 203 } LongDate() -> ::windows::runtime::Result<DateTimeFormatter>204 pub fn LongDate() -> ::windows::runtime::Result<DateTimeFormatter> { 205 Self::IDateTimeFormatterStatics(|this| unsafe { 206 let mut result__: ::windows::runtime::RawPtr = ::std::mem::zeroed(); 207 (::windows::runtime::Interface::vtable(this).6)(::std::mem::transmute_copy(this), &mut result__).from_abi::<DateTimeFormatter>(result__) 208 }) 209 } LongTime() -> ::windows::runtime::Result<DateTimeFormatter>210 pub fn LongTime() -> ::windows::runtime::Result<DateTimeFormatter> { 211 Self::IDateTimeFormatterStatics(|this| unsafe { 212 let mut result__: ::windows::runtime::RawPtr = ::std::mem::zeroed(); 213 (::windows::runtime::Interface::vtable(this).7)(::std::mem::transmute_copy(this), &mut result__).from_abi::<DateTimeFormatter>(result__) 214 }) 215 } ShortDate() -> ::windows::runtime::Result<DateTimeFormatter>216 pub fn ShortDate() -> ::windows::runtime::Result<DateTimeFormatter> { 217 Self::IDateTimeFormatterStatics(|this| unsafe { 218 let mut result__: ::windows::runtime::RawPtr = ::std::mem::zeroed(); 219 (::windows::runtime::Interface::vtable(this).8)(::std::mem::transmute_copy(this), &mut result__).from_abi::<DateTimeFormatter>(result__) 220 }) 221 } ShortTime() -> ::windows::runtime::Result<DateTimeFormatter>222 pub fn ShortTime() -> ::windows::runtime::Result<DateTimeFormatter> { 223 Self::IDateTimeFormatterStatics(|this| unsafe { 224 let mut result__: ::windows::runtime::RawPtr = ::std::mem::zeroed(); 225 (::windows::runtime::Interface::vtable(this).9)(::std::mem::transmute_copy(this), &mut result__).from_abi::<DateTimeFormatter>(result__) 226 }) 227 } IDateTimeFormatterFactory<R, F: FnOnce(&IDateTimeFormatterFactory) -> ::windows::runtime::Result<R>>(callback: F) -> ::windows::runtime::Result<R>228 pub fn IDateTimeFormatterFactory<R, F: FnOnce(&IDateTimeFormatterFactory) -> ::windows::runtime::Result<R>>(callback: F) -> ::windows::runtime::Result<R> { 229 static mut SHARED: ::windows::runtime::FactoryCache<DateTimeFormatter, IDateTimeFormatterFactory> = ::windows::runtime::FactoryCache::new(); 230 unsafe { SHARED.call(callback) } 231 } IDateTimeFormatterStatics<R, F: FnOnce(&IDateTimeFormatterStatics) -> ::windows::runtime::Result<R>>(callback: F) -> ::windows::runtime::Result<R>232 pub fn IDateTimeFormatterStatics<R, F: FnOnce(&IDateTimeFormatterStatics) -> ::windows::runtime::Result<R>>(callback: F) -> ::windows::runtime::Result<R> { 233 static mut SHARED: ::windows::runtime::FactoryCache<DateTimeFormatter, IDateTimeFormatterStatics> = ::windows::runtime::FactoryCache::new(); 234 unsafe { SHARED.call(callback) } 235 } 236 } 237 unsafe impl ::windows::runtime::RuntimeType for DateTimeFormatter { 238 const SIGNATURE: ::windows::runtime::ConstBuffer = ::windows::runtime::ConstBuffer::from_slice(b"rc(Windows.Globalization.DateTimeFormatting.DateTimeFormatter;{95eeca10-73e0-4e4b-a183-3d6ad0ba35ec})"); 239 } 240 unsafe impl ::windows::runtime::Interface for DateTimeFormatter { 241 type Vtable = IDateTimeFormatter_abi; 242 const IID: ::windows::runtime::GUID = ::windows::runtime::GUID::from_values(2515454480, 29664, 20043, [161, 131, 61, 106, 208, 186, 53, 236]); 243 } 244 impl ::windows::runtime::RuntimeName for DateTimeFormatter { 245 const NAME: &'static str = "Windows.Globalization.DateTimeFormatting.DateTimeFormatter"; 246 } 247 impl ::std::convert::From<DateTimeFormatter> for ::windows::runtime::IUnknown { from(value: DateTimeFormatter) -> Self248 fn from(value: DateTimeFormatter) -> Self { 249 unsafe { ::std::mem::transmute(value) } 250 } 251 } 252 impl ::std::convert::From<&DateTimeFormatter> for ::windows::runtime::IUnknown { from(value: &DateTimeFormatter) -> Self253 fn from(value: &DateTimeFormatter) -> Self { 254 ::std::convert::From::from(::std::clone::Clone::clone(value)) 255 } 256 } 257 impl<'a> ::windows::runtime::IntoParam<'a, ::windows::runtime::IUnknown> for DateTimeFormatter { into_param(self) -> ::windows::runtime::Param<'a, ::windows::runtime::IUnknown>258 fn into_param(self) -> ::windows::runtime::Param<'a, ::windows::runtime::IUnknown> { 259 ::windows::runtime::Param::Owned(::std::convert::Into::<::windows::runtime::IUnknown>::into(self)) 260 } 261 } 262 impl<'a> ::windows::runtime::IntoParam<'a, ::windows::runtime::IUnknown> for &DateTimeFormatter { into_param(self) -> ::windows::runtime::Param<'a, ::windows::runtime::IUnknown>263 fn into_param(self) -> ::windows::runtime::Param<'a, ::windows::runtime::IUnknown> { 264 ::windows::runtime::Param::Owned(::std::convert::Into::<::windows::runtime::IUnknown>::into(::std::clone::Clone::clone(self))) 265 } 266 } 267 impl ::std::convert::From<DateTimeFormatter> for ::windows::runtime::IInspectable { from(value: DateTimeFormatter) -> Self268 fn from(value: DateTimeFormatter) -> Self { 269 value.0 270 } 271 } 272 impl ::std::convert::From<&DateTimeFormatter> for ::windows::runtime::IInspectable { from(value: &DateTimeFormatter) -> Self273 fn from(value: &DateTimeFormatter) -> Self { 274 value.0.clone() 275 } 276 } 277 impl<'a> ::windows::runtime::IntoParam<'a, ::windows::runtime::IInspectable> for DateTimeFormatter { into_param(self) -> ::windows::runtime::Param<'a, ::windows::runtime::IInspectable>278 fn into_param(self) -> ::windows::runtime::Param<'a, ::windows::runtime::IInspectable> { 279 ::windows::runtime::Param::Owned(self.0) 280 } 281 } 282 impl<'a> ::windows::runtime::IntoParam<'a, ::windows::runtime::IInspectable> for &'a DateTimeFormatter { into_param(self) -> ::windows::runtime::Param<'a, ::windows::runtime::IInspectable>283 fn into_param(self) -> ::windows::runtime::Param<'a, ::windows::runtime::IInspectable> { 284 ::windows::runtime::Param::Borrowed(&self.0) 285 } 286 } 287 unsafe impl ::std::marker::Send for DateTimeFormatter {} 288 unsafe impl ::std::marker::Sync for DateTimeFormatter {} 289 #[derive(:: std :: cmp :: PartialEq, :: std :: cmp :: Eq, :: std :: marker :: Copy, :: std :: clone :: Clone, :: std :: default :: Default, :: std :: fmt :: Debug)] 290 #[repr(transparent)] 291 pub struct DayFormat(pub i32); 292 impl DayFormat { 293 pub const None: DayFormat = DayFormat(0i32); 294 pub const Default: DayFormat = DayFormat(1i32); 295 } 296 impl ::std::convert::From<i32> for DayFormat { from(value: i32) -> Self297 fn from(value: i32) -> Self { 298 Self(value) 299 } 300 } 301 unsafe impl ::windows::runtime::Abi for DayFormat { 302 type Abi = Self; 303 type DefaultType = Self; 304 } 305 unsafe impl ::windows::runtime::RuntimeType for DayFormat { 306 const SIGNATURE: ::windows::runtime::ConstBuffer = ::windows::runtime::ConstBuffer::from_slice(b"enum(Windows.Globalization.DateTimeFormatting.DayFormat;i4)"); 307 } 308 #[derive(:: std :: cmp :: PartialEq, :: std :: cmp :: Eq, :: std :: marker :: Copy, :: std :: clone :: Clone, :: std :: default :: Default, :: std :: fmt :: Debug)] 309 #[repr(transparent)] 310 pub struct DayOfWeekFormat(pub i32); 311 impl DayOfWeekFormat { 312 pub const None: DayOfWeekFormat = DayOfWeekFormat(0i32); 313 pub const Default: DayOfWeekFormat = DayOfWeekFormat(1i32); 314 pub const Abbreviated: DayOfWeekFormat = DayOfWeekFormat(2i32); 315 pub const Full: DayOfWeekFormat = DayOfWeekFormat(3i32); 316 } 317 impl ::std::convert::From<i32> for DayOfWeekFormat { from(value: i32) -> Self318 fn from(value: i32) -> Self { 319 Self(value) 320 } 321 } 322 unsafe impl ::windows::runtime::Abi for DayOfWeekFormat { 323 type Abi = Self; 324 type DefaultType = Self; 325 } 326 unsafe impl ::windows::runtime::RuntimeType for DayOfWeekFormat { 327 const SIGNATURE: ::windows::runtime::ConstBuffer = ::windows::runtime::ConstBuffer::from_slice(b"enum(Windows.Globalization.DateTimeFormatting.DayOfWeekFormat;i4)"); 328 } 329 #[derive(:: std :: cmp :: PartialEq, :: std :: cmp :: Eq, :: std :: marker :: Copy, :: std :: clone :: Clone, :: std :: default :: Default, :: std :: fmt :: Debug)] 330 #[repr(transparent)] 331 pub struct HourFormat(pub i32); 332 impl HourFormat { 333 pub const None: HourFormat = HourFormat(0i32); 334 pub const Default: HourFormat = HourFormat(1i32); 335 } 336 impl ::std::convert::From<i32> for HourFormat { from(value: i32) -> Self337 fn from(value: i32) -> Self { 338 Self(value) 339 } 340 } 341 unsafe impl ::windows::runtime::Abi for HourFormat { 342 type Abi = Self; 343 type DefaultType = Self; 344 } 345 unsafe impl ::windows::runtime::RuntimeType for HourFormat { 346 const SIGNATURE: ::windows::runtime::ConstBuffer = ::windows::runtime::ConstBuffer::from_slice(b"enum(Windows.Globalization.DateTimeFormatting.HourFormat;i4)"); 347 } 348 #[repr(transparent)] 349 #[derive(:: std :: cmp :: PartialEq, :: std :: cmp :: Eq, :: std :: clone :: Clone, :: std :: fmt :: Debug)] 350 #[doc(hidden)] 351 pub struct IDateTimeFormatter(::windows::runtime::IInspectable); 352 unsafe impl ::windows::runtime::Interface for IDateTimeFormatter { 353 type Vtable = IDateTimeFormatter_abi; 354 const IID: ::windows::runtime::GUID = ::windows::runtime::GUID::from_values(2515454480, 29664, 20043, [161, 131, 61, 106, 208, 186, 53, 236]); 355 } 356 #[repr(C)] 357 #[doc(hidden)] 358 pub struct IDateTimeFormatter_abi( 359 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, iid: &::windows::runtime::GUID, interface: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 360 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr) -> u32, 361 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr) -> u32, 362 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, count: *mut u32, values: *mut *mut ::windows::runtime::GUID) -> ::windows::runtime::HRESULT, 363 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, value: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 364 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, value: *mut i32) -> ::windows::runtime::HRESULT, 365 #[cfg(feature = "Foundation_Collections")] pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 366 #[cfg(not(feature = "Foundation_Collections"))] usize, 367 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>) -> ::windows::runtime::HRESULT, 368 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>) -> ::windows::runtime::HRESULT, 369 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>) -> ::windows::runtime::HRESULT, 370 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>) -> ::windows::runtime::HRESULT, 371 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, value: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>) -> ::windows::runtime::HRESULT, 372 #[cfg(feature = "Foundation_Collections")] pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 373 #[cfg(not(feature = "Foundation_Collections"))] usize, 374 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>) -> ::windows::runtime::HRESULT, 375 #[cfg(feature = "Foundation")] pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, value: super::super::Foundation::DateTime, result__: *mut ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>) -> ::windows::runtime::HRESULT, 376 #[cfg(not(feature = "Foundation"))] usize, 377 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut YearFormat) -> ::windows::runtime::HRESULT, 378 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut MonthFormat) -> ::windows::runtime::HRESULT, 379 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut DayOfWeekFormat) -> ::windows::runtime::HRESULT, 380 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut DayFormat) -> ::windows::runtime::HRESULT, 381 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut HourFormat) -> ::windows::runtime::HRESULT, 382 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut MinuteFormat) -> ::windows::runtime::HRESULT, 383 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut SecondFormat) -> ::windows::runtime::HRESULT, 384 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>) -> ::windows::runtime::HRESULT, 385 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>) -> ::windows::runtime::HRESULT, 386 ); 387 #[repr(transparent)] 388 #[derive(:: std :: cmp :: PartialEq, :: std :: cmp :: Eq, :: std :: clone :: Clone, :: std :: fmt :: Debug)] 389 #[doc(hidden)] 390 pub struct IDateTimeFormatter2(::windows::runtime::IInspectable); 391 unsafe impl ::windows::runtime::Interface for IDateTimeFormatter2 { 392 type Vtable = IDateTimeFormatter2_abi; 393 const IID: ::windows::runtime::GUID = ::windows::runtime::GUID::from_values(667490950, 48554, 20432, [158, 54, 103, 29, 90, 165, 238, 3]); 394 } 395 #[repr(C)] 396 #[doc(hidden)] 397 pub struct IDateTimeFormatter2_abi( 398 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, iid: &::windows::runtime::GUID, interface: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 399 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr) -> u32, 400 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr) -> u32, 401 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, count: *mut u32, values: *mut *mut ::windows::runtime::GUID) -> ::windows::runtime::HRESULT, 402 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, value: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 403 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, value: *mut i32) -> ::windows::runtime::HRESULT, 404 #[cfg(feature = "Foundation")] pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, datetime: super::super::Foundation::DateTime, timezoneid: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>, result__: *mut ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>) -> ::windows::runtime::HRESULT, 405 #[cfg(not(feature = "Foundation"))] usize, 406 ); 407 #[repr(transparent)] 408 #[derive(:: std :: cmp :: PartialEq, :: std :: cmp :: Eq, :: std :: clone :: Clone, :: std :: fmt :: Debug)] 409 #[doc(hidden)] 410 pub struct IDateTimeFormatterFactory(::windows::runtime::IInspectable); 411 unsafe impl ::windows::runtime::Interface for IDateTimeFormatterFactory { 412 type Vtable = IDateTimeFormatterFactory_abi; 413 const IID: ::windows::runtime::GUID = ::windows::runtime::GUID::from_values(3968698963, 6702, 16685, [136, 21, 59, 116, 95, 177, 162, 160]); 414 } 415 #[repr(C)] 416 #[doc(hidden)] 417 pub struct IDateTimeFormatterFactory_abi( 418 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, iid: &::windows::runtime::GUID, interface: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 419 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr) -> u32, 420 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr) -> u32, 421 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, count: *mut u32, values: *mut *mut ::windows::runtime::GUID) -> ::windows::runtime::HRESULT, 422 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, value: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 423 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, value: *mut i32) -> ::windows::runtime::HRESULT, 424 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, formattemplate: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>, result__: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 425 #[cfg(feature = "Foundation_Collections")] pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, formattemplate: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>, languages: ::windows::runtime::RawPtr, result__: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 426 #[cfg(not(feature = "Foundation_Collections"))] usize, 427 #[cfg(feature = "Foundation_Collections")] pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, formattemplate: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>, languages: ::windows::runtime::RawPtr, geographicregion: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>, calendar: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>, clock: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>, result__: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 428 #[cfg(not(feature = "Foundation_Collections"))] usize, 429 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, yearformat: YearFormat, monthformat: MonthFormat, dayformat: DayFormat, dayofweekformat: DayOfWeekFormat, result__: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 430 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, hourformat: HourFormat, minuteformat: MinuteFormat, secondformat: SecondFormat, result__: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 431 #[cfg(feature = "Foundation_Collections")] pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, yearformat: YearFormat, monthformat: MonthFormat, dayformat: DayFormat, dayofweekformat: DayOfWeekFormat, hourformat: HourFormat, minuteformat: MinuteFormat, secondformat: SecondFormat, languages: ::windows::runtime::RawPtr, result__: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 432 #[cfg(not(feature = "Foundation_Collections"))] usize, 433 #[cfg(feature = "Foundation_Collections")] 434 pub unsafe extern "system" fn( 435 this: ::windows::runtime::RawPtr, 436 yearformat: YearFormat, 437 monthformat: MonthFormat, 438 dayformat: DayFormat, 439 dayofweekformat: DayOfWeekFormat, 440 hourformat: HourFormat, 441 minuteformat: MinuteFormat, 442 secondformat: SecondFormat, 443 languages: ::windows::runtime::RawPtr, 444 geographicregion: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>, 445 calendar: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>, 446 clock: ::std::mem::ManuallyDrop<::windows::runtime::HSTRING>, 447 result__: *mut ::windows::runtime::RawPtr, 448 ) -> ::windows::runtime::HRESULT, 449 #[cfg(not(feature = "Foundation_Collections"))] usize, 450 ); 451 #[repr(transparent)] 452 #[derive(:: std :: cmp :: PartialEq, :: std :: cmp :: Eq, :: std :: clone :: Clone, :: std :: fmt :: Debug)] 453 #[doc(hidden)] 454 pub struct IDateTimeFormatterStatics(::windows::runtime::IInspectable); 455 unsafe impl ::windows::runtime::Interface for IDateTimeFormatterStatics { 456 type Vtable = IDateTimeFormatterStatics_abi; 457 const IID: ::windows::runtime::GUID = ::windows::runtime::GUID::from_values(3217942464, 57164, 18990, [144, 18, 244, 125, 175, 63, 18, 18]); 458 } 459 #[repr(C)] 460 #[doc(hidden)] 461 pub struct IDateTimeFormatterStatics_abi( 462 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, iid: &::windows::runtime::GUID, interface: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 463 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr) -> u32, 464 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr) -> u32, 465 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, count: *mut u32, values: *mut *mut ::windows::runtime::GUID) -> ::windows::runtime::HRESULT, 466 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, value: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 467 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, value: *mut i32) -> ::windows::runtime::HRESULT, 468 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 469 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 470 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 471 pub unsafe extern "system" fn(this: ::windows::runtime::RawPtr, result__: *mut ::windows::runtime::RawPtr) -> ::windows::runtime::HRESULT, 472 ); 473 #[derive(:: std :: cmp :: PartialEq, :: std :: cmp :: Eq, :: std :: marker :: Copy, :: std :: clone :: Clone, :: std :: default :: Default, :: std :: fmt :: Debug)] 474 #[repr(transparent)] 475 pub struct MinuteFormat(pub i32); 476 impl MinuteFormat { 477 pub const None: MinuteFormat = MinuteFormat(0i32); 478 pub const Default: MinuteFormat = MinuteFormat(1i32); 479 } 480 impl ::std::convert::From<i32> for MinuteFormat { from(value: i32) -> Self481 fn from(value: i32) -> Self { 482 Self(value) 483 } 484 } 485 unsafe impl ::windows::runtime::Abi for MinuteFormat { 486 type Abi = Self; 487 type DefaultType = Self; 488 } 489 unsafe impl ::windows::runtime::RuntimeType for MinuteFormat { 490 const SIGNATURE: ::windows::runtime::ConstBuffer = ::windows::runtime::ConstBuffer::from_slice(b"enum(Windows.Globalization.DateTimeFormatting.MinuteFormat;i4)"); 491 } 492 #[derive(:: std :: cmp :: PartialEq, :: std :: cmp :: Eq, :: std :: marker :: Copy, :: std :: clone :: Clone, :: std :: default :: Default, :: std :: fmt :: Debug)] 493 #[repr(transparent)] 494 pub struct MonthFormat(pub i32); 495 impl MonthFormat { 496 pub const None: MonthFormat = MonthFormat(0i32); 497 pub const Default: MonthFormat = MonthFormat(1i32); 498 pub const Abbreviated: MonthFormat = MonthFormat(2i32); 499 pub const Full: MonthFormat = MonthFormat(3i32); 500 pub const Numeric: MonthFormat = MonthFormat(4i32); 501 } 502 impl ::std::convert::From<i32> for MonthFormat { from(value: i32) -> Self503 fn from(value: i32) -> Self { 504 Self(value) 505 } 506 } 507 unsafe impl ::windows::runtime::Abi for MonthFormat { 508 type Abi = Self; 509 type DefaultType = Self; 510 } 511 unsafe impl ::windows::runtime::RuntimeType for MonthFormat { 512 const SIGNATURE: ::windows::runtime::ConstBuffer = ::windows::runtime::ConstBuffer::from_slice(b"enum(Windows.Globalization.DateTimeFormatting.MonthFormat;i4)"); 513 } 514 #[derive(:: std :: cmp :: PartialEq, :: std :: cmp :: Eq, :: std :: marker :: Copy, :: std :: clone :: Clone, :: std :: default :: Default, :: std :: fmt :: Debug)] 515 #[repr(transparent)] 516 pub struct SecondFormat(pub i32); 517 impl SecondFormat { 518 pub const None: SecondFormat = SecondFormat(0i32); 519 pub const Default: SecondFormat = SecondFormat(1i32); 520 } 521 impl ::std::convert::From<i32> for SecondFormat { from(value: i32) -> Self522 fn from(value: i32) -> Self { 523 Self(value) 524 } 525 } 526 unsafe impl ::windows::runtime::Abi for SecondFormat { 527 type Abi = Self; 528 type DefaultType = Self; 529 } 530 unsafe impl ::windows::runtime::RuntimeType for SecondFormat { 531 const SIGNATURE: ::windows::runtime::ConstBuffer = ::windows::runtime::ConstBuffer::from_slice(b"enum(Windows.Globalization.DateTimeFormatting.SecondFormat;i4)"); 532 } 533 #[derive(:: std :: cmp :: PartialEq, :: std :: cmp :: Eq, :: std :: marker :: Copy, :: std :: clone :: Clone, :: std :: default :: Default, :: std :: fmt :: Debug)] 534 #[repr(transparent)] 535 pub struct YearFormat(pub i32); 536 impl YearFormat { 537 pub const None: YearFormat = YearFormat(0i32); 538 pub const Default: YearFormat = YearFormat(1i32); 539 pub const Abbreviated: YearFormat = YearFormat(2i32); 540 pub const Full: YearFormat = YearFormat(3i32); 541 } 542 impl ::std::convert::From<i32> for YearFormat { from(value: i32) -> Self543 fn from(value: i32) -> Self { 544 Self(value) 545 } 546 } 547 unsafe impl ::windows::runtime::Abi for YearFormat { 548 type Abi = Self; 549 type DefaultType = Self; 550 } 551 unsafe impl ::windows::runtime::RuntimeType for YearFormat { 552 const SIGNATURE: ::windows::runtime::ConstBuffer = ::windows::runtime::ConstBuffer::from_slice(b"enum(Windows.Globalization.DateTimeFormatting.YearFormat;i4)"); 553 } 554