|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectedu.uiuc.cs397rhc.sound.AtomicMidiCondition
AtomicMidiConditions represent atomic conditions over the fields
of a ShortMessage. These atomic conditions are not created
directly, but are instead produced using static factory methods.
| Nested Class Summary | |
|---|---|
static class |
AtomicMidiCondition.Field
The fields of a ShortMessage, complete with a method to
extract the value from a specific ShortMessage. |
| Method Summary | |
|---|---|
static MidiCondition |
createBetweenExclusive(AtomicMidiCondition.Field field,
long value1,
long value2)
Factory method to create a MidiCondition specifying
that the given field be beween the two given values, exclusive. |
static MidiCondition |
createBetweenInclusive(AtomicMidiCondition.Field field,
long value1,
long value2)
Factory method to create a MidiCondition specifying
that the given field be between the two given values, inclusive. |
static MidiCondition |
createEq(AtomicMidiCondition.Field field,
long value)
Factory method to create a MidiCondition specifying
that the given field be equal to the given value. |
static MidiCondition |
createGt(AtomicMidiCondition.Field field,
long value)
Factory method to create a MidiCondition specifying
that the given field be greater than the given value. |
static MidiCondition |
createGte(AtomicMidiCondition.Field field,
long value)
Factory method to create a MidiCondition specifying
that the given field be greater than or equal to the given value. |
static MidiCondition |
createLt(AtomicMidiCondition.Field field,
long value)
Factory method to create a MidiCondition specifying
that the given field be less thanthe given value. |
static MidiCondition |
createLte(AtomicMidiCondition.Field field,
long value)
Factory method to create a MidiCondition specifying
that the given field be less than or equal to the given value. |
static MidiCondition |
createNotEq(AtomicMidiCondition.Field field,
long value)
Factory method to create a MidiCondition specifying
that the given field be not equal to the given value. |
static MidiCondition |
createOutsideExclusive(AtomicMidiCondition.Field field,
long value1,
long value2)
Factory method to create a MidiCondition specifying
that the given field be outside the two given values, exclusive. |
static MidiCondition |
createOutsideInclusive(AtomicMidiCondition.Field field,
long value1,
long value2)
Factory method to create a MidiCondition specifying
that the given field be outside the two given values, inclusive. |
boolean |
equals(java.lang.Object other)
|
java.lang.String |
getPrettyString()
Returns a pretty, printable representation of this condition. |
boolean |
isSatisfiedBy(javax.sound.midi.MidiMessage msg,
long time)
Whether the given MidiMessage and timestamp satisfy this
AtomicMidiCondition. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Method Detail |
|---|
public boolean isSatisfiedBy(javax.sound.midi.MidiMessage msg,
long time)
MidiMessage and timestamp satisfy this
AtomicMidiCondition.
isSatisfiedBy in interface MidiConditionmsg - the messagetime - the timestamp
true if the field checked by this
AtomicMidiCondition is on the interval
[low,high], false otherwisepublic boolean equals(java.lang.Object other)
equals in class java.lang.Objectpublic java.lang.String getPrettyString()
MidiCondition
getPrettyString in interface MidiConditionpublic java.lang.String toString()
toString in class java.lang.Object
public static MidiCondition createEq(AtomicMidiCondition.Field field,
long value)
MidiCondition specifying
that the given field be equal to the given value.
field - the field to be testedvalue - the value to be used in testing
MidiCondition that represents the given field
being equal to the given value
public static MidiCondition createNotEq(AtomicMidiCondition.Field field,
long value)
MidiCondition specifying
that the given field be not equal to the given value.
field - the field to be testedvalue - the value to be used in testing
MidiCondition that represents the given field
being not equal to the given value
public static MidiCondition createLte(AtomicMidiCondition.Field field,
long value)
MidiCondition specifying
that the given field be less than or equal to the given value.
field - the field to be testedvalue - the value to be used in testing
MidiCondition that represents the given field
being less than or equal to the given value
public static MidiCondition createGte(AtomicMidiCondition.Field field,
long value)
MidiCondition specifying
that the given field be greater than or equal to the given value.
field - the field to be testedvalue - the value to be used in testing
MidiCondition that represents the given field
being greater than or equal to the given value
public static MidiCondition createLt(AtomicMidiCondition.Field field,
long value)
MidiCondition specifying
that the given field be less thanthe given value.
field - the field to be testedvalue - the value to be used in testing
MidiCondition that represents the given field
being less than the given value
public static MidiCondition createGt(AtomicMidiCondition.Field field,
long value)
MidiCondition specifying
that the given field be greater than the given value.
field - the field to be testedvalue - the value to be used in testing
MidiCondition that represents the given field
being greater than the given value
public static MidiCondition createBetweenInclusive(AtomicMidiCondition.Field field,
long value1,
long value2)
MidiCondition specifying
that the given field be between the two given values, inclusive.
field - the field to be testedvalue1 - the value to be used in testingvalue2 - the value to be used in testing
MidiCondition that represents the given field
being between the two given values, inclusive
public static MidiCondition createBetweenExclusive(AtomicMidiCondition.Field field,
long value1,
long value2)
MidiCondition specifying
that the given field be beween the two given values, exclusive.
field - the field to be testedvalue1 - the value to be used in testingvalue2 - the value to be used in testing
MidiCondition that represents the given field
being between the two given values, exclusive
public static MidiCondition createOutsideInclusive(AtomicMidiCondition.Field field,
long value1,
long value2)
MidiCondition specifying
that the given field be outside the two given values, inclusive.
field - the field to be testedvalue1 - the value to be used in testingvalue2 - the value to be used in testing
MidiCondition that represents the given field
being outside the two given values, inclusive
public static MidiCondition createOutsideExclusive(AtomicMidiCondition.Field field,
long value1,
long value2)
MidiCondition specifying
that the given field be outside the two given values, exclusive.
field - the field to be testedvalue1 - the value to be used in testingvalue2 - the value to be used in testing
MidiCondition that represents the given field
being outside the two given values, exclusive
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||