On 01/04/2011 13:04, Paul Alfille wrote:
> Have you looked at the "structure" entries? Does it give you the
> information you need? Otherwise, I think your idea has merit. This
> information could be included in every owserver response (with a bump
> in protocol number and preserving backwards compatibility).
I did not look at the structure directory. Indeed, there is lots
of useful doc. In there a documentation somewhere about the meaning
of the contents of the files under this directory ?
I will look at this and see if my proposal is still useful or not.
Regards,
Vincent
> Paul Alfille
>
> On Fri, Apr 1, 2011 at 6:07 AM, Vincent Danjean <[email protected]> wrote:
>> Hi,
>>
>> I would like to propose a new command for owserver. Currently, when
>> we want to list directories, several commands are available, at least
>> DIR and DIRALLSLASH. Moreover, we can use flags in the command to
>> add (or not) to the listing system files.
>> If a software want automatically scan a directory and know which
>> kind of files are present, it needs at least two invocations of
>> DIRALLSLASH to discove the properties of directory entries (system or
>> not, directory or file). And some other properties are known by
>> owfs but cannot be discovered by software. I mean:
>> - is the file readable ?
>> - is the file writable ?
>> - can the file contents change ? (never for the 'type' property for example)
>> - what is the type of the data ? (float, int, string)
>> - ...
>>
>> I can think of this kind of flags:
>> r: readable
>> w: writable
>> d: directory (R/W does not apply ?)
>> i: immuable (contents never changes)
>> s: system file
>> ti: contents is always an integer
>> tf: contents is always a double
>> ts: contents is a string
>> l: this file is a link (ie alias)
>>
>> The format of the answer can be problematic if all POSIX filename are
>> allowed for aliases and if we want a ASCII answer. A possible format would
>> be for each entry:
>> flags1 flags2 ... name:X [link:Y]
>> filename1
>> [filename2...]
>> where flagsX are previous flags (boolean properties)
>> and name:X, link:Y, ... are properties with argument that will follow
>> in the next X, Y lines.
>> In my example, there will nearly always be name:1 (name of the file
>> on one line, ie without "\n" in the name of the file)
>> And link:Y would be present for aliases (generally, Y would be 1
>> unless there is "\n" in the target of the alias)
>>
>> What do you think of this ?
>> And is the info (immuable, format, ...) already exported by drivers ?
>>
>> This command can be extended over time to give more info if needed
>> (client should ignore unknown attributes, or the request can include
>> before the path the list of attributes we are interested in)
>>
>> Regards,
>> Vincent
>>
>> ------------------------------------------------------------------------------
>> Create and publish websites with WebMatrix
>> Use the most popular FREE web apps or write code yourself;
>> WebMatrix provides all the features you need to develop and
>> publish your website. http://p.sf.net/sfu/ms-webmatrix-sf
>> _______________________________________________
>> Owfs-developers mailing list
>> [email protected]
>> https://lists.sourceforge.net/lists/listinfo/owfs-developers
>>
>
> ------------------------------------------------------------------------------
> Create and publish websites with WebMatrix
> Use the most popular FREE web apps or write code yourself;
> WebMatrix provides all the features you need to develop and
> publish your website. http://p.sf.net/sfu/ms-webmatrix-sf
> _______________________________________________
> Owfs-developers mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/owfs-developers
>
--
Vincent Danjean Adresse: Laboratoire d'Informatique de Grenoble
Téléphone: +33 4 76 61 20 11 ENSIMAG - antenne de Montbonnot
Fax: +33 4 76 61 20 99 ZIRST 51, avenue Jean Kuntzmann
Email: [email protected] 38330 Montbonnot Saint Martin
------------------------------------------------------------------------------
Create and publish websites with WebMatrix
Use the most popular FREE web apps or write code yourself;
WebMatrix provides all the features you need to develop and
publish your website. http://p.sf.net/sfu/ms-webmatrix-sf
_______________________________________________
Owfs-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/owfs-developers