code: public void setDominantMeasurement(int dominantMeasurement) {
          if (dominantMeasurement != MEASUREMENT_HEIGHT && dominantMeasurement != MEASUREMENT_WIDTH) {
              throw new IllegalArgumentException("Invalid measurement type.");
          }
          this.dominantMeasurement = dominantMeasurement;
          requestLayout();
      }
docs: Set the dominant measurement for the aspect ratio.
  
  @see #MEASUREMENT_WIDTH
  @see #MEASUREMENT_HEIGHT