Xalan-C++ API Documentation

The Xalan C++ XSLT Processor Version 1.11


Public Types | Public Member Functions | List of all members
less_null_terminated_arrays< T > Struct Template Reference

This functor is designed to compare 0-terminated arrays. More...

#include <STLHelper.hpp>

Inherits binary_function< const T *, const T *, bool >.

Public Types

typedef std::binary_function< const T *, const T *, bool > BaseClassType
 
typedef BaseClassType::result_type result_type
 
typedef BaseClassType::first_argument_type first_argument_type
 
typedef BaseClassType::second_argument_type second_argument_type
 

Public Member Functions

result_type operator() (first_argument_type theLHS, second_argument_type theRHS) const
 Compare the values of two objects. More...
 

Detailed Description

template<class T>
struct less_null_terminated_arrays< T >

This functor is designed to compare 0-terminated arrays.

It substitutes for the default less<type*> so that pointers to arrays can be compared, rather than copies of arrays. For example, you might want to use C-style strings as keys in a map, rather than string objects. The default algorithm less<const char*> would just compare the pointers, and not the vector of characters to which it points. Using this algorithm instead of the default will allow the map to work as expected.

Definition at line 317 of file STLHelper.hpp.

Member Typedef Documentation

◆ BaseClassType

template<class T >
typedef std::binary_function<const T*, const T*, bool> less_null_terminated_arrays< T >::BaseClassType

Definition at line 323 of file STLHelper.hpp.

◆ first_argument_type

template<class T >
typedef BaseClassType::first_argument_type less_null_terminated_arrays< T >::first_argument_type

Definition at line 327 of file STLHelper.hpp.

◆ result_type

template<class T >
typedef BaseClassType::result_type less_null_terminated_arrays< T >::result_type

Definition at line 326 of file STLHelper.hpp.

◆ second_argument_type

template<class T >
typedef BaseClassType::second_argument_type less_null_terminated_arrays< T >::second_argument_type

Definition at line 328 of file STLHelper.hpp.

Member Function Documentation

◆ operator()()

template<class T >
result_type less_null_terminated_arrays< T >::operator() ( first_argument_type  theLHS,
second_argument_type  theRHS 
) const
inline

Compare the values of two objects.

Parameters
theLHSfirst object to compare
theRHSsecond object to compare
Returns
true if objects are the same

Definition at line 339 of file STLHelper.hpp.


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

Interpreting class diagrams

Doxygen and GraphViz are used to generate this API documentation from the Xalan-C header files.

Xalan-C++ XSLT Processor Version 1.11
Copyright © 1999-2012 The Apache Software Foundation.
All Rights Reserved.

Apache Logo