# [name]

A low level class for loading resources with XmlHttpRequest, used internaly by most loaders.

## Constructor

### [name]( [page:LoadingManager manager] )

[page:LoadingManager manager] — The [page:LoadingManager loadingManager] for the loader to use. Default is [page:LoadingManager THREE.DefaultLoadingManager].
Creates a new [name].

## Properties

### [property:Cache cache]

A [page:Cache cache] instance that hold the response from each request made through this loader, so each file is requested once.

### [property:String responseType]

Can be set to change the response type.

## Methods

### [method:null load]( [page:String url], [page:Function onLoad], [page:Function onProgress], [page:Function onError] )

[page:String url] — required
[page:Function onLoad] — Will be called when load completes. The argument will be the loaded text response.
[page:Function onProgress] — Will be called while load progresses. The argument will be the XmlHttpRequest instance, that contain .[page:Integer total] and .[page:Integer loaded] bytes.
[page:Function onError] — Will be called when load errors.
Begin loading from url and return the [page:String text] response that will contain the data.

### [method:null setCrossOrigin]( [page:String value] )

[page:String value] — The crossOrigin string to implement CORS for loading the url from a different domain that allows CORS.

### [method:null setResponseType]( [page:String value] )

[page:String value] — the empty string (default), "arraybuffer", "blob", "document", "json", or "text".

## Example

[example:webgl_morphtargets_human]

## Source

[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]