In a client server programm i have this line
String line = inputStream.readLine();
if (line.startsWith("/adduser")) {
//do code
}
example command " /adduser -id 1022 -p SomePass " I know how to begin the process by the line.startswith , but how can i make the program to read what is after -id and put it in a value and same with -p.