gnump3d-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnump3d-devel] request for library function: show files


From: Adam DiCarlo
Subject: Re: [Gnump3d-devel] request for library function: show files
Date: 02 Nov 2003 11:24:58 -0600
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2

Steve Kemp <address@hidden> writes:

>   No, that's not how I'd envisaged that working, that just returns a
>  formatted string containing the layout of a single file.

Ah, ok.  It's something to build from though.

>   This is identical to the tagcache.pm code which I pointed to
>  previously using either "formatMultipleSongTags", or
>  "_formatSingleFile".

Yes -- I see it calls those.

>   I was understanding your previous requirement to have something like
>   this:
> 
>       sub getHTMLOutputForFiles( @ )
>       {
>          # returns something like
>          "<tr><td>....</.td></tr>\n" .  # For first file.
>          "<tr><td>...</td></tr>\n"   .  # For second file.
>       }
> 
>   If all you need is the ability to process a format string from a 
>  file then you should use the global tag cache object directly, it 
>  does the job already.

Right.

My requirement is something equivalent to what's happening in the bulk
of serveDirectory.  Given:
 - a set of files
 - the user preferences
 - possibly a format string (or else use the configured song format
   default)

Given those, produce a list which is a buncha HTML lines you can spit
out (sorted and all).

As I see it, this lets you reduce code all over the place.  Not only
in serveDirectory, but in search.pm, random.pm, recent.pm, etc etc
etc.  Right now they each have their own way of rendering files.

-- 
.....Adam Di address@hidden<URL:http://www.debian.org/>





reply via email to

[Prev in Thread] Current Thread [Next in Thread]