public void didMoveTo ( int placeId , PlaceConfig config ) { if ( _moveListener != null ) { _moveListener . requestCompleted ( config ) ; _moveListener = null ; } // keep track of our previous place id _previousPlaceId = _placeId ; // clear out our last request time _lastRequestTime = 0 ; // do some cleaning up in case we were previously in a place didLeavePlace ( ) ; // make a note that we're now mostly in the new location _placeId = placeId ; // start up a new place controller to manage the new place try { _controller = createController ( config ) ; if ( _controller == null ) { log . warning ( "Place config returned null controller" , "config" , config ) ; return ; } _controller . init ( _ctx , config ) ; // subscribe to our new place object to complete the move subscribeToPlace ( ) ; } catch ( Exception e ) { log . warning ( "Failed to create place controller" , "config" , config , e ) ; handleFailure ( _placeId , LocationCodes . E_INTERNAL_ERROR ) ; } }
This can be called by cooperating directors that need to coopt the moving process to extend it in some way or other . In such situations they will be responsible for receiving the successful move response and they should let the location director know that the move has been effected .