Jatin
2006-03-01 06:14:40 UTC
Is it possible in Delphi to make default constructor hidden such that
caller can't call it? Even if I declare it to be private, the TObject's
default constructor is still visible to the caller, which I want to
avoid. Basically what I want to achieve is that caller should only be
able to instantiate the object by calling its non-default constructor.
Is there any other wy to achieve that? I will appreciate any comments
and suggestions.
Thanks,
Jatin
====================
caller can't call it? Even if I declare it to be private, the TObject's
default constructor is still visible to the caller, which I want to
avoid. Basically what I want to achieve is that caller should only be
able to instantiate the object by calling its non-default constructor.
Is there any other wy to achieve that? I will appreciate any comments
and suggestions.
Thanks,
Jatin
====================