Class: IEgrip::Document
Overview
Constant Summary
Constants inherited
from Node
Node::NODETYPE_DIC
Instance Method Summary
collapse
#getElementByName, #getElementByText, #getElementByTitle, #getElementByValue, #getElementsByName, #getElementsByTagName, #getElementsByText, #getElementsByTitle, #getElementsByValue
#childElements, #childNodes, #contains, #firstChild, #hasChildElements, #hasChildNodes, #isEqualNode, #lastChild, #nextSibling, #previousSibling, #struct
Methods inherited from Node
#inspect, #nodeName, #nodeType, #nodeTypeName
Methods inherited from GripWrapper
#initialize, #inspect, #ole_methodNames, #raw
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
in the class IEgrip::GripWrapper
Instance Method Details
#all ⇒ Object
349
350
351
352
|
# File 'lib/iegrip.rb', line 349
def all
raw_all = @raw_object.all
raw_all ? HTMLElementCollection.new(raw_all, @ie_obj) : nil
end
|
#body ⇒ Object
345
346
347
|
# File 'lib/iegrip.rb', line 345
def body()
HTMLElement.new(@raw_object.body, @ie_obj)
end
|
#createAttribute(attr_name) ⇒ Object
378
379
380
381
|
# File 'lib/iegrip.rb', line 378
def createAttribute(attr_name)
raw_attr = @raw_object.createAttribute(attr_name);
Attr.new(raw_attr, @ie_obj)
end
|
#createElement(tag_name) ⇒ Object
373
374
375
376
|
# File 'lib/iegrip.rb', line 373
def createElement(tag_name)
raw_element = @raw_object.createElement(tag_name)
HTMLElement.new(raw_element, @ie_obj)
end
|
#documentElement ⇒ Object
368
369
370
371
|
# File 'lib/iegrip.rb', line 368
def documentElement
raw_element = @raw_object.documentElement()
raw_element ? HTMLElement.new(raw_element, @ie_obj) : nil
end
|
#frames(index = nil) ⇒ Object
354
355
356
357
358
359
360
361
|
# File 'lib/iegrip.rb', line 354
def frames(index=nil)
if index
return(nil) if index >= @raw_object.Frames.length
Frames.new(@raw_object.frames, @ie_obj)[index]
else
Frames.new(@raw_object.frames, @ie_obj)
end
end
|
#getElementById(element_id) ⇒ Object
363
364
365
366
|
# File 'lib/iegrip.rb', line 363
def getElementById(element_id)
raw_element = @raw_object.getElementById(element_id)
raw_element ? HTMLElement.new(raw_element, @ie_obj) : nil
end
|
#head ⇒ Object
340
341
342
343
|
# File 'lib/iegrip.rb', line 340
def head()
raw_head = @raw_object.head
raw_head ? HTMLElement.new(raw_head, @ie_obj) : nil
end
|