code: public void addLayerSnappingRules(String layerId) {
  		Layer<?> layer = mapWidget.getMapModel().getLayer(layerId);
  		if (layer != null && layer instanceof VectorLayer) {
  			VectorLayer vLayer = (VectorLayer) layer;
  			for (SnappingRuleInfo snappingRuleInfo : vLayer.getLayerInfo().getSnappingRules()) {
  				SnapRuleUtil.addRule(delegate.getSnappingService(), mapWidget, snappingRuleInfo);
  			}
  		}
  	}
docs: Add the list of snapping rules as they are configured for a specific layer within the XML configuration.
  
  @param layerId The vector layer to use the configuration from.