Package eu.bandm.music.entities
Class Accidental
- All Implemented Interfaces:
Translet.Parseable<Accidental>
Represents accidentals, used for key indications and for pitches, when combined with
white keys.
This class only represents the conventional accidental signs,
which stand for half tone / chromatic steps.
Quarter tone / sixth tone / ecmelic accidentals require a different implementation,
but also follow a very different theory.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final AccidentalThe single flat.static final AccidentalThe double flat.protected static final Map<Integer, Accidental> Index of the defined accidentals by chromatic steps.protected static final EntityCatalog<Accidental> The catalog holding accidentals defined with a name.static final intExplains one chromatic step upward as seven functional fifths upward.static final AccidentalThe single sharp.static final AccidentalThe double sharp.static final AccidentalThe natural sign.protected intThe chromatic steps caused by this accidental.protected intThe number of fifths caused by this accidental.Fields inherited from class eu.bandm.tscore.base.Entity
documentations -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAccidental(int shift_chromaticSteps) Constructor with no names in (human) languages.protectedAccidental(int shift_chromaticSteps, MuLi muli) Constructor giving names in different (human) languages. -
Method Summary
Modifier and TypeMethodDescriptionstatic AccidentalbyChromaticSteps(int i) Return the accidental defined for this number of chromatic steps, or define a new one (with synthetic and symbolic name only), if necessary.intReturn the number of chromatic shifts caused by this accidental.intReturn the number of shifts by a fifths (in functional harmonic space) caused by this accidental.Methods inherited from class eu.bandm.tscore.base.Entity
addName, dump, dump, getCatalog, getDocumentation, getDocumentation, getDocumentations, getName, getNames, getParser, getParser, getSpecific, setDocumentation, toString, toString
-
Field Details
-
fifth_per_chromaticStep
public static final int fifth_per_chromaticStepExplains one chromatic step upward as seven functional fifths upward.- See Also:
-
shift_chromaticSteps
protected int shift_chromaticStepsThe chromatic steps caused by this accidental. Positive numbers go upward. -
shift_fifths
protected int shift_fifthsThe number of fifths caused by this accidental. Positive numbers go upward. -
by_chromaticSteps
Index of the defined accidentals by chromatic steps. Positive numbers go upward. -
catalog
The catalog holding accidentals defined with a name. -
b
The single flat. -
bb
The double flat. -
nat
The natural sign. (The symbolic sign "=" is inherited from musictex and lilypond. -
h
The single sharp. -
hh
The double sharp. While the synthetic triple, quadruple,... sharps will have "###" etc. as their symbolic name, this instance has traditionally "x".
-
-
Constructor Details
-
Accidental
Constructor giving names in different (human) languages. The symbolic name will be added automatically. -
Accidental
protected Accidental(int shift_chromaticSteps) Constructor with no names in (human) languages. The symbolic name will be added automatically.
-
-
Method Details
-
get_chromaticSteps_shift
public int get_chromaticSteps_shift()Return the number of chromatic shifts caused by this accidental. Positive numbers mean upward interval. -
get_fifths_shift
public int get_fifths_shift()Return the number of shifts by a fifths (in functional harmonic space) caused by this accidental. Positive numbers mean upward interval. -
byChromaticSteps
Return the accidental defined for this number of chromatic steps, or define a new one (with synthetic and symbolic name only), if necessary.
-