File head_complete.hpp

template<typename ScoreType>
class CompleteHead : public VectorDecorator<AllocatedVector<ScoreType>>, public IHead
#include <head_complete.hpp>

A head that contains a numerical score for each available output.

Template Parameters:

ScoreType – The type of the numerical scores

Public Types

using value_iterator = View<ScoreType>::iterator

An iterator that provides access to the scores the are contained by the head and allows to modify them.

using value_const_iterator = View<ScoreType>::const_iterator

An iterator that provides read-only access to the scores that are contained by the head.

Public Functions

inline CompleteHead(uint32 numElements)
Parameters:

numElements – The number of scores that are contained by the head.

inline value_iterator values_begin()

Returns a value_iterator to the beginning of the scores that are contained by the head.

Returns:

A value_iterator to the beginning

inline value_iterator values_end()

Returns a value_iterator to the end of the scores that are contained by the head.

Returns:

A value_iterator to the end

inline value_const_iterator values_cbegin() const

Returns a value_const_iterator to the beginning of the scores that are contained by the head.

Returns:

A value_const_iterator to the beginning

inline value_const_iterator values_cend() const

Returns a value_const_iterator to the end of the scores that are contained by the head.

Returns:

A value_const_iterator to the end

inline virtual void visit(CompleteHeadVisitor<uint8> completeBinaryHeadVisitor, CompleteHeadVisitor<float32> complete32BitHeadVisitor, CompleteHeadVisitor<float64> complete64BitHeadVisitor, PartialHeadVisitor<uint8> partialBinaryHeadVisitor, PartialHeadVisitor<float32> partial32BitHeadVisitor, PartialHeadVisitor<float64> partial64BitHeadVisitor) const override

Invokes one of the given visitor functions, depending on which one is able to handle this particular type of head.

Parameters:
  • completeBinaryHeadVisitor – A visitor function for handling objects of the type CompleteHead<uint8>

  • complete32BitHeadVisitor – A visitor function for handling objects of the type CompleteHead<float32>

  • complete64BitHeadVisitor – A visitor function for handling objects of the type CompleteHead<float64>

  • partialBinaryHeadVisitor – A visitor function for handling objects of the type PartialHead<uint8>

  • partial32BitHeadVisitor – A visitor function for handling objects of the type PartialHead<float32>

  • partial64BitHeadVisitor – A visitor function for handling objects of the type PartialHead<float64>