Results 1 to 3 of 3

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Eclipse Plugin Developer aphex's Avatar
    Join Date: Mar:2003
    Location: Karlsruhe
    Posts: 546

    ant + java + console

    Sunspot, ant. , 2 , . :

    Code:
    System.out.println("===========Main Menu========================");
    				System.out.println(" 	t - Temperature							");
    				System.out.println("	a - Accelometer							");
    				System.out.println("	l - Light								");
    				System.out.println("	r - Random Number						");
    				System.out.println("	m - Main Menu							");
    				System.out.println("	q - quit								");
    				System.out.println("============================================");
    				menu=readString("");
    			}
    :
    Code:
    public static String readString(String text){
    		Scanner in = new Scanner(System.in);
    		
    		return in.nextLine();
    		
    		
    	}
    ?
    We are drowning in information, but starving for knowledge and time!

  2. #2
    Registered User
    Join Date: Aug:2006
    Location:
    Posts: 4,052
    javadoc- scanner
    Advances this scanner past the current line and returns the input that was skipped. This method returns the rest of the current line, excluding any line separator at the end. The position is set to the beginning of the next line.

    Since this method continues to search through the input looking for a line separator, it may buffer all of the input searching for the line to skip if no line separators are present.
    .. .


    System.in BufferedReader javadoc.


  3. #3
    Eclipse Plugin Developer aphex's Avatar
    Join Date: Mar:2003
    Location: Karlsruhe
    Posts: 546
    solar_sea, Buffered Reader, Console
    We are drowning in information, but starving for knowledge and time!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

Copyright © 1999-2011 . .
iskamPC.com | mobility.BG | Bloody's Techblog | | 3D Vision Blog |