goweb

package module
v0.0.0-...-90fb0b4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 6, 2020 License: MIT Imports: 3 Imported by: 0

README

goweb

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Attribute

type Attribute struct {
	Type  string `json:"attr-type"`
	Value string `json:"attr-value"`
}

func (Attribute) String

func (a Attribute) String() string

type Component

type Component struct {
	Name string               `json:"comp-name"`
	Vals map[string]Attribute `json:"comp-values"`
}

func CreateComponentFromStringInterfaceMap

func CreateComponentFromStringInterfaceMap(m map[string]interface{}) *Component

func (*Component) Identifier

func (c *Component) Identifier() string

func (*Component) Length

func (c *Component) Length() int

func (*Component) Mapped

func (c *Component) Mapped() (map[string]interface{}, error)

func (*Component) String

func (c *Component) String() string

type Element

type Element struct {
	// contains filtered or unexported fields
}

func (*Element) AddEventListener

func (e *Element) AddEventListener(_eventName string, _cb js.Func) error

func (*Element) AppendChild

func (e *Element) AppendChild(_el Element)

func (*Element) GetAttribute

func (e *Element) GetAttribute(_name string) (js.Value, error)

func (*Element) GetProperty

func (e *Element) GetProperty(_names ...string) (js.Value, error)

func (*Element) ID

func (e *Element) ID() string

func (*Element) SetAttribute

func (e *Element) SetAttribute(_compName string, vals map[string]interface{})

func (*Element) SetAttributes

func (e *Element) SetAttributes(_comps []Component) error

func (*Element) SetFuncProperty

func (e *Element) SetFuncProperty(_propName string, _func js.Func) error

func (*Element) SetValueProperty

func (e *Element) SetValueProperty(_propName string, _val js.Value) error

func (*Element) String

func (e *Element) String() string

func (*Element) Tag

func (e *Element) Tag() string

func (*Element) Value

func (e *Element) Value() js.Value

type WebPage

type WebPage struct {
	// contains filtered or unexported fields
}

func NewWebPage

func NewWebPage() *WebPage

func (*WebPage) CreateElementFromValue

func (wp *WebPage) CreateElementFromValue(_v js.Value) *Element

func (*WebPage) CreateElementWithTag

func (wp *WebPage) CreateElementWithTag(_tag string) *Element

func (*WebPage) GetElementByID

func (wp *WebPage) GetElementByID(_id string) (*Element, error)

func (*WebPage) GetElementByTag

func (wp *WebPage) GetElementByTag(_tag string) (*Element, error)

GetElementByTag returns the first element in the document with the given tag (e.g. <div>, <a-entity>, etc.)

func (*WebPage) LogElement

func (wp *WebPage) LogElement(e *Element)

func (*WebPage) LogError

func (wp *WebPage) LogError(err error)

func (*WebPage) LogMessage

func (wp *WebPage) LogMessage(msg string)

func (*WebPage) LogValue

func (wp *WebPage) LogValue(_v js.Value)

func (*WebPage) PageLoaded

func (wp *WebPage) PageLoaded()

func (*WebPage) RemoveElementByID

func (wp *WebPage) RemoveElementByID(_id string)

func (*WebPage) SetCookie

func (wp *WebPage) SetCookie(_name, _val string)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL