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

org.unidal.eunit.model.entity.EunitException Maven / Gradle / Ivy

/* THIS FILE WAS AUTO GENERATED BY codegen-maven-plugin, DO NOT EDIT IT */
package org.unidal.eunit.model.entity;

import org.unidal.eunit.model.BaseEntity;
import org.unidal.eunit.model.IVisitor;

public class EunitException extends BaseEntity {
   private Class m_type;

   private String m_message;

   private String m_pattern;

   public EunitException() {
   }

   @Override
   public void accept(IVisitor visitor) {
      visitor.visitEunitException(this);
   }

   @Override
   public boolean equals(Object obj) {
      if (obj instanceof EunitException) {
         EunitException _o = (EunitException) obj;

         if (!equals(getType(), _o.getType())) {
            return false;
         }

         if (!equals(getMessage(), _o.getMessage())) {
            return false;
         }

         if (!equals(getPattern(), _o.getPattern())) {
            return false;
         }


         return true;
      }

      return false;
   }

   public String getMessage() {
      return m_message;
   }

   public String getPattern() {
      return m_pattern;
   }

   public Class getType() {
      return m_type;
   }

   @Override
   public int hashCode() {
      int hash = 0;

      hash = hash * 31 + (m_type == null ? 0 : m_type.hashCode());
      hash = hash * 31 + (m_message == null ? 0 : m_message.hashCode());
      hash = hash * 31 + (m_pattern == null ? 0 : m_pattern.hashCode());

      return hash;
   }

   @Override
   public void mergeAttributes(EunitException other) {
      if (other.getType() != null) {
         m_type = other.getType();
      }

      if (other.getMessage() != null) {
         m_message = other.getMessage();
      }

      if (other.getPattern() != null) {
         m_pattern = other.getPattern();
      }
   }

   public EunitException setMessage(String message) {
      m_message = message;
      return this;
   }

   public EunitException setPattern(String pattern) {
      m_pattern = pattern;
      return this;
   }

   public EunitException setType(Class type) {
      m_type = type;
      return this;
   }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy