I've made several changes to accommodate several issues raised on this
list. See
https://github.com/cataphract/php-src/compare/break_iterator
All but the first two commits are new. Please see the test cases for
doubts concerning usage.
--
Gustavo Lopes
--
PHP Internals - PHP Runtime Devel
Hi!
>> I understand that, but I have no idea how to write proper rules for word
>> boundaries, I just want to tell it "give me word boundaries" but not by
>> saying createWordBoundaries() but by doing createIterator($type) where
>> $type == WORD_BOUNDARIES.
>
> Why? This makes no sense to me. Why
On Mon, 04 Jun 2012 21:09:28 +0200, Stas Malyshev
wrote:
I understand that, but I have no idea how to write proper rules for word
boundaries, I just want to tell it "give me word boundaries" but not by
saying createWordBoundaries() but by doing createIterator($type) where
$type == WORD_BOUNDA
Hi!
> You can create a RuleBasedBreakIterator with any rules you choose. The
I understand that, but I have no idea how to write proper rules for word
boundaries, I just want to tell it "give me word boundaries" but not by
saying createWordBoundaries() but by doing createIterator($type) where
$ty
On Fri, 01 Jun 2012 11:31:13 -0700, Stas Malyshev wrote:
BreakIterator also exposes other native methods:
getAvailableLocales(), getLocale() and factory methods to build
several predefined types of BreakIterators: createWordInstance()
for word boundaries, createCharacterInstance() for locale
de
Hi!
> I've wrapped ICU's BreakIterator and RuleBasedBreakIterator. I stopped
> short of adding a procedural interface. I think there's a larger
> expectation of a having an OOP interface when working with iterators.
> What do you think? If there's no procedural interface, I'll change the
> ins
HI,
On Fri, Jun 1, 2012 at 5:02 PM, Gustavo Lopes wrote:
> In any case, I'll rename the classes before merging.
You may have missed part of my replies. One key part was: to discuss
it before doing anything.
This is only one day discussion and I don't feel like we have a long
term decision abou
On Fri, 01 Jun 2012 15:35:13 +0200, Maciek Sokolewicz wrote:
In my personal opinion, all Intl classes should be prefixed with
Intl. It's not so much that BreakIterator is a very common name, but
rather a very ambiguous name that may point to many different things.
Just by the fact that multiple p
On Fri, 1 Jun 2012 15:56:59 +0200, Nikita Popov wrote:
On Fri, Jun 1, 2012 at 9:57 AM, Gustavo Lopes
wrote:
We currently don't use namespaces in any of the core extensions.
Does anything prevent us from starting to do so?
other symbols in ext/intl are in the global namespace; to put
BreakIte
On Fri, 1 Jun 2012 15:37:30 +0200, Pierre Joye wrote:
On Fri, Jun 1, 2012 at 1:34 PM, Gustavo Lopes
wrote:
So would you have RuleBasedBreakIterator renamed
IntlRuleBasedBreakIterator
too?...
Ideally we would yes, while they are less common and less aimed to be
seen as part of another API.
On Fri, Jun 1, 2012 at 9:57 AM, Gustavo Lopes wrote:
> We currently don't use namespaces in any of the core extensions.
Does anything prevent us from starting to do so?
> other symbols in ext/intl are in the global namespace; to put BreakIterator
> in a new namespace would be inconsistent -- and
hi,
On Fri, Jun 1, 2012 at 1:34 PM, Gustavo Lopes wrote:
> So would you have RuleBasedBreakIterator renamed IntlRuleBasedBreakIterator
> too?...
Ideally we would yes, while they are less common and less aimed to be
seen as part of another API.
>I find it very hard to believe that "BreakIterato
On 01-06-2012 13:34, Gustavo Lopes wrote:
On Fri, 1 Jun 2012 12:58:37 +0200, Pierre Joye wrote:
On Fri, Jun 1, 2012 at 10:02 AM, Benjamin Eberlei
wrote:
How about IntlBreakIterator? I agree with David that the naming is very
weird, it doesn't hint at something from Intl but another crazy spl
i
On Fri, 1 Jun 2012 12:58:37 +0200, Pierre Joye wrote:
On Fri, Jun 1, 2012 at 10:02 AM, Benjamin Eberlei
wrote:
How about IntlBreakIterator? I agree with David that the naming is
very
weird, it doesn't hint at something from Intl but another crazy spl
iterator :-)
Asides from date related cla
hi,
On Fri, Jun 1, 2012 at 10:02 AM, Benjamin Eberlei wrote:
> How about IntlBreakIterator? I agree with David that the naming is very
> weird, it doesn't hint at something from Intl but another crazy spl
> iterator :-)
I agree too. BreakIterator is a very common name and I suspect
possible nami
How about IntlBreakIterator? I agree with David that the naming is very
weird, it doesn't hint at something from Intl but another crazy spl
iterator :-)
On Fri, Jun 1, 2012 at 9:57 AM, Gustavo Lopes wrote:
> On Fri, 01 Jun 2012 09:40:19 +1000, David Muir wrote:
>
>> Coming from a "pleb", my only
On Fri, 01 Jun 2012 09:40:19 +1000, David Muir wrote:
Coming from a "pleb", my only concern is the name if the class is in
the
global scope. A "BreakIterator" to me sounds like something related
to
breaking out of a looping structure, and not something used for
iterating over various language s
Coming from a "pleb", my only concern is the name if the class is in the
global scope. A "BreakIterator" to me sounds like something related to
breaking out of a looping structure, and not something used for
iterating over various language structure boundaries.
If it's in a ICU namespace, then it's
Hi
I've wrapped ICU's BreakIterator and RuleBasedBreakIterator. I stopped
short of adding a procedural interface. I think there's a larger
expectation of a having an OOP interface when working with iterators.
What do you think? If there's no procedural interface, I'll change the
instances of
19 matches
Mail list logo