- @Override
- public int hashCode() {
- final int prime = 31;
- int result = 1;
- result = prime * result + ((name == null) ? 0 : name.hashCode());
- result = prime * result + ((revision == null) ? 0 : revision.hashCode());
- return result;
- }
-
- @Override
- public boolean equals(final Object obj) {
- if (this == obj) {
- return true;
- }
- if (obj == null) {
- return false;
- }
- if (getClass() != obj.getClass()) {
- return false;
- }
- SourceIdentifier other = (SourceIdentifier) obj;
- if (name == null) {
- if (other.name != null) {
- return false;
- }
- } else if (!name.equals(other.name)) {
- return false;
- }
- if (revision == null) {
- if (other.revision != null) {
- return false;
- }
- } else if (!revision.equals(other.revision)) {
- return false;
- }
- return true;
- }
-
+ /**
+ * Since we've got two ways of model versioning (revision & semantic version),
+ * this method shouldn't be called directly anymore. Eventually, callers of this method
+ * should be notified before method gets deleted.
+ * @deprecated use either
+ * <ul>
+ * <li>{@link SemVerSourceIdentifier#create(String, SemVer)}</li>
+ * <li>{@link SemVerSourceIdentifier#create(String, Optional, SemVer)}</li>
+ * <li>{@link SemVerSourceIdentifier#create(String, String, SemVer)}</li>
+ * </ul>or
+ * <ul>
+ * <li>{@link RevisionSourceIdentifier#create(String)}</li>
+ * <li>{@link RevisionSourceIdentifier#create(String, String)}</li>
+ * <li>{@link RevisionSourceIdentifier#create(String, Optional)}</li>
+ * </ul>
+ *
+ * @param moduleName
+ * Name of schema
+ * @param revision
+ * Revision of source in format YYYY-mm-dd. If not present,
+ * default value will be used.
+ * @return particular SourceIdentifier instance
+ */
+ @Deprecated