8 #ifndef __VRV_EXPANSION_MAP_H__
9 #define __VRV_EXPANSION_MAP_H__
15 #include "expansion.h"
49 xsdAnyURI_List &deletionList,
bool deleteList);
51 std::vector<std::string> GetExpansionIDsForElement(
const std::string &xmlId);
67 void SetProcessed(
bool isProcessed) { m_isProcessed = isProcessed; }
68 bool IsProcessed() {
return m_isProcessed; }
79 static bool IsRepeatStart(Measure *measure);
80 static bool IsRepeatEnd(Measure *measure);
81 static bool IsNextRepeatStart(Measure *measure);
82 static bool IsPreviousRepeatEnd(Measure *measure);
86 bool UpdateIDs(Object *
object);
88 void GetIDList(Object *
object, std::vector<std::string> &idList);
90 void GeneratePredictableIDs(Object *source, Object *target);
93 bool AddExpandedIDToExpansionMap(
const std::string &origXmlId, std::string newXmlId);
95 std::string CreateSection(
96 Section *section,
const ListOfObjects::iterator &first,
const ListOfObjects::iterator &last);
100 std::map<std::string, std::vector<std::string>>
m_map;
This class represents a MEI expansion.
Definition: expansion.h:26
Definition: expansionmap.h:23
void GenerateExpansionFor(Score *score)
Generate an expan for the score analysing the repeats and endings.
std::map< std::string, std::vector< std::string > > m_map
The expansion map indicates which xmlId has been repeated (expanded) elsewhere.
Definition: expansionmap.h:100
void ToJson(std::string &output)
Write the currentexpansionMap to a JSON string.
Object * Expand(Expansion *expansion, xsdAnyURI_List &existingList, Object *prevSection, xsdAnyURI_List &deletionList, bool deleteList)
Expand expansion recursively.
bool HasExpansionMap()
Check if m_expansionMap has been filled.
This class represents a basic object.
Definition: object.h:64
This class represent a <score> in MEI.
Definition: score.h:30