Created
November 27, 2021 23:04
-
-
Save alanwhite/d5925501aba4590d714aaca73922a015 to your computer and use it in GitHub Desktop.
Cramming extracts of the musical measure and part models into a single gist for the sake of a blog post
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class MeasureModel extends ScoreContainerModel { | |
// snip ... | |
private List<PartModel> parts = new ArrayList<PartModel>(); | |
// snip ... | |
public List<PartModel> getParts() { | |
return parts; | |
} | |
public PartModel getPartByIndex(int index) { | |
return parts.get(index); | |
} | |
public void setParts(List<PartModel> parts) { | |
this.parts = parts; | |
} | |
} | |
public class PartModel extends ScoreContainerModel { | |
// snip ... | |
/* | |
* What's on the lines ... | |
*/ | |
private List<StaffElementModel> staffElements = new ArrayList<StaffElementModel>(); | |
// snip ... | |
public List<StaffElementModel> getStaffElements() { | |
return staffElements; | |
} | |
public void setStaffElements(List<StaffElementModel> staffElements) { | |
this.staffElements = staffElements; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment