Class Autofill.Session

Object
org.mozilla.geckoview.Autofill.Session
Enclosing class:
Autofill

public static final class Autofill.Session extends Object
Represents an autofill session. A session holds the autofill nodes and state of a page.
  • Method Details

    • getDefaultDimensions

      @UiThread @NonNull public Rect getDefaultDimensions()
    • dataFor

      @UiThread @NonNull public Autofill.NodeData dataFor(@NonNull Autofill.Node node)
      Get data for the given node.
      Parameters:
      node - the Autofill.Node get data for.
      Returns:
      the Autofill.NodeData for the given node.
    • autofill

      @UiThread public void autofill(@NonNull SparseArray<CharSequence> values)
      Perform auto-fill using the specified values.
      Parameters:
      values - Map of auto-fill IDs to values.
    • isVisible

      @UiThread public boolean isVisible(@NonNull Autofill.Node node)
      Returns true if the node is currently visible in the page.
      Parameters:
      node - the Autofill.Node instance
      Returns:
      true if the node is visible, false otherwise.
    • getFocused

      @UiThread @Nullable public Autofill.Node getFocused()
      Returns the currently focused node.
      Returns:
      a reference to the Autofill.Node that is currently focused or null if no node is currently focused.
    • getFocusedData

      @UiThread @Nullable public Autofill.NodeData getFocusedData()
      Returns the currently focused node data.
      Returns:
      a refernce to Autofill.NodeData or null if no node is focused.
    • getRoot

      @AnyThread @NonNull public Autofill.Node getRoot()
      Get the root node of the session tree. Each session is managed in a tree with a virtual root node for the document.
      Returns:
      The root Autofill.Node for this session.
    • toString

      @UiThread public String toString()
      Overrides:
      toString in class Object
    • fillViewStructure

      @UiThread public void fillViewStructure(@NonNull View view, @NonNull ViewStructure structure, int flags)
    • fillViewStructure

      @UiThread public void fillViewStructure(@NonNull Autofill.Node node, @NonNull View view, @NonNull ViewStructure structure, int flags)