OpenMS
AA Struct Reference

#include <OpenMS/ANALYSIS/ID/AhoCorasickAmbiguous.h>

Collaboration diagram for AA:
[legend]

Public Member Functions

constexpr AA ()
 Default C'tor; creates an invalid AA. More...
 
constexpr AA (const char c)
 
constexpr uint8_t operator() () const
 yields the internal 8bit representation More...
 
constexpr bool operator== (const AA other) const
 equality operator More...
 
constexpr bool operator<= (const AA other) const
 less-or-equal operator More...
 
constexpr bool isAmbiguous () const
 is AA a 'B', 'J', 'Z', 'X', or '$' ? More...
 
constexpr bool isValid () const
 is AA a letter or '$' ? More...
 
constexpr bool isValidForPeptide () const
 is the AA a letter, i.e. A-Z or a-z? More...
 
constexpr AAoperator++ ()
 Pre-increment operator (advance to next AA) More...
 
constexpr AA operator++ (int)
 Post-increment operator (advance to next AA) More...
 
constexpr AA operator- (const AA rhs) const
 Decrement operator. More...
 

Private Attributes

uint8_t aa_
 internal representation as 1-byte integer More...
 

Detailed Description

An AminoAcid, with supports construction from char and has convenience functions such as isAmbiguous() or isValid()

Constructor & Destructor Documentation

◆ AA() [1/2]

constexpr AA ( )
inlineconstexpr

Default C'tor; creates an invalid AA.

◆ AA() [2/2]

constexpr AA ( const char  c)
inlineexplicitconstexpr

C'tor from char; any char A-Z or a-z yields a valid AA. '$' is a special AA, which should only be used when modeling mismatches. All other chars produce an invalid AA ('?')

Member Function Documentation

◆ isAmbiguous()

constexpr bool isAmbiguous ( ) const
inlineconstexpr

is AA a 'B', 'J', 'Z', 'X', or '$' ?

References AA::aa_.

◆ isValid()

constexpr bool isValid ( ) const
inlineconstexpr

is AA a letter or '$' ?

References AA::aa_.

◆ isValidForPeptide()

constexpr bool isValidForPeptide ( ) const
inlineconstexpr

is the AA a letter, i.e. A-Z or a-z?

References AA::aa_.

◆ operator()()

constexpr uint8_t operator() ( ) const
inlineconstexpr

yields the internal 8bit representation

◆ operator++() [1/2]

constexpr AA& operator++ ( )
inlineconstexpr

Pre-increment operator (advance to next AA)

◆ operator++() [2/2]

constexpr AA operator++ ( int  )
inlineconstexpr

Post-increment operator (advance to next AA)

◆ operator-()

constexpr AA operator- ( const AA  rhs) const
inlineconstexpr

Decrement operator.

References AA::aa_.

◆ operator<=()

constexpr bool operator<= ( const AA  other) const
inlineconstexpr

less-or-equal operator

References AA::aa_.

◆ operator==()

constexpr bool operator== ( const AA  other) const
inlineconstexpr

equality operator

References AA::aa_.

Member Data Documentation

◆ aa_

uint8_t aa_
private

internal representation as 1-byte integer

Referenced by AA::isAmbiguous(), AA::isValid(), AA::isValidForPeptide(), AA::operator-(), AA::operator<=(), and AA::operator==().