Ahh, the things you can find in an old, gigantic system! Chris B recently uncovered this gem in an old Java application. It might be misnamed, but then again... how could one possibly describe what this is supposed to do...
/** * Description: * On Entry: * On Exit: * Creation date: (14/02/02 3:45:08 PM) * @return boolean * @param theStringToCompareTo java.lang.String * @param theStringToCompareFrom java.lang.String */ public boolean containsNotEqualBackwards (String theStringToCompareFrom, String theStringToCompareTo) { if (theStringToCompareFrom.equals(theStringToCompareTo)) return false; else { StringBuffer compareTo = new StringBuffer(theStringToCompareTo).reverse(); StringBuffer compareFrom = new StringBuffer(theStringToCompareFrom).reverse(); return (compareFrom.substring(0,11).trim().equals(compareTo.toString().trim())); } }
[Advertisement]
BuildMaster allows you to create a self-service release management platform that allows different teams to manage their applications. Explore how!