Code example for Text

Methods: getNodeValue

0
    if (instrument != null) return instrument.getMidiProgram();
    return 0; 
  } 
  public AbstractFraction getDuration() throws MusicXMLParseException { 
    if (duration != null) {
      int value = Math.round(Float.parseFloat(duration.getNodeValue()));
      return new Fraction(value * durationMultiplier, 4 * divisions);
    } 
    return getAugmentedFraction(); 
  } 
 
  public Notations getNotations() { return notations; }
  private Notations createNotations() { 
    Node node;
    for (node = element.getFirstChild(); node != null;
         node = node.getNextSibling()) {
      if (node.getNodeType() == Node.ELEMENT_NODE) {
        if (node.getNodeName().equals(LYRIC_ELEMENT)) break;
      } 
    }