public static <T> T findValue(ServiceRegistry registry, ServiceName name) {
        ServiceController<T> service = findService(registry, name);
        return ((service != null) && (service.getState() == State.UP)) ? service.getValue() : null;
    }
public static < T > T findValue ( ServiceRegistry registry , ServiceName name ) { ServiceController < T > service = findService ( registry , name ) ; return ( ( service != null ) && ( service . getState ( ) == State . UP ) ) ? service . getValue ( ) : null ; }
Returns the value of the specified service, if the service exists and is started.
@param registry the service registry
@param name the service name
@return the service value, if the service exists and is started, null otherwise