osl::FixedCapacityVector< T, Capacity > Class Template Reference

`#include <container.h>`

## Classes

struct | Array

## Public Types

typedef array_t::value_type | value_type
typedef array_t::iterator | iterator
typedef array_t::const_iterator | const_iterator

## Public Member Functions

| FixedCapacityVector ()
| FixedCapacityVector (size_t size)
| FixedCapacityVector (FixedCapacityVector const &rhs)
template<class RangeIterator>
| FixedCapacityVector (const RangeIterator &first, const RangeIterator &last)
| ~FixedCapacityVector ()
FixedCapacityVector & | operator= (FixedCapacityVector const &rhs)
T & | operator[] (size_t i)
iterator | begin ()
iterator | end ()
T & | front ()
T & | back ()
void | push_back (const T &e)
template<class RangeIterator>
void | push_back (const RangeIterator &first, const RangeIterator &last)
void | pop_back ()
void | clear ()
void | resize (size_t new_length)
void | erase (const T &e)
void | unique ()
| 重複する要素を取り除く
size_t | size () const
bool | empty () const
size_t | capacity () const
T const & | operator[] (size_t i) const
const_iterator | begin () const
const_iterator | end () const
const T & | front () const
const T & | back () const
bool | isMember (const T &e, const_iterator first, const_iterator last) const
bool | isMember (const T &e) const
detail::FixedCapacityVectorPushBack< T > | pushBackHelper ()

## Protected Types

typedef Array | array_t

## Protected Attributes

T * | ptr
CArray< int64_t,(sizeof(T[Capacity])+sizeof(int64_t) -1)/sizeof(int64_t)> | relements

## Private Member Functions

const array_t & | elements () const
array_t & | elements ()

## Detailed Description

template<typename T, size_t Capacity>
class osl::FixedCapacityVector< T, Capacity >

Definition at line 136 of file container.h.

## Member Typedef Documentation

## array_t

template<typename T, size_t Capacity>

typedef Array osl::FixedCapacityVector< T, Capacity >::array_t

protected

Definition at line 144 of file container.h.

## const_iterator

template<typename T, size_t Capacity>

typedef array_t::const_iterator osl::FixedCapacityVector< T, Capacity >::const_iterator

Definition at line 157 of file container.h.

## iterator

template<typename T, size_t Capacity>

typedef array_t::iterator osl::FixedCapacityVector< T, Capacity >::iterator

Definition at line 156 of file container.h.

## value_type

template<typename T, size_t Capacity>

typedef array_t::value_type osl::FixedCapacityVector< T, Capacity >::value_type

Definition at line 155 of file container.h.

## Constructor & Destructor Documentation

## FixedCapacityVector() [1/4]

template<typename T, size_t Capacity>

osl::FixedCapacityVector< T, Capacity >::FixedCapacityVector | ( |  | ) |

inline

Definition at line 159 of file container.h.

## FixedCapacityVector() [2/4]

template<typename T, size_t Capacity>

osl::FixedCapacityVector< T, Capacity >::FixedCapacityVector | ( | size_t | size | ) |

inline explicit

Definition at line 160 of file container.h.

## FixedCapacityVector() [3/4]

template<typename T, size_t Capacity>

osl::FixedCapacityVector< T, Capacity >::FixedCapacityVector | ( | FixedCapacityVector< T, Capacity > const & | rhs | ) |

inline

Definition at line 163 of file container.h.

## FixedCapacityVector() [4/4]

template<typename T, size_t Capacity>
template<class RangeIterator>

osl::FixedCapacityVector< T, Capacity >::FixedCapacityVector | ( | const RangeIterator & | first,
|  | const RangeIterator & | last )

inline

Definition at line 168 of file container.h.

## ~FixedCapacityVector()

template<typename T, size_t Capacity>

osl::FixedCapacityVector< T, Capacity >::~FixedCapacityVector | ( |  | ) |

inline

Definition at line 172 of file container.h.

## Member Function Documentation

## back() [1/2]

template<typename T, size_t Capacity>

T & osl::FixedCapacityVector< T, Capacity >::back | ( |  | ) |

inline

Definition at line 202 of file container.h.

## back() [2/2]

template<typename T, size_t Capacity>

const T & osl::FixedCapacityVector< T, Capacity >::back | ( |  | ) | const

inline

Definition at line 255 of file container.h.

## begin() [1/2]

template<typename T, size_t Capacity>

iterator osl::FixedCapacityVector< T, Capacity >::begin | ( |  | ) |

inline

Definition at line 198 of file container.h.

Referenced by osl::checkmate::CheckmateIfCapture::cannotCapture(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::clear(), osl::checkmate::Dfpn::defense(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::empty(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::erase(), osl::eval::See::findEffectPieces(), osl::eval::See::findEffectPiecesAfterMove(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::FixedCapacityVector(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::front(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::front(), osl::GenerateEscapeKing::generate(), osl::checkmate::Dfpn::generateEscape(), osl::NumEffectState::generateLegal(), osl::move_probability::StandardFeatureSet::generateLogProb2(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::isMember(), osl::operator<(), osl::operator<(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::operator=(), osl::container::operator==(), osl::operator==(), osl::rating::operator==(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::pushBackHelper(), osl::book::BookInMemory::readRecursive(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::resize(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::size(), osl::checkmate::Dfpn::sort(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::unique(), and osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::~FixedCapacityVector().

## begin() [2/2]

template<typename T, size_t Capacity>

const_iterator osl::FixedCapacityVector< T, Capacity >::begin | ( |  | ) | const

inline

Definition at line 251 of file container.h.

## capacity()

template<typename T, size_t Capacity>

size_t osl::FixedCapacityVector< T, Capacity >::capacity | ( |  | ) | const

inline

Definition at line 245 of file container.h.

Referenced by osl::book::BookInMemory::readRecursive().

## clear()

template<typename T, size_t Capacity>

void osl::FixedCapacityVector< T, Capacity >::clear | ( |  | ) |

inline

Definition at line 215 of file container.h.

Referenced by osl::effect_util::AdditionalEffect::find(), osl::eval::See::findEffectPieces(), osl::eval::See::findEffectPiecesAfterMove(), and osl::checkmate::Dfpn::proofOracleAttack().

## elements() [1/2]

template<typename T, size_t Capacity>

array_t & osl::FixedCapacityVector< T, Capacity >::elements | ( |  | ) |

inline private

Definition at line 151 of file container.h.

## elements() [2/2]

template<typename T, size_t Capacity>

const array_t & osl::FixedCapacityVector< T, Capacity >::elements | ( |  | ) | const

inline private

Definition at line 148 of file container.h.

Referenced by osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::begin(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::begin(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::clear(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::operator=(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::operator[](), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::operator[](), and osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::resize().

## empty()

template<typename T, size_t Capacity>

bool osl::FixedCapacityVector< T, Capacity >::empty | ( |  | ) | const

inline

Definition at line 244 of file container.h.

Referenced by osl::checkmate::Dfpn::attack(), osl::checkmate::CheckmateIfCapture::cannotCapture(), osl::checkmate::Dfpn::defense(), osl::effect_util::SendOffSquare::find(), osl::eval::See::findEffectPieces(), osl::eval::See::findEffectPiecesAfterMove(), osl::checkmate::Dfpn::generateCheck(), osl::checkmate::Dfpn::generateEscape(), osl::rating::FeatureSet::generateLogProb(), osl::checkmate::Dfpn::proofOracleDefense(), osl::book::BookInMemory::readRecursive(), osl::eval::See::seeInternal(), and osl::effect_util::SendOffSquare::unpack().

## end() [1/2]

template<typename T, size_t Capacity>

iterator osl::FixedCapacityVector< T, Capacity >::end | ( |  | ) |

inline

Definition at line 199 of file container.h.

Referenced by osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::back(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::back(), osl::checkmate::CheckmateIfCapture::cannotCapture(), osl::checkmate::Dfpn::defense(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::erase(), osl::eval::See::findEffectPieces(), osl::eval::See::findEffectPiecesAfterMove(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::FixedCapacityVector(), osl::GenerateEscapeKing::generate(), osl::NumEffectState::generateLegal(), osl::move_probability::StandardFeatureSet::generateLogProb2(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::isMember(), osl::operator<(), osl::operator<(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::operator=(), osl::container::operator==(), osl::operator==(), osl::rating::operator==(), push_back(), osl::book::BookInMemory::readRecursive(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::resize(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::unique(), and osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::~FixedCapacityVector().

## end() [2/2]

template<typename T, size_t Capacity>

const_iterator osl::FixedCapacityVector< T, Capacity >::end | ( |  | ) | const

inline

Definition at line 252 of file container.h.

## erase()

template<typename T, size_t Capacity>

void osl::FixedCapacityVector< T, Capacity >::erase | ( | const T & | e | ) |

inline

Definition at line 229 of file container.h.

## front() [1/2]

template<typename T, size_t Capacity>

T & osl::FixedCapacityVector< T, Capacity >::front | ( |  | ) |

inline

Definition at line 201 of file container.h.

## front() [2/2]

template<typename T, size_t Capacity>

const T & osl::FixedCapacityVector< T, Capacity >::front | ( |  | ) | const

inline

Definition at line 254 of file container.h.

## isMember() [1/2]

template<typename T, size_t Capacity>

bool osl::FixedCapacityVector< T, Capacity >::isMember | ( | const T & | e | ) | const

inline

Definition at line 260 of file container.h.

## isMember() [2/2]

template<typename T, size_t Capacity>

bool osl::FixedCapacityVector< T, Capacity >::isMember | ( | const T & | e,
|  | const_iterator | first,
|  | const_iterator | last ) const

inline

Definition at line 257 of file container.h.

Referenced by osl::rating::BradleyTerry::addSquare(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::isMember(), and osl::move_probability::AttackKing8Long::match().

## operator=()

template<typename T, size_t Capacity>

FixedCapacityVector & osl::FixedCapacityVector< T, Capacity >::operator= | ( | FixedCapacityVector< T, Capacity > const & | rhs | ) |

inline

Definition at line 175 of file container.h.

## operator[]() [1/2]

template<typename T, size_t Capacity>

T & osl::FixedCapacityVector< T, Capacity >::operator[] | ( | size_t | i | ) |

inline

Definition at line 193 of file container.h.

## operator[]() [2/2]

template<typename T, size_t Capacity>

T const & osl::FixedCapacityVector< T, Capacity >::operator[] | ( | size_t | i | ) | const

inline

Definition at line 247 of file container.h.

## pop_back()

template<typename T, size_t Capacity>

void osl::FixedCapacityVector< T, Capacity >::pop_back | ( |  | ) |

inline

Definition at line 211 of file container.h.

Referenced by osl::eval::See::computeValue(), and osl::checkmate::Dfpn::defense().

## push_back() [1/2]

template<typename T, size_t Capacity>
template<class RangeIterator>

void osl::FixedCapacityVector< T, Capacity >::push_back | ( | const RangeIterator & | first,
|  | const RangeIterator & | last )

Definition at line 282 of file container.h.

References end(), ptr, and size().

## push_back() [2/2]

template<typename T, size_t Capacity>

void osl::FixedCapacityVector< T, Capacity >::push_back | ( | const T & | e | ) |

inline

Definition at line 204 of file container.h.

Referenced by osl::eval::ml::BishopRookFork::eval(), osl::eval::ml::BishopExchangeSilverKing::evalOne(), osl::eval::ml::NonPawnAttackedPtypePair::evalOne(), osl::eval::ml::PiecePairKing::evalOne(), osl::book::BookInMemory::find(), osl::effect_util::AdditionalEffect::find(), osl::eval::See::findAdditionalPieces(), osl::eval::See::findEffectPieces(), osl::eval::See::findEffectPiecesAfterMove(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::FixedCapacityVector(), osl::GenerateEscapeKing::generate(), osl::checkmate::Dfpn::generateCheck(), osl::checkmate::Dfpn::generateEscape(), osl::move_probability::FeatureSet::generateRating(), osl::rating::FeatureSet::generateRating(), osl::NumEffectState::generateWithFullUnpromotions(), osl::move_probability::BlockLong::makeLongAttackOne(), osl::checkmate::Dfpn::proofOracleAttack(), osl::book::BookInMemory::readRecursive(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::resize(), and osl::progress::ml::NewProgress::updateNonPawnAttackedPtypePairOne().

## pushBackHelper()

template<typename T, size_t Capacity>

detail::FixedCapacityVectorPushBack< T > osl::FixedCapacityVector< T, Capacity >::pushBackHelper | ( |  | ) |

inline

Definition at line 263 of file container.h.

## resize()

template<typename T, size_t Capacity>

void osl::FixedCapacityVector< T, Capacity >::resize | ( | size_t | new_length | ) |

inline

Definition at line 221 of file container.h.

Referenced by osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::FixedCapacityVector().

## size()

template<typename T, size_t Capacity>

size_t osl::FixedCapacityVector< T, Capacity >::size | ( |  | ) | const

inline

Definition at line 243 of file container.h.

Referenced by osl::rating::BradleyTerry::addSquare(), osl::checkmate::Dfpn::analyze(), osl::checkmate::Dfpn::attack(), osl::checkmate::Dfpn::blockingSimulation(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::clear(), osl::eval::See::computeValue(), osl::effect_util::AdditionalEffect::count(), osl::checkmate::Dfpn::defense(), osl::eval::ml::BishopExchangeSilverKing::evalOne(), osl::eval::ml::BishopRookFork::evalOne(), osl::eval::ml::NonPawnAttackedPtypePair::evalOne(), osl::eval::ml::PiecePairKing::evalOne(), osl::eval::See::findEffectPieces(), osl::eval::See::findEffectPiecesAfterMove(), osl::move_probability::StateInfo::finishUpdate(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::FixedCapacityVector(), osl::GenerateEscapeKing::generate(), osl::checkmate::Dfpn::generateEscape(), osl::rating::FeatureSet::generateLogProb(), osl::move_probability::StandardFeatureSet::generateLogProb2(), osl::rating::FeatureSet::generateRating(), osl::NumEffectState::generateWithFullUnpromotions(), osl::container::operator<<(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::operator=(), osl::container::operator==(), osl::operator==(), osl::rating::operator==(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::operator[](), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::operator[](), osl::checkmate::Dfpn::proofOracleDefense(), push_back(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::push_back(), osl::book::BookInMemory::readRecursive(), osl::FixedCapacityVector< MoveLogProb, Move::MaxUniqMoves >::resize(), osl::checkmate::Dfpn::sort(), and osl::progress::ml::NewProgress::updateNonPawnAttackedPtypePairOne().

## unique()

template<typename T, size_t Capacity>

void osl::FixedCapacityVector< T, Capacity >::unique | ( |  | ) |

inline

重複する要素を取り除く

Definition at line 236 of file container.h.

## Member Data Documentation

## ptr

template<typename T, size_t Capacity>

T* osl::FixedCapacityVector< T, Capacity >::ptr

protected

Definition at line 145 of file container.h.

Referenced by push_back().

## relements

template<typename T, size_t Capacity>

CArray<int64_t, (sizeof(T[Capacity])+sizeof(int64_t)-1)/sizeof(int64_t)> osl::FixedCapacityVector< T, Capacity >::relements

protected

Definition at line 146 of file container.h.

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

- container.h