Re: [fw-general] Consistency in naming

2007-03-03 Thread Matthew Ratzloff

Hi Thomas,

Actually, most of those are nouns, or double as nouns.  For the ones that 
aren't (Act/Assert, Mime/Decode, etc.), I put in an issue.


For example, Memcached is the name of the product (the memcache daemon, like 
httpd).  In some cases, the class directly corresponds to a recognized name 
or setting, like Console/Getopt or Environment/.../AllowUrlFopen. 
Gdata/ClientLogin is both a noun and the name of the Google API (a "login" 
is the noun form, to "log in" is the verb).  Search and Gdata/CodeSearch are 
both nouns--you are conducting a search.


In some cases, adjectives are more intuitive.  This is the case with 
Controller/Router/Rewrite, Validator/GreaterThan, and Measure/Cooking. 
Since the original name of Measure was Unit, I assume the synonym Measure 
was chosen instead to be more descriptive ("a cooking measure").  It could 
have been something like UnitConverter, I suppose, but I think it's fine as 
is.


So anyway, for the most part, the names are good.  There are just a handful 
that would have to change to create a naming standard.


-Matt

- Original Message - 
From: "Thomas Weidner" <[EMAIL PROTECTED]>

To: "Ralph Schindler" <[EMAIL PROTECTED]>
Cc: "Matthew Ratzloff" <[EMAIL PROTECTED]>; "Zend Framework" 


Sent: Saturday, March 03, 2007 1:46 PM
Subject: Re: [fw-general] Consistency in naming


We would have to rename all nouned classes. This would be probably the 
following ones...


Acl/Assert
Cache/Backend/Memcached
Controller/Response
Controller/Route/Rewrite
Gdata/ClientLogin
Gdata/CodeSearch
Http/Response
Locale
Log
Mail/Protocol/Smtp/Auth/Login
Measure
Measure/Cooking
Measure/Flow
Mime/Decode
Pdf/Cmap/ByteEncoding
Request
Search
Validate
Validate/Between
Validate/GreaterThan
Validate/LessThan
View
Environment/View
Environment/Security/Test/Core/AllowUrlFopen
Environment/Security/Test/Core/AllowUriInclude
Environment/Security/Test/Core/DisplayErrors
Environment/Security/Test/Core/ExposePhp
Environment/Security/Test/Core/RegisterGlobals
Environment/Security/Test/Session/UseTransSid
Environment/View
Soap/AutoDiscover
Translate 




Re: [fw-general] Consistency in naming

2007-03-03 Thread Ralph Schindler




I think you respond related to the issues ZF-944, ZF-945, ZF-946, ZF-947.
I am not member of the devteam, so the decission itself was not done by me.


Thomas, I dont mean to stir the pot, but like alot of issues that start 
on the message board, I didn't know it got transfered to Jira for 
tracking and hence didn't track the issue and weigh in, partially b/c 
for me it seemed like a no brainer for cleanup.


I think Matt R. has made some great points on naming, which I too am a 
bit of a stickler on the namings, at the very least, at the entry point 
for individual components.  My goal would be to have the most inherent 
namings for all the top level components (think of things that get their 
own section in the manual.



Related to your question...
Nouns do not translate good in every language, but I am only german 
native and do not know the english language very well.


Yeah, I am not aware of how other (spoken) languages handle things like 
this, but in english, a Translator is a very common thing.. It seems to 
me that if you start using the zend-framework, (and are looking to 
translate something), you would ask yourself: "does the zend framework 
have a language translator?"




Acl/Assert
Cache/Backend/Memcached
Controller/Response
Controller/Route/Rewrite
Gdata/ClientLogin
Gdata/CodeSearch
Http/Response
Locale
Log
Mail/Protocol/Smtp/Auth/Login
Measure
Measure/Cooking
Measure/Flow
Mime/Decode
Pdf/Cmap/ByteEncoding
Request
Search
Validate
Validate/Between
Validate/GreaterThan
Validate/LessThan
View
Environment/View
Environment/Security/Test/Core/AllowUrlFopen
Environment/Security/Test/Core/AllowUriInclude
Environment/Security/Test/Core/DisplayErrors
Environment/Security/Test/Core/ExposePhp
Environment/Security/Test/Core/RegisterGlobals
Environment/Security/Test/Session/UseTransSid
Environment/View
Soap/AutoDiscover
Translate


Good list, but again, I stress my qualms are only at the top most levels 
of components, not necessarily with every class.  The other thing I like 
to point out is (while english is not the most pragmatic of languages) 
alot of nouns double as verbs, like Measure..  also, things like Rewrite 
can be considered an adjective, describing the type of noun Route is...


In summary, I think ultimately the issues brought up in jira represent 
cases that could benefit the most from a name change to make the 
framework more inherent across the board, and easier to pick up by 
newbie zend frameworks.










Re: [fw-general] Consistency in naming

2007-03-03 Thread Thomas Weidner

Most people declared Zend_Translate over Zend_Translator, because
non native english people know "translate" but do not know 
"translator"...


Why? Do nouns not translate well to other languages?  I don't understand.


I think you respond related to the issues ZF-944, ZF-945, ZF-946, ZF-947.
I am not member of the devteam, so the decission itself was not done by me.

Related to your question...
Nouns do not translate good in every language, but I am only german native 
and do not know the english language very well.


We would have to rename all nouned classes. This would be probably the 
following ones...


Acl/Assert
Cache/Backend/Memcached
Controller/Response
Controller/Route/Rewrite
Gdata/ClientLogin
Gdata/CodeSearch
Http/Response
Locale
Log
Mail/Protocol/Smtp/Auth/Login
Measure
Measure/Cooking
Measure/Flow
Mime/Decode
Pdf/Cmap/ByteEncoding
Request
Search
Validate
Validate/Between
Validate/GreaterThan
Validate/LessThan
View
Environment/View
Environment/Security/Test/Core/AllowUrlFopen
Environment/Security/Test/Core/AllowUriInclude
Environment/Security/Test/Core/DisplayErrors
Environment/Security/Test/Core/ExposePhp
Environment/Security/Test/Core/RegisterGlobals
Environment/Security/Test/Session/UseTransSid
Environment/View
Soap/AutoDiscover
Translate

Please excuse my inperfect english...
But if it is decided to change all classes to noun we should do this 100%.

The original classname Zend_Translate was choosen by me several months ago 
because this class is used when you want to "translate" something... so you 
"translate this text".


As german native I am much more common to "Translate" than "Translator". But 
this is only my view of this issue.


Greetings
Thomas
I18N Team Leader 



Re: [fw-general] Consistency in naming

2007-03-03 Thread Ralph Schindler




Most people declared Zend_Translate over Zend_Translator, because
non native english people know "translate" but do not know "translator"...


Why? Do nouns not translate well to other languages?  I don't understand.

-ralph


Re: [fw-general] Consistency in naming

2007-02-20 Thread Nico Edtinger

[19.02.2007 22:20] Matthew Ratzloff wrote:

In subclasses:

Zend_Mail_Read (wherever it went) => Zend_Mail_Reader


It's now called Zend_Mail_Storage_.. solved that one =)


Zend_Mime_Decode => Zend_Mime_Decoder


Decoder sounds like a Schwarzenegger action movie. It's also more of  
an internal class. But if everyone's happy with that name I'll change  
it.


nico


Re: [fw-general] Consistency in naming

2007-02-20 Thread Matthew Ratzloff
>> Zend_Mime_Decode => Zend_Mime_Decoder
>
> Decoder sounds like a Schwarzenegger action movie. It's also more of
> an internal class. But if everyone's happy with that name I'll change
> it.

:-D  Anyway, it lines up with Zend_Json_Decoder.

-Matt



Re: [fw-general] Consistency in naming

2007-02-20 Thread Thomas Weidner
Unlike classes like Zend_Search or Zend_Filter, Zend_Validate and 
Zend_Translate can only be verbs, and should be changed to a noun form to 
match the rest of the framework.


Zend_Validate => Zend_Validator
Zend_Translate => Zend_Translator


When creating Zend_Translate there was a contest on which name to use...
Most people declared Zend_Translate over Zend_Translator, because
non native english people know "translate" but do not know "translator"...

I would have to problem in renaming my class to Zend_Translator...
The only thing I ask is to leave it then as it is, and not change it once 
again

in two weeks.

Consistency means predictability, which means being able to recall names 
without having to check the manual every time.  It's why most people can't 
use PHP's date or string functions without looking at the documentation, 
for example.


This point is related to the actual discussion within [EMAIL PROTECTED] 
about using the php date format

for Zend_Date instead of the actual ISO Format which is much more native.

It would be nice if some more people could write their opinion if
Zend_Date should use PHP's date format letters or if it should remain
in using the ISO Format.

Matthew already has announced that ISO would be better / simpler.
But it would be nice to have some additional opinions.

Greetings
Thomas
(I18N Team Leader) 



Re: [fw-general] Consistency in naming

2007-02-19 Thread Jim Scherer

Great catch and well put. I hope this is implemented.


Matthew Ratzloff wrote:
> 
> There seem to be a few issues with naming consistency of the framework 
> components.  Nearly all of them have Zend_(noun) as the pattern, but there 
> are some that don't.
> 
> Unlike classes like Zend_Search or Zend_Filter, Zend_Validate and 
> Zend_Translate can only be verbs, and should be changed to a noun form to 
> match the rest of the framework.
> 
> Zend_Validate => Zend_Validator
> Zend_Translate => Zend_Translator
> 
> In subclasses:
> 
> Zend_Acl_Assert => Zend_Acl_Assertion
> Zend_Mail_Read (wherever it went) => Zend_Mail_Reader
> Zend_Mime_Decode => Zend_Mime_Decoder
> 
> Consistency means predictability, which means being able to recall names 
> without having to check the manual every time.  It's why most people can't 
> use PHP's date or string functions without looking at the documentation,
> for 
> example.
> 
> -Matt 
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Consistency-in-naming-tf3255289s16154.html#a9051094
Sent from the Zend Framework mailing list archive at Nabble.com.



Re: [fw-general] Consistency in naming

2007-02-19 Thread Werner

Matthew Ratzloff wrote:


Consistency means predictability, which means being able to recall 
names without having to check the manual every time.  It's why most 
people can't use PHP's date or string functions without looking at the 
documentation, for example.


Very good point, I'm glad you mentioned it - Twice this week already I 
assumed that there is a Zend_Validator class, only to find (once again) 
that it's indeed Zend_Validation. Thanks for pointing out what went on 
in my brain - I guess predictability overrides memory in my case.


- Werner


Re: [fw-general] Consistency in naming

2007-02-19 Thread Martel Valgoerad

Matthew Ratzloff wrote:

Consistency means predictability, which means being able to recall names 
without having to check the manual every time.  


Seconded.

-Matt 


--
Martel Valgoerad aka Michal Minicki | [EMAIL PROTECTED] | 
http://aie.pl/martel.asc
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
"Idleness is not doing nothing. Idleness is being free to do anything." --
Floyd Dell