rfc:static-classes

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
rfc:static-classes [2008/05/10 11:16]
lstrojny Adding instance clarification (thanks, felipe)
rfc:static-classes [2017/09/22 13:28] (current)
Line 40: Line 40:
 AbstractStaticClass2::staticMethod(); // Throws error, not allowed. Must be extended first AbstractStaticClass2::staticMethod(); // Throws error, not allowed. Must be extended first
 </code> </code>
 +
  
  
Line 53: Line 54:
   * The current behaviour of abstract classes/non-static classes with static members **would not** change. This is important for backwards compatibility   * The current behaviour of abstract classes/non-static classes with static members **would not** change. This is important for backwards compatibility
   * ''%%__setStatic()%%'' and ''%%__getStatic()%%'' **will** provide functionality similiar to ''%%__get()%%'' and ''%%__set()%%''   * ''%%__setStatic()%%'' and ''%%__getStatic()%%'' **will** provide functionality similiar to ''%%__get()%%'' and ''%%__set()%%''
-  * It **will not** be possible to create instances of static classes+  * Static classes **cannot** be instantiated 
 +  * Static classes **can** implement interfaces containing only static methods
  
 ===== Code ===== ===== Code =====
rfc/static-classes.1210418193.txt.gz · Last modified: 2017/09/22 13:28 (external edit)