This pointer

Info about design forms features
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1107: count(): Parameter must be an array or an object that implements Countable
PetrS
Site Admin
Posts: 181
Joined: 11 Jul 2014, 13:55
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1107: count(): Parameter must be an array or an object that implements Countable

This pointer

Postby PetrS » 21 Oct 2015, 06:56

size=150This pointer/size

The 'this' keyword refers to the current instance of the class/CLC.
The meaning and behaviour is the same as url=https://msdn.microsoft.com/cs-cz/library/dk1507sz.aspx'this' keyword in C#/url
It can be used in class constructor (see example below) or in class functions. Using 'this' in global scope (main script) is possible, but NOT recommended

See attached example for more details.
Attachments
ThisPointer.cls
(22.18 KiB) Downloaded 302 times
Ing. Petr Slepicka

Engineering calculations online - EuroCode, AISC, statics
Automate your static calculations today!

[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1107: count(): Parameter must be an array or an object that implements Countable
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1107: count(): Parameter must be an array or an object that implements Countable
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1107: count(): Parameter must be an array or an object that implements Countable

Return to “Design forms features”

Who is online

Users browsing this forum: No registered users and 6 guests