public class BlobModule extends ReactContextBaseJavaModule
NativeModule.NativeMethod
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
NAME |
METHOD_TYPE_ASYNC, METHOD_TYPE_PROMISE, METHOD_TYPE_SYNC
Constructor and Description |
---|
BlobModule(ReactApplicationContext reactContext) |
Modifier and Type | Method and Description |
---|---|
void |
addNetworkingHandler() |
void |
addWebSocketHandler(int id) |
void |
createFromParts(ReadableArray parts,
java.lang.String blobId) |
java.util.Map<java.lang.String,java.lang.Object> |
getConstants() |
java.lang.String |
getName() |
void |
initialize()
This is called at the end of
CatalystApplicationFragment#createCatalystInstance() after
the CatalystInstance has been created, in order to initialize NativeModules that require the
CatalystInstance or JS modules. |
void |
release(java.lang.String blobId) |
void |
remove(java.lang.String blobId) |
void |
removeWebSocketHandler(int id) |
byte[] |
resolve(ReadableMap blob) |
byte[] |
resolve(java.lang.String blobId,
int offset,
int size) |
byte[] |
resolve(android.net.Uri uri) |
void |
sendOverSocket(ReadableMap blob,
int id) |
java.lang.String |
store(byte[] data) |
void |
store(byte[] data,
java.lang.String blobId) |
getCurrentActivity, getReactApplicationContext
canOverrideExistingModule, hasConstants, invalidate, onCatalystInstanceDestroy
public static final java.lang.String NAME
public BlobModule(ReactApplicationContext reactContext)
public void initialize()
NativeModule
CatalystApplicationFragment#createCatalystInstance()
after
the CatalystInstance has been created, in order to initialize NativeModules that require the
CatalystInstance or JS modules.initialize
in interface NativeModule
initialize
in class BaseJavaModule
public java.lang.String getName()
require()
this module
from javascript.public java.util.Map<java.lang.String,java.lang.Object> getConstants()
getConstants
in class BaseJavaModule
public java.lang.String store(byte[] data)
public void store(byte[] data, java.lang.String blobId)
public void remove(java.lang.String blobId)
public byte[] resolve(android.net.Uri uri)
public byte[] resolve(java.lang.String blobId, int offset, int size)
public byte[] resolve(ReadableMap blob)
public void addNetworkingHandler()
public void addWebSocketHandler(int id)
public void removeWebSocketHandler(int id)
public void sendOverSocket(ReadableMap blob, int id)
public void createFromParts(ReadableArray parts, java.lang.String blobId)
public void release(java.lang.String blobId)