ATLAS Offline Software
Classes | Public Member Functions | Public Attributes | List of all members
columnar::ColumnarToolDataArray Struct Referencefinal

#include <ColumnarToolDataArray.h>

Collaboration diagram for columnar::ColumnarToolDataArray:

Classes

struct  StringHash
 

Public Member Functions

std::string convertInternalToUserName (std::string_view name) const
 convert a column name between user and internal names More...
 
std::vector< std::string > convertUserToInternalNames (std::string_view name) const
 

Public Attributes

ColumnarTool< ColumnarModeArray > * mainTool = nullptr
 the main tool that is associated with this object More...
 
std::vector< ColumnarTool< ColumnarModeArray > * > sharedTools
 the list of all tools that reference this object More...
 
std::unordered_map< std::string, std::string, StringHash, std::equal_to<> > containerInternalToUserNames
 the names associated with all container ids More...
 
std::unordered_map< std::string, std::vector< std::string >, StringHash, std::equal_to<> > containerUserToInternalNames
 
std::unordered_map< std::string, std::string, StringHash, std::equal_to<> > columnInternalToUserNames
 an extra map, for mapping individual column names More...
 
std::unordered_map< std::string, std::vector< std::string >, StringHash, std::equal_to<> > columnUserToInternalNames
 
std::unordered_map< std::string, ColumnDataArraycolumns
 the name-column map More...
 

Detailed Description

Definition at line 58 of file ColumnarToolDataArray.h.

Member Function Documentation

◆ convertInternalToUserName()

std::string columnar::ColumnarToolDataArray::convertInternalToUserName ( std::string_view  name) const

convert a column name between user and internal names

Definition at line 340 of file ColumnarToolArray.cxx.

342  {
343  if (name.empty())
344  return std::string{};
345  if (auto iter = columnInternalToUserNames.find (name);
347  return iter->second;
348  auto split = name.find ('.');
349  if (split == std::string::npos)
350  split = name.size();
351  auto containerName = name.substr (0, split);
352  auto iter = containerInternalToUserNames.find (containerName);
353  if (iter == containerInternalToUserNames.end())
354  return std::string (name);
355  return iter->second + std::string (name.substr (split));
356  }

◆ convertUserToInternalNames()

std::vector< std::string > columnar::ColumnarToolDataArray::convertUserToInternalNames ( std::string_view  name) const

Definition at line 360 of file ColumnarToolArray.cxx.

362  {
363  if (auto iter = columnUserToInternalNames.find (name);
365  return iter->second;
366  auto split = name.find ('.');
367  if (split == std::string::npos)
368  split = name.size();
369  auto containerName = name.substr (0, split);
370  auto iter = containerUserToInternalNames.find (containerName);
371  if (iter == containerUserToInternalNames.end())
372  return {std::string (name)};
373  std::vector<std::string> result;
374  for (auto& internalContainerName : iter->second)
375  result.push_back (internalContainerName + std::string (name.substr (split)));
376  if (result.empty())
377  result.push_back (std::string (name));
378  return result;
379  }

Member Data Documentation

◆ columnInternalToUserNames

std::unordered_map<std::string,std::string,StringHash,std::equal_to<> > columnar::ColumnarToolDataArray::columnInternalToUserNames

an extra map, for mapping individual column names

Definition at line 78 of file ColumnarToolDataArray.h.

◆ columns

std::unordered_map<std::string,ColumnDataArray> columnar::ColumnarToolDataArray::columns

the name-column map

Definition at line 82 of file ColumnarToolDataArray.h.

◆ columnUserToInternalNames

std::unordered_map<std::string,std::vector<std::string>,StringHash,std::equal_to<> > columnar::ColumnarToolDataArray::columnUserToInternalNames

Definition at line 79 of file ColumnarToolDataArray.h.

◆ containerInternalToUserNames

std::unordered_map<std::string,std::string,StringHash,std::equal_to<> > columnar::ColumnarToolDataArray::containerInternalToUserNames

the names associated with all container ids

Definition at line 74 of file ColumnarToolDataArray.h.

◆ containerUserToInternalNames

std::unordered_map<std::string,std::vector<std::string>,StringHash,std::equal_to<> > columnar::ColumnarToolDataArray::containerUserToInternalNames

Definition at line 75 of file ColumnarToolDataArray.h.

◆ mainTool

ColumnarTool<ColumnarModeArray>* columnar::ColumnarToolDataArray::mainTool = nullptr

the main tool that is associated with this object

Definition at line 68 of file ColumnarToolDataArray.h.

◆ sharedTools

std::vector<ColumnarTool<ColumnarModeArray>*> columnar::ColumnarToolDataArray::sharedTools

the list of all tools that reference this object

Definition at line 71 of file ColumnarToolDataArray.h.


The documentation for this struct was generated from the following files:
createLinkingScheme.iter
iter
Definition: createLinkingScheme.py:62
get_generator_info.result
result
Definition: get_generator_info.py:21
columnar::ColumnarToolDataArray::containerInternalToUserNames
std::unordered_map< std::string, std::string, StringHash, std::equal_to<> > containerInternalToUserNames
the names associated with all container ids
Definition: ColumnarToolDataArray.h:74
columnar::ColumnarToolDataArray::columnUserToInternalNames
std::unordered_map< std::string, std::vector< std::string >, StringHash, std::equal_to<> > columnUserToInternalNames
Definition: ColumnarToolDataArray.h:79
columnar::ColumnarToolDataArray::columnInternalToUserNames
std::unordered_map< std::string, std::string, StringHash, std::equal_to<> > columnInternalToUserNames
an extra map, for mapping individual column names
Definition: ColumnarToolDataArray.h:78
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:240
columnar::ColumnarToolDataArray::containerUserToInternalNames
std::unordered_map< std::string, std::vector< std::string >, StringHash, std::equal_to<> > containerUserToInternalNames
Definition: ColumnarToolDataArray.h:75
Trk::split
@ split
Definition: LayerMaterialProperties.h:38