SHIM Class Reference

`#include <shim.h>`

Inheritance diagram for SHIM:
[legend]

## Public Types

typedef std::map< std::string, std::string > | HeaderList

## Public Member Functions

| SHIM (const HeaderList &hl)
| SHIM (const Tag *tag=0)
const HeaderList & | headers () const
virtual | ~SHIM ()
virtual const std::string & | filterString () const
virtual StanzaExtension * | newInstance (const Tag *tag) const
virtual Tag * | tag () const
virtual StanzaExtension * | clone () const
Public Member Functions inherited from StanzaExtension
| StanzaExtension (int type)
virtual | ~StanzaExtension ()
virtual Stanza * | embeddedStanza () const
virtual Tag * | embeddedTag () const
int | extensionType () const

## Detailed Description

An implementation/abstraction of Stanza Headers and Internet Metadata (SHIM, XEP-0131).

XEP Version: 1.2

Author
  Jakob Schröter js@ca.nosp@m.maya.nosp@m..net

Since
  1.0

Definition at line 35 of file shim.h.

## Member Typedef Documentation

## HeaderList

typedef std::map<std::string, std::string> HeaderList

A list of SHIM headers (name & value).

Definition at line 41 of file shim.h.

## Constructor & Destructor Documentation

## SHIM() [1/2]

SHIM | ( | const HeaderList & | hl | ) |

Creates a new SHIM object containing the given headers.

Parameters

  hl | The list of headers.

Definition at line 19 of file shim.cpp.

## SHIM() [2/2]

SHIM | ( | const Tag * | tag = 0 | ) |

Creates a new SHIM object from the given Tag.

Parameters

  tag | The Tag to parse.

Definition at line 24 of file shim.cpp.

## ~SHIM()

~SHIM | ( |  | ) |

virtual

Virtual destructor.

Definition at line 41 of file shim.cpp.

## Member Function Documentation

## clone()

virtual StanzaExtension * clone | ( |  | ) | const

inline virtual

Returns an identical copy of the current StanzaExtension.

Returns
  An identical copy of the current StanzaExtension.

Implements StanzaExtension.

Definition at line 79 of file shim.h.

## filterString()

const std::string & filterString | ( |  | ) | const

virtual

Returns an XPath expression that describes a path to child elements of a stanza that an extension handles.

Returns
  The extension's filter string.

Implements StanzaExtension.

Definition at line 45 of file shim.cpp.

## headers()

const HeaderList & headers | ( |  | ) | const

inline

Returns the headers.

Returns
  The headers.

Definition at line 59 of file shim.h.

## newInstance()

virtual StanzaExtension * newInstance | ( | const Tag * | tag | ) | const

inline virtual

Returns a new Instance of the derived type. Usually, for a derived class FooExtension, the implementation of this function looks like:

StanzaExtension* FooExtension::newInstance( const Tag* tag ) const
{
return new FooExtension( tag );
}
gloox::SHIM::tag
virtual Tag * tag() const
Definition shim.cpp:53
gloox::StanzaExtension::StanzaExtension
StanzaExtension(int type)
Definition stanzaextension.h:211
gloox::Tag
This is an abstraction of an XML element.
Definition tag.h:47

Returns
  The derived extension's new instance.

Implements StanzaExtension.

Definition at line 70 of file shim.h.

## tag()

Tag * tag | ( |  | ) | const

virtual

Returns a Tag representation of the extension.

Returns
  A Tag representation of the extension.

Implements StanzaExtension.

Definition at line 53 of file shim.cpp.

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

- shim.h
- shim.cpp