SkillAgentSearch skills...

RxService

a android library for use service binding with rxjava

Install / Use

/learn @jiechic/RxService
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

RxService

License Jcenter

A android library for use service binding with rxjava

Installation

Using JCenter:

repositories {
    jcenter()
}

dependencies {
    compile 'com.jiechic.android.library:rxservice:1.0.0'
}

Requirements

RxJava 2.1.0+

sourceCompatibility JavaVersion.VERSION_1_8

targetCompatibility JavaVersion.VERSION_1_8

Usage

Just enable RxService as soon as possible. In Android, for example:


class MainActivity : Activity() {

    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        RxService(this, ServiceHandler::class.java)
                .connectService()
                .map { IServiceHandler.Stub.asInterface(it) }
                .subscribe { Log.d(MainActivity::class.java.simpleName, it.sendAndGet("hello world")) }
    }
}
View on GitHub
GitHub Stars4
CategoryDevelopment
Updated2y ago
Forks0

Languages

Java

Security Score

55/100

Audited on Oct 10, 2023

No findings