LibreOffice LibreOffice 4.1 SDK C/C++ API Reference

- Main Page
- Related Pages
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | List of all members
com::sun::star::uno::ContextLayer Class Reference

Objects of this class are used for applying a current context until they are destructed, i.e. More...

`#include <current_context.hxx>`

## Public Member Functions
| ContextLayer (Reference< XCurrentContext > const &xNewContext=Reference< XCurrentContext >()) throw ()
| Constructor: Saves the previous context and sets the new (given) one. More...
| ~ContextLayer () throw ()
| Destructor: restores the previous context. More...
Reference< XCurrentContext > | getPreviousContext () const throw ()
| Gets the previously set context. More...

## Detailed Description

Objects of this class are used for applying a current context until they are destructed, i.e.

the ctor of this class saves the previous and sets the given context while the dtor restores the previous one upon destruction.

## Constructor & Destructor Documentation

com::sun::star::uno::ContextLayer::ContextLayer | ( | Reference< XCurrentContext > const & | xNewContext = `Reference< XCurrentContext >()` | ) |
throw | ( |
| ) |  |
| inline

Constructor: Saves the previous context and sets the new (given) one.

Parameters

  xNewContext | new context to be set

com::sun::star::uno::ContextLayer::~ContextLayer | ( |  | ) |
throw | ( |
| ) |  |
| inline

Destructor: restores the previous context.

## Member Function Documentation

Reference< XCurrentContext > com::sun::star::uno::ContextLayer::getPreviousContext | ( |  | ) | const
throw | ( |
| ) |  |
| inline

Gets the previously set context.

Returns
  the previously set context

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

- uno/current_context.hxx