当前位置: 首页>>代码示例>>C++>>正文


C++ Syntax::registerSyntaxType方法代码示例

本文整理汇总了C++中Syntax::registerSyntaxType方法的典型用法代码示例。如果您正苦于以下问题:C++ Syntax::registerSyntaxType方法的具体用法?C++ Syntax::registerSyntaxType怎么用?C++ Syntax::registerSyntaxType使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Syntax的用法示例。


在下文中一共展示了Syntax::registerSyntaxType方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: registerSyntaxTask

void
associateSyntax(Syntax & syntax, ActionFactory & action_factory)
{
  /**
   * Note: the optional third parameter is used to differentiate which task is
   * satisfied based on the syntax encountered for classes which are registered
   * to satisfy more than one task
   */
  registerSyntaxTask("CopyNodalVarsAction", "Variables/*", "check_copy_nodal_vars");
  registerSyntaxTask("CopyNodalVarsAction", "Variables/*", "copy_nodal_vars");
  registerSyntaxTask("CopyNodalVarsAction", "AuxVariables/*", "check_copy_nodal_vars");
  registerSyntaxTask("CopyNodalVarsAction", "AuxVariables/*", "copy_nodal_aux_vars");

  registerSyntaxTask("AddKernelAction", "Kernels/*", "add_kernel");
  registerSyntaxTask("AddNodalKernelAction", "NodalKernels/*", "add_nodal_kernel");
  registerSyntaxTask("AddKernelAction", "AuxKernels/*", "add_aux_kernel");
  registerSyntaxTask("AddKernelAction", "Bounds/*", "add_aux_kernel");

  registerSyntaxTask("AddScalarKernelAction", "ScalarKernels/*", "add_scalar_kernel");
  registerSyntaxTask("AddScalarKernelAction", "AuxScalarKernels/*", "add_aux_scalar_kernel");

  registerSyntaxTask("AddBCAction", "BCs/*", "add_bc");

  registerSyntax("CreateProblemAction", "Problem");
  registerSyntax("DynamicObjectRegistrationAction", "Problem");
  registerSyntax("SetupMeshAction", "Mesh");
  registerSyntax("SetupMeshCompleteAction", "Mesh");
  //  registerSyntaxTask("SetupMeshCompleteAction", "Mesh", "prepare_mesh");
  //  registerSyntaxTask("SetupMeshCompleteAction", "Mesh", "setup_mesh_complete");
  registerSyntax("CreateDisplacedProblemAction", "Mesh");
  registerSyntax("AddMeshModifierAction", "MeshModifiers/*");
  registerSyntax("AddMortarInterfaceAction", "Mesh/MortarInterfaces/*");

  registerSyntax("AddFunctionAction", "Functions/*");
  syntax.registerSyntaxType("Functions/*", "FunctionName");

  registerSyntax("GlobalParamsAction", "GlobalParams");

  registerSyntax("AddDistributionAction", "Distributions/*");
  registerSyntax("AddSamplerAction", "Samplers/*");

  registerSyntax("SetupDebugAction", "Debug");
  registerSyntax("SetupResidualDebugAction", "Debug");

  /// Variable/AuxVariable Actions
  registerSyntax("AddVariableAction", "Variables/*");
  syntax.registerSyntaxType("Variables/*", "VariableName");
  syntax.registerSyntaxType("Variables/*", "NonlinearVariableName");
  //  syntax.registerActionSyntax("AddVariableAction", "Variables/*", "add_variable");
  //  syntax.registerActionSyntax("AddVariableAction", "Variables/*", "add_ic");

  registerSyntax("AddICAction", "Variables/*/InitialCondition");

  registerSyntax("AddAuxVariableAction", "AuxVariables/*");
  syntax.registerSyntaxType("AuxVariables/*", "VariableName");
  syntax.registerSyntaxType("AuxVariables/*", "AuxVariableName");
  //  syntax.registerActionSyntax("AddAuxVariableAction", "AuxVariables/*", "add_aux_variable");
  //  syntax.registerActionSyntax("AddAuxVariableAction", "AuxVariables/*", "add_ic");

  registerSyntax("AddICAction", "AuxVariables/*/InitialCondition");

  registerSyntaxTask("EmptyAction", "BCs/Periodic", "no_action"); // placeholder
  registerSyntax("AddPeriodicBCAction", "BCs/Periodic/*");

  registerSyntaxTask("AddInitialConditionAction", "ICs/*", "add_ic");

  registerSyntax("AddMaterialAction", "Materials/*");

  registerSyntax("SetupPostprocessorDataAction", "Postprocessors/*");
  registerSyntax("AddPostprocessorAction", "Postprocessors/*");
  syntax.registerSyntaxType("Postprocessors/*", "PostprocessorName");
  syntax.registerSyntaxType("Postprocessors/*", "UserObjectName");

  registerSyntax("AddVectorPostprocessorAction", "VectorPostprocessors/*");
  syntax.registerSyntaxType("VectorPostprocessors/*", "VectorPostprocessorName");

  registerSyntax("AddDamperAction", "Dampers/*");

  registerSyntax("AddOutputAction", "Outputs/*");
  registerSyntax("CommonOutputAction", "Outputs");
  syntax.registerSyntaxType("Outputs/*", "OutputName");

  // Note: Preconditioner Actions will be built by this setup action
  registerSyntax("SetupPreconditionerAction", "Preconditioning/*");
  registerSyntax("AddFieldSplitAction", "Preconditioning/*/*");

  registerSyntax("DetermineSystemType", "Executioner");
  registerSyntax("CreateExecutionerAction", "Executioner");
  registerSyntax("SetupTimeStepperAction", "Executioner/TimeStepper");
  registerSyntax("SetupTimeIntegratorAction", "Executioner/TimeIntegrator");

  registerSyntax("SetupQuadratureAction", "Executioner/Quadrature");
  registerSyntax("SetupPredictorAction", "Executioner/Predictor");
#ifdef LIBMESH_ENABLE_AMR
  registerSyntax("AdaptivityAction", "Executioner/Adaptivity");
#endif

  registerSyntax("PartitionerAction", "Mesh/Partitioner");

  registerSyntax("AddDiracKernelAction", "DiracKernels/*");
//.........这里部分代码省略.........
开发者ID:aeslaughter,项目名称:moose,代码行数:101,代码来源:MooseSyntax.C


注:本文中的Syntax::registerSyntaxType方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。