@Test public void testEquals() { short len = 6; MStringInput input1 = new MStringInput("sqoopsqoop", true, InputEditable.ANY, StringUtils.EMPTY, len); MStringInput input2 = new MStringInput("sqoopsqoop", true, InputEditable.ANY, StringUtils.EMPTY, len); assertTrue(input1.equals(input2)); MStringInput input3 = new MStringInput("sqoopsqoop", false, InputEditable.ANY, StringUtils.EMPTY, len); MStringInput input4 = new MStringInput("sqoopsqoop", true, InputEditable.ANY, StringUtils.EMPTY, len); assertFalse(input3.equals(input4)); }
@Override public boolean equals(Object other) { if (other == this) { return true; } if (!(other instanceof MStringInput)) { return false; } MStringInput msi = (MStringInput) other; return getName().equals(msi.getName()) && (isSensitive() == msi.isSensitive()) && (maxLength == msi.maxLength); }
MStringInput extends MInput<String> { @Override public boolean equals(Object other) { if (other == this) { return true; } if (!(other instanceof MStringInput)) { return false; } MStringInput msi = (MStringInput) other; return getName().equals(msi.getName()) && (isSensitive() == msi.isSensitive()) && (maxLength == msi.maxLength); } }
MStringInput extends MInput<String> { @Override public boolean equals(Object other) { if (other == this) { return true; } if (!(other instanceof MStringInput)) { return false; } MStringInput msi = (MStringInput) other; return getName().equals(msi.getName()) && (isSensitive() == msi.isSensitive()) && (maxLength == msi.maxLength); } MStringInput(String name, boolean sensitive, InputEditable editable, String overrides, short maxLength); }
MStringInput extends MInput<String> { @Override public boolean equals(Object other) { if (other == this) { return true; } if (!(other instanceof MStringInput)) { return false; } MStringInput msi = (MStringInput) other; return getName().equals(msi.getName()) && (isSensitive() == msi.isSensitive()) && (maxLength == msi.maxLength); } MStringInput(String name, boolean sensitive, InputEditable editable, String overrides, short maxLength); short getMaxLength(); @Override String getUrlSafeValueString(); @Override void restoreFromUrlSafeValueString(String valueString); @Override MInputType getType(); @Override boolean hasExtraInfo(); @Override String getExtraInfoToString(); @Override boolean equals(Object other); @Override int hashCode(); @Override boolean isEmpty(); @Override void setEmpty(); @Override MStringInput clone(boolean cloneWithValue); }
MStringInput extends MInput<String> { @Override public boolean equals(Object other) { if (other == this) { return true; } if (!(other instanceof MStringInput)) { return false; } MStringInput msi = (MStringInput) other; return getName().equals(msi.getName()) && (isSensitive() == msi.isSensitive()) && (maxLength == msi.maxLength); } MStringInput(String name, boolean sensitive, InputEditable editable, String overrides, short maxLength); short getMaxLength(); @Override String getUrlSafeValueString(); @Override void restoreFromUrlSafeValueString(String valueString); @Override MInputType getType(); @Override boolean hasExtraInfo(); @Override String getExtraInfoToString(); @Override boolean equals(Object other); @Override int hashCode(); @Override boolean isEmpty(); @Override void setEmpty(); @Override MStringInput clone(boolean cloneWithValue);  }