mirror of
https://github.com/oceanprotocol/ocean.js.git
synced 2024-11-26 20:39:05 +01:00
added docs for compute methods
This commit is contained in:
parent
ba9cd6a6da
commit
06f9149078
@ -230,6 +230,18 @@ export class Provider {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Allows download of asset data file.
|
||||||
|
* @param {string} did
|
||||||
|
* @param {string} destination
|
||||||
|
* @param {string} accountId
|
||||||
|
* @param {FileMetadata[]} files
|
||||||
|
* @param {-1} index
|
||||||
|
* @param {string} providerUri
|
||||||
|
* @param {Web3} web3
|
||||||
|
* @param {any} fetchMethod
|
||||||
|
* @param {UserCustomParameters} userCustomParameters
|
||||||
|
* @return {Promise<any>}
|
||||||
|
*/
|
||||||
public async download(
|
public async download(
|
||||||
did: string,
|
did: string,
|
||||||
destination: string,
|
destination: string,
|
||||||
@ -285,6 +297,14 @@ export class Provider {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** Instruct the provider to start a compute job
|
/** Instruct the provider to start a compute job
|
||||||
|
* @param {string} did
|
||||||
|
* @param {string} consumerAddress
|
||||||
|
* @param {ComputeAlgorithm} algorithm
|
||||||
|
* @param {string} providerUri
|
||||||
|
* @param {Web3} web3
|
||||||
|
* @param {any} fetchMethod
|
||||||
|
* @param {ComputeOutput} output
|
||||||
|
* @return {Promise<ComputeJob | ComputeJob[]>}
|
||||||
*/
|
*/
|
||||||
public async computeStart(
|
public async computeStart(
|
||||||
did: string,
|
did: string,
|
||||||
@ -347,7 +367,14 @@ export class Provider {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Instruct the provider to stop a compute job
|
/** Instruct the provider to Stop the execution of a to stop a compute job.
|
||||||
|
* @param {string} did
|
||||||
|
* @param {string} consumerAddress
|
||||||
|
* @param {string} jobId
|
||||||
|
* @param {string} providerUri
|
||||||
|
* @param {Web3} web3
|
||||||
|
* @param {any} fetchMethod
|
||||||
|
* @return {Promise<ComputeJob | ComputeJob[]>}
|
||||||
*/
|
*/
|
||||||
public async computeStop(
|
public async computeStop(
|
||||||
did: string,
|
did: string,
|
||||||
@ -408,6 +435,15 @@ export class Provider {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Get status for a specific jobId/documentId/owner.
|
||||||
|
* @param {string} did
|
||||||
|
* @param {string} consumerAddress
|
||||||
|
* @param {string} providerUri
|
||||||
|
* @param {Web3} web3
|
||||||
|
* @param {any} fetchMethod
|
||||||
|
* @param {string} jobId
|
||||||
|
* @return {Promise<ComputeJob | ComputeJob[]>}
|
||||||
|
*/
|
||||||
public async computeStatus(
|
public async computeStatus(
|
||||||
did: string,
|
did: string,
|
||||||
consumerAddress: string,
|
consumerAddress: string,
|
||||||
@ -468,6 +504,15 @@ export class Provider {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Get status for a specific jobId/documentId/owner.
|
||||||
|
* @param {string} jobId
|
||||||
|
* @param {number} index
|
||||||
|
* @param {string} providerUri
|
||||||
|
* @param {string} destination
|
||||||
|
* @param {Web3} web3
|
||||||
|
* @param {any} fetchMethod
|
||||||
|
* @return {Promise<ComputeJob | ComputeJob[]>}
|
||||||
|
*/
|
||||||
public async computeResult(
|
public async computeResult(
|
||||||
jobId: string,
|
jobId: string,
|
||||||
index: number,
|
index: number,
|
||||||
@ -519,7 +564,14 @@ export class Provider {
|
|||||||
return destination
|
return destination
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Instruct the provider to stop & delete all resources for a compute job
|
/** Deletes a compute job.
|
||||||
|
* @param {string} did
|
||||||
|
* @param {string} consumerAddress
|
||||||
|
* @param {string} jobId
|
||||||
|
* @param {string} providerUri
|
||||||
|
* @param {Web3} web3
|
||||||
|
* @param {any} fetchMethod
|
||||||
|
* @return {Promise<ComputeJob | ComputeJob[]>}
|
||||||
*/
|
*/
|
||||||
public async computeDelete(
|
public async computeDelete(
|
||||||
did: string,
|
did: string,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user