Forums Register Login

Nested class - instantiation

+Pie Number of slices to send: Send
How to instantiate the class Inner extending StInner . Its giving error if i try in the below ways?


Regards.

+Pie Number of slices to send: Send
Because Inner is not static, it needs to be bound to an instance of the enclosing class (StInner).

If you want to make that in3, the following should work (this is from memory, so no warranty):

Because those who mind don't matter and those who matter don't mind - Seuss. Tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 549 times.
Similar Threads
inner static class
Converting into Arrays
Interaction between threads
Inner class Doubts
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 28, 2024 04:23:35.