LibMusicXML 3.22
guidonote Class Reference

A guido note representation. More...

#include <guido.h>

Inheritance diagram for guidonote:
guidoelement smartable

Public Member Functions

void set (unsigned short voice, std::string name, char octave, guidonoteduration &dur, std::string acc)
void setName (const std::string name)
void setOctave (char octave)
void setDuration (const guidonoteduration &dur)
void setAccidental (const std::string acc)
const char * name () const
const char * accidental () const
char octave () const
const guidonotedurationduration () const
virtual bool isNote () const
Public Member Functions inherited from guidoelement
long add (Sguidoelement &elt)
long add (Sguidoparam &param)
long add (Sguidoparam param)
virtual void print (std::ostream &os) const
void setName (std::string name)
 the element name
std::string getName () const
std::string getStart () const
std::string getEnd () const
std::string getSep () const
void setEnd (std::string end)
std::vector< Sguidoelement > & elements ()
const std::vector< Sguidoelement > & elements () const
const std::vector< Sguidoparam > & parameters () const
bool empty () const
virtual bool isSeq () const
virtual bool isChord () const
virtual bool isTag () const
virtual bool isRangeTag () const
virtual bool isBeginTag () const
virtual bool isEndTag () const
int countNotes () const
const bool getNext (Sguidoelement &i, Sguidoelement &next_e) const
 Get next subelement.
const bool getPrev (Sguidoelement &i, Sguidoelement &next_e) const
Public Member Functions inherited from smartable
unsigned refs () const
 gives the reference count of the object
void addReference ()
 addReference increments the ref count and checks for refCount overflow
void removeReference ()
 removeReference delete the object when refCount is zero

Static Public Member Functions

static SMARTP< guidonotecreate (unsigned short voice)
static SMARTP< guidonotecreate (unsigned short voice, std::string name, char octave, guidonoteduration &dur, std::string acc="")
Static Public Member Functions inherited from guidoelement
static SMARTP< guidoelementcreate (std::string name, std::string sep=" ")

Protected Member Functions

 guidonote (unsigned short voice)
 guidonote (unsigned short voice, std::string name, char octave, guidonoteduration &dur, std::string acc="")
Protected Member Functions inherited from guidoelement
 guidoelement (std::string name, std::string sep=" ")
void printparams (std::ostream &os) const
Protected Member Functions inherited from smartable
 smartable (const smartable &)
virtual ~smartable ()
 destructor checks for non-zero refCount
smartableoperator= (const smartable &)

Protected Attributes

std::string fNote
std::string fAccidental
char fOctave
guidonoteduration fDuration
Protected Attributes inherited from guidoelement
std::string fName
std::string fStartList
 the contained element start marker (default to empty)
std::string fEndList
 the contained element end marker (default to empty)
std::string fSep
 the element separator (default to space)
std::vector< SguidoelementfElements
 list of the enclosed elements
std::vector< SguidoparamfParams
 list of optional parameters

Detailed Description

A note is represented by its name, optional accidentals, duration (in the form of numerator/denominator) and optional dots.

Member Function Documentation

◆ isNote()

virtual bool isNote ( ) const
inlinevirtual

Reimplemented from guidoelement.