Module: IXMLHttpRequest

Includes:
WIN32OLE::VARIANT
Defined in:
sample/xml.rb

Overview

IXMLHttpRequest Interface

Constant Summary

Constants included from WIN32OLE::VARIANT

WIN32OLE::VARIANT::VT_ARRAY, WIN32OLE::VARIANT::VT_BOOL, WIN32OLE::VARIANT::VT_BSTR, WIN32OLE::VARIANT::VT_BYREF, WIN32OLE::VARIANT::VT_CY, WIN32OLE::VARIANT::VT_DATE, WIN32OLE::VARIANT::VT_DISPATCH, WIN32OLE::VARIANT::VT_EMPTY, WIN32OLE::VARIANT::VT_ERROR, WIN32OLE::VARIANT::VT_I1, WIN32OLE::VARIANT::VT_I2, WIN32OLE::VARIANT::VT_I4, WIN32OLE::VARIANT::VT_I8, WIN32OLE::VARIANT::VT_INT, WIN32OLE::VARIANT::VT_NULL, WIN32OLE::VARIANT::VT_PTR, WIN32OLE::VARIANT::VT_R4, WIN32OLE::VARIANT::VT_R8, WIN32OLE::VARIANT::VT_UI1, WIN32OLE::VARIANT::VT_UI2, WIN32OLE::VARIANT::VT_UI4, WIN32OLE::VARIANT::VT_UI8, WIN32OLE::VARIANT::VT_UINT, WIN32OLE::VARIANT::VT_UNKNOWN, WIN32OLE::VARIANT::VT_USERDEFINED, WIN32OLE::VARIANT::VT_VARIANT

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#lastargsObject (readonly)

Returns the value of attribute lastargs


6859
6860
6861
# File 'sample/xml.rb', line 6859

def lastargs
  @lastargs
end

Instance Method Details

#abortObject

VOID abort Abort HTTP request


6976
6977
6978
6979
6980
# File 'sample/xml.rb', line 6976

def abort()
  ret = _invoke(6, [], [])
  @lastargs = WIN32OLE::ARGV
  ret
end

#getAllResponseHeadersObject

BSTR getAllResponseHeaders Get all HTTP response headers


6959
6960
6961
6962
6963
# File 'sample/xml.rb', line 6959

def getAllResponseHeaders()
  ret = _invoke(4, [], [])
  @lastargs = WIN32OLE::ARGV
  ret
end

#getResponseHeader(arg0) ⇒ Object

BSTR getResponseHeader Get HTTP response header

BSTR arg0 --- bstrHeader [IN]

6951
6952
6953
6954
6955
# File 'sample/xml.rb', line 6951

def getResponseHeader(arg0)
  ret = _invoke(3, [arg0], [VT_BSTR])
  @lastargs = WIN32OLE::ARGV
  ret
end

#onreadystatechange=(arg0) ⇒ Object

VOID onreadystatechange Register a complete event handler


6919
6920
6921
6922
6923
# File 'sample/xml.rb', line 6919

def onreadystatechange=(arg0)
  ret = _setproperty(14, [arg0], [VT_VARIANT])
  @lastargs = WIN32OLE::ARGV
  ret
end

#open(arg0, arg1, arg2 = nil, arg3 = nil, arg4 = nil) ⇒ Object

VOID open Open HTTP connection

BSTR arg0 --- bstrMethod [IN]
BSTR arg1 --- bstrUrl [IN]
VARIANT arg2 --- varAsync [IN]
VARIANT arg3 --- bstrUser [IN]
VARIANT arg4 --- bstrPassword [IN]

6932
6933
6934
6935
6936
# File 'sample/xml.rb', line 6932

def open(arg0, arg1, arg2=nil, arg3=nil, arg4=nil)
  ret = _invoke(1, [arg0, arg1, arg2, arg3, arg4], [VT_BSTR, VT_BSTR, VT_VARIANT, VT_VARIANT, VT_VARIANT])
  @lastargs = WIN32OLE::ARGV
  ret
end

#readyStateObject

I4 readyState Get ready state


6911
6912
6913
6914
6915
# File 'sample/xml.rb', line 6911

def readyState()
  ret = _getproperty(13, [], [])
  @lastargs = WIN32OLE::ARGV
  ret
end

#responseBodyObject

VARIANT responseBody Get response body


6895
6896
6897
6898
6899
# File 'sample/xml.rb', line 6895

def responseBody()
  ret = _getproperty(11, [], [])
  @lastargs = WIN32OLE::ARGV
  ret
end

#responseStreamObject

VARIANT responseStream Get response body


6903
6904
6905
6906
6907
# File 'sample/xml.rb', line 6903

def responseStream()
  ret = _getproperty(12, [], [])
  @lastargs = WIN32OLE::ARGV
  ret
end

#responseTextObject

BSTR responseText Get response body


6887
6888
6889
6890
6891
# File 'sample/xml.rb', line 6887

def responseText()
  ret = _getproperty(10, [], [])
  @lastargs = WIN32OLE::ARGV
  ret
end

#responseXMLObject

DISPATCH responseXML Get response body


6879
6880
6881
6882
6883
# File 'sample/xml.rb', line 6879

def responseXML()
  ret = _getproperty(9, [], [])
  @lastargs = WIN32OLE::ARGV
  ret
end

#send(arg0 = nil) ⇒ Object

VOID send Send HTTP request

VARIANT arg0 --- varBody [IN]

6968
6969
6970
6971
6972
# File 'sample/xml.rb', line 6968

def send(arg0=nil)
  ret = _invoke(5, [arg0], [VT_VARIANT])
  @lastargs = WIN32OLE::ARGV
  ret
end

#setRequestHeader(arg0, arg1) ⇒ Object

VOID setRequestHeader Add HTTP request header

BSTR arg0 --- bstrHeader [IN]
BSTR arg1 --- bstrValue [IN]

6942
6943
6944
6945
6946
# File 'sample/xml.rb', line 6942

def setRequestHeader(arg0, arg1)
  ret = _invoke(2, [arg0, arg1], [VT_BSTR, VT_BSTR])
  @lastargs = WIN32OLE::ARGV
  ret
end

#statusObject

I4 status Get HTTP status code


6863
6864
6865
6866
6867
# File 'sample/xml.rb', line 6863

def status()
  ret = _getproperty(7, [], [])
  @lastargs = WIN32OLE::ARGV
  ret
end

#statusTextObject

BSTR statusText Get HTTP status text


6871
6872
6873
6874
6875
# File 'sample/xml.rb', line 6871

def statusText()
  ret = _getproperty(8, [], [])
  @lastargs = WIN32OLE::ARGV
  ret
end