Class Poco::Util::OptionCallback
Author: Applied Informatics Software Engineering GmbH and Contributors

# Poco::Util

# template < class C >

# class OptionCallback

Library: Util
Package: Options
Header: Poco/Util/OptionCallback.h

## Description

This class is used as an argument to Option::callback().

It stores a pointer to an object and a pointer to a member function of the object's class.

## Inheritance

Direct Base Classes: AbstractOptionCallback

All Base Classes: AbstractOptionCallback

## Member Summary

Member Functions: clone, invoke, operator =

Inherited Functions: clone, invoke

## Types

### void

typedef void (C::* Callback)(const std::string & name, const std::string & value);

## Constructors

### OptionCallback

OptionCallback(
const OptionCallback & cb
);

Creates an OptionCallback from another one.

### OptionCallback

OptionCallback(
C * pObject,
Callback method
);

Creates the OptionCallback for the given object and member function.

## Destructor

### ~OptionCallback

~OptionCallback();

Destroys the OptionCallback.

## Member Functions

### clone

AbstractOptionCallback * clone() const;

See also: Poco::Util::AbstractOptionCallback::clone()

### invoke

void invoke(
const std::string & name,
const std::string & value
) const;

See also: Poco::Util::AbstractOptionCallback::invoke()

### operator =

OptionCallback & operator = (
const OptionCallback & cb
);