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

com.regnosys.rosetta.translate.datamodel.Schema Maven / Gradle / Ivy

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

import java.util.Collection;
import java.util.Objects;

public class Schema {
	
	private final Collection attributes; //all top level attributes in this file
	
	private final Collection globalTypes; //all named types in this schema

	public Schema(Collection attributes, Collection globalTypes) {
		this.attributes = attributes;
		this.globalTypes = globalTypes;
	}

	public Collection getAttributes() {
		return attributes;
	}

	public Collection getGlobalTypes() {
		return globalTypes;
	}

	@Override
	public int hashCode() {
		return Objects.hash(attributes, globalTypes);
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		Schema other = (Schema) obj;
		return Objects.equals(attributes, other.attributes) && Objects.equals(globalTypes, other.globalTypes);
	}

	@Override
	public String toString() {
		return "Schema [attributes=" + attributes + ", globalTypes=" + globalTypes + "]";
	}
	
	
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy