text: /**
  	* \file PnlBrlyRlyHeadbar_blks.cpp
  	* job handler for job PnlBrlyRlyHeadbar (implementation of blocks)
  	* \copyright (C) 2016-2020 MPSI Technologies GmbH
  	* \author Alexander Wirthmueller (auto-generation)
  	* \date created: 11 Jan 2021
  	*/
  // IP header --- ABOVE
  
  using namespace std;
  using namespace Sbecore;
  using namespace Xmlio;
  
  /******************************************************************************
   class PnlBrlyRlyHeadbar::StgInf
   ******************************************************************************/
  
  void PnlBrlyRlyHeadbar::StgInf::writeXML(
  			const uint ixBrlyVLocale
  			, xmlTextWriter* wr
  			, string difftag
  			, bool shorttags
  		) {
  	if (difftag.length() == 0) difftag = "StgInfBrlyRlyHeadbar";
  
  	string itemtag;
  	if (shorttags) itemtag = "Si";
  	else itemtag = "StgitemInfBrlyRlyHeadbar";
  
  	xmlTextWriterStartElement(wr, BAD_CAST difftag.c_str());
  		if (ixBrlyVLocale == VecBrlyVLocale::ENUS) {
  			writeStringAttr(wr, itemtag, "sref", "MenAppCptwidth", "100");
  			writeStringAttr(wr, itemtag, "sref", "MenAppWidth", "176");
  			writeStringAttr(wr, itemtag, "sref", "MenCrdCptwidth", "55");
  			writeStringAttr(wr, itemtag, "sref", "MenCrdWidth", "323");
  		} else if (ixBrlyVLocale == VecBrlyVLocale::DECH) {
  			writeStringAttr(wr, itemtag, "sref", "MenAppCptwidth", "100");
  			writeStringAttr(wr, itemtag, "sref", "MenAppWidth", "176");
  			writeStringAttr(wr, itemtag, "sref", "MenCrdCptwidth", "154");
  			writeStringAttr(wr, itemtag, "sref", "MenCrdWidth", "323");
  		};
  	xmlTextWriterEndElement(wr);
  };
  
  /******************************************************************************
   class PnlBrlyRlyHeadbar::Tag
   ******************************************************************************/
  
  void PnlBrlyRlyHeadbar::Tag::writeXML(
  			const uint ixBrlyVLocale
  			, xmlTextWriter* wr
  			, string difftag
  			, bool shorttags
  		) {
  	if (difftag.length() == 0) difftag = "TagBrlyRlyHeadbar";
  
  	string itemtag;
  	if (shorttags) itemtag = "Ti";
  	else itemtag = "TagitemBrlyRlyHeadbar";
  
  	xmlTextWriterStartElement(wr, BAD_CAST difftag.c_str());
  		if (ixBrlyVLocale == VecBrlyVLocale::ENUS) {
  			writeStringAttr(wr, itemtag, "sref", "MenApp", "BeamRelay");
  			writeStringAttr(wr, itemtag, "sref", "MenCrd", "Relay");
  		} else if (ixBrlyVLocale == VecBrlyVLocale::DECH) {
  			writeStringAttr(wr, itemtag, "sref", "MenApp", "BeamRelay");
  			writeStringAttr(wr, itemtag, "sref", "MenCrd", "Verbindungskette");
  		};
  	xmlTextWriterEndElement(wr);
  };
  
  /******************************************************************************
   class PnlBrlyRlyHeadbar::DpchEngData
   ******************************************************************************/
  
  PnlBrlyRlyHeadbar::DpchEngData::DpchEngData(
  			const ubigint jref
  			, const set<uint>& mask
  		) :
  			DpchEngBrly(VecBrlyVDpch::DPCHENGBRLYRLYHEADBARDATA, jref)
  		{
  	if (find(mask, ALL)) this->mask = {JREF, STGINF, TAG};
  	else this->mask = mask;
  
  };
  
  string PnlBrlyRlyHeadbar::DpchEngData::getSrefsMask() {
  	vector<string> ss;
  	string srefs;
  
  	if (has(JREF)) ss.push_back("jref");
  	if (has(STGINF)) ss.push_back("stginf");
  	if (has(TAG)) ss.push_back("tag");
  
  	StrMod::vectorToString(ss, srefs);
  
  	return(srefs);
  };
  
  void PnlBrlyRlyHeadbar::DpchEngData::merge(
  			DpchEngBrly* dpcheng
  		) {
  	DpchEngData* src = (DpchEngData*) dpcheng;
  
  	if (src->has(JREF)) {jref = src->jref; add(JREF);};
  	if (src->has(STGINF)) add(STGINF);
  	if (src->has(TAG)) add(TAG);
  };
  
  void PnlBrlyRlyHeadbar::DpchEngData::writeXML(
  			const uint ixBrlyVLocale
  			, xmlTextWriter* wr
  		) {
  	xmlTextWriterStartElement(wr, BAD_CAST "DpchEngBrlyRlyHeadbarData");
  	xmlTextWriterWriteAttribute(wr, BAD_CAST "xmlns", BAD_CAST "http://www.mpsitech.com/brly");
  		if (has(JREF)) writeString(wr, "scrJref", Scr::scramble(jref));
  		if (has(STGINF)) StgInf::writeXML(ixBrlyVLocale, wr);
  		if (has(TAG)) Tag::writeXML(ixBrlyVLocale, wr);
  	xmlTextWriterEndElement(wr);
  };
  