ContainerListener interface:
This interface holds two methods. Whenever a component is added to a container, componentAdded ( ) is invoked. Whenever a component is removed from a container, componentRemoved ( ) is invoked. Their common forms are display here:
Syntax : Void componentAdded (ContainerEvent ce )
Syntax : Void componentRemoved (ContainerEvent ce)