if (axis == getAxis()) return getPreferredSpan(axis);
if (!isLayoutValid(axis)) { if (axis == myAxis) requirements[axis] = calculateMajorAxisRequirements(axis, requirements[axis]);
  public float getMaximumSpan(int axis)  {    if (axis == getAxis())      return getPreferredSpan(axis);    else      return Integer.MAX_VALUE;  }