All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.regnosys.rosetta.translate.MappingError Maven / Gradle / Ivy

There is a newer version: 11.25.1
Show newest version
package com.regnosys.rosetta.translate;

public class MappingError {
	
	public enum MappingErrorLevel {
		ERROR, WARNING;
	}
	
	private final MappingErrorLevel level;
	private final String message;
	
	public MappingError(MappingErrorLevel level, String message) {
		this.level = level;
		this.message = message;
	}
	public MappingErrorLevel getLevel() {
		return level;
	}
	public String getMessage() {
		return message;
	}
	@Override
	public String toString() {
		return "MappingError [level=" + level + ", message=" + message + "]";
	}
	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + ((level == null) ? 0 : level.hashCode());
		result = prime * result + ((message == null) ? 0 : message.hashCode());
		return result;
	}
	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		MappingError other = (MappingError) obj;
		if (level != other.level)
			return false;
		if (message == null) {
			if (other.message != null)
				return false;
		} else if (!message.equals(other.message))
			return false;
		return true;
	}
	
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy