#[repr(u8)]pub enum Placement {
Top = 0,
TopStart = 1,
TopEnd = 2,
Bottom = 3,
BottomStart = 4,
BottomEnd = 5,
Left = 6,
LeftStart = 7,
LeftEnd = 8,
Right = 9,
RightStart = 10,
RightEnd = 11,
}Expand description
All 12 anchored overlay placements (4 sides × 3 cross-axis alignments).
Variants§
Top = 0
TopStart = 1
TopEnd = 2
Bottom = 3
BottomStart = 4
BottomEnd = 5
Left = 6
LeftStart = 7
LeftEnd = 8
Right = 9
RightStart = 10
RightEnd = 11
Implementations§
Source§impl OverlayPlacement
impl OverlayPlacement
pub const COUNT: usize = 12
pub const BITS: u8 = 4
pub const ALL: &'static [OverlayPlacement]
Sourcepub const VALUE_SET: ValueSetDesc
pub const VALUE_SET: ValueSetDesc
Named variants mirrored to hosts as NV_<TYPE>_<VARIANT>.
pub const fn to_word(self) -> u32
pub const fn try_from_word(__nv_bits: u32) -> Option<OverlayPlacement>
pub const fn from_word(__nv_bits: u32) -> OverlayPlacement
pub const fn opt_to_word(__nv_v: Option<OverlayPlacement>) -> u32
Source§impl OverlayPlacement
impl OverlayPlacement
pub const fn side(self) -> Side
pub const fn alignment(self) -> Alignment
pub const fn from_side_align(side: Side, align: Alignment) -> OverlayPlacement
Sourcepub const fn opposite(self) -> OverlayPlacement
pub const fn opposite(self) -> OverlayPlacement
Flips the primary side (Bottom -> Top, RightStart -> LeftStart) while keeping alignment.
Sourcepub const fn flip_alignment(self) -> OverlayPlacement
pub const fn flip_alignment(self) -> OverlayPlacement
Flips cross-axis alignment (Start <-> End) while keeping the primary side.
Trait Implementations§
Source§impl Clone for OverlayPlacement
impl Clone for OverlayPlacement
Source§fn clone(&self) -> OverlayPlacement
fn clone(&self) -> OverlayPlacement
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for OverlayPlacement
Source§impl Debug for OverlayPlacement
impl Debug for OverlayPlacement
Source§impl Default for OverlayPlacement
impl Default for OverlayPlacement
Source§fn default() -> OverlayPlacement
fn default() -> OverlayPlacement
Returns the “default value” for a type. Read more
Source§impl Display for OverlayPlacement
impl Display for OverlayPlacement
impl Eq for OverlayPlacement
Source§impl Hash for OverlayPlacement
impl Hash for OverlayPlacement
Source§impl OptWord for OverlayPlacement
impl OptWord for OverlayPlacement
const OPT_BITS: u8 = 4
const OPT_KIND: FieldKind = ::nativeview_store::__private::FieldKind::Enum
const OPT_ENCODING: OptEncoding = ::nativeview_store::__private::OptEncoding::PlusOne
Source§const VALUES: Option<&'static ValueSetDesc>
const VALUES: Option<&'static ValueSetDesc>
Named values of the inner type (see
WordValue::VALUES).fn opt_to_bits(__nv_v: Option<OverlayPlacement>) -> u32
fn opt_from_bits(__nv_bits: u32) -> Option<OverlayPlacement>
Source§impl PartialEq for OverlayPlacement
impl PartialEq for OverlayPlacement
impl StructuralPartialEq for OverlayPlacement
Source§impl WordValue for OverlayPlacement
impl WordValue for OverlayPlacement
const BITS: u8 = 4
const KIND: FieldKind = ::nativeview_store::__private::FieldKind::Enum
Source§const VALUES: Option<&'static ValueSetDesc>
const VALUES: Option<&'static ValueSetDesc>
Named values (
WordEnum variants, word_flags! bits), mirrored to hosts as
NV_<TYPE>_<VALUE> by codegen so foreign code never hand-copies them.fn to_bits(self) -> u32
fn from_bits(__nv_bits: u32) -> OverlayPlacement
Source§const OPT_ENCODING: OptEncoding = OptEncoding::Required
const OPT_ENCODING: OptEncoding = OptEncoding::Required
Optionality & bit-encoding discriminator hashed into
TableDesc::schema_hash.Source§fn to_masked_bits(self, _bit_width: u32) -> u32
fn to_masked_bits(self, _bit_width: u32) -> u32
Source§fn from_masked_bits(bits: u32, _bit_width: u32) -> Self
fn from_masked_bits(bits: u32, _bit_width: u32) -> Self
Decodes
bits from a field of bit_width (1..=32) bits (sign-extending narrowed signed
integers).Auto Trait Implementations§
impl Forget for OverlayPlacement
impl Freeze for OverlayPlacement
impl Move for OverlayPlacement
impl RefUnwindSafe for OverlayPlacement
impl Send for OverlayPlacement
impl Sync for OverlayPlacement
impl Unpin for OverlayPlacement
impl UnsafeUnpin for OverlayPlacement
impl UnwindSafe for OverlayPlacement
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> ScalarField for Twhere
T: WordValue,
impl<T> ScalarField for Twhere
T: WordValue,
fn read_row( row: &[u32], word: usize, shift: u32, mask: u32, _val_word: usize, ) -> T
fn write_row( self, writer: &mut RowWriter<'_>, word: usize, shift: u32, mask: u32, _val_word: usize, )
Source§fn encode_patch_ops(
self,
word: usize,
shift: u32,
mask: u32,
_val_word: usize,
emit: &mut dyn FnMut(usize, u32, u32),
)
fn encode_patch_ops( self, word: usize, shift: u32, mask: u32, _val_word: usize, emit: &mut dyn FnMut(usize, u32, u32), )
Emits
(word_idx, clear_mask, set_bits) masked patch operations for crate::RowPatch.fn read_ref( row: RowRef<'_>, word: usize, shift: u32, mask: u32, val_word: usize, ) -> Self
Source§impl<T> TableField for Twhere
T: WordValue,
impl<T> TableField for Twhere
T: WordValue,
const KIND: FieldKind = T::KIND
Source§const OPT_ENCODING: OptEncoding = T::OPT_ENCODING
const OPT_ENCODING: OptEncoding = T::OPT_ENCODING
Optionality & bit-encoding discriminator hashed into
TableDesc::schema_hash.Source§const BITS: u8 = T::BITS
const BITS: u8 = T::BITS
Bits occupied in its primary word (
1..=32 for scalar, 1 for wide Option<T>, 64 for 64-bit/Str).Source§const PACK_KIND: PackKind = PackKind::Scalar
const PACK_KIND: PackKind = PackKind::Scalar
Word packing layout shape (
Scalar, WideOpt, Wide64, Str, Resource).Source§const VALUES: Option<&'static ValueSetDesc> = T::VALUES
const VALUES: Option<&'static ValueSetDesc> = T::VALUES
Named values the field holds (see
WordValue::VALUES).