• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Java IO package

 
Ranch Hand
Posts: 486
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Which can be constructed using java.io.File?

1. java.io.FileWriter
2.java.io.FileReader
3.java.io.PrintWriter
4.java.io.BufferedWriter
5.java.io.BufferedReader.

I think it should be 1,2,4,5

Can anyone suggest??
 
author
Posts: 9050
21
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey Dinesh,

Part of the intention of the exam is to teach candidates how to use the API documentation. This question should be very easy for you to research...if you've practiced using the API. If you haven't started using the API yet then you might as well start now because you're going to need to learn how sooner or later! Every Java programmer needs to know how to use the API docs!

hth,

Bert
 
Ranch Hand
Posts: 52
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Dinesh

What Bert has told is perfectly correct, sooner or later you must start reading the APIs.

If I understood your question correct, then the answers from the below choices:


1.FileReader
2.FileWriter
3.PrintWriter
4.BufferedReader
5.BufferedWriter

would be as follows:

1, 2, 3


Some of the Constructors of these classes which takes File as an argument:
FileWriter(File file)

FileReader(File file)

PrintWriter(File file)

BufferedReader(Reader in)

BufferedWriter(Writer out)

HTH
Kris
 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey Dinesh

It s clearly given in API. Just check it out....
 
Bartender
Posts: 6663
5
MyEclipse IDE Firefox Browser Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What is the source of this question ?
 
reply
    Bookmark Topic Watch Topic
  • New Topic