System::Collections::Generic Namespace Reference

Classes

class  _KeyCollection
 
class  _KeyList
 
class  _ValueCollection
 
class  _ValueList
 
class  ArrayList
 
class  BaseDictionary
 
class  BaseEnumerator
 
class  BaseKVCollection
 
struct  ComparerAdapter
 
class  DefaultComparer
 
class  Dictionary
 Forward declaration of Dictionary class. More...
 
struct  DictionaryHashSelector
 
struct  DictionaryHashSelector< T, typename std::enable_if< std::is_enum< T >::value >::type >
 
struct  DictionaryHashSelector< T, typename std::enable_if< System::detail::has_method_gethashcode< T >::value >::type >
 
struct  DictionaryHashSelector< T, typename std::enable_if< System::detail::has_ref_method_gethashcode< T >::value &&!System::detail::has_method_gethashcode< T >::value >::type >
 
class  DictionaryPtr
 
struct  EqualityComparerAdapter
 
struct  EqualityComparerHashAdapter
 
class  HashDictionary
 
class  HashSet
 Forward declaration of HashSet class. More...
 
class  HashSetPtr
 
class  ICollection
 
class  IComparer
 
class  IDictionary
 
class  IEnumerable
 
class  IEnumerator
 
class  IEqualityComparer
 
class  IKVCollection
 
class  IList
 
class  ISet
 
class  KeyValuePair
 
class  KVPairIterator
 
class  LinkedList
 LinkedList forward declaration. More...
 
class  LinkedListNode
 
class  List
 List forward declaration. More...
 
class  ListPtr
 
class  Queue
 Queue class forward declaration. More...
 
class  QueuePtr
 
class  ReverseEnumerator
 
class  SimpleEnumerator
 
class  SortedDictionary
 Sorted dictionary type forward declaration. More...
 
class  SortedDictionaryPtr
 
class  SortedList
 
class  Stack
 Stack class forward declaration. More...
 
class  StackPtr
 

Functions

template<template< typename, typename > class containterT, class T , class Allocator >
int _net_binnary_search (const containterT< T, Allocator > &container, int index, int count, T value, const SharedPtr< System::Collections::Generic::IComparer< T > > &comparer)
 
template<template< typename, typename > class containterT, class T , class Allocator >
std::enable_if< IsSmartPtr< T >::value, int >::type _net_binnary_search (const containterT< T, Allocator > &container, int index, int count, T value)
 
template<template< typename, typename > class containterT, class T , class Allocator >
std::enable_if<!IsSmartPtr< T >::value &&!std::is_scalar< T >::value, int >::type _net_binnary_search (const containterT< T, Allocator > &container, int index, int count, T value)
 
template<template< typename, typename > class containterT, class T , class Allocator >
std::enable_if< std::is_scalar< T >::value, int >::type _net_binnary_search (const containterT< T, Allocator > &container, int index, int count, T value)
 
template<typename TKey , typename TValue >
bool operator== (const KeyValuePair< TKey, TValue > &left, const KeyValuePair< TKey, TValue > &right)
 
template<typename TKey , typename TValue >
bool operator!= (const KeyValuePair< TKey, TValue > &left, const KeyValuePair< TKey, TValue > &right)
 

Function Documentation

◆ _net_binnary_search() [1/4]

template<template< typename, typename > class containterT, class T , class Allocator >
int System::Collections::Generic::_net_binnary_search ( const containterT< T, Allocator > &  container,
int  index,
int  count,
value,
const SharedPtr< System::Collections::Generic::IComparer< T > > &  comparer 
)

Implements binary search in random access container.

Template Parameters
containerTSTL-styled container template type with two template arguments: element type and allocator type.
TElement type.
AllocatorAllocator type.
Parameters
containerContainer to search in.
indexSearch range beginning index.
countSearch range length.
valueValue to look for.
comparerComparer object.
Returns
If found, index of the next element; otherwise, complements of index at which the search stopped.

◆ _net_binnary_search() [2/4]

template<template< typename, typename > class containterT, class T , class Allocator >
std::enable_if<IsSmartPtr<T>::value, int>::type System::Collections::Generic::_net_binnary_search ( const containterT< T, Allocator > &  container,
int  index,
int  count,
value 
)

Implements binary search in random access container. Specialization for smart pointers. Uses System::Object::CompareTo method.

Template Parameters
containerTSTL-styled container template type with two template arguments: element type and allocator type.
TElement type.
AllocatorAllocator type.
Parameters
containerContainer to search in.
indexSearch range beginning index.
countSearch range length.
valueValue to look for.
Returns
If found, index of the next element; otherwise, complements of index at which the search stopped.

◆ _net_binnary_search() [3/4]

template<template< typename, typename > class containterT, class T , class Allocator >
std::enable_if<!IsSmartPtr<T>::value && !std::is_scalar<T>::value, int>::type System::Collections::Generic::_net_binnary_search ( const containterT< T, Allocator > &  container,
int  index,
int  count,
value 
)

Implements binary search in random access container. Specialization for value types. Uses CompareTo method.

Template Parameters
containerTSTL-styled container template type with two template arguments: element type and allocator type.
TElement type.
AllocatorAllocator type.
Parameters
containerContainer to search in.
indexSearch range beginning index.
countSearch range length.
valueValue to look for.
Returns
If found, index of the next element; otherwise, complements of index at which the search stopped.

◆ _net_binnary_search() [4/4]

template<template< typename, typename > class containterT, class T , class Allocator >
std::enable_if<std::is_scalar<T>::value, int>::type System::Collections::Generic::_net_binnary_search ( const containterT< T, Allocator > &  container,
int  index,
int  count,
value 
)

Implements binary search in random access container. Specialization for scalar types. Compares elements using greater and less operators.

Template Parameters
containerTSTL-styled container template type with two template arguments: element type and allocator type.
TElement type.
AllocatorAllocator type.
Parameters
containerContainer to search in.
indexSearch range beginning index.
countSearch range length.
valueValue to look for.
Returns
If found, index of the next element; otherwise, complements of index at which the search stopped.

◆ operator!=()

template<typename TKey , typename TValue >
bool System::Collections::Generic::operator!= ( const KeyValuePair< TKey, TValue > &  left,
const KeyValuePair< TKey, TValue > &  right 
)

Compares two key-value pairs using inverse 'equals' semantics.

Template Parameters
TKeyKey type.
TValueValue type.
Parameters
leftLHS operand.
rightRHS operand.
Returns
True if both keys and values don't match, false otherwise.

◆ operator==()

template<typename TKey , typename TValue >
bool System::Collections::Generic::operator== ( const KeyValuePair< TKey, TValue > &  left,
const KeyValuePair< TKey, TValue > &  right 
)

Compares two key-value pairs using 'equals' semantics. Uses operator == or EqualsTo method for both keys and values, whichever is defined.

Template Parameters
TKeyKey type.
TValueValue type.
Parameters
leftLHS operand.
rightRHS operand.
Returns
True if both keys and values match, false otherwise.