Class FastHtmlTable


  • public class FastHtmlTable
    extends java.lang.Object
    This class is used to represent an html table, and to aid the FAST Framework in interacting with it
    Since:
    1.0.0
    • Constructor Summary

      Constructors 
      Constructor Description
      FastHtmlTable()
      Default constructor
    • Method Summary

      Modifier and Type Method Description
      void convertFastElementToFastHtmlTable​(FastElement fastElement)
      Converts a FastElement into the FastHtmlTable
      java.util.List<org.openqa.selenium.WebElement> getColumnHeaders()
      Returns column headers of this FastHtmlTable as a list of WebElement
      java.util.Map<java.lang.String,​java.lang.Integer> getColumnNameToIndex()
      Returns map with columnNames as key, and column index as values
      org.openqa.selenium.WebElement getRowByColumns​(java.util.Map<java.lang.String,​java.lang.String> columnAndValues)
      Returns the table row that matches the specified columns and values
      org.openqa.selenium.WebElement getRowCell​(org.openqa.selenium.WebElement tableRow, java.lang.String columnName)
      Returns the cell that matches the specified tableRow and columnName from an html table
      java.util.List<org.openqa.selenium.WebElement> getRowCells​(org.openqa.selenium.WebElement tableRow)
      Returns the cless of the specified tableRow as a list of WebElement
      org.openqa.selenium.WebElement getTable()
      Returns the html table this FastHtmlTable represents as a WebElement
      java.util.List<org.openqa.selenium.WebElement> getTableRows()
      Returns the table rows of this FastHtmlTable as a list of WebElement
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • FastHtmlTable

        public FastHtmlTable()
        Default constructor
    • Method Detail

      • convertFastElementToFastHtmlTable

        public void convertFastElementToFastHtmlTable​(FastElement fastElement)
                                               throws FastException
        Converts a FastElement into the FastHtmlTable
        Parameters:
        fastElement - A FastElement that was used to find a html table
        Throws:
        FastException - If error occurs during execution
        Since:
        1.0.0
      • getColumnNameToIndex

        public java.util.Map<java.lang.String,​java.lang.Integer> getColumnNameToIndex()
        Returns map with columnNames as key, and column index as values
        Returns:
        columnNameToIndex map
        Since:
        1.0.0
      • getTable

        public org.openqa.selenium.WebElement getTable()
        Returns the html table this FastHtmlTable represents as a WebElement
        Returns:
        The html table as a WebElement
        Since:
        1.0.0
      • getColumnHeaders

        public java.util.List<org.openqa.selenium.WebElement> getColumnHeaders()
        Returns column headers of this FastHtmlTable as a list of WebElement
        Returns:
        columnHeaders
        Since:
        1.0.0
      • getTableRows

        public java.util.List<org.openqa.selenium.WebElement> getTableRows()
        Returns the table rows of this FastHtmlTable as a list of WebElement
        Returns:
        tableRows
        Since:
        1.0.0
      • getRowByColumns

        public org.openqa.selenium.WebElement getRowByColumns​(java.util.Map<java.lang.String,​java.lang.String> columnAndValues)
        Returns the table row that matches the specified columns and values
        Parameters:
        columnAndValues - A map containing the column and value pairs of a row in a html table
        Returns:
        Row containing column and values specified in columnAndValues
        Since:
        1.0.0
      • getRowCells

        public java.util.List<org.openqa.selenium.WebElement> getRowCells​(org.openqa.selenium.WebElement tableRow)
        Returns the cless of the specified tableRow as a list of WebElement
        Parameters:
        tableRow - The html table row whose cells are being obtained
        Returns:
        A list of WebElement which designate the cells of a row in an html table
        Since:
        1.0.0
      • getRowCell

        public org.openqa.selenium.WebElement getRowCell​(org.openqa.selenium.WebElement tableRow,
                                                         java.lang.String columnName)
        Returns the cell that matches the specified tableRow and columnName from an html table
        Parameters:
        tableRow - An html table row
        columnName - A column name of an html table
        Returns:
        The cell that is in the specified columnName of the specified tableRow
        Since:
        1.0.0