- public GetSnapshotReply(@Nonnull String id, @Nonnull Snapshot snapshot) {
- this.id = Preconditions.checkNotNull(id);
- this.snapshot = Preconditions.checkNotNull(snapshot);
+ public GetSnapshotReply(@NonNull String id, @NonNull Snapshot snapshot) {
+ this.id = requireNonNull(id);
+ this.snapshot = requireNonNull(snapshot);
return id;
}
@SuppressFBWarnings(value = "EI_EXPOSE_REP", justification = "Exposes a mutable object stored in a field but "
+ "this is OK since this class is merely a DTO and does not process the byte[] internally. "
+ "Also it would be inefficient to create a return copy as the byte[] could be large.")
return id;
}
@SuppressFBWarnings(value = "EI_EXPOSE_REP", justification = "Exposes a mutable object stored in a field but "
+ "this is OK since this class is merely a DTO and does not process the byte[] internally. "
+ "Also it would be inefficient to create a return copy as the byte[] could be large.")