mil.dod.th.junit4.test.runner/src/mil/dod/th/ose/junit4xmltestrunner/IntegrationTestService.java
protected <S> void addReference(final String name, final Class<S> clazz, final String filter, 
            final boolean optional) throws InvalidSyntaxException
    {
        // customizer can be null, keep it that way if filter is not provided
        ServiceTrackerCustomizer<S, Object> customizer = null;
        if (filter != null)
        {
            customizer = new FilterServiceTracker<S>(filter);
        }
        final ServiceTracker<S, Object> tracker = 
                new ServiceTracker<S, Object>(m_Context.getBundleContext(), clazz.getName(), customizer);
        
        m_ServiceReferences.put(name, new ServiceReferenceInfo(clazz, optional, tracker));
        
        
    }
/**
     * Create a service reference that is filtered by the provided services properties.  See other overloaded methods, 
     * typically this method does not need to be called directly.
     * 
     * @param <S>
     *      Type of service to add
     * @param name
     *      Name of reference
     * @param clazz
     *      Interface class for desired service
     * @param filter
     *      LDAP filter string to filter the service based on its properties
     * @param optional
     *      whether the reference is optional, will be ignored if not found
     * @throws InvalidSyntaxException
     *      if the filter string is not in a valid format 
     */
Create a service reference that is filtered by the provided services properties.  See other overloaded methods,
typically this method does not need to be called directly.


Create a service reference that is filtered by the provided services properties . See other overloaded methods typically this method does not need to be called directly .
protected <S> void addReference(final String name, final Class<S> clazz, final String filter, 
            final boolean optional) throws InvalidSyntaxException
    {
        ServiceTrackerCustomizer<S, Object> customizer = null;
        if (filter != null)
        {
            customizer = new FilterServiceTracker<S>(filter);
        }
        final ServiceTracker<S, Object> tracker = 
                new ServiceTracker<S, Object>(m_Context.getBundleContext(), clazz.getName(), customizer);
        m_ServiceReferences.put(name, new ServiceReferenceInfo(clazz, optional, tracker));
    }
protected < S > void addReference ( final String name , final Class < S > clazz , final String filter , final boolean optional ) throws InvalidSyntaxException { ServiceTrackerCustomizer < S , Object > customizer = null ; if ( filter != null ) { customizer = new FilterServiceTracker < S > ( filter ) ; } final ServiceTracker < S , Object > tracker = new ServiceTracker < S , Object > ( m_Context . getBundleContext ( ) , clazz . getName ( ) , customizer ) ; m_ServiceReferences . put ( name , new ServiceReferenceInfo ( clazz , optional , tracker ) ) ; }
Create a service reference that is filtered by the provided services properties.
Create a service reference that is filtered by the provided services properties .
// customizer can be null, keep it that way if filter is not provided