Zend_UTF8 – New API Design
A while ago, I designed the API of Zend_UTF8 to be similar to PHP5’s string functions. So f.e. you just would have had to call Zend_UTF8::strlen() to get the length of a string. I actually wanted to do it that way for PHP6 compatibility reasons.
I gave up on that, as its performance is just too bad. Instead of that, there’s going to be a string object (basically the same API as the Java String Object, so Java developers should be familiar with it) which allows to perform way better, since a string becomes a constant and it won’t have to do the UTF-8 transformation over and over again. There is also going to be a string object for PHP6 which basically does the same while using the PHP6’s string functions.
That might result in more work once we raise the Zend Framework’s requirements to PHP6, but till then it will perform better, which in my opinion is way more important.