|
@@ -41,10 +41,11 @@ private typedef AbstractSocket = {
|
|
|
/**
|
|
|
This class can be used to handle Http requests consistently across
|
|
|
platforms. There are two intended usages:
|
|
|
+
|
|
|
- call haxe.Http.requestUrl(url) and receive the result as a String (not
|
|
|
- available on flash)
|
|
|
+ available on flash)
|
|
|
- create a new haxe.Http(url), register your callbacks for onData, onError
|
|
|
- and onStatus, then call request().
|
|
|
+ and onStatus, then call request().
|
|
|
**/
|
|
|
class Http {
|
|
|
|
|
@@ -699,7 +700,7 @@ class Http {
|
|
|
the result String.
|
|
|
|
|
|
The intended usage is to bind it to a custom function:
|
|
|
- httpInstance.onData = function(data) { // handle result }
|
|
|
+ `httpInstance.onData = function(data) { // handle result }`
|
|
|
**/
|
|
|
public dynamic function onData( data : String ) {
|
|
|
}
|
|
@@ -709,7 +710,7 @@ class Http {
|
|
|
error description.
|
|
|
|
|
|
The intended usage is to bind it to a custom function:
|
|
|
- httpInstance.onError = function(msg) { // handle error }
|
|
|
+ `httpInstance.onError = function(msg) { // handle error }`
|
|
|
**/
|
|
|
public dynamic function onError( msg : String ) {
|
|
|
}
|
|
@@ -719,7 +720,7 @@ class Http {
|
|
|
new status.
|
|
|
|
|
|
The intended usage is to bind it to a custom function:
|
|
|
- httpInstance.onStatus = function(status) { // handle status }
|
|
|
+ `httpInstance.onStatus = function(status) { // handle status }`
|
|
|
**/
|
|
|
public dynamic function onStatus( status : Int ) {
|
|
|
}
|