1 package io.extact.rms.application.domain; 2 3 public interface IdAccessable { 4 5 Integer getId(); 6 7 void setId(Integer id); 8 9 default boolean isSameId(IdAccessable other) { 10 if (other == null) { 11 return false; 12 } 13 if (this.getId() == null) { 14 return false; 15 } 16 return this.getId().equals(other.getId()); 17 } 18 }