libmapipp::object Class Reference

Base Object class. More...

#include <object.h>

Inheritance diagram for libmapipp::object:
libmapipp::attachment libmapipp::folder libmapipp::message libmapipp::message_store

Public Member Functions

virtual mapi_object_t & data () throw ()
 Obtain a reference to the mapi_object_t associated with this object. More...
 
virtual property_container get_property_container ()
 Obtain a property_container to be used with this object. More...
 
virtual sessionget_session ()
 Obtain the session associated with this object. More...
 
 object (session &mapi_session, const std::string &object_type="") throw ()
 Object Constructor. More...
 
virtual ~object () throw ()
 Destructor. More...
 

Protected Attributes

mapi_object_t m_object
 
sessionm_session
 

Detailed Description

Base Object class.

Most classes such as folder, message and message_store derive from this class. It is important that objects be passed around as references and that no unnecessary copies are made as this will call the class destructor which will call mapi_object_release() and release the handle associated with this object.

Constructor & Destructor Documentation

libmapipp::object::object ( session mapi_session,
const std::string &  object_type = "" 
)
throw (
)
inlineexplicit

Object Constructor.

Parameters
mapi_sessionSession this object is to be associated with.
object_typeThe name of the type of object (to be set in a subclass)

References m_object.

virtual libmapipp::object::~object ( )
throw (
)
inlinevirtual

Destructor.

Calls mapi_object_release() which releases the handle associated with this object.

References m_object.

Member Function Documentation

virtual mapi_object_t& libmapipp::object::data ( )
throw (
)
inlinevirtual

Obtain a reference to the mapi_object_t associated with this object.

Returns
A reference to the C struct mapi_object_t associated with this object

References m_object.

virtual property_container libmapipp::object::get_property_container ( )
virtual

Obtain a property_container to be used with this object.

Returns
A property_container to be used with this object.
Examples:
attach_test.cpp, foldertree.cpp, and test.cpp.
virtual session& libmapipp::object::get_session ( )
inlinevirtual

Obtain the session associated with this object.

Returns
The session associated with this object

References m_session.

Member Data Documentation

session& libmapipp::object::m_session
protected

Referenced by get_session().


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

Creative Commons License
Creative Commons Attribution icon Creative Commons Share Alike icon
This content is licensed under the Creative Commons
Attribution ShareAlike License v. 3.0:
http://creativecommons.org/licenses/by-sa/3.0/