Search
Preparing search index...
The search index is not available
Storage SDK Reference Guide - v0.3.16
Options
All
Public
Public/Protected
All
Inherited
Menu
Storage SDK Reference Guide - v0.3.16
StorageProvider
Class StorageProvider
Hierarchy
StorageProvider
Index
Constructors
constructor
Properties
files
Methods
check
Permission
download
get
Access
get
Blob
get
Downloader
get
Uploader
grant
App
Permission
link
Nft
login
make
MetadataURL
my
Files
num
Of
My
Files
num
Of
My
Files
Pages
num
Of
Shared
Files
num
Of
Shared
Files
Pages
on
Account
Change
on
Network
Change
shared
Files
upload
init
Constructors
constructor
new
Storage
Provider
(
cfg
:
Config
)
:
StorageProvider
Parameters
cfg:
Config
Returns
StorageProvider
Properties
files
files
:
FileAPI
Methods
check
Permission
check
Permission
(
)
:
Promise
<
boolean
>
Returns
Promise
<
boolean
>
download
download
(
did
:
any
, onProgress
:
(
(
bytesDownloaded
:
number
, bytesTotal
:
number
)
=>
Promise
<
void
>
)
)
:
Promise
<
void
>
Parameters
did:
any
onProgress:
(
(
bytesDownloaded
:
number
, bytesTotal
:
number
)
=>
Promise
<
void
>
)
(
bytesDownloaded
:
number
, bytesTotal
:
number
)
:
Promise
<
void
>
Parameters
bytesDownloaded:
number
bytesTotal:
number
Returns
Promise
<
void
>
Returns
Promise
<
void
>
get
Access
get
Access
(
)
:
Promise
<
FileAPI
>
Returns
Promise
<
FileAPI
>
get
Blob
get
Blob
(
did
:
any
, onProgress
:
(
(
bytesDownloaded
:
number
, bytesTotal
:
number
)
=>
Promise
<
void
>
)
)
:
Promise
<
Blob
>
Parameters
did:
any
onProgress:
(
(
bytesDownloaded
:
number
, bytesTotal
:
number
)
=>
Promise
<
void
>
)
(
bytesDownloaded
:
number
, bytesTotal
:
number
)
:
Promise
<
void
>
Parameters
bytesDownloaded:
number
bytesTotal:
number
Returns
Promise
<
void
>
Returns
Promise
<
Blob
>
get
Downloader
get
Downloader
(
)
:
Promise
<
Downloader
>
Returns
Promise
<
Downloader
>
get
Uploader
get
Uploader
(
)
:
Promise
<
Uploader
>
Returns
Promise
<
Uploader
>
grant
App
Permission
grant
App
Permission
(
)
:
Promise
<
any
>
Returns
Promise
<
any
>
link
Nft
link
Nft
(
fileId
:
string
, tokenId
:
number
, nftContract
:
string
, nftChainID
:
number
)
:
Promise
<
any
>
Parameters
fileId:
string
tokenId:
number
nftContract:
string
nftChainID:
number
Returns
Promise
<
any
>
login
login
(
)
:
Promise
<
void
>
Returns
Promise
<
void
>
make
MetadataURL
make
MetadataURL
(
title
:
string
, description
:
string
, did
:
string
, file
:
File
)
:
Promise
<
string
>
Parameters
title:
string
description:
string
did:
string
file:
File
Returns
Promise
<
string
>
my
Files
my
Files
(
pageNumber
?:
number
, pageSize
?:
number
)
:
Promise
<
any
[]
>
Parameters
pageNumber:
number
= 1
pageSize:
number
= 20
Returns
Promise
<
any
[]
>
num
Of
My
Files
num
Of
My
Files
(
)
:
Promise
<
any
>
Returns
Promise
<
any
>
num
Of
My
Files
Pages
num
Of
My
Files
Pages
(
pageSize
?:
number
)
:
Promise
<
number
>
Parameters
pageSize:
number
= 20
Returns
Promise
<
number
>
num
Of
Shared
Files
num
Of
Shared
Files
(
)
:
Promise
<
any
>
Returns
Promise
<
any
>
num
Of
Shared
Files
Pages
num
Of
Shared
Files
Pages
(
pageSize
?:
number
)
:
Promise
<
number
>
Parameters
pageSize:
number
= 20
Returns
Promise
<
number
>
on
Account
Change
on
Account
Change
(
accounts
:
any
)
:
void
Parameters
accounts:
any
Returns
void
on
Network
Change
on
Network
Change
(
newNetwork
:
any
, oldNetwork
:
any
)
:
void
Parameters
newNetwork:
any
oldNetwork:
any
Returns
void
shared
Files
shared
Files
(
pageNumber
?:
number
, pageSize
?:
number
)
:
Promise
<
any
[]
>
Parameters
pageNumber:
number
= 1
pageSize:
number
= 20
Returns
Promise
<
any
[]
>
upload
upload
(
fileRaw
:
any
, params
?:
UploadParams
&
{
onProgress
:
any
}
)
:
Promise
<
string
>
Parameters
fileRaw:
any
params:
UploadParams
&
{
onProgress
:
any
}
= ...
Returns
Promise
<
string
>
Static
init
init
(
cfg
:
Config
)
:
Promise
<
StorageProvider
>
Parameters
cfg:
Config
Returns
Promise
<
StorageProvider
>
Exports
<internal>
Storage
Provider
constructor
files
check
Permission
download
get
Access
get
Blob
get
Downloader
get
Uploader
grant
App
Permission
link
Nft
login
make
MetadataURL
my
Files
num
Of
My
Files
num
Of
My
Files
Pages
num
Of
Shared
Files
num
Of
Shared
Files
Pages
on
Account
Change
on
Network
Change
shared
Files
upload
init
Generated using
TypeDoc
, the 11/9/2022 at 3:32:28 PM