We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c543b34 commit 253cf8fCopy full SHA for 253cf8f
1 file changed
fcl-android/src/main/java/io/outblock/fcl/utils/FclError.kt
@@ -0,0 +1,34 @@
1
+package io.outblock.fcl.utils
2
+
3
+import io.outblock.fcl.BuildConfig
4
5
+class FCLException(
6
+ private val error: FclError,
7
+ private val exception: Exception? = null,
8
+) : Exception(error.value) {
9
10
+ init {
11
+ if (BuildConfig.DEBUG) {
12
+ printStackTrace()
13
+ }
14
15
16
+}
17
18
+enum class FclError(val value: String) {
19
+ generic("generic"),
20
+ invaildURL("invaildURL"),
21
+ invaildService("invaildService"),
22
+ invalidSession("invalidSession"),
23
+ declined("declined"),
24
+ invalidResponse("invalidResponse"),
25
+ decodeFailure("decodeFailure"),
26
+ unauthenticated("unauthenticated"),
27
+ missingPreAuthz("missingPreAuthz"),
28
+ missingPayer("missingPayer"),
29
+ encodeFailure("encodeFailure"),
30
+ convertToTxFailure("convertToTxFailure"),
31
+ invaildProposer("invaildProposer"),
32
+ fetchAccountFailure("fetchAccountFailure"),
33
+ invaildContext("invaildContext"),
34
0 commit comments