2018-09-18 22:42:38 +02:00
|
|
|
package values
|
|
|
|
|
|
|
|
import "github.com/MontFerret/ferret/pkg/runtime/core"
|
|
|
|
|
2018-09-28 01:05:56 +02:00
|
|
|
type (
|
2018-10-05 22:35:08 +02:00
|
|
|
HTMLNode interface {
|
2018-09-28 01:05:56 +02:00
|
|
|
core.Value
|
2018-09-18 22:42:38 +02:00
|
|
|
|
2018-09-28 01:05:56 +02:00
|
|
|
NodeType() Int
|
2018-09-18 22:42:38 +02:00
|
|
|
|
2018-09-28 01:05:56 +02:00
|
|
|
NodeName() String
|
2018-09-18 22:42:38 +02:00
|
|
|
|
2018-09-28 01:05:56 +02:00
|
|
|
Length() Int
|
2018-09-18 22:42:38 +02:00
|
|
|
|
2018-09-28 01:05:56 +02:00
|
|
|
InnerText() String
|
2018-09-18 22:42:38 +02:00
|
|
|
|
2018-10-05 22:35:08 +02:00
|
|
|
InnerHTML() String
|
2018-09-18 22:42:38 +02:00
|
|
|
|
2018-09-28 01:05:56 +02:00
|
|
|
Value() core.Value
|
2018-09-18 22:42:38 +02:00
|
|
|
|
2018-09-28 01:05:56 +02:00
|
|
|
GetAttributes() core.Value
|
2018-09-18 22:42:38 +02:00
|
|
|
|
2018-09-28 01:05:56 +02:00
|
|
|
GetAttribute(name String) core.Value
|
2018-09-18 22:42:38 +02:00
|
|
|
|
2018-09-28 01:05:56 +02:00
|
|
|
GetChildNodes() core.Value
|
2018-09-18 22:42:38 +02:00
|
|
|
|
2018-09-28 01:05:56 +02:00
|
|
|
GetChildNode(idx Int) core.Value
|
2018-09-18 22:42:38 +02:00
|
|
|
|
2018-09-28 01:05:56 +02:00
|
|
|
QuerySelector(selector String) core.Value
|
2018-09-18 22:42:38 +02:00
|
|
|
|
2018-09-28 01:05:56 +02:00
|
|
|
QuerySelectorAll(selector String) core.Value
|
|
|
|
}
|
|
|
|
|
2018-10-05 22:35:08 +02:00
|
|
|
HTMLDocument interface {
|
|
|
|
HTMLNode
|
2018-09-28 01:05:56 +02:00
|
|
|
|
2018-10-05 22:35:08 +02:00
|
|
|
URL() core.Value
|
2018-10-07 04:33:39 +02:00
|
|
|
|
|
|
|
InnerHTMLBySelector(selector String) String
|
|
|
|
|
|
|
|
InnerHTMLBySelectorAll(selector String) *Array
|
|
|
|
|
|
|
|
InnerTextBySelector(selector String) String
|
|
|
|
|
|
|
|
InnerTextBySelectorAll(selector String) *Array
|
2018-09-28 01:05:56 +02:00
|
|
|
}
|
|
|
|
)
|