public ServiceResult getService( int requestorId, ComponentDescription requestorDesc, Object requestor, Class serviceClass, ServiceRevokedListener srl, boolean recordInView) { if (delegate instanceof ExtendedServiceBroker) { ExtendedServiceBroker esb = (ExtendedServiceBroker) delegate; return esb.getService(requestorId, requestorDesc, requestor, serviceClass, srl, recordInView); } else { Object service = delegate.getService(requestor, serviceClass, srl); return (service == null ? (null) : new ServiceResult(0, null, service)); } }
/** * get an instance of the requested service from a service provider associated with this context. */ public <T> T getService( Object requestor, final Class<T> serviceClass, final ServiceRevokedListener srl) { return delegate.getService(requestor, serviceClass, srl); }