net.charlesames.music.ensemble
Class TuningElement
java.lang.Object
net.charlesames.utility.common.Disposable
net.charlesames.utility.entity.Entity
net.charlesames.utility.entity.WriteableEntity
net.charlesames.music.ensemble.EnsembleEntity
net.charlesames.music.ensemble.TuningElement
- All Implemented Interfaces:
- EntityContainer
- Direct Known Subclasses:
- TuningElementAccidental, TuningElementDegree, TuningElementInflection, TuningElementLetter
public abstract class TuningElement
- extends EnsembleEntity
Element of a mapping from degrees to cents.
- Author:
- Charles Ames
|
Method Summary |
abstract void |
checkCents(int cents)
Check the indicated cents value. |
boolean |
equals(EnsembleEntity other)
Check if this entity has the same class and content as another entity. |
int |
getCents()
Get the cents value. |
void |
setCents(int cents)
Set the cents value. |
| Methods inherited from class net.charlesames.utility.entity.WriteableEntity |
check, clearXmlSpecs, createXmlSpec, getTagName, getXmlData, getXmlSpec, getXmlSpec, initializeXsd, isPersistent, logError, logError, makeDirty, putXmlData, save, setID, setName, setPersistent, setStatus, toXmlNode |
| Methods inherited from class net.charlesames.utility.entity.Entity |
decrementReferenceCount, dereferenceHandle, dispose, equals, getHandle, getID, getName, getPath, getReferenceCount, getStatus, getText, hasContainer, incrementReferenceCount, isModifiable, methodHasOverride, predecessor, resequenceEntities, setContainer, setModifiable, shiftEntitiesDown, shiftEntityDown, shiftEntityUp, successor, wipe |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
TuningElement
public TuningElement(TuningMap container,
java.lang.String name)
- Constructor for
TuningElement instances.
- Parameters:
container - The TuningMap that contains this element.name -
checkCents
public abstract void checkCents(int cents)
- Check the indicated cents value.
- Parameters:
cents - The indicated cents value.
getCents
public int getCents()
- Get the cents value.
- Returns:
- The assigned cents value.
setCents
public void setCents(int cents)
- Set the cents value.
- Parameters:
cents - The intended cents value.
equals
public boolean equals(EnsembleEntity other)
- Description copied from class:
EnsembleEntity
- Check if this entity has the same class and content as another entity.
- Overrides:
equals in class EnsembleEntity
- Parameters:
other - The other entity.
- Returns:
- True if the two entities have the same class and content; false otherwise.