Class: VCDOM::XPath::XPathResult
- Inherits:
-
Object
- Object
- VCDOM::XPath::XPathResult
show all
- Defined in:
- lib/vcdom/xpath/xpath_result.rb,
lib/vcdom/xpath/xpath_result.rb
Defined Under Namespace
Classes: ResultBoolean, ResultNodesSnapshot, ResultNumber, ResultSingleNode, ResultString
Constant Summary
collapse
- ANY_TYPE =
:any_type
- NUMBER_TYPE =
:number_type
- STRING_TYPE =
:string_type
- BOOLEAN_TYPE =
:boolean_type
- UNORDERED_NODE_ITERATOR_TYPE =
:unordered_node_iterator_type
- ORDERED_NODE_ITERATOR_TYPE =
:ordered_node_iterator_type
- UNORDERED_NODE_SNAPSHOT_TYPE =
:unordered_node_snapshot_type
- ORDERED_NODE_SNAPSHOT_TYPE =
:ordered_node_snapshot_type
- ANY_UNORDERED_NODE_TYPE =
:any_unordered_node_type
- FIRST_ORDERED_NODE_TYPE =
:first_ordered_node_type
Instance Method Summary
collapse
Constructor Details
55
56
57
|
# File 'lib/vcdom/xpath/xpath_result.rb', line 55
def initialize( value ) @value = value
end
|
Instance Method Details
#invalid_iterator_state ⇒ Object
Signifies that the iterator has become invalid. True if resultType is UNORDERED_NODE_ITERATOR_TYPE or ORDERED_NODE_ITERATOR_TYPE and the document has been modified since this result was returned.
25
26
27
|
# File 'lib/vcdom/xpath/xpath_result.rb', line 25
def invalid_iterator_state
false
end
|
#iterate_next ⇒ Object
51
52
53
54
|
# File 'lib/vcdom/xpath/xpath_result.rb', line 51
def iterate_next()
raise XPathException.new( XPathException::TYPE_ERR,
"result type is not UNORDERED_NODE_ITERATOR_TYPE or ORDERED_NODE_ITERATOR_TYPE" )
end
|
#number_value ⇒ Object
raises(XPathException) on retrieval
#result_type ⇒ Object
20
21
22
|
# File 'lib/vcdom/xpath/xpath_result.rb', line 20
def result_type
raise "INTERNAL ERROR"
end
|
#single_node_value ⇒ Object
43
44
45
46
|
# File 'lib/vcdom/xpath/xpath_result.rb', line 43
def single_node_value
raise XPathException.new( XPathException::TYPE_ERR,
"result type is not ANY_UNORDERED_NODE_TYPE or FIRST_ORDERED_NODE_TYPE" )
end
|
#snapshot_item(index) ⇒ Object
47
48
49
50
|
# File 'lib/vcdom/xpath/xpath_result.rb', line 47
def snapshot_item( index )
raise XPathException.new( XPathException::TYPE_ERR,
"result type is not UNORDERED_NODE_SNAPSHOT_TYPE or ORDERED_NODE_SNAPSHOT_TYPE" )
end
|
#snapshot_length ⇒ Object
28
29
30
31
|
# File 'lib/vcdom/xpath/xpath_result.rb', line 28
def snapshot_length
raise XPathException.new( XPathException::TYPE_ERR,
"result type is not UNORDERED_NODE_SNAPSHOT_TYPE or ORDERED_NODE_SNAPSHOT_TYPE" )
end
|