mil.dod.th.ose.integration/src/mil/dod/th/ose/controller/integration/utils/AssetTestUtils.java
public static AssetFactory grabAssetFactoryByClass(final String productType)
    {
        final AssetDirectoryService assetDirectoryService = getAssetDirectoryService();
        
        final Iterator<AssetFactory> factoryList = 
                assetDirectoryService.getAssetFactories().iterator();
        
        AssetFactory foundFactory = null;
        
        while (factoryList.hasNext())
        {
            final AssetFactory assetFactory = factoryList.next();
            if (assetFactory.getProductType().equals(productType))
            {
                foundFactory = assetFactory;
                break;
            }
        }
        
        assertThat(foundFactory, notNullValue());
        
        return foundFactory;
    }
/**
     * Retrieves an asset's {@link AssetFactory}.
     * @param productType
     *  the asset factory that needs to be matched on.
     * @return
     *  the {@link AssetFactory} that corresponds to the factory class passed in.
     */
Retrieves an asset's  AssetFactory.
@param productType
the asset factory that needs to be matched on.
@return
the  AssetFactory that corresponds to the factory class passed in.
Retrieves an asset ' s AssetFactory . @param productType the asset factory that needs to be matched on . @return the AssetFactory that corresponds to the factory class passed in .
public static AssetFactory grabAssetFactoryByClass(final String productType)
    {
        final AssetDirectoryService assetDirectoryService = getAssetDirectoryService();
        final Iterator<AssetFactory> factoryList = 
                assetDirectoryService.getAssetFactories().iterator();
        AssetFactory foundFactory = null;
        while (factoryList.hasNext())
        {
            final AssetFactory assetFactory = factoryList.next();
            if (assetFactory.getProductType().equals(productType))
            {
                foundFactory = assetFactory;
                break;
            }
        }
        assertThat(foundFactory, notNullValue());
        return foundFactory;
    }
public static AssetFactory grabAssetFactoryByClass ( final String productType ) { final AssetDirectoryService assetDirectoryService = getAssetDirectoryService ( ) ; final Iterator < AssetFactory > factoryList = assetDirectoryService . getAssetFactories ( ) . iterator ( ) ; AssetFactory foundFactory = null ; while ( factoryList . hasNext ( ) ) { final AssetFactory assetFactory = factoryList . next ( ) ; if ( assetFactory . getProductType ( ) . equals ( productType ) ) { foundFactory = assetFactory ; break ; } } assertThat ( foundFactory , notNullValue ( ) ) ; return foundFactory ; }
Retrieves an asset's {@link AssetFactory}.
Retrieves an asset ' s { @link AssetFactory } .