RomanjiConverter

class RomanjiConverter(cache: ConversionCache, apiClient: GoogleIMEClient, logger: Logger, debugMode: Boolean = false)(source)

Constructors

Link copied to clipboard
constructor(cache: ConversionCache, apiClient: GoogleIMEClient, logger: Logger, debugMode: Boolean = false)

Functions

Link copied to clipboard
suspend fun convert(input: String): String?

Converts the given romaji input to Japanese using the API client. Utilizes a word-level cache to store and retrieve previous conversion results. Each word is cached separately to improve cache hit rate.