[TYPO3-core] RFC: #15585: Introducing t3lib_div::getObjectEnv($input) and t3lib_div::getType ($input)

Helmut Hummel helmut at typo3.org
Sun Aug 29 13:27:46 CEST 2010


Hi, David,

On 29.08.10 10:18, David Bruchmann wrote:

> Concerning the CGL please give me a hint.

* Turn on whitespace preview in your texteditor and you'll find some
  places where you used spaces instead of tabs
* The first function declaration misses "static"
* be more verbose in your variable and function names:
  e.g. getDataType(), getObjectEnvironment(), $object instead of
  $input, $objectDescription instead of $obj, $className instead of
  $class ...
* mind your spelling in the class description (in English all words are
  lowercase, with only some exceptions).

Although I still not see an advantage of your getType over the PHP
native function, here some additional functional remarkes:

* switch ($var) will not work. If switch should be used here it must be
  switch (TRUE).
* To be complete, the function should not return just strings but class
  constants (which the could contain the needed strings)

> For the Rest: I suppose that I'll never get a +1 for integrating it in 
> t3lib_div, so I'll put it in the debug-class.

So this RFC is dropped, right?

Looking forward to the new debug class. Btw.: Maybe you could look at
FLOW3's implementation of var_dump()[1].


Regards Helmut


[1]http://robertlemke.de/blog/posts/2010/03/20/debugging-flow3-applications


More information about the TYPO3-team-core mailing list