Re:application for object string, integer, boolean, float
| From: | Mike Griffiths | Date: | Sun, 24 Feb 2013 13:10:34 +0000 |
| Subject: | Re:application for object string, integer, boolean, float | ||
| References: | 1 | Groups: | php.webmaster |
| Request: | Send a blank email to php-webmaster+get-15549@lists.php.net to get a copy of this message | ||
Hi Peter
Unfortunately, this mailing list is not a support channel. You would be
better off looking here: http://php.net/support.php
That said, this may be of use:
http://php.net/manual/en/language.types.type-juggling.php
Thanks
Mike
On Feb 24, 2013 1:00 PM, "Peter Sokolík" <pesoklp13@gmail.com> wrote:
> Hello,
>
> i am Peter Sokolík from Slovakia. Me and my friends are started working on
> new php framework using OOP as main structure of whole project and trying
> to get more chance to work on php projects for java developers like me to
> work with php like java.
>
> Sure there are some things which not allow us make php framework same than
> java project, but main problem which we think is most important is working
> with native objects like string or integer like object with possibility of
> using native operations.
>
> for example
> if we want to hint datatype to parameters for methods of object we need to
> use object or array, but int is not a object in php.
>
> $int = 4; // this is native integer of php
> if i want strict determinate type of param of function addInteger(Integer
> $int) i have no way to do that.
>
> i know that php is still in evolution :) but do you not think that for
> change php to real programming languge is not important made hinting for
> native values like integer or string?
>
> it will be very usefull to have possibility make
> function addInt(Integer $i){
> //somecode
> }
>
> $i = 4;
> addInt($i);
>
> than using
>
> $i = new Integer(4);
> where i can do $result = $i + 4;
>
> thanks for reply
>
> yoursfaithfully
>
> --
> Bc. Peter Sokolík
> Slovakia
> PeSokLP13@gmail.com
>