[FLOW3-general] Relation to singleton scope Object

Benno Weinzierl benno_weinzierl at web.de
Fri Jun 29 00:21:55 CEST 2012


Hi Karsten,

i have different singleton status objects (e.g. new, processing, reviewed,
and so on).
A status "new" for example is derived from abstractStatus.
In the concrete implementation it knows its followup status and can have
some special methods like ->doSomethingThatOnlyANewStatusCan()

But every new-status in the system is the same, thats why singleton.

Regards, Benno

Karsten Dambekalns <karsten at typo3.org> wrote:
> Hi.
> 
> On 17.05.12 15:18, Benno Weinzierl wrote:
>> is there a build in way to store a ManyToOne relation to a singleton scope
>> object in a persisted entity object?
> 
> Relations to singletons are not supported right now, as singletons can
> be (re-)injected easily due to their very nature.
> 
> Why exactly is your status object a singleton? That would mean that you
> can have only one status in your whole system - sounds weird to me.
> 
> Regards,
> Karsten


More information about the FLOW3-general mailing list