Enum pgn_reader::File [−][src]
#[repr(u8)] pub enum File { A, B, C, D, E, F, G, H, }
A file of the chessboard.
Variants
Implementations
impl File
[src]
pub fn new(index: u32) -> File
[src]
pub unsafe fn new_unchecked(index: u32) -> File
[src]
Gets a File
from an integer index.
Safety
It is the callers responsibility to ensure the index is in the range
0..=7
.
pub fn from_char(ch: char) -> Option<File>
[src]
pub fn char(self) -> char
[src]
#[must_use]pub fn offset(self, delta: i32) -> Option<Rank>
[src]
#[must_use]pub fn flip_horizontal(self) -> File
[src]
#[must_use]pub fn flip_diagonal(self) -> Rank
[src]
#[must_use]pub fn flip_anti_diagonal(self) -> Rank
[src]
Trait Implementations
impl Clone for File
[src]
impl Copy for File
[src]
impl Debug for File
[src]
impl Display for File
[src]
impl Eq for File
[src]
impl Hash for File
[src]
pub fn hash<__H>(&self, state: &mut __H) where
__H: Hasher,
[src]
__H: Hasher,
pub fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
impl Ord for File
[src]
pub fn cmp(&self, other: &File) -> Ordering
[src]
#[must_use]pub fn max(self, other: Self) -> Self
1.21.0[src]
#[must_use]pub fn min(self, other: Self) -> Self
1.21.0[src]
#[must_use]pub fn clamp(self, min: Self, max: Self) -> Self
1.50.0[src]
impl PartialEq<File> for File
[src]
pub fn eq(&self, other: &File) -> bool
[src]
#[must_use]pub fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
impl PartialOrd<File> for File
[src]
pub fn partial_cmp(&self, other: &File) -> Option<Ordering>
[src]
#[must_use]pub fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]pub fn le(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]pub fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]pub fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
impl StructuralEq for File
[src]
impl StructuralPartialEq for File
[src]
impl Sub<File> for File
[src]
type Output = i32
The resulting type after applying the -
operator.
pub fn sub(self, other: File) -> i32
[src]
impl TryFrom<i16> for File
[src]
type Error = TryFromIntError
The type returned in the event of a conversion error.
pub fn try_from(value: i16) -> Result<File, <File as TryFrom<i16>>::Error>
[src]
impl TryFrom<i32> for File
[src]
type Error = TryFromIntError
The type returned in the event of a conversion error.
pub fn try_from(value: i32) -> Result<File, <File as TryFrom<i32>>::Error>
[src]
impl TryFrom<i64> for File
[src]
type Error = TryFromIntError
The type returned in the event of a conversion error.
pub fn try_from(value: i64) -> Result<File, <File as TryFrom<i64>>::Error>
[src]
impl TryFrom<i8> for File
[src]
type Error = TryFromIntError
The type returned in the event of a conversion error.
pub fn try_from(value: i8) -> Result<File, <File as TryFrom<i8>>::Error>
[src]
impl TryFrom<isize> for File
[src]
type Error = TryFromIntError
The type returned in the event of a conversion error.
pub fn try_from(value: isize) -> Result<File, <File as TryFrom<isize>>::Error>
[src]
impl TryFrom<u16> for File
[src]
type Error = TryFromIntError
The type returned in the event of a conversion error.
pub fn try_from(value: u16) -> Result<File, <File as TryFrom<u16>>::Error>
[src]
impl TryFrom<u32> for File
[src]
type Error = TryFromIntError
The type returned in the event of a conversion error.
pub fn try_from(value: u32) -> Result<File, <File as TryFrom<u32>>::Error>
[src]
impl TryFrom<u64> for File
[src]
type Error = TryFromIntError
The type returned in the event of a conversion error.
pub fn try_from(value: u64) -> Result<File, <File as TryFrom<u64>>::Error>
[src]
impl TryFrom<u8> for File
[src]
type Error = TryFromIntError
The type returned in the event of a conversion error.
pub fn try_from(value: u8) -> Result<File, <File as TryFrom<u8>>::Error>
[src]
impl TryFrom<usize> for File
[src]
Auto Trait Implementations
impl RefUnwindSafe for File
impl Send for File
impl Sync for File
impl Unpin for File
impl UnwindSafe for File
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,