Oracle Coherence for C++ API
Release 3.7.1.0

E22845-01

Map::Entry Class Reference

#include <coherence/util/Map.hpp>

Inherits Object.

Inherited by TreeMap::Node [virtual], and WrapperCollections::AbstractWrapperEntry [virtual].

List of all members.


Detailed Description

A map entry (key-value pair).

The Map::entrySet method returns a collection-view of the map, whose elements are of this class. The only way to obtain a reference to a map entry is from the iterator of this collection-view. These Map::Entry objects are valid only for the duration of the iteration; more formally, the behavior of a map entry is undefined if the backing map has been modified after the entry was returned by the iterator.

See also:
Map::entrySet()
 

Public Types

typedef spec::Handle  Handle
  Entry Handle definition.
typedef spec::View  View
  Entry View definition.
typedef spec::Holder  Holder
  Entry Holder definition.

Public Member Functions

virtual Object::View  getKey () const =0
  Return the key corresponding to this entry.
virtual Object::Holder  getValue () const =0
  Return the value corresponding to this entry.
virtual Object::Holder  getValue ()=0
  Return the value corresponding to this entry.
virtual Object::Holder  setValue (Object::Holder ohValue)=0
  Update the value corresponding to this entry.

Member Function Documentation

virtual Object::View getKey (    )  const [pure virtual]

Return the key corresponding to this entry.

Returns:
the key corresponding to this entry.

Implemented in ConverterCollections::ConverterEntry, TreeMap::Node, and WrapperCollections::AbstractWrapperEntry.

virtual Object::Holder getValue (    )  const [pure virtual]

Return the value corresponding to this entry.

Returns:
the value corresponding to this entry.

Implemented in ConverterCollections::ConverterEntry, TreeMap::Node, and WrapperCollections::AbstractWrapperEntry.

virtual Object::Holder getValue (    )  [pure virtual]

Return the value corresponding to this entry.

Returns:
the value corresponding to this entry.

Implemented in TreeMap::Node, and WrapperCollections::AbstractWrapperEntry.

virtual Object::Holder setValue ( Object::Holder  ohValue  )  [pure virtual]

Update the value corresponding to this entry.

Parameters:
  ohValue  the new value for the entry
Returns:
the prior value

Implemented in ConverterCollections::ConverterEntry, TreeMap::Node, and WrapperCollections::AbstractWrapperEntry.


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

Copyright © 2000, 2011, Oracle and/or its affiliates. All rights reserved.