Forced use of no-arguments arguments, the default constructor template allows the system to dynamically recreate a fragment if necessary. From the docs:
All subclasses of Fragment must include a public empty constructor. A structure often re-creates an instance of a fragment class when necessary, in particular during state recovery, and should be able to find this constructor to create it. If an empty constructor is not available, in some cases the runtime will be thrown during state recovery.
“often” and “in some cases” leaves it uncertain. But not satisfying your curiosity ... the arguments are this!
source
share