[Yanel-dev] direct file access

simon litwan simon.litwan at wyona.com
Thu May 7 11:12:57 CEST 2009


Guillaume Déflache schrieb:
> Michael Wechner schrieb:
>> simon litwan schrieb:
>>> simon litwan schrieb:
>>>> Michael Wechner schrieb:
>>>>> simon litwan schrieb:
>>>>>> [...]
>>>>>>>
>>>>>>> no way via the API. But you could do a cast on a specific file 
>>>>>>> based implementation
>>>>>> even if i cast to VFSNode there is nothing to access the file.
>>>>>>
>>>>> adding such a VFSNode specific method could be discussed of course 
>>>>> ;-)
>>>> i think it would make sense.
>>> should i provide a patch. with something like
>>>
>>> public File getFile() {
>>
>> my guts feeling tells me that introducing such a method is a bad 
>> thing, mainly because
>> one breaks the exchangebility of the data repo implementation. It 
>> doesn't hurt the API or anything like that, but
>> it somehow encourages "bad behaviour". WDOT?
>
> I think it's not so bad as breaking it would be intentional by adding 
> a cast, and that alone makes it explicit and greppable. Also doing 
> this is not encouraging anything as you have to put a little extra 
> effort (granted only a few more characters) to do it, which is IMHO 
> better than having to give up using Yanel altogether! ;)
i agree. but it's not about give up using yanel, rather give up using yarep.
>
>
>> As said I would rather first talk to the xuggle guys, especially 
>> since they really seem to be into Open Source.
>
> Sure, it would be nicer.

as i wrote before, i found a thread where they talk about 
Input/OutputStreams but seems to be some effort. and at the moment i can 
not wait, and i also have not really the time to implement this by my self.

now i found a new approach. i'm using yarep as before except if i need 
the file. when i need the file i ask the repo for its configFile and 
read out the path to the content and construct the file path.

cheers
simon


More information about the Yanel-development mailing list