LibreOffice Module desktop (master) 1
Public Member Functions | Private Attributes | List of all members
desktop::CallbackFlushHandler::CallbackData Struct Reference

Public Member Functions

 CallbackData (const char *payload)
 
 CallbackData (const char *payload, int viewId)
 
 CallbackData (const tools::Rectangle *pRect, int viewId)
 
const std::string & getPayload () const
 
void updateRectangleAndPart (const RectangleAndPart &rRectAndPart)
 Update a RectangleAndPart object and update PayloadString if necessary. More...
 
const RectangleAndPartgetRectangleAndPart () const
 Return the parsed RectangleAndPart instance. More...
 
boost::property_tree::ptree & setJson (const std::string &payload)
 Parse and set the JSON object and return it. Clobbers PayloadString. More...
 
void setJson (const boost::property_tree::ptree &rTree)
 Set a Json object and update PayloadString. More...
 
const boost::property_tree::ptree & getJson () const
 Return the parsed JSON instance. More...
 
int getViewId () const
 
bool isEmpty () const
 
void clear ()
 
bool validate () const
 Validate that the payload and parsed object match. More...
 
bool isCached () const
 Returns true iff there is cached data. More...
 

Private Attributes

std::string PayloadString
 
boost::variant< boost::blank, RectangleAndPart, boost::property_tree::ptree, intPayloadObject
 The parsed payload cache. Update validate() when changing this. More...
 

Detailed Description

Definition at line 122 of file init.hxx.

Constructor & Destructor Documentation

◆ CallbackData() [1/3]

desktop::CallbackFlushHandler::CallbackData::CallbackData ( const char *  payload)
inline

Definition at line 124 of file init.hxx.

◆ CallbackData() [2/3]

desktop::CallbackFlushHandler::CallbackData::CallbackData ( const char *  payload,
int  viewId 
)
inline

Definition at line 129 of file init.hxx.

◆ CallbackData() [3/3]

desktop::CallbackFlushHandler::CallbackData::CallbackData ( const tools::Rectangle pRect,
int  viewId 
)
inline

Definition at line 135 of file init.hxx.

Member Function Documentation

◆ clear()

void desktop::CallbackFlushHandler::CallbackData::clear ( )
inline

Definition at line 158 of file init.hxx.

◆ getJson()

const boost::property_tree::ptree & desktop::CallbackFlushHandler::CallbackData::getJson ( ) const

Return the parsed JSON instance.

Definition at line 539 of file init.cxx.

Referenced by desktop::CallbackFlushHandler::processWindowEvent().

◆ getPayload()

const std::string & desktop::CallbackFlushHandler::CallbackData::getPayload ( ) const

◆ getRectangleAndPart()

const RectangleAndPart & desktop::CallbackFlushHandler::CallbackData::getRectangleAndPart ( ) const

Return the parsed RectangleAndPart instance.

Definition at line 507 of file init.cxx.

References desktop::RectangleAndPart::Create().

Referenced by getPayload(), and desktop::CallbackFlushHandler::processInvalidateTilesEvent().

◆ getViewId()

int desktop::CallbackFlushHandler::CallbackData::getViewId ( ) const

Definition at line 545 of file init.cxx.

References lcl_getViewId().

Referenced by desktop::CallbackFlushHandler::queue().

◆ isCached()

bool desktop::CallbackFlushHandler::CallbackData::isCached ( ) const
inline

Returns true iff there is cached data.

Definition at line 168 of file init.hxx.

◆ isEmpty()

bool desktop::CallbackFlushHandler::CallbackData::isEmpty ( ) const
inline

Definition at line 154 of file init.hxx.

Referenced by desktop::CallbackFlushHandler::queue().

◆ setJson() [1/2]

void desktop::CallbackFlushHandler::CallbackData::setJson ( const boost::property_tree::ptree &  rTree)

Set a Json object and update PayloadString.

Definition at line 529 of file init.cxx.

◆ setJson() [2/2]

boost::property_tree::ptree & desktop::CallbackFlushHandler::CallbackData::setJson ( const std::string &  payload)

Parse and set the JSON object and return it. Clobbers PayloadString.

Definition at line 516 of file init.cxx.

Referenced by desktop::CallbackFlushHandler::processWindowEvent().

◆ updateRectangleAndPart()

void desktop::CallbackFlushHandler::CallbackData::updateRectangleAndPart ( const RectangleAndPart rRectAndPart)

Update a RectangleAndPart object and update PayloadString if necessary.

Definition at line 501 of file init.cxx.

◆ validate()

bool desktop::CallbackFlushHandler::CallbackData::validate ( ) const

Validate that the payload and parsed object match.

Definition at line 555 of file init.cxx.

References lcl_getViewId().

Referenced by desktop::CallbackFlushHandler::processWindowEvent(), and desktop::CallbackFlushHandler::queue().

Member Data Documentation

◆ PayloadObject

boost::variant<boost::blank, RectangleAndPart, boost::property_tree::ptree, int> desktop::CallbackFlushHandler::CallbackData::PayloadObject
mutableprivate

The parsed payload cache. Update validate() when changing this.

Definition at line 174 of file init.hxx.

Referenced by getPayload().

◆ PayloadString

std::string desktop::CallbackFlushHandler::CallbackData::PayloadString
mutableprivate

Definition at line 171 of file init.hxx.

Referenced by getPayload().


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