技术领域Technical Field
本申请涉及计算机技术领域,具体涉及一种应用程序快速启动方法及装置。The present application relates to the field of computer technology, and in particular to a method and device for quickly starting an application program.
背景技术Background Art
随着物联网技术的发展,越来越多的智能化设备出现在人们的日常生活当中,例如智能电视、智能空调、智能火灾报警器等等,智能家居产品接入网络后用户可对其实现智能控制,目前用户可以通过在终端中安装应用程序来实现对其的智能控制,例如远程监控、以及查看智能设备的相关信息等。With the development of Internet of Things technology, more and more intelligent devices are appearing in people's daily lives, such as smart TVs, smart air conditioners, smart fire alarms, etc. After smart home products are connected to the network, users can realize intelligent control over them. Currently, users can realize intelligent control over them by installing applications in the terminal, such as remote monitoring and viewing relevant information of smart devices.
应用程序在使用时,先检测用户的登录状态,确定登录成功后再获取智能设备的信息,在登录失败和获取信息失败时,应用程序会自动返回至登录界面,目前的应用程序在获取信息时花费的时间较长,且获取信息失败至返回到登录界面花费的时间也较长。When the application is in use, it first detects the user's login status, and then obtains information from the smart device after confirming that the login is successful. When the login fails or the information acquisition fails, the application will automatically return to the login interface. The current application takes a long time to obtain information, and the time it takes from failing to obtain information to returning to the login interface is also long.
发明内容Summary of the invention
为了克服上述现有技术的缺陷,本申请提供了一种应用程序快速启动方法及装置。In order to overcome the above-mentioned defects of the prior art, the present application provides a method and device for quickly starting an application.
具体技术方案如下所示:The specific technical solutions are as follows:
一种应用程序快速启动方法,包括:A method for quickly launching an application, comprising:
步骤A、基于用户指令启动应用程序;Step A: starting the application based on user instructions;
步骤B、确定从应用程序启动至进入应用程序首页过程中的多个存在先后次序的任务;Step B, determining a plurality of tasks in a sequential order from application startup to entering the application homepage;
步骤C、确定当前需执行的任务,若当前需执行的任务的子任务数量为多个,则调用与所述子任务数量相同的多个线程同时处理多个所述子任务;每个线程对应处理一不同的所述子任务;Step C, determining the task to be executed currently, if the task to be executed currently has multiple subtasks, calling multiple threads with the same number of subtasks to process the multiple subtasks simultaneously; each thread processes a different subtask;
步骤D、若所有子任务均执行成功,则基于所述先后次序将当前执行成功任务的下一任务作为当前需执行的任务,并执行步骤C;若存在任何一子任务执行失败,则将所述先后次序中排序第一的任务作为当前需执行的任务,并执行步骤C;Step D: If all subtasks are successfully executed, the next task of the currently successfully executed task is used as the current task to be executed based on the order, and step C is executed; if any subtask fails to be executed, the task ranked first in the order is used as the current task to be executed, and step C is executed;
步骤E、当所述先后次序中排序倒数第一的任务执行成功,则进入应用程序首页。Step E: When the last task in the order is successfully executed, the application homepage is entered.
在一个实施例中,所述多个存在先后次序的任务包括第一任务、第二任务和第三任务;In one embodiment, the plurality of tasks in a sequential order include a first task, a second task, and a third task;
所述第一任务包括获取用户信息数据的子任务;The first task includes a subtask of obtaining user information data;
所述第二任务包括获取应用信息数据的子任务和获取家庭信息数据的子任务;The second task includes a subtask of obtaining application information data and a subtask of obtaining family information data;
所述第三任务包括获取应用背景信息数据的子任务、获取家庭房间信息数据的子任务、获取家庭场景信息数据的子任务和获取家庭设备信息数据的子任务。The third task includes a subtask of obtaining application background information data, a subtask of obtaining home room information data, a subtask of obtaining home scene information data, and a subtask of obtaining home device information data.
在一个实施例中,所述步骤C还包括:In one embodiment, the step C further comprises:
若当前需执行的任务的子任务数量为一个,则直接执行所述子任务。If the number of subtasks of the task currently to be executed is one, the subtask is directly executed.
在一个实施例中,所述步骤D还包括:In one embodiment, the step D further comprises:
监测自执行所述先后次序中排序第一的任务起所花费的执行时长,当所述执行时长超过预设时长,将所述先后次序中排序第一的任务作为当前需执行的任务,并执行步骤C。Monitor the execution time taken since the execution of the task ranked first in the sequence. When the execution time exceeds a preset time, take the task ranked first in the sequence as the current task to be executed, and execute step C.
在一个实施例中,通过user或getUser I nfo接口获取所述用户信息数据。In one embodiment, the user information data is obtained through the user or getUserInfo interface.
在一个实施例中,通过devi ce、product或f i ndA l lAccessoryProduc t接口获取所述应用信息数据;In one embodiment, the application information data is obtained through a device, product, or findAllAccessoryProduc t interface;
和/或,通过user、home或f i ndA l l接口获取所述家庭信息数据。And/or, obtaining the home information data through a user, home or findA l l interface.
在一个实施例中,通过assets、f i l e或f i ndByCode接口获取所述应用背景信息数据;In one embodiment, the application context information data is obtained through assets, file or findByCode interface;
和/或,通过user、room或f i ndRoomLi st接口获取所述家庭房间信息数据;and/or, obtaining the family room information data through a user, room or findRoomList interface;
和/或,通过user、scenes或searchSceneLi st接口获取所述家庭场景信息数据;And/or, obtaining the home scene information data through the user, scenes or searchSceneList interface;
和/或,通过devi ce、accessory或f i ndAccessoryByHome I d接口获取所述家庭设备信息数据。And/or, obtaining the home device information data through a device, accessory or findAccessoryByHomeId interface.
一种应用程序快速启动装置,包括:A device for quickly launching an application program, comprising:
第一模块,用于基于用户指令启动应用程序;The first module is used to start the application based on the user instruction;
第二模块,用于确定从应用程序启动至进入应用程序首页过程中的多个存在先后次序的任务;The second module is used to determine multiple tasks in a sequence from application startup to entering the application homepage;
第三模块,用于确定当前需执行的任务,若当前需执行的任务的子任务数量为多个,则调用与所述子任务数量相同的多个线程同时处理多个所述子任务;每个线程对应处理一不同的所述子任务;The third module is used to determine the task to be executed currently. If the task to be executed currently has multiple subtasks, multiple threads equal to the number of the subtasks are called to process the multiple subtasks simultaneously; each thread processes a different subtask.
第四模块,用于若所有子任务均执行成功,则基于所述先后次序将当前执行成功任务的下一任务作为当前需执行的任务,并驱动所述第三模块工作;若存在任何一子任务执行失败,则将所述先后次序中排序第一的任务作为当前需执行的任务,并驱动所述第三模块工作;The fourth module is used for, if all subtasks are successfully executed, taking the next task of the currently successfully executed task as the task to be executed based on the sequence, and driving the third module to work; if any subtask fails to be executed, taking the task ranked first in the sequence as the task to be executed, and driving the third module to work;
第五模块,用于当所述先后次序中排序倒数第一的任务执行成功,则进入应用程序首页。The fifth module is used to enter the application home page when the last task in the sequence is successfully executed.
在一个实施例中,所述第三模块还用于若当前需执行的任务的子任务数量为一个,则直接执行所述子任务。In one embodiment, the third module is further configured to directly execute the subtask if the number of subtasks of the task currently to be executed is one.
在一个实施例中,所述第四模块还用于监测自执行所述先后次序中排序第一的任务起所花费的执行时长,当所述执行时长超过预设时长,将所述先后次序中排序第一的任务作为当前需执行的任务,并驱动所述第三模块工作。In one embodiment, the fourth module is also used to monitor the execution time taken since the execution of the task ranked first in the priority sequence. When the execution time exceeds the preset time, the task ranked first in the priority sequence is used as the current task to be executed, and the third module is driven to work.
本申请至少具有以下有益效果:This application has at least the following beneficial effects:
本申请提供了一种应用程序快速启动方法及装置,方法包括:步骤A、基于用户指令启动应用程序;步骤B、确定从应用程序启动至进入应用程序首页过程中的多个存在先后次序的任务;步骤C、确定当前需执行的任务,若当前需执行的任务的子任务数量为多个,则调用与子任务数量相同的多个线程同时处理多个子任务;每个线程对应处理一不同的子任务;步骤D、若所有子任务均执行成功,则基于先后次序将当前执行成功任务的下一任务作为当前需执行的任务,并执行步骤C;若存在任何一子任务执行失败,则将先后次序中排序第一的任务作为当前需执行的任务,并执行步骤C;步骤E、当先后次序中排序倒数第一的任务执行成功,则进入应用程序首页。The present application provides a method and device for quickly starting an application, the method comprising: step A, starting the application based on a user instruction; step B, determining multiple tasks in a sequence from the start of the application to entering the application homepage; step C, determining the task to be executed currently, if the number of subtasks of the task to be executed currently is multiple, calling multiple threads with the same number of subtasks to process the multiple subtasks simultaneously; each thread processes a different subtask; step D, if all subtasks are executed successfully, then based on the sequence, the next task of the currently successfully executed task is used as the current task to be executed, and step C is executed; if any subtask fails to execute, then the task ranked first in the sequence is used as the current task to be executed, and step C is executed; step E, when the task ranked last in the sequence is executed successfully, the application homepage is entered.
本申请通过调用与子任务数量相同的多个线程同时处理多个子任务,以将多个子任务并行设置,缩短了应用程序执行任务花费的时间,优化了请求深度,减少了应用程序加载数据的时间,加快了数据的获取速度,且当任何一子任务执行失败,便重新执行在先后次序中排序第一的任务,缩短了应用程序重新启动的时间。The present application processes multiple subtasks simultaneously by calling multiple threads with the same number of subtasks, so as to set multiple subtasks in parallel, thereby shortening the time spent by the application to execute tasks, optimizing the request depth, reducing the time taken by the application to load data, speeding up the acquisition of data, and when any subtask fails to execute, the task ranked first in the sequence is re-executed, shortening the time to restart the application.
附图说明BRIEF DESCRIPTION OF THE DRAWINGS
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
图1为实施例1提供的应用程序快速启动方法的第一流程图;FIG1 is a first flow chart of a method for quickly starting an application program provided in Example 1;
图2为实施例1提供的应用程序快速启动方法的第二流程图;FIG2 is a second flow chart of the method for quickly starting an application program provided in Example 1;
图3为实施例1提供的应用程序快速启动方法的第三流程图;FIG3 is a third flow chart of the method for quickly starting an application program provided in Example 1;
图4为实施例2提供的应用程序快速启动装置的模块图。FIG. 4 is a module diagram of a device for quickly launching an application program provided in Example 2.
附图标记:Reference numerals:
1-第一模块;2-第二模块;3-第三模块;4-第四模块;5-第五模块。1-first module; 2-second module; 3-third module; 4-fourth module; 5-fifth module.
具体实施方式DETAILED DESCRIPTION
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅是本申请的一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
实施例1Example 1
目前的应用程序在获取信息花费的时间较长,且应用程序在获取信息失败到返回至登录界面花费的时间也较长,用户需要花费较长的时间等待,导致用户的体验感差。Current applications take a long time to obtain information, and the time it takes for an application to return to the login interface after failing to obtain information is also long. Users need to spend a long time waiting, resulting in a poor user experience.
如图1、图2和图3所示,本申请提供了一种应用程序快速启动方法,包括:As shown in FIG. 1 , FIG. 2 and FIG. 3 , the present application provides a method for quickly starting an application program, including:
步骤A、基于用户指令启动应用程序;Step A: starting the application based on user instructions;
步骤B、确定从应用程序启动至进入应用程序首页过程中的多个存在先后次序的任务;Step B, determining a plurality of tasks in a sequential order from application startup to entering the application homepage;
步骤C、确定当前需执行的任务,若当前需执行的任务的子任务数量为多个,则调用与子任务数量相同的多个线程同时处理多个子任务;每个线程对应处理一不同的子任务;Step C, determining the task to be executed currently, if the task to be executed currently has multiple subtasks, calling multiple threads with the same number of subtasks to process the multiple subtasks simultaneously; each thread processes a different subtask;
步骤D、若所有子任务均执行成功,则基于先后次序将当前执行成功任务的下一任务作为当前需执行的任务,并执行步骤C;若存在任何一子任务执行失败,则将先后次序中排序第一的任务作为当前需执行的任务,并执行步骤C;Step D: If all subtasks are successfully executed, the next task of the currently successfully executed task is used as the current task to be executed based on the order of priority, and step C is executed; if any subtask fails to be executed, the task ranked first in the order of priority is used as the current task to be executed, and step C is executed;
步骤E、当先后次序中排序倒数第一的任务执行成功,则进入应用程序首页。Step E: When the last task in the order of priority is successfully executed, the application home page is entered.
本申请通过步骤B中筛选出多个存在先后次序的任务,即存在依赖关系需串行设置的多个任务,确定必要的进行串行设置的任务,将非必要进行串行设置的任务进行优化处理,优化了请求深度;并在步骤C中通过调用与子任务数量相同的多个线程同时处理多个子任务,以将多个子任务并行设置,缩短了应用程序执行任务花费的时间,减少了应用程序加载数据的时间,加快了数据的获取速度,减少了用户使用应用程序时的等待时间;且在步骤D中设定当任何一子任务执行失败,便重新执行在先后次序中排序第一的任务,缩短了应用程序重新启动的时间,提高了用户的体验感。The present application optimizes the request depth by screening out multiple tasks with a sequence in step B, that is, multiple tasks that have a dependency relationship and need to be set in series, determining the tasks that are necessary to be set in series, and optimizing the tasks that are not necessary to be set in series; and in step C, multiple subtasks are processed simultaneously by calling multiple threads with the same number of subtasks to set multiple subtasks in parallel, thereby shortening the time spent by the application to execute tasks, reducing the time for the application to load data, speeding up data acquisition, and reducing the waiting time when the user uses the application; and in step D, it is set that when any subtask fails to execute, the task ranked first in the sequence is re-executed, thereby shortening the time to restart the application and improving the user experience.
本申请适用于与智能家居设备相关联的应用端,用户可通过应用端远程控制和查看智能设备相关信息。具体地,应用端可设置在手机、笔记本、或平板电脑等移动终端上。This application is applicable to an application terminal associated with a smart home device, through which a user can remotely control and view relevant information of the smart device. Specifically, the application terminal can be set on a mobile terminal such as a mobile phone, a notebook, or a tablet computer.
如图1、图2和图3所示,步骤C还包括:As shown in FIG. 1 , FIG. 2 and FIG. 3 , step C further includes:
若当前需执行的任务的子任务数量为一个,则直接执行子任务。If the number of subtasks of the task currently to be executed is one, the subtask is executed directly.
本申请可根据当前需执行的任务的子任务数量选择直接执行子任务或是调用与子任务数量相同的多个线程同时处理多个子任务,适用范围广。The present application can choose to directly execute a subtask or call multiple threads with the same number of subtasks to process multiple subtasks simultaneously according to the number of subtasks of the task currently to be executed, and has a wide range of applications.
如图1、图2和图3所示,步骤D还包括:As shown in FIG. 1 , FIG. 2 and FIG. 3 , step D further includes:
监测自执行先后次序中排序第一的任务起所花费的执行时长,当执行时长超过预设时长,将先后次序中排序第一的任务作为当前需执行的任务,并执行步骤C。The execution time taken since the task ranked first in the execution sequence is monitored. When the execution time exceeds the preset time, the task ranked first in the execution sequence is used as the current task to be executed, and step C is executed.
若执行时长超过预设时长,意味着中途出现执行任务失败的情况,本申请通过对执行时长进行监测,可快速发现执行任务失败的情况,以便快速重新执行在先后次序中排序第一的任务,缩短了应用程序重新启动的时间,减少了获取信息失败至返回到登录界面花费的时间。If the execution time exceeds the preset time, it means that the task failed in the middle. By monitoring the execution time, the present application can quickly discover the failure of the task so as to quickly re-execute the task that is ranked first in the priority order, thereby shortening the time for restarting the application and reducing the time spent from failure to obtain information to returning to the login interface.
如图1、图2和图3所示,多个存在先后次序的任务包括第一任务、第二任务和第三任务;As shown in FIG. 1 , FIG. 2 and FIG. 3 , the plurality of tasks in a sequential order include a first task, a second task and a third task;
第一任务包括获取用户信息数据的子任务;The first task includes the subtask of obtaining user information data;
第二任务包括获取应用信息数据的子任务和获取家庭信息数据的子任务;The second task includes a subtask of obtaining application information data and a subtask of obtaining family information data;
第三任务包括获取应用背景信息数据的子任务、获取家庭房间信息数据的子任务、获取家庭场景信息数据的子任务和获取家庭设备信息数据的子任务。The third task includes a subtask of obtaining application background information data, a subtask of obtaining home room information data, a subtask of obtaining home scene information data, and a subtask of obtaining home device information data.
本申请通过执行第一任务检测用户数据,确认用户是否登录成功,若检测到用户数据,即用户登录成功,将读取用户信息及相应token数据,若未检测到用户数据,即用户登录失败,则跳转至登录界面重新检测用户数据。This application detects user data by executing the first task to confirm whether the user has logged in successfully. If user data is detected, that is, the user has logged in successfully, the user information and corresponding token data will be read. If user data is not detected, that is, the user login failed, the application will jump to the login interface to re-check the user data.
具体地,通过user或getUser I nfo接口获取用户信息数据。Specifically, user information data is obtained through the user or getUser Info interface.
本申请通过执行第二任务获取应用信息数据以获取应用生产信息,还通过执行第二任务获取家庭信息数据以获取登录成功的用户的家庭信息数据。在本实施例中,获取应用信息数据的子任务状态以l oadProductFi n i s h记录,获取家庭信息数据的子任务状态以l oadHomeFi n i sh记录。The present application obtains application production information by executing the second task to obtain application information data, and also obtains home information data by executing the second task to obtain home information data to obtain home information data of the user who has successfully logged in. In this embodiment, the subtask status of obtaining application information data is recorded as loadProductFi n i sh, and the subtask status of obtaining home information data is recorded as loadHomeFi n i sh.
具体地,通过devi ce、product或f i ndA l lAccessoryProduct接口获取应用信息数据。Specifically, the application information data is obtained through the device, product or findA l lAccessoryProduct interface.
具体地,通过user、home或f i ndA l l接口获取家庭信息数据。Specifically, family information data is obtained through the user, home or findA l l interface.
本申请通过执行获取应用背景信息数据的子任务以获取应用背景图片信息数据,在本实施例中,通过assets、f i l e或f i ndByCode接口请求得到背景图片地址or i gina l Ur l,并保存到应用全局数据缓存中。具体地,获取应用背景信息数据的子任务状态以l oadHomeBgFi n i sh记录。This application obtains application background image information data by executing the subtask of obtaining application background information data. In this embodiment, the background image address origina l Url is obtained through the assets, file or findByCode interface request and saved to the application global data cache. Specifically, the subtask status of obtaining application background information data is recorded in loadHomeBgFinish.
本申请通过执行获取家庭房间信息数据的子任务以获取登录成功的用户的家庭房间信息数据。在本实施例中,通过user、room或f i ndRoomLi s t接口请求得到登录成功的用户的家庭信息房间数据,保存在全局的用户家庭房间列表缓存中。具体地,获取家庭房间信息数据的子任务状态以l oad RoomFi n i sh记录。This application obtains the home room information data of the user who has successfully logged in by executing the subtask of obtaining the home room information data. In this embodiment, the home room information data of the user who has successfully logged in is obtained through the user, room or findRoomList interface request, and is saved in the global user home room list cache. Specifically, the subtask status of obtaining the home room information data is recorded as loadRoomFinish.
本申请通过执行获取家庭场景信息数据的子任务以获取登录成功的用户的家庭场景信息数据。在本实施例中,通过user、scenes或searchSce neLi st接口请求得到登录成功的用户的家庭场景信息数据,保存在全局的用户家庭场景列表缓存中。具体地,获取家庭场景信息数据的子任务状态以l oadSceneFi n i sh记录。This application obtains the home scene information data of the user who successfully logged in by executing the subtask of obtaining home scene information data. In this embodiment, the home scene information data of the user who successfully logged in is obtained through the user, scenes or searchSceneList interface request, and is saved in the global user home scene list cache. Specifically, the subtask status of obtaining home scene information data is recorded in loadSceneFi n i sh.
本申请通过执行获取家庭设备信息数据的子任务以获取登录成功的用户的家庭设备信息数据。在本实施例中,通过devi ce、accessory或f i nd AccessoryByHome I d接口请求得到登录成功的用户的家庭设备信息数据,保存在全局的用户家庭设备列表缓存中。具体地,获取家庭设备信息数据的子任务状态以l oadDevi ceFi n i sh记录。This application obtains the home device information data of the user who successfully logged in by executing the subtask of obtaining home device information data. In this embodiment, the home device information data of the user who successfully logged in is obtained through the device, accessory or findAccessoryByHomeId interface request, and is saved in the global user home device list cache. Specifically, the subtask status of obtaining home device information data is recorded as loadDeviceFinish.
在本实施例中,若第一任务、第二任务和第三任务均执行成功,则各任务状态均显示为l oadTrue,则应用程序进入首页,并将相应的用户数据显示到首页上,若在执行的过程中其中一个任务或子任务执行失败,则对应的任务状态显示为l oadError,则应用程序跳转至登录界面,则需要用户重新登录。In this embodiment, if the first task, the second task and the third task are all executed successfully, the status of each task is displayed as loadTrue, the application enters the home page, and displays the corresponding user data on the home page. If one of the tasks or subtasks fails during the execution process, the corresponding task status is displayed as loadError, the application jumps to the login interface, and the user is required to log in again.
本实施例至少具有以下有益效果:This embodiment has at least the following beneficial effects:
1.大大减少了应用程序的启动时间,减少了用户使用应用程序时的等待时间,提高了用户的体验感。1. Greatly reduces the startup time of the application, reduces the waiting time when users use the application, and improves the user experience.
2.将多个子任务并行设置,能够快速识别出哪个子任务执行失败,进而快速检测出哪些接口存在问题,最终快速返回至在先后次序中排序第一的任务,缩短了应用程序重新启动的时间。2. Setting multiple subtasks in parallel can quickly identify which subtask failed to execute, and then quickly detect which interfaces have problems, and finally quickly return to the task ranked first in the order, shortening the time to restart the application.
3.将原先的无先后次序但串行设置的子任务拆分,调用与子任务数量相同的多个线程同时处理多个子任务,每个线程对应处理一不同的子任务,各子任务之间相互独立,提高了代码的可读性和可复用性。3. Split the original subtasks that are not in order but set serially, and call multiple threads with the same number of subtasks to process multiple subtasks simultaneously. Each thread processes a different subtask, and each subtask is independent of each other, which improves the readability and reusability of the code.
实施例2Example 2
如图4所示,本申请还提供了一种应用程序快速启动装置,包括:As shown in FIG4 , the present application also provides a device for quickly starting an application program, including:
第一模块1,用于基于用户指令启动应用程序;The first module 1 is used to start the application based on the user instruction;
第二模块2,用于确定从应用程序启动至进入应用程序首页过程中的多个存在先后次序的任务;The second module 2 is used to determine a plurality of tasks in a sequential order from the start of the application to the entry into the application homepage;
第三模块3,用于确定当前需执行的任务,若当前需执行的任务的子任务数量为多个,则调用与子任务数量相同的多个线程同时处理多个子任务;每个线程对应处理一不同的子任务;The third module 3 is used to determine the task to be executed currently. If the task to be executed currently has multiple subtasks, multiple threads with the same number of subtasks are called to process the multiple subtasks simultaneously; each thread processes a different subtask.
第四模块4,用于若所有子任务均执行成功,则基于先后次序将当前执行成功任务的下一任务作为当前需执行的任务,并驱动第三模块工作;若存在任何一子任务执行失败,则将先后次序中排序第一的任务作为当前需执行的任务,并驱动第三模块工作;The fourth module 4 is used to, if all subtasks are successfully executed, take the next task of the currently successfully executed task as the current task to be executed based on the order of precedence, and drive the third module to work; if any subtask fails to be executed, take the task ranked first in the order of precedence as the current task to be executed, and drive the third module to work;
第五模块5,用于当先后次序中排序倒数第一的任务执行成功,则进入应用程序首页。The fifth module 5 is used to enter the application home page when the last task in the order of priority is successfully executed.
本申请通过第一模块1、第二模块2、第三模块3、第四模块4和第五模块5之间的相互配合,缩短了应用程序执行任务花费的时间,优化了请求深度,减少了应用程序加载数据的时间,加快了数据的获取速度,缩短了应用程序重新启动的时间,减少了获取信息失败至返回到登录界面花费的时间。Through the mutual cooperation between the first module 1, the second module 2, the third module 3, the fourth module 4 and the fifth module 5, the present application shortens the time taken by the application to execute tasks, optimizes the request depth, reduces the time taken by the application to load data, speeds up the acquisition of data, shortens the time taken to restart the application, and reduces the time taken to return to the login interface from the failure to obtain information.
在一个实施例中,第三模块还用于若当前需执行的任务的子任务数量为一个,则直接执行子任务。In one embodiment, the third module is further configured to directly execute the subtask if the number of subtasks of the task currently to be executed is one.
在一个实施例中,第四模块还用于监测自执行先后次序中排序第一的任务起所花费的执行时长,当执行时长超过预设时长,将先后次序中排序第一的任务作为当前需执行的任务,并驱动第三模块工作。In one embodiment, the fourth module is also used to monitor the execution time taken since the task ranked first in the execution order is executed. When the execution time exceeds the preset time, the task ranked first in the execution order is used as the current task to be executed, and the third module is driven to work.
本领域普通技术人员应该明白,上述的本申请的各模块或各步骤可以用通用的计算装置来实现,它们可以集中在单个计算装置上,或者分布在多个计算装置所组成的网络上,可选地,他们可以用计算机装置可执行的程序代码来实现,从而可以将它们存储在存储装置中由计算装置来执行,或者将它们分别制作成各个集成电路模块,或者将它们中的多个模块或步骤制作成单个集成电路模块来实现。这样,本申请不限制于任何特定的硬件和软件的结合。It should be understood by those skilled in the art that the above modules or steps of the present application can be implemented by a general-purpose computing device, they can be concentrated on a single computing device, or distributed on a network composed of multiple computing devices, optionally, they can be implemented by a program code executable by a computer device, so that they can be stored in a storage device and executed by the computing device, or they can be made into individual integrated circuit modules, or multiple modules or steps therein can be made into a single integrated circuit module for implementation. Thus, the present application is not limited to any specific combination of hardware and software.
注意,上述仅为本申请的较佳实施例及所运用技术原理。本领域技术人员会理解,本申请不限于这里的特定实施例,对本领域技术人员来说能够进行各种明显的变化、重新调整和替代而不会脱离本申请的保护范围。因此,虽然通过以上实施例对本申请进行了较为详细的说明,但是本申请不仅仅限于以上实施例,在不脱离本申请构思的情况下,还可以包括更多其他等效实施例,而本申请的范围由所附的权利要求范围决定。Note that the above are only preferred embodiments of the present application and the technical principles used. Those skilled in the art will understand that the present application is not limited to the specific embodiments herein, and that various obvious changes, readjustments and substitutions can be made by those skilled in the art without departing from the scope of protection of the present application. Therefore, although the present application is described in more detail through the above embodiments, the present application is not limited to the above embodiments, and may include more other equivalent embodiments without departing from the concept of the present application, and the scope of the present application is determined by the scope of the appended claims.
以上所述仅为本申请的较佳实施例,并不用以限制本申请,凡在本申请的精神和原则之内,所作的任何修改、等同替换、改进等,均应包含在本申请的保护范围之内。The above description is only a preferred embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application should be included in the protection scope of the present application.
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202411071598.3ACN118916091A (en) | 2024-08-06 | 2024-08-06 | Method and device for quickly starting application program |
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202411071598.3ACN118916091A (en) | 2024-08-06 | 2024-08-06 | Method and device for quickly starting application program |
| Publication Number | Publication Date |
|---|---|
| CN118916091Atrue CN118916091A (en) | 2024-11-08 |
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202411071598.3APendingCN118916091A (en) | 2024-08-06 | 2024-08-06 | Method and device for quickly starting application program |
| Country | Link |
|---|---|
| CN (1) | CN118916091A (en) |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN119668699A (en)* | 2024-11-28 | 2025-03-21 | 杭州迈冲科技有限公司 | A boot acceleration method and device based on Android system |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN119668699A (en)* | 2024-11-28 | 2025-03-21 | 杭州迈冲科技有限公司 | A boot acceleration method and device based on Android system |
| Publication | Publication Date | Title |
|---|---|---|
| US20190018690A1 (en) | Method And Apparatus For Controlling A Startup Bootstrap Program Of An Intelligent TV Set | |
| CN118916091A (en) | Method and device for quickly starting application program | |
| CN103729240B (en) | Application program control method | |
| US20130054951A1 (en) | Software execution method and electronic device using the same | |
| US20150019692A1 (en) | Method and apparatus for firmware virtualization | |
| CN110798701A (en) | Video update pushing method and terminal | |
| CN112612551A (en) | Method, device, equipment, medium and product for managing distributed transactions | |
| US11853153B2 (en) | Multi-thread exit method and mobile terminal | |
| CN113411225A (en) | QGA service management method, device, equipment and medium based on cloud host | |
| CN112558968A (en) | Resource tree view generation method, device, equipment and storage medium | |
| CN113590277B (en) | Task state switching method, device and electronic system | |
| CN118277140A (en) | Application page recovery method, device, equipment and storage medium | |
| CN111736928B (en) | Picture-in-picture mode starting method and device and computer readable storage medium | |
| CN111221732B (en) | Script execution processing method, device and storage medium | |
| CN113656063A (en) | System version replacing method, device, equipment and computer readable medium | |
| CN107943533B (en) | Image acquisition method, device, storage medium and electronic device | |
| CN113157161B (en) | Control method and device | |
| CN112130721A (en) | Method for starting multi-window multi-task by one key based on Andriod platform and readable medium | |
| CN111047032A (en) | Image detection acceleration method and device and storage medium | |
| CN111367589A (en) | Information processing device, recording medium, and information processing method | |
| CN114706753B (en) | Display interface testing method and device, electronic equipment and storage medium | |
| CN118574000B (en) | Method for controlling camera to display preview image and electronic device | |
| CN112698885B (en) | Method and device for operating | |
| CN117492613A (en) | Data processing method, device, vehicle and storage medium | |
| US20090106759A1 (en) | Information processing system and related method thereof |
| 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 |