mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2024-12-24 12:39:37 +00:00
44 lines
831 B
Dart
44 lines
831 B
Dart
import 'dart:ffi';
|
|
import 'package:ffi/ffi.dart';
|
|
|
|
class TransactionInfoRow extends Struct {
|
|
@Uint64()
|
|
external int amount;
|
|
|
|
@Uint64()
|
|
external int fee;
|
|
|
|
@Uint64()
|
|
external int blockHeight;
|
|
|
|
@Uint64()
|
|
external int confirmations;
|
|
|
|
@Uint32()
|
|
external int subaddrAccount;
|
|
|
|
@Int8()
|
|
external int direction;
|
|
|
|
@Int8()
|
|
external int isPending;
|
|
|
|
@Uint32()
|
|
external int subaddrIndex;
|
|
|
|
external Pointer<Utf8> hash;
|
|
|
|
external Pointer<Utf8> paymentId;
|
|
|
|
external Pointer<Utf8> assetType;
|
|
|
|
@Int64()
|
|
external int datetime;
|
|
|
|
int getDatetime() => datetime;
|
|
int getAmount() => amount >= 0 ? amount : amount * -1;
|
|
bool getIsPending() => isPending != 0;
|
|
String getHash() => hash.toDartString();
|
|
String getPaymentId() => paymentId.toDartString();
|
|
String getAssetType() => assetType.toDartString();
|
|
}
|