Ultra 0.9.4
Loading...
Searching...
No Matches
ultra::gp::exon_view Class Reference

#include <individual.h>

Inheritance diagram for ultra::gp::exon_view:

Public Types

using iterator = internal::basic_exon_iterator<false>
 Iterator type iterating over mutable active genes.
using sentinel = std::default_sentinel_t
 Sentinel marking the end of the exon traversal.

Public Member Functions

 exon_view (gp::individual &ind) noexcept
iterator begin () const
sentinel end () const noexcept

Detailed Description

A view over the active genes (exons) of an individual.

This view exposes only the genes that are reachable from the individual's output locus, following argument dependencies. The view models a std::ranges::input_range:

  • iteration is single-pass;
  • copying iterators does not guarantee independent traversal;
  • no size is known in advance.
Remarks
The underlying individual must outlive the view.

Constructor & Destructor Documentation

◆ exon_view()

ultra::gp::exon_view::exon_view ( gp::individual & ind)
inlineexplicitnoexcept

Constructs a view over the active genes of an individual.

Parameters
[in]indThe individual whose exons will be iterated.

Member Function Documentation

◆ begin()

iterator ultra::gp::exon_view::begin ( ) const
inlinenodiscard
Returns
an input iterator positioned at the first exon

◆ end()

sentinel ultra::gp::exon_view::end ( ) const
inlinenodiscardnoexcept
Returns
a sentinel representing the end of the exon range

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