Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #19374

Re: RAM FileDescriptor

From David Lamb <dalamb@cs.queensu.ca>
Newsgroups comp.lang.java.programmer
Subject Re: RAM FileDescriptor
Date 2012-10-15 15:07 -0400
Organization A noiseless patient Spider
Message-ID <k5hmue$vae$1@dont-email.me> (permalink)
References <f6d1d840-9769-447a-893e-f8cce07d2d23@googlegroups.com> <k5hl0v$i7r$1@dont-email.me>

Show all headers | View raw


On 15/10/2012 2:41 PM, Jeff Higgins wrote:
> On 10/15/2012 02:08 PM, bob smith wrote:
>> Let's say you have a function that plays a movie that is passed in as
>> a FileDescriptor.  Is there any way to load the movie into RAM and get
>> a FileDescriptor for the RAM?
> Looking here:
> <http://docs.oracle.com/javase/7/docs/api/java/io/class-use/FileDescriptor.html>
> the most likely route seems to be java.io.RandomAccessFile.getFD(). But
> I don't know what "a FileDescriptor for the RAM" means. Will you clarify?

I doubt it exists as a general concept and thus probably doesn't exist 
in Java. I seem to recall that some operating systems from many years 
ago let you map a file into RAM and operate on it from there, but I'm 
moderately sure that feature either went through the standard file 
system stuff and was (nearly) invisible, or you accessed a massive byte 
array directly. The former corresponds to people's advice to use a 
FileInputStream amd the latter to a ByteInputStream as appropriate.

Wouldn't your movie exceed the capacity of RAM? or are you limiting 
yourself to short ones?

Back to comp.lang.java.programmer | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

RAM FileDescriptor bob smith <bob@coolfone.comze.com> - 2012-10-15 11:08 -0700
  Re: RAM FileDescriptor Lew <lewbloch@gmail.com> - 2012-10-15 11:27 -0700
  Re: RAM FileDescriptor Eric Sosman <esosman@comcast-dot-net.invalid> - 2012-10-15 14:34 -0400
  Re: RAM FileDescriptor Jeff Higgins <jeff@invalid.invalid> - 2012-10-15 14:41 -0400
    Re: RAM FileDescriptor David Lamb <dalamb@cs.queensu.ca> - 2012-10-15 15:07 -0400
      Re: RAM FileDescriptor Daniel Pitts <newsgroup.nospam@virtualinfinity.net> - 2012-10-15 12:59 -0700
        Re: RAM FileDescriptor Arne Vajhoej <arne@vajhoej.dk> - 2012-10-17 11:45 -0400
          Re: RAM FileDescriptor David Lamb <dalamb@cs.queensu.ca> - 2012-10-17 15:08 -0400
    Re: RAM FileDescriptor Jeff Higgins <jeff@invalid.invalid> - 2012-10-15 15:25 -0400
  Re: RAM FileDescriptor Jeff Higgins <jeff@invalid.invalid> - 2012-10-15 16:22 -0400
    Re: RAM FileDescriptor Jeff Higgins <jeff@invalid.invalid> - 2012-10-15 16:26 -0400
  Re: RAM FileDescriptor Jim Janney <jjanney@shell.xmission.com> - 2012-10-16 12:40 -0600
  Re: RAM FileDescriptor Arne Vajhoej <arne@vajhoej.dk> - 2012-10-17 11:43 -0400
  Re: RAM FileDescriptor Jan Burse <janburse@fastmail.fm> - 2012-10-17 17:55 +0200

csiph-web