java - Prevent instantiation of a class from a library -
i developing application depends on library. not have control on library code.
i have extended class library in application. want application able create instances of extended class, not parent class.
is there way prevent object creation of parent class?
i don't think there way in can restrict creation of parent instance, if see architecture "initializer" make sure instance created , @ same time allocate heap space.
at end memory has allocated , instances has created.
Comments
Post a Comment