pub struct Divisions {
pub attributes: (),
pub content: PositiveDivisions,
}Expand description
The Divisions element indicates how many divisions per quarter note are used to indicate a note’s duration.
For example, if duration = 1 and divisions = 2, this is an eighth note duration. Duration and Divisions are used directly for generating sound output, so they must be chosen to take tuplets into account.
Using a Divisions element lets us use just one number to represent a duration for each note in the score, while retaining the full power of a fractional representation. If maximum compatibility with Standard MIDI 1.0 files is important, do not have the Divisions value exceed 16383.
Fields§
§attributes: ()Element-specific attributes
content: PositiveDivisionsElement-specific content
Trait Implementations§
Source§impl ElementDeserializer for Divisions
impl ElementDeserializer for Divisions
fn deserialize(element: &XmlElement) -> Result<Divisions, String>
Source§impl ElementSerializer for Divisions
impl ElementSerializer for Divisions
fn serialize(element: &Divisions) -> XmlElement
impl Eq for Divisions
impl StructuralPartialEq for Divisions
Auto Trait Implementations§
impl Freeze for Divisions
impl RefUnwindSafe for Divisions
impl Send for Divisions
impl Sync for Divisions
impl Unpin for Divisions
impl UnwindSafe for Divisions
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more