code: public JsHandlerRegistration addLayersModelChangedHandler(final LayersModelChangedHandler handler) {
  		HandlerRegistration registration = ((MapImpl) map).getMapWidget().getMapModel()
  				.addMapModelChangedHandler(new MapModelChangedHandler() {
  
  					public void onMapModelChanged(MapModelChangedEvent event) {
  						handler.onLayersModelChanged(new LayersModelChangedEvent(map.getLayersModel()));
  					}
  				});
  		return new JsHandlerRegistration(new HandlerRegistration[] { registration });
  	}
docs: Add a handler to change events in the layer configuration from the map. This event is fired for example when the
  map gets it's configuration from the server. Only then can it know what layers it has available.