*/
bool has_children () const;
+ /**
+ * Return the number of
+ * children of this cell.
+ */
+ unsigned int n_children() const;
+
/**
* Number of times that this
* object is refined. Note that
*/
bool has_children () const;
+ /**
+ * Return the number of
+ * children of this cell.
+ */
+ unsigned int n_children() const;
+
/**
* Return the number of times
* that this cell is
*/
bool has_children () const;
+ /**
+ * Return the number of
+ * children of this cell.
+ */
+ unsigned int n_children() const;
+
/**
* Return the number of times
* that this cell is
*/
bool has_children () const;
+ /**
+ * Return the number of
+ * children of this cell.
+ */
+ unsigned int n_children() const;
+
/**
* Return the number of times
* that this cell is
// $Id$
// Version: $Name$
//
-// Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005 by the deal.II authors
+// Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006 by the deal.II authors
//
// This file is subject to QPL and may not be distributed
// without copyright and license information. Please refer
}
+template <int dim>
+inline
+unsigned int
+TriaObjectAccessor<1,dim>::n_children () const
+{
+ Assert (this->state() == IteratorState::valid,
+ typename TriaAccessor<dim>::ExcDereferenceInvalidObject());
+ // a line has always 2 children
+ return has_children() ? 2 : 0;
+}
+
template <int dim>
inline
}
+template <int dim>
+inline
+unsigned int
+TriaObjectAccessor<2,dim>::n_children () const
+{
+ Assert (this->state() == IteratorState::valid,
+ typename TriaAccessor<dim>::ExcDereferenceInvalidObject());
+ // a quad has always 4 children
+ return has_children() ? 4 : 0;
+}
+
+
template <int dim>
inline
template <int dim>
-bool TriaObjectAccessor<3,dim>::has_children () const
+inline
+bool
+TriaObjectAccessor<3,dim>::has_children () const
{
Assert (this->state() == IteratorState::valid,
typename TriaAccessor<dim>::ExcDereferenceInvalidObject());
}
+template <int dim>
+inline
+unsigned int
+TriaObjectAccessor<3,dim>::n_children () const
+{
+ Assert (this->state() == IteratorState::valid,
+ typename TriaAccessor<dim>::ExcDereferenceInvalidObject());
+ // a hex has always 8 children
+ return has_children() ? 8 : 0;
+}
+
template <int dim>
inline