00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011 #include "otsdaq-core/ConfigurationDataFormats/ViewRegisterInfo.h"
00012
00013 using namespace ots;
00014
00015
00016
00017 ViewRegisterInfo::ViewRegisterInfo(std::string typeName, std::string registerName, std::string baseAddress, int size, std::string access)
00018 {
00019 dataTable_.push_back(typeName),
00020 dataTable_.push_back(registerName),
00021 dataTable_.push_back(baseAddress),
00022 dataTable_.push_back(std::to_string(size)),
00023 dataTable_.push_back(access);
00024 }
00025
00026
00027 ViewRegisterInfo::~ViewRegisterInfo(void)
00028 {
00029 }
00030
00031
00032 const std::string& ViewRegisterInfo::getTypeName(void) const
00033 {
00034 return dataTable_.at(typeName_);
00035 }
00036
00037
00038 const std::string& ViewRegisterInfo::getRegisterName(void) const
00039 {
00040 return dataTable_.at(registerName_);
00041 }
00042
00043 const std::string& ViewRegisterInfo::getBaseAddress(void) const
00044 {
00045 return dataTable_.at(baseAddress_);
00046 }
00047
00048 const int ViewRegisterInfo::getSize(void) const
00049 {
00050 return std::stoi(dataTable_.at(size_));
00051 }
00052
00053 const std::string& ViewRegisterInfo::getAccess(void) const
00054 {
00055 return dataTable_.at(access_);
00056 }
00057
00058 const int ViewRegisterInfo::getNumberOfColumns(void) const{
00059 return dataTable_.size();
00060 }
00061
00062