how to detect end of file in java

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • shimit
    New Member
    • Nov 2008
    • 1

    how to detect end of file in java

    hiii,
    i have a text file and i have to print all values using file io system..
    can you tell me how to check end of file..
    thanks in advance.
  • JosAH
    Recognized Expert MVP
    • Mar 2007
    • 11453

    #2
    Originally posted by shimit
    i have a text file and i have to print all values using file io system..
    can you tell me how to check end of file..
    thanks in advance.
    All methods return an appropriate sentinel value such as -1 or null; read the API
    documentation for the classes and methods you want to use.

    kind regards,

    Jos

    Comment

    Working...