public void targetAppears ( TargetHandler targetItf ) { this . defaultTargetHandlerResolver . addTargetHandler ( targetItf ) ; // When a target is deployed, we may also have to update instance states. // Consider as an example when the DM restarts. Targets may be injected // before and after the pojo was started by iPojo. // See #519 for more details. // Notice we restore instances only when the DM was started (the messaging // must be ready). If it is not started, do nothing. The "start" method // will trigger the restoration. // We consider the DM is started if the timer is not null. if ( this . timer != null ) restoreInstancesFrom ( targetItf ) ; }
This method is invoked by iPojo every time a new target handler appears .