Search:

Type: Posts; User: fahman_khan75@yahoo.com

Search: Search took 0.10 seconds.

  1. Re: Using this reference variable on constructors

    In my book, it had the code
    public RetailItem(String desc,int itemNumber,
    double wholesale, double retail)
    {

    description=desc;
    ItemNumber=itemNumber;
    cost=new CostData(wholesale, retail);
    ...
  2. Using this reference variable on constructors

    I’m trying to simplify my constructor by using “this” reference variable. I’m aware how to use this reference when making constructors that involve fields of primitive data types; however, not so...
Results 1 to 2 of 2