Skip to main content

Language

Enum Language 

Source
#[non_exhaustive]
pub enum Language {
Show 149 variants Afrikaans, Albanian, ArabicSaudiArabia, ArabicIraq, ArabicEgypt, ArabicLibya, ArabicAlgeria, ArabicMorocco, ArabicTunisia, ArabicOman, ArabicYemen, ArabicSyria, ArabicJordan, ArabicLebanon, ArabicKuwait, ArabicUAE, ArabicBahrain, ArabicQatar, Armenian, Assamese, AzeriLatin, AzeriCyrillic, Basque, Belarussian, Bengali, Bulgarian, Burmese, Catalan, ChineseTaiwan, ChinesePRC, ChineseHongKongSARPRC, ChineseSingapore, ChineseMacauSAR, Croatian, Czech, Danish, DutchNetherlands, DutchBelgium, EnglishUnitedStates, EnglishUnitedKingdom, EnglishAustralian, EnglishCanadian, EnglishNewZealand, EnglishIreland, EnglishSouthAfrica, EnglishJamaica, EnglishCaribbean, EnglishBelize, EnglishTrinidad, EnglishZimbabwe, EnglishPhilippines, Estonian, Faeroese, Farsi, Finnish, FrenchStandard, FrenchBelgian, FrenchCanadian, FrenchSwitzerland, FrenchLuxembourg, FrenchMonaco, Georgian, GermanStandard, GermanSwitzerland, GermanAustria, GermanLuxembourg, GermanLiechtenstein, Greek, Gujarati, Hebrew, Hindi, Hungarian, Icelandic, Indonesian, ItalianStandard, ItalianSwitzerland, Japanese, Kannada, KashmiriIndia, Kazakh, Konkani, Korean, KoreanJohab, Latvian, Lithuanian, LithuanianClassic, Macedonian, MalayMalaysian, MalayBruneiDarussalam, Malayalam, Manipuri, Marathi, NepaliIndia, NorwegianBokmal, NorwegianNynorsk, Oriya, Polish, PortugueseBrazil, PortugueseStandard, Punjabi, Romanian, Russian, Sanskrit, SerbianCyrillic, SerbianLatin, Sindhi, Slovak, Slovenian, SpanishTraditionalSort, SpanishMexican, SpanishModernSort, SpanishGuatemala, SpanishCostaRica, SpanishPanama, SpanishDominicanRepublic, SpanishVenezuela, SpanishColombia, SpanishPeru, SpanishArgentina, SpanishEcuador, SpanishChile, SpanishUruguay, SpanishParaguay, SpanishBolivia, SpanishElSalvador, SpanishHonduras, SpanishNicaragua, SpanishPuertoRico, Sutu, SwahiliKenya, Swedish, SwedishFinland, Tamil, TatarTatarstan, Telugu, Thai, Turkish, Ukrainian, UrduPakistan, UrduIndia, UzbekLatin, UzbekCyrillic, Vietnamese, HidUsageDataDescriptor, HidVendorDefined1, HidVendorDefined2, HidVendorDefined3, HidVendorDefined4, Other(u16),
}
Expand description

USB language id.

Variants (Non-exhaustive)§

This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
§

Afrikaans

Afrikaans

§

Albanian

Albanian

§

ArabicSaudiArabia

Arabic (Saudi Arabia)

§

ArabicIraq

Arabic (Iraq)

§

ArabicEgypt

Arabic (Egypt)

§

ArabicLibya

Arabic (Libya)

§

ArabicAlgeria

Arabic (Algeria)

§

ArabicMorocco

Arabic (Morocco)

§

ArabicTunisia

Arabic (Tunisia)

§

ArabicOman

Arabic (Oman)

§

ArabicYemen

Arabic (Yemen)

§

ArabicSyria

Arabic (Syria)

§

ArabicJordan

Arabic (Jordan)

§

ArabicLebanon

Arabic (Lebanon)

§

ArabicKuwait

Arabic (Kuwait)

§

ArabicUAE

Arabic (UAE)

§

ArabicBahrain

Arabic (Bahrain)

§

ArabicQatar

Arabic (Qatar)

§

Armenian

Armenian

§

Assamese

Assamese

§

AzeriLatin

Azeri (Latin)

§

AzeriCyrillic

Azeri (Cyrillic)

§

Basque

Basque

§

Belarussian

Belarussian

§

Bengali

Bengali

§

Bulgarian

Bulgarian

§

Burmese

Burmese

§

Catalan

Catalan

§

ChineseTaiwan

Chinese (Taiwan)

§

ChinesePRC

Chinese (PRC)

§

ChineseHongKongSARPRC

Chinese (Hong Kong SAR PRC)

§

ChineseSingapore

Chinese (Singapore)

§

ChineseMacauSAR

Chinese (Macau SAR)

§

Croatian

Croatian

§

Czech

Czech

§

Danish

Danish

§

DutchNetherlands

Dutch (Netherlands)

§

DutchBelgium

Dutch (Belgium)

§

EnglishUnitedStates

English (United States)

§

EnglishUnitedKingdom

English (United Kingdom)

§

EnglishAustralian

English (Australian)

§

EnglishCanadian

English (Canadian)

§

EnglishNewZealand

English (New Zealand)

§

EnglishIreland

English (Ireland)

§

EnglishSouthAfrica

English (South Africa)

§

EnglishJamaica

English (Jamaica)

§

EnglishCaribbean

English (Caribbean)

§

EnglishBelize

English (Belize)

§

EnglishTrinidad

English (Trinidad)

§

EnglishZimbabwe

English (Zimbabwe)

§

EnglishPhilippines

English (Philippines)

§

Estonian

Estonian

§

Faeroese

Faeroese

§

Farsi

Farsi

§

Finnish

Finnish

§

FrenchStandard

French (Standard)

§

FrenchBelgian

French (Belgian)

§

FrenchCanadian

French (Canadian)

§

FrenchSwitzerland

French (Switzerland)

§

FrenchLuxembourg

French (Luxembourg)

§

FrenchMonaco

French (Monaco)

§

Georgian

Georgian

§

GermanStandard

German (Standard)

§

GermanSwitzerland

German (Switzerland)

§

GermanAustria

German (Austria)

§

GermanLuxembourg

German (Luxembourg)

§

GermanLiechtenstein

German (Liechtenstein)

§

Greek

Greek

§

Gujarati

Gujarati

§

Hebrew

Hebrew

§

Hindi

Hindi

§

Hungarian

Hungarian

§

Icelandic

Icelandic

§

Indonesian

Indonesian

§

ItalianStandard

Italian (Standard)

§

ItalianSwitzerland

Italian (Switzerland)

§

Japanese

Japanese

§

Kannada

Kannada

§

KashmiriIndia

KashmiriIndia

§

Kazakh

Kazakh

§

Konkani

Konkani

§

Korean

Korean

§

KoreanJohab

Korean (Johab)

§

Latvian

Latvian

§

Lithuanian

Lithuanian

§

LithuanianClassic

Lithuanian (Classic)

§

Macedonian

Macedonian

§

MalayMalaysian

Malay (Malaysian)

§

MalayBruneiDarussalam

Malay (Brunei Darussalam)

§

Malayalam

Malayalam

§

Manipuri

Manipuri

§

Marathi

Marathi

§

NepaliIndia

Nepali (India)

§

NorwegianBokmal

Norwegian (Bokmal)

§

NorwegianNynorsk

Norwegian (Nynorsk)

§

Oriya

Oriya

§

Polish

Polish

§

PortugueseBrazil

Portuguese (Brazil)

§

PortugueseStandard

Portuguese (Standard)

§

Punjabi

Punjabi

§

Romanian

Romanian

§

Russian

Russian

§

Sanskrit

Sanskrit

§

SerbianCyrillic

Serbian (Cyrillic)

§

SerbianLatin

Serbian (Latin)

§

Sindhi

Sindhi

§

Slovak

Slovak

§

Slovenian

Slovenian

§

SpanishTraditionalSort

Spanish (Traditional Sort)

§

SpanishMexican

Spanish (Mexican)

§

SpanishModernSort

Spanish (ModernSort)

§

SpanishGuatemala

Spanish (Guatemala)

§

SpanishCostaRica

Spanish (Costa Rica)

§

SpanishPanama

Spanish (Panama)

§

SpanishDominicanRepublic

Spanish (Dominican Republic)

§

SpanishVenezuela

Spanish (Venezuela)

§

SpanishColombia

Spanish (Colombia)

§

SpanishPeru

Spanish (Peru)

§

SpanishArgentina

Spanish (Argentina)

§

SpanishEcuador

Spanish (Ecuador)

§

SpanishChile

Spanish (Chile)

§

SpanishUruguay

Spanish (Uruguay)

§

SpanishParaguay

Spanish (Paraguay)

§

SpanishBolivia

Spanish (Bolivia)

§

SpanishElSalvador

Spanish (El Salvador)

§

SpanishHonduras

Spanish (Honduras)

§

SpanishNicaragua

Spanish (Nicaragua)

§

SpanishPuertoRico

Spanish (Puerto Rico)

§

Sutu

Sutu

§

SwahiliKenya

Swahili (Kenya)

§

Swedish

Swedish

§

SwedishFinland

Swedish (Finland)

§

Tamil

Tamil

§

TatarTatarstan

Tatar (Tatarstan)

§

Telugu

Telugu

§

Thai

Thai

§

Turkish

Turkish

§

Ukrainian

Ukrainian

§

UrduPakistan

Urdu (Pakistan)

§

UrduIndia

Urdu (India)

§

UzbekLatin

Uzbek (Latin)

§

UzbekCyrillic

Uzbek (Cyrillic)

§

Vietnamese

Vietnamese

§

HidUsageDataDescriptor

HID usage data descriptor

§

HidVendorDefined1

HID vendor defined 1

§

HidVendorDefined2

HID vendor defined 2

§

HidVendorDefined3

HID vendor defined 3

§

HidVendorDefined4

HID vendor defined 4

§

Other(u16)

Custom language code

Trait Implementations§

Source§

impl Clone for Language

Source§

fn clone(&self) -> Language

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Language

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for Language

Source§

fn default() -> Language

Returns the “default value” for a type. Read more
Source§

impl From<Language> for u16

Source§

fn from(lang: Language) -> u16

Converts to this type from the input type.
Source§

impl Hash for Language

Source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · Source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source§

impl Ord for Language

Source§

fn cmp(&self, other: &Language) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · Source§

fn max(self, other: Self) -> Self
where Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · Source§

fn min(self, other: Self) -> Self
where Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · Source§

fn clamp(self, min: Self, max: Self) -> Self
where Self: Sized,

Restrict a value to a certain interval. Read more
Source§

impl PartialEq for Language

Source§

fn eq(&self, other: &Language) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl PartialOrd for Language

Source§

fn partial_cmp(&self, other: &Language) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · Source§

fn lt(&self, other: &Rhs) -> bool

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · Source§

fn le(&self, other: &Rhs) -> bool

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · Source§

fn gt(&self, other: &Rhs) -> bool

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · Source§

fn ge(&self, other: &Rhs) -> bool

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
Source§

impl Copy for Language

Source§

impl Eq for Language

Source§

impl StructuralPartialEq for Language

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.