On Tue, Mar 15, 2011 at 1:54 PM, Nick Pope wrote:
> Currently we have:
>
> SplFileInfo -- information/metadata about a file.
> |
> V
> SplFileObject -- modify/access contents of a file.
>
> It could make sense to subclass this to provide methods for accessing
> information a
On 15/03/11 10:01, Peter Cowburn wrote:
For countBytes() how is that different from SplFileInfo's getSize() ?
As for countWords() and the others, I think this crosses the line (in
my view) over what a "File Object" should provide.
Hi Peter & Sebastian,
Bah. It isn't. Obviously that was going
Hi all,
On 15 March 2011 09:35, Nick Pope wrote:
> Hi Sebastian,
>
> Since Etienne brought it up, would it not also make sense for you to
> implement countWords() and countBytes()?
For countBytes() how is that different from SplFileInfo's getSize() ?
As for countWords() and the others, I think t
Hello Nick,
Might be fun, I'll have a look at it. Is the stuff I have done so far any
good? I've got only a little C experience, so any feedback is good!
cheers
On Tue, Mar 15, 2011 at 9:35 AM, Nick Pope wrote:
> Hi Sebastian,
>
> Since Etienne brought it up, would it not also make sense for
Hi Sebastian,
Since Etienne brought it up, would it not also make sense for you to
implement countWords() and countBytes()?
Also, unicode issues aside, it might still be nice to implement
countChars().
And finally, so that it provides all most of the functionality of the
GNU wc program, th
Hello,
That makes perfect sense. I have raised a feature request and have attached
a patch containing both countLines() method implementation and phpt tests.
thx
On Sun, Mar 13, 2011 at 9:39 PM, Etienne Kneuss wrote:
> On Mar 11 23:22:04, Sebastian Marek wrote:
> > Hi,
> >
> > I have recently
On Mar 11 23:22:04, Sebastian Marek wrote:
> Hi,
>
> I have recently used SplFileObject to work with files. I was lacking a bit
> of functionality in there regarding counting number of lines in a given
> file. Although I could just load contents of the file to an array and check
> it size, I thoug