コード例 #1
0
void
ActionWarehouse::executeActionsWithAction(const std::string & task)
{
  // Set the current task name
  _current_task = task;

  for (ActionIterator act_iter = actionBlocksWithActionBegin(task);
       act_iter != actionBlocksWithActionEnd(task);
       ++act_iter)
  {
    if (_show_actions)
    {
      _console << "[DBG][ACT] "
               << "TASK (" << COLOR_YELLOW << std::setw (24) << task << COLOR_DEFAULT << ") "
               << "TYPE (" << COLOR_YELLOW << std::setw (32) << (*act_iter)->type() << COLOR_DEFAULT << ") "
               << "NAME (" << COLOR_YELLOW << std::setw (16) << (*act_iter)->getShortName() << COLOR_DEFAULT << ") ";

      MemData mcount;
      mcount.start();
      (*act_iter)->act();
      mcount.stop();

      _console << "MEM (" << COLOR_YELLOW << mcount.delta() << "kB" << COLOR_DEFAULT << ")"<< std::endl;
    }
    else
      (*act_iter)->act();
  }
}
コード例 #2
0
ファイル: ActionWarehouse.C プロジェクト: shoheiogawa/moose
void
ActionWarehouse::executeActionsWithAction(const std::string & task)
{
  // Set the current task name
  _current_task = task;

  for (_act_iter = actionBlocksWithActionBegin(task); _act_iter != actionBlocksWithActionEnd(task);
       ++_act_iter)
  {
    if (_show_actions)
    {
      Moose::perf_log.push(task + ":" + (*_act_iter)->name(), "Setup");
      _console << "[DBG][ACT] "
               << "TASK (" << COLOR_YELLOW << std::setw(24) << task << COLOR_DEFAULT << ") "
               << "TYPE (" << COLOR_YELLOW << std::setw(32) << (*_act_iter)->type() << COLOR_DEFAULT
               << ") "
               << "NAME (" << COLOR_YELLOW << std::setw(16) << (*_act_iter)->name() << COLOR_DEFAULT
               << ")" << std::endl;

      (*_act_iter)->act();
      Moose::perf_log.pop(task + ":" + (*_act_iter)->name(), "Setup");
    }
    else
      (*_act_iter)->act();
  }
}
コード例 #3
0
ファイル: ActionWarehouse.C プロジェクト: Jieun2/moose
void
ActionWarehouse::executeActionsWithAction(const std::string & task)
{
  for (ActionIterator act_iter = actionBlocksWithActionBegin(task);
       act_iter != actionBlocksWithActionEnd(task);
       ++act_iter)
  {
    if (_show_actions)
      Moose::out << "[DBG][ACT] " << (*act_iter)->type() << " (" << YELLOW << task << COLOR_DEFAULT << ")"  << std::endl;
    (*act_iter)->act();
  }
}