Posted By

limonn on 08/17/06


Tagged


Versions (?)

Who likes this?

2 people have marked this snippet as a favorite

damarev
yeco


creando una clase


 / Published in: ActionScript
 

URL: http://www.oreillynet.com/pub/a/javascript/2003/08/19/actionscriptckbk.html

creando una clase

  1. function NewClass() {
  2. }
  3. NewClass.prototype.someProperty = "someValue";
  4. NewClass.prototype.someMethod = function() {
  5. trace("someMethod called");
  6. };
  7. var nc = new NewClass();
  8.  
  9. //And you can then utilize the properties and //methods of that instance:
  10.  
  11. trace(nc.someProperty);
  12. nc.someMethod();

Report this snippet  

You need to login to post a comment.