Verovio
Source code documentation
tabgrp.h
1 // Name: tabgrp.h
3 // Author: Laurent Pugin
4 // Created: 2019
5 // Copyright (c) Authors and others. All rights reserved.
7 
8 #ifndef __VRV_TABGRP_H__
9 #define __VRV_TABGRP_H__
10 
11 #include "durationinterface.h"
12 #include "layerelement.h"
13 #include "offsetinterface.h"
14 
15 namespace vrv {
16 
17 //----------------------------------------------------------------------------
18 // TabGrp
19 //----------------------------------------------------------------------------
20 
25 public:
31  TabGrp();
32  virtual ~TabGrp();
33  Object *Clone() const override { return new TabGrp(*this); }
34  void Reset() override;
35  std::string GetClassName() const override { return "tabGrp"; }
37 
42  DurationInterface *GetDurationInterface() override { return vrv_cast<DurationInterface *>(this); }
43  const DurationInterface *GetDurationInterface() const override { return vrv_cast<const DurationInterface *>(this); }
44  OffsetInterface *GetOffsetInterface() override { return vrv_cast<OffsetInterface *>(this); }
45  const OffsetInterface *GetOffsetInterface() const override { return vrv_cast<const OffsetInterface *>(this); }
47 
51  bool IsSupportedChild(ClassId classId) override;
52 
58  const Note *GetTopNote() const;
59  Note *GetBottomNote();
60  const Note *GetBottomNote() const;
61  int GetYTop() const;
62  int GetYBottom() const;
64 
65  //----------//
66  // Functors //
67  //----------//
68 
73  FunctorCode Accept(Functor &functor) override;
74  FunctorCode Accept(ConstFunctor &functor) const override;
75  FunctorCode AcceptEnd(Functor &functor) override;
76  FunctorCode AcceptEnd(ConstFunctor &functor) const override;
78 
79 protected:
83  void FilterList(ListOfConstObjects &childList) const override;
84 
85 private:
86  //
87 public:
88  //
89 private:
90  //
91 };
92 
93 } // namespace vrv
94 
95 #endif
This abstract class is the base class for all const functors.
Definition: functor.h:126
This class is an interface for elements with duration, such as notes and rests.
Definition: durationinterface.h:39
This abstract class is the base class for all mutable functors.
Definition: functor.h:101
This class is a base class for the Layer (<layer>) content.
Definition: layerelement.h:51
This class models the MEI <note> element.
Definition: note.h:69
This class represents a basic object.
Definition: object.h:64
This class is an pseudo interface for elements maintaining a flat list of children LayerElement for p...
Definition: object.h:908
This class is an interface for elements having a single visual offset, such as arpeg,...
Definition: offsetinterface.h:28
This class models the MEI <tabGrp> element.
Definition: tabgrp.h:24
void FilterList(ListOfConstObjects &childList) const override
Filter the flat list and keep only Note elements.
bool IsSupportedChild(ClassId classId) override
Add an element to a element.
void Reset() override
Virtual reset method.
FunctorCode Accept(Functor &functor) override
Interface for class functor visitation.
Object * Clone() const override
Method call for copying child classes.
Definition: tabgrp.h:33
Note * GetTopNote()
Return the top or bottom note or their Y position.