| #[doc(hidden)] |
| #[repr(transparent)] |
| pub struct ICharacterGrouping(::windows::core::IUnknown); |
| unsafe impl ::windows::core::Interface for ICharacterGrouping { |
| type Vtable = ICharacterGrouping_Vtbl; |
| } |
| impl ::core::clone::Clone for ICharacterGrouping { |
| fn clone(&self) -> Self { |
| Self(self.0.clone()) |
| } |
| } |
| unsafe impl ::windows::core::ComInterface for ICharacterGrouping { |
| const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xfae761bb_805d_4bb0_95bb_c1f7c3e8eb8e); |
| } |
| #[repr(C)] |
| #[doc(hidden)] |
| pub struct ICharacterGrouping_Vtbl { |
| pub base__: ::windows::core::IInspectable_Vtbl, |
| pub First: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut ::std::mem::MaybeUninit<::windows::core::HSTRING>) -> ::windows::core::HRESULT, |
| pub Label: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut ::std::mem::MaybeUninit<::windows::core::HSTRING>) -> ::windows::core::HRESULT, |
| } |
| #[doc(hidden)] |
| #[repr(transparent)] |
| pub struct ICharacterGroupings(::windows::core::IUnknown); |
| unsafe impl ::windows::core::Interface for ICharacterGroupings { |
| type Vtable = ICharacterGroupings_Vtbl; |
| } |
| impl ::core::clone::Clone for ICharacterGroupings { |
| fn clone(&self) -> Self { |
| Self(self.0.clone()) |
| } |
| } |
| unsafe impl ::windows::core::ComInterface for ICharacterGroupings { |
| const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xb8d20a75_d4cf_4055_80e5_ce169c226496); |
| } |
| #[repr(C)] |
| #[doc(hidden)] |
| pub struct ICharacterGroupings_Vtbl { |
| pub base__: ::windows::core::IInspectable_Vtbl, |
| pub Lookup: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, text: ::std::mem::MaybeUninit<::windows::core::HSTRING>, result__: *mut ::std::mem::MaybeUninit<::windows::core::HSTRING>) -> ::windows::core::HRESULT, |
| } |
| #[doc(hidden)] |
| #[repr(transparent)] |
| pub struct ICharacterGroupingsFactory(::windows::core::IUnknown); |
| unsafe impl ::windows::core::Interface for ICharacterGroupingsFactory { |
| type Vtable = ICharacterGroupingsFactory_Vtbl; |
| } |
| impl ::core::clone::Clone for ICharacterGroupingsFactory { |
| fn clone(&self) -> Self { |
| Self(self.0.clone()) |
| } |
| } |
| unsafe impl ::windows::core::ComInterface for ICharacterGroupingsFactory { |
| const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x99ea9fd9_886d_4401_9f98_69c82d4c2f78); |
| } |
| #[repr(C)] |
| #[doc(hidden)] |
| pub struct ICharacterGroupingsFactory_Vtbl { |
| pub base__: ::windows::core::IInspectable_Vtbl, |
| pub Create: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, language: ::std::mem::MaybeUninit<::windows::core::HSTRING>, result__: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, |
| } |
| #[doc = "*Required features: `\"Globalization_Collation\"`*"] |
| #[repr(transparent)] |
| pub struct CharacterGrouping(::windows::core::IUnknown); |
| impl CharacterGrouping { |
| pub fn First(&self) -> ::windows::core::Result<::windows::core::HSTRING> { |
| let this = self; |
| unsafe { |
| let mut result__ = ::windows::core::zeroed::<::windows::core::HSTRING>(); |
| (::windows::core::Interface::vtable(this).First)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__) |
| } |
| } |
| pub fn Label(&self) -> ::windows::core::Result<::windows::core::HSTRING> { |
| let this = self; |
| unsafe { |
| let mut result__ = ::windows::core::zeroed::<::windows::core::HSTRING>(); |
| (::windows::core::Interface::vtable(this).Label)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__) |
| } |
| } |
| } |
| impl ::core::cmp::PartialEq for CharacterGrouping { |
| fn eq(&self, other: &Self) -> bool { |
| self.0 == other.0 |
| } |
| } |
| impl ::core::cmp::Eq for CharacterGrouping {} |
| impl ::core::fmt::Debug for CharacterGrouping { |
| fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { |
| f.debug_tuple("CharacterGrouping").field(&self.0).finish() |
| } |
| } |
| impl ::windows::core::RuntimeType for CharacterGrouping { |
| const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.Globalization.Collation.CharacterGrouping;{fae761bb-805d-4bb0-95bb-c1f7c3e8eb8e})"); |
| } |
| impl ::core::clone::Clone for CharacterGrouping { |
| fn clone(&self) -> Self { |
| Self(self.0.clone()) |
| } |
| } |
| unsafe impl ::windows::core::Interface for CharacterGrouping { |
| type Vtable = ICharacterGrouping_Vtbl; |
| } |
| unsafe impl ::windows::core::ComInterface for CharacterGrouping { |
| const IID: ::windows::core::GUID = <ICharacterGrouping as ::windows::core::ComInterface>::IID; |
| } |
| impl ::windows::core::RuntimeName for CharacterGrouping { |
| const NAME: &'static str = "Windows.Globalization.Collation.CharacterGrouping"; |
| } |
| ::windows::imp::interface_hierarchy!(CharacterGrouping, ::windows::core::IUnknown, ::windows::core::IInspectable); |
| unsafe impl ::core::marker::Send for CharacterGrouping {} |
| unsafe impl ::core::marker::Sync for CharacterGrouping {} |
| #[doc = "*Required features: `\"Globalization_Collation\"`*"] |
| #[repr(transparent)] |
| pub struct CharacterGroupings(::windows::core::IUnknown); |
| impl CharacterGroupings { |
| pub fn new() -> ::windows::core::Result<Self> { |
| Self::IActivationFactory(|f| f.ActivateInstance::<Self>()) |
| } |
| fn IActivationFactory<R, F: FnOnce(&::windows::imp::IGenericFactory) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> { |
| static SHARED: ::windows::imp::FactoryCache<CharacterGroupings, ::windows::imp::IGenericFactory> = ::windows::imp::FactoryCache::new(); |
| SHARED.call(callback) |
| } |
| pub fn Lookup(&self, text: &::windows::core::HSTRING) -> ::windows::core::Result<::windows::core::HSTRING> { |
| let this = self; |
| unsafe { |
| let mut result__ = ::windows::core::zeroed::<::windows::core::HSTRING>(); |
| (::windows::core::Interface::vtable(this).Lookup)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(text), &mut result__).from_abi(result__) |
| } |
| } |
| pub fn Create(language: &::windows::core::HSTRING) -> ::windows::core::Result<CharacterGroupings> { |
| Self::ICharacterGroupingsFactory(|this| unsafe { |
| let mut result__ = ::windows::core::zeroed::<CharacterGroupings>(); |
| (::windows::core::Interface::vtable(this).Create)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(language), &mut result__).from_abi(result__) |
| }) |
| } |
| #[doc = "*Required features: `\"Foundation_Collections\"`*"] |
| #[cfg(feature = "Foundation_Collections")] |
| pub fn First(&self) -> ::windows::core::Result<super::super::Foundation::Collections::IIterator<CharacterGrouping>> { |
| let this = &::windows::core::ComInterface::cast::<super::super::Foundation::Collections::IIterable<CharacterGrouping>>(self)?; |
| unsafe { |
| let mut result__ = ::windows::core::zeroed::<super::super::Foundation::Collections::IIterator<CharacterGrouping>>(); |
| (::windows::core::Interface::vtable(this).First)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__) |
| } |
| } |
| #[doc = "*Required features: `\"Foundation_Collections\"`*"] |
| #[cfg(feature = "Foundation_Collections")] |
| pub fn GetAt(&self, index: u32) -> ::windows::core::Result<CharacterGrouping> { |
| let this = &::windows::core::ComInterface::cast::<super::super::Foundation::Collections::IVectorView<CharacterGrouping>>(self)?; |
| unsafe { |
| let mut result__ = ::windows::core::zeroed::<CharacterGrouping>(); |
| (::windows::core::Interface::vtable(this).GetAt)(::windows::core::Interface::as_raw(this), index, &mut result__).from_abi(result__) |
| } |
| } |
| #[doc = "*Required features: `\"Foundation_Collections\"`*"] |
| #[cfg(feature = "Foundation_Collections")] |
| pub fn Size(&self) -> ::windows::core::Result<u32> { |
| let this = &::windows::core::ComInterface::cast::<super::super::Foundation::Collections::IVectorView<CharacterGrouping>>(self)?; |
| unsafe { |
| let mut result__ = ::windows::core::zeroed::<u32>(); |
| (::windows::core::Interface::vtable(this).Size)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__) |
| } |
| } |
| #[doc = "*Required features: `\"Foundation_Collections\"`*"] |
| #[cfg(feature = "Foundation_Collections")] |
| pub fn IndexOf(&self, value: &CharacterGrouping, index: &mut u32) -> ::windows::core::Result<bool> { |
| let this = &::windows::core::ComInterface::cast::<super::super::Foundation::Collections::IVectorView<CharacterGrouping>>(self)?; |
| unsafe { |
| let mut result__ = ::windows::core::zeroed::<bool>(); |
| (::windows::core::Interface::vtable(this).IndexOf)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(value), index, &mut result__).from_abi(result__) |
| } |
| } |
| #[doc = "*Required features: `\"Foundation_Collections\"`*"] |
| #[cfg(feature = "Foundation_Collections")] |
| pub fn GetMany(&self, startindex: u32, items: &mut [::core::option::Option<CharacterGrouping>]) -> ::windows::core::Result<u32> { |
| let this = &::windows::core::ComInterface::cast::<super::super::Foundation::Collections::IVectorView<CharacterGrouping>>(self)?; |
| unsafe { |
| let mut result__ = ::windows::core::zeroed::<u32>(); |
| (::windows::core::Interface::vtable(this).GetMany)(::windows::core::Interface::as_raw(this), startindex, items.len() as u32, ::core::mem::transmute_copy(&items), &mut result__).from_abi(result__) |
| } |
| } |
| #[doc(hidden)] |
| pub fn ICharacterGroupingsFactory<R, F: FnOnce(&ICharacterGroupingsFactory) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> { |
| static SHARED: ::windows::imp::FactoryCache<CharacterGroupings, ICharacterGroupingsFactory> = ::windows::imp::FactoryCache::new(); |
| SHARED.call(callback) |
| } |
| } |
| impl ::core::cmp::PartialEq for CharacterGroupings { |
| fn eq(&self, other: &Self) -> bool { |
| self.0 == other.0 |
| } |
| } |
| impl ::core::cmp::Eq for CharacterGroupings {} |
| impl ::core::fmt::Debug for CharacterGroupings { |
| fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { |
| f.debug_tuple("CharacterGroupings").field(&self.0).finish() |
| } |
| } |
| impl ::windows::core::RuntimeType for CharacterGroupings { |
| const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.Globalization.Collation.CharacterGroupings;{b8d20a75-d4cf-4055-80e5-ce169c226496})"); |
| } |
| impl ::core::clone::Clone for CharacterGroupings { |
| fn clone(&self) -> Self { |
| Self(self.0.clone()) |
| } |
| } |
| unsafe impl ::windows::core::Interface for CharacterGroupings { |
| type Vtable = ICharacterGroupings_Vtbl; |
| } |
| unsafe impl ::windows::core::ComInterface for CharacterGroupings { |
| const IID: ::windows::core::GUID = <ICharacterGroupings as ::windows::core::ComInterface>::IID; |
| } |
| impl ::windows::core::RuntimeName for CharacterGroupings { |
| const NAME: &'static str = "Windows.Globalization.Collation.CharacterGroupings"; |
| } |
| #[cfg(feature = "Foundation_Collections")] |
| impl ::core::iter::IntoIterator for CharacterGroupings { |
| type Item = CharacterGrouping; |
| type IntoIter = super::super::Foundation::Collections::VectorViewIterator<Self::Item>; |
| fn into_iter(self) -> Self::IntoIter { |
| ::core::iter::IntoIterator::into_iter(&self) |
| } |
| } |
| #[cfg(feature = "Foundation_Collections")] |
| impl ::core::iter::IntoIterator for &CharacterGroupings { |
| type Item = CharacterGrouping; |
| type IntoIter = super::super::Foundation::Collections::VectorViewIterator<Self::Item>; |
| fn into_iter(self) -> Self::IntoIter { |
| super::super::Foundation::Collections::VectorViewIterator::new(::windows::core::ComInterface::cast(self).ok()) |
| } |
| } |
| ::windows::imp::interface_hierarchy!(CharacterGroupings, ::windows::core::IUnknown, ::windows::core::IInspectable); |
| #[cfg(feature = "Foundation_Collections")] |
| impl ::windows::core::CanTryInto<super::super::Foundation::Collections::IIterable<CharacterGrouping>> for CharacterGroupings {} |
| #[cfg(feature = "Foundation_Collections")] |
| impl ::windows::core::CanTryInto<super::super::Foundation::Collections::IVectorView<CharacterGrouping>> for CharacterGroupings {} |
| unsafe impl ::core::marker::Send for CharacterGroupings {} |
| unsafe impl ::core::marker::Sync for CharacterGroupings {} |
| #[cfg(feature = "implement")] |
| ::core::include!("impl.rs"); |