@Test public void notEqualsWithFileSystemType() { StorageInfo storageInfo1 = new StorageInfo(STORAGE_TYPE, new UINT16(0), ACCESS_CAPABILITY, MAX_CAPACITY, FREE_SPACE_IN_BYTES, FREE_SPACE_IN_IMAGES, STORAGE_DESCRIPTION, VOLUME_LABEL); StorageInfo storageInfo2 = new StorageInfo(STORAGE_TYPE, new UINT16(1), ACCESS_CAPABILITY, MAX_CAPACITY, FREE_SPACE_IN_BYTES, FREE_SPACE_IN_IMAGES, STORAGE_DESCRIPTION, VOLUME_LABEL); assertFalse(storageInfo1.equals(storageInfo2)); }
@Override public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } StorageInfo rhs = (StorageInfo) o; return new EqualsBuilder() .append(storageType, rhs.storageType) .append(fileSystemType, rhs.fileSystemType) .append(accessCapability, rhs.accessCapability) .append(maxCapacity, rhs.maxCapacity) .append(freeSpaceInBytes, rhs.freeSpaceInBytes) .append(freeSpaceInImages, rhs.freeSpaceInImages) .append(storageDescription, rhs.storageDescription) .append(volumeLabel, rhs.volumeLabel) .isEquals(); }
StorageInfo { @Override public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } StorageInfo rhs = (StorageInfo) o; return new EqualsBuilder() .append(storageType, rhs.storageType) .append(fileSystemType, rhs.fileSystemType) .append(accessCapability, rhs.accessCapability) .append(maxCapacity, rhs.maxCapacity) .append(freeSpaceInBytes, rhs.freeSpaceInBytes) .append(freeSpaceInImages, rhs.freeSpaceInImages) .append(storageDescription, rhs.storageDescription) .append(volumeLabel, rhs.volumeLabel) .isEquals(); } }
StorageInfo { @Override public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } StorageInfo rhs = (StorageInfo) o; return new EqualsBuilder() .append(storageType, rhs.storageType) .append(fileSystemType, rhs.fileSystemType) .append(accessCapability, rhs.accessCapability) .append(maxCapacity, rhs.maxCapacity) .append(freeSpaceInBytes, rhs.freeSpaceInBytes) .append(freeSpaceInImages, rhs.freeSpaceInImages) .append(storageDescription, rhs.storageDescription) .append(volumeLabel, rhs.volumeLabel) .isEquals(); } StorageInfo(UINT16 storageType, UINT16 fileSystemType,
                       UINT16 accessCapability, UINT64 maxCapacity, UINT64 freeSpaceInBytes, UINT32 freeSpaceInImages,
                       String storageDescription, String volumeLabel
    ); }
StorageInfo { @Override public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } StorageInfo rhs = (StorageInfo) o; return new EqualsBuilder() .append(storageType, rhs.storageType) .append(fileSystemType, rhs.fileSystemType) .append(accessCapability, rhs.accessCapability) .append(maxCapacity, rhs.maxCapacity) .append(freeSpaceInBytes, rhs.freeSpaceInBytes) .append(freeSpaceInImages, rhs.freeSpaceInImages) .append(storageDescription, rhs.storageDescription) .append(volumeLabel, rhs.volumeLabel) .isEquals(); } StorageInfo(UINT16 storageType, UINT16 fileSystemType,
                       UINT16 accessCapability, UINT64 maxCapacity, UINT64 freeSpaceInBytes, UINT32 freeSpaceInImages,
                       String storageDescription, String volumeLabel
    ); static StorageInfo read(InputStream is); static StorageInfo read(PtpInputStream pis); UINT16 getStorageType(); UINT16 getFileSystemType(); UINT16 getAccessCapability(); UINT64 getMaxCapacity(); UINT64 getFreeSpaceInBytes(); UINT32 getFreeSpaceInImages(); String getStorageDescription(); String getVolumeLabel(); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString(); }
StorageInfo { @Override public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } StorageInfo rhs = (StorageInfo) o; return new EqualsBuilder() .append(storageType, rhs.storageType) .append(fileSystemType, rhs.fileSystemType) .append(accessCapability, rhs.accessCapability) .append(maxCapacity, rhs.maxCapacity) .append(freeSpaceInBytes, rhs.freeSpaceInBytes) .append(freeSpaceInImages, rhs.freeSpaceInImages) .append(storageDescription, rhs.storageDescription) .append(volumeLabel, rhs.volumeLabel) .isEquals(); } StorageInfo(UINT16 storageType, UINT16 fileSystemType,
                       UINT16 accessCapability, UINT64 maxCapacity, UINT64 freeSpaceInBytes, UINT32 freeSpaceInImages,
                       String storageDescription, String volumeLabel
    ); static StorageInfo read(InputStream is); static StorageInfo read(PtpInputStream pis); UINT16 getStorageType(); UINT16 getFileSystemType(); UINT16 getAccessCapability(); UINT64 getMaxCapacity(); UINT64 getFreeSpaceInBytes(); UINT32 getFreeSpaceInImages(); String getStorageDescription(); String getVolumeLabel(); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString();  }