Why is class and stream | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 3

Why is class and stream

in java

22nd Dec 2017, 9:33 AM
Gaurav Pratap
Gaurav Pratap - avatar
2 Answers
+ 3
All Java streams are derived from InputStream ( java.io.InputStream ) and OutputStream ( java.io.OutputStream ) classes. They are abstract base classes meant for otherstream classes. The System.in is the inputstream class derivative and analogically System.out is the output counterpart.
22nd Dec 2017, 10:13 AM
Hritik Kumar
Hritik Kumar - avatar
+ 3
A class--the basic building block of an object-oriented language such asJava--is a template that describes the data and behavior associated with instances of thatclass. When you instantiate a class you create an object that looks and feels like other instances of the same class
22nd Dec 2017, 10:14 AM
Hritik Kumar
Hritik Kumar - avatar