code: public void setService(LoadBalancerHeartBeatingService service) throws IllegalStateException, NullPointerException {
  		if (service == null) {
  			throw new NullPointerException("null service");
  		}
  		if (addressFactory == null || logger == null) {
  			throw new IllegalStateException();
  		}
  		this.service = service;
  		service.addLoadBalancerHeartBeatingListener(this);
  		for (SipLoadBalancer balancer : service.getLoadBalancers()) {
  			addLoadBalancer(balancer);
  		}
  	}
docs: /* (non-Javadoc)
  @see org.mobicents.ha.javax.sip.LoadBalancerElector#setService(org.mobicents.ha.javax.sip.LoadBalancerHeartBeatingService)