Recent

Author Topic: Adding interfaces to any class (tnx Warfley!)  (Read 2331 times)

ASerge

  • Hero Member
  • *****
  • Posts: 2362
Re: Adding interfaces to any class (tnx Warfley!)
« Reply #15 on: December 13, 2024, 03:05:29 pm »
But how do you convert it back?
What for? If we have an object A, then convert it to B, then why back? Just use A.

Warfley

  • Hero Member
  • *****
  • Posts: 1856
Re: Adding interfaces to any class (tnx Warfley!)
« Reply #16 on: December 13, 2024, 03:48:44 pm »
For example, you want to create the object, pass it to another object and get it back later. E.g. as transferral of ownership. Is not that uncommon.

 

TinyPortal © 2005-2018