Class AudioAnalysisSection

java.lang.Object
se.michaelthelin.spotify.model_objects.AbstractModelObject
se.michaelthelin.spotify.model_objects.miscellaneous.AudioAnalysisSection
All Implemented Interfaces:
Serializable, IModelObject

public class AudioAnalysisSection extends AbstractModelObject
Retrieve information about Audio Analysis Section objects by creating instances from this class.
Sections are defined by large variations in rhythm or timbre, e.g. chorus, verse, bridge, guitar solo, etc. Each section contains its own descriptions of tempo, key, mode, time_signature, and loudness.
See Also:
  • Method Details

    • getMeasure

      public AudioAnalysisMeasure getMeasure()
      Get the measure of the audio analysis section object. This measure contains the start point, duration and confidence of the section.
      Returns:
      The measure of the audio analysis section object.
    • getLoudness

      public Float getLoudness()
      Get the (average) loudness of the section in decibels.
      Returns:
      The loudness of the section.
    • getTempo

      public Float getTempo()
      Get the (estimated) tempo of the section in beats per minute.
      Returns:
      The tempo of the section.
    • getTempoConfidence

      public Float getTempoConfidence()
      Get the tempo confidence of the section.
      Returns:
      The tempo confidence of the section.
    • getKey

      public Integer getKey()
      Get the main key of the section.
      Returns:
      Main key of the section.
      See Also:
    • getKeyConfidence

      public Float getKeyConfidence()
      Get the key confidence of the section.
      Returns:
      The key confidence of the section.
    • getMode

      public Modality getMode()
      Get the modality of the section. (either "major" or "minor")
      Returns:
      The modality type of the section.
      See Also:
    • getModeConfidence

      public Float getModeConfidence()
      Get the modality confidence of the section.
      Returns:
      The modality confidence of the section.
    • getTimeSignature

      public Integer getTimeSignature()
      Get the estimated overall time signature of the section. The time signature (or meter) is the number of beats in a bar.
      Example: A Viennese waltz has a three-quarters beat, so this method would return the value 3 in this case.
      Returns:
      Time signature value of the section.
    • getTimeSignatureConfidence

      public Float getTimeSignatureConfidence()
      Get the time signature confidence of the section.
      Returns:
      The time signature confidence of the section.
    • toString

      public String toString()
      Description copied from class: AbstractModelObject
      Returns a String representation of this model object in the style:

      ModelObject(attr1=value1, attr2=value2, ...)

      Specified by:
      toString in class AbstractModelObject
    • builder

      public AudioAnalysisSection.Builder builder()
      Description copied from interface: IModelObject
      Create a builder for building an instance of a model object.
      The type of the builder and its methods depend on its corresponding implementation.
      Returns:
      A builder object.