| From | Sent On | Attachments |
|---|---|---|
| 104 earlier messages | ||
| Matthew Weier O'Phinney | May 10, 2011 12:27 pm | |
| dukeofgaming | May 10, 2011 12:28 pm | |
| guil...@gmail.com | May 10, 2011 12:31 pm | |
| guil...@gmail.com | May 10, 2011 12:35 pm | |
| Drak | May 10, 2011 12:36 pm | |
| Ferenc Kovacs | May 10, 2011 12:40 pm | |
| Ferenc Kovacs | May 10, 2011 12:41 pm | |
| dukeofgaming | May 10, 2011 12:44 pm | |
| Rasmus Lerdorf | May 10, 2011 12:44 pm | |
| Drak | May 10, 2011 12:49 pm | |
| Rasmus Lerdorf | May 10, 2011 12:51 pm | |
| Chad Fulton | May 10, 2011 1:02 pm | |
| Christopher Jones | May 10, 2011 1:28 pm | |
| Lester Caine | May 10, 2011 2:32 pm | |
| Lars Schultz | May 10, 2011 3:03 pm | |
| guil...@gmail.com | May 10, 2011 3:27 pm | |
| Johannes Schlüter | May 10, 2011 5:01 pm | |
| Johannes Schlüter | May 10, 2011 5:15 pm | |
| Lester Caine | May 10, 2011 10:41 pm | |
| Lars Schultz | May 10, 2011 11:34 pm | |
| dukeofgaming | May 10, 2011 11:49 pm | |
| Lars Schultz | May 11, 2011 12:02 am | |
| Lester Caine | May 11, 2011 12:20 am | |
| Rasmus Lerdorf | May 11, 2011 12:44 am | |
| Michael Wallner | May 11, 2011 12:51 am | |
| Lars Schultz | May 11, 2011 12:59 am | |
| Lester Caine | May 11, 2011 1:04 am | |
| dukeofgaming | May 11, 2011 1:11 am | |
| Lars Schultz | May 11, 2011 1:25 am | |
| dukeofgaming | May 11, 2011 1:39 am | |
| Johannes Schlüter | May 11, 2011 1:54 am | |
| dukeofgaming | May 11, 2011 2:04 am | |
| Lester Caine | May 11, 2011 2:21 am | |
| Rasmus Lerdorf | May 11, 2011 2:30 am | |
| Johannes Schlüter | May 11, 2011 2:44 am | |
| dukeofgaming | May 11, 2011 2:59 am | |
| Lester Caine | May 11, 2011 3:43 am | |
| Richard Quadling | May 11, 2011 4:31 am | |
| Christian Kaps | May 11, 2011 5:21 am | |
| Drak | May 11, 2011 5:29 am | |
| Mike van Riel | May 11, 2011 5:35 am | |
| Ferenc Kovacs | May 11, 2011 5:52 am | |
| Lester Caine | May 11, 2011 6:18 am | |
| Mike van Riel | May 11, 2011 6:27 am | |
| Ferenc Kovacs | May 11, 2011 6:31 am | |
| Lester Caine | May 11, 2011 6:59 am | |
| Matthew Weier O'Phinney | May 11, 2011 8:30 am | |
| Matthew Weier O'Phinney | May 11, 2011 8:32 am | |
| Philip Olson | May 11, 2011 8:42 am | |
| guil...@gmail.com | May 11, 2011 8:58 am | |
| guil...@gmail.com | May 11, 2011 9:06 am | |
| guil...@gmail.com | May 11, 2011 9:21 am | |
| Christopher Jones | May 11, 2011 9:54 am | |
| Rasmus Lerdorf | May 11, 2011 9:58 am | |
| Lester Caine | May 11, 2011 10:11 am | |
| Arvids Godjuks | May 11, 2011 10:18 am | |
| guil...@gmail.com | May 11, 2011 10:28 am | |
| Andi Gutmans | May 11, 2011 11:03 am | |
| Ilia Alshanetsky | May 11, 2011 11:14 am | |
| Johannes Schlüter | May 11, 2011 11:20 am | |
| Philip Olson | May 11, 2011 11:33 am | |
| Martin Scotta | May 11, 2011 11:34 am | |
| Stas Malyshev | May 11, 2011 11:43 am | |
| Stas Malyshev | May 11, 2011 11:50 am | |
| Johannes Schlüter | May 11, 2011 11:54 am | |
| dukeofgaming | May 11, 2011 12:17 pm | |
| Stas Malyshev | May 11, 2011 12:30 pm | |
| Stas Malyshev | May 11, 2011 12:32 pm | |
| Sebastian Bergmann | May 11, 2011 1:55 pm | |
| Sebastian Bergmann | May 11, 2011 1:59 pm | |
| Sebastian Bergmann | May 11, 2011 2:01 pm | |
| Sebastian Bergmann | May 11, 2011 2:05 pm | |
| Philip Olson | May 11, 2011 2:10 pm | |
| Mike van Riel | May 11, 2011 2:53 pm | |
| dukeofgaming | May 11, 2011 2:53 pm | |
| Rasmus Lerdorf | May 11, 2011 2:55 pm | |
| guil...@gmail.com | May 11, 2011 2:57 pm | |
| Marcelo Gornstein | May 11, 2011 3:05 pm | |
| dukeofgaming | May 11, 2011 3:06 pm | |
| guil...@gmail.com | May 11, 2011 3:14 pm | |
| Stefan Marr | May 11, 2011 3:20 pm | |
| Philip Olson | May 11, 2011 4:28 pm | |
| Stas Malyshev | May 11, 2011 5:02 pm | |
| Jordi Boggiano | May 11, 2011 5:55 pm | |
| Philip Olson | May 12, 2011 10:29 am | |
| Alexey Shein | May 13, 2011 7:13 am | .txt, .txt |
| Alexey Shein | May 16, 2011 6:51 am | .txt, .txt |
| Michael Morris | May 16, 2011 2:16 pm | |
| Kalle Sommer Nielsen | May 16, 2011 2:29 pm | |
| Subject: | Re: [PHP-DEV] annotations again | |
|---|---|---|
| From: | guil...@gmail.com (guil...@gmail.com) | |
| Date: | May 11, 2011 8:58:10 am | |
| List: | net.php.lists.internals | |
Hi Larz,
On Wed, May 11, 2011 at 4:02 AM, Lars Schultz <lars...@toolpark.com> wrote:
Am 10.05.2011 16:53, schrieb Martin Scotta:
Annotations are not required, you add them if you want to.
Yes. sure. But I am sure that certain Annotations must be combined to unleash their purpose, no? There is no validation for that, correct?
The patch does all compile time and runtime validations, so your assertion is not valid.
Also they can be used not only with classes. You can annotate methods, members, parameters (I'm not sure about the RFC scope)
With the interface approach you can annotate classes, methods, members and parameters, depending on how you build it, no? Annotating functions by themselves...is that really an issue? Since they're mostly stateless why would they need meta-data?
with "extends" you inherit implementation with "traits" you inherit code With annotations you inherit behavior.
inheriting behaviour is just a special case of inheriting "code" as in traits, no?
you cannot do this with interfaces <Annotation(param=Value)> class Class { }
interface Annotation { function getParam(); }
and how do you apply an interface to a method? <Deprecated> function getSomething() { }
interface Annotation { function getMethodAnnotation($method){ switch( $method ) { case 'getSomething': return array('deprecated'); } } }
All the framework/library boiler-plate should be reduced to minimum.
I can't argue with that.
What I just noticed is that simple examples (key=>value or even just keywords) are indeed concise and I could imagine using it this way. But for that we have docblocs. But as soon as you go into more complex structures, more than key=>value which guilherme keeps arguing is so essential to the Annotations and is also why we can't use docblocks, it gets unreadable and especially for maintaining state within meta-data, I'd always use PHP-Interfaces over Annotations.
If you tell me that you're doing this:
class User implements PersistenceEntity { // ... }
You're coupling your Entity to an individual persistence tool. This means you have a huge problem, because you're coupling things that should be separated. This breaks the clean separation of concerns that OO brings to us.
-- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php
-- Guilherme Blanco Mobile: +55 (16) 9215-8480 MSN: guil...@hotmail.com São Paulo - SP/Brazil
-- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php






.txt, .txt