1

Probably it's a Java more than an Android programming question, anyway: there are two ways to declare the 3 standard view constructors: one is using this() to call the next most parametrized constructor, with null and 0, as I've seen here, and doing all the custom init in the last constructor.

The other way is calling super(), calling each time a function that does the init job.

Is one way more right than the other (why?), or it's just a style choice?

Community
  • 1
  • 1
bigstones
  • 14,587
  • 6
  • 63
  • 80
  • possible duplicate of [this vs super keywords](http://stackoverflow.com/questions/4023344/this-vs-super-keywords) – Mark B Dec 30 '10 at 17:01
  • I don't think it's very duplicative; this gets at the heart of: which path should your constructors take if there are multiple constructors in the superclass - and it's a very good question. +1. – Carl Manaster Dec 30 '10 at 17:04
  • This is really a duplicate of this question: http://stackoverflow.com/questions/4023344/this-vs-super-keywords You can find the answer there. – Mark B Dec 30 '10 at 17:00

1 Answers1

0

OK, so I guess that there isn't any technical involvement one can think of, at least none so important that hi-rep people would know for sure. so... I deduce it's only a style choice.

bigstones
  • 14,587
  • 6
  • 63
  • 80