CN113412468A - SDK plug-in loading method and device, mobile terminal and storage medium - Google Patents

SDK plug-in loading method and device, mobile terminal and storage medium Download PDF

Info

Publication number
CN113412468A
CN113412468A CN201980091635.8A CN201980091635A CN113412468A CN 113412468 A CN113412468 A CN 113412468A CN 201980091635 A CN201980091635 A CN 201980091635A CN 113412468 A CN113412468 A CN 113412468A
Authority
CN
China
Prior art keywords
sdk plug
target
mobile terminal
application
plug
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201980091635.8A
Other languages
Chinese (zh)
Inventor
朱洪波
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Shenzhen Huantai Technology Co Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp Ltd
Shenzhen Huantai Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangdong Oppo Mobile Telecommunications Corp Ltd, Shenzhen Huantai Technology Co Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Publication of CN113412468A publication Critical patent/CN113412468A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating

Abstract

The embodiment of the application discloses a loading method and device of an SDK plug-in, a mobile terminal and a storage medium, and relates to the technical field of Internet of things. The method is applied to a mobile terminal, the mobile terminal is provided with an application program, and a fast application is added in the application program, and the method comprises the following steps: and the mobile terminal receives a first starting instruction aiming at the application program, downloads and stores a target SDK plug-in corresponding to the fast application when responding to the first starting instruction and meeting the specified downloading condition, and responds to a second starting instruction aiming at the fast application to load the target SDK plug-in from the local of the mobile terminal. The loading method, the loading device, the mobile terminal and the storage medium of the SDK plug-in provided by the embodiment of the application separate the downloading and the loading of the SDK plug-in, so that the optimization and the management of the SDK plug-in are facilitated.

Description

SDK plug-in loading method and device, mobile terminal and storage medium Technical Field
The application relates to the technical field of internet of things, in particular to a loading method and device of an SDK plug-in, a mobile terminal and a storage medium.
Background
Mobile terminals, such as tablet computers, smart phones, etc., have become one of the most common consumer electronic products in people's daily life. A user may install an application on a mobile terminal to implement various functions.
Disclosure of Invention
In view of the above problems, the present application provides a method and an apparatus for loading an SDK plug-in, a mobile terminal, and a storage medium to solve the above problems.
In a first aspect, an embodiment of the present application provides a method for loading an SDK plug-in, where the method is applied to a mobile terminal, and the mobile terminal is installed with an application program, and the application program is added with a fast application, and the method includes: the mobile terminal receives a first starting instruction aiming at the application program; when the first starting instruction is responded and the specified downloading condition is met, downloading and storing a target Software Development Kit (SDK) plug-in corresponding to the fast application; and when a second starting instruction for the fast application is received, the target SDK plug-in is loaded from the local of the mobile terminal in response to the second starting instruction.
In a second aspect, an embodiment of the present application provides a loading apparatus for an SDK plug-in, where the loading apparatus is applied to a mobile terminal, and an application is installed on the mobile terminal, and a fast application is added to the application, and the apparatus includes: the instruction receiving module is used for receiving a first starting instruction aiming at the application program by the mobile terminal; the SDK plug-in downloading module is used for downloading and storing the target software development kit SDK plug-in corresponding to the fast application when responding to the first starting instruction and meeting the specified downloading condition; and the SDK plug-in loading module is used for responding to a second starting instruction to load the target SDK plug-in from the local of the mobile terminal when the second starting instruction aiming at the fast application is received.
In a third aspect, an embodiment of the present application provides a mobile terminal, including a memory and a processor, where the memory is coupled to the processor, and the memory stores instructions, and the processor executes the above method when the instructions are executed by the processor.
In a fourth aspect, the present application provides a computer-readable storage medium, in which a program code is stored, and the program code can be called by a processor to execute the above method.
According to the loading method and device of the SDK plug-in, the mobile terminal and the storage medium provided by the embodiment of the application, the mobile terminal receives the first starting instruction aiming at the application program, when the first starting instruction is responded and the specified downloading condition is met, the target SDK plug-in corresponding to the fast application is downloaded and stored, and when the second starting instruction aiming at the fast application is received, the target SDK plug-in is loaded from the local of the mobile terminal in response to the second starting instruction, so that the target SDK plug-in is convenient to optimize and manage by separating the downloading and the loading of the SDK plug-in.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 shows an architecture diagram of an intelligent home system provided by an embodiment of the present application.
Fig. 2 shows an architecture diagram of another smart home system provided in an embodiment of the present application;
fig. 3 is a schematic diagram illustrating a fast application engine architecture provided in an embodiment of the present application.
Fig. 4 shows a schematic diagram of an adding method operating environment of a fast application provided by an embodiment of the present application.
Fig. 5 is a flowchart illustrating a loading method of an SDK plug-in according to an embodiment of the present application;
fig. 6 is a flowchart illustrating a loading method of an SDK plug-in according to another embodiment of the present application;
FIG. 7 is a flowchart illustrating the step S220 of the loading method of the SDK plug-in shown in FIG. 6 of the present application;
fig. 8 is a flowchart illustrating a step S230 of the loading method of the SDK plug-in illustrated in fig. 6 of the present application;
fig. 9 is a flowchart illustrating a step S232 of the loading method of the SDK plug-in illustrated in fig. 8 of the present application;
FIG. 10 is a flowchart illustrating the step S250 of the loading method of the SDK plug-in shown in FIG. 6 of the present application;
fig. 11 is a flowchart illustrating a loading method of an SDK plug-in according to still another embodiment of the present application;
fig. 12 is a schematic flowchart illustrating a loading method of an SDK plug-in according to another embodiment of the present application;
fig. 13 is a flowchart illustrating a loading method of an SDK plug-in according to still another embodiment of the present application;
fig. 14 shows a block diagram of modules of a loading apparatus of an SDK plug-in provided in an embodiment of the present application;
fig. 15 is a block diagram illustrating an electronic device according to an embodiment of the present application, configured to execute a loading method of an SDK plug-in according to an embodiment of the present application;
fig. 16 illustrates a storage unit for storing or carrying program codes for implementing a loading method of an SDK plug-in according to an embodiment of the present application.
Detailed Description
In order to make the technical solutions better understood by those skilled in the art, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application.
With the progress of the technology level, the smart home goes deep into each family, and is popular among multiple families due to the convenience brought by the smart home. The intelligent home is connected with various intelligent home devices (such as an air conditioner, a lighting lamp, a refrigerator, a washing machine and the like) in a home through the Internet of things technology, and various controls such as household appliance control, lighting control, telephone remote control, indoor and outdoor remote control, anti-theft alarm, environment monitoring, heating and ventilation control, infrared forwarding, programmable timing control and the like are provided.
Because the mobile terminal can be provided with the application to realize various functions, the management and the control of the household equipment can be remotely realized by installing the application program for managing and controlling the household equipment in the mobile terminal. The household equipment can be an air conditioner, a lighting lamp, an intelligent camera, an intelligent socket, a wireless switch, an intelligent curtain motor, an intelligent sound box and various sensors (such as a human body sensor, a door and window sensor, a smoke alarm and the like).
Referring to fig. 1, currently, home devices are managed and controlled by a mobile terminal, and data interaction between the mobile terminal 100 and the home devices is generally realized by establishing a wireless connection between the mobile terminal 100 and an intelligent gateway 300 and establishing a wireless connection between the home devices 200 and the intelligent gateway 300. In addition, the mobile terminal 100 and the smart gateway 300 are in communication connection with the server 400, and the mobile terminal 100 may perform data interaction with the home device through the server 400 and the smart gateway 300.
Referring to fig. 2, the mobile terminal 100 may be in communication connection with the first cloud server 402, so as to implement data interaction with the first cloud server 402. The home device 200 is in communication connection with the second cloud server 401 through the intelligent gateway 300, so that data interaction between the second cloud server and the second cloud server 401 is realized. In addition, data interaction can be performed between the first cloud server 402 and the second cloud server 401, so that the mobile terminal 100 can implement data interaction with the home equipment 200 through the first cloud server 402, the second cloud server 404 and the smart gateway 300.
At present, home devices of different manufacturers generally need to be controlled through different application programs, that is, communication between the application programs of the home devices of different manufacturers and servers of different manufacturers needs to install more application programs, so that more storage spaces of the mobile terminal are occupied.
With the popularization of Quick applications (Quick APPs), mobile terminal developers more expect to implement the same functions as the aforementioned client through Quick applications, so as to improve the development efficiency of smart home functions and save the storage space of the mobile terminal. The quick application is a novel application form based on a terminal equipment hardware platform, does not need to be installed, is used on demand, and has native application experience (performance, system integration, interaction and the like). As shown in the schematic structural diagram of the fast application engine shown in fig. 3, the front-end design of the fast application uses and integrates the design idea of the mainstream front-end framework (Vue, reach, etc.): the application is built in a componentized mode, an MVVM design mode taking data binding as a core is adopted, the performance is improved in a V-DOM mode, and meanwhile, a concise and clear template of the class Vue is selected.
As shown in fig. 4, the mobile terminal 100 shown in fig. 4 runs a fast application and an application program 110. Wherein the fast application is run on the fast application engine, and the extended interface 97 provided by the application program is set in the fast application engine. And an extension interface 96 communicating with the extension interface 97 is provided in the application 110. And the application 110 may call Software Development Kit (SDK) plug-ins of various vendors through the extension interface. For example, vendor A's SDK plug-in 111, vendor B's SDK plug-in 112, and vendor C's SDK plug-in 113 in the graph may be invoked. In this case, the data processing command triggered in the fast application may be transmitted to the extension interface 96 in the client through the extension interface 97 provided in the fast application engine, and then the data processing command is transmitted to the SDK plug-in of each vendor.
Further, the application program 110 may provide access to the fast application, that is, the fast application may be accessed by the application program 110. Communication between the fast application and the application 110 may be via cross-application communication, such as using AIDL interaction. Specifically, an interface for parameter transfer may be provided between the application program 110 and the embedded fast application, and is used for data transfer between the application program 110 and the fast application, for example, a channel class interface may be defined between the fast application and the application program 110, and all interface functions are implemented using one channel class interface. Upon entering a fast application through the application program 110, the application program 110 may instruct the fast application engine to access the corresponding fast application according to the link of the fast application, thereby exposing an interface of the fast application. The fast application interface may receive the control information, and after obtaining the control information, the application program 110 transmits the control information to the server of the home device through the SDK, so as to manage and control the home device. In addition, the fast application engine may also receive information passed by the application program 110 and display the information that needs to be displayed on the fast application control page.
The inventor finds that, through long-term research, when an application program enters a fast application, the SDK plug-ins corresponding to the fast application are all checked and updated, whether the SDK plug-ins are downloaded is judged, updating judgment is complex, the process is long, the SDK plug-ins are easily overlapped with the loading time of the SDK plug-ins, and the loading of the SDK plug-ins is slow. In view of the above problems, the inventor proposes a method and an apparatus for loading an SDK plug-in, a mobile terminal, and a storage medium provided in the embodiments of the present application, and facilitates optimization and management of the SDK plug-in by separating downloading and loading of the SDK plug-in. The specific loading method of the SDK plug-in is explained in detail in the following embodiments.
Referring to fig. 5, fig. 5 is a schematic flowchart illustrating a loading method of an SDK plug-in according to an embodiment of the present application. The loading method of the SDK plug-in is used for separating the downloading and the loading of the SDK plug-in, so that the optimization and the management of the SDK plug-in are facilitated. In a specific embodiment, the loading method of the SDK plug-in is applied to the loading apparatus 200 of the SDK plug-in shown in fig. 14 and the mobile terminal 100 (fig. 15) configured with the loading apparatus 500 of the SDK plug-in, wherein the mobile terminal is installed with an application program in which a fast application is added. The following will describe a specific flow of this embodiment by taking a mobile terminal as an example, and it is understood that the mobile terminal applied in this embodiment may be an electronic device such as a smart phone, a tablet computer, a wearable electronic device, a vehicle-mounted device, a gateway, and the like, and is not limited specifically herein. As will be described in detail with respect to the flow shown in fig. 5, the loading method of the SDK plug-in may specifically include the following steps:
step S110: the mobile terminal receives a first starting instruction aiming at the application program.
In this embodiment, the mobile terminal is installed with an application program, and the application program is added with a fast application, so that when a user wants to start the fast application, the user needs to start the application program first and then start the fast application added in the application program, and therefore, the user can send a start instruction indicating to start the application program to the mobile terminal, where the start instruction is marked as a first start instruction, and correspondingly, the mobile terminal receives the first start instruction for the application program.
As an embodiment, the first start instruction may be generated when the user performs a touch operation on the icon of the application program, for example, may be generated when a single-finger click operation on the icon of the application program is detected, may be generated when a press operation on the icon of the application program is detected, may be generated when a multi-finger click operation on the icon of the application program is detected, may be generated when a long press operation on the icon of the application program is detected, or the like, and is not limited herein; the first start instruction may be generated when detecting that the user searches for the application program in the search box of the mobile terminal, for example, when the mobile terminal detects that the user searches for "application program a" in the search box, the first start instruction indicating to start "application program a" is generated, and when the mobile terminal detects that the user searches for "application program B" in the search box, the first start instruction indicating to start "application program B" is generated; the first start instruction may be generated when it is detected that the user inputs voice information for starting the application program into the mobile terminal, for example, when the mobile terminal detects voice information of the user "start application program a", the first start instruction for instructing to start the application program a "is generated, and when the mobile terminal detects voice information of the user" start application program B ", the first start instruction for instructing to start the application program B" is generated.
Step S120: and when the first starting instruction is responded and the specified downloading condition is met, downloading and storing the target software development kit SDK plug-in corresponding to the fast application.
Further, the mobile terminal is provided with a specified download condition, wherein the specified download condition may be stored locally in the mobile terminal after being set in advance, or may be obtained from a server in real time, and in addition, the specified download condition may be configured by the mobile terminal, or may be configured by a user, which is not limited herein. Therefore, when the mobile terminal receives a first starting instruction, whether the mobile terminal meets the specified downloading condition or not can be judged, wherein when the mobile terminal meets the specified downloading condition, the target SDK plug-in corresponding to the fast application is downloaded and stored in response to the first starting instruction; and when the mobile terminal does not meet the specified downloading condition, not responding to the first starting instruction. Taking the network condition as an example, if the current network state of the mobile terminal is poor, that is, the network condition is not satisfied, and it represents that the mobile terminal cannot download the target SDK plug-in corresponding to the fast application from the server through the network, the mobile terminal may not respond to the first start instruction; and if the current network state of the mobile terminal is better, namely the current network state meets the network condition, the mobile terminal is characterized in that the mobile terminal can download the target SDK plug-in corresponding to the fast application from the server through the network, and the mobile terminal responds to the first starting instruction to download and store the target SDK plug-in.
Step S130: and when a second starting instruction for the fast application is received, the target SDK plug-in is loaded from the local of the mobile terminal in response to the second starting instruction.
In this embodiment, when a user wants to start the fast application in an application program, a start instruction indicating to start the fast application may be sent to the mobile terminal, where the start instruction is marked as a second start instruction, and correspondingly, the mobile terminal receives the second start instruction for the fast application.
As one mode, the second start instruction may be generated when the user performs a touch operation on a control in the application program of the fast application, for example, the second start instruction may be generated when a single-finger click operation on the control of the fast application is detected, may be generated when a press operation on the control of the fast application is detected, may be generated when a multi-finger click operation on the control of the fast application is detected, may be generated when a long-press operation on the control of the fast application is detected, and the like, which is not limited herein; the second start instruction may be generated when detecting that the user searches for the fast application in the search box of the application program, for example, when the mobile terminal detects that the user searches for "fast application a" in the search box of the application program, the second start instruction indicating to start "fast application a" is generated, and when the mobile terminal detects that the user searches for "fast application B" in the search box of the application program, the second start instruction indicating to start "fast application B" is generated; the second start instruction may also be generated when detecting that the user inputs voice information for starting the application program in the application program, for example, when the mobile terminal detects voice information for "starting fast application a" input by the user in the application program, the second start instruction for instructing to start the "fast application a" is generated, and when the mobile terminal detects voice information for "starting fast application B" input by the user in the application program, the second start instruction for instructing to start the "fast application B" is generated.
Further, the mobile terminal responds to the second starting instruction to load the target SDK plug-in from the local of the mobile terminal, so that the fast application can obtain corresponding control and service from the corresponding manufacturer server through the target SDK plug-in. Therefore, the target SDK plug-in is downloaded and loaded in a time-sharing mode, so that the target SDK plug-in is more flexible in downloading and loading processing and is more beneficial to optimization.
In addition, in this embodiment, the target SDK plug-in may be implemented by a main process of the mobile terminal, and the loading of the target SDK plug-in may be implemented by an ipc process or a main thread of the mobile terminal; or the target SDK plug-in may be implemented by a host process of the mobile terminal, and the loading of the target SDK plug-in may be implemented in a hybrid manner, such as simultaneously by the host process and the ipc process of the mobile terminal, or simultaneously by the host process and the host thread of the mobile terminal, for example, because the SDK plug-in has a UI of the host process, the part that is trustworthy may be loaded in the host process separately, and the other part may be implemented by the ipc process or the host thread of the mobile terminal, because the loading at the technical side is separate, it may be convenient to perform subsequent optimization processing on the SDK plug-in.
According to the loading method of the SDK plug-in, the mobile terminal receives the first starting instruction for the application program, when the first starting instruction is responded and the specified downloading condition is met, the target SDK plug-in corresponding to the fast application is downloaded and stored, and when the second starting instruction for the fast application is received, the target SDK plug-in is loaded from the local of the mobile terminal in response to the second starting instruction, so that the target SDK plug-in is convenient to optimize and manage by separating the downloading and the loading of the SDK plug-in.
Referring to fig. 6, fig. 6 is a schematic flowchart illustrating a loading method of an SDK plug-in according to another embodiment of the present application. The method is applied to the mobile terminal, and as will be described in detail below with respect to the flow shown in fig. 6, the method for loading the SDK plug-in may specifically include the following steps:
step S210: the mobile terminal receives a first starting instruction aiming at the application program.
For detailed description of step S210, please refer to step S110, which is not described herein again.
Step S220: and when the first starting instruction is responded and the specified downloading condition is met, acquiring the parameter information of the fast application.
In this embodiment, when it is determined that the mobile terminal meets the specified download condition, the parameter information of the fast application may be further obtained in response to the first start instruction, where the parameter information may be used as an input parameter of the mobile terminal to a download interface of a target SDK plug-in corresponding to the fast application.
Referring to fig. 7, fig. 7 is a flowchart illustrating a step S220 of the loading method of the SDK plug-in shown in fig. 6 according to the present application. As will be explained in detail with respect to the flow shown in fig. 7, the method may specifically include the following steps:
step S221: and acquiring brand information corresponding to the fast application.
As an implementation manner, the mobile terminal may obtain the brand information corresponding to the fast application, where the mobile terminal may obtain the brand information corresponding to the fast application from a corresponding terminal server, or obtain the brand information corresponding to the fast application from a manufacturer server corresponding to the fast application, which is not limited herein.
Taking the example that the mobile terminal obtains the brand information corresponding to the fast application from its corresponding terminal server, the mobile terminal can obtain the identification information of the fast application and send the identification information to the terminal server, the terminal server searches the brand information corresponding to the identification information according to the identification information, and returns the brand information to the mobile terminal, as an implementable manner, the terminal server stores a mapping relationship between a plurality of identification information and a plurality of brand information, when the mobile terminal acquires the identification information a of the fast application, the identification information a may be sent to the terminal server, the terminal server searches the brand information corresponding to the identification information a from the stored mapping relation, when the brand information corresponding to the identification information A is found to be brand information A, the brand information A can be returned to the mobile terminal.
Step S222: and acquiring a first protocol version number of the application program, wherein the first protocol version number is used for representing the maximum version in the protocol version numbers supported by the application program.
Further, the mobile terminal obtains a first protocol version number of the application program, where the first protocol version number is used to represent a maximum version of protocol version numbers supported by the application program, and the first protocol version number is hard-coded and written, that is, the first protocol version number is fixed, and certainly, when the version of the application program is updated, the first protocol version number may remain unchanged, or may remain unchanged after the update, which is not limited herein. For example, when the version number of the application program is "version number 1", the first protocol version number is fixed to "version number 1", and when the version number of the application program is updated to "version number 2", the first protocol version number may be kept unchanged, i.e., continuously fixed to "version number 1", or updated and fixed to "version number 2", which is not limited herein.
Step S223: generating parameter information of the fast application based on the brand information and the first protocol version number.
In this embodiment, after the brand information corresponding to the fast application and the first protocol version number of the application program are acquired, the parameter information of the fast application may be generated based on the brand information and the first protocol version number, and the parameter information may be used as an input parameter of the mobile terminal to a download interface of a target SDK plug-in corresponding to the fast application.
Step S230: and downloading and storing a target SDK plug-in corresponding to the fast application based on the parameter information.
After the parameter information of the fast application is obtained, the target SDK plug-in corresponding to the fast application can be downloaded and stored based on the parameter information, so that the downloading accuracy of the target SDK plug-in is improved. In this embodiment, the latest version of the SDK plug-in corresponding to the fast application may be downloaded and saved based on the parameter information, for example, if the protocol version number includes a protocol version number 1 and a protocol version number 2, and the protocol version number of the protocol version number 2 is greater than the protocol version number of the protocol version number 1, where the protocol version number is a version number of a jar packet of an interface specification defining the SDK plug-in.
As a first mode, if the first protocol version number is a protocol version number 2, the manufacturer server corresponding to the fast application preferentially searches for the SDK plug-in of the protocol version number 2, and if the protocol version number 2 is found to include the SDK plug-in, then searches for and acquires the SDK plug-in of the latest version from the protocol version number 2, and returns the SDK plug-in of the latest version to the mobile terminal as the target SDK plug-in; if the SDK plug-in with the protocol version number 2 is not found, for example, when the mobile terminal requests a target SDK plug-in from a server, if the protocol version number requested by the mobile terminal is the protocol version number 2, and the protocol version number used by a manufacturer server corresponding to the fast application is the protocol version number 1, the SDK plug-in representing the manufacturer server does not have the version with the protocol version number 2 (only the SDK protocol version with the protocol version number 1), then the SDK plug-in with the protocol version number 1 is found, if the protocol version number 1 is found to include the SDK plug-in, then the SDK plug-in with the latest version is found from the protocol version number 1, and the SDK plug-in with the latest version is returned to the mobile terminal to serve as the target SDK plug-in.
As a second way, if the first protocol version number is the protocol version number 1, then the vendor server corresponding to the fast application only searches for the SDK plugin of the protocol version number 1, and if the protocol version number 1 is found to include the SDK plugin, then searches for and obtains the SDK plugin of the latest version from the protocol version number 1, and returns the SDK plugin of the latest version to the mobile terminal as the target SDK plugin. Thus, in this embodiment, the SDK plug-in is downward compatible.
Referring to fig. 8, fig. 8 is a flowchart illustrating a step S230 of the loading method of the SDK plug-in shown in fig. 6 according to the present application. As will be explained in detail with respect to the flow shown in fig. 8, the method may specifically include the following steps:
step S231: and acquiring a manufacturer server corresponding to the fast application based on the brand information.
And obtaining the manufacturer server corresponding to the fast application based on the brand information in the parameter information. As a way, different fast applications correspond to different brand information, and different brand information corresponds to different vendor servers, so that the vendor server corresponding to the fast application can be obtained based on the brand information based on the correspondence between the fast application-brand information-vendor server.
For example, as shown in table 1, table 1 shows a correspondence between the fast application, the brand information, and the vendor server. Wherein the fast application is denoted by K, the brand information is denoted by P, and the vendor server is denoted by C.
TABLE 1
Quick application (K) Brand information (P) Manufacturer server (C)
K1 P1 C1
K2 P2 C2
K3 P3 C3
K4 P4 C4
...... ...... ......
If the fast application is K1, based on the correspondence between K1-P1-C1, it may be determined that the brand information corresponding to the fast application K1 is the brand P1, and the vendor server corresponding to the fast application K1 is the vendor server C1; if the fast application is K2, based on the correspondence between K2-P2-C2, it may be determined that the brand information corresponding to the fast application K2 is the brand P2, and the vendor server corresponding to the fast application K2 is the vendor server C2, and so on, which is not described herein again.
Step S232: and searching and storing the SDK plug-in of the latest version under the first protocol version number in the manufacturer server based on the first protocol version number.
Further, after the manufacturer server corresponding to the fast application is obtained based on the brand information in the parameter information, the SDK plug-in of the latest version under the first protocol version number may be searched for and stored in the manufacturer server based on the first protocol version number in the parameter information. For example, if the first protocol version number is the protocol version number 2, the SDK plug-in of the latest version of the protocol version number 2 is searched in the vendor server and stored; if the first protocol version number is the protocol version number 1, searching and storing the SDK plug-in of the latest version of the protocol version number 1 in the manufacturer server.
Referring to fig. 9, fig. 9 is a flowchart illustrating a step S232 of the loading method of the SDK plug-in shown in fig. 8 according to the present application. As will be explained in detail with respect to the flow shown in fig. 9, the method may specifically include the following steps:
step S2321: and judging whether the manufacturer server comprises the SDK plug-in under the first protocol version number.
As a way, after determining the vendor server corresponding to the fast application, it may be determined whether the vendor server includes the SDK plug-in under the first protocol version number. For example, if the first protocol version number is protocol version number 2, it may be determined whether the vendor server includes an SDK plug-in of protocol version number 2; if the first protocol version number is protocol version number 1, it can be determined whether the vendor server includes an SDK plug-in of protocol version number 1.
Step S2322: if the manufacturer server comprises the SDK plug-in under the first protocol version number, searching and storing the SDK plug-in of the latest version under the first protocol version number in the manufacturer server based on the first protocol version number.
If the judgment result indicates that the manufacturer server includes the SDK plug-in under the first protocol version number, the latest version of the SDK plug-in under the first protocol version number can be searched and stored in the manufacturer server. For example, if the first protocol version number is protocol version number 2 and the vendor server includes the SDK plug-in under the protocol version number 2, the latest version of the SDK plug-ins in all the SDK plug-ins under the protocol version number 2 may be searched in the vendor server, so as to obtain and store the latest version of the SDK plug-ins.
Step S2323: and if the manufacturer server does not comprise the SDK plug-in under the first protocol version number, acquiring a second protocol version number of the application program, wherein the second protocol version number is smaller than the first protocol version number.
If the determination result indicates that the vendor server does not include the SDK plugin under the first protocol version number, a second protocol version number of the application program may be obtained, where the second protocol version number is smaller than the first protocol version number, for example, if the first protocol version number is protocol version number 5 and the vendor server does not include the SDK plugin under the protocol version number 5, a second protocol version number may be selected from protocol version numbers that are smaller than the protocol version number 5, such as protocol version number 1, protocol version number 2, protocol version number 3, protocol version number 4, and the like, for example, protocol version number 4 is selected as the second protocol version number, and protocol version number 2 is selected as the second protocol version number, and the like.
By one approach, the second protocol version number is only smaller than the first protocol version number. For example, if the first protocol version number is protocol version number 5, then the second protocol version number is protocol version number 4; if the first protocol version number is protocol version number 4, then the second protocol version number is protocol version number 3, which is not described herein again.
Step S2324: and searching the SDK plug-in of the latest version under the second protocol version number in the manufacturer server based on the second protocol version number.
Further, after the second protocol version number is determined, the SDK plugin of the latest version under the second protocol version number may be searched in the vendor server, so as to improve the possibility that the mobile terminal acquires the SDK plugin of the latest version that can be operated, and improve user experience.
Step S240: and when a second starting instruction for the fast application is received, responding to the second starting instruction, and acquiring the target SDK plug-in from the local of the mobile terminal.
For a detailed description of step S240, please refer to step S130, which is not described herein again.
Step S250: and separating a target file from the target SDK plug-in and loading the target SDK plug-in.
In this embodiment, after the target SDK plugin is obtained locally from the mobile terminal, the target file in the SDK plugin can be separated, and the target SDK plugin is loaded, where the target file at least includes a configuration file and a so file, so as to ensure that the file is read quickly when the SDK plugin is used. As one way, the target SDK plug-in may be directly and dynamically loaded at the time of loading, but the so file in the target file still needs to be loaded separately, where the so file may be loaded using loadlibrary, and the configuration file may be read in the code at the time of loading.
Referring to fig. 10, fig. 10 is a flowchart illustrating a step S250 of the loading method of the SDK plug-in shown in fig. 6 of the present application. As will be explained in detail with respect to the flow shown in fig. 10, the method may specifically include the following steps:
step S251: and separating the target file from the target SDK plug-in and judging whether the target file is complete or not.
As an embodiment, after separating the target file from the target SDK plug-in, the mobile terminal may determine whether the target file is complete, for example, whether the configuration file and the so file are complete.
Step S252: and if the target file is complete, loading the target SDK plug-in.
As a way, if the judgment result indicates that the target file is complete, the target SDK file may be directly loaded.
As another way, if the determination result indicates that the target file is incomplete, file deletion may be caused and the target file cannot be used normally, and since the target files such as the configuration file and the so file are separated from the SDK plugin, the target file can be separated from the SDK plugin again, so that the target files such as the configuration file or the so file can be processed again when being damaged or deleted accidentally, and thus, errors can not be caused during loading, the loading safety of the SDK plugin and the integrity of the loaded SDK plugin can be ensured, and the loading speed can be ensured.
Step S260: and when the mobile terminal downloads the SDK plug-in to be loaded corresponding to the fast application, judging whether the application program is killed after the target SDK plug-in is loaded.
Further, if the mobile terminal downloads the target SDK again to the to-be-loaded SDK corresponding to the fast application after loading the target SDK, it may be determined whether the application is killed (kill) after loading the target SDK plug-in, that is, it may be determined whether the application completely exits after loading the target SDK plug-in.
Step S270: if the mobile terminal is not killed after the target SDK plug-in is loaded, the SDK plug-in to be loaded is saved, and the target SDK plug-in is reserved to continue to be used as the current SDK plug-in of the fast application.
If the judgment result indicates that the mobile terminal is not killed after the target SDK plug-in is loaded, as a way, the SDK plug-in to be loaded can be saved to be used as the next loaded SDK plug-in, and the target SDK plug-in is kept to continue to be used as the current SDK plug-in of the fast application, that is, even if the mobile terminal downloads the SDK plug-in to be loaded again, if the application program is not killed in the process from the loading of the target SDK plug-in to the downloading of the SDK plug-in to be loaded, other SDK plug-ins are not reloaded, and if the SDK plug-in to be loaded is not reloaded. Specifically, if the application program pulls up the excessively fast application and then exits and re-enters, but the fast application does not exit last time, the SDK plug-in can be loaded in the fast application, at this time, the local latest version of the SDK plug-in is loaded, and if the application program downloads the SDK plug-in to be loaded in the updated version again, the fast application continues to use the target SDK plug-in loaded before, unless the application program is killed and then re-enters, thereby ensuring that no multiple versions of the SDK plug-ins are loaded together.
In another embodiment of the application, in the method for loading the SDK plug-in, the mobile terminal receives a first start instruction for the application program, obtains the parameter information of the fast application when the first start instruction is responded and a specified download condition is satisfied, and downloads and stores the target SDK plug-in corresponding to the fast application based on the parameter information. And when a second starting instruction for the fast application is received, responding to the second starting instruction, acquiring the target SDK plug-in from the local of the mobile terminal, separating a target file from the target SDK plug-in and loading the target SDK plug-in. And when the mobile terminal downloads the SDK plug-in to be loaded corresponding to the fast application again, judging whether the application program is killed after the target SDK plug-in is loaded, if the mobile terminal is not killed after the target SDK plug-in is loaded, storing the SDK plug-in to be loaded, and keeping the target SDK plug-in to continue to serve as the current SDK plug-in of the fast application. Compared with the loading method of the SDK plug-in shown in fig. 5, the embodiment may download the SDK plug-in based on the parameter information of the fast application to improve the speed and accuracy of acquiring the SDK plug-in, and may further separate the target file from the target SDK plug-in and load the target file to improve the loading speed and the recording security of the target SDK plug-in.
Referring to fig. 11, fig. 11 is a schematic flowchart illustrating a loading method of an SDK plug-in according to still another embodiment of the present application. The method is applied to the mobile terminal, and as will be described in detail below with respect to the flow shown in fig. 11, the method for loading the SDK plug-in may specifically include the following steps:
step S310: the mobile terminal receives a first starting instruction aiming at the application program.
Step S320: and when the first starting instruction is responded and the specified downloading condition is met, acquiring the parameter information of the fast application.
Step S330: and downloading and storing a target SDK plug-in corresponding to the fast application based on the parameter information.
Step S340: and when a second starting instruction for the fast application is received, responding to the second starting instruction, and acquiring the target SDK plug-in from the local of the mobile terminal.
Step S350: and separating a target file from the target SDK plug-in and loading the target SDK plug-in.
For the detailed description of steps S310 to S350, please refer to steps S210 to S250, which are not described herein again.
Step S360: and when the mobile terminal downloads the SDK plug-in to be loaded corresponding to the fast application, judging whether the target SDK plug-in is deleted.
Further, if the mobile terminal downloads the target SDK plugin again after loading the target SDK plugin, it may be determined whether the target SDK plugin is deleted, that is, it may be detected whether the target SDK plugin is deleted from the memory of the mobile terminal.
Step S370: and if the target SDK plug-in is not deleted, storing the SDK plug-in to be loaded, and keeping the target SDK plug-in to continue to be used as the current SDK plug-in of the fast application.
If the judgment result indicates that the target SDK plugin is not deleted, as a way, the SDK plugin to be loaded may be saved as the next-time loaded SDK plugin, and the target SDK plugin is kept to continue to be the current SDK plugin of the fast application, that is, even if the mobile terminal downloads the target SDK plugin again, if the target SDK plugin is not deleted from the memory of the mobile terminal in the process from loading the target SDK plugin to downloading the SDK plugin to be loaded, other SDK plugins are not reloaded, and if the target SDK plugin is not reloaded, it is ensured that multiple versions of SDK plugins are not loaded together.
In another embodiment of the application, in the method for loading the SDK plug-in, the mobile terminal receives a first start instruction for the application program, obtains the parameter information of the fast application when the first start instruction is responded and a specified download condition is satisfied, and downloads and stores the target SDK plug-in corresponding to the fast application based on the parameter information. And when a second starting instruction for the fast application is received, responding to the second starting instruction, acquiring the target SDK plug-in from the local of the mobile terminal, separating a target file from the target SDK plug-in and loading the target SDK plug-in. And when the mobile terminal downloads the SDK plug-in to be loaded corresponding to the fast application again, judging whether the target SDK plug-in is deleted, if the target SDK plug-in is not deleted, storing the SDK plug-in to be loaded, and keeping the target SDK plug-in to continue to be used as the current SDK plug-in of the fast application. Compared with the loading method of the SDK plug-in shown in fig. 5, the embodiment may download the SDK plug-in based on the parameter information of the fast application to improve the speed and accuracy of acquiring the SDK plug-in, and may further separate the target file from the target SDK plug-in and load the target file to improve the loading speed and the recording security of the target SDK plug-in.
Referring to fig. 12, fig. 12 is a schematic flowchart illustrating a loading method of an SDK plug-in according to another embodiment of the present application. The method is applied to the mobile terminal, the mobile terminal is provided with an application program, a plurality of fast applications are added to the application program, the flow shown in fig. 12 will be described in detail below, and the loading method of the SDK plug-in specifically may include the following steps:
step S410: the mobile terminal receives a first starting instruction aiming at the application program.
For detailed description of step S410, please refer to step S110, which is not described herein again.
Step S420: and responding to the first starting instruction, starting the application program and displaying a home page of the application program.
As a mode, after receiving a first start instruction, the mobile terminal may start an application program in response to the first start instruction, and enter and display a home page of the application program.
Step S430: and acquiring the equipment information displayed on the home page, and acquiring the target fast application corresponding to the equipment information.
Further, the top page of the application may display device information of a plurality of devices, and the device information may be displayed in a text form, for example, the top page of the application displays "XX air conditioner", "XX refrigerator", "XX television", and the like, where "XX" may represent a brand; the device information may be displayed in the form of a picture, for example, a top page of the application displays a picture including XX air-conditioning texts, displays a picture including XX refrigerator texts, displays a picture including XX tv texts, and the like, and for example, a top page of the application displays a control including XX air-conditioning texts, displays a control including XX refrigerator texts, displays a control including XX tv texts, and the like, which is not limited herein. As one mode, the display content of the home page of the application program may be identified, for example, a picture displayed on the home page of the mobile terminal, characters displayed on the home page, and a control displayed on the home page may be identified, so as to obtain the device information displayed on the home page of the application program.
In addition, after the device information is acquired, the target fast application corresponding to the device information can be acquired according to the device information. As one way, a correspondence between the fast application and the device information may be established, so as to determine the fast application corresponding to the device identifier according to the device identifier. As a manner, the correspondence between the fast application and the device information may be stored in the mobile terminal for installing the application program in a form of a list, where each device information corresponds to one fast application, or multiple device information corresponds to one fast application.
Step S440: and preferentially downloading and storing a target SDK plug-in corresponding to a target fast application in the plurality of fast applications.
Further, since the device information corresponding to the target fast application is displayed on the top page of the application program, the possibility that the control corresponding to the device information is selected by the user is the greatest, and therefore, in order to ensure that the SDK plug-in corresponding to the target fast application corresponding to the device information is downloaded when the user selects the control corresponding to the device information, user experience is improved, and the target SDK plug-in corresponding to the target fast application in the plurality of fast applications can be downloaded preferentially and stored.
As a mode, the mobile terminal may respectively download the target SDK plug-in corresponding to each of the plurality of fast applications, and store the target SDK plug-in corresponding to each fast application in different storage areas, so that different directories stored in SDK plug-ins of different brands, different protocol versions, and different protocol version numbers are different, and the downloading and the loading do not interfere with each other.
Step S450: and when a second starting instruction for the target fast application is received, responding to the second starting instruction to load the target SDK plug-in corresponding to the target fast application from the local of the mobile terminal, and continuously downloading the target SDK plug-ins corresponding to other fast applications except the target fast application in the plurality of fast applications.
Further, when the mobile terminal responds to the second starting instruction to load the target SDK plug-in corresponding to the target fast application, the target SDK plug-ins corresponding to other fast applications except the target fast application in the plurality of fast applications can be continuously downloaded, so that the downloading of the SDK plug-ins does not affect the normal use of the user, and the user experience is improved.
In another embodiment of the application, a mobile terminal receives a first start instruction for an application program, responds to the first start instruction, starts the application program and displays a home page of the application program, acquires device information displayed on the home page, acquires a target fast application corresponding to the device information, preferentially downloads and stores a target SDK plugin corresponding to a target fast application in a plurality of fast applications, and when a second start instruction for the target fast application is received, responds to the second start instruction to locally load the target SDK plugin corresponding to the target fast application from the mobile terminal, and continues to download target SDK plugins corresponding to other fast applications except the target fast application in the plurality of fast applications. Compared with the loading method of the SDK plug-in shown in fig. 5, the present embodiment also preferentially records the target SDK plug-in of the fast application corresponding to the device information displayed by the application program, so as to improve user experience.
Referring to fig. 13, fig. 13 is a schematic flowchart illustrating a loading method of an SDK plug-in according to yet another embodiment of the present application. The method is applied to the mobile terminal, the mobile terminal is provided with an application program, a plurality of fast applications are added to the application program, the flow shown in fig. 13 will be described in detail below, and the loading method of the SDK plug-in specifically may include the following steps:
step S510: the mobile terminal receives a first starting instruction aiming at the application program.
For detailed description of step S510, please refer to step S110, which is not described herein again.
Step S520: and responding to the first starting instruction, acquiring the current SDK plug-in of the fast application and identifying the current version of the current SDK plug-in.
As a mode, when receiving a first start instruction, the mobile terminal may respond to the first start instruction to obtain a current SDK plugin of the fast application, and identify a current version of the current SDK plugin.
Step S530: and judging whether the current version is the latest version.
Further, after the current version of the current SDK plug-in of the fast application is obtained, it may be determined whether the current version is the latest version. As an implementation manner, the version number of the current version and the version number of the latest version may be respectively obtained, whether the version number of the current version is identical to the version number of the latest version is compared, if the version number of the current version is identical to the version number of the latest version, the current version may be determined to be the latest version, and if the version number of the current version is not identical to the version number of the latest version, the current version may be determined not to be the latest version.
Step S540: and if the current version is not the latest version, downloading and storing the SDK plug-in of the latest version corresponding to the quick application.
As a mode, if the judgment result indicates that the current version is not the latest version, the SDK plug-in of the latest version corresponding to the fast application can be downloaded and stored to ensure that the SDK plug-in loaded by the fast application is the latest version; as another mode, if the determination result indicates that the current version is the latest version, the SDK plug-in may not be downloaded, so as to reduce the power consumption of the mobile terminal.
Step S550: and responding to the second starting instruction, and detecting whether the mobile terminal is configured with an original SDK plug-in corresponding to the fast application.
In this embodiment, when receiving the second start instruction, the mobile terminal may detect whether the mobile terminal is configured with the original SDK plug-in corresponding to the fast application in response to the second start instruction, that is, may detect whether the mobile terminal is loaded with the original SDK plug-in corresponding to the fast application in response to the second start instruction.
Step S560: and if the mobile terminal is configured with the original SDK plug-in corresponding to the fast application, forcibly updating the original SDK plug-in to the target SDK plug-in.
As a manner, if the detection result indicates that the mobile terminal is configured with the original SDK plugin corresponding to the fast application, the original SDK plugin may be forcibly updated to the target SDK plugin, so as to ensure that the version of the SDK plugin loaded by the mobile terminal is the latest version.
Step S570: and if the mobile terminal is configured with the original SDK plug-in corresponding to the fast application, outputting prompt information, wherein a prompt information user prompts the user to select whether to update the original SDK plug-in to the target SDK plug-in.
As another mode, if the detection result indicates that the mobile terminal is configured with the original SDK plugin corresponding to the fast application, a prompt message may be output to intentionally prompt the user to select whether to update the original SDK plugin to the target SDK plugin, so as to improve user experience.
In another embodiment of the present application, in a method for loading an SDK plugin, a mobile terminal receives a first start instruction for an application program, responds to the first start instruction, obtains a current SDK plugin for a fast application, identifies a current version of the current SDK plugin, determines whether the current version is a latest version, and if the current version is not the latest version, downloading and storing the latest version of the SDK plug-in corresponding to the fast application, responding to the second starting instruction, detecting whether the mobile terminal is configured with the original SDK plug-in corresponding to the fast application, if the mobile terminal is configured with the original SDK plug-in corresponding to the fast application, forcibly updating the original SDK plug-in to the target SDK plug-in, or if the mobile terminal is configured with an original SDK plug-in corresponding to the fast application, outputting a prompt message, the prompt message is used for prompting the user to select whether to update the original SDK plug-in to the target SDK plug-in. Compared with the loading method of the SDK plug-in shown in fig. 5, in this embodiment, when the current SDK plug-in version of the fast application is not the latest version, the target SDK plug-in is downloaded again, so that the power consumption of the mobile terminal is reduced.
Referring to fig. 14, fig. 14 is a block diagram illustrating a module of a loading apparatus 500 for an SDK plug-in according to an embodiment of the present application. The loading device 500 of the SDK plug-in is applied to the mobile terminal, and the mobile terminal is installed with an application program, and a fast application is added to the application program. As will be explained below with respect to the block diagram shown in fig. 14, the loading apparatus 500 of the SDK plug-in includes: an instruction receiving module 510, an SDK plug-in downloading module 520, and an SDK plug-in loading module 530, wherein:
an instruction receiving module 510, configured to receive, by the mobile terminal, a first start instruction for the application program.
And the SDK plug-in downloading module 520 is configured to, when the first start instruction is responded and the specified downloading condition is met, download and store the target software development kit SDK plug-in corresponding to the fast application. Further, the SDK plug-in download module 520 includes: the device comprises a parameter information acquisition submodule and a first SDK plug-in downloading submodule, wherein:
and the parameter information acquisition submodule is used for acquiring the parameter information of the fast application. Further, the parameter information obtaining sub-module includes: brand information acquisition unit, first protocol version number acquisition unit and parameter information acquisition unit, wherein:
and the brand information acquisition unit is used for acquiring the brand information corresponding to the quick application.
A first protocol version number obtaining unit, configured to obtain a first protocol version number of the application program, where the first protocol version number is used to represent a maximum version of protocol version numbers supported by the application program.
A parameter information obtaining unit, configured to generate parameter information of the fast application based on the brand information and the first protocol version number.
And the first SDK plug-in downloading submodule is used for downloading and storing the target SDK plug-in corresponding to the fast application based on the parameter information. Further, the SDK plug-in download sub-module includes: the vendor server obtains the unit and SDK plug-in unit, wherein:
and the manufacturer server acquisition unit is used for acquiring a manufacturer server corresponding to the fast application based on the brand information.
And the SDK plug-in searching unit is used for searching and storing the SDK plug-in of the latest version under the first protocol version number in the manufacturer server based on the first protocol version number. Further, the SDK plug-in lookup unit includes: the judging subunit, the first SDK plug-in searching subunit, the second protocol version number obtaining subunit and the second SDK plug-in searching subunit are provided, wherein:
and the judging subunit is used for judging whether the manufacturer server comprises the SDK plug-in under the first protocol version number.
And the first SDK plug-in searching subunit is configured to search and store the SDK plug-in of the latest version under the first protocol version number in the vendor server based on the first protocol version number if the vendor server includes the SDK plug-in under the first protocol version number.
A second protocol version number obtaining subunit, configured to obtain a second protocol version number of the application program if the vendor server does not include the SDK plug-in under the first protocol version number, where the second protocol version number is smaller than the first protocol version number.
And the second SDK plug-in searching subunit is used for searching the SDK plug-in of the latest version under the second protocol version number in the manufacturer server based on the second protocol version number.
Further, a plurality of fast applications are added to the application program, and the SDK plug-in download module 420 further includes: a second target SDK plug-in downloading submodule, a target SDK plug-in storage submodule, a home page display submodule, a target fast application acquisition submodule and a priority downloading submodule, wherein:
and the second target SDK plug-in downloading submodule is used for respectively downloading the target SDK plug-ins corresponding to each of the plurality of fast applications.
And the target SDK plug-in storage submodule is used for storing the target SDK plug-ins corresponding to each fast application in different storage areas.
And the display submodule is used for responding to the first starting instruction, starting the application program and displaying a home page of the application program.
And the target fast application acquisition submodule is used for acquiring the equipment information displayed on the home page and acquiring the target fast application corresponding to the equipment information.
And the priority downloading submodule is used for downloading and storing the target SDK plug-in corresponding to the target fast application in the plurality of fast applications in priority.
Further, the SDK plug-in downloading module 520 further includes: the current version acquisition submodule, the current version judgment submodule and the third target SDK plug-in downloading submodule, wherein:
and the current version obtaining sub-module is used for responding to the first starting instruction, obtaining the current SDK plug-in of the fast application and identifying the current version of the current SDK plug-in.
And the current version judgment sub-module is used for judging whether the current version is the latest version.
And the third target SDK plug-in downloading submodule is used for downloading and storing the SDK plug-in of the latest version corresponding to the quick application if the current version is not the latest version.
An SDK plugin loading module 530, configured to, when receiving a second start instruction for the fast application, respond to the second start instruction to load the target SDK plugin from the local of the mobile terminal. Further, the SDK plug-in loading module 530 includes: the SDK plug-in unit obtaining submodule and the first SDK plug-in unit loading submodule, wherein:
and the SDK plug-in acquisition sub-module is used for responding to the second starting instruction and acquiring the target SDK plug-in from the local of the mobile terminal.
And the first SDK plug-in loading submodule is used for separating a target file from the target SDK plug-in and loading the target SDK plug-in. Further, the SDK plug-in loading sub-module includes: the device comprises a target file separating unit and an SDK plug-in loading unit, wherein:
and the target file separating unit is used for separating the target file from the target SDK plug-in and judging whether the target file is complete or not.
And the SDK plug-in loading unit is used for loading the target SDK plug-in if the target file is complete.
Further, the SDK plug-in loading module 530 includes: a second SDK plug-in loads a sub-module, wherein:
and the second SDK plug-in loading submodule is used for responding to a second starting instruction to load the target SDK plug-in corresponding to the target fast application from the local of the mobile terminal when the second starting instruction aiming at the target fast application is received, and continuously downloading the target SDK plug-ins corresponding to other fast applications except the target fast application in the plurality of fast applications.
Further, the SDK plug-in loading module 530 includes: the system comprises an original SDK plug-in detection submodule, a forced update module and a prompt message output submodule, wherein:
and the original SDK plug-in detection submodule is used for responding to the second starting instruction and detecting whether the mobile terminal is configured with the original SDK plug-in corresponding to the fast application.
And the forced updating sub-module is used for forcibly updating the original SDK plug-in to the target SDK plug-in if the mobile terminal is configured with the original SDK plug-in corresponding to the fast application.
And the prompt information output sub-module is used for outputting prompt information if the mobile terminal is configured with an original SDK plug-in corresponding to the fast application, wherein the prompt information user prompts the user to select whether to update the original SDK plug-in to the target SDK plug-in.
Further, the SDK plug-in loading apparatus 500 further includes: first judging module, first reservation module, second judging module and second reservation module, wherein:
and the first judgment module is used for judging whether the application program is killed after the target SDK plug-in is loaded when the mobile terminal downloads the SDK plug-in to be loaded corresponding to the fast application.
And the first retention module is used for storing the SDK plug-in to be loaded and retaining the target SDK plug-in to continue to serve as the current SDK plug-in of the fast application if the mobile terminal is not killed after the target SDK plug-in is loaded.
And the second judging module is used for judging whether the target SDK plug-in is deleted or not when the mobile terminal downloads the SDK plug-in to be loaded corresponding to the fast application.
And the second reserving module is used for saving the SDK plug-in to be loaded and reserving the target SDK plug-in to continue to be used as the current SDK plug-in of the fast application if the target SDK plug-in is not deleted.
It can be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described apparatuses and modules may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, the coupling between the modules may be electrical, mechanical or other type of coupling.
In addition, functional modules in the embodiments of the present application may be integrated into one processing module, or each of the modules may exist alone physically, or two or more modules are integrated into one module. The integrated module can be realized in a hardware mode, and can also be realized in a software functional module mode.
Referring to fig. 15, a block diagram of a mobile terminal 100 according to an embodiment of the present disclosure is shown. The mobile terminal 100 may be a smart phone, a tablet computer, an electronic book, or other electronic devices capable of running an application program. The mobile terminal 100 in the present application may include one or more of the following components: a processor 110, a memory 120, a screen 130, a codec 140, and one or more applications, wherein the one or more applications may be stored in the memory 120 and configured to be executed by the one or more processors 110, the one or more programs configured to perform the method as described in the aforementioned method embodiments.
Processor 110 may include one or more processing cores, among other things. The processor 110 interfaces with various components throughout the mobile terminal 100 using various interfaces and lines, and performs various functions of the mobile terminal 100 and processes data by executing or executing instructions, programs, code sets, or instruction sets stored in the memory 120 and invoking data stored in the memory 120. Alternatively, the processor 110 may be implemented in hardware using at least one of Digital Signal Processing (DSP), Field-Programmable Gate Array (FPGA), and Programmable Logic Array (PLA). The processor 110 may integrate one or more of a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), a modem, and the like. Wherein, the CPU mainly processes an operating system, a user interface, an application program and the like; the GPU is used for rendering and drawing display content; the modem is used to handle wireless communications. It is understood that the modem may not be integrated into the processor 110, but may be implemented by a communication chip.
The Memory 120 may include a Random Access Memory (RAM) or a Read-Only Memory (Read-Only Memory). The memory 120 may be used to store instructions, programs, code sets, or instruction sets. The memory 120 may include a stored program area and a stored data area, wherein the stored program area may store instructions for implementing an operating system, instructions for implementing at least one function (such as a touch function, a sound playing function, an image playing function, etc.), instructions for implementing various method embodiments described below, and the like. The storage data area may also store data created by the terminal 100 in use, such as a phonebook, audio-video data, chat log data, and the like.
Referring to fig. 16, a block diagram of a computer-readable storage medium according to an embodiment of the present application is shown. The computer-readable medium 600 has stored therein program code that can be called by a processor to perform the method described in the above-described method embodiments.
The computer-readable storage medium 600 may be an electronic memory such as a flash memory, an EEPROM (electrically erasable programmable read only memory), an EPROM, a hard disk, or a ROM. Alternatively, the computer-readable storage medium 600 includes a non-volatile computer-readable storage medium. The computer readable storage medium 600 has storage space for program code 610 for performing any of the method steps of the method described above. The program code can be read from or written to one or more computer program products. The program code 610 may be compressed, for example, in a suitable form.
To sum up, according to the loading method and apparatus for the SDK plug-in, the mobile terminal and the storage medium provided in the embodiments of the present application, the mobile terminal receives a first start instruction for the application program, downloads and stores a target SDK plug-in corresponding to the fast application when the first start instruction is responded and a specified download condition is satisfied, and loads the target SDK plug-in from a local of the mobile terminal in response to a second start instruction for the fast application when the second start instruction for the fast application is received, so that the SDK plug-in is optimized and managed conveniently by separating downloading and loading the SDK plug-in.
Finally, it should be noted that: the above embodiments are only used to illustrate the technical solutions of the present application, and not to limit the same; although the present application has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; such modifications and substitutions do not necessarily depart from the spirit and scope of the corresponding technical solutions in the embodiments of the present application.

Claims (20)

  1. A loading method of an SDK plug-in is characterized by being applied to a mobile terminal, wherein an application program is installed in the mobile terminal, and a fast application is added in the application program, and the method comprises the following steps:
    the mobile terminal receives a first starting instruction aiming at the application program;
    when the first starting instruction is responded and the specified downloading condition is met, downloading and storing a target Software Development Kit (SDK) plug-in corresponding to the fast application;
    and when a second starting instruction for the fast application is received, the target SDK plug-in is loaded from the local of the mobile terminal in response to the second starting instruction.
  2. The method of claim 1, wherein downloading and saving the target SDK plug-in corresponding to the fast application comprises:
    acquiring parameter information of the fast application;
    and downloading and storing a target SDK plug-in corresponding to the fast application based on the parameter information.
  3. The method of claim 2, wherein the obtaining the parameter information of the fast application comprises:
    acquiring brand information corresponding to the fast application;
    acquiring a first protocol version number of the application program, wherein the first protocol version number is used for representing the maximum version in the protocol version numbers supported by the application program;
    generating parameter information of the fast application based on the brand information and the first protocol version number.
  4. The method of claim 3, wherein downloading and saving the target SDK plug-in corresponding to the fast application based on the parameter information comprises:
    obtaining a manufacturer server corresponding to the fast application based on the brand information;
    and searching and storing the SDK plug-in of the latest version under the first protocol version number in the manufacturer server based on the first protocol version number.
  5. The method of claim 4, wherein the finding and saving in the vendor server of the latest version of the SDK plug-in under the first protocol version number based on the first protocol version number comprises:
    judging whether the manufacturer server comprises an SDK plug-in under the first protocol version number;
    if the manufacturer server comprises the SDK plug-in under the first protocol version number, searching and storing the SDK plug-in of the latest version under the first protocol version number in the manufacturer server based on the first protocol version number.
  6. The method of claim 5, further comprising:
    if the manufacturer server does not comprise the SDK plug-in under the first protocol version number, acquiring a second protocol version number of the application program, wherein the second protocol version number is smaller than the first protocol version number;
    and searching the SDK plug-in of the latest version under the second protocol version number in the manufacturer server based on the second protocol version number.
  7. The method of claim 6, wherein the second protocol version number is only smaller than the first protocol version number.
  8. The method of any of claims 1-7, wherein the loading the target SDK plugin from local to the mobile terminal in response to the second initiation instruction comprises:
    responding to the second starting instruction, and acquiring the target SDK plug-in from the local of the mobile terminal;
    and separating a target file from the target SDK plug-in and loading the target SDK plug-in.
  9. The method of claim 8, wherein detaching the target file from the target SDK plug-in and loading the target SDK plug-in comprises:
    separating the target file from the target SDK plug-in and judging whether the target file is complete or not;
    and if the target file is complete, loading the target SDK plug-in.
  10. The method according to claim 8 or 9, wherein the object files comprise at least a configuration file and a so file.
  11. The method of any of claims 1-10, further comprising, after loading the target SDK plug-in from local to the mobile terminal in response to the second boot instruction:
    when the mobile terminal downloads the SDK plug-in to be loaded corresponding to the fast application, judging whether the application program is killed after the target SDK plug-in is loaded;
    if the mobile terminal is not killed after the target SDK plug-in is loaded, the SDK plug-in to be loaded is saved, and the target SDK plug-in is reserved to continue to be used as the current SDK plug-in of the fast application.
  12. The method according to any of claims 1-10, further comprising, after loading the target SDK plug-in from local to the mobile terminal in response to the second boot instruction:
    when the mobile terminal downloads the SDK plug-in to be loaded corresponding to the fast application, judging whether the target SDK plug-in is deleted;
    and if the target SDK plug-in is not deleted, storing the SDK plug-in to be loaded, and keeping the target SDK plug-in to continue to be used as the current SDK plug-in of the fast application.
  13. The method according to any one of claims 1 to 12, wherein a plurality of fast applications are added to the application program, and the downloading and saving of the target SDK plug-in corresponding to the fast applications comprises:
    downloading a target SDK plug-in corresponding to each of the plurality of fast applications respectively;
    and storing the target SDK plug-in corresponding to each fast application in different storage areas.
  14. The method of claim 13, wherein after the mobile terminal receives the first start instruction for the application program, the method further comprises:
    responding to the first starting instruction, starting the application program and displaying a home page of the application program;
    acquiring the equipment information displayed on the home page, and acquiring a target fast application corresponding to the equipment information;
    and preferentially downloading and storing a target SDK plug-in corresponding to a target fast application in the plurality of fast applications.
  15. The method of claim 14, wherein when receiving a second start instruction for the fast application, loading the target SDK plug-in from the local of the mobile terminal in response to the second start instruction comprises:
    and when a second starting instruction for the target fast application is received, responding to the second starting instruction to load the target SDK plug-in corresponding to the target fast application from the local of the mobile terminal, and continuously downloading the target SDK plug-ins corresponding to other fast applications except the target fast application in the plurality of fast applications.
  16. The method according to any one of claims 1-15, wherein downloading and saving the target SDK plug-in corresponding to the fast application when responding to the first start instruction and satisfying a specified download condition comprises:
    responding to the first starting instruction, acquiring a current SDK plug-in of the fast application and identifying a current version of the current SDK plug-in;
    judging whether the current version is the latest version;
    and if the current version is not the latest version, downloading and storing the SDK plug-in of the latest version corresponding to the quick application.
  17. The method of any of claims 1-16, wherein the loading the target SDK plugin from local to the mobile terminal in response to the second initiation instruction comprises:
    responding to the second starting instruction, and detecting whether the mobile terminal is configured with an original SDK plug-in corresponding to the fast application;
    if the mobile terminal is configured with an original SDK plug-in corresponding to the fast application, forcibly updating the original SDK plug-in to the target SDK plug-in; or
    And if the mobile terminal is configured with the original SDK plug-in corresponding to the fast application, outputting prompt information, wherein a prompt information user prompts the user to select whether to update the original SDK plug-in to the target SDK plug-in.
  18. The loading device of the SDK plug-in is characterized by being applied to a mobile terminal, wherein the mobile terminal is provided with an application program, and a fast application is added into the application program, and the device comprises:
    the instruction receiving module is used for receiving a first starting instruction aiming at the application program by the mobile terminal;
    the SDK plug-in downloading module is used for downloading and storing the target software development kit SDK plug-in corresponding to the fast application when responding to the first starting instruction and meeting the specified downloading condition;
    and the SDK plug-in loading module is used for responding to a second starting instruction to load the target SDK plug-in from the local of the mobile terminal when the second starting instruction aiming at the fast application is received.
  19. A mobile terminal comprising a memory and a processor, the memory coupled to the processor, the memory storing instructions that, when executed by the processor, the processor performs the method of any of claims 1-17.
  20. A computer-readable storage medium having program code stored therein, the program code being invoked by a processor to perform the method of any one of claims 1 to 17.
CN201980091635.8A 2019-05-16 2019-05-16 SDK plug-in loading method and device, mobile terminal and storage medium Pending CN113412468A (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2019/087298 WO2020228033A1 (en) 2019-05-16 2019-05-16 Sdk plug-in loading method and apparatus, and mobile terminal and storage medium

Publications (1)

Publication Number Publication Date
CN113412468A true CN113412468A (en) 2021-09-17

Family

ID=73289126

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201980091635.8A Pending CN113412468A (en) 2019-05-16 2019-05-16 SDK plug-in loading method and device, mobile terminal and storage medium

Country Status (2)

Country Link
CN (1) CN113412468A (en)
WO (1) WO2020228033A1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113590179B (en) * 2021-08-02 2024-03-12 上海米哈游璃月科技有限公司 Plug-in detection method and device, electronic equipment and storage medium
CN114363990B (en) * 2021-12-28 2024-01-12 上海黑眸智能科技有限责任公司 Equipment end network distribution method and system compatible with multiple APP, equipment end and APP end

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050097133A1 (en) * 2003-10-31 2005-05-05 Quoc Pham Producing software distribution kit (SDK) volumes
CN103677877A (en) * 2012-09-12 2014-03-26 腾讯科技(深圳)有限公司 Method and device for updating local advertisement software development kit
US20160110987A1 (en) * 2014-10-21 2016-04-21 Anytransactions, Inc. Personal monitor and tracking system
CN106843978A (en) * 2017-01-23 2017-06-13 北京乐盟互动科技有限公司 A kind of SDK cut-in methods and system
CN107122200A (en) * 2016-02-25 2017-09-01 博雅网络游戏开发(深圳)有限公司 Load plug-in unit SDK method, system and client
US20170269921A1 (en) * 2016-03-18 2017-09-21 TUPL, Inc. Continuous and automatic application development and deployment
CN108366127A (en) * 2018-03-07 2018-08-03 北京奇艺世纪科技有限公司 A kind of acquisition methods and device of software package
CN108958074A (en) * 2018-06-20 2018-12-07 维沃移动通信有限公司 A kind of smart machine control method and mobile terminal
CN109271239A (en) * 2018-08-10 2019-01-25 北京达佳互联信息技术有限公司 Method, apparatus, system, equipment and the medium of data processing
CN109324970A (en) * 2018-09-28 2019-02-12 平安普惠企业管理有限公司 SDK running environment detection method, device, computer equipment and storage medium

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103560902A (en) * 2013-10-10 2014-02-05 中兴通讯股份有限公司 Server, intelligent terminal and remote management method of intelligent terminal
CN108563460A (en) * 2018-03-14 2018-09-21 广东能龙教育股份有限公司 Plug-in-based android application new function release method

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050097133A1 (en) * 2003-10-31 2005-05-05 Quoc Pham Producing software distribution kit (SDK) volumes
CN103677877A (en) * 2012-09-12 2014-03-26 腾讯科技(深圳)有限公司 Method and device for updating local advertisement software development kit
US20160110987A1 (en) * 2014-10-21 2016-04-21 Anytransactions, Inc. Personal monitor and tracking system
CN107122200A (en) * 2016-02-25 2017-09-01 博雅网络游戏开发(深圳)有限公司 Load plug-in unit SDK method, system and client
US20170269921A1 (en) * 2016-03-18 2017-09-21 TUPL, Inc. Continuous and automatic application development and deployment
CN106843978A (en) * 2017-01-23 2017-06-13 北京乐盟互动科技有限公司 A kind of SDK cut-in methods and system
CN108366127A (en) * 2018-03-07 2018-08-03 北京奇艺世纪科技有限公司 A kind of acquisition methods and device of software package
CN108958074A (en) * 2018-06-20 2018-12-07 维沃移动通信有限公司 A kind of smart machine control method and mobile terminal
CN109271239A (en) * 2018-08-10 2019-01-25 北京达佳互联信息技术有限公司 Method, apparatus, system, equipment and the medium of data processing
CN109324970A (en) * 2018-09-28 2019-02-12 平安普惠企业管理有限公司 SDK running environment detection method, device, computer equipment and storage medium

Also Published As

Publication number Publication date
WO2020228033A1 (en) 2020-11-19

Similar Documents

Publication Publication Date Title
CN113412469A (en) Equipment network distribution method and device, electronic equipment and storage medium
CN113412457B (en) Scene pushing method, device and system, electronic equipment and storage medium
CN107734616B (en) Application program closing method and device, storage medium and electronic equipment
CN113348725B (en) Device operation method, device, gateway, electronic device and computer readable medium
US11782590B2 (en) Scene-operation method, electronic device, and non-transitory computer readable medium
CN108737869B (en) Smart television starting processing method based on human body induction and smart television system
CN113330724A (en) Intelligent home scheduling method, device, system, server and storage medium
CN102984209B (en) A kind of distribution method of application program and terminal thereof
CN113498594B (en) Control method and device of smart home system, electronic equipment and storage medium
CN110687820B (en) Control method and device of intelligent household equipment, terminal equipment and storage medium
WO2020168568A1 (en) Data processing method and apparatus, electronic device and readable storage medium
CN109725543B (en) Equipment control code configuration method and device, cloud server and network system
CN112332997B (en) Distribution network method of terminal equipment, terminal equipment and computer readable storage medium
CN112714426B (en) Intelligent upgrading method and device of Bluetooth equipment, electronic equipment and medium
CN114565070B (en) Label binding method and device and mobile terminal
CN113412468A (en) SDK plug-in loading method and device, mobile terminal and storage medium
CN112230943A (en) Application processing method and device and electronic equipment
CN113615141A (en) Account number association method, device, system, server and storage medium
CN111479250A (en) File sharing method, device and system and terminal equipment
EP2664988A1 (en) Method, device and system for installing terminal software
CN110795172A (en) Foreground process control method and device, electronic equipment and storage medium
KR102506155B1 (en) Electronic device, application executing system and control methods thereof
CN106817370B (en) Method and device for transmitting network data
CN110941484B (en) Application program calling method and device
CN108322812B (en) Multi-screen interaction method and device and terminal

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination