PHPTAL package name

View: New views
8 Messages — Rating Filter:   Alert me  

PHPTAL package name

by Kornel Lesinski-5 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


I've been informed on #pear that PHPTAL package should be renamed to HTML_Template_PHPTAL. That category definitely suits the project, but as far as I'm aware, this also requires change of package name and class names.

Just change of package name doesn't sound very bad, it'll only require existing pear users to uninstall old package first (right?), but change of class name prefix seems very disruptive to me. It would require changes not only all over PHPTAL codebase, but also in all existing PHPTAL-based projects/framework adapters and some 3rd party extensions.

I could provide wrappers or dummy classes that inherit new ones under old names, but that would be messy and nearly double number of files that have to be loaded (startup performance is PHPTAL's weak point already, and I don't want PHPTAL to be perceived as bloated and high overhead).

Also, without real namespaces class names that are already overly long (e.g. PHPTAL_Php_Attribute_TAL_Condition) would get even longer. Some of those classes are visible to users.


I wouldn't mind renaming classes when migrating to PEAR2. With real namespaces these problems are minuscule.


So my questions are:

Is it possible to have "PHPTAL" package in HTML/Template category? or HTML_Template_PHPTAL package that uses only PHPTAL as class name prefix?
Can renaming be deferred until PEAR2?

--
regards, Kornel


--
PEAR Development Mailing List (http://pear.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


PHPTAL package name

by Kornel Lesinski-5 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hello, any advice on this?

On 10 Nov 2009, at 23:41, Kornel Lesiński wrote:

> I've been informed on #pear that PHPTAL package should be renamed to  
> HTML_Template_PHPTAL. That category definitely suits the project,  
> but as far as I'm aware, this also requires change of package name  
> and class names.
>
> Just change of package name doesn't sound very bad, it'll only  
> require existing pear users to uninstall old package first (right?),  
> but change of class name prefix seems very disruptive to me. It  
> would require changes not only all over PHPTAL codebase, but also in  
> all existing PHPTAL-based projects/framework adapters and some 3rd  
> party extensions.
>
> I could provide wrappers or dummy classes that inherit new ones  
> under old names, but that would be messy and nearly double number of  
> files that have to be loaded (startup performance is PHPTAL's weak  
> point already, and I don't want PHPTAL to be perceived as bloated  
> and high overhead).
>
> Also, without real namespaces class names that are already overly  
> long (e.g. PHPTAL_Php_Attribute_TAL_Condition) would get even  
> longer. Some of those classes are visible to users.
>
>
> I wouldn't mind renaming classes when migrating to PEAR2. With real  
> namespaces these problems are minuscule.
>
>
> So my questions are:
>
> Is it possible to have "PHPTAL" package in HTML/Template category?  
> or HTML_Template_PHPTAL package that uses only PHPTAL as class name  
> prefix?
> Can renaming be deferred until PEAR2?

--
regards, Kornel


--
PEAR Development Mailing List (http://pear.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: PHPTAL package name

by tfk :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hey Kornel,

you are correct, changing the packagre name requires changing the
class names and possibly the file structure in your VCS
(HTML/Template/PHPTAL.php, etc.).

I don't know about the upgrade procedure for your existing users, but
my guess is that if they use a pear-install already, the "new" package
name would hint at a totally new package for the user. E.g. if they
did pear install PHPTAL before, they now need to do pear install
HTML_Template_PHPTAL.

Let me know if this answers your question.

Till

On Thu, Nov 26, 2009 at 5:41 PM, Kornel Lesinski
<kornel@...> wrote:

> Hello, any advice on this?
>
> On 10 Nov 2009, at 23:41, Kornel Lesiński wrote:
>
>> I've been informed on #pear that PHPTAL package should be renamed to
>> HTML_Template_PHPTAL. That category definitely suits the project, but as far
>> as I'm aware, this also requires change of package name and class names.
>>
>> Just change of package name doesn't sound very bad, it'll only require
>> existing pear users to uninstall old package first (right?), but change of
>> class name prefix seems very disruptive to me. It would require changes not
>> only all over PHPTAL codebase, but also in all existing PHPTAL-based
>> projects/framework adapters and some 3rd party extensions.
>>
>> I could provide wrappers or dummy classes that inherit new ones under old
>> names, but that would be messy and nearly double number of files that have
>> to be loaded (startup performance is PHPTAL's weak point already, and I
>> don't want PHPTAL to be perceived as bloated and high overhead).
>>
>> Also, without real namespaces class names that are already overly long
>> (e.g. PHPTAL_Php_Attribute_TAL_Condition) would get even longer. Some of
>> those classes are visible to users.
>>
>>
>> I wouldn't mind renaming classes when migrating to PEAR2. With real
>> namespaces these problems are minuscule.
>>
>>
>> So my questions are:
>>
>> Is it possible to have "PHPTAL" package in HTML/Template category? or
>> HTML_Template_PHPTAL package that uses only PHPTAL as class name prefix?
>> Can renaming be deferred until PEAR2?
>
> --
> regards, Kornel
>
>
> --
> PEAR Development Mailing List (http://pear.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PEAR Development Mailing List (http://pear.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: PHPTAL package name

by Kornel Lesinski-5 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On 26 Nov 2009, at 18:23, till wrote:

> you are correct, changing the packagre name requires changing the
> class names and possibly the file structure in your VCS
> (HTML/Template/PHPTAL.php, etc.).
>
> I don't know about the upgrade procedure for your existing users, but
> my guess is that if they use a pear-install already, the "new" package
> name would hint at a totally new package for the user. E.g. if they
> did pear install PHPTAL before, they now need to do pear install
> HTML_Template_PHPTAL.

That's not good. That means not only reinstall, but also changes in  
users' code.

> Let me know if this answers your question.


I'd like to know if "PHPTAL" is acceptable as package name?

--
regards, Kornel


--
PEAR Development Mailing List (http://pear.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: PHPTAL package name

by tfk :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Fri, Nov 27, 2009 at 11:01 AM, Kornel Lesinski
<kornel@...> wrote:

> On 26 Nov 2009, at 18:23, till wrote:
>
>> you are correct, changing the packagre name requires changing the
>> class names and possibly the file structure in your VCS
>> (HTML/Template/PHPTAL.php, etc.).
>>
>> I don't know about the upgrade procedure for your existing users, but
>> my guess is that if they use a pear-install already, the "new" package
>> name would hint at a totally new package for the user. E.g. if they
>> did pear install PHPTAL before, they now need to do pear install
>> HTML_Template_PHPTAL.
>
> That's not good. That means not only reinstall, but also changes in users'
> code.
>
>> Let me know if this answers your question.
>
>
> I'd like to know if "PHPTAL" is acceptable as package name?
>

Afaik, no. But feel free to go on IRC to ask.

IMHO, the change is not so huge:

require_once 'HTML/Template/PHPTAL.php';
$phptal = new HTML_Template_PHPTAL('my_template_file.xhtml');

Till

Till

--
PEAR Development Mailing List (http://pear.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: PHPTAL package name

by Kornel Lesinski-5 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On 28.11.2009, at 11:17, till wrote:
>
> Afaik, no. But feel free to go on IRC to ask.
>
> IMHO, the change is not so huge:
>
> require_once 'HTML/Template/PHPTAL.php';
> $phptal = new HTML_Template_PHPTAL('my_template_file.xhtml');


It also affects base classes for pre/post filters, translation service, custom attributes, and probably prefix of functions for custom expression modifiers. In latest version I've exposed PHPTAL's DOM with dozen of PHPTAL_Dom_* classes.

I'm not keen on having 3 times longer prefix.

Can PEAR2 packages be published yet?

--
regards, Kornel


--
PEAR Development Mailing List (http://pear.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: PHPTAL package name

by tfk :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

2009/11/28 Kornel Lesiński <kornel@...>:

> On 28.11.2009, at 11:17, till wrote:
>>
>> Afaik, no. But feel free to go on IRC to ask.
>>
>> IMHO, the change is not so huge:
>>
>> require_once 'HTML/Template/PHPTAL.php';
>> $phptal = new HTML_Template_PHPTAL('my_template_file.xhtml');
>
>
> It also affects base classes for pre/post filters, translation service, custom attributes, and probably prefix of functions for custom expression modifiers. In latest version I've exposed PHPTAL's DOM with dozen of PHPTAL_Dom_* classes.
>
> I'm not keen on having 3 times longer prefix.
>
> Can PEAR2 packages be published yet?
>

Yeah, I think especially Brett would be happy to help you. ;)

--
PEAR Development Mailing List (http://pear.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: PHPTAL package name

by Greg Beaver-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Kornel Lesiński wrote:

> On 28.11.2009, at 11:17, till wrote:
>>
>> Afaik, no. But feel free to go on IRC to ask.
>>
>> IMHO, the change is not so huge:
>>
>> require_once 'HTML/Template/PHPTAL.php';
>> $phptal = new HTML_Template_PHPTAL('my_template_file.xhtml');
>
>
> It also affects base classes for pre/post filters, translation service, custom attributes, and probably prefix of functions for custom expression modifiers. In latest version I've exposed PHPTAL's DOM with dozen of PHPTAL_Dom_* classes.
>
> I'm not keen on having 3 times longer prefix.
>
> Can PEAR2 packages be published yet?

Yes.  You should expect them to be alpha stability at least until pyrus
is officially released (still need some bodies to work on the bug tracker)

Greg

--
PEAR Development Mailing List (http://pear.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php