IntaRNA 3.4.1
RNA-RNA interaction prediction | C++ API
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Friends | List of all members
IntaRNA::InteractionRange Class Reference

#include <InteractionRange.h>

Collaboration diagram for IntaRNA::InteractionRange:
Collaboration graph
[legend]

Public Member Functions

 InteractionRange (const RnaSequence &rna1, const RnaSequence &rna2, const IndexRange &r1=IndexRange(0, RnaSequence::lastPos), const IndexRange &r2=IndexRange(RnaSequence::lastPos, 0), const E_type energy=E_INF)
 
 InteractionRange (const Interaction &interaction)
 
virtual ~InteractionRange ()
 
bool isSane () const
 
const bool operator< (const InteractionRange &r) const
 
InteractionRange & operator= (const Interaction &interaction)
 

Public Attributes

const RnaSequence * s1
 the first interaction partner
 
const RnaSequence * s2
 the second interaction partner
 
IndexRange r1
 the index range of s1 interacting with r2
 
IndexRange r2
 the index range of s2 interacting with r1
 
E_type energy
 the energy value associated with this interaction range
 

Friends

std::ostream & operator<< (std::ostream &out, const InteractionRange &r)
 

Detailed Description

Represents two ranges that form an interaction

Constructor & Destructor Documentation

◆ InteractionRange() [1/2]

IntaRNA::InteractionRange::InteractionRange ( const RnaSequence &  rna1,
const RnaSequence &  rna2,
const IndexRange &  r1 = IndexRange(0,RnaSequence::lastPos),
const IndexRange &  r2 = IndexRange(RnaSequence::lastPos,0),
const E_type  energy = E_INF 
)
inline

Construction of an interaction range given two index ranges

Parameters
rna1the first RNA interacting
rna2the second RNA interacting
r1the range of rna1 interacting
r2the range of rna2 interacting
energythe energy value assigned to the range

◆ InteractionRange() [2/2]

IntaRNA::InteractionRange::InteractionRange ( const Interaction &  interaction)
inline

Construction of an interaction range given two index ranges

◆ ~InteractionRange()

virtual IntaRNA::InteractionRange::~InteractionRange ( )
inlinevirtual

Destruction

Member Function Documentation

◆ isSane()

bool IntaRNA::InteractionRange::isSane ( ) const
inline

Checks whether or not the range encoding is reasonable.

Returns
from <= to

◆ operator<()

const bool IntaRNA::InteractionRange::operator< ( const InteractionRange &  r) const
inline

Defines a less-than order on interaction ranges.

Parameters
rthe range to compare to
Returns
(r1 < r.r1) || (!(r1>r.r1) && r2<r.r2)

◆ operator=()

InteractionRange & IntaRNA::InteractionRange::operator= ( const Interaction &  interaction)

Copies the range of the given interaction into this.

Parameters
interactionthe interaction to get the range from
Returns
the altered range object (*this)

Friends And Related Symbol Documentation

◆ operator<<

std::ostream & operator<< ( std::ostream &  out,
const InteractionRange &  r 
)
friend

Prints the range's boundaries to stream

Parameters
outthe ostream to write to
rthe InteractionRange object to add
Returns
the altered stream out

Member Data Documentation

◆ energy

E_type IntaRNA::InteractionRange::energy

the energy value associated with this interaction range

◆ r1

IndexRange IntaRNA::InteractionRange::r1

the index range of s1 interacting with r2

◆ r2

IndexRange IntaRNA::InteractionRange::r2

the index range of s2 interacting with r1

◆ s1

const RnaSequence* IntaRNA::InteractionRange::s1

the first interaction partner

◆ s2

const RnaSequence* IntaRNA::InteractionRange::s2

the second interaction partner


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