fuzzyComparison method
Fuzzy Compare. return this == other.
other
: The target for comparison.
Implementation
bool fuzzyComparison(EnumAminoAcid other) {
if (this == EnumAminoAcid.Asp) {
return other == EnumAminoAcid.Asp || other == EnumAminoAcid.Asx;
} else if (this == EnumAminoAcid.Asn) {
return other == EnumAminoAcid.Asn || other == EnumAminoAcid.Asx;
} else if (this == EnumAminoAcid.Asx) {
return other == EnumAminoAcid.Asp ||
other == EnumAminoAcid.Asn ||
other == EnumAminoAcid.Asx;
} else if (this == EnumAminoAcid.Gln) {
return other == EnumAminoAcid.Gln || other == EnumAminoAcid.Glx;
} else if (this == EnumAminoAcid.Glu) {
return other == EnumAminoAcid.Glu || other == EnumAminoAcid.Glx;
} else if (this == EnumAminoAcid.Glx) {
return other == EnumAminoAcid.Gln ||
other == EnumAminoAcid.Glu ||
other == EnumAminoAcid.Glx;
} else if (this == EnumAminoAcid.Leu) {
return other == EnumAminoAcid.Leu || other == EnumAminoAcid.Xle;
} else if (this == EnumAminoAcid.Ile) {
return other == EnumAminoAcid.Ile || other == EnumAminoAcid.Xle;
} else if (this == EnumAminoAcid.Xle) {
return other == EnumAminoAcid.Leu ||
other == EnumAminoAcid.Ile ||
other == EnumAminoAcid.Xle;
} else if (this == EnumAminoAcid.Xaa || other == EnumAminoAcid.Xaa) {
return true;
} else {
return this == other;
}
}