@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getCodec() == null) ? 0 : getCodec().hashCode()); hashCode = prime * hashCode + ((getDurationMillis() == null) ? 0 : getDurationMillis().hashCode()); hashCode = prime * hashCode + ((getFormat() == null) ? 0 : getFormat().hashCode()); hashCode = prime * hashCode + ((getFrameRate() == null) ? 0 : getFrameRate().hashCode()); hashCode = prime * hashCode + ((getFrameHeight() == null) ? 0 : getFrameHeight().hashCode()); hashCode = prime * hashCode + ((getFrameWidth() == null) ? 0 : getFrameWidth().hashCode()); hashCode = prime * hashCode + ((getRotation() == null) ? 0 : getRotation().hashCode()); return hashCode; }
/** * Returns a string representation of this object; useful for testing and * debugging. * * @return A string representation of this object. * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getCodec() != null) sb.append("Codec: " + getCodec() + ","); if (getDurationMillis() != null) sb.append("DurationMillis: " + getDurationMillis() + ","); if (getFormat() != null) sb.append("Format: " + getFormat() + ","); if (getFrameRate() != null) sb.append("FrameRate: " + getFrameRate() + ","); if (getFrameHeight() != null) sb.append("FrameHeight: " + getFrameHeight() + ","); if (getFrameWidth() != null) sb.append("FrameWidth: " + getFrameWidth() + ","); if (getRotation() != null) sb.append("Rotation: " + getRotation()); sb.append("}"); return sb.toString(); }
&& other.getFrameWidth().equals(this.getFrameWidth()) == false) return false; if (other.getRotation() == null ^ this.getRotation() == null) return false; if (other.getRotation() != null && other.getRotation().equals(this.getRotation()) == false) return false; return true;
jsonWriter.value(frameWidth); if (videoMetadata.getRotation() != null) { Integer rotation = videoMetadata.getRotation(); jsonWriter.name("Rotation"); jsonWriter.value(rotation);