Want *WantParseUri(const char *uri)
|
Converts a specified character string into a Want object.
|
const char *WantToUri(Want want)
|
Converts a specified Want object into a character string.
|
void SetWantElement(Want *want, ElementName element);
|
Sets the element variable for a specified Want object.
|
void SetWantData(Want *want, const void *data, uint16_t dataLength)
|
Sets data to carry in a specified Want object for starting a particular ability.
|
bool SetWantSvcIdentity(Want *want, SvcIdentity sid)
|
Sets the sid member variable for a specified Want object.
|
void ClearWant(Want *want)
|
Clears the memory of a specified Want object.
|
void SetMainRoute(const std::string &entry)
|
Sets the main route for the ability.
|
void SetUIContent(RootView *rootView)
|
Sets the UI layout for the ability.
|
void OnStart(const Want& intent)
|
Called when the ability is started. This callback is invoked to handle transitions between ability lifecycle states.
|
void OnStop()
|
Called when the ability is being destroyed. This callback is invoked to handle transitions between ability lifecycle states.
|
void OnActive(const Want& intent)
|
Called when the ability is visible to users. This callback is invoked to handle transitions between ability lifecycle states.
|
void OnInactive()
|
Called when the ability is invisible to users. This callback is invoked to handle transitions between ability lifecycle states.
|
void OnBackground()
|
Called when the ability is moved to the background. This callback is invoked to handle transitions between ability lifecycle states.
|
const SvcIdentity *OnConnect(const Want &want)
|
Called when the Service ability is connected for the first time.
|
void OnDisconnect(const Want &want);
|
Called when all abilities connected to the Service ability are disconnected.
|
void MsgHandle(uint32_t funcId, IpcIo *request, IpcIo *reply);
|
Handles a message sent by the client to the Service ability.
|
void Dump(const std::string &extra)
|
Prints ability information to the console.
|
void Present(AbilitySlice *abilitySlice, const Want &want)
|
Presents another ability slice.
|
void Terminate()
|
Destroys the ability slice.
|
void SetUIContent(RootView *rootView)
|
Sets the UI layout for the host ability of the ability slice.
|
void OnStart(const Want& want)
|
Called when the ability slice is started. This callback is invoked to handle transitions between ability slice lifecycle states.
|
void OnStop()
|
Called when the ability slice is being destroyed. This callback is invoked to handle transitions between ability slice lifecycle states.
|
void OnActive(const Want& want)
|
Called when the ability slice is visible to users. This callback is invoked to handle transitions between ability slice lifecycle states.
|
void OnInactive()
|
Called when the ability slice is invisible to users. This callback is invoked to handle transitions between ability slice lifecycle states.
|
void OnBackground()
|
Called when the ability slice is moved to the background. This callback is invoked to handle transitions between ability slice lifecycle states.
|
int StartAbility(const Want &want)
|
Starts an ability based on the specified Want information.
|
int StopAbility(const Want &want)
|
Stops a Service ability based on the specified Want information.
|
int TerminateAbility()
|
Destroys the ability.
|
int ConnectAbility(const Want &want, const IAbilityConnection &conn, void *data);
|
Connects to a Service ability based on the specified Want information.
|
int DisconnectAbility(const IAbilityConnection &conn)
|
Disconnects from a Service ability.
|
const char *GetBundleName()
|
Obtains the bundle name of the application to which the ability belongs.
|
const char *GetSrcPath()
|
Obtains the source code path of the ability.
|
const char *GetDataPath()
|
Obtains the data path of the ability.
|
int StartAbility(const Want *want)
|
Starts an Ability. This function does not need to be used in applications developed based on Ability.
|
int ConnectAbility(const Want *want, const IAbilityConnection *conn, void *data);
|
Connects to a Service ability based on the specified Want information. This function does not need to be used in applications developed based on Ability.
|
int DisconnectAbility(const IAbilityConnection *conn);
|
Disconnects from a Service ability. This function does not need to be used in applications developed based on Ability.
|
int StopAbility(const Want *want)
|
Stops a Service ability based on the specified Want information. This function does not need to be used in applications developed based on Ability.
|
void (*OnAbilityConnectDone)(ElementName *elementName, SvcIdentity *serviceSid, int resultCode, void *data)
|
Called when a client is connected to a Service ability.
|
void (*OnAbilityDisconnectDone)(ElementName *elementName, int resultCode, void *data)
|
Called after all connections to a Service ability are disconnected.
|
void PostTask(const Task& task)
|
Posts a task to an asynchronous thread.
|
void PostQuit()
|
Quits the event loop of the current thread.
|
static AbilityEventHandler* GetCurrentHandler()
|
Obtains the event handler of the current thread.
|
void Run()
|
Starts running the event loop of the current thread.
|
#define REGISTER_AA(className)
|
Registers the class name of an Ability child class.
|
#define REGISTER_AS(className)
|
Registers the class name of an AbilitySlice child class.
|