Rosetta 3.3

#include <FixedSizeLexicographicalIterator.hh>
Public Types  
typedef platform::Size  Size 
typedef fixedsizearray1< Size, S >  fsarray 
Public Member Functions  
FixedSizeLexicographicalIterator ()  
default constructor  requires that set_dimension_sizes later be called. or the default alphabet (size 0).  
FixedSizeLexicographicalIterator (fsarray const &dim_sizes)  
Constructor with dimension sizes.  
void  set_dimension_sizes (fsarray const &dim_sizes) 
Set the dimension sizes; resets the curr_pos_ to the beginning of the enumeration.  
void  begin () 
reset the iterator to the beginning string (1,1,1,...)  
bool  at_end () const 
Is the iterator at the end?  
Size  operator++ () 
Increment the iterator and return the number of dimensions that were advanced. the number of advanced dimensions ranges from 0 to ndims. 0 is returned only if the iterator is at the end.  
Size  size () const 
The number of dimensions.  
Size  ndims () const 
The number of dimensions.  
Size  operator[] (Size dim) const 
Access the ith dimension (from mostsignificant digit to least). If the iterator pointed to the string "MACE", then dimension "2" refers to the position holding "A". Unsigned dimension input.  
Size  dimsize (Size dim) const 
Size  index () const 
Give an integer index of the current state. This can be used to reset the lexicographical iterator to the current state again later.  
void  set_position_from_index (Size index) 
Set the state of the lexicographical iterator using a particular index.  
Size  continue_at_dimension (Size dim) 
Advance the nth dimension to its next value and reset the higher dimensions to their initial values. E.g. If there were four dimensions of size 5, and the current state was [ 1, 3, 2, 4 ], then continue_at_dimension( 2 ) would result in the state [ 1, 4, 1, 1 ], and if the state were [ 1, 5, 2, 3 ], then continue_at_dimension( 2 ) would result in the state [ 2, 1, 1, 1 ]. Returns the number of dimensions that were advanced (0 if at_end, but otherwise, >= dim)  
Size  num_states_total () const 
Returns the number of states that could be enumerated. 
typedef fixedsizearray1< Size, S > utility::FixedSizeLexicographicalIterator< S >::fsarray 
typedef platform::Size utility::FixedSizeLexicographicalIterator< S >::Size 
utility::FixedSizeLexicographicalIterator< S >::FixedSizeLexicographicalIterator  (  ) 
default constructor  requires that set_dimension_sizes later be called. or the default alphabet (size 0).
 fake that there's one alphabet and that it has size 0.
utility::FixedSizeLexicographicalIterator< S >::FixedSizeLexicographicalIterator  (  fsarray const &  dim_sizes  ) 
bool utility::FixedSizeLexicographicalIterator< S >::at_end  (  )  const 
Is the iterator at the end?
both curr_pos_ and dim_sizes_ must have size greater than 0. Therefore, even the empty set of alphabets (used by the default ctor) must contain 1 alphabet.
void utility::FixedSizeLexicographicalIterator< S >::begin  (  ) 
reset the iterator to the beginning string (1,1,1,...)
First element is the 1 string
FixedSizeLexicographicalIterator< S >::Size utility::FixedSizeLexicographicalIterator< S >::continue_at_dimension  (  Size  dim  ) 
Advance the nth dimension to its next value and reset the higher dimensions to their initial values. E.g. If there were four dimensions of size 5, and the current state was [ 1, 3, 2, 4 ], then continue_at_dimension( 2 ) would result in the state [ 1, 4, 1, 1 ], and if the state were [ 1, 5, 2, 3 ], then continue_at_dimension( 2 ) would result in the state [ 2, 1, 1, 1 ]. Returns the number of dimensions that were advanced (0 if at_end, but otherwise, >= dim)
set the higher dimensions to their maximum values, and simply invoke the ++operator which will handle the logic of rolling over lower dimensions if the nth dimension is at its maximum value.
References test::T200_Scoring::ii.
Size utility::FixedSizeLexicographicalIterator< S >::dimsize  (  Size  dim  )  const [inline] 
FixedSizeLexicographicalIterator< S >::Size utility::FixedSizeLexicographicalIterator< S >::index  (  )  const 
Give an integer index of the current state. This can be used to reset the lexicographical iterator to the current state again later.
References test::T200_Scoring::ii.
Size utility::FixedSizeLexicographicalIterator< S >::ndims  (  )  const [inline] 
The number of dimensions.
References utility::FixedSizeLexicographicalIterator< S >::size().
FixedSizeLexicographicalIterator< S >::Size utility::FixedSizeLexicographicalIterator< S >::num_states_total  (  )  const 
Returns the number of states that could be enumerated.
References test::T200_Scoring::ii.
FixedSizeLexicographicalIterator< S >::Size utility::FixedSizeLexicographicalIterator< S >::operator++  (  ) 
Increment the iterator and return the number of dimensions that were advanced. the number of advanced dimensions ranges from 0 to ndims. 0 is returned only if the iterator is at the end.
Return the number of dimensions advanced by the increment operator so that an outside observer can track the progress of the iterator
References test::T200_Scoring::ii.
Size utility::FixedSizeLexicographicalIterator< S >::operator[]  (  Size  dim  )  const [inline] 
Access the ith dimension (from mostsignificant digit to least). If the iterator pointed to the string "MACE", then dimension "2" refers to the position holding "A". Unsigned dimension input.
void utility::FixedSizeLexicographicalIterator< S >::set_dimension_sizes  (  fsarray const &  dim_sizes  ) 
Set the dimension sizes; resets the curr_pos_ to the beginning of the enumeration.
References begin, and test::T200_Scoring::ii.
void utility::FixedSizeLexicographicalIterator< S >::set_position_from_index  (  Size  index  ) 
Set the state of the lexicographical iterator using a particular index.
No requirement that the index doesn't "overflow" the iterator; however, if it should overflow, then at_end() will return true.
References test::T200_Scoring::ii, and ObjexxFCL::index().
Size utility::FixedSizeLexicographicalIterator< S >::size  (  )  const [inline] 
The number of dimensions.
References utility::fixedsizearray1< T, S >::size().
Referenced by utility::FixedSizeLexicographicalIterator< S >::ndims().