mil.dod.th.ose.gui.integration/src/mil/dod/th/ose/gui/integration/helpers/CommsGeneralHelper.java
public static WebElement retrieveStack(final WebDriver driver, final String stackName)
    {   
        List<WebElement> commsPanels = driver.findElements(By.cssSelector("table[class='commsInfoPanel']"));
        
        for(WebElement element : commsPanels)
        {
            List<WebElement> spans = element.findElements(By.tagName("span"));
            
            for(WebElement span : spans)
            {
                if (span.getText().equals(stackName))
                {
                    return element;
                }
            }
        }
        
        return null;
    }
/**
     * Method that finds and returns the WebElement that represents the stack. This method returns null if the
     * specified stack cannot be found.
     * 
     * @param driver
     *      Instance of the {@link WebDriver} the stack will be retrieved from.
     * @param stackName
     *      Name of the stack to be retrieved.
     * @return
     *      {@link WebElement} that represents the specified stack or <code>null</code> if it cannot be found.
     */
Method that finds and returns the WebElement that represents the stack. This method returns null if the
specified stack cannot be found.

@param driver
Instance of the  WebDriver the stack will be retrieved from.
@param stackName
Name of the stack to be retrieved.
@return
WebElement that represents the specified stack or null if it cannot be found.
Method that finds and returns the WebElement that represents the stack . This method returns null if the specified stack cannot be found . @param driver Instance of the WebDriver the stack will be retrieved from . @param stackName Name of the stack to be retrieved . @return WebElement that represents the specified stack or null if it cannot be found .
public static WebElement retrieveStack(final WebDriver driver, final String stackName)
    {   
        List<WebElement> commsPanels = driver.findElements(By.cssSelector("table[class='commsInfoPanel']"));
        for(WebElement element : commsPanels)
        {
            List<WebElement> spans = element.findElements(By.tagName("span"));
            for(WebElement span : spans)
            {
                if (span.getText().equals(stackName))
                {
                    return element;
                }
            }
        }
        return null;
    }
public static WebElement retrieveStack ( final WebDriver driver , final String stackName ) { List < WebElement > commsPanels = driver . findElements ( By . cssSelector ( "table[class='commsInfoPanel']" ) ) ; for ( WebElement element : commsPanels ) { List < WebElement > spans = element . findElements ( By . tagName ( "span" ) ) ; for ( WebElement span : spans ) { if ( span . getText ( ) . equals ( stackName ) ) { return element ; } } } return null ; }
Method that finds and returns the WebElement that represents the stack.
Method that finds and returns the WebElement that represents the stack .