*/
void move_backward ();
- friend class InverseConstnessIterator;
+ /**
+ * Make all other iterators
+ * friend, i.e. including the
+ * one with opposite constness.
+ */
+ template <class N, bool B>
+ friend class Iterator<N,B>;
};
};
unsigned int num_blocks;
/**
- * Make the iterator class a
- * friend.
+ * Make the iterator classes
+ * friends.
*/
- friend class iterator;
- friend class const_iterator;
+ template <typename T1, bool B>
+ friend class BlockVectorIterators::Iterator<T1,B>;
template <typename Number2> friend class BlockVector;
};
index_within_block (c.index_within_block),
next_break_forward (c.next_break_forward),
next_break_backward (c.next_break_backward)
- {};
+ {}
// to cast away the
// constness. disallow this
Assert (constness==true, ExcCastingAwayConstness());
- };
+ }
next_break_forward (next_break_forward),
next_break_backward (next_break_backward)
{
- };
+ }
next_break_backward = c.next_break_backward;
return *this;
- };
+ }
// reference to a temporary
reference p = parent->block(current_block)(index_within_block);
return p;
- };
+ }
// reference to a temporary
reference p = parent->block(current_block)(index_within_block);
return &p;
- };
+ }
// class as well.
reference p = (*parent)(global_index+d);
return p;
- };
+ }
{
move_forward ();
return *this;
- };
+ }
const Iterator old_value = *this;
move_forward ();
return old_value;
- };
+ }
{
move_backward ();
return *this;
- };
+ }
const Iterator old_value = *this;
move_backward ();
return old_value;
- };
+ }
Assert (parent == i.parent, ExcPointerToDifferentVectors());
return (global_index == i.global_index);
- };
+ }
Assert (parent == i.parent, ExcPointerToDifferentVectors());
return (global_index == i.global_index);
- };
+ }
Assert (parent == i.parent, ExcPointerToDifferentVectors());
return (global_index != i.global_index);
- };
+ }
Assert (parent == i.parent, ExcPointerToDifferentVectors());
return (global_index != i.global_index);
- };
+ }
Assert (parent == i.parent, ExcPointerToDifferentVectors());
return (global_index < i.global_index);
- };
+ }
Assert (parent == i.parent, ExcPointerToDifferentVectors());
return (global_index < i.global_index);
- };
+ }
Assert (parent == i.parent, ExcPointerToDifferentVectors());
return (global_index <= i.global_index);
- };
+ }
Assert (parent == i.parent, ExcPointerToDifferentVectors());
return (global_index <= i.global_index);
- };
+ }
Assert (parent == i.parent, ExcPointerToDifferentVectors());
return (global_index > i.global_index);
- };
+ }
Assert (parent == i.parent, ExcPointerToDifferentVectors());
return (global_index > i.global_index);
- };
+ }
Assert (parent == i.parent, ExcPointerToDifferentVectors());
return (global_index >= i.global_index);
- };
-
+ }
+
template <typename number, bool constness>
Assert (parent == i.parent, ExcPointerToDifferentVectors());
return (global_index >= i.global_index);
- };
+ }
return (static_cast<signed int>(global_index) -
static_cast<signed int>(i.global_index));
- };
+ }
return (static_cast<signed int>(global_index) -
static_cast<signed int>(i.global_index));
- };
+ }
// have to seek new block
// anyway
return Iterator (*parent, global_index+d);
- };
+ }
// have to seek new block
// anyway
return Iterator (*parent, global_index-d);
- };
+ }
*this = Iterator (*parent, global_index+d);
return *this;
- };
+ }
*this = Iterator (*parent, global_index-d);
return *this;
- };
+ }
};