AppWidgetProviderWithCallbacks
public
class
AppWidgetProviderWithCallbacks
extends AppWidgetProvider
implements
CallbackReceiver<T extends CallbackReceiver>
Version of AppWidgetProvider
that implements a CallbackReceiver
.
Summary
Inherited methods |
|
From class
android.content.BroadcastReceiver
final
void
|
abortBroadcast()
|
final
void
|
clearAbortBroadcast()
|
final
boolean
|
getAbortBroadcast()
|
final
boolean
|
getDebugUnregister()
|
final
int
|
getResultCode()
|
final
String
|
getResultData()
|
final
Bundle
|
getResultExtras(boolean arg0)
|
final
BroadcastReceiver.PendingResult
|
goAsync()
|
final
boolean
|
isInitialStickyBroadcast()
|
final
boolean
|
isOrderedBroadcast()
|
abstract
void
|
onReceive(Context arg0, Intent arg1)
|
IBinder
|
peekService(Context arg0, Intent arg1)
|
final
void
|
setDebugUnregister(boolean arg0)
|
final
void
|
setOrderedHint(boolean arg0)
|
final
void
|
setResult(int arg0, String arg1, Bundle arg2)
|
final
void
|
setResultCode(int arg0)
|
final
void
|
setResultData(String arg0)
|
final
void
|
setResultExtras(Bundle arg0)
|
|
From class
java.lang.Object
Object
|
clone()
|
boolean
|
equals(Object arg0)
|
void
|
finalize()
|
final
Class<?>
|
getClass()
|
int
|
hashCode()
|
final
void
|
notify()
|
final
void
|
notifyAll()
|
String
|
toString()
|
final
void
|
wait(long arg0, int arg1)
|
final
void
|
wait(long arg0)
|
final
void
|
wait()
|
|
|
Public constructors
public AppWidgetProviderWithCallbacks ()
Public methods
createRemoteCallback
public T createRemoteCallback (Context context)
Creates a RemoteCallback
that will call the method with method
specified with the arguments specified when triggered. Only methods
tagged with RemoteCallable
can be used here.
This method returns a stub implementation of the class calling it to
record the arguments/method being used. This should only be used in a
chain of 2 calls, starting with createRemoteCallback(), then followed
up with a call to any method tagged with RemoteCallable
.
createRemoteCallback().callMyMethod("My arguments", 43, 2.4)
.toPendingIntent(context);
\@RemoteCallable
public RemoteCallback callMyMethod(String argStr, int argInt, double argDouble) {
...
return RemoteCallback.LOCAL;
}
Parameters |
context |
Context |
onReceive
public void onReceive (Context context,
Intent intent)
Parameters |
context |
Context |
intent |
Intent |