Serial data string.equals wild cards?

I just used

else if ((command.indexOf("ATM") > -1) && (command.length()==6)){
      Serial1.println("Now this traps the command ATMxxx");
    }

This works perfectly, just one line.