In my application, I need to make my class as immutable, but in my class I have an object of other class which is mutable, can anyone please suggest me Implementation.
Pseudo code:
Class A which I would like as immutable class
class A {
/* ... */
//class B is mutable
B b = new B();
/* ... */
}
final