NCBI C++ ToolKit
Public Types | Public Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
Messenger Class Reference

Search Toolkit Book for Messenger

#include "messenger.hpp"
(Private to src/app/cn3d.)

+ Collaboration diagram for Messenger:

Public Types

typedef std::map< const MoleculeIdentifier *, std::vector< bool > > MoleculeHighlightMap

Public Member Functions

void PostRedrawSequenceViewer (ViewerBase *viewer)
void PostRedrawAllSequenceViewers (void)
void PostRedrawMolecule (const Molecule *molecule)
void PostRedrawAllStructures (void)
void UnPostRedrawAllSequenceViewers (void)
void UnPostRedrawSequenceViewer (ViewerBase *viewer)
void UnPostStructureRedraws (void)
void ProcessRedraws (void)
void SequenceWindowsSave (bool prompt)
void NewSequenceViewerFont (void)
bool IsHighlighted (const Molecule *molecule, int residueID) const
bool IsHighlighted (const Sequence *sequence, unsigned int seqIndex) const
bool IsHighlightedAnywhere (const MoleculeIdentifier *identifier) const
bool IsHighlightedAnywhere (const Molecule *molecule) const
bool RemoveAllHighlights (bool postRedraws)
void AddHighlights (const Sequence *sequence, unsigned int seqIndexFrom, unsigned int seqIndexTo)
void RemoveHighlights (const Sequence *sequence, unsigned int seqIndexFrom, unsigned int seqIndexTo)
void ToggleHighlights (const Sequence *sequence, unsigned int seqIndexFrom, unsigned int seqIndexTo)
void AddHighlights (const Molecule *molecule, int residueIDFrom, int residueIDTo, bool scrollViewersTo=false)
void ToggleHighlight (const Molecule *molecule, int residueID, bool scrollViewersTo=false)
void GetHighlights (MoleculeHighlightMap *copyHighlights)
void SetHighlights (const MoleculeHighlightMap &newHighlights)
void HighlightAndShowSequence (const Sequence *sequence)
void KeepHighlightsOnlyOnSequence (const Sequence *sequence)
void SuspendHighlighting (bool suspend)
void CacheHighlights (void)
void RestoreCachedHighlights (void)
 Messenger (void)
bool IsAnythingHighlighted (void) const
bool GetHighlightedResiduesWithStructure (MoleculeHighlightMap *residues) const
ncbi::objects::CBiostruc_annot_set * CreateBiostrucAnnotSetForHighlightsOnSingleObject (void) const
bool GetHighlightsForSelectionMessage (std::string *data) const
void AddSequenceViewer (ViewerBase *sequenceViewer)
void AddStructureWindow (StructureWindow *window)
void RemoveStructureWindow (const StructureWindow *structureWindow)
void RemoveSequenceViewer (const ViewerBase *sequenceViewer)
void SetAllWindowTitles (void) const
bool IsFileMessengerActive (void) const
void FileMessengerSend (const std::string &toApp, const std::string &command, const std::string &data)

Private Types

typedef std::list< ViewerBase * > SequenceViewerList
typedef std::map< const Molecule *, boolRedrawMoleculeList
typedef std::map< ViewerBase *, boolRedrawSequenceViewerList

Private Member Functions

bool IsHighlighted (const MoleculeIdentifier *identifier, int index) const
void ToggleHighlights (const MoleculeIdentifier *identifier, unsigned int indexFrom, unsigned int indexTo, const StructureSet *set)
void RedrawMoleculesWithIdentifier (const MoleculeIdentifier *identifier, const StructureSet *set)

Private Attributes

SequenceViewerList sequenceViewers
RedrawMoleculeList redrawMolecules
RedrawSequenceViewerList redrawSequenceViewers
bool redrawAllStructures
bool redrawAllSequenceViewers
bool highlightingSuspended
MoleculeHighlightMap highlights
MoleculeHighlightMap highlightCache

Detailed Description

Definition at line 64 of file messenger.hpp.

Member Typedef Documentation

◆ MoleculeHighlightMap

typedef std::map< const MoleculeIdentifier *, std::vector < bool > > Messenger::MoleculeHighlightMap

Definition at line 99 of file messenger.hpp.

◆ RedrawMoleculeList

typedef std::map< const Molecule *, bool > Messenger::RedrawMoleculeList

Definition at line 148 of file messenger.hpp.

◆ RedrawSequenceViewerList

typedef std::map< ViewerBase *, bool > Messenger::RedrawSequenceViewerList

Definition at line 150 of file messenger.hpp.

◆ SequenceViewerList

typedef std::list< ViewerBase * > Messenger::SequenceViewerList

Definition at line 142 of file messenger.hpp.

Constructor & Destructor Documentation

◆ Messenger()

Messenger::Messenger ( void  )

Definition at line 166 of file messenger.hpp.

Member Function Documentation

◆ AddHighlights() [1/2]

void Messenger::AddHighlights ( const Molecule molecule,
int  residueIDFrom,
int  residueIDTo,
bool  scrollViewersTo = false 

◆ AddHighlights() [2/2]

void Messenger::AddHighlights ( const Sequence sequence,
unsigned int  seqIndexFrom,
unsigned int  seqIndexTo 

◆ AddSequenceViewer()

void Messenger::AddSequenceViewer ( ViewerBase sequenceViewer)

Definition at line 182 of file messenger.hpp.

References sequenceViewers.

Referenced by AlignmentManager::Init().

◆ AddStructureWindow()

void Messenger::AddStructureWindow ( StructureWindow window)

Definition at line 185 of file messenger.hpp.

References structureWindow.

Referenced by StructureWindow::StructureWindow().

◆ CacheHighlights()

void Messenger::CacheHighlights ( void  )

◆ CreateBiostrucAnnotSetForHighlightsOnSingleObject()

CBiostruc_annot_set * Messenger::CreateBiostrucAnnotSetForHighlightsOnSingleObject ( void  ) const

◆ FileMessengerSend()

void Messenger::FileMessengerSend ( const std::string toApp,
const std::string command,
const std::string data 

Definition at line 599 of file messenger.cpp.

References command, data, StructureWindow::SendCommand(), and structureWindow.

◆ GetHighlightedResiduesWithStructure()

bool Messenger::GetHighlightedResiduesWithStructure ( MoleculeHighlightMap residues) const

Definition at line 453 of file messenger.cpp.

References highlights, and IsAnythingHighlighted().

Referenced by AnnotateDialog::AnnotateDialog().

◆ GetHighlights()

void Messenger::GetHighlights ( MoleculeHighlightMap copyHighlights)

◆ GetHighlightsForSelectionMessage()

bool Messenger::GetHighlightsForSelectionMessage ( std::string data) const

◆ HighlightAndShowSequence()

void Messenger::HighlightAndShowSequence ( const Sequence sequence)

◆ IsAnythingHighlighted()

bool Messenger::IsAnythingHighlighted ( void  ) const

◆ IsFileMessengerActive()

bool Messenger::IsFileMessengerActive ( void  ) const

Definition at line 594 of file messenger.cpp.

References StructureWindow::IsFileMessengerActive(), and structureWindow.

◆ IsHighlighted() [1/3]

bool Messenger::IsHighlighted ( const Molecule molecule,
int  residueID 
) const

◆ IsHighlighted() [2/3]

bool Messenger::IsHighlighted ( const MoleculeIdentifier identifier,
int  index 
) const

Definition at line 200 of file messenger.cpp.

References ERRORMSG, highlightingSuspended, and highlights.

◆ IsHighlighted() [3/3]

bool Messenger::IsHighlighted ( const Sequence sequence,
unsigned int  seqIndex 
) const

Definition at line 221 of file messenger.cpp.

References Sequence::identifier, and IsHighlighted().

◆ IsHighlightedAnywhere() [1/2]

bool Messenger::IsHighlightedAnywhere ( const Molecule molecule) const

Definition at line 231 of file messenger.cpp.

References Molecule::identifier, and IsHighlighted().

◆ IsHighlightedAnywhere() [2/2]

bool Messenger::IsHighlightedAnywhere ( const MoleculeIdentifier identifier) const

Definition at line 226 of file messenger.cpp.

References IsHighlighted().

◆ KeepHighlightsOnlyOnSequence()

void Messenger::KeepHighlightsOnlyOnSequence ( const Sequence sequence)

◆ NewSequenceViewerFont()

void Messenger::NewSequenceViewerFont ( void  )

Definition at line 190 of file messenger.cpp.

References sequenceViewers.

Referenced by StructureWindow::OnSetFont().

◆ PostRedrawAllSequenceViewers()

void Messenger::PostRedrawAllSequenceViewers ( void  )

◆ PostRedrawAllStructures()

void Messenger::PostRedrawAllStructures ( void  )

◆ PostRedrawMolecule()

void Messenger::PostRedrawMolecule ( const Molecule molecule)

◆ PostRedrawSequenceViewer()

void Messenger::PostRedrawSequenceViewer ( ViewerBase viewer)

◆ ProcessRedraws()

void Messenger::ProcessRedraws ( void  )

◆ RedrawMoleculesWithIdentifier()

void Messenger::RedrawMoleculesWithIdentifier ( const MoleculeIdentifier identifier,
const StructureSet set 

◆ RemoveAllHighlights()

bool Messenger::RemoveAllHighlights ( bool  postRedraws)

◆ RemoveHighlights()

void Messenger::RemoveHighlights ( const Sequence sequence,
unsigned int  seqIndexFrom,
unsigned int  seqIndexTo 

◆ RemoveSequenceViewer()

void Messenger::RemoveSequenceViewer ( const ViewerBase sequenceViewer)

Definition at line 174 of file messenger.cpp.

References sequenceViewers, and t.

Referenced by AlignmentManager::~AlignmentManager().

◆ RemoveStructureWindow()

void Messenger::RemoveStructureWindow ( const StructureWindow structureWindow)

Definition at line 167 of file messenger.cpp.

References ERRORMSG, NULL, and structureWindow.

Referenced by StructureWindow::OnExit().

◆ RestoreCachedHighlights()

void Messenger::RestoreCachedHighlights ( void  )

◆ SequenceWindowsSave()

void Messenger::SequenceWindowsSave ( bool  prompt)

◆ SetAllWindowTitles()

void Messenger::SetAllWindowTitles ( void  ) const

◆ SetHighlights()

void Messenger::SetHighlights ( const MoleculeHighlightMap newHighlights)

◆ SuspendHighlighting()

void Messenger::SuspendHighlighting ( bool  suspend)

◆ ToggleHighlight()

void Messenger::ToggleHighlight ( const Molecule molecule,
int  residueID,
bool  scrollViewersTo = false 

◆ ToggleHighlights() [1/2]

void Messenger::ToggleHighlights ( const MoleculeIdentifier identifier,
unsigned int  indexFrom,
unsigned int  indexTo,
const StructureSet set 

◆ ToggleHighlights() [2/2]

void Messenger::ToggleHighlights ( const Sequence sequence,
unsigned int  seqIndexFrom,
unsigned int  seqIndexTo 

◆ UnPostRedrawAllSequenceViewers()

void Messenger::UnPostRedrawAllSequenceViewers ( void  )

Definition at line 100 of file messenger.cpp.

References redrawAllSequenceViewers, and redrawSequenceViewers.

◆ UnPostRedrawSequenceViewer()

void Messenger::UnPostRedrawSequenceViewer ( ViewerBase viewer)

◆ UnPostStructureRedraws()

void Messenger::UnPostStructureRedraws ( void  )

Definition at line 117 of file messenger.cpp.

References redrawAllStructures, and redrawMolecules.

Referenced by OpenGLRenderer::Construct().

Member Data Documentation

◆ highlightCache

MoleculeHighlightMap Messenger::highlightCache

Definition at line 157 of file messenger.hpp.

Referenced by CacheHighlights(), and RestoreCachedHighlights().

◆ highlightingSuspended

bool Messenger::highlightingSuspended

Definition at line 154 of file messenger.hpp.

Referenced by IsHighlighted(), and SuspendHighlighting().

◆ highlights

MoleculeHighlightMap Messenger::highlights

◆ redrawAllSequenceViewers

bool Messenger::redrawAllSequenceViewers

◆ redrawAllStructures

bool Messenger::redrawAllStructures

◆ redrawMolecules

RedrawMoleculeList Messenger::redrawMolecules

◆ redrawSequenceViewers

RedrawSequenceViewerList Messenger::redrawSequenceViewers

◆ sequenceViewers

SequenceViewerList Messenger::sequenceViewers

◆ structureWindow

StructureWindow* Messenger::structureWindow

The documentation for this class was generated from the following files:
Modified on Wed Jul 17 13:19:09 2024 by rev. 669887