libmesh解析
本工作只是尝试解析原libmesh的代码,供学习使用
 全部  命名空间 文件 函数 变量 类型定义 枚举 枚举值 友元 
Public 类型 | Public 成员函数 | Public 属性 | 所有成员列表
variant_filter_iterator< Predicate, Type, ReferenceType, PointerType, ConstType, ConstReferenceType, ConstPointerType >::Pred< IterType, PredType > 模板结构体 参考

The actual predicate is held as a template parameter here. 更多...

#include <variant_filter_iterator.h>

类 variant_filter_iterator< Predicate, Type, ReferenceType, PointerType, ConstType, ConstReferenceType, ConstPointerType >::Pred< IterType, PredType > 继承关系图:
[图例]

Public 类型

typedef
variant_filter_iterator
< Predicate, ConstType,
ConstReferenceType,
ConstPointerType >::PredBase 
const_PredBase
 

Public 成员函数

 Pred (const PredType &v)
 Constructor. 更多...
 
virtual ~Pred ()=default
 Destructor. 更多...
 
virtual std::unique_ptr< PredBaseclone () const override
 
virtual std::unique_ptr
< typename
PredBase::const_PredBase
const_clone () const override
 The redefinition of the const_clone function for the Pred class. 更多...
 
virtual bool operator() (const std::unique_ptr< IterBase > &in) const override
 Re-implementation of op() 更多...
 

Public 属性

PredType pred_data
 This is the predicate passed in by the user. 更多...
 

详细描述

template<class Predicate, class Type, class ReferenceType = Type &, class PointerType = Type *, class ConstType = const Type, class ConstReferenceType = const Type &, class ConstPointerType = const Type *>
template<typename IterType, typename PredType>
struct variant_filter_iterator< Predicate, Type, ReferenceType, PointerType, ConstType, ConstReferenceType, ConstPointerType >::Pred< IterType, PredType >

The actual predicate is held as a template parameter here.

There are two template arguments here, one for the actual type of the predicate and one for the iterator type.

在文件 variant_filter_iterator.h238 行定义.

成员类型定义说明

template<class Predicate, class Type, class ReferenceType = Type &, class PointerType = Type *, class ConstType = const Type, class ConstReferenceType = const Type &, class ConstPointerType = const Type *>
typedef variant_filter_iterator<Predicate, ConstType, ConstReferenceType, ConstPointerType>::PredBase variant_filter_iterator< Predicate, Type, ReferenceType, PointerType, ConstType, ConstReferenceType, ConstPointerType >::PredBase::const_PredBase
inherited

在文件 variant_filter_iterator.h118 行定义.

构造及析构函数说明

template<class Predicate, class Type, class ReferenceType = Type &, class PointerType = Type *, class ConstType = const Type, class ConstReferenceType = const Type &, class ConstPointerType = const Type *>
template<typename IterType , typename PredType >
variant_filter_iterator< Predicate, Type, ReferenceType, PointerType, ConstType, ConstReferenceType, ConstPointerType >::Pred< IterType, PredType >::Pred ( const PredType &  v)
inline

Constructor.

在文件 variant_filter_iterator.h243 行定义.

243  :
244  pred_data (v) {}
PredType pred_data
This is the predicate passed in by the user.
template<class Predicate, class Type, class ReferenceType = Type &, class PointerType = Type *, class ConstType = const Type, class ConstReferenceType = const Type &, class ConstPointerType = const Type *>
template<typename IterType , typename PredType >
virtual variant_filter_iterator< Predicate, Type, ReferenceType, PointerType, ConstType, ConstReferenceType, ConstPointerType >::Pred< IterType, PredType >::~Pred ( )
virtualdefault

Destructor.

成员函数说明

template<class Predicate, class Type, class ReferenceType = Type &, class PointerType = Type *, class ConstType = const Type, class ConstReferenceType = const Type &, class ConstPointerType = const Type *>
template<typename IterType , typename PredType >
virtual std::unique_ptr<PredBase> variant_filter_iterator< Predicate, Type, ReferenceType, PointerType, ConstType, ConstReferenceType, ConstPointerType >::Pred< IterType, PredType >::clone ( ) const
inlineoverridevirtual
template<class Predicate, class Type, class ReferenceType = Type &, class PointerType = Type *, class ConstType = const Type, class ConstReferenceType = const Type &, class ConstPointerType = const Type *>
template<typename IterType , typename PredType >
virtual std::unique_ptr<typename PredBase::const_PredBase> variant_filter_iterator< Predicate, Type, ReferenceType, PointerType, ConstType, ConstReferenceType, ConstPointerType >::Pred< IterType, PredType >::const_clone ( ) const
inlineoverridevirtual

The redefinition of the const_clone function for the Pred class.

实现了 variant_filter_iterator< Predicate, Type, ReferenceType, PointerType, ConstType, ConstReferenceType, ConstPointerType >::PredBase.

在文件 variant_filter_iterator.h262 行定义.

参考 variant_filter_iterator< Predicate, Type, ReferenceType, PointerType, ConstType, ConstReferenceType, ConstPointerType >::Pred< IterType, PredType >::pred_data.

263  {
265  return std::make_unique<const_Pred>(pred_data);
266  }
Original Authors: Corwin Joy * Michael Gradman cjoy@houston.rr.com * Michael.Gradman@caminus.com Caminus, Suite 1150, Two Allen Center, 1200 Smith Street, Houston, TX 77002 This class is an extension of variant_bidirectional_iterator to a filter_iterator similar to boost&#39;s.
PredType pred_data
This is the predicate passed in by the user.
template<class Predicate, class Type, class ReferenceType = Type &, class PointerType = Type *, class ConstType = const Type, class ConstReferenceType = const Type &, class ConstPointerType = const Type *>
template<typename IterType , typename PredType >
virtual bool variant_filter_iterator< Predicate, Type, ReferenceType, PointerType, ConstType, ConstReferenceType, ConstPointerType >::Pred< IterType, PredType >::operator() ( const std::unique_ptr< IterBase > &  in) const
inlineoverridevirtual

Re-implementation of op()

实现了 variant_filter_iterator< Predicate, Type, ReferenceType, PointerType, ConstType, ConstReferenceType, ConstPointerType >::PredBase.

在文件 variant_filter_iterator.h271 行定义.

参考 variant_filter_iterator< Predicate, Type, ReferenceType, PointerType, ConstType, ConstReferenceType, ConstPointerType >::Iter< IterType >::iter_data , 以及 variant_filter_iterator< Predicate, Type, ReferenceType, PointerType, ConstType, ConstReferenceType, ConstPointerType >::Pred< IterType, PredType >::pred_data.

272  {
273  libmesh_assert(in);
274 
275  // Attempt downcast
276  const Iter<IterType> * p =
277  libMesh::cast_ptr<const Iter<IterType> *>(in.get());
278 
279  // Return result of op() for the user's predicate.
280  return pred_data(p->iter_data);
281  }
PredType pred_data
This is the predicate passed in by the user.

类成员变量说明

template<class Predicate, class Type, class ReferenceType = Type &, class PointerType = Type *, class ConstType = const Type, class ConstReferenceType = const Type &, class ConstPointerType = const Type *>
template<typename IterType , typename PredType >
PredType variant_filter_iterator< Predicate, Type, ReferenceType, PointerType, ConstType, ConstReferenceType, ConstPointerType >::Pred< IterType, PredType >::pred_data

该结构体的文档由以下文件生成: