Ejemplo n.º 1
0
// オブジェクト情報を表示する
void DebugPrintObjectInfo(UINT id)
{
    UINT i;
    TRACKING_OBJECT *o;

    // 検索
    o = NULL;
    LockTrackingList();
    {
        for (i = 0; i < TRACKING_NUM_ARRAY; i++)
        {
            if (hashlist[i] != NULL)
            {
                TRACKING_LIST *t = hashlist[i];

                while (true)
                {
                    if (t->Object->Id == id)
                    {
                        o = t->Object;
                        break;
                    }

                    if (t->Next == NULL)
                    {
                        break;
                    }

                    t = t->Next;
                }

                if (o != NULL)
                {
                    break;
                }
            }
        }
    }
    UnlockTrackingList();

    if (o == NULL)
    {
        // ID が発見できなかった
        Print("obj_id %u Not Found.\n\n", id);
        return;
    }

    PrintObjectInfo(o);
    Print("\n");
}
Ejemplo n.º 2
0
INT wmain(INT argc, WCHAR **argv)
{
	po::variables_map variables_map;
	printInfoStruct stPrintInfo;
	if (!ParseArguments(argc, argv, variables_map, stPrintInfo))
		return 3;

	if (variables_map.count("print-objects")) {
		PrintObjects();
		return 0;
	}

	if (variables_map.count("print-object-info")) {
		PrintObjectInfo(stPrintInfo);
		return 0;
	}

	if (QueryPerfData(stPrintInfo))
		return PrintOutput(variables_map, stPrintInfo);
	else
		return 3;
}
CollectionPtr HLTriggerObjectCollectionHelper::GetL3FilterObjectsByPath ( const char * path_name, bool verbose ){
  CollectionPtr collection ( new Collection ( *m_data, 0));

  std::vector<unsigned short> matchingHLTriggerRawIndices;
  // first, look at each object in the HLTriggerObj collection
  for (unsigned short i = 0; i < m_data->HLTriggerObjPt->size() ; ++i)
  {
    if(verbose)
      PrintObjectInfo(i);

    short pathIndex = IndexOfAssociatedPath(path_name, i);
    if(pathIndex > -1)
    {
      // if it is associated to a path, check to see if it passed an L3 filter in the path
      if(m_data->HLTriggerObjPassedPathL3Filter->at(i).at(pathIndex))
        matchingHLTriggerRawIndices.push_back(i); // keep raw index of trigObj
    }

  }
  collection->SetRawIndices(matchingHLTriggerRawIndices);
  
  return collection;
}