signon 8.54

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

- Class List
- Class Hierarchy
- Class Members

Public Slots | Public Member Functions | Static Public Member Functions | Protected Member Functions | List of all members
SignonDaemonNS::SignonDisposable Class Reference

Base class for server objects that can be automatically destroyed after a certain period of inactivity. More...

`#include <signondisposable.h>`

Inheritance diagram for SignonDaemonNS::SignonDisposable:
[legend]
Collaboration diagram for SignonDaemonNS::SignonDisposable:
[legend]

## Public Slots
static void | destroyUnused ()
| Deletes all disposable object for which the inactivity time has elapsed. More...

## Public Member Functions
| SignonDisposable (int maxInactivity, QObject *parent)
| Construct an object that can be automatically destroyed after having being unused for seconds. More...
virtual void | destroy ()
| Performs any predestruction operations and the destruction itself. More...
void | keepInUse () const
| Mark the object as used. More...
void | setAutoDestruct (bool value=true) const
| Mark the object as used. More...

## Static Public Member Functions
static void | invokeOnIdle (int maxInactivity, QObject *object, const char *member)
| Invoke the specified method on when there are no disposable objects for more than seconds. More...

## Protected Member Functions
virtual | ~SignonDisposable ()

## Detailed Description

Base class for server objects that can be automatically destroyed after a certain period of inactivity.

Definition at line 39 of file signondisposable.h.

## Constructor & Destructor Documentation

SignonDaemonNS::SignonDisposable::~SignonDisposable | ( |  | ) |
| protected virtual

Definition at line 52 of file signondisposable.cpp.

SignonDaemonNS::SignonDisposable::SignonDisposable | ( | int | maxInactivity,
|  | QObject * | parent
| ) |  |

Construct an object that can be automatically destroyed after having being unused for seconds.

Parameters

  maxInactivity | the number of seconds of inactivity.
  parent | the parent object.

Definition at line 33 of file signondisposable.cpp.

References destroyUnused(), and keepInUse().

## Member Function Documentation

virtual void SignonDaemonNS::SignonDisposable::destroy | ( |  | ) |
| inline virtual

Performs any predestruction operations and the destruction itself.

Reimplement this for smoother control.

Reimplemented in SignonDaemonNS::SignonSessionCore, and SignonDaemonNS::SignonIdentity.

Definition at line 60 of file signondisposable.h.

Referenced by destroyUnused().

void SignonDaemonNS::SignonDisposable::destroyUnused | ( |  | ) |
| static slot

Deletes all disposable object for which the inactivity time has elapsed.

Definition at line 109 of file signondisposable.cpp.

References destroy(), and TRACE.

Referenced by SignonDaemonNS::SignonSessionCore::childEvent(), SignonDaemonNS::SignonDaemonAdaptor::getAuthSessionObjectPath(), SignonDaemonNS::SignonDaemonAdaptor::getIdentity(), invokeOnIdle(), SignonDaemonNS::SignonDaemonAdaptor::registerNewIdentity(), and SignonDisposable().

void SignonDaemonNS::SignonDisposable::invokeOnIdle | ( | int | maxInactivity,
|  | QObject * | object,
|  | const char * | member
| ) |  |
| static

Invoke the specified method on when there are no disposable objects for more than seconds.

To keep the implementation simpler, this function can be called only once, and the variable must still be accessible when the method will be invoked (use a static string).

Definition at line 81 of file signondisposable.cpp.

References destroyUnused().

void SignonDaemonNS::SignonDisposable::keepInUse | ( |  | ) | const

Mark the object as used.

Calling this method causes the inactivity timer to be reset.

Definition at line 57 of file signondisposable.cpp.

Referenced by SignonDaemonNS::SignonIdentity::addReference(), SignonDaemonNS::SignonSessionCore::childEvent(), SignonDaemonNS::SignonSessionCore::destroy(), SignonDaemonNS::SignonDaemon::getIdentity(), SignonDaemonNS::SignonIdentity::getInfo(), SignonDaemonNS::SignonSessionCore::id(), SignonDaemonNS::SignonSessionCore::method(), SignonDaemonNS::SignonSessionCore::process(), SignonDaemonNS::SignonSessionCore::queryAvailableMechanisms(), SignonDaemonNS::SignonIdentity::remove(), SignonDaemonNS::SignonIdentity::removeReference(), setAutoDestruct(), SignonDaemonNS::SignonSessionCore::setId(), SignonDisposable(), SignonDaemonNS::SignonIdentity::signOut(), SignonDaemonNS::SignonIdentity::store(), and SignonDaemonNS::SignonIdentity::verifySecret().

void SignonDaemonNS::SignonDisposable::setAutoDestruct | ( | bool | value = `true` | ) | const

Mark the object as used.

Calling this method enables/disables autodestruction.

Parameters

  value | enable/disable autodestruction

Definition at line 75 of file signondisposable.cpp.

References keepInUse().

Referenced by SignonDaemonNS::SignonIdentity::queryUiSlot(), SignonDaemonNS::SignonIdentity::remove(), SignonDaemonNS::SignonIdentity::requestCredentialsUpdate(), SignonDaemonNS::SignonIdentity::signOut(), and SignonDaemonNS::SignonIdentity::verifyUiSlot().

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

- src/signond/signondisposable.h
- src/signond/signondisposable.cpp