Ok, few notes:
- enum is not an object, so findobject wont work.
- if i understand correctly, in your constructor you want to set your variable "type"and “amount”. Not assign your constructor variables to whichever the default values are for type and amount.
- when setting “type” correctly in your constructor, you can just use this same “type” variable as your class’ enum.