Main Page Namespace List Class Hierarchy Alphabetical List Compound List File List Compound Members File Members

# gnFilter Class Reference

`#include <gnFilter.h>`

Inheritance diagram for gnFilter::

List of all members.

## Public Types
enum | gnFilterType { alphabetCharacterFilterType, numberCharacterFilterType, proteinSeqFilterType, basicDNASeqFilterType, fullDNASeqFilterType, basicRNASeqFilterType, fullRNASeqFilterType, DNAtoRNAFilterType, RNAtoDNAFilterType, DNAComplementFilterType, RNAComplementFilterType }
## Public Methods
| gnFilter ()
| gnFilter (const gnFilterType f_type)
| Creates a gnFilter for a predefined filter type. More...
| gnFilter (const gnSeqC defaultChar, const gnSeqC rdefaultChar)
| gnFilter (const gnFilter &sf)
| ~gnFilter ()
gnFilter* | Clone () const
boolean | IsValid (const gnSeqC ch) const
gnSeqC | MakeValid (const gnSeqC ch) const
gnSeqC | Filter (const gnSeqC ch) const
| Filter the given character. More...
uint32 | IsValid (const gnSeqC *seq, const uint32 len) const
| IsValid() scans the supplied character array for invalid characters. More...
void | MakeValid (gnSeqC *seq, const uint32 len) const
void | Filter (gnSeqC **seq, uint32 &len) const
| Filter the given character array. More...
void | ReverseFilter (gnSeqC **seq, uint32 &len) const
uint32 | IsValid (const string &seq) const
void | MakeValid (string &seq) const
void | Filter (string &seq) const
| Filters the given string. More...
void | ReverseFilter (string &seq) const
void | SetDefaultChar (const gnSeqC ch1, const gnSeqC ch2)
gnSeqC | GetDefaultChar () const
gnSeqC | GetRDefaultChar () const
void | SetSingle (const gnSeqC ch)
void | SetPair (const gnSeqC ch1, const gnSeqC ch2)
boolean | RemovePair (const gnSeqC ch)
boolean | RemoveSingle (const gnSeqC ch)
## Static Public Methods
const gnFilter* | alphabetCharacterFilter ()
const gnFilter* | numberCharacterFilter ()
const gnFilter* | proteinSeqFilter ()
const gnFilter* | basicDNASeqFilter ()
const gnFilter* | fullDNASeqFilter ()
const gnFilter* | basicRNASeqFilter ()
const gnFilter* | fullRNASeqFilter ()
const gnFilter* | DNAtoRNAFilter ()
const gnFilter* | RNAtoDNAFilter ()
const gnFilter* | DNAComplementFilter ()
const gnFilter* | RNAComplementFilter ()
## Private Methods
void | CreateAlphabetCharacterFilter ()
void | CreateNumberCharacterFilter ()
void | CreateProteinFilter ()
void | CreateBasicDNAFilter ()
void | CreateFullDNAFilter ()
void | CreateBasicRNAFilter ()
void | CreateFullRNAFilter ()
void | CreateDNAtoRNAFilter ()
void | CreateRNAtoDNAFilter ()
void | CreateDNAComplementFilter ()
void | CreateRNAComplementFilter ()
## Private Attributes
string | m_name
gnSeqC | m_pairArray [GNSEQC_MAX]
gnSeqC | m_defaultChar
gnSeqC | m_rDefaultChar

## Member Enumeration Documentation

enum gnFilter::gnFilterType

  | Enumeration values:
  alphabetCharacterFilterType |
  numberCharacterFilterType |
  proteinSeqFilterType |
  basicDNASeqFilterType |
  fullDNASeqFilterType |
  basicRNASeqFilterType |
  fullRNASeqFilterType |
  DNAtoRNAFilterType |
  RNAtoDNAFilterType |
  DNAComplementFilterType |
  RNAComplementFilterType |
Definition at line 42 of file gnFilter.h.

## Constructor & Destructor Documentation

gnFilter::gnFilter ( | )

| Definition at line 76 of file gnFilter.cpp. Referenced by Clone(), DNAComplementFilter(), DNAtoRNAFilter(), RNAComplementFilter(), RNAtoDNAFilter(), alphabetCharacterFilter(), basicDNASeqFilter(), basicRNASeqFilter(), fullDNASeqFilter(), fullRNASeqFilter(), numberCharacterFilter(), and proteinSeqFilter().

gnFilter::gnFilter ( | const gnFilterType f_type )

  | Creates a gnFilter for a predefined filter type. Used by the static sequence constructors to avoid the "static initialization order fiasco" Parameters:
  f_type | The type of filter to create.
See also: gnFilterType Definition at line 100 of file gnFilter.cpp.

gnFilter::gnFilter ( | const gnSeqC defaultChar,
| const gnSeqC rdefaultChar )

| Definition at line 83 of file gnFilter.cpp.

gnFilter::gnFilter ( | const gnFilter & sf )

| Definition at line 91 of file gnFilter.cpp.

gnFilter::~gnFilter ( | )

| Definition at line 141 of file gnFilter.cpp.

## Member Function Documentation

gnFilter * gnFilter::Clone ( | ) const`[inline, virtual]`

| Reimplemented from gnBaseFilter. Definition at line 131 of file gnFilter.h.

void gnFilter::CreateAlphabetCharacterFilter ( | )`[private]`

| Definition at line 223 of file gnFilter.cpp. Referenced by gnFilter().

void gnFilter::CreateBasicDNAFilter ( | )`[private]`

| Definition at line 318 of file gnFilter.cpp. Referenced by gnFilter().

void gnFilter::CreateBasicRNAFilter ( | )`[private]`

| Definition at line 374 of file gnFilter.cpp. Referenced by gnFilter().

void gnFilter::CreateDNAComplementFilter ( | )`[private]`

| Definition at line 500 of file gnFilter.cpp. Referenced by gnFilter().

void gnFilter::CreateDNAtoRNAFilter ( | )`[private]`

| Definition at line 428 of file gnFilter.cpp. Referenced by gnFilter().

void gnFilter::CreateFullDNAFilter ( | )`[private]`

| Definition at line 336 of file gnFilter.cpp. Referenced by gnFilter().

void gnFilter::CreateFullRNAFilter ( | )`[private]`

| Definition at line 390 of file gnFilter.cpp. Referenced by gnFilter().

void gnFilter::CreateNumberCharacterFilter ( | )`[private]`

| Definition at line 255 of file gnFilter.cpp. Referenced by gnFilter().

void gnFilter::CreateProteinFilter ( | )`[private]`

| Definition at line 271 of file gnFilter.cpp. Referenced by gnFilter().

void gnFilter::CreateRNAComplementFilter ( | )`[private]`

| Definition at line 538 of file gnFilter.cpp. Referenced by gnFilter().

void gnFilter::CreateRNAtoDNAFilter ( | )`[private]`

| Definition at line 464 of file gnFilter.cpp. Referenced by gnFilter().

const gnFilter * gnFilter::DNAComplementFilter ( | )`[static]`

| Definition at line 64 of file gnFilter.cpp. Referenced by gnContigSpec::SeqRead().

const gnFilter * gnFilter::DNAtoRNAFilter ( | )`[static]`

| Definition at line 54 of file gnFilter.cpp.

void gnFilter::Filter ( | string & seq ) const`[virtual]`

  | Filters the given string. Parameters:
  seq | The string to filter
Reimplemented from gnBaseFilter. Definition at line 187 of file gnFilter.cpp.

void gnFilter::Filter ( | gnSeqC ** seq,
| uint32 & len ) const`[inline, virtual]`

  | Filter the given character array. Parameters:
  seq | A pointer to the character array
  len | the length of the character array to filter
Returns: The filtered character Reimplemented from gnBaseFilter. Definition at line 146 of file gnFilter.cpp.

gnSeqC gnFilter::Filter ( | const gnSeqC ch ) const`[inline, virtual]`

  | Filter the given character. Parameters:
  ch | The character to filter
Returns: The filtered character Reimplemented from gnBaseFilter. Definition at line 148 of file gnFilter.h.

gnSeqC gnFilter::GetDefaultChar ( | ) const`[inline]`

| Definition at line 193 of file gnFilter.h.

gnSeqC gnFilter::GetRDefaultChar ( | ) const`[inline]`

| Definition at line 198 of file gnFilter.h.

uint32 gnFilter::IsValid ( | const string & seq ) const`[inline]`

| Definition at line 175 of file gnFilter.h.

uint32 gnFilter::IsValid ( | const gnSeqC * seq,
| const uint32 len ) const`[inline]`

  | IsValid() scans the supplied character array for invalid characters. Parameters:
  seq | The sequence to scan. This is a generic character array.
  len | The length of the sequence to scan.
Returns: The index of the first invalid character, or len if none exists Definition at line 155 of file gnFilter.h.

boolean gnFilter::IsValid ( | const gnSeqC ch ) const`[inline]`

| Definition at line 138 of file gnFilter.h. Referenced by Filter(), and IsValid().

void gnFilter::MakeValid ( | string & seq ) const`[inline]`

| Definition at line 180 of file gnFilter.h.

void gnFilter::MakeValid ( | gnSeqC * seq,
| const uint32 len ) const`[inline]`

| Definition at line 165 of file gnFilter.h.

gnSeqC gnFilter::MakeValid ( | const gnSeqC ch ) const`[inline]`

| Definition at line 143 of file gnFilter.h. Referenced by MakeValid().

const gnFilter * gnFilter::RNAComplementFilter ( | )`[static]`

| Definition at line 69 of file gnFilter.cpp.

const gnFilter * gnFilter::RNAtoDNAFilter ( | )`[static]`

| Definition at line 59 of file gnFilter.cpp.

boolean gnFilter::RemovePair ( | const gnSeqC ch )`[inline]`

| Definition at line 215 of file gnFilter.h.

boolean gnFilter::RemoveSingle ( | const gnSeqC ch )`[inline]`

| Definition at line 222 of file gnFilter.h.

void gnFilter::ReverseFilter ( | string & seq ) const

| Definition at line 195 of file gnFilter.cpp.

void gnFilter::ReverseFilter ( | gnSeqC ** seq,
| uint32 & len ) const

| Definition at line 158 of file gnFilter.cpp. Referenced by gnContigSpec::SeqRead().

void gnFilter::SetDefaultChar ( | const gnSeqC ch1,
| const gnSeqC ch2 )`[inline]`

| Definition at line 187 of file gnFilter.h. Referenced by CreateAlphabetCharacterFilter(), CreateBasicDNAFilter(), CreateBasicRNAFilter(), CreateDNAComplementFilter(), CreateDNAtoRNAFilter(), CreateFullDNAFilter(), CreateFullRNAFilter(), CreateNumberCharacterFilter(), CreateProteinFilter(), CreateRNAComplementFilter(), and CreateRNAtoDNAFilter().

void gnFilter::SetPair ( | const gnSeqC ch1,
| const gnSeqC ch2 )`[inline]`

| Definition at line 209 of file gnFilter.h. Referenced by CreateAlphabetCharacterFilter(), CreateDNAComplementFilter(), CreateDNAtoRNAFilter(), CreateRNAComplementFilter(), and CreateRNAtoDNAFilter().

void gnFilter::SetSingle ( | const gnSeqC ch )`[inline]`

| Definition at line 204 of file gnFilter.h. Referenced by CreateBasicDNAFilter(), CreateBasicRNAFilter(), CreateDNAComplementFilter(), CreateDNAtoRNAFilter(), CreateFullDNAFilter(), CreateFullRNAFilter(), CreateNumberCharacterFilter(), CreateProteinFilter(), CreateRNAComplementFilter(), and CreateRNAtoDNAFilter().

const gnFilter * gnFilter::alphabetCharacterFilter ( | )`[static]`

| Definition at line 18 of file gnFilter.cpp.

const gnFilter * gnFilter::basicDNASeqFilter ( | )`[static]`

| Definition at line 34 of file gnFilter.cpp.

const gnFilter * gnFilter::basicRNASeqFilter ( | )`[static]`

| Definition at line 44 of file gnFilter.cpp.

const gnFilter * gnFilter::fullDNASeqFilter ( | )`[static]`

| Definition at line 39 of file gnFilter.cpp. Referenced by gnABISource::gnABISource(), gnDNXSource::gnDNXSource(), gnFASSource::gnFASSource(), gnGBKSource::gnGBKSource(), and gnSEQSource::gnSEQSource().

const gnFilter * gnFilter::fullRNASeqFilter ( | )`[static]`

| Definition at line 49 of file gnFilter.cpp.

const gnFilter * gnFilter::numberCharacterFilter ( | )`[static]`

| Definition at line 23 of file gnFilter.cpp.

const gnFilter * gnFilter::proteinSeqFilter ( | )`[static]`

| Definition at line 29 of file gnFilter.cpp.

## Member Data Documentation

gnSeqC gnFilter::m_defaultChar`[private]`

| Definition at line 125 of file gnFilter.h.

string gnFilter::m_name`[private]`

| Reimplemented from gnBaseFilter. Definition at line 122 of file gnFilter.h.

gnSeqC gnFilter::m_pairArray`[private]`

| Definition at line 124 of file gnFilter.h.

gnSeqC gnFilter::m_rDefaultChar`[private]`

| Definition at line 126 of file gnFilter.h.

The documentation for this class was generated from the following files:

- gnFilter.h
- gnFilter.cpp