Added setter for amount in ClassA.