Closed GoogleCodeExporter closed 8 years ago
As a corollary to dotsManager, perhaps there should be a superclass of
dotsManagedObject. It would guarantee and normalize things like constructor
registration and property listeners (to report changes to the manager).
It would also make clear that things like dotsDrawable are not free-standing
objects--they should be used through their managers.
Would all managed objects keep a handle to their manager? Or just resolve it
with
manager static methods? I like the handle idea because the manager singleton
could
be resolved once, at construct time.
Original comment by Benjamin.Heasly
on 16 Dec 2009 at 10:14
One concern I have is the growing number of singleton classes. All that global
state
is clumsy to test and not very OOP.
How many are too many?
But maybe there really is a lot of global state in this kind of hardware-rich
environment. Screen, input devices, UDP sockets, machine settings, system
modes--all
these things are global and all of them need to be managed.
Original comment by Benjamin.Heasly
on 16 Dec 2009 at 10:22
As of r43, there is no double inheritance. There is a branch of singleton
objects and a
branch of managed objects.
Manager singletons deal with behaviors like remoteness and reuse of particular
types of
managed objects.
Original comment by Benjamin.Heasly
on 29 Jan 2010 at 5:19
Original issue reported on code.google.com by
Benjamin.Heasly
on 16 Dec 2009 at 10:07