Loader class abstract
Base class for implementing loaders
- Implementers
Constructors
- Loader.new([LoadingManager? manager, bool flipY = false])
-
manager
— TheloadingManager
for the loader to use. Default isDefaultLoadingManager
.
Properties
- crossOrigin ↔ String
-
getter/setter pair
- flipY ↔ bool
-
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
- manager ↔ LoadingManager
-
getter/setter pair
- mimeType ↔ String
-
getter/setter pair
- path ↔ String
-
getter/setter pair
-
requestHeader
↔ Map<
String, dynamic> -
getter/setter pair
- resourcePath ↔ String?
-
getter/setter pair
- responseType ↔ String
-
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- withCredentials ↔ bool
-
getter/setter pair
Methods
-
dispose(
) → void -
fromAsset(
String asset, {String? package}) → Future -
asset
- path of the file to be loaded -
fromBlob(
Blob blob) → Future -
blob
- a blob of the file to be loaded -
fromBytes(
Uint8List bytes) → Future -
bytes
- the loaded bytes of the file -
fromFile(
File file) → Future -
file
- the file to be loaded -
fromNetwork(
Uri uri) → Future -
uri
- a uri containing the location of the file to be loaded -
fromPath(
String filePath) → Future -
filePath
- path of the file to be loaded -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
setCrossOrigin(
String crossOrigin) → Loader -
crossOrigin
— The crossOrigin string to implement CORS for loading the url from a different domain that allows CORS. -
setPath(
String path) → Loader -
path
— Set the base path for the asset. -
setRequestHeader(
Map< String, dynamic> requestHeader) → Loader -
requestHeader
- key: The name of the header whose value is to be set. value: The value to set as the body of the header. -
setResourcePath(
String? resourcePath) → Loader -
resourcePath
— Set the base path for dependent resources like textures. -
setWithCredentials(
bool value) → Loader - Whether the XMLHttpRequest uses credentials such as cookies, authorization headers or TLS client certificates. See XMLHttpRequest.withCredentials.
-
toString(
) → String -
A string representation of this object.
inherited
-
unknown(
dynamic url) → Future -
url
- a dynmaic data that gets parsed by the system
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited