Struct abjad::AbjadPrefs
source · pub struct AbjadPrefs {
pub count_shaddah: bool,
pub double_alif_maddah: bool,
pub ignore_lone_hamzah: bool,
pub letter_order: LetterOrder,
}
Expand description
We need to allow some options for abjad calculation. At present there are
four: three booleans and one enum
. All of the booleans are false by default.
The enum
also has a default value, which should be suitable for the vast
majority of use cases. If you don’t need to change any of the options, then,
when calling one of the methods, you can simply pass AbjadPrefs::default()
.
Fields§
§count_shaddah: bool
Count the shaddah diacritic? This will have the effect of doubling the value of the preceding letter.
double_alif_maddah: bool
Count alif maddah as a double alif (with value 2 instead of 1)?
ignore_lone_hamzah: bool
Ignore the pseudo-letter hamzah in its isolated state? (By default we assign it a value of 1.)
letter_order: LetterOrder
Which letter order to use: Mashriqi (default) or Maghribi? (Unless you are certain that you need the latter, you probably don’t.)
Trait Implementations§
source§impl Clone for AbjadPrefs
impl Clone for AbjadPrefs
source§fn clone(&self) -> AbjadPrefs
fn clone(&self) -> AbjadPrefs
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for AbjadPrefs
impl Debug for AbjadPrefs
source§impl Default for AbjadPrefs
impl Default for AbjadPrefs
source§fn default() -> AbjadPrefs
fn default() -> AbjadPrefs
source§impl Hash for AbjadPrefs
impl Hash for AbjadPrefs
source§impl Ord for AbjadPrefs
impl Ord for AbjadPrefs
source§fn cmp(&self, other: &AbjadPrefs) -> Ordering
fn cmp(&self, other: &AbjadPrefs) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere Self: Sized,
source§impl PartialEq<AbjadPrefs> for AbjadPrefs
impl PartialEq<AbjadPrefs> for AbjadPrefs
source§fn eq(&self, other: &AbjadPrefs) -> bool
fn eq(&self, other: &AbjadPrefs) -> bool
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd<AbjadPrefs> for AbjadPrefs
impl PartialOrd<AbjadPrefs> for AbjadPrefs
source§fn partial_cmp(&self, other: &AbjadPrefs) -> Option<Ordering>
fn partial_cmp(&self, other: &AbjadPrefs) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
self
and other
) and is used by the <=
operator. Read more