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

com.osohq.oso.Pattern Maven / Gradle / Ivy

There is a newer version: 0.27.3
Show newest version
package com.osohq.oso;

import java.util.HashMap;
import java.util.Objects;

public class Pattern {
  private String tag; // nullable
  private HashMap fields;

  public Pattern(String tag, HashMap fields) {
    this.tag = tag;
    this.fields = fields;
  }

  public String getTag() {
    return tag;
  }

  public void setTag(String tag) {
    this.tag = tag;
  }

  public HashMap getFields() {
    return fields;
  }

  public void setFields(HashMap fields) {
    this.fields = fields;
  }

  @Override
  public boolean equals(Object o) {
    if (this == o) return true;
    if (o == null || getClass() != o.getClass()) return false;
    Pattern pattern = (Pattern) o;
    return Objects.equals(tag, pattern.tag) && fields.equals(pattern.fields);
  }

  @Override
  public int hashCode() {
    return Objects.hash(tag, fields);
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy