HydraExpress™ C++ API Reference Guide

 
Loading...
Searching...
No Matches
rwsf::ArrayHandle< T > Class Template Reference

Implements multidimensional SOAP-encoded arrays. More...

#include <rwsf/webservice/ArrayHandle.h>

Inheritance diagram for rwsf::ArrayHandle< T >:
rwsf::XmlBindingHandle rwsf::XmlBindingHandleBase rwsf::HandleBase

Public Member Functions

 ArrayHandle (const ArrayHandle< T > &other)
void append (const_reference item)
reference at (size_type idx)
const_reference at (size_type idx) const
reference back ()
const_reference back () const
iterator begin ()
const_iterator begin () const
void clear ()
bool contains (const_reference key) const
bool empty () const
iterator end ()
const_iterator end () const
size_type entries () const
bool find (const_reference key, value_type &val) const
reference first ()
const_reference first () const
std::vector< size_t > & getDimensions ()
const std::vector< size_t > & getDimensions () const
size_type index (const_reference key) const
iterator insert (const_reference key)
iterator insert (iterator it, const_reference key)
void insertAt (size_type index, const_reference item)
bool isEmpty () const
reference last ()
const_reference last () const
size_type length () const
size_type occurrencesOf (const_reference key) const
reference operator() (size_type idx)
const_reference operator() (size_type idx) const
reference operator[] (size_type idx)
const_reference operator[] (size_type idx) const
void parseDimensions (const std::string &arrayType)
void prepend (const_reference item)
void push_back (const_reference item)
bool remove (const_reference key)
size_type removeAll (const_reference key)
value_type removeAt (size_type index)
value_type removeFirst ()
value_type removeLast ()
size_type replaceAll (const_reference oldVal, const_reference newVal)
void resize (size_t n)
size_type size () const
Public Member Functions inherited from rwsf::XmlBindingHandle
 XmlBindingHandle ()
 XmlBindingHandle (const XmlBindingHandle &other)
XmlBindingHandle clone () const
bool equals (const rwsf::XmlBindingHandle &second) const
bool getXsiNil () const
std::string getXsiNoNamespaceSchemaLocation () const
std::string getXsiSchemaLocation () const
bool isA (const rwsf::XmlBindingHandle &other) const
bool isHandleValid () const
bool isMarshalXsiTypeSet () const
bool isXsiNilSet () const
bool isXsiNoNamespaceSchemaLocationSet () const
bool isXsiSchemaLocationSet () const
void marshal (rwsf::XmlWriter &writer, bool includeChildTypeAttributes, const rwsf::XmlName &, bool includeSelfTypeAttribute, bool nilValue) const
bool operator!= (const rwsf::XmlBindingHandle &second) const
bool operator== (const rwsf::XmlBindingHandle &second) const
void setMarshalXsiType (bool setValue)
void setXsiNil (bool XsiNil)
void setXsiNilSet (bool setValue)
void setXsiNoNamespaceSchemaLocation (const std::string &loc)
void setXsiNoNamespaceSchemaLocationSet (bool setValue)
void setXsiSchemaLocation (const std::string &loc)
void setXsiSchemaLocationSet (bool setValue)
std::string typeId () const
const char * typeIdChar () const
std::string xsiType () const
const char * xsiTypeChar () const
Public Member Functions inherited from rwsf::XmlBindingHandleBase
 XmlBindingHandleBase (const XmlBindingHandleBase &other)
bool isSimple () const
void marshal (rwsf::XmlWriter &writer, bool includeChildTypeAttributes, const rwsf::XmlName &, bool includeSelfTypeAttribute, bool nilValue) const
std::string typeId () const
const char * typeIdChar () const
rwsf::XmlName xmlType () const
Public Member Functions inherited from rwsf::HandleBase
bool isValid (void) const
bool operator!= (const HandleBase &second) const
bool operator== (const HandleBase &second) const

Additional Inherited Members

Protected Member Functions inherited from rwsf::HandleBase
 HandleBase (BodyBase *body)
 HandleBase (const HandleBase &second)
 HandleBase (StaticCtor)
 HandleBase (void)
virtual ~HandleBase (void)
BodyBase & body (void) const
HandleBaseoperator= (const HandleBase &second)

Detailed Description

template<class T>
class rwsf::ArrayHandle< T >

All generated SOAP-Encoded arrays are derived from rwsf::ArrayHandler<T> , instantiated on the type of element contained in the array.

Note that this class uses reference semantics in which an instance of this class represents a reference to an implementation class.

For more information on SOAP-Encoded arrays, see the appendix in Web Service Development Guide.

Constructor & Destructor Documentation

◆ ArrayHandle()

template<class T>
rwsf::ArrayHandle< T >::ArrayHandle ( const ArrayHandle< T > & other)
inline

Copy constructor. Constructs a new handle from handle other.

Member Function Documentation

◆ append()

template<class T>
void rwsf::ArrayHandle< T >::append ( const_reference item)
inline

Adds item to the end of the collection body.

◆ at() [1/2]

template<class T>
reference rwsf::ArrayHandle< T >::at ( size_type idx)
inline

Returns a reference to the idxth element of the body. Index idx must be between 0 and one less then the number of entries in self, otherwise the function throws an exception of type rwsf::OutOfBoundsException.

◆ at() [2/2]

template<class T>
const_reference rwsf::ArrayHandle< T >::at ( size_type idx) const
inline

Returns a reference to the idxth element of the body. Index idx must be between 0 and one less then the number of entries in self, otherwise the function throws an exception of type rwsf::OutOfBoundsException.

◆ back() [1/2]

template<class T>
reference rwsf::ArrayHandle< T >::back ( )
inline

Returns a reference to the last element.

◆ back() [2/2]

template<class T>
const_reference rwsf::ArrayHandle< T >::back ( ) const
inline

Returns a reference to the last element.

◆ begin() [1/2]

template<class T>
iterator rwsf::ArrayHandle< T >::begin ( )
inline

Returns an iterator positioned at the first element of the body.

◆ begin() [2/2]

template<class T>
const_iterator rwsf::ArrayHandle< T >::begin ( ) const
inline

Returns an iterator positioned at the first element of the body.

◆ clear()

template<class T>
void rwsf::ArrayHandle< T >::clear ( )
inline

Clears the collection by removing all items from the body. Each item has its destructor called.

◆ contains()

template<class T>
bool rwsf::ArrayHandle< T >::contains ( const_reference key) const
inline

Returns true if key exists in the collection, otherwise returns false.

◆ empty()

template<class T>
bool rwsf::ArrayHandle< T >::empty ( ) const
inline

Returns true if there are no items in the collection, false otherwise.

◆ end() [1/2]

template<class T>
iterator rwsf::ArrayHandle< T >::end ( )
inline

Returns a past-the-end valued iterator of the body.

◆ end() [2/2]

template<class T>
const_iterator rwsf::ArrayHandle< T >::end ( ) const
inline

Returns a past-the-end valued iterator of the body.

◆ entries()

template<class T>
size_type rwsf::ArrayHandle< T >::entries ( ) const
inline

Returns the number of elements in the body.

◆ find()

template<class T>
bool rwsf::ArrayHandle< T >::find ( const_reference key,
value_type & val ) const
inline

Returns true if key exists in the collection, and assigns key to val. Otherwise, returns false and leaves the value of val unchanged.

◆ first() [1/2]

template<class T>
reference rwsf::ArrayHandle< T >::first ( )
inline

Returns a reference to the first element of the body.

◆ first() [2/2]

template<class T>
const_reference rwsf::ArrayHandle< T >::first ( ) const
inline

Returns a reference to the first element of the body.

◆ getDimensions() [1/2]

template<class T>
std::vector< size_t > & rwsf::ArrayHandle< T >::getDimensions ( )
inline

Returns a vector containing the size of each dimension in the array. If the array is int[2,3,4], then the returned vector contains 2, 3 and 4 in that order. Any dimension without a size is set to 0. For example, a one-dimension array returns a vector with a single element whose value is the upper bound of the array or 0 if there is no upper bound (defined as int[]).

◆ getDimensions() [2/2]

template<class T>
const std::vector< size_t > & rwsf::ArrayHandle< T >::getDimensions ( ) const
inline

Returns a vector containing the size of each dimension in the array. If the array is int[2,3,4], then the returned vector contains 2, 3 and 4 in that order. Any dimension without a size is set to 0. For example, a one-dimension array returns a vector with a single element whose value is the upper bound of the array or 0 if there is no upper bound (defined as int[]).

◆ index()

template<class T>
size_type rwsf::ArrayHandle< T >::index ( const_reference key) const
inline

Returns the position of the first item that matches key, or returns RWSF_NPOS if no such item exists.

◆ insert() [1/2]

template<class T>
iterator rwsf::ArrayHandle< T >::insert ( const_reference key)
inline

Adds the item key to the end of the collection.

◆ insert() [2/2]

template<class T>
iterator rwsf::ArrayHandle< T >::insert ( iterator it,
const_reference key )
inline

Adds the new item key before the item at position it.

◆ insertAt()

template<class T>
void rwsf::ArrayHandle< T >::insertAt ( size_type index,
const_reference item )
inline

Inserts item in front of the item at position index in self. This position must be between 0 and the number of entries in the collection, otherwise the function throws an exception of type rwsf::OutOfBoundsException.

◆ isEmpty()

template<class T>
bool rwsf::ArrayHandle< T >::isEmpty ( ) const
inline

Returns true if there are no items in the collection, false otherwise.

◆ last() [1/2]

template<class T>
reference rwsf::ArrayHandle< T >::last ( )
inline

Returns a reference to the last element.

◆ last() [2/2]

template<class T>
const_reference rwsf::ArrayHandle< T >::last ( ) const
inline

Returns a reference to the last element.

◆ length()

template<class T>
size_type rwsf::ArrayHandle< T >::length ( ) const
inline

Returns the number of elements in the body.

◆ occurrencesOf()

template<class T>
size_type rwsf::ArrayHandle< T >::occurrencesOf ( const_reference key) const
inline

Returns the number of times key occurs in the collection.

◆ operator()() [1/2]

template<class T>
reference rwsf::ArrayHandle< T >::operator() ( size_type idx)
inline

Returns a reference to the idxth element of the body. Index idx should be between 0 and one less then the number of entries, otherwise the results are undefined. No bounds checking is performed.

◆ operator()() [2/2]

template<class T>
const_reference rwsf::ArrayHandle< T >::operator() ( size_type idx) const
inline

Returns a reference to the idxth element of the body. Index idx should be between 0 and one less then the number of entries, otherwise the results are undefined. No bounds checking is performed.

◆ operator[]() [1/2]

template<class T>
reference rwsf::ArrayHandle< T >::operator[] ( size_type idx)
inline

Returns a reference to the idxth element of the body. Index idx must be between 0 and one less then the number of entries in self, otherwise the function throws an exception of type rwsf::OutOfBoundsException.

◆ operator[]() [2/2]

template<class T>
const_reference rwsf::ArrayHandle< T >::operator[] ( size_type idx) const
inline

Returns a reference to the idxth element of the body. Index idx must be between 0 and one less then the number of entries in self, otherwise the function throws an exception of type rwsf::OutOfBoundsException.

◆ parseDimensions()

template<class T>
void rwsf::ArrayHandle< T >::parseDimensions ( const std::string & arrayType)
inline

Parses the dimension string in the XML SOAP Array definition and sets the array dimensions in "this".

◆ prepend()

template<class T>
void rwsf::ArrayHandle< T >::prepend ( const_reference item)
inline

Adds the item item to the beginning of the collection.

◆ push_back()

template<class T>
void rwsf::ArrayHandle< T >::push_back ( const_reference item)
inline

Adds item to the end of the collection body.

◆ remove()

template<class T>
bool rwsf::ArrayHandle< T >::remove ( const_reference key)
inline

Removes the first occurrence of key in the array and returns true. If key is not found, returns false.

◆ removeAll()

template<class T>
size_type rwsf::ArrayHandle< T >::removeAll ( const_reference key)
inline

Removes all occurrences of key in the collection and returns the number of items removed.

◆ removeAt()

template<class T>
value_type rwsf::ArrayHandle< T >::removeAt ( size_type index)
inline

Removes and returns the item at position index in self. This position must be between 0 and one less then the number of entries in the collection, otherwise the function throws an exception of type rwsf::OutOfBoundsException.

◆ removeFirst()

template<class T>
value_type rwsf::ArrayHandle< T >::removeFirst ( )
inline

Removes and returns the first item in the collection.

◆ removeLast()

template<class T>
value_type rwsf::ArrayHandle< T >::removeLast ( )
inline

Removes and returns the last item in the collection.

◆ replaceAll()

template<class T>
size_type rwsf::ArrayHandle< T >::replaceAll ( const_reference oldVal,
const_reference newVal )
inline

Replaces all elements t in self with newVal such that the expression (t == oldVal) is true. Returns the number of items replaced.

◆ resize()

template<class T>
void rwsf::ArrayHandle< T >::resize ( size_t n)
inline

Modifies the capacity of the vector to be at least as large as n. This function has no effect if the capacity is already as large as n.

◆ size()

template<class T>
size_type rwsf::ArrayHandle< T >::size ( ) const
inline

Returns the number of elements in the body.

Copyright © 2026 Rogue Wave Software, Inc., a Perforce company. All Rights Reserved.