mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2024-12-22 19:39:22 +00:00
add debug log level value to enum
This commit is contained in:
parent
08f01d3141
commit
e5d8dff6cd
10 changed files with 29 additions and 218 deletions
|
@ -15,7 +15,7 @@ void _debugLog(Object? object) {
|
|||
if (kDebugMode) {
|
||||
Logging.instance.log(
|
||||
object,
|
||||
level: LogLevel.Fatal,
|
||||
level: LogLevel.Debug,
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -124,12 +124,14 @@ const _LoglogLevelEnumValueMap = {
|
|||
r'Warning': r'Warning',
|
||||
r'Error': r'Error',
|
||||
r'Fatal': r'Fatal',
|
||||
r'Debug': r'Debug',
|
||||
};
|
||||
const _LoglogLevelValueEnumMap = {
|
||||
r'Info': LogLevel.Info,
|
||||
r'Warning': LogLevel.Warning,
|
||||
r'Error': LogLevel.Error,
|
||||
r'Fatal': LogLevel.Fatal,
|
||||
r'Debug': LogLevel.Debug,
|
||||
};
|
||||
|
||||
Id _logGetId(Log object) {
|
||||
|
|
|
@ -14,5 +14,6 @@ enum LogLevel {
|
|||
Info,
|
||||
Warning,
|
||||
Error,
|
||||
Fatal;
|
||||
Fatal,
|
||||
Debug;
|
||||
}
|
||||
|
|
|
@ -428,21 +428,21 @@ class MockElectrumXClient extends _i1.Mock implements _i5.ElectrumXClient {
|
|||
_i7.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i7.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i7.Future<Set<String>> getSparkUsedCoinsTags({
|
||||
_i7.Future<List<String>> getSparkUnhashedUsedCoinsTags({
|
||||
String? requestID,
|
||||
required int? startNumber,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkUsedCoinsTags,
|
||||
#getSparkUnhashedUsedCoinsTags,
|
||||
[],
|
||||
{
|
||||
#requestID: requestID,
|
||||
#startNumber: startNumber,
|
||||
},
|
||||
),
|
||||
returnValue: _i7.Future<Set<String>>.value(<String>{}),
|
||||
) as _i7.Future<Set<String>>);
|
||||
returnValue: _i7.Future<List<String>>.value(<String>[]),
|
||||
) as _i7.Future<List<String>>);
|
||||
@override
|
||||
_i7.Future<List<Map<String, dynamic>>> getSparkMintMetaData({
|
||||
String? requestID,
|
||||
|
|
|
@ -78,27 +78,6 @@ class MockCachedElectrumXClient extends _i1.Mock
|
|||
_i4.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i4.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i4.Future<Map<String, dynamic>> getSparkAnonymitySet({
|
||||
required String? groupId,
|
||||
String? blockhash = r'',
|
||||
required _i5.CryptoCurrency? cryptoCurrency,
|
||||
required bool? useOnlyCacheIfNotEmpty,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkAnonymitySet,
|
||||
[],
|
||||
{
|
||||
#groupId: groupId,
|
||||
#blockhash: blockhash,
|
||||
#cryptoCurrency: cryptoCurrency,
|
||||
#useOnlyCacheIfNotEmpty: useOnlyCacheIfNotEmpty,
|
||||
},
|
||||
),
|
||||
returnValue:
|
||||
_i4.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i4.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
String base64ToHex(String? source) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#base64ToHex,
|
||||
|
@ -162,17 +141,6 @@ class MockCachedElectrumXClient extends _i1.Mock
|
|||
returnValue: _i4.Future<List<String>>.value(<String>[]),
|
||||
) as _i4.Future<List<String>>);
|
||||
@override
|
||||
_i4.Future<Set<String>> getSparkUsedCoinsTags(
|
||||
{required _i5.CryptoCurrency? cryptoCurrency}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkUsedCoinsTags,
|
||||
[],
|
||||
{#cryptoCurrency: cryptoCurrency},
|
||||
),
|
||||
returnValue: _i4.Future<Set<String>>.value(<String>{}),
|
||||
) as _i4.Future<Set<String>>);
|
||||
@override
|
||||
_i4.Future<void> clearSharedTransactionCache(
|
||||
{required _i5.CryptoCurrency? cryptoCurrency}) =>
|
||||
(super.noSuchMethod(
|
||||
|
|
|
@ -425,21 +425,21 @@ class MockElectrumXClient extends _i1.Mock implements _i4.ElectrumXClient {
|
|||
_i6.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i6.Future<Set<String>> getSparkUsedCoinsTags({
|
||||
_i6.Future<List<String>> getSparkUnhashedUsedCoinsTags({
|
||||
String? requestID,
|
||||
required int? startNumber,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkUsedCoinsTags,
|
||||
#getSparkUnhashedUsedCoinsTags,
|
||||
[],
|
||||
{
|
||||
#requestID: requestID,
|
||||
#startNumber: startNumber,
|
||||
},
|
||||
),
|
||||
returnValue: _i6.Future<Set<String>>.value(<String>{}),
|
||||
) as _i6.Future<Set<String>>);
|
||||
returnValue: _i6.Future<List<String>>.value(<String>[]),
|
||||
) as _i6.Future<List<String>>);
|
||||
@override
|
||||
_i6.Future<List<Map<String, dynamic>>> getSparkMintMetaData({
|
||||
String? requestID,
|
||||
|
@ -559,27 +559,6 @@ class MockCachedElectrumXClient extends _i1.Mock
|
|||
_i6.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i6.Future<Map<String, dynamic>> getSparkAnonymitySet({
|
||||
required String? groupId,
|
||||
String? blockhash = r'',
|
||||
required _i2.CryptoCurrency? cryptoCurrency,
|
||||
required bool? useOnlyCacheIfNotEmpty,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkAnonymitySet,
|
||||
[],
|
||||
{
|
||||
#groupId: groupId,
|
||||
#blockhash: blockhash,
|
||||
#cryptoCurrency: cryptoCurrency,
|
||||
#useOnlyCacheIfNotEmpty: useOnlyCacheIfNotEmpty,
|
||||
},
|
||||
),
|
||||
returnValue:
|
||||
_i6.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
String base64ToHex(String? source) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#base64ToHex,
|
||||
|
@ -643,17 +622,6 @@ class MockCachedElectrumXClient extends _i1.Mock
|
|||
returnValue: _i6.Future<List<String>>.value(<String>[]),
|
||||
) as _i6.Future<List<String>>);
|
||||
@override
|
||||
_i6.Future<Set<String>> getSparkUsedCoinsTags(
|
||||
{required _i2.CryptoCurrency? cryptoCurrency}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkUsedCoinsTags,
|
||||
[],
|
||||
{#cryptoCurrency: cryptoCurrency},
|
||||
),
|
||||
returnValue: _i6.Future<Set<String>>.value(<String>{}),
|
||||
) as _i6.Future<Set<String>>);
|
||||
@override
|
||||
_i6.Future<void> clearSharedTransactionCache(
|
||||
{required _i2.CryptoCurrency? cryptoCurrency}) =>
|
||||
(super.noSuchMethod(
|
||||
|
|
|
@ -425,21 +425,21 @@ class MockElectrumXClient extends _i1.Mock implements _i4.ElectrumXClient {
|
|||
_i6.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i6.Future<Set<String>> getSparkUsedCoinsTags({
|
||||
_i6.Future<List<String>> getSparkUnhashedUsedCoinsTags({
|
||||
String? requestID,
|
||||
required int? startNumber,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkUsedCoinsTags,
|
||||
#getSparkUnhashedUsedCoinsTags,
|
||||
[],
|
||||
{
|
||||
#requestID: requestID,
|
||||
#startNumber: startNumber,
|
||||
},
|
||||
),
|
||||
returnValue: _i6.Future<Set<String>>.value(<String>{}),
|
||||
) as _i6.Future<Set<String>>);
|
||||
returnValue: _i6.Future<List<String>>.value(<String>[]),
|
||||
) as _i6.Future<List<String>>);
|
||||
@override
|
||||
_i6.Future<List<Map<String, dynamic>>> getSparkMintMetaData({
|
||||
String? requestID,
|
||||
|
@ -559,27 +559,6 @@ class MockCachedElectrumXClient extends _i1.Mock
|
|||
_i6.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i6.Future<Map<String, dynamic>> getSparkAnonymitySet({
|
||||
required String? groupId,
|
||||
String? blockhash = r'',
|
||||
required _i2.CryptoCurrency? cryptoCurrency,
|
||||
required bool? useOnlyCacheIfNotEmpty,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkAnonymitySet,
|
||||
[],
|
||||
{
|
||||
#groupId: groupId,
|
||||
#blockhash: blockhash,
|
||||
#cryptoCurrency: cryptoCurrency,
|
||||
#useOnlyCacheIfNotEmpty: useOnlyCacheIfNotEmpty,
|
||||
},
|
||||
),
|
||||
returnValue:
|
||||
_i6.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
String base64ToHex(String? source) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#base64ToHex,
|
||||
|
@ -643,17 +622,6 @@ class MockCachedElectrumXClient extends _i1.Mock
|
|||
returnValue: _i6.Future<List<String>>.value(<String>[]),
|
||||
) as _i6.Future<List<String>>);
|
||||
@override
|
||||
_i6.Future<Set<String>> getSparkUsedCoinsTags(
|
||||
{required _i2.CryptoCurrency? cryptoCurrency}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkUsedCoinsTags,
|
||||
[],
|
||||
{#cryptoCurrency: cryptoCurrency},
|
||||
),
|
||||
returnValue: _i6.Future<Set<String>>.value(<String>{}),
|
||||
) as _i6.Future<Set<String>>);
|
||||
@override
|
||||
_i6.Future<void> clearSharedTransactionCache(
|
||||
{required _i2.CryptoCurrency? cryptoCurrency}) =>
|
||||
(super.noSuchMethod(
|
||||
|
|
|
@ -425,21 +425,21 @@ class MockElectrumXClient extends _i1.Mock implements _i4.ElectrumXClient {
|
|||
_i6.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i6.Future<Set<String>> getSparkUsedCoinsTags({
|
||||
_i6.Future<List<String>> getSparkUnhashedUsedCoinsTags({
|
||||
String? requestID,
|
||||
required int? startNumber,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkUsedCoinsTags,
|
||||
#getSparkUnhashedUsedCoinsTags,
|
||||
[],
|
||||
{
|
||||
#requestID: requestID,
|
||||
#startNumber: startNumber,
|
||||
},
|
||||
),
|
||||
returnValue: _i6.Future<Set<String>>.value(<String>{}),
|
||||
) as _i6.Future<Set<String>>);
|
||||
returnValue: _i6.Future<List<String>>.value(<String>[]),
|
||||
) as _i6.Future<List<String>>);
|
||||
@override
|
||||
_i6.Future<List<Map<String, dynamic>>> getSparkMintMetaData({
|
||||
String? requestID,
|
||||
|
@ -559,27 +559,6 @@ class MockCachedElectrumXClient extends _i1.Mock
|
|||
_i6.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i6.Future<Map<String, dynamic>> getSparkAnonymitySet({
|
||||
required String? groupId,
|
||||
String? blockhash = r'',
|
||||
required _i2.CryptoCurrency? cryptoCurrency,
|
||||
required bool? useOnlyCacheIfNotEmpty,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkAnonymitySet,
|
||||
[],
|
||||
{
|
||||
#groupId: groupId,
|
||||
#blockhash: blockhash,
|
||||
#cryptoCurrency: cryptoCurrency,
|
||||
#useOnlyCacheIfNotEmpty: useOnlyCacheIfNotEmpty,
|
||||
},
|
||||
),
|
||||
returnValue:
|
||||
_i6.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
String base64ToHex(String? source) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#base64ToHex,
|
||||
|
@ -643,17 +622,6 @@ class MockCachedElectrumXClient extends _i1.Mock
|
|||
returnValue: _i6.Future<List<String>>.value(<String>[]),
|
||||
) as _i6.Future<List<String>>);
|
||||
@override
|
||||
_i6.Future<Set<String>> getSparkUsedCoinsTags(
|
||||
{required _i2.CryptoCurrency? cryptoCurrency}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkUsedCoinsTags,
|
||||
[],
|
||||
{#cryptoCurrency: cryptoCurrency},
|
||||
),
|
||||
returnValue: _i6.Future<Set<String>>.value(<String>{}),
|
||||
) as _i6.Future<Set<String>>);
|
||||
@override
|
||||
_i6.Future<void> clearSharedTransactionCache(
|
||||
{required _i2.CryptoCurrency? cryptoCurrency}) =>
|
||||
(super.noSuchMethod(
|
||||
|
|
|
@ -425,21 +425,21 @@ class MockElectrumXClient extends _i1.Mock implements _i4.ElectrumXClient {
|
|||
_i6.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i6.Future<Set<String>> getSparkUsedCoinsTags({
|
||||
_i6.Future<List<String>> getSparkUnhashedUsedCoinsTags({
|
||||
String? requestID,
|
||||
required int? startNumber,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkUsedCoinsTags,
|
||||
#getSparkUnhashedUsedCoinsTags,
|
||||
[],
|
||||
{
|
||||
#requestID: requestID,
|
||||
#startNumber: startNumber,
|
||||
},
|
||||
),
|
||||
returnValue: _i6.Future<Set<String>>.value(<String>{}),
|
||||
) as _i6.Future<Set<String>>);
|
||||
returnValue: _i6.Future<List<String>>.value(<String>[]),
|
||||
) as _i6.Future<List<String>>);
|
||||
@override
|
||||
_i6.Future<List<Map<String, dynamic>>> getSparkMintMetaData({
|
||||
String? requestID,
|
||||
|
@ -559,27 +559,6 @@ class MockCachedElectrumXClient extends _i1.Mock
|
|||
_i6.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i6.Future<Map<String, dynamic>> getSparkAnonymitySet({
|
||||
required String? groupId,
|
||||
String? blockhash = r'',
|
||||
required _i2.CryptoCurrency? cryptoCurrency,
|
||||
required bool? useOnlyCacheIfNotEmpty,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkAnonymitySet,
|
||||
[],
|
||||
{
|
||||
#groupId: groupId,
|
||||
#blockhash: blockhash,
|
||||
#cryptoCurrency: cryptoCurrency,
|
||||
#useOnlyCacheIfNotEmpty: useOnlyCacheIfNotEmpty,
|
||||
},
|
||||
),
|
||||
returnValue:
|
||||
_i6.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
String base64ToHex(String? source) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#base64ToHex,
|
||||
|
@ -643,17 +622,6 @@ class MockCachedElectrumXClient extends _i1.Mock
|
|||
returnValue: _i6.Future<List<String>>.value(<String>[]),
|
||||
) as _i6.Future<List<String>>);
|
||||
@override
|
||||
_i6.Future<Set<String>> getSparkUsedCoinsTags(
|
||||
{required _i2.CryptoCurrency? cryptoCurrency}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkUsedCoinsTags,
|
||||
[],
|
||||
{#cryptoCurrency: cryptoCurrency},
|
||||
),
|
||||
returnValue: _i6.Future<Set<String>>.value(<String>{}),
|
||||
) as _i6.Future<Set<String>>);
|
||||
@override
|
||||
_i6.Future<void> clearSharedTransactionCache(
|
||||
{required _i2.CryptoCurrency? cryptoCurrency}) =>
|
||||
(super.noSuchMethod(
|
||||
|
|
|
@ -425,21 +425,21 @@ class MockElectrumXClient extends _i1.Mock implements _i4.ElectrumXClient {
|
|||
_i6.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i6.Future<Set<String>> getSparkUsedCoinsTags({
|
||||
_i6.Future<List<String>> getSparkUnhashedUsedCoinsTags({
|
||||
String? requestID,
|
||||
required int? startNumber,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkUsedCoinsTags,
|
||||
#getSparkUnhashedUsedCoinsTags,
|
||||
[],
|
||||
{
|
||||
#requestID: requestID,
|
||||
#startNumber: startNumber,
|
||||
},
|
||||
),
|
||||
returnValue: _i6.Future<Set<String>>.value(<String>{}),
|
||||
) as _i6.Future<Set<String>>);
|
||||
returnValue: _i6.Future<List<String>>.value(<String>[]),
|
||||
) as _i6.Future<List<String>>);
|
||||
@override
|
||||
_i6.Future<List<Map<String, dynamic>>> getSparkMintMetaData({
|
||||
String? requestID,
|
||||
|
@ -559,27 +559,6 @@ class MockCachedElectrumXClient extends _i1.Mock
|
|||
_i6.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i6.Future<Map<String, dynamic>> getSparkAnonymitySet({
|
||||
required String? groupId,
|
||||
String? blockhash = r'',
|
||||
required _i2.CryptoCurrency? cryptoCurrency,
|
||||
required bool? useOnlyCacheIfNotEmpty,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkAnonymitySet,
|
||||
[],
|
||||
{
|
||||
#groupId: groupId,
|
||||
#blockhash: blockhash,
|
||||
#cryptoCurrency: cryptoCurrency,
|
||||
#useOnlyCacheIfNotEmpty: useOnlyCacheIfNotEmpty,
|
||||
},
|
||||
),
|
||||
returnValue:
|
||||
_i6.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i6.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
String base64ToHex(String? source) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#base64ToHex,
|
||||
|
@ -643,17 +622,6 @@ class MockCachedElectrumXClient extends _i1.Mock
|
|||
returnValue: _i6.Future<List<String>>.value(<String>[]),
|
||||
) as _i6.Future<List<String>>);
|
||||
@override
|
||||
_i6.Future<Set<String>> getSparkUsedCoinsTags(
|
||||
{required _i2.CryptoCurrency? cryptoCurrency}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getSparkUsedCoinsTags,
|
||||
[],
|
||||
{#cryptoCurrency: cryptoCurrency},
|
||||
),
|
||||
returnValue: _i6.Future<Set<String>>.value(<String>{}),
|
||||
) as _i6.Future<Set<String>>);
|
||||
@override
|
||||
_i6.Future<void> clearSharedTransactionCache(
|
||||
{required _i2.CryptoCurrency? cryptoCurrency}) =>
|
||||
(super.noSuchMethod(
|
||||
|
|
Loading…
Reference in a new issue