Updated on 2026-08-14

This commit is contained in:
Tangem 2022-11-16 16:28:08 +03:00
parent 37054e453d
commit b925625342
16 changed files with 223 additions and 3 deletions

View file

@ -0,0 +1,8 @@
package com.tangem.crypto
interface DerivationManager {
fun deriveMissingBlockchains(networkId: String?)
fun hasDerivation(): Boolean
}

View file

@ -0,0 +1,40 @@
package com.tangem.crypto
import com.tangem.crypto.models.Token
/**
* Provider for user tokens data
*/
interface UserWalletManager {
/**
* Returns all user tokens (merged from local and backend)
*/
fun getUserTokens(): List<Token>
/**
* Returns user walletId
*/
fun getWalletId(): String
/**
* Checks that token added to user wallet
*
* @param token to receive referral payments
*/
fun isTokenAdded(token: Token): Boolean
/**
* Adds token to wallet if its not
*
* @param token to add to wallet
*/
fun addToken(token: Token)
/**
* Returns wallet public address for token
*
* @param token for which find address
*/
fun getWalletAddress(token: Token): String
}

View file

@ -0,0 +1,10 @@
package com.tangem.crypto.models
data class Token(
val id: String,
val name: String,
val symbol: String,
val networkId: String?,
val contractAddress: String?,
val decimalCount: Int?,
)