Re: Re: cvs: php4 /ext/standard filters.c
| From: | Sara Golemon | Date: | Tue, 07 Jan 2003 22:40:28 +0000 |
| Subject: | Re: Re: cvs: php4 /ext/standard filters.c | ||
| References: | 1 2 3 4 5 6 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-93241@lists.php.net to get a copy of this message | ||
oooh yes, good point:
stream_filter_append($fp, "string.base64", "encode");
and
stream_filter_append($fp, "string.base64", "decode");
probably with "encode" being the default behavior. That make
implementation very simple and in fact the toupper/tolower calls should be
similarly combined into a single filter class (string.case ?).
What is the "preferred" way of passing multiple parameters? I know each
filter could handle it differently, but consistency is also a very nice
thing. Coma separated perhaps? Changing the behavior of stream_append to
use an array instead of a string? (might be going a bit far, but would
give maximum flexibility)
> With the current model, the concept is that you can use either the
> filter name or filter parameters to distinguish the ultimate behaviour.
>
> Yes this is a possible headache.
> I am thinking that two separate chains of filters (one for reading and
> one for writing) might make this situation a little easier;
> this way you could have a filtered read stream but leave writing
> unfiltered etc.
>