Skip to content

Commit

Permalink
PrairieMetadata: add API to query spectral mode
Browse files Browse the repository at this point in the history
  • Loading branch information
ctrueden committed Oct 10, 2014
1 parent f9b6ac3 commit 1cf9297
Showing 1 changed file with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -565,6 +565,9 @@ public class Sequence {
/** {@code cycle} of this {@code <Sequence>}. */
private Integer cycle;

/** {@code SpectralMode} of this {@code <Sequence>}. */
private boolean spectralMode;

/**
* Creates a new sequence by parsing the given {@code <Sequence>} element.
*/
Expand All @@ -584,6 +587,7 @@ public void parse(final Element sequenceElement) {
if (cycle == null) {
throw new IllegalArgumentException("Sequence missing cycle attribute");
}
spectralMode = b(attr(sequenceElement, "SpectralMode"));

// iterate over all Frame elements
final NodeList frameNodes = sequenceElement.getElementsByTagName("Frame");
Expand Down Expand Up @@ -619,6 +623,10 @@ public int getCycle() {
return cycle;
}

public boolean isSpectralMode() {
return spectralMode;
}

/**
* Gets the minimum index value. Matches the smallest {@code index}
* attribute found, and hence will not necessarily equal {@code 1} (though
Expand Down

0 comments on commit 1cf9297

Please sign in to comment.