Package com.longbridge.asset
Class AssetContext
- java.lang.Object
-
- com.longbridge.asset.AssetContext
-
- All Implemented Interfaces:
AutoCloseable
public class AssetContext extends Object implements AutoCloseable
Asset context for querying and downloading account statements
-
-
Constructor Summary
Constructors Constructor Description AssetContext()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()static AssetContextcreate(Config config)Create a AssetContext objectCompletableFuture<Object>getStatementDownloadUrl(String fileKey)Get statement data download URLCompletableFuture<Object>getStatements(GetStatementListOptions opts)Get statement data list
-
-
-
Method Detail
-
create
public static AssetContext create(Config config)
Create a AssetContext object- Parameters:
config- Config object- Returns:
- A AssetContext object
-
close
public void close() throws Exception- Specified by:
closein interfaceAutoCloseable- Throws:
Exception
-
getStatements
public CompletableFuture<Object> getStatements(GetStatementListOptions opts) throws OpenApiException
Get statement data list- Parameters:
opts- Query options (statementType, startDate, limit); may be null- Returns:
- A Future representing the result of the operation
- Throws:
OpenApiException- If an error occurs
-
getStatementDownloadUrl
public CompletableFuture<Object> getStatementDownloadUrl(String fileKey) throws OpenApiException
Get statement data download URL- Parameters:
fileKey- File key obtained from getStatements- Returns:
- A Future representing the result of the operation
- Throws:
OpenApiException- If an error occurs
-
-