Enum objc2_encode::Encoding [−][src]
pub enum Encoding<'a> {
Show 25 variants
Char,
Short,
Int,
Long,
LongLong,
UChar,
UShort,
UInt,
ULong,
ULongLong,
Float,
Double,
Bool,
Void,
String,
Object,
Block,
Class,
Sel,
Unknown,
BitField(u8),
Pointer(&'a Encoding<'a>),
Array(usize, &'a Encoding<'a>),
Struct(&'a str, &'a [Encoding<'a>]),
Union(&'a str, &'a [Encoding<'a>]),
}Expand description
An Objective-C type encoding.
For more information, see Apple’s documentation: https://developer.apple.com/library/mac/documentation/Cocoa/Conceptual/ObjCRuntimeGuide/Articles/ocrtTypeEncodings.html
Variants
Char
A C char. Corresponds to the c code.
Short
A C short. Corresponds to the s code.
Int
A C int. Corresponds to the i code.
Long
A C long. Corresponds to the l code.
LongLong
A C long long. Corresponds to the q code.
UChar
A C unsigned char. Corresponds to the C code.
UShort
A C unsigned short. Corresponds to the S code.
UInt
A C unsigned int. Corresponds to the I code.
ULong
A C unsigned long. Corresponds to the L code.
ULongLong
A C unsigned long long. Corresponds to the Q code.
Float
A C float. Corresponds to the f code.
Double
A C double. Corresponds to the d code.
Bool
A C++ bool / C99 _Bool. Corresponds to the B code.
Void
A C void. Corresponds to the v code.
String
A C char *. Corresponds to the * code.
Object
An Objective-C object (id). Corresponds to the @ code.
Block
An Objective-C block. Corresponds to the @? code.
Class
An Objective-C class (Class). Corresponds to the # code.
Sel
An Objective-C selector (SEL). Corresponds to the : code.
Unknown
An unknown type. Corresponds to the ? code.
BitField(u8)
Tuple Fields
0: u8A bitfield with the given number of bits.
Corresponds to the bnum code.
Pointer(&'a Encoding<'a>)
Tuple Fields
0: &'a Encoding<'a>A pointer to the given type.
Corresponds to the ^type code.
Array(usize, &'a Encoding<'a>)
An array with the given length and type.
Corresponds to the [len type] code.
Struct(&'a str, &'a [Encoding<'a>])
A struct with the given name and fields.
Corresponds to the {name=fields...} code.
Union(&'a str, &'a [Encoding<'a>])
A union with the given name and fields.
Corresponds to the (name=fields...) code.
Trait Implementations
Auto Trait Implementations
impl<'a> RefUnwindSafe for Encoding<'a>
impl<'a> UnwindSafe for Encoding<'a>
Blanket Implementations
Mutably borrows from an owned value. Read more