pub struct SeriesTransform<A: SerialAlphabet> { /* private fields */ }Expand description
A normalized positional and/or symbolic series transform.
Implementations§
Source§impl<A: SerialAlphabet> SeriesTransform<A>
impl<A: SerialAlphabet> SeriesTransform<A>
Sourcepub fn identity(cardinality: usize) -> Self
pub fn identity(cardinality: usize) -> Self
Constructs an identity transform for a known series cardinality.
Sourcepub fn retrograde(cardinality: usize) -> Self
pub fn retrograde(cardinality: usize) -> Self
Constructs a retrograde transform for a known series cardinality.
Sourcepub fn rotation(cardinality: usize, steps: usize) -> Self
pub fn rotation(cardinality: usize, steps: usize) -> Self
Constructs a left position rotation reduced modulo the series cardinality.
Sourcepub fn block_partition(partition: BlockPartition) -> Self
pub fn block_partition(partition: BlockPartition) -> Self
Constructs the order transform induced by an exhaustive block partition.
Sourcepub fn ordinal_permutation(order_map: OrdinalMap) -> Self
pub fn ordinal_permutation(order_map: OrdinalMap) -> Self
Constructs a transform from a prevalidated ordinal permutation.
Sourcepub fn cyclic_relabeling(
alphabet: A,
steps: usize,
) -> Result<Self, SymbolBijectionError>
pub fn cyclic_relabeling( alphabet: A, steps: usize, ) -> Result<Self, SymbolBijectionError>
Constructs a cyclic relabeling over an alphabet’s canonical order.
Sourcepub fn bijection(relabeling: SymbolBijection<A>) -> Self
pub fn bijection(relabeling: SymbolBijection<A>) -> Self
Constructs a transform from a caller-supplied validated symbol bijection.
Sourcepub fn order_map(&self) -> Option<&OrdinalMap>
pub fn order_map(&self) -> Option<&OrdinalMap>
Returns the explicit order map, or None when positions are retained.
Sourcepub fn relabeling(&self) -> Option<&SymbolBijection<A>>
pub fn relabeling(&self) -> Option<&SymbolBijection<A>>
Returns the symbolic relabeling, or None when symbols are retained.
Sourcepub fn compose(&self, next: &Self) -> Result<Self, SeriesTransformError>
pub fn compose(&self, next: &Self) -> Result<Self, SeriesTransformError>
Composes self followed by next into one normalized transform.
Sourcepub fn inverse(&self) -> Result<Self, SeriesTransformError>
pub fn inverse(&self) -> Result<Self, SeriesTransformError>
Returns the exact inverse transform.
Sourcepub fn canonical_form(&self) -> String
pub fn canonical_form(&self) -> String
Returns a deterministic canonical representation of the normalized maps.
Trait Implementations§
Source§impl<A: Clone + SerialAlphabet> Clone for SeriesTransform<A>
impl<A: Clone + SerialAlphabet> Clone for SeriesTransform<A>
Source§fn clone(&self) -> SeriesTransform<A>
fn clone(&self) -> SeriesTransform<A>
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more