List of usage examples for org.apache.commons.lang.builder CompareToBuilder CompareToBuilder
public CompareToBuilder()
Constructor for CompareToBuilder.
Starts off assuming that the objects are equal.
From source file:org.jgap.gp.function.Loop.java
/** * The compareTo-method./*from ww w . j a va 2 s . c om*/ * * @param a_other the other object to compare * @return -1, 0, 1 * * @author Klaus Meffert * @since 3.01 */ public int compareTo(Object a_other) { int result = super.compareTo(a_other); if (result != 0) { return result; } Loop other = (Loop) a_other; return new CompareToBuilder().append(m_typeVar, other.m_typeVar).append(m_count, other.m_count) .toComparison(); }
From source file:org.jgap.gp.function.Push.java
/** * The compareTo-method./* w ww. jav a 2 s . c o m*/ * * @param a_other the other object to compare * @return -1, 0, 1 * * @author Klaus Meffert * @since 3.0 */ public int compareTo(Object a_other) { int result = super.compareTo(a_other); if (result != 0) { return result; } Push other = (Push) a_other; return new CompareToBuilder().append(m_type, other.m_type).toComparison(); }
From source file:org.jgap.gp.function.ReadFromMatrix.java
/** * The compareTo-method./*from w w w .j av a2 s. co m*/ * * @param a_other the other object to compare * @return -1, 0, 1 * * @author Klaus Meffert * @since 3.4.3 */ public int compareTo(Object a_other) { int result = super.compareTo(a_other); if (result != 0) { return result; } ReadFromMatrix other = (ReadFromMatrix) a_other; return new CompareToBuilder().append(m_matrixName, other.m_matrixName) .append(getSubChildTypes(), other.getSubChildTypes()).toComparison(); }
From source file:org.jgap.gp.function.ReadTerminal.java
/** * The compareTo-method./*from w w w .ja va 2 s . co m*/ * * @param a_other the other object to compare * @return -1, 0, 1 * * @author Klaus Meffert * @since 3.0 */ public int compareTo(Object a_other) { int result = super.compareTo(a_other); if (result != 0) { return result; } ReadTerminal other = (ReadTerminal) a_other; return new CompareToBuilder().append(m_storageName, other.m_storageName).toComparison(); }
From source file:org.jgap.gp.function.ReadTerminalIndexed.java
/** * The compareTo-method.//from w w w . ja v a2 s.co m * * @param a_other the other object to compare * @return -1, 0, 1 * * @author Klaus Meffert * @since 3.0 */ public int compareTo(Object a_other) { int result = super.compareTo(a_other); if (result != 0) { return result; } ReadTerminalIndexed other = (ReadTerminalIndexed) a_other; return new CompareToBuilder().append(m_index, other.m_index).toComparison(); }
From source file:org.jgap.gp.function.ReplaceInMatrix.java
/** * The compareTo-method.//w w w . ja v a2 s . c om * * @param a_other the other object to compare * @return -1, 0, 1 * * @author Klaus Meffert * @since 3.4.3 */ public int compareTo(Object a_other) { int result = super.compareTo(a_other); if (result != 0) { return result; } ReplaceInMatrix other = (ReplaceInMatrix) a_other; return new CompareToBuilder().append(m_matrixName, other.m_matrixName).append(m_mode, other.m_mode) .append(m_targetCharacters, other.m_targetCharacters).append(m_replacement, other.m_replacement) .append(getSubChildTypes(), other.getSubChildTypes()).toComparison(); }
From source file:org.jgap.gp.function.ResetMatrix.java
/** * The compareTo-method.//from w w w . j ava 2 s .co m * * @param a_other the other object to compare * @return -1, 0, 1 * * @author Klaus Meffert * @since 3.4.3 */ public int compareTo(Object a_other) { int result = super.compareTo(a_other); if (result != 0) { return result; } ResetMatrix other = (ResetMatrix) a_other; return new CompareToBuilder().append(m_matrixName, other.m_matrixName).append(m_filler, other.m_filler) .toComparison(); }
From source file:org.jgap.gp.function.StoreTerminal.java
/** * The compareTo-method.// ww w .j a v a 2 s .com * * @param a_other the other object to compare * @return -1, 0, 1 * * @author Klaus Meffert * @since 3.0 */ public int compareTo(Object a_other) { int result = super.compareTo(a_other); if (result != 0) { return result; } StoreTerminal other = (StoreTerminal) a_other; return new CompareToBuilder().append(m_storageName, other.m_storageName).append(m_type, other.m_type) .toComparison(); }
From source file:org.jgap.gp.function.StoreTerminalIndexed.java
/** * The compareTo-method./*from w ww .j av a2 s . c o m*/ * * @param a_other the other object to compare * @return -1, 0, 1 * * @author Klaus Meffert * @since 3.0 */ public int compareTo(Object a_other) { int result = super.compareTo(a_other); if (result != 0) { return result; } StoreTerminalIndexed other = (StoreTerminalIndexed) a_other; return new CompareToBuilder().append(m_index, other.m_index).append(m_type, other.m_type).toComparison(); }
From source file:org.jgap.gp.function.SubProgram.java
/** * The compareTo-method.//from w w w .jav a 2s. c o m * * @param a_other the other object to compare * @return -1, 0, 1 * * @author Klaus Meffert * @since 3.0 */ public int compareTo(Object a_other) { int result = super.compareTo(a_other); if (result != 0) { return result; } SubProgram other = (SubProgram) a_other; return new CompareToBuilder().append(m_types, other.m_types).toComparison(); }