The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

douglasv (316) [Avatar] Offline
#1
To create a setter, you have to suffix your setter method with =.
(that is an equals sign and a period) ?

a var automatically creates a getter and setter? yes,no?
a val automatically creates a getter? yes,no?

def creates a method, yes,no?

If I wanted _age to be available to an embedded new Instance I would create
a val age = _age, yes,no?
otherwise the parameters of the first instance wouldn't be visible,to the 2nd instance,
yes,no?

A def can define a method or field, yes,no?

Alot going on in this page, good place for a companion or trait,yes,no?