A class named Product with a constructor and a method : Constructor « Class « Flash / Flex / ActionScript






A class named Product with a constructor and a method

 

public class Product {
  var price:Number;

  public function Product (  ) {
  }

  public function doSomething (  ):void {
  }
}

        








Related examples in the same category

1.Creating a Constructor
2.Add public attribute to contrustor.
3.Constructor with parameter
4.Add assignment code to class constructor
5.Set the memeber variable in constructor
6.Declare a constructor method for the Example class