blob: b70e83a0f892ec52e00d868c685910d3746a8fd0 [file]
// generated by diplomat-tool
// dart format off
part of 'lib.g.dart';
/// See the [Rust documentation for `VerticalOrientation`](https://docs.rs/icu/2.0.0/icu/properties/props/struct.VerticalOrientation.html) for more information.
enum VerticalOrientation {
/// See the [Rust documentation for `Rotated`](https://docs.rs/icu/2.0.0/icu/properties/props/struct.VerticalOrientation.html#associatedconstant.Rotated) for more information.
rotated,
/// See the [Rust documentation for `TransformedRotated`](https://docs.rs/icu/2.0.0/icu/properties/props/struct.VerticalOrientation.html#associatedconstant.TransformedRotated) for more information.
transformedRotated,
/// See the [Rust documentation for `TransformedUpright`](https://docs.rs/icu/2.0.0/icu/properties/props/struct.VerticalOrientation.html#associatedconstant.TransformedUpright) for more information.
transformedUpright,
/// See the [Rust documentation for `Upright`](https://docs.rs/icu/2.0.0/icu/properties/props/struct.VerticalOrientation.html#associatedconstant.Upright) for more information.
upright;
/// See the [Rust documentation for `for_char`](https://docs.rs/icu/2.0.0/icu/properties/props/trait.EnumeratedProperty.html#tymethod.for_char) for more information.
static VerticalOrientation forChar(Rune ch) {
final result = _icu4x_VerticalOrientation_for_char_mv1(ch);
return VerticalOrientation.values[result];
}
/// Get the "long" name of this property value (returns empty if property value is unknown)
///
/// See the [Rust documentation for `get`](https://docs.rs/icu/2.0.0/icu/properties/struct.PropertyNamesLongBorrowed.html#method.get) for more information.
String? longName() {
final result = _icu4x_VerticalOrientation_long_name_mv1(index);
if (!result.isOk) {
return null;
}
return result.union.ok._toDart([], isStatic: true);
}
/// Get the "short" name of this property value (returns empty if property value is unknown)
///
/// See the [Rust documentation for `get`](https://docs.rs/icu/2.0.0/icu/properties/struct.PropertyNamesShortBorrowed.html#method.get) for more information.
String? shortName() {
final result = _icu4x_VerticalOrientation_short_name_mv1(index);
if (!result.isOk) {
return null;
}
return result.union.ok._toDart([], isStatic: true);
}
/// Convert to an integer value usable with ICU4C and CodePointMapData
///
/// See the [Rust documentation for `to_icu4c_value`](https://docs.rs/icu/2.0.0/icu/properties/props/struct.VerticalOrientation.html#method.to_icu4c_value) for more information.
int toIntegerValue() {
final result = _icu4x_VerticalOrientation_to_integer_value_mv1(index);
return result;
}
/// Convert from an integer value from ICU4C or CodePointMapData
///
/// See the [Rust documentation for `from_icu4c_value`](https://docs.rs/icu/2.0.0/icu/properties/props/struct.VerticalOrientation.html#method.from_icu4c_value) for more information.
static VerticalOrientation? fromIntegerValue(int other) {
final result = _icu4x_VerticalOrientation_from_integer_value_mv1(other);
if (!result.isOk) {
return null;
}
return VerticalOrientation.values[result.union.ok];
}
}
@_DiplomatFfiUse('icu4x_VerticalOrientation_for_char_mv1')
@ffi.Native<ffi.Int32 Function(ffi.Uint32)>(isLeaf: true, symbol: 'icu4x_VerticalOrientation_for_char_mv1')
// ignore: non_constant_identifier_names
external int _icu4x_VerticalOrientation_for_char_mv1(Rune ch);
@_DiplomatFfiUse('icu4x_VerticalOrientation_long_name_mv1')
@ffi.Native<_ResultSliceUtf8Void Function(ffi.Int32)>(isLeaf: true, symbol: 'icu4x_VerticalOrientation_long_name_mv1')
// ignore: non_constant_identifier_names
external _ResultSliceUtf8Void _icu4x_VerticalOrientation_long_name_mv1(int self);
@_DiplomatFfiUse('icu4x_VerticalOrientation_short_name_mv1')
@ffi.Native<_ResultSliceUtf8Void Function(ffi.Int32)>(isLeaf: true, symbol: 'icu4x_VerticalOrientation_short_name_mv1')
// ignore: non_constant_identifier_names
external _ResultSliceUtf8Void _icu4x_VerticalOrientation_short_name_mv1(int self);
@_DiplomatFfiUse('icu4x_VerticalOrientation_to_integer_value_mv1')
@ffi.Native<ffi.Uint8 Function(ffi.Int32)>(isLeaf: true, symbol: 'icu4x_VerticalOrientation_to_integer_value_mv1')
// ignore: non_constant_identifier_names
external int _icu4x_VerticalOrientation_to_integer_value_mv1(int self);
@_DiplomatFfiUse('icu4x_VerticalOrientation_from_integer_value_mv1')
@ffi.Native<_ResultInt32Void Function(ffi.Uint8)>(isLeaf: true, symbol: 'icu4x_VerticalOrientation_from_integer_value_mv1')
// ignore: non_constant_identifier_names
external _ResultInt32Void _icu4x_VerticalOrientation_from_integer_value_mv1(int other);
// dart format on