blob: aae0b2129ae8f81fd0a992656d7de38946136c76 [file] [log] [blame]
// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
class $FACTORYPROVIDER {
static HttpRequest createHttpRequest() =>
JS('HttpRequest', 'new XMLHttpRequest()');
static HttpRequest createHttpRequest_get(String url,
onSuccess(HttpRequest request)) =>
_HttpRequestUtils.get(url, onSuccess, false);
static HttpRequest createHttpRequest_getWithCredentials(String url,
onSuccess(HttpRequest request)) =>
_HttpRequestUtils.get(url, onSuccess, true);
}