casa  5.7.0-16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Static Public Member Functions | Private Attributes | List of all members
casa::PlotLogLocate Class Reference

Used to report located indices. More...

#include <PlotLogger.h>

Inheritance diagram for casa::PlotLogLocate:
casa::PlotLogMessage casacore::LogMessage

Public Member Functions

 PlotLogLocate (const casacore::String &origin1, const casacore::String &origin2, const PlotRegion &locateRegion, std::vector< std::vector< std::pair< unsigned int, unsigned int > > > *locatedIndices, int eventType=DEFAULT_EVENT_TYPE, bool deleteIndicesOnDestruction=true)
 Non-Static //. More...
 
 PlotLogLocate (const PlotLogLocate &copy)
 Copy constructor. More...
 
 ~PlotLogLocate ()
 Destructor. More...
 
const PlotRegionlocateRegion () const
 Returns the region that was located. More...
 
unsigned int numLocatedIndices () const
 Returns the total number of points that were located. More...
 
unsigned int numSearchedPlots () const
 Returns the number of plots that were searched. More...
 
std::vector< std::vector
< std::pair< unsigned int,
unsigned int > > > * 
indices () const
 Returns the located indices. More...
 
std::vector< std::pair
< unsigned int, unsigned int > > * 
plotIndices (unsigned int index) const
 Returns the located indices for the plot at the given index, or NULL for invalid. More...
 
bool willDeleteIndices () const
 Returns whether or not this message will delete the indices vector on destruction or not. More...
 
- Public Member Functions inherited from casa::PlotLogMessage
 PlotLogMessage (int eventType=DEFAULT_EVENT_TYPE)
 Non-Static //. More...
 
 PlotLogMessage (const casacore::String &origin1, const casacore::String &origin2, int eventType=DEFAULT_EVENT_TYPE)
 Constructor which takes the origin(s) and an optional priority. More...
 
 PlotLogMessage (const casacore::String &origin1, const casacore::String &origin2, const casacore::String &message, int eventType=DEFAULT_EVENT_TYPE)
 Constructor which takes the origin(s), the message, and an optional priority. More...
 
 PlotLogMessage (const PlotLogMessage &copy)
 Copy constructor. More...
 
virtual ~PlotLogMessage ()
 Destructor. More...
 
virtual int eventType () const
 Returns the event type of this message. More...
 
- Public Member Functions inherited from casacore::LogMessage
 LogMessage (Priority priority=NORMAL)
 Create a message with the given priority and the current time, and an empty origin and message. More...
 
 LogMessage (const LogOrigin &sourceLocation, Priority priority=NORMAL)
 Create a message with the given location and priority, the current time and an empty message. More...
 
 LogMessage (const String &message, const LogOrigin &sourceLocation, Priority=NORMAL)
 Create a completely filled out LogMessage. More...
 
 LogMessage (const LogMessage &other)
 Make this LogMessage a copy of other. More...
 
LogMessageoperator= (const LogMessage &other)
 
 ~LogMessage ()
 
const Stringmessage () const
 Get the message text. More...
 
LogMessagemessage (const String &message, Bool keepLastTime=False)
 Set the message text. More...
 
uInt line () const
 Get and set the line number in the LogOrigin. More...
 
LogMessageline (uInt which)
 
LogMessagesourceLocation (const SourceLocation *where)
 Set the source location - usually this will be called with the macro WHERE. More...
 
const LogOriginorigin () const
 Get and set the origin of this LogMessage. More...
 
LogMessageorigin (const LogOrigin &origin)
 
Priority priority () const
 Get or change the priority of this LogMessage. More...
 
LogMessagepriority (Priority which)
 
const TimemessageTime () const
 Returns the time at which the message text was created. More...
 
LogMessagemessageTime (const Time &theTime)
 Normally you should not manually set the time, however there may be rare circumstances where it is useful - for example if you have a single static message that you want to send out at various times. More...
 
String toString () const
 Turn this entire LogMessage into a String. More...
 
String toTermString () const
 

Static Public Member Functions

static PlotLogLocate canvasLocate (PlotCanvas *canvas, const PlotRegion &region)
 Static //. More...
 
- Static Public Member Functions inherited from casacore::LogMessage
static const StringtoString (Priority which)
 Map the given priority into a String - so, for example, it can be stored in a table. More...
 

Private Attributes

PlotRegion m_region
 Region. More...
 
std::vector< std::vector
< std::pair< unsigned int,
unsigned int > > > * 
m_indices
 Indices. More...
 
bool m_shouldDelete
 Should delete indices. More...
 

Additional Inherited Members

- Public Types inherited from casacore::LogMessage
enum  Priority {
  DEBUGGING,
  DEBUG2,
  DEBUG1,
  NORMAL5,
  NORMAL4,
  NORMAL3,
  NORMAL2,
  NORMAL1,
  NORMAL,
  WARN,
  SEVERE
}
 An "importance" which is assigned to each LogMessage. More...
 
- Static Public Attributes inherited from casa::PlotLogMessage
static const int DEFAULT_EVENT_TYPE
 Static //. More...
 
- Protected Attributes inherited from casa::PlotLogMessage
int m_eventType
 Event type, either a value from PlotLogger::Event, or a custom user-defined value. More...
 

Detailed Description

Used to report located indices.

Basically just a container for the results of a PlotCanvas::locate.

Definition at line 185 of file PlotLogger.h.

Constructor & Destructor Documentation

casa::PlotLogLocate::PlotLogLocate ( const casacore::String origin1,
const casacore::String origin2,
const PlotRegion locateRegion,
std::vector< std::vector< std::pair< unsigned int, unsigned int > > > *  locatedIndices,
int  eventType = DEFAULT_EVENT_TYPE,
bool  deleteIndicesOnDestruction = true 
)

Non-Static //.

Constructor which takes the two origins, the region that was located, and the located indices (see PlotCanvas::locate()). If deleteIndicesOnDestruction is true, the given indices vector will be deleted when this message is destroyed. This should be used with care if multiple PlotLogLocates using the same located indices are being used.

casa::PlotLogLocate::PlotLogLocate ( const PlotLogLocate copy)

Copy constructor.

NOTE: will set the deleteIndicesOnDestruction flag on the original to false so that the indices won't be deleted from out under the copy.

casa::PlotLogLocate::~PlotLogLocate ( )

Destructor.

Member Function Documentation

static PlotLogLocate casa::PlotLogLocate::canvasLocate ( PlotCanvas canvas,
const PlotRegion region 
)
static

Static //.

Convenience access to PlotCanvas::locate() to return a PlotLogLocate message.

std::vector<std::vector<std::pair<unsigned int, unsigned int> > >* casa::PlotLogLocate::indices ( ) const

Returns the located indices.

const PlotRegion& casa::PlotLogLocate::locateRegion ( ) const

Returns the region that was located.

unsigned int casa::PlotLogLocate::numLocatedIndices ( ) const

Returns the total number of points that were located.

unsigned int casa::PlotLogLocate::numSearchedPlots ( ) const

Returns the number of plots that were searched.

std::vector<std::pair<unsigned int, unsigned int> >* casa::PlotLogLocate::plotIndices ( unsigned int  index) const

Returns the located indices for the plot at the given index, or NULL for invalid.

bool casa::PlotLogLocate::willDeleteIndices ( ) const

Returns whether or not this message will delete the indices vector on destruction or not.

Member Data Documentation

std::vector<std::vector<std::pair<unsigned int, unsigned int> > >* casa::PlotLogLocate::m_indices
private

Indices.

Definition at line 244 of file PlotLogger.h.

PlotRegion casa::PlotLogLocate::m_region
private

Region.

Definition at line 241 of file PlotLogger.h.

bool casa::PlotLogLocate::m_shouldDelete
private

Should delete indices.

Definition at line 247 of file PlotLogger.h.


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