Liblinphone  5.4.0
Public Member Functions | List of all members
linphone::Dictionary Class Reference

Object that represents key-value pair container. More...

#include <dictionary.hh>

Inheritance diagram for linphone::Dictionary:

Public Member Functions

LINPHONECXX_PUBLIC Dictionary (void *ptr, bool takeRef=true)
 
LINPHONECXX_PUBLIC _LinphoneDictionary * cPtr ()
 
LINPHONECXX_PUBLIC std::list< std::string > getKeys () const
 Returns the list of keys present in the dictionary. More...
 
LINPHONECXX_PUBLIC void clear ()
 Clears the dictionary.
 
LINPHONECXX_PUBLIC std::shared_ptr< linphone::Dictionaryclone () const
 Instantiates a new dictionary with values from source. More...
 
LINPHONECXX_PUBLIC std::shared_ptr< linphone::BuffergetBuffer (const std::string &key) const
 Gets the LinphoneBuffer value of a key. More...
 
LINPHONECXX_PUBLIC float getFloat (const std::string &key) const
 Gets the float value of a key. More...
 
LINPHONECXX_PUBLIC int getInt (const std::string &key) const
 Gets the int value of a key. More...
 
LINPHONECXX_PUBLIC int64_t getInt64 (const std::string &key) const
 Gets the int64 value of a key. More...
 
LINPHONECXX_PUBLIC std::string getString (const std::string &key) const
 Gets the char* value of a key. More...
 
LINPHONECXX_PUBLIC linphone::Status hasKey (const std::string &key) const
 Search if the key is present in the dictionary. More...
 
LINPHONECXX_PUBLIC linphone::Status remove (const std::string &key)
 Removes the pair of the key. More...
 
LINPHONECXX_PUBLIC void setBuffer (const std::string &key, const std::shared_ptr< linphone::Buffer > &value)
 Sets a LinphoneBuffer value to a key. More...
 
LINPHONECXX_PUBLIC void setFloat (const std::string &key, float value)
 Sets a float value to a key. More...
 
LINPHONECXX_PUBLIC void setInt (const std::string &key, int value)
 Sets a int value to a key. More...
 
LINPHONECXX_PUBLIC void setInt64 (const std::string &key, int64_t value)
 Sets a int64 value to a key. More...
 
LINPHONECXX_PUBLIC void setString (const std::string &key, const std::string &value)
 Sets a char* value to a key. More...
 

Detailed Description

Object that represents key-value pair container.

Member Function Documentation

◆ clone()

LINPHONECXX_PUBLIC std::shared_ptr<linphone::Dictionary> linphone::Dictionary::clone ( ) const

Instantiates a new dictionary with values from source.

Returns
The newly created Dictionary object.

◆ getBuffer()

LINPHONECXX_PUBLIC std::shared_ptr<linphone::Buffer> linphone::Dictionary::getBuffer ( const std::string &  key) const

Gets the LinphoneBuffer value of a key.

Parameters
keyThe key.
Returns
The value.

◆ getFloat()

LINPHONECXX_PUBLIC float linphone::Dictionary::getFloat ( const std::string &  key) const

Gets the float value of a key.

Parameters
keyThe key.
Returns
The value.

◆ getInt()

LINPHONECXX_PUBLIC int linphone::Dictionary::getInt ( const std::string &  key) const

Gets the int value of a key.

Parameters
keyThe key.
Returns
The value.

◆ getInt64()

LINPHONECXX_PUBLIC int64_t linphone::Dictionary::getInt64 ( const std::string &  key) const

Gets the int64 value of a key.

Parameters
keyThe key.
Returns
The value.

◆ getKeys()

LINPHONECXX_PUBLIC std::list<std::string> linphone::Dictionary::getKeys ( ) const

Returns the list of keys present in the dictionary.

Returns
the of keys inside the dictionary.

◆ getString()

LINPHONECXX_PUBLIC std::string linphone::Dictionary::getString ( const std::string &  key) const

Gets the char* value of a key.

Parameters
keyThe key.
Returns
The value.

◆ hasKey()

LINPHONECXX_PUBLIC linphone::Status linphone::Dictionary::hasKey ( const std::string &  key) const

Search if the key is present in the dictionary.

Parameters
keyThe key.
Returns
The LinphoneStatus of the operation.

◆ remove()

LINPHONECXX_PUBLIC linphone::Status linphone::Dictionary::remove ( const std::string &  key)

Removes the pair of the key.

Parameters
keyThe key.
Returns
The LinphoneStatus of the operation.

◆ setBuffer()

LINPHONECXX_PUBLIC void linphone::Dictionary::setBuffer ( const std::string &  key,
const std::shared_ptr< linphone::Buffer > &  value 
)

Sets a LinphoneBuffer value to a key.

Parameters
keyThe key.
valueThe LinphoneBuffer value.

◆ setFloat()

LINPHONECXX_PUBLIC void linphone::Dictionary::setFloat ( const std::string &  key,
float  value 
)

Sets a float value to a key.

Parameters
keyThe key.
valueThe int value.

◆ setInt()

LINPHONECXX_PUBLIC void linphone::Dictionary::setInt ( const std::string &  key,
int  value 
)

Sets a int value to a key.

Parameters
keyThe key.
valueThe int value.

◆ setInt64()

LINPHONECXX_PUBLIC void linphone::Dictionary::setInt64 ( const std::string &  key,
int64_t  value 
)

Sets a int64 value to a key.

Parameters
keyThe key.
valueThe int64 value.

◆ setString()

LINPHONECXX_PUBLIC void linphone::Dictionary::setString ( const std::string &  key,
const std::string &  value 
)

Sets a char* value to a key.

Parameters
keyThe key.
valueThe value.

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