TAO_AnyTypeCode 4.0.1
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
CORBA::NVList Class Reference

CORBA::NVList implementation. More...

#include <NVList.h>

Collaboration diagram for CORBA::NVList:
Collaboration graph
[legend]

Public Types

typedef NVList_ptr _ptr_type
 
typedef NVList_var _var_type
 
typedef NVList_out _out_type
 

Public Member Functions

ULong count () const
 return the current number of elements in the list
 
NamedValue_ptr add (Flags)
 add an element and just initialize the flags
 
NamedValue_ptr add_item (const char *, Flags)
 add an element and initialize its name and flags
 
NamedValue_ptr add_value (const char *, const Any &, Flags)
 initializes a value, name, and flags
 
NamedValue_ptr add_item_consume (char *, Flags)
 
NamedValue_ptr add_value_consume (char *, Any_ptr, Flags)
 
NamedValue_ptr item (ULong n)
 retrieve the item at the nth location. Raises Bounds
 
void remove (ULong n)
 remove element at index n. Raises Bounds
 
ULong _incr_refcount ()
 
ULong _decr_refcount ()
 
void _tao_incoming_cdr (TAO_InputCDR &cdr, int flag, bool &lazy_evaluation)
 
void _tao_encode (TAO_OutputCDR &cdr, int flag)
 
void _tao_decode (TAO_InputCDR &cdr, int flag)
 Decode the NVList arguments from the cdr stream.
 
ptrdiff_t _tao_target_alignment ()
 
Boolean _lazy_has_arguments () const
 

Static Public Member Functions

static NVList_duplicate (NVList *)
 
static NVList_nil ()
 

Protected Member Functions

 ~NVList ()
 Destructor.
 

Private Member Functions

 NVList ()
 
NamedValue_ptr add_element (Flags)
 
void evaluate ()
 

Private Attributes

ACE_Unbounded_Queue< NamedValue_ptrvalues_
 Internal list of parameters stored as NamedValues.
 
ULong max_
 Maximum length of list.
 
std::atomic< uint32_t > refcount_
 Reference counter.
 
TAO_SYNCH_MUTEX lock_
 Protects the incoming pointer.
 
TAO_InputCDRincoming_
 
int incoming_flag_
 

Friends

class ::TAO_NVList_Adapter_Impl
 
class Request
 

Detailed Description

CORBA::NVList implementation.

This is used in the (client side) DII (Dynamic Invocation Interface) to hold parameters, except for the return parameter. It's used in the same role in the (server side) DSI (Dynamic Skeleton Interface).

Each user (client, server) provides the typecode and memory for each parameter using an NVList, then talks to the ORB using a Request or ServerRequest pseudo-object. The ORB copies data to/from the IPC messages (e.g. IIOP::Request, IIOP::Response) as appropriate.

Member Typedef Documentation

◆ _out_type

◆ _ptr_type

◆ _var_type

Constructor & Destructor Documentation

◆ ~NVList()

CORBA::NVList::~NVList ( )
protected

Destructor.

Protected destructor to enforce proper memory management through the reference counting mechanism.

◆ NVList()

CORBA::NVList::NVList ( )
private

Constructor - cannot be instantiated directly other than through the CORBA::ORB::create_list method

Member Function Documentation

◆ _decr_refcount()

CORBA::ULong CORBA::NVList::_decr_refcount ( )

◆ _duplicate()

CORBA::NVList * CORBA::NVList::_duplicate ( CORBA::NVList * x)
static

◆ _incr_refcount()

CORBA::ULong CORBA::NVList::_incr_refcount ( )

◆ _lazy_has_arguments()

CORBA::Boolean CORBA::NVList::_lazy_has_arguments ( ) const

If this list is used by a DII request, this will tell us if our CDR stream contains any marshaled arguments (needed for GIOP 1.2).

◆ _nil()

CORBA::NVList * CORBA::NVList::_nil ( )
static

◆ _tao_decode()

void CORBA::NVList::_tao_decode ( TAO_InputCDR & cdr,
int flag )

Decode the NVList arguments from the cdr stream.

◆ _tao_encode()

void CORBA::NVList::_tao_encode ( TAO_OutputCDR & cdr,
int flag )

Encode the NVList into the CDR stream. flag masks the type of arguments (IN, OUT or INOUT) that are to be marshaled.

◆ _tao_incoming_cdr()

void CORBA::NVList::_tao_incoming_cdr ( TAO_InputCDR & cdr,
int flag,
bool & lazy_evaluation )

Set the incoming CDR stream, this is used by TAO to perform lazy evaluation of the NVList in an incoming ServerRequest. The <flag> is used to check which parameters (IN, OUT and/or INOUT) are to be extracted

◆ _tao_target_alignment()

ptrdiff_t CORBA::NVList::_tao_target_alignment ( )

Return the required alignment to marshal the NVList without any re-alignment. It returns ACE_CDR::MAX_ALIGNMENT to indicate errors.

◆ add()

CORBA::NamedValue_ptr CORBA::NVList::add ( CORBA::Flags flags)

add an element and just initialize the flags

◆ add_element()

CORBA::NamedValue_ptr CORBA::NVList::add_element ( CORBA::Flags flags)
private

Helper to increase the list size. This is used by all the add_ methods of the NVList class

◆ add_item()

CORBA::NamedValue_ptr CORBA::NVList::add_item ( const char * name,
CORBA::Flags flags )

add an element and initialize its name and flags

◆ add_item_consume()

CORBA::NamedValue_ptr CORBA::NVList::add_item_consume ( char * name,
CORBA::Flags flags )

just like add_item. In addition, memory management of char * name is taken over by the NVList

◆ add_value()

CORBA::NamedValue_ptr CORBA::NVList::add_value ( const char * name,
const Any & value,
CORBA::Flags flags )

initializes a value, name, and flags

◆ add_value_consume()

CORBA::NamedValue_ptr CORBA::NVList::add_value_consume ( char * ,
Any_ptr ,
Flags  )

just like add_value. In addition, the NVList controls the memory management of the char *name and Any *value parameter

◆ count()

CORBA::ULong CORBA::NVList::count ( ) const

return the current number of elements in the list

◆ evaluate()

void CORBA::NVList::evaluate ( )
private

Lazy evaluation routine to fill up the Anys in the NVList from the CDR stream.

◆ item()

CORBA::NamedValue_ptr CORBA::NVList::item ( CORBA::ULong n)

retrieve the item at the nth location. Raises Bounds

◆ remove()

void CORBA::NVList::remove ( CORBA::ULong n)

remove element at index n. Raises Bounds

Friends And Related Symbol Documentation

◆ ::TAO_NVList_Adapter_Impl

friend class ::TAO_NVList_Adapter_Impl
friend

◆ Request

friend class Request
friend

Member Data Documentation

◆ incoming_

TAO_InputCDR* CORBA::NVList::incoming_
private

When the NVList is used as part of a Server Request we can simply store the CDR buffer and perform lazy evaluation to compute the Anys.

◆ incoming_flag_

int CORBA::NVList::incoming_flag_
private

The flags used to check which parameters are actually extracted from the <incoming_> buffer

◆ lock_

TAO_SYNCH_MUTEX CORBA::NVList::lock_
private

Protects the incoming pointer.

◆ max_

ULong CORBA::NVList::max_
private

Maximum length of list.

◆ refcount_

std::atomic<uint32_t> CORBA::NVList::refcount_
private

Reference counter.

◆ values_

ACE_Unbounded_Queue<NamedValue_ptr> CORBA::NVList::values_
private

Internal list of parameters stored as NamedValues.


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