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

# gnPosSpecificTranslator Class Reference

Used to translate sequences differently based on the position of input characters. More...

`#include <gnPosSpecificTranslator.h>`

Inheritance diagram for gnPosSpecificTranslator:

List of all members.

## Public Types
enum | gnTranslatorType { ProteinDNATranslatorType, DNAProteinTranslatorType }
## Public Member Functions
| gnPosSpecificTranslator ()
| gnPosSpecificTranslator (gnTranslatorType t_type)
| gnPosSpecificTranslator (const gnPosSpecificTranslator &sf)
gnPosSpecificTranslator & | operator= (const gnPosSpecificTranslator &sf)
gnPosSpecificTranslator * | Clone () const
virtual gnSeqC | Filter (const gnSeqC ch) const
| Filter the given character.
virtual void | Filter (gnSeqC **seq, uint32 &len) const
| Filter the given character array.
virtual void | Filter (string &seq) const
| Filters the given string.
virtual string | GetName () const
| Gets the name of this filter.
virtual void | SetName (string name)
| Sets the name of this filter.
## Static Public Member Functions
const gnPosSpecificTranslator * | ProteinDNATranslator ()
const gnPosSpecificTranslator * | DNAProteinTranslator ()
## Protected Attributes
string | m_name
## Private Member Functions
void | CreateProteinDNATranslator ()
void | CreateDNAProteinTranslator ()
## Private Attributes
gnTranslatorType | m_type
const gnBaseFilter * | filter

## Detailed Description

Used to translate sequences differently based on the position of input characters.

Useful for tranlating genes because the first codon is translated differently.

Definition at line 32 of file gnPosSpecificTranslator.h.

## Member Enumeration Documentation

enum gnPosSpecificTranslator::gnTranslatorType

  | Enumeration values:
  ProteinDNATranslatorType |
  DNAProteinTranslatorType |
Definition at line 39 of file gnPosSpecificTranslator.h.

## Constructor & Destructor Documentation

gnPosSpecificTranslator::gnPosSpecificTranslator | ( |  | ) |

| Definition at line 28 of file gnPosSpecificTranslator.cpp. Referenced by Clone(), DNAProteinTranslator(), and ProteinDNATranslator().

gnPosSpecificTranslator::gnPosSpecificTranslator | ( | gnTranslatorType | t_type | ) |

| Definition at line 36 of file gnPosSpecificTranslator.cpp. References gnFastTranslator::DNAProteinTranslator(), DNAProteinTranslatorType, filter, m_type, gnFastTranslator::ProteinDNATranslator(), and ProteinDNATranslatorType.

gnPosSpecificTranslator::gnPosSpecificTranslator | ( | const gnPosSpecificTranslator & | sf | ) |

| Definition at line 32 of file gnPosSpecificTranslator.cpp. References gnBaseFilter::m_name.

## Member Function Documentation

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

| Implements gnBaseFilter. Definition at line 67 of file gnPosSpecificTranslator.h. References gnPosSpecificTranslator().

void gnPosSpecificTranslator::CreateDNAProteinTranslator | ( |  | ) | `[private]`

void gnPosSpecificTranslator::CreateProteinDNATranslator | ( |  | ) | `[private]`

const gnPosSpecificTranslator * gnPosSpecificTranslator::DNAProteinTranslator | ( |  | ) | `[static]`

| Definition at line 22 of file gnPosSpecificTranslator.cpp. References gnPosSpecificTranslator().

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

  | Filters the given string. Parameters:
  seq | The string to filter
Implements gnBaseFilter. Definition at line 59 of file gnPosSpecificTranslator.cpp. References DNAProteinTranslatorType, gnBaseFilter::Filter(), filter, and ProteinDNATranslatorType.

void gnPosSpecificTranslator::Filter | ( | gnSeqC ** | seq,
|  | uint32 & | len
| ) | const`[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 Implements gnBaseFilter. Definition at line 55 of file gnPosSpecificTranslator.cpp. References gnBaseFilter::Filter(), and filter.

gnSeqC gnPosSpecificTranslator::Filter | ( | const gnSeqC | ch | ) | const`[virtual]`

  | Filter the given character. Parameters:
  ch | The character to filter
Returns: The filtered character Implements gnBaseFilter. Definition at line 51 of file gnPosSpecificTranslator.cpp. References gnBaseFilter::Filter(), filter, and gnSeqC.

string gnBaseFilter::GetName | ( |  | ) | const`[inline, virtual, inherited]`

| Gets the name of this filter. Returns: the filter name Definition at line 65 of file gnBaseFilter.h. References gnBaseFilter::m_name.

gnPosSpecificTranslator& gnPosSpecificTranslator::operator= | ( | const gnPosSpecificTranslator & | sf | ) |

const gnPosSpecificTranslator * gnPosSpecificTranslator::ProteinDNATranslator | ( |  | ) | `[static]`

| Definition at line 18 of file gnPosSpecificTranslator.cpp. References gnPosSpecificTranslator().

void gnBaseFilter::SetName | ( | string | name | ) | `[inline, virtual, inherited]`

  | Sets the name of this filter. Parameters:
  name | the new filter name
Definition at line 70 of file gnBaseFilter.h. References gnBaseFilter::m_name. Referenced by gnFilter::CreateAlphabetCharacterFilter(), gnFilter::CreateBasicDNAFilter(), gnFilter::CreateBasicRNAFilter(), gnFilter::CreateDNAComplementFilter(), gnTranslator::CreateDNAProteinTranslator(), gnFilter::CreateDNAtoRNAFilter(), gnFilter::CreateFullDNAFilter(), gnFilter::CreateFullRNAFilter(), gnFilter::CreateNumberCharacterFilter(), gnTranslator::CreateProteinDNATranslator(), gnFilter::CreateProteinFilter(), gnTranslator::CreateProteinRNATranslator(), gnFilter::CreateRNAComplementFilter(), gnTranslator::CreateRNAProteinTranslator(), and gnFilter::CreateRNAtoDNAFilter().

## Member Data Documentation

const gnBaseFilter* gnPosSpecificTranslator::filter`[private]`

| Definition at line 60 of file gnPosSpecificTranslator.h. Referenced by Filter(), and gnPosSpecificTranslator().

string gnBaseFilter::m_name`[protected, inherited]`

| Definition at line 60 of file gnBaseFilter.h. Referenced by gnBaseFilter::GetName(), gnFastTranslator::gnFastTranslator(), gnFilter::gnFilter(), gnPosSpecificTranslator(), gnTranslator::gnTranslator(), and gnBaseFilter::SetName().

gnTranslatorType gnPosSpecificTranslator::m_type`[private]`

| Definition at line 59 of file gnPosSpecificTranslator.h. Referenced by gnPosSpecificTranslator().

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

- gnPosSpecificTranslator.h
- gnPosSpecificTranslator.cpp