subscribeToFiles

abstract fun subscribeToFiles(topic: FileTopic): Flowable<SOCommFileApi.ReceivedFile>

Subscribes to download events for files on a given FileTopic.

Notice that the file returned in the ReceivedFile in the returned Flowable are placed in the temporary folder of the application. This destination can be cleaned by the Android system at any time, so if you want to keep this file persistent, it's the callers responsibility to move the file to a different, persistent location. Furthermore, if you've processed the file and do not want it to persist anymore, its the callers responsibility to delete that file from the system.

Scheduler: The returned Flowable will operate on the IO Scheduler.

Return

a Flowable which emits items every time a File has been provided and downloaded from the remote device.

Parameters

topic

The FileTopic to get the file download events from.