Documentation ¶
Index ¶
- type AttrModifiedListener
- type AttrRemovedListener
- type ChildNodeCountUpdatedListener
- type ChildNodeInsertedListener
- type ChildNodeRemovedListener
- type DocumentUpdatedListener
- type Frame
- type HTMLDocument
- func LoadHTMLDocument(ctx context.Context, logger *zerolog.Logger, client *cdp.Client, ...) (*HTMLDocument, error)
- func LoadRootHTMLDocument(ctx context.Context, logger *zerolog.Logger, client *cdp.Client, ...) (*HTMLDocument, error)
- func NewHTMLDocument(logger *zerolog.Logger, client *cdp.Client, domManager *Manager, ...) *HTMLDocument
- func (doc *HTMLDocument) Close() error
- func (doc *HTMLDocument) Compare(other core.Value) int64
- func (doc *HTMLDocument) Copy() core.Value
- func (doc *HTMLDocument) CountBySelector(ctx context.Context, selector values.String) (values.Int, error)
- func (doc *HTMLDocument) ExistsBySelector(ctx context.Context, selector values.String) (values.Boolean, error)
- func (doc *HTMLDocument) Frame() page.FrameTree
- func (doc *HTMLDocument) GetChildDocuments(ctx context.Context) (*values.Array, error)
- func (doc *HTMLDocument) GetChildNode(ctx context.Context, idx values.Int) (core.Value, error)
- func (doc *HTMLDocument) GetChildNodes(ctx context.Context) (*values.Array, error)
- func (doc *HTMLDocument) GetElement() drivers.HTMLElement
- func (doc *HTMLDocument) GetIn(ctx context.Context, path []core.Value) (core.Value, error)
- func (doc *HTMLDocument) GetName() values.String
- func (doc *HTMLDocument) GetNodeName() values.String
- func (doc *HTMLDocument) GetNodeType() values.Int
- func (doc *HTMLDocument) GetParentDocument(ctx context.Context) (drivers.HTMLDocument, error)
- func (doc *HTMLDocument) GetTitle() values.String
- func (doc *HTMLDocument) GetURL() values.String
- func (doc *HTMLDocument) Hash() uint64
- func (doc *HTMLDocument) IsDetached() values.Boolean
- func (doc *HTMLDocument) Iterate(ctx context.Context) (core.Iterator, error)
- func (doc *HTMLDocument) Length() values.Int
- func (doc *HTMLDocument) MarshalJSON() ([]byte, error)
- func (doc *HTMLDocument) MoveMouseByXY(ctx context.Context, x, y values.Float) error
- func (doc *HTMLDocument) QuerySelector(ctx context.Context, selector values.String) (core.Value, error)
- func (doc *HTMLDocument) QuerySelectorAll(ctx context.Context, selector values.String) (*values.Array, error)
- func (doc *HTMLDocument) ScrollBottom(ctx context.Context) error
- func (doc *HTMLDocument) ScrollBySelector(ctx context.Context, selector values.String) error
- func (doc *HTMLDocument) ScrollByXY(ctx context.Context, x, y values.Float) error
- func (doc *HTMLDocument) ScrollTop(ctx context.Context) error
- func (doc *HTMLDocument) SetIn(ctx context.Context, path []core.Value, value core.Value) error
- func (doc *HTMLDocument) String() string
- func (doc *HTMLDocument) Type() core.Type
- func (doc *HTMLDocument) Unwrap() interface{}
- func (doc *HTMLDocument) WaitForAttributeBySelector(ctx context.Context, selector, name values.String, value core.Value, ...) error
- func (doc *HTMLDocument) WaitForAttributeBySelectorAll(ctx context.Context, selector, name values.String, value core.Value, ...) error
- func (doc *HTMLDocument) WaitForClassBySelector(ctx context.Context, selector, class values.String, when drivers.WaitEvent) error
- func (doc *HTMLDocument) WaitForClassBySelectorAll(ctx context.Context, selector, class values.String, when drivers.WaitEvent) error
- func (doc *HTMLDocument) WaitForElement(ctx context.Context, selector values.String, when drivers.WaitEvent) error
- func (doc *HTMLDocument) WaitForStyleBySelector(ctx context.Context, selector, name values.String, value core.Value, ...) error
- func (doc *HTMLDocument) WaitForStyleBySelectorAll(ctx context.Context, selector, name values.String, value core.Value, ...) error
- func (doc *HTMLDocument) XPath(ctx context.Context, expression values.String) (core.Value, error)
- type HTMLElement
- func LoadHTMLElement(ctx context.Context, logger *zerolog.Logger, client *cdp.Client, ...) (*HTMLElement, error)
- func LoadHTMLElementWithID(ctx context.Context, logger *zerolog.Logger, client *cdp.Client, ...) (*HTMLElement, error)
- func NewHTMLElement(logger *zerolog.Logger, client *cdp.Client, domManager *Manager, ...) *HTMLElement
- func (el *HTMLElement) Blur(ctx context.Context) error
- func (el *HTMLElement) BlurBySelector(ctx context.Context, selector values.String) error
- func (el *HTMLElement) Clear(ctx context.Context) error
- func (el *HTMLElement) ClearBySelector(ctx context.Context, selector values.String) error
- func (el *HTMLElement) Click(ctx context.Context, count values.Int) error
- func (el *HTMLElement) ClickBySelector(ctx context.Context, selector values.String, count values.Int) error
- func (el *HTMLElement) ClickBySelectorAll(ctx context.Context, selector values.String, count values.Int) error
- func (el *HTMLElement) Close() error
- func (el *HTMLElement) Compare(other core.Value) int64
- func (el *HTMLElement) Copy() core.Value
- func (el *HTMLElement) CountBySelector(ctx context.Context, selector values.String) (values.Int, error)
- func (el *HTMLElement) ExistsBySelector(ctx context.Context, selector values.String) (values.Boolean, error)
- func (el *HTMLElement) Focus(ctx context.Context) error
- func (el *HTMLElement) FocusBySelector(ctx context.Context, selector values.String) error
- func (el *HTMLElement) GetAttribute(ctx context.Context, name values.String) (core.Value, error)
- func (el *HTMLElement) GetAttributes(ctx context.Context) (*values.Object, error)
- func (el *HTMLElement) GetChildNode(ctx context.Context, idx values.Int) (core.Value, error)
- func (el *HTMLElement) GetChildNodes(ctx context.Context) (*values.Array, error)
- func (el *HTMLElement) GetIn(ctx context.Context, path []core.Value) (core.Value, error)
- func (el *HTMLElement) GetInnerHTML(ctx context.Context) (values.String, error)
- func (el *HTMLElement) GetInnerHTMLBySelector(ctx context.Context, selector values.String) (values.String, error)
- func (el *HTMLElement) GetInnerHTMLBySelectorAll(ctx context.Context, selector values.String) (*values.Array, error)
- func (el *HTMLElement) GetInnerText(ctx context.Context) (values.String, error)
- func (el *HTMLElement) GetInnerTextBySelector(ctx context.Context, selector values.String) (values.String, error)
- func (el *HTMLElement) GetInnerTextBySelectorAll(ctx context.Context, selector values.String) (*values.Array, error)
- func (el *HTMLElement) GetNodeName() values.String
- func (el *HTMLElement) GetNodeType() values.Int
- func (el *HTMLElement) GetStyle(ctx context.Context, name values.String) (core.Value, error)
- func (el *HTMLElement) GetStyles(ctx context.Context) (*values.Object, error)
- func (el *HTMLElement) GetValue(ctx context.Context) (core.Value, error)
- func (el *HTMLElement) Hash() uint64
- func (el *HTMLElement) Hover(ctx context.Context) error
- func (el *HTMLElement) HoverBySelector(ctx context.Context, selector values.String) error
- func (el *HTMLElement) Input(ctx context.Context, value core.Value, delay values.Int) error
- func (el *HTMLElement) InputBySelector(ctx context.Context, selector values.String, value core.Value, ...) error
- func (el *HTMLElement) IsDetached() values.Boolean
- func (el *HTMLElement) Iterate(_ context.Context) (core.Iterator, error)
- func (el *HTMLElement) Length() values.Int
- func (el *HTMLElement) MarshalJSON() ([]byte, error)
- func (el *HTMLElement) QuerySelector(ctx context.Context, selector values.String) (core.Value, error)
- func (el *HTMLElement) QuerySelectorAll(ctx context.Context, selector values.String) (*values.Array, error)
- func (el *HTMLElement) RemoveAttribute(ctx context.Context, names ...values.String) error
- func (el *HTMLElement) RemoveStyle(ctx context.Context, names ...values.String) error
- func (el *HTMLElement) ScrollIntoView(ctx context.Context) error
- func (el *HTMLElement) Select(ctx context.Context, value *values.Array) (*values.Array, error)
- func (el *HTMLElement) SelectBySelector(ctx context.Context, selector values.String, value *values.Array) (*values.Array, error)
- func (el *HTMLElement) SetAttribute(ctx context.Context, name, value values.String) error
- func (el *HTMLElement) SetAttributes(ctx context.Context, attrs *values.Object) error
- func (el *HTMLElement) SetIn(ctx context.Context, path []core.Value, value core.Value) error
- func (el *HTMLElement) SetInnerHTML(ctx context.Context, innerHTML values.String) error
- func (el *HTMLElement) SetInnerHTMLBySelector(ctx context.Context, selector, innerHTML values.String) error
- func (el *HTMLElement) SetInnerText(ctx context.Context, innerText values.String) error
- func (el *HTMLElement) SetInnerTextBySelector(ctx context.Context, selector, innerText values.String) error
- func (el *HTMLElement) SetStyle(ctx context.Context, name values.String, value core.Value) error
- func (el *HTMLElement) SetStyles(ctx context.Context, styles *values.Object) error
- func (el *HTMLElement) SetValue(ctx context.Context, value core.Value) error
- func (el *HTMLElement) String() string
- func (el *HTMLElement) Type() core.Type
- func (el *HTMLElement) Unwrap() interface{}
- func (el *HTMLElement) WaitForAttribute(ctx context.Context, name values.String, value core.Value, ...) error
- func (el *HTMLElement) WaitForClass(ctx context.Context, class values.String, when drivers.WaitEvent) error
- func (el *HTMLElement) WaitForStyle(ctx context.Context, name values.String, value core.Value, ...) error
- func (el *HTMLElement) XPath(ctx context.Context, expression values.String) (result core.Value, err error)
- type HTMLElementIdentity
- type Manager
- func (m *Manager) AddAttrModifiedListener(listener AttrModifiedListener) events.ListenerID
- func (m *Manager) AddAttrRemovedListener(listener AttrRemovedListener) events.ListenerID
- func (m *Manager) AddChildNodeCountUpdatedListener(listener ChildNodeCountUpdatedListener) events.ListenerID
- func (m *Manager) AddChildNodeInsertedListener(listener ChildNodeInsertedListener) events.ListenerID
- func (m *Manager) AddChildNodeRemovedListener(listener ChildNodeRemovedListener) events.ListenerID
- func (m *Manager) AddDocumentUpdatedListener(listener DocumentUpdatedListener) events.ListenerID
- func (m *Manager) AddFrame(frame page.FrameTree)
- func (m *Manager) Close() error
- func (m *Manager) GetFrameNode(ctx context.Context, frameID page.FrameID) (*HTMLDocument, error)
- func (m *Manager) GetFrameNodes(ctx context.Context) (*values.Array, error)
- func (m *Manager) GetFrameTree(_ context.Context, frameID page.FrameID) (page.FrameTree, error)
- func (m *Manager) GetMainFrame() *HTMLDocument
- func (m *Manager) RemoveAttrModifiedListener(listenerID events.ListenerID)
- func (m *Manager) RemoveAttrRemovedListener(listenerID events.ListenerID)
- func (m *Manager) RemoveChildNodeCountUpdatedListener(listenerID events.ListenerID)
- func (m *Manager) RemoveChildNodeInsertedListener(listenerID events.ListenerID)
- func (m *Manager) RemoveChildNodeRemovedListener(listenerID events.ListenerID)
- func (m *Manager) RemoveFrame(frameID page.FrameID) error
- func (m *Manager) RemoveFrameRecursively(frameID page.FrameID) error
- func (m *Manager) RemoveFramesByParentID(parentFrameID page.FrameID) error
- func (m *Manager) RemoveReloadListener(listenerID events.ListenerID)
- func (m *Manager) SetMainFrame(doc *HTMLDocument)
- func (m *Manager) WaitForDOMReady(ctx context.Context) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AttrModifiedListener ¶
type AttrRemovedListener ¶
type DocumentUpdatedListener ¶
type HTMLDocument ¶
type HTMLDocument struct {
// contains filtered or unexported fields
}
func LoadHTMLDocument ¶
func LoadRootHTMLDocument ¶
func NewHTMLDocument ¶
func NewHTMLDocument( logger *zerolog.Logger, client *cdp.Client, domManager *Manager, input *input.Manager, exec *eval.ExecutionContext, rootElement *HTMLElement, frames page.FrameTree, ) *HTMLDocument
func (*HTMLDocument) Close ¶
func (doc *HTMLDocument) Close() error
func (*HTMLDocument) Copy ¶
func (doc *HTMLDocument) Copy() core.Value
func (*HTMLDocument) CountBySelector ¶
func (*HTMLDocument) ExistsBySelector ¶
func (*HTMLDocument) Frame ¶
func (doc *HTMLDocument) Frame() page.FrameTree
func (*HTMLDocument) GetChildDocuments ¶
func (*HTMLDocument) GetChildNode ¶
func (*HTMLDocument) GetChildNodes ¶
func (*HTMLDocument) GetElement ¶
func (doc *HTMLDocument) GetElement() drivers.HTMLElement
func (*HTMLDocument) GetName ¶
func (doc *HTMLDocument) GetName() values.String
func (*HTMLDocument) GetNodeName ¶
func (doc *HTMLDocument) GetNodeName() values.String
func (*HTMLDocument) GetNodeType ¶
func (doc *HTMLDocument) GetNodeType() values.Int
func (*HTMLDocument) GetParentDocument ¶
func (doc *HTMLDocument) GetParentDocument(ctx context.Context) (drivers.HTMLDocument, error)
func (*HTMLDocument) GetTitle ¶
func (doc *HTMLDocument) GetTitle() values.String
func (*HTMLDocument) GetURL ¶
func (doc *HTMLDocument) GetURL() values.String
func (*HTMLDocument) Hash ¶
func (doc *HTMLDocument) Hash() uint64
func (*HTMLDocument) IsDetached ¶
func (doc *HTMLDocument) IsDetached() values.Boolean
func (*HTMLDocument) Length ¶
func (doc *HTMLDocument) Length() values.Int
func (*HTMLDocument) MarshalJSON ¶
func (doc *HTMLDocument) MarshalJSON() ([]byte, error)
func (*HTMLDocument) MoveMouseByXY ¶
func (*HTMLDocument) QuerySelector ¶
func (*HTMLDocument) QuerySelectorAll ¶
func (*HTMLDocument) ScrollBottom ¶
func (doc *HTMLDocument) ScrollBottom(ctx context.Context) error
func (*HTMLDocument) ScrollBySelector ¶
func (*HTMLDocument) ScrollByXY ¶
func (*HTMLDocument) String ¶
func (doc *HTMLDocument) String() string
func (*HTMLDocument) Type ¶
func (doc *HTMLDocument) Type() core.Type
func (*HTMLDocument) Unwrap ¶
func (doc *HTMLDocument) Unwrap() interface{}
func (*HTMLDocument) WaitForAttributeBySelector ¶
func (*HTMLDocument) WaitForAttributeBySelectorAll ¶
func (*HTMLDocument) WaitForClassBySelector ¶
func (*HTMLDocument) WaitForClassBySelectorAll ¶
func (*HTMLDocument) WaitForElement ¶
func (*HTMLDocument) WaitForStyleBySelector ¶
func (*HTMLDocument) WaitForStyleBySelectorAll ¶
type HTMLElement ¶
type HTMLElement struct {
// contains filtered or unexported fields
}
func LoadHTMLElement ¶
func LoadHTMLElementWithID ¶
func LoadHTMLElementWithID( ctx context.Context, logger *zerolog.Logger, client *cdp.Client, domManager *Manager, input *input.Manager, exec *eval.ExecutionContext, id HTMLElementIdentity, ) (*HTMLElement, error)
func NewHTMLElement ¶
func NewHTMLElement( logger *zerolog.Logger, client *cdp.Client, domManager *Manager, input *input.Manager, exec *eval.ExecutionContext, id HTMLElementIdentity, nodeType int, nodeName string, children []HTMLElementIdentity, ) *HTMLElement
func (*HTMLElement) BlurBySelector ¶
func (*HTMLElement) ClearBySelector ¶
func (*HTMLElement) ClickBySelector ¶
func (*HTMLElement) ClickBySelectorAll ¶
func (*HTMLElement) Close ¶
func (el *HTMLElement) Close() error
func (*HTMLElement) Copy ¶
func (el *HTMLElement) Copy() core.Value
func (*HTMLElement) CountBySelector ¶
func (*HTMLElement) ExistsBySelector ¶
func (*HTMLElement) FocusBySelector ¶
func (*HTMLElement) GetAttribute ¶
func (*HTMLElement) GetAttributes ¶
func (*HTMLElement) GetChildNode ¶
func (*HTMLElement) GetChildNodes ¶
func (*HTMLElement) GetInnerHTML ¶
func (*HTMLElement) GetInnerHTMLBySelector ¶
func (*HTMLElement) GetInnerHTMLBySelectorAll ¶
func (*HTMLElement) GetInnerText ¶
func (*HTMLElement) GetInnerTextBySelector ¶
func (*HTMLElement) GetInnerTextBySelectorAll ¶
func (*HTMLElement) GetNodeName ¶
func (el *HTMLElement) GetNodeName() values.String
func (*HTMLElement) GetNodeType ¶
func (el *HTMLElement) GetNodeType() values.Int
func (*HTMLElement) Hash ¶
func (el *HTMLElement) Hash() uint64
func (*HTMLElement) HoverBySelector ¶
func (*HTMLElement) InputBySelector ¶
func (*HTMLElement) IsDetached ¶
func (el *HTMLElement) IsDetached() values.Boolean
func (*HTMLElement) Length ¶
func (el *HTMLElement) Length() values.Int
func (*HTMLElement) MarshalJSON ¶
func (el *HTMLElement) MarshalJSON() ([]byte, error)
func (*HTMLElement) QuerySelector ¶
func (*HTMLElement) QuerySelectorAll ¶
func (*HTMLElement) RemoveAttribute ¶
func (*HTMLElement) RemoveStyle ¶
func (*HTMLElement) ScrollIntoView ¶
func (el *HTMLElement) ScrollIntoView(ctx context.Context) error
func (*HTMLElement) SelectBySelector ¶
func (*HTMLElement) SetAttribute ¶
func (*HTMLElement) SetAttributes ¶
func (*HTMLElement) SetInnerHTML ¶
func (*HTMLElement) SetInnerHTMLBySelector ¶
func (*HTMLElement) SetInnerText ¶
func (*HTMLElement) SetInnerTextBySelector ¶
func (*HTMLElement) String ¶
func (el *HTMLElement) String() string
func (*HTMLElement) Type ¶
func (el *HTMLElement) Type() core.Type
func (*HTMLElement) Unwrap ¶
func (el *HTMLElement) Unwrap() interface{}
func (*HTMLElement) WaitForAttribute ¶
func (*HTMLElement) WaitForClass ¶
func (*HTMLElement) WaitForStyle ¶
type HTMLElementIdentity ¶
type HTMLElementIdentity struct { NodeID dom.NodeID ObjectID runtime.RemoteObjectID }
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
func (*Manager) AddAttrModifiedListener ¶
func (m *Manager) AddAttrModifiedListener(listener AttrModifiedListener) events.ListenerID
func (*Manager) AddAttrRemovedListener ¶
func (m *Manager) AddAttrRemovedListener(listener AttrRemovedListener) events.ListenerID
func (*Manager) AddChildNodeCountUpdatedListener ¶
func (m *Manager) AddChildNodeCountUpdatedListener(listener ChildNodeCountUpdatedListener) events.ListenerID
func (*Manager) AddChildNodeInsertedListener ¶
func (m *Manager) AddChildNodeInsertedListener(listener ChildNodeInsertedListener) events.ListenerID
func (*Manager) AddChildNodeRemovedListener ¶
func (m *Manager) AddChildNodeRemovedListener(listener ChildNodeRemovedListener) events.ListenerID
func (*Manager) AddDocumentUpdatedListener ¶
func (m *Manager) AddDocumentUpdatedListener(listener DocumentUpdatedListener) events.ListenerID
func (*Manager) GetFrameNode ¶
func (*Manager) GetFrameNodes ¶
func (*Manager) GetFrameTree ¶
func (*Manager) GetMainFrame ¶
func (m *Manager) GetMainFrame() *HTMLDocument
func (*Manager) RemoveAttrModifiedListener ¶
func (m *Manager) RemoveAttrModifiedListener(listenerID events.ListenerID)
func (*Manager) RemoveAttrRemovedListener ¶
func (m *Manager) RemoveAttrRemovedListener(listenerID events.ListenerID)
func (*Manager) RemoveChildNodeCountUpdatedListener ¶
func (m *Manager) RemoveChildNodeCountUpdatedListener(listenerID events.ListenerID)
func (*Manager) RemoveChildNodeInsertedListener ¶
func (m *Manager) RemoveChildNodeInsertedListener(listenerID events.ListenerID)
func (*Manager) RemoveChildNodeRemovedListener ¶
func (m *Manager) RemoveChildNodeRemovedListener(listenerID events.ListenerID)
func (*Manager) RemoveFrameRecursively ¶
func (*Manager) RemoveFramesByParentID ¶
func (*Manager) RemoveReloadListener ¶
func (m *Manager) RemoveReloadListener(listenerID events.ListenerID)
func (*Manager) SetMainFrame ¶
func (m *Manager) SetMainFrame(doc *HTMLDocument)
Click to show internal directories.
Click to hide internal directories.