epoc32/include/stdapis/stlport/stl/wrappers/_vector.h
branchSymbian2
changeset 2 2fe1408b6811
parent 0 061f57f2323e
     1.1 --- a/epoc32/include/stdapis/stlport/stl/wrappers/_vector.h	Tue Nov 24 13:55:44 2009 +0000
     1.2 +++ b/epoc32/include/stdapis/stlport/stl/wrappers/_vector.h	Tue Mar 16 16:12:26 2010 +0000
     1.3 @@ -1,1 +1,89 @@
     1.4 -_vector.h
     1.5 +/*
     1.6 + *
     1.7 + * Copyright (c) 1994
     1.8 + * Hewlett-Packard Company
     1.9 + *
    1.10 + * Copyright (c) 1996,1997
    1.11 + * Silicon Graphics Computer Systems, Inc.
    1.12 + *
    1.13 + * Copyright (c) 1997
    1.14 + * Moscow Center for SPARC Technology
    1.15 + *
    1.16 + * Copyright (c) 1999 
    1.17 + * Boris Fomitchev
    1.18 + *
    1.19 + * This material is provided "as is", with absolutely no warranty expressed
    1.20 + * or implied. Any use is at your own risk.
    1.21 + *
    1.22 + * Permission to use or copy this software for any purpose is hereby granted 
    1.23 + * without fee, provided the above notices are retained on all copies.
    1.24 + * Permission to modify the code and to distribute modified code is granted,
    1.25 + * provided the above notices are retained, and a notice that the code was
    1.26 + * modified is included with the above copyright notice.
    1.27 + *
    1.28 + */
    1.29 +
    1.30 +/* NOTE: This is an internal header file, included by other STL headers.
    1.31 + *   You should not attempt to use it directly.
    1.32 + */
    1.33 +
    1.34 +#ifndef _STLP_INTERNAL_WRAP_VECTOR_H
    1.35 +#define _STLP_INTERNAL_WRAP_VECTOR_H
    1.36 +
    1.37 +#ifndef _STLP_INTERNAL_VECTOR_H
    1.38 +# include <stl/_vector.h>
    1.39 +#endif
    1.40 +
    1.41 +# if defined (_STLP_DEBUG)
    1.42 +#  define _VEC_SUPER _DBG_vector<_Tp, _STLP_DEFAULT_ALLOCATOR(_Tp) >
    1.43 +# else
    1.44 +#  define _VEC_SUPER __vector__<_Tp, _STLP_DEFAULT_ALLOCATOR(_Tp) >
    1.45 +# endif
    1.46 +
    1.47 +# ifdef _STLP_USE_NAMESPACES
    1.48 +namespace STLPORT { 
    1.49 +# endif
    1.50 +
    1.51 +template <class _Tp>
    1.52 +class vector : public _VEC_SUPER
    1.53 +{
    1.54 +public:
    1.55 +    typedef _VEC_SUPER  _Super;
    1.56 +    __IMPORT_WITH_REVERSE_ITERATORS(_Super)
    1.57 +    __IMPORT_SUPER_COPY_ASSIGNMENT(vector, vector<_Tp>, _VEC_SUPER)
    1.58 +    vector() {}
    1.59 +    explicit vector(size_type __n, const _Tp& __value) : _VEC_SUPER(__n, __value) { }
    1.60 +    explicit vector(size_type __n) : _VEC_SUPER(__n) { }
    1.61 +    vector(const_iterator __first, const_iterator __last) : _VEC_SUPER(__first,__last) { }
    1.62 +# ifdef _STLP_DEBUG
    1.63 +  // certainly, no member templates here !
    1.64 +    vector(const _Tp* __first, const _Tp* __last) : _VEC_SUPER(__first,__last) { }    
    1.65 +# endif
    1.66 +    ~vector() {}
    1.67 +};
    1.68 +
    1.69 +#  if defined (_STLP_BASE_MATCH_BUG)
    1.70 +template <class _Tp>
    1.71 +inline bool operator==(const vector<_Tp>& __x, const vector<_Tp>& __y) {
    1.72 +  return __x.size() == __y.size() &&
    1.73 +    equal(__x.begin(), __x.end(), __y.begin());
    1.74 +}
    1.75 +
    1.76 +template <class _Tp>
    1.77 +inline bool operator<(const vector<_Tp>& __x, const vector<_Tp>& __y) {
    1.78 +  return lexicographical_compare(__x.begin(), __x.end(), 
    1.79 +				 __y.begin(), __y.end());
    1.80 +}
    1.81 +#  endif /* _STLP_BASE_MATCH_BUG */
    1.82 +#  undef _VEC_SUPER
    1.83 +
    1.84 +// close std namespace
    1.85 +# ifdef _STLP_USE_NAMESPACES
    1.86 +}
    1.87 +# endif
    1.88 +
    1.89 +#endif /* _STLP_WRAP_VECTOR_H */
    1.90 +
    1.91 +// Local Variables:
    1.92 +// mode:C++
    1.93 +// End: