PCL
IndirectSortedArray.h
Go to the documentation of this file.
1 // ____ ______ __
2 // / __ \ / ____// /
3 // / /_/ // / / /
4 // / ____// /___ / /___ PixInsight Class Library
5 // /_/ \____//_____/ PCL 2.1.19
6 // ----------------------------------------------------------------------------
7 // pcl/IndirectSortedArray.h - Released 2019-11-07T10:59:34Z
8 // ----------------------------------------------------------------------------
9 // This file is part of the PixInsight Class Library (PCL).
10 // PCL is a multiplatform C++ framework for development of PixInsight modules.
11 //
12 // Copyright (c) 2003-2019 Pleiades Astrophoto S.L. All Rights Reserved.
13 //
14 // Redistribution and use in both source and binary forms, with or without
15 // modification, is permitted provided that the following conditions are met:
16 //
17 // 1. All redistributions of source code must retain the above copyright
18 // notice, this list of conditions and the following disclaimer.
19 //
20 // 2. All redistributions in binary form must reproduce the above copyright
21 // notice, this list of conditions and the following disclaimer in the
22 // documentation and/or other materials provided with the distribution.
23 //
24 // 3. Neither the names "PixInsight" and "Pleiades Astrophoto", nor the names
25 // of their contributors, may be used to endorse or promote products derived
26 // from this software without specific prior written permission. For written
27 // permission, please contact info@pixinsight.com.
28 //
29 // 4. All products derived from this software, in any form whatsoever, must
30 // reproduce the following acknowledgment in the end-user documentation
31 // and/or other materials provided with the product:
32 //
33 // "This product is based on software from the PixInsight project, developed
34 // by Pleiades Astrophoto and its contributors (http://pixinsight.com/)."
35 //
36 // Alternatively, if that is where third-party acknowledgments normally
37 // appear, this acknowledgment must be reproduced in the product itself.
38 //
39 // THIS SOFTWARE IS PROVIDED BY PLEIADES ASTROPHOTO AND ITS CONTRIBUTORS
40 // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
41 // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
42 // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL PLEIADES ASTROPHOTO OR ITS
43 // CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
44 // EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, BUSINESS
45 // INTERRUPTION; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; AND LOSS OF USE,
46 // DATA OR PROFITS) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
47 // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
48 // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
49 // POSSIBILITY OF SUCH DAMAGE.
50 // ----------------------------------------------------------------------------
51 
52 #ifndef __PCL_IndirectSortedArray_h
53 #define __PCL_IndirectSortedArray_h
54 
56 
57 #include <pcl/Defs.h>
58 #include <pcl/Diagnostics.h>
59 
60 #include <pcl/IndirectArray.h>
61 #include <pcl/SortedArray.h>
62 
63 namespace pcl
64 {
65 
66 // ----------------------------------------------------------------------------
67 
90 template <class T, class A = StandardAllocator>
91 class PCL_CLASS IndirectSortedArray : public IndirectSortedContainer<T>
92 {
93 public:
94 
98 
103 
106  typedef typename array_implementation::allocator
108 
111  typedef typename array_implementation::iterator
113 
116  typedef typename array_implementation::const_iterator
118 
123 
128 
131  typedef typename array_implementation::equal
133 
136  typedef typename array_implementation::less
138 
139  // -------------------------------------------------------------------------
140 
144  IndirectSortedArray() : m_array()
145  {
146  }
147 
152  explicit
153  IndirectSortedArray( size_type n ) : m_array( n )
154  {
155  }
156 
161  IndirectSortedArray( size_type n, const T* p ) : m_array( n, p )
162  {
163  }
164 
170  template <class FI>
171  IndirectSortedArray( FI i, FI j ) : m_array( i, j )
172  {
173  Sort();
174  }
175 
179  IndirectSortedArray( const IndirectSortedArray& x ) : m_array( x.m_array )
180  {
181  }
182 
186  IndirectSortedArray( IndirectSortedArray&& x ) : m_array( std::move( x.m_array ) )
187  {
188  }
189 
198  {
199  }
200 
205  bool IsUnique() const
206  {
207  return m_array.IsUnique();
208  }
209 
217  bool IsAliasOf( const IndirectSortedArray& x ) const
218  {
219  return m_array.IsAliasOf( x.m_array );
220  }
221 
231  {
232  m_array.EnsureUnique();
233  }
234 
239  size_type Size() const
240  {
241  return m_array.Size();
242  }
243 
247  {
248  return m_array.Length();
249  }
250 
254  {
255  return m_array.Capacity();
256  }
257 
261  {
262  return m_array.Available();
263  }
264 
267  bool IsValid() const
268  {
269  return m_array.IsValid();
270  }
271 
274  bool IsEmpty() const
275  {
276  return m_array.IsEmpty();
277  }
278 
282  {
283  return m_array.LowerBound();
284  }
285 
289  {
290  return m_array.UpperBound();
291  }
292 
295  const allocator& GetAllocator() const
296  {
297  return m_array.GetAllocator();
298  }
299 
302  void SetAllocator( const allocator& a )
303  {
304  m_array.SetAllocator( a );
305  }
306 
310  {
311  return m_array.At( i );
312  }
313 
317  {
318  return m_array.At( i );
319  }
320 
324  {
325  return m_array.MutableIterator( i );
326  }
327 
330  const T* operator []( size_type i ) const
331  {
332  return m_array[i];
333  }
334 
337  const T* operator *() const
338  {
339  return *Begin();
340  }
341 
345  {
346  return m_array.ConstBegin();
347  }
348 
352  {
353  return m_array.Begin();
354  }
355 
359  {
360  return m_array.ConstEnd();
361  }
362 
366  {
367  return m_array.End();
368  }
369 
373  {
374  return m_array.ConstReverseBegin();
375  }
376 
380  {
381  return m_array.ReverseBegin();
382  }
383 
387  {
388  return m_array.ConstReverseEnd();
389  }
390 
394  {
395  return m_array.ReverseEnd();
396  }
397 
400  const T* First() const
401  {
402  return m_array.First();
403  }
404 
407  T* MutableFirst()
408  {
409  return IsEmpty() ? nullptr : *MutableBegin();
410  }
411 
414  const T* Last() const
415  {
416  return m_array.Last();
417  }
418 
421  T* MutableLast()
422  {
423  return IsEmpty() ? nullptr : *MutableReverseBegin();
424  }
425 
435  {
436  m_array.UniquifyIterator( i );
437  }
438 
449  {
450  m_array.UniquifyIterators( i, j );
451  }
452 
453 #ifndef __PCL_NO_STL_COMPATIBLE_ITERATORS
454 
458  {
459  return Begin();
460  }
461 
466  {
467  return End();
468  }
469 #endif // !__PCL_NO_STL_COMPATIBLE_ITERATORS
470 
477  IndirectSortedArray& operator =( const IndirectSortedArray& x )
478  {
479  Assign( x );
480  return *this;
481  }
482 
485  void Assign( const IndirectSortedArray& x )
486  {
487  m_array.Assign( x.m_array );
488  }
489 
494  {
495  Transfer( x );
496  return *this;
497  }
498 
502  {
503  m_array.Transfer( x.m_array );
504  }
505 
509  {
510  m_array.Transfer( x.m_array );
511  }
512 
515  IndirectSortedArray& operator =( const array_implementation& x )
516  {
517  Assign( x );
518  return *this;
519  }
520 
523  void Assign( const array_implementation& x )
524  {
525  m_array.Assign( x );
526  Sort();
527  }
528 
531  IndirectSortedArray& operator =( array_implementation&& x )
532  {
533  Transfer( x );
534  return *this;
535  }
536 
539  void Transfer( array_implementation& x )
540  {
541  m_array.Transfer( x );
542  Sort();
543  }
544 
547  void Transfer( array_implementation&& x )
548  {
549  m_array.Transfer( x );
550  Sort();
551  }
552 
555  void Assign( const T* p, size_type n = 1 )
556  {
557  m_array.Assign( p, n );
558  }
559 
562  template <class FI>
563  void Assign( FI i, FI j )
564  {
565  m_array.Assign( i, j );
566  Sort();
567  }
568 
571  template <class C>
572  void CloneAssign( const C& x )
573  {
574  m_array.CloneAssign( x );
575  Sort();
576  }
577 
581  {
582  m_array.CloneAssign( x );
583  }
584 
588  {
589  m_array.CloneAssign( x );
590  }
591 
594  void Import( iterator i, iterator j )
595  {
596  m_array.Import( i, j );
597  Sort();
598  }
599 
603  {
604  return m_array.Release();
605  }
606 
609  void Add( const IndirectSortedArray& x )
610  {
611  const_iterator p = x.m_array.Begin(), q = x.m_array.End();
612  less cmp;
613  for ( iterator i = m_array.Begin(); i < m_array.End() && p < q; ++i )
614  if ( cmp( *p, *i ) )
615  i = m_array.Insert( i, *p++ );
616  if ( p < q )
617  m_array.Append( p, q );
618  }
619 
622  void Add( const IndirectArray<T,A>& x )
623  {
624  Add( x.Begin(), x.End() );
625  }
626 
629  const_iterator Add( const T* p, size_type n = 1 )
630  {
631  return m_array.Insert( pcl::InsertionPoint( m_array.Begin(), m_array.End(), p, less() ), p, n );
632  }
633 
636  template <class FI>
637  void Add( FI i, FI j )
638  {
639  if ( i != j )
640  {
641  m_array.EnsureUnique();
642  for ( const_iterator l = m_array.Begin(), r = m_array.End(); ; )
643  {
644  FI h = i;
645  const_iterator m = m_array.Insert( pcl::InsertionPoint( l, r, *i, less() ), *i );
646 
647  if ( ++i == j )
648  break;
649 
650  if ( less()( *i, *h ) )
651  {
652  l = m_array.Begin();
653  r = m;
654  }
655  else
656  {
657  l = m+1;
658  r = m_array.End();
659  }
660  }
661  }
662  }
663 
666  void Remove( const_iterator i, size_type n = 1 )
667  {
668  m_array.Remove( i, n );
669  }
670 
674  {
675  m_array.Remove( i, j );
676  }
677 
692  {
693  m_array.Truncate( i );
694  }
695 
708  void Shrink( size_type n = 1 )
709  {
710  m_array.Shrink( n );
711  }
712 
715  void Remove( const T& v )
716  {
717  const_iterator i = pcl::BinarySearch( Begin(), End(), &v, less() );
718  if ( i != End() )
719  m_array.Remove( i, pcl::InsertionPoint( i+1, End(), &v, less() ) );
720  }
721 
724  template <class BP>
725  void Remove( const T& v, BP p )
726  {
727  m_array.Remove( v, p );
728  }
729 
732  void Remove( const T* p )
733  {
734  m_array.Remove( p );
735  }
736 
739  void Clear()
740  {
741  m_array.Clear();
742  }
743 
746  void Delete( iterator i, size_type n = 1 )
747  {
748  Delete( i, i+n );
749  }
750 
753  void Delete( iterator i, iterator j )
754  {
755  // NB: Copy-on-write must *not* happen in this function.
756  if ( i < End() )
757  {
758  i = pcl::Max( const_cast<iterator>( Begin() ), i );
759  j = pcl::Min( j, const_cast<iterator>( End() ) );
760  m_array.Delete( i, j );
761  if ( j < End() )
762  pcl::Fill( pcl::Copy( i, j, const_cast<iterator>( End() ) ),
763  const_cast<iterator>( End() ),
764  static_cast<T*>( nullptr ) );
765  }
766  }
767 
770  void Delete( const T& v )
771  {
772  // NB: Copy-on-write must *not* happen in this function.
773  const_iterator i = pcl::BinarySearch( Begin(), End(), &v, less() );
774  if ( i != End() )
775  Delete( const_cast<iterator>( i ),
776  const_cast<iterator>( pcl::InsertionPoint( i+1, Begin(), &v, less() ) ) );
777  }
778 
781  template <class BP>
782  void Delete( const T& v, BP p )
783  {
784  // NB: Copy-on-write must *not* happen in this function.
785  m_array.Delete( v, p );
786  pcl::QuickSort( Begin(), End(), less() );
787  }
788 
791  void Delete()
792  {
793  m_array.Delete();
794  }
795 
798  void Destroy( iterator i, size_type n = 1 )
799  {
800  m_array.Destroy( i, n );
801  }
802 
805  void Destroy( iterator i, iterator j )
806  {
807  m_array.Destroy( i, j );
808  }
809 
812  void Destroy( const T& v )
813  {
814  const_iterator i = pcl::BinarySearch( Begin(), End(), &v, less() );
815  if ( i != End() )
816  Destroy( const_cast<iterator>( i ),
817  const_cast<iterator>( pcl::InsertionPoint( i+1, End(), &v, less() ) ) );
818  }
819 
822  template <class BP>
823  void Destroy( const T& v, BP p )
824  {
825  m_array.Destroy( v, p );
826  pcl::QuickSort( Begin(), End(), less() );
827  }
828 
831  void Destroy()
832  {
833  m_array.Destroy();
834  }
835 
838  void Pack()
839  {
840  m_array.Pack();
841  }
842 
845  void Reserve( size_type n )
846  {
847  m_array.Reserve( n );
848  }
849 
852  void Squeeze()
853  {
854  m_array.Squeeze();
855  }
856 
860  void Fill( const T& v )
861  {
862  m_array.Fill( v );
863  }
864 
867  template <class F>
868  void Apply( F f ) const
869  {
870  m_array.Apply( f );
871  }
872 
875  template <class F>
877  {
878  return m_array.FirstThat( f );
879  }
880 
883  template <class F>
885  {
886  return m_array.LastThat( f );
887  }
888 
891  size_type Count( const T& v ) const
892  {
893  const_iterator i = pcl::BinarySearch( Begin(), End(), &v, less() );
894  return (i != End()) ? pcl::InsertionPoint( i+1, End(), &v, less() ) - i : 0;
895  }
896 
899  size_type Count( const T* p ) const
900  {
901  return m_array.Count( p );
902  }
903 
906  template <class BP>
907  size_type Count( const T& v, BP p ) const
908  {
909  return m_array.Count( v, p );
910  }
911 
914  template <class UP>
915  size_type CountIf( UP p ) const
916  {
917  return m_array.CountIf( p );
918  }
919 
923  {
924  return Begin();
925  }
926 
929  template <class BP>
930  const_iterator MinItem( BP p ) const
931  {
932  return m_array.MinItem( p );
933  }
934 
938  {
939  return IsEmpty() ? End() : End()-1;
940  }
941 
944  template <class BP>
945  const_iterator MaxItem( BP p ) const
946  {
947  return m_array.MaxItem( p );
948  }
949 
952  const_iterator Search( const T& v ) const
953  {
954  return pcl::BinarySearch( Begin(), End(), &v, less() );
955  }
956 
959  const_iterator Search( const T* p ) const
960  {
961  return m_array.Search( p );
962  }
963 
966  template <class BP>
967  const_iterator Search( const T& v, BP p ) const
968  {
969  return m_array.Search( v, p );
970  }
971 
974  const_iterator SearchLast( const T& v ) const
975  {
976  return pcl::BinarySearchLast( Begin(), End(), &v, less() );
977  }
978 
981  const_iterator SearchLast( const T* p ) const
982  {
983  return m_array.SearchLast( p );
984  }
985 
988  template <class BP>
989  const_iterator SearchLast( const T& v, BP p ) const
990  {
991  return m_array.SearchLast( v, p );
992  }
993 
996  bool Contains( const T& v ) const
997  {
998  return Search( v ) != End();
999  }
1000 
1003  bool Contains( const T* p ) const
1004  {
1005  return m_array.Contains( p );
1006  }
1007 
1010  template <class BP>
1011  bool Contains( const T& v, BP p ) const
1012  {
1013  return Search( v, p ) != End();
1014  }
1015 
1018  void Sort()
1019  {
1020  m_array.Sort();
1021  }
1022 
1027  {
1028  pcl::Swap( x1.m_array, x2.m_array );
1029  }
1030 
1036  friend bool operator ==( const IndirectSortedArray& x1, const IndirectSortedArray& x2 )
1037  {
1038  return x1.m_array == x2.m_array;
1039  }
1040 
1046  friend bool operator ==( const IndirectSortedArray& x1, const array_implementation& x2 )
1047  {
1048  return x1.m_array == x2;
1049  }
1050 
1056  friend bool operator ==( const array_implementation& x1, const IndirectSortedArray& x2 )
1057  {
1058  return x1 == x2.m_array;
1059  }
1060 
1066  friend bool operator <( const IndirectSortedArray& x1, const IndirectSortedArray& x2 )
1067  {
1068  return x1.m_array < x2.m_array;
1069  }
1070 
1076  friend bool operator <( const IndirectSortedArray& x1, const array_implementation& x2 )
1077  {
1078  return x1.m_array < x2;
1079  }
1080 
1086  friend bool operator <( const array_implementation& x1, const IndirectSortedArray& x2 )
1087  {
1088  return x1 < x2.m_array;
1089  }
1090 
1107  template <class S, typename SP>
1108  S& ToSeparated( S& s, SP separator ) const
1109  {
1110  return m_array.ToSeparated( s, separator );
1111  }
1112 
1135  template <class S, typename SP, class AF>
1136  S& ToSeparated( S& s, SP separator, AF append ) const
1137  {
1138  return m_array.ToSeparated( s, separator, append );
1139  }
1140 
1149  template <class S>
1150  S& ToCommaSeparated( S& s ) const
1151  {
1152  return m_array.ToCommaSeparated( s );
1153  }
1154 
1163  template <class S>
1164  S& ToSpaceSeparated( S& s ) const
1165  {
1166  return m_array.ToSpaceSeparated( s );
1167  }
1168 
1177  template <class S>
1178  S& ToTabSeparated( S& s ) const
1179  {
1180  return m_array.ToTabSeparated( s );
1181  }
1182 
1193  uint64 Hash64( uint64 seed = 0 ) const
1194  {
1195  return m_array.Hash64( seed );
1196  }
1197 
1208  uint32 Hash32( uint32 seed = 0 ) const
1209  {
1210  return m_array.Hash32( seed );
1211  }
1212 
1217  uint64 Hash( uint64 seed = 0 ) const
1218  {
1219  return Hash64( seed );
1220  }
1221 
1222  // -------------------------------------------------------------------------
1223 
1224 private:
1225 
1226  array_implementation m_array;
1227 };
1228 
1229 // ----------------------------------------------------------------------------
1230 
1238 template <class T, class A, class V> inline
1239 IndirectSortedArray<T,A>& operator <<( IndirectSortedArray<T,A>& x, const V* p )
1240 {
1241  x.Add( static_cast<const T*>( p ) );
1242  return x;
1243 }
1244 
1252 template <class T, class A, class V> inline
1253 IndirectSortedArray<T,A>& operator <<( IndirectSortedArray<T,A>&& x, const V* p )
1254 {
1255  x.Add( static_cast<const T*>( p ) );
1256  return x;
1257 }
1258 
1264 template <class T, class A> inline
1265 IndirectSortedArray<T,A>& operator <<( IndirectSortedArray<T,A>& x1, const IndirectSortedArray<T,A>& x2 )
1266 {
1267  x1.Add( x2 );
1268  return x1;
1269 }
1270 
1276 template <class T, class A> inline
1277 IndirectSortedArray<T,A>& operator <<( IndirectSortedArray<T,A>&& x1, const IndirectSortedArray<T,A>& x2 )
1278 {
1279  x1.Add( x2 );
1280  return x1;
1281 }
1282 
1288 template <class T, class A> inline
1289 IndirectSortedArray<T,A>& operator <<( IndirectSortedArray<T,A>& x1, const IndirectArray<T,A>& x2 )
1290 {
1291  x1.Add( x2 );
1292  return x1;
1293 }
1294 
1300 template <class T, class A> inline
1301 IndirectSortedArray<T,A>& operator <<( IndirectSortedArray<T,A>&& x1, const IndirectArray<T,A>& x2 )
1302 {
1303  x1.Add( x2 );
1304  return x1;
1305 }
1306 
1307 // ----------------------------------------------------------------------------
1308 
1309 } // pcl
1310 
1311 #endif // __PCL_IndirectSortedArray_h
1312 
1313 // ----------------------------------------------------------------------------
1314 // EOF pcl/IndirectSortedArray.h - Released 2019-11-07T10:59:34Z
uint64 Hash64(const void *data, size_type size, uint64 seed=0)
Definition: Math.h:3551
const_iterator MaxItem() const
void Delete(iterator i, size_type n=1)
IndirectArray< T, A > array_implementation
Complex< T1 > operator*(const Complex< T1 > &c1, const Complex< T2 > &c2)
Definition: Complex.h:539
void Delete(iterator i, iterator j)
A functional class that tests two pointers for equality of the pointed objects.
Definition: Indirect.h:273
void Transfer(IndirectSortedArray &&x)
uint32 Hash32(uint32 seed=0) const
IndirectSortedArray(const IndirectSortedArray &x)
void Delete(const T &v, BP p)
void Assign(const T *p, size_type n=1)
array_implementation::block_allocator block_allocator
void Swap(GenericPoint< T > &p1, GenericPoint< T > &p2)
Definition: Point.h:1402
const_iterator Search(const T &v) const
size_type CountIf(UP p) const
size_type Count(const T *p) const
void Transfer(IndirectSortedArray &x)
const_iterator begin() const
PCL root namespace.
Definition: AbstractImage.h:76
bool Contains(const T &v, BP p) const
array_implementation::const_iterator const_iterator
array_implementation::iterator iterator
FI BinarySearchLast(FI i, FI j, const T &v)
Definition: Search.h:238
const_iterator FirstThat(F f) const
void Truncate(const_iterator i)
array_implementation::const_reverse_iterator const_reverse_iterator
const_reverse_iterator ReverseBegin() const
void Destroy(iterator i, size_type n=1)
void Destroy(const T &v, BP p)
void Remove(const T &v, BP p)
void Sort(BI i, BI j)
Definition: Sort.h:534
const_iterator SearchLast(const T &v) const
const_iterator MinItem(BP p) const
Root base class of all PCL sorted containers of pointers to objects.
Definition: Container.h:108
A functional class that applies the less than relational operator to the objects pointed to by two po...
Definition: Indirect.h:295
void Add(const IndirectArray< T, A > &x)
Generic dynamic array of pointers to objects.
Definition: IndirectArray.h:91
void CloneAssign(IndirectSortedArray &x)
bool Contains(const T &v) const
void Shrink(size_type n=1)
const_iterator MaxItem(BP p) const
T *const * const_iterator
reverse_iterator MutableReverseEnd()
void SetAllocator(const allocator &a)
size_t size_type
Definition: Defs.h:543
const_iterator Search(const T *p) const
Provides memory allocation for PCL containers.
Definition: Allocator.h:131
FI InsertionPoint(FI i, FI j, const T &v)
Definition: Search.h:326
const_iterator LastThat(F f) const
void Destroy(T *p)
Definition: Allocator.h:276
const_iterator SearchLast(const T *p) const
FI BinarySearch(FI i, FI j, const T &v)
Definition: Search.h:170
void Remove(const_iterator i, size_type n=1)
const allocator & GetAllocator() const
unsigned long long uint64
Definition: Defs.h:616
size_type Count(const T &v, BP p) const
constexpr const T & Max(const T &a, const T &b)
Definition: Utility.h:119
void Assign(const array_implementation &x)
IndirectSortedArray(size_type n, const T *p)
constexpr const T & Min(const T &a, const T &b)
Definition: Utility.h:90
bool Contains(const T *p) const
const_iterator End() const
size_type Count(const T &v) const
iterator MutableIterator(const_iterator i)
IndirectSortedArray(IndirectSortedArray &&x)
uint64 Hash64(uint64 seed=0) const
void Transfer(array_implementation &x)
reverse_iterator MutableReverseBegin()
bool operator<(const Array< T, A > &x1, const Array< T, A > &x2)
Definition: Array.h:2086
array_implementation::less less
const_iterator Search(const T &v, BP p) const
iterator MutableAt(size_type i)
array_implementation::equal equal
uint64 Hash(uint64 seed=0) const
void UniquifyIterator(iterator &i)
void Transfer(array_implementation &&x)
array_implementation::reverse_iterator reverse_iterator
void QuickSort(RI i, RI j)
Definition: Sort.h:250
friend void Swap(IndirectSortedArray &x1, IndirectSortedArray &x2)
void Add(const IndirectSortedArray &x)
const_iterator SearchLast(const T &v, BP p) const
array_implementation::allocator allocator
const_iterator end() const
Reverse random access iterator.
Definition: Iterator.h:414
const_reverse_iterator ReverseEnd() const
void Remove(const_iterator i, const_iterator j)
const_iterator Add(const T *p, size_type n=1)
FI1 Search(FI1 i1, FI1 j1, FI2 i2, FI2 j2)
Definition: Search.h:397
const_iterator MinItem() const
bool operator==(const Array< T, A > &x1, const Array< T, A > &x2)
Definition: Array.h:2075
void Assign(const IndirectSortedArray &x)
Generic dynamic sorted array of pointers to objects.
void Import(iterator i, iterator j)
const_iterator At(size_type i) const
const_iterator Begin() const
void Destroy(iterator i, iterator j)
bool IsAliasOf(const IndirectSortedArray &x) const
unsigned int uint32
Definition: Defs.h:600
void UniquifyIterators(iterator &i, iterator &j)
void CloneAssign(SortedArray< T, A > &x)
Generic dynamic sorted array.
Definition: SortedArray.h:82