PresageCallback Class Reference

#include <presageCallback.h>

Inheritance diagram for PresageCallback:
Inheritance graph
[legend]

List of all members.

Public Member Functions

virtual ~PresageCallback ()
virtual std::string get_past_stream () const =0
virtual std::string get_future_stream () const =0

Protected Member Functions

 PresageCallback ()

Detailed Description

Abstract callback object used to retrieve context from user application.

A concrete callback implementation must implement the getPastStream() and getFutureStream() method which are responsible for retrieving the context from the user text buffer.

Using a callback object decouples the user application from the chosen text buffer (which could be a simple string, a graphical text widget, a file stream, etc.) and frees the caller from having to explicitly notify of any updates to the context. Presage will invoke on the callback whenever access to contextual data is required.

getPastStream() must return a string containing the text preceding the current insertion point.

getFutureStream() must return a string containing the text following the current insertion point.

Definition at line 66 of file presageCallback.h.


Constructor & Destructor Documentation

virtual PresageCallback::~PresageCallback (  )  [inline, virtual]

Definition at line 68 of file presageCallback.h.

PresageCallback::PresageCallback (  )  [inline, protected]

Definition at line 74 of file presageCallback.h.


Member Function Documentation

virtual std::string PresageCallback::get_future_stream (  )  const [pure virtual]

Implemented in CPresageCallback, LegacyPresageCallback, PresageDemoCallback, and SimulatorPresageCallback.

Referenced by ContextTracker::getFutureStream(), and ContextTracker::toString().

Here is the caller graph for this function:

virtual std::string PresageCallback::get_past_stream (  )  const [pure virtual]

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

Generated on 9 Feb 2015 for presage by  doxygen 1.6.1