/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package cz.csu.sdmx.validation.model;

/**
 *
 * @author themi
 */
public class Param {
    private String name;
    private String value;

    public Param(String name, String value) {
        this.name = name;
        this.value = value;
    }

    public String getName() {
        return name;
    }

    public String getValue() {
        return value;
    }

    @Override
    public String toString() {
        return "[" + name + "=" + value + "]"; //To change body of generated methods, choose Tools | Templates.
    }

    @Override
    public int hashCode() {
        return name.hashCode() + value.hashCode();
    }

    @Override
    public boolean equals(Object obj) {
        
        if(obj instanceof Param){
            Param param = (Param) obj;
            return name.equals(param.getName()) && value.equals(param.getValue());
        }
        return super.equals(obj); //To change body of generated methods, choose Tools | Templates.
    }
    
}
