2 * Jalview - A Sequence Alignment Editor and Viewer (Version 2.8)
3 * Copyright (C) 2012 J Procter, AM Waterhouse, LM Lui, J Engelhardt, G Barton, M Clamp, S Searle
5 * This file is part of Jalview.
7 * Jalview is free software: you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
11 * Jalview is distributed in the hope that it will be useful, but
12 * WITHOUT ANY WARRANTY; without even the implied warranty
13 * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
14 * PURPOSE. See the GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License along with Jalview. If not, see <http://www.gnu.org/licenses/>.
18 package vamsas.objects.simple;
20 public class SeqSearchResult extends vamsas.objects.simple.Result implements
23 private vamsas.objects.simple.Alignment alignment;
25 private java.lang.String annotation;
27 private java.lang.String features;
29 private java.lang.String newickTree;
31 public SeqSearchResult()
35 public SeqSearchResult(vamsas.objects.simple.Alignment alignment,
36 java.lang.String annotation, java.lang.String features,
37 java.lang.String newickTree)
39 this.alignment = alignment;
40 this.annotation = annotation;
41 this.features = features;
42 this.newickTree = newickTree;
46 * Gets the alignment value for this SeqSearchResult.
50 public vamsas.objects.simple.Alignment getAlignment()
56 * Sets the alignment value for this SeqSearchResult.
60 public void setAlignment(vamsas.objects.simple.Alignment alignment)
62 this.alignment = alignment;
66 * Gets the annotation value for this SeqSearchResult.
70 public java.lang.String getAnnotation()
76 * Sets the annotation value for this SeqSearchResult.
80 public void setAnnotation(java.lang.String annotation)
82 this.annotation = annotation;
86 * Gets the features value for this SeqSearchResult.
90 public java.lang.String getFeatures()
96 * Sets the features value for this SeqSearchResult.
100 public void setFeatures(java.lang.String features)
102 this.features = features;
106 * Gets the newickTree value for this SeqSearchResult.
110 public java.lang.String getNewickTree()
116 * Sets the newickTree value for this SeqSearchResult.
120 public void setNewickTree(java.lang.String newickTree)
122 this.newickTree = newickTree;
125 private java.lang.Object __equalsCalc = null;
127 public synchronized boolean equals(java.lang.Object obj)
129 if (!(obj instanceof SeqSearchResult))
131 SeqSearchResult other = (SeqSearchResult) obj;
136 if (__equalsCalc != null)
138 return (__equalsCalc == obj);
142 _equals = super.equals(obj)
143 && ((this.alignment == null && other.getAlignment() == null) || (this.alignment != null && this.alignment
144 .equals(other.getAlignment())))
145 && ((this.annotation == null && other.getAnnotation() == null) || (this.annotation != null && this.annotation
146 .equals(other.getAnnotation())))
147 && ((this.features == null && other.getFeatures() == null) || (this.features != null && this.features
148 .equals(other.getFeatures())))
149 && ((this.newickTree == null && other.getNewickTree() == null) || (this.newickTree != null && this.newickTree
150 .equals(other.getNewickTree())));
155 private boolean __hashCodeCalc = false;
157 public synchronized int hashCode()
163 __hashCodeCalc = true;
164 int _hashCode = super.hashCode();
165 if (getAlignment() != null)
167 _hashCode += getAlignment().hashCode();
169 if (getAnnotation() != null)
171 _hashCode += getAnnotation().hashCode();
173 if (getFeatures() != null)
175 _hashCode += getFeatures().hashCode();
177 if (getNewickTree() != null)
179 _hashCode += getNewickTree().hashCode();
181 __hashCodeCalc = false;