Menu
Menu
DaniWeb
Log In
Sign Up
Read
Contribute
Meet
Search
Search
About 1,000 results for
inputstream
- Page 1
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesCherrill
InputStream
, as the Java API doc makes very clear, is an …[] array. So, you can declare [I]is[/I] as an
InputStream
reference variable, but you have to instantiate one of its… your integer. oh, and ps, read the API doc for
InputStream
.read() to find out what it returns (hint: it's…
Re: Difference between bufferedReader and inputStream
Programming
Software Development
8 Years Ago
by JamesCherrill
InputStream
reads bytes one at a time - no character set processing and no buffering. It's the parent class for stream input, but rarely used becuase one of its subclasses is usually more appropriate (eg BufferedReader) BufferedReader reads characters and buffers its input. If your input is text, always use BufferedReader.
making wav files continuously play
Programming
Software Development
16 Years Ago
by enes
InputStream
in = new FileInputStream(new File("Pirates of Caribbean.wav")); AudioStream musicin; musicin= new AudioStream(in); AudioPlayer.player.start(musicin); i wrote above it works but after sometime music ends but i want to play it always how can i achieve it
InputStream's undefined behaviour
Programming
Software Development
11 Years Ago
by bguild
It's surprisingly how little documentation `java.io.
InputStream
` has for a class of its complexity and importance.… exception. With the documentation as it is, a certain `
InputStream
` might throw an exception upon any attempt to read an…of all. Even in comparison to the other methods of `
InputStream
`, `skip` makes very few promises about what it will…
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesKox
…(byte[] b) throws IOException { try { int number = 0;
InputStream
is = new
InputStream
(b); BufferedReader br = new BufferedReader(is); while ((b = br…CODE] When i compile the code it highlights "
InputStream
is = new
InputStream
(b);" and says it can't be instantiated…
null inputstream
Programming
Software Development
14 Years Ago
by ceyesuma
…class PropertyWriter { public String line; public String path; public
InputStream
is; public PropertyWriter() { } public void StreamToString(String path,…: "+getPath()); PropertyWriter pw = new PropertyWriter();
InputStream
is=pw.getClass().getResourceAsStream(path); setIs(is); } …
Reading multiple XML files from inputstream
Programming
Software Development
12 Years Ago
by lucas.ploeg
… can help me.. I already obtained the
inputstream
here.. but now I have to split it…from the stream... [code]public void run() { try{
InputStream
is = client.getInputStream(); parse(is); //System out the … to make the document.. [code]public static void parse(
InputStream
xml) { try { //File file = new File…
Re: istream& inputStream Overload
Programming
Software Development
6 Years Ago
by jnneson
… Operation OverLoad. istream &operator>>(istream&
inputStream
, Date& dateObject) { string inVariable[20], string valueHolder….setMinute(valueHolder[5]); second = dateObject.setSecond(valueHolder[6]); return
inputStream
; } I am lost with the overloading of >>…
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by abbie
…finishes. So, if you're forced to use
InputStream
as the parameter, you can use BufferedReader to… read the
InputStream
. For instance, if 'isr' is your
InputStream
, it's something like BufferedReader …br = new BufferedReader(isr); And converting the
inputstream
into String (using br.readLine()), you can then …
Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesKox
…'m trying to create a method where it takes a
InputStream
as a parameter, reads the stream and returns the number… code so far... [CODE] public int countNo(
InputStream
stream)throws IOException { try { stream = new
InputStream
(); while ((stream = input.read()) != -1) { input.…
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesKox
[QUOTE=JamesCherrill;872977]
InputStream
, as the Java API doc makes very clear, is an …[] array. So, you can declare [I]is[/I] as an
InputStream
reference variable, but you have to instantiate one of its… your integer. oh, and ps, read the API doc for
InputStream
.read() to find out what it returns (hint: it's…
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesKox
… int read(byte[] b) throws IOException { try { int number = 0;
InputStream
is = new ByteArrayInputStream(b); BufferedReader br = new BufferedReader(is); while… used a ByteArrayInputStream to initialise [I]is[/I] as an
InputStream
, but i don't know how to "[I]instantiate…
doubt about InputStream.read() function
Programming
Software Development
13 Years Ago
by ayan2587
…am trying to understand as to how this
InputStream
.read(byte[] b) function actually works. …I have a doubt regarding the
InputStream
.read(byte[] b) function. The code is … public static int count(String filename) throws IOException {
InputStream
is = new BufferedInputStream(new FileInputStream(filename)); byte[] c…
istream& inputStream Overload
Programming
Software Development
6 Years Ago
by jnneson
…... thanks istream &operator>>(istream&
inputStream
, Date& dateObject) { string inVariable[20];
inputStream
.getline(inVariable, 20, "\n"…
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by BestJewSinceJC
… it, use FileReader or FileInputStream, not
InputStream
, since you cannot open a File with
InputStream
. Then use a while loop like they…
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesCherrill
… right! ByteArrayInputStream is a subclass of
InputStream
, ie it's a "kind" of
InputStream
. You have created an instance of…
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesKox
… right! ByteArrayInputStream is a subclass of
InputStream
, ie it's a "kind" of
InputStream
. You have created an instance of…
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesKox
… various examples over the net. I've read about the
InputStream
, but there seems to be so many different examples on…
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by alias120
[url]http://java.sun.com/j2se/1.4.2/docs/api/java/io/
InputStream
.html[/url] Check this link out, something information that might prove helpful. -alias
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesKox
….sun.com/j2se/1.4.2/docs/api/java/io/
InputStream
.html[/url] Check this link out, something information that might…
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by masijade
Sorry, but his question started [quote]create a method where it takes a
InputStream
as a parameter[/quote] and not, necessarily, anything to do with a file. If you want the size of a file, simply use the length() method.
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesKox
Thanks for the replies guys! I'm just coming back to this program today. BestJewSinceJC, i'm using an
inputStream
, but your reply has been useful anyways. Thanks.
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesKox
… int read(byte[] b) throws IOException { try { int number = 0;
InputStream
is = new ByteArrayInputStream(b); while ((b = number.read()) != -1) { number…
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesKox
… as of post #6.[/QUOTE] Yes i'm taking an
InputStream
, and trying to read the stream and return the number…
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesKox
… answer... [QUOTE]Write a method called countNo which takes an
InputStream
as a parameter, reads the stream and returns the number…
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesKox
… was instructed the first few replies.... [CODE] public int countNo(
InputStream
stream)throws IOException { try { int number = 0; while ((stream = number…
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by Ezzaral
You read from 'stream'. That is your
InputStream
object that is being passed into the method.
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesKox
[QUOTE=Ezzaral;873304]You read from 'stream'. That is your
InputStream
object that is being passed into the method.[/QUOTE] Okay, …
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesKox
…] Alright. Here's my code now... [CODE] public int countNo(
InputStream
stream)throws IOException { try { int number = 0; while ((number = stream…
Re: Help with a inputstream...
Programming
Software Development
14 Years Ago
by JamesKox
…. Will it be something like this... [code] public int countNo(
InputStream
stream)throws IOException { int number = 0; try { while ((stream.read…
1
2
3
17
Next
Last
Search
Search
Forum Categories
Hardware/Software
Programming
Digital Media
Community Center
Latest Content
Newest Topics
Latest Topics
Latest Posts
Latest Comments
Top Tags
Topics Feed
Social
Meet People
Forums
Top Members
Community Functions
DaniWeb Premium
Newsletter Archive
Markdown Syntax
Community Rules
Developer APIs
Connect API
Forum API Docs
Tools
SEO Backlink Checker
Legal
Terms of Service
Privacy Policy
FAQ
About Us
Advertise
Contact Us
© 2024 DaniWeb® LLC