Skip to content

Instantly share code, notes, and snippets.

@lukaszkalnik
Created February 10, 2020 15:22
Show Gist options
  • Save lukaszkalnik/0a4846ad685781dea46e2359b6e9964b to your computer and use it in GitHub Desktop.
Save lukaszkalnik/0a4846ad685781dea46e2359b6e9964b to your computer and use it in GitHub Desktop.
internal class DefaultGatewayApiService(
val getLightsUseCase: GetLightsUseCase,
val getSystemDetailUseCase: GetSystemUseCase
) : GatewayApiService {
override suspend fun getLights(roomId: String): Either<Throwable, List<Light>> =
getLightsUseCase(roomId)
override suspend fun getSystemDetail(): Either<Throwable, SystemDetail> = //...
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment