CN107943270A - Control method, device and the storage medium and mobile terminal of application service - Google Patents
Control method, device and the storage medium and mobile terminal of application service Download PDFInfo
- Publication number
- CN107943270A CN107943270A CN201711168326.5A CN201711168326A CN107943270A CN 107943270 A CN107943270 A CN 107943270A CN 201711168326 A CN201711168326 A CN 201711168326A CN 107943270 A CN107943270 A CN 107943270A
- Authority
- CN
- China
- Prior art keywords
- setting
- services
- information
- service
- destination service
- 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.)
- Granted
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F1/00—Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
- G06F1/26—Power supply means, e.g. regulation thereof
- G06F1/32—Means for saving power
- G06F1/3203—Power management, i.e. event-based initiation of a power-saving mode
- G06F1/3234—Power saving characterised by the action undertaken
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F1/00—Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
- G06F1/26—Power supply means, e.g. regulation thereof
- G06F1/32—Means for saving power
- G06F1/3203—Power management, i.e. event-based initiation of a power-saving mode
- G06F1/3206—Monitoring of events, devices or parameters that trigger a change in power modality
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements 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/46—Multiprogramming arrangements
- G06F9/50—Allocation of resources, e.g. of the central processing unit [CPU]
- G06F9/5005—Allocation of resources, e.g. of the central processing unit [CPU] to service a request
- G06F9/5011—Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals
- G06F9/5016—Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals the resource being the memory
Abstract
The embodiment of the present application discloses a kind of control method of application service, device and storage medium and mobile terminal, the described method includes:Before mode is restarted according to setting and restarts destination service, the information on services of the destination service is obtained;Judge whether the information on services meets that condition is restarted in setting;If the information on services meets that condition is restarted in setting, the operation for restarting the destination service is performed;If the information on services, which is unsatisfactory for setting, restarts condition, the destination service is forbidden to restart.Technical solution provided by the embodiments of the present application, can rational management and control application program reboot operation, prevent some services for being unsatisfactory for restarting condition from restarting mode according to setting and being restarted, cause the consumption of the unnecessary resource of mobile terminal and flow, the running memory and electricity of mobile terminal are saved, improves the fluency of running of mobile terminal.
Description
Technical field
The invention relates to application control technical field, more particularly to a kind of control method of application service, device
And storage medium and mobile terminal.
Background technology
Function in the mobile terminals such as mobile phone is more and more, provides convenience for the live and work of people, and people can be with
Phone is taken using mobile phone, can also be listened to music, be watched video, play game etc..Serviced in the android system of mobile phone
(service) as one of four big components, the service needed in backstage longtime running can be provided, such as Weather information is more
Newly, the backstage of music play, the download of resource etc..But there is certain lack to the control method of application service in correlation technique
Fall into, it is necessary to improve.
The content of the invention
The embodiment of the present application provides a kind of control method of application service, device and storage medium and mobile terminal, can be with
Application service in rational management and control mobile terminal.
In a first aspect, the embodiment of the present application provides a kind of control method of application service, including:
Before mode is restarted according to setting and restarts destination service, the information on services of the destination service is obtained;
Judge whether the information on services meets that condition is restarted in setting;
If the information on services meets that condition is restarted in setting, the operation for restarting the destination service is performed;
If the information on services, which is unsatisfactory for setting, restarts condition, the destination service is forbidden to restart.
In second aspect, the embodiment of the present application provides a kind of control device of application service, including:
Information on services acquisition module, for before mode is restarted according to setting and restarts destination service, obtaining the target
The information on services of service;
Condition judgment module is restarted, for judging whether the information on services meets that condition is restarted in setting;
Destination service restarts module, if meeting that condition is restarted in setting for the information on services, the mesh is restarted in execution
Mark the operation of service;
Destination service restarts disabled module, if being unsatisfactory for setting for the information on services restarts condition, forbids described
Destination service is restarted.
The third aspect, the embodiment of the present application provide a kind of computer-readable recording medium, are stored thereon with computer journey
Sequence, realizes the control method of the application service provided such as first aspect when which is executed by processor.
In fourth aspect, the embodiment of the present application provides a kind of mobile terminal, including memory, processor and is stored in
On reservoir and the computer program that can run on a processor, realized when the processor performs as what first aspect was provided answers
With the control method of service.
The embodiment of the present application is by before mode is restarted according to setting and restarts destination service, first obtaining the destination service
Information on services, if the information on services meets that condition is restarted in setting, the destination service is restarted, if the information on services is not
Meet that condition is restarted in setting, then forbid destination service to be restarted, can rational management and control application program reboot operation, prevent
Some services for being unsatisfactory for restarting condition are restarted mode according to setting and are restarted, and cause the unnecessary resource of mobile terminal and stream
The consumption of amount, saves the running memory and electricity of mobile terminal, improves the fluency of running of mobile terminal.
Brief description of the drawings
Fig. 1 is a kind of flow chart of the control method of application service provided by the embodiments of the present application;
Fig. 2 is the flow chart of the control method of another application service provided by the embodiments of the present application;
Fig. 3 is the flow chart of the control method of another application service provided by the embodiments of the present application;
Fig. 4 is a kind of structure diagram of the control device of application service provided by the embodiments of the present application;
Fig. 5 is a kind of structure diagram of mobile terminal provided by the embodiments of the present application
Fig. 6 is the structure diagram of another mobile terminal provided by the embodiments of the present application.
Embodiment
It is specifically real to the application below in conjunction with the accompanying drawings in order to make the purpose, technical scheme and advantage of the application clearer
Example is applied to be described in further detail.It is understood that specific embodiment described herein is used only for explaining the application,
Rather than the restriction to the application.It also should be noted that for the ease of describing, illustrate only in attached drawing related to the application
Part rather than full content.It should be mentioned that some exemplary realities before exemplary embodiment is discussed in greater detail
Apply processing or method that example is described as describing as flow chart.Although operations (or step) are described as order by flow chart
Processing, but many of which operation can be implemented concurrently, concomitantly or at the same time.In addition, the order of operations
It can be rearranged.The processing can be terminated when its operations are completed, it is also possible to being not included in attached drawing
Additional step.The processing can correspond to method, function, code, subroutine, subprogram etc..
Fig. 1 gives a kind of flow chart of the control method of application service provided by the embodiments of the present application, the present embodiment
Method can be performed by the control device of application service, which can be realized by way of hardware and/or software, the dress
The inside of the mobile terminal can be arranged on as a mobile terminal part by putting.Mobile terminal bag described in the embodiment of the present application
Include but be not limited to mobile phone, the equipment such as tablet computer or notebook.
As shown in Figure 1, the control method of application service provided in this embodiment comprises the following steps:
Step 101, before mode is restarted according to setting and restarts destination service, obtain the destination service service letter
Breath.
Service is a kind of non-visual running background logic, for providing running background service for application, can be claimed
For service., can be by application up and down when some application needs to perform a section business logic, but is not desired to visualize on foreground
Text calls startService functions to start service, come called a service, this service can be the application certainly
Body or another application service., can be to being when needing to call a service if others application
System sends request, and whether oneself is activated for the process that system can check where service, if do not started, it is necessary to start
Process where service.
Generally, the life cycle of service is:StartService functions (i.e. startService () is being called manually
Method) after, inside can call onCreate () method, onStartCommand () method and onDestroy methods successively automatically
().Wherein, onCreate () method is used for an example for creating service, and onStartCommand () method is used for certainly
After settled service is killed, how to handle, such as whether be restarted after judging abnormal end, it is abnormal under what circumstances
Terminate, onDestroy () method, which is used to destroy, to be serviced.StopService () method is further included, is serviced for closing, manual
It is automatic to call internalist methodology onDestroy () to destroy service after the stopService () method of calling.
Some services can restart mode to be restarted, example after being closed or closing extremely by some settings
Such as, a timer is set, often restarts a destination service when detecting that the timer reaches setting interval time, or
Setup parameter value is returned to restart destination service by the first setting function of calling, or by for stopping the of service
Called again in two setting functions and be used for the 3rd setting function for starting service to start destination service.And some services are
Rogue services, such as the service that some third-party applications are opened and called for keep-alive itself, so being stopped it in service
Afterwards when restarting, the information on services of service can be first obtained, whether meets that the judgement knot of condition is restarted in setting according to information on services
Fruit determines whether to restart the destination service.Wherein, it is described first setting function include onstart functions or
OnStartCommand functions, the second setting function include onDestroy functions, and the 3rd setting function includes
StartService functions.Wherein, onstar functions are used in the version of below android2.0.And in android2.0
OnstartCommand () method is then used above.Both methods are put together in use, conflict will not be produced.
In certain embodiment, before mode is restarted according to setting and restarts destination service, the destination service is obtained
Information on services the step of before further include:Startup characteristic information satisfaction setting startup characteristic information is waited to restart service, really
It is set to destination service.The startup characteristic information includes at least one of following:Triggering services the event started, Starting mode, opens
Operation duration and the feedback information of user after startup after dynamic.
Step 102, judge whether the information on services meets that condition is restarted in setting, if so, then performing step 103, otherwise
Perform step 104.
If the information on services meets that condition is restarted in setting, the operation for restarting the destination service is performed;If the clothes
Business information is unsatisfactory for setting and restarts condition, then forbids the destination service to restart.Wherein, the information on services includes Service name
Claim, service corresponding user identifier, process identification (PID) and at least one using Bao Mingzhong.
Step 103, execution restart the operation of the destination service.
It is exemplary, when information on services meets that condition is restarted in setting, and when timer reaches setting interval time, pass through
StartService functions are called to restart destination service;It is again exemplary, when information on services meets that condition is restarted in setting, pass through
The the first setting function called returns to setup parameter value to restart destination service;It is again exemplary, meet to set in information on services
When restarting condition surely, it is used for the 3rd setting function for starting service by being called in the second setting function for stopping service
To restart destination service.
Wherein, the setup parameter value includes START_STICKY or START_REDELIVER_INTENT.If return
It is worth for START_STICKY, expression:If service processes are fallen by kill, the state for retaining service is beginning state, but
The intent objects of delivering are not retained, subsequent system can be attempted to re-create service, i.e. the service unlimited can be run simultaneously
Wait for bringing for work.If return value is START_REDELIVER_INTENT, then it represents that:If service processes are different
Normal kill falls, and system can restart the service automatically, and the value of Intent is passed to.
Step 104, forbid the destination service to restart.
It is exemplary, when information on services is unsatisfactory for setting and restarts condition, even if timer reaches setting time interval,
The operation for restarting destination service is not performed, further, can also be included:Stop the Clocked operation of the timer;Again
Exemplary, when information on services is unsatisfactory for setting and restarts condition, the first called setting function of control does not return to setting ginseng
Numerical value, returns to the setup parameter value to restart destination service so that no thoroughfare;It is again exemplary, it is unsatisfactory for setting in information on services
When restarting condition surely, forbid calling the 3rd setting function in the second setting function, letter is set second so that no thoroughfare
The 3rd setting function is called to restart destination service in number.
The control method of application service provided in this embodiment, by according to setting restart mode restart destination service it
Before, the information on services of the destination service is first obtained, if the information on services meets that condition is restarted in setting, restarts the target
Service, if the information on services, which is unsatisfactory for setting, restarts condition, forbids destination service to be restarted, and can reasonably management and control answer
With the reboot operation of program, prevent some services for being unsatisfactory for restarting condition from restarting mode according to setting and being restarted, cause to move
The consumption of the dynamic unnecessary resource of terminal and flow, saves the running memory and electricity of mobile terminal, improves mobile terminal
The fluency of operation.
In some embodiments, it is described to judge whether the destination service meets that setting is restarted condition and be included:Sentence
Whether the information on services that breaks is in the first setting white list;If correspondingly, the information on services meets that bar is restarted in setting
Part, then perform and restart the operation of the destination service and can include:If the service name is held in the first setting white list
Row restarts the operation of the destination service;If the information on services is unsatisfactory for setting and restarts condition, forbid the target
Server resets can include:If the service name in the first setting white list, does not forbid the destination service to restart.
Judge whether the information on services meets that setting is restarted condition and can be included alternatively, described:Judge user's mark
Whether knowledge and/or process identification (PID) and/or application bag name are in the second setting white list;If the correspondingly, information on services
Meet that condition is restarted in setting, then perform and restart the operation of the destination service and can include:If the user identifier, process identification (PID)
And/or application bag name then performs the operation for restarting the destination service in the second setting white list;If the service letter
Breath is unsatisfactory for setting and restarts condition, then forbidding the destination service to restart can include:If the user identifier and/or process mark
Know and/or application bag name is not in the second setting white list, then forbid the destination service to restart.
In some embodiments, can also comprise the following steps:From described in server or mobile terminal locally acquisition
First setting white list and the second setting white list.Wherein, the first setting white list and the second setting white list are in terminal
The mode being locally stored includes file mode storage or database mode storage.
Fig. 2 gives the flow chart of the control method of another application service provided by the embodiments of the present application.Such as Fig. 2 institutes
Show, the control method of application service provided in this embodiment comprises the following steps:
Step 201, before restarting destination service, obtain passing through called the first setting function and return to setup parameter value
Take the information on services of the destination service.Wherein, the setup parameter restarts the destination service for instruction, and described first sets
Determining function includes onstart functions or onStartCommand functions.
The setup parameter value includes START_STICKY or START_REDELIVER_INTENT.
Step 202, judge whether the information on services meets that condition is restarted in setting, if so, then performing step 203, otherwise
Perform step 204.
If the information on services meets that condition is restarted in setting, the operation for restarting the destination service is performed;If the clothes
Business information is unsatisfactory for setting and restarts condition, then forbids the destination service to restart.Wherein, the information on services includes Service name
Claim, service corresponding user identifier, process identification (PID) and at least one using Bao Mingzhong.
Step 203, execution restart the operation of the destination service.
When the information on services meets that condition is restarted in setting, perform and call the first setting function and return to setup parameter value
To restart the operation of destination service.
Step 204, forbid the destination service to restart.
When the information on services is unsatisfactory for imposing a condition, the first called setting function of control does not return to setup parameter
Value, returns to the setup parameter value to restart destination service so that no thoroughfare.
In some embodiments, it is described to forbid the destination service to restart being:The first called setting of control
Function returns to null value, or the first setting function return START_NOT_STICKY parameter values that control is called.If return value
For START_NOT_STICKY, then it represents that:If service processes are fallen by abnormal kill, system will not restart the service automatically.
The first setting function can be specifically rewritten, such as following examples:
public int onStartCommand(Intent intent,int flags,int startId){
handleCommand(intent);
return START_NOT_STICKY;
}
It is unsatisfactory in the case that setting restarts condition, when being restarted, can control and calling in the information on services of destination service
The first setting function after above-mentioned rewriting.
The control method of application service provided in this embodiment, setting ginseng is returned in the first setting function for passing through called
Numerical value before restarting destination service, first obtains the information on services of the destination service, if the information on services meets setting weight
Condition is opened, then restarts the destination service, if the information on services, which is unsatisfactory for setting, restarts condition, forbids destination service to carry out
Restart, can rational management and control application program reboot operation, prevent some to be unsatisfactory for restarting services of condition according to setting weight
The mode of opening is restarted, and causes the consumption of the unnecessary resource of mobile terminal and flow, saves the running memory of mobile terminal
And electricity, improve the fluency of running of mobile terminal.
Fig. 3 gives the flow chart of the control method of another application service provided by the embodiments of the present application.Such as Fig. 3 institutes
Show, the control method of application service provided in this embodiment comprises the following steps:
Step 301, by calling in the second setting function for stopping service being used to start the 3rd setting for service
Function is determined before restarting destination service, to obtain the information on services of the destination service.Wherein, the second setting function includes
OnDestroy functions, the 3rd setting function include startService functions.
Step 302, judge whether the information on services meets that condition is restarted in setting, if so, then performing step 303, otherwise
Perform step 304.
If the information on services meets that condition is restarted in setting, the operation for restarting the destination service is performed;If the clothes
Business information is unsatisfactory for setting and restarts condition, then forbids the destination service to restart.Wherein, the information on services includes Service name
Claim, service corresponding user identifier, process identification (PID) and at least one using Bao Mingzhong.
Step 303, execution restart the operation of the destination service.
When the information on services meets that condition is restarted in setting, by being adjusted in the second setting function for stopping service
Function is set with the 3rd for startup service to restart destination service.
Step 304, forbid the destination service to restart.
When the information on services is unsatisfactory for imposing a condition, forbid calling the 3rd setting letter in the second setting function
Number, calls the 3rd setting function to restart destination service so that no thoroughfare in the second setting function.
Generally, by calling the 3rd setting function startService's in the second setting function onDestroy
For mode to rewrite onDestroy functions, the onDestroy functions of rewriting are as follows:
In some embodiments, it is described to forbid the destination service to restart being:Forbid in the second setting function
The 3rd setting function is called, i.e., before the 3rd setting function is called, the information on services of destination service is discontented with if judging
Condition is restarted in foot setting, then forbids calling the 3rd setting function in the second setting function.
Method provided in this embodiment, is used to start clothes by calling in the second setting function for stopping service
The 3rd of business sets function before restarting destination service, first to obtain the information on services of the destination service, if the service letter
Breath meets that condition is restarted in setting, then restarts the destination service, if the information on services, which is unsatisfactory for setting, restarts condition, forbid
Destination service is restarted, can rational management and control application program reboot operation, prevent some clothes for being unsatisfactory for restarting condition
Business is restarted mode according to setting and is restarted, and causes the consumption of the unnecessary resource of mobile terminal and flow, saves mobile whole
The running memory and electricity at end, improve the fluency of running of mobile terminal.
Fig. 4 is a kind of structure diagram of the control device of application service provided by the embodiments of the present application, which can be by
Software and/or hardware realization, integrate in the terminal.As shown in figure 4, the device includes information on services acquisition module 41, again
Open condition judgment module 42, destination service restarts module 43 and destination service restarts disabled module 44.
The information on services acquisition module 41, for before mode is restarted according to setting and restarts destination service, obtaining institute
State the information on services of destination service;
It is described to restart condition judgment module 42, for judging whether the information on services meets that condition is restarted in setting;
Destination service restarts module 43, if meeting that condition is restarted in setting for the information on services, execution is restarted described
The operation of destination service;
The destination service restarts disabled module 44, if being unsatisfactory for setting for the information on services restarts condition, prohibits
Only the destination service is restarted.
Device provided in this embodiment, described in before mode is restarted according to setting and restarts destination service, first obtaining
The information on services of destination service, if the information on services meets that condition is restarted in setting, restarts the destination service, if the clothes
Business information is unsatisfactory for setting and restarts condition, then forbid destination service to be restarted, and can reasonably management and control application program restart
Operation, prevents some services for being unsatisfactory for restarting condition from restarting mode according to setting and being restarted, causes mobile terminal unnecessary
Resource and flow consumption, save the running memory and electricity of mobile terminal, improve the fluency of running of mobile terminal.
Optionally, the information on services includes service name, services corresponding user identifier, process identification (PID) and application bag
At least one of in name.
Optionally, the information on services acquisition module includes:
First service information acquisition unit, for passing through the first called setting function return setup parameter value come weight
Before opening destination service, the information on services of the destination service is obtained, the setup parameter restarts the target clothes for instruction
Business, the first setting function include onstart functions or onStartCommand functions.
Optionally, the information on services is obtained and included:
Second service information acquisition unit, for by being used in the second setting function for stopping service
Start the 3rd setting function of service before restarting destination service, to obtain the information on services of the destination service, described second
Setting function includes onDestroy functions, and the 3rd setting function includes startService functions.
Optionally, the setup parameter value includes START_STICKY or START_REDELIVER_INTENT.
Optionally, it is described to restart condition judgment module and be used for:Judge the information on services whether in the first setting white list
In;Correspondingly,
The destination service is restarted module and is specifically used for:If the service name performs in the first setting white list
Restart the operation of the destination service;
The destination service is restarted disabled module and is specifically used for:
If the service name in the first setting white list, does not forbid the destination service to restart;
Alternatively,
It is described to restart condition judgment module and be specifically used for:Judge the user identifier and/or process identification (PID) and/or application bag
Whether name is in the second setting white list;Correspondingly,
The destination service is restarted module and is specifically used for:If the user identifier, process identification (PID) and/or application bag name are the
In two setting white lists, then the operation for restarting the destination service is performed;
The destination service is restarted disabled module and is specifically used for:
If the user identifier and/or process identification (PID) and/or application bag name in the second setting white list, do not forbid institute
Destination service is stated to restart.
Optionally, described device further includes:
White list acquisition module, for locally obtaining the first setting white list and the from server or mobile terminal
Two setting white lists, the first setting white list and the second setting white list include file side in the mode that terminal local stores
Formula stores or database mode storage.
The embodiment of the present application also provides a kind of storage medium for including computer executable instructions, and the computer can perform
When being performed by computer processor for performing a kind of control method of application service, this method includes for instruction:
Before mode is restarted according to setting and restarts destination service, the information on services of the destination service is obtained;
Judge whether the information on services meets that condition is restarted in setting;
If the information on services meets that condition is restarted in setting, the operation for restarting the destination service is performed;
If the information on services, which is unsatisfactory for setting, restarts condition, the destination service is forbidden to restart.
Storage medium --- any various types of memory devices or storage device.Term " storage medium " is intended to wrap
Include:Install medium, such as CD-ROM, floppy disk or magnetic tape equipment;Computer system memory or random access memory, such as
DRAM, DDR RAM, SRAM, EDO RAM, blue Bath (Rambus) RAM etc.;Nonvolatile memory, such as flash memory, magnetizing mediums
(such as hard disk or optical storage);Memory component of register or other similar types etc..Storage medium can further include other
The memory of type or its combination.In addition, storage medium can be located at program in the first computer system being wherein performed,
Or can be located in different second computer systems, second computer system is connected to the by network (such as internet)
One computer system.Second computer system can provide programmed instruction and be used to perform to the first computer." storage is situated between term
Matter " can include may reside within diverse location two of (such as in different computer systems by network connection) or
More storage mediums.Storage medium can store the programmed instruction that can be performed by one or more processors and (such as implement
For computer program).
Certainly, a kind of storage medium for including computer executable instructions that the embodiment of the present application is provided, its computer
The control operation for the application service that executable instruction is not limited to the described above, can also carry out the application any embodiment and is provided
Application service control method in relevant operation.
The embodiment of the present application provides a kind of mobile terminal, and provided by the embodiments of the present application answer can be integrated in the mobile terminal
With the control device of service.Fig. 5 is a kind of structure diagram of mobile terminal provided by the embodiments of the present application.Mobile terminal 500
It can include:Memory 501, processor 502 and the computer journey that is stored on memory 501 and can be run in processor 502
Sequence, the processor 502 realize the controlling party of the application service as described in the embodiment of the present application when performing the computer program
Method.
Mobile terminal provided by the embodiments of the present application, can rational management and control application program reboot operation, prevent
The service for being unsatisfactory for restarting condition is restarted mode according to setting and is restarted, and causes the unnecessary resource of mobile terminal and flow
Consumption, saves the running memory and electricity of mobile terminal, improves the fluency of running of mobile terminal.
Fig. 6 is the structure diagram of another mobile terminal provided by the embodiments of the present application, as shown in fig. 6, the movement is whole
End can include:Memory 601, central processing unit (Central Processing Unit, CPU) 602 (also known as processor, with
Lower abbreviation CPU), the memory 601, for storing executable program code;The processor 602 is by reading the storage
The executable program code stored in device 601 runs program corresponding with the executable program code, for performing:
Restart according to setting before mode restarts destination service, obtain the information on services of the destination service;Judge the information on services
Whether condition is restarted in satisfaction setting;If the information on services meets that condition is restarted in setting, the destination service is restarted in execution
Operation;If the information on services, which is unsatisfactory for setting, restarts condition, the destination service is forbidden to restart.
The mobile terminal further includes:Peripheral Interface 603, RF (Radio Frequency, radio frequency) circuit 605, audio-frequency electric
Road 606, loudspeaker 611, power management chip 608, input/output (I/O) subsystem 609, touch-screen 612, other input/controls
Control equipment 610 and outside port 604, these components are communicated by one or more communication bus or signal wire 607.
It should be understood that diagram mobile terminal 600 is only an example of mobile terminal, and mobile terminal 600
Can have than more or less components shown in figure, can combine two or more components, or can be with
Configured with different components.Various parts shown in figure can be including one or more signal processings and/or special
Hardware, software including integrated circuit are realized in the combination of hardware and software.
Just provided in this embodiment below to be used to control the mobile terminal of application service to be described in detail, the movement is whole
End is by taking mobile phone as an example.
Memory 601, the memory 601 can be accessed by CPU602, Peripheral Interface 603 etc., and the memory 601 can
Including high-speed random access memory, can also include nonvolatile memory, such as one or more disk memories,
Flush memory device or other volatile solid-state parts.
The peripheral hardware that outputs and inputs of equipment can be connected to CPU502 and deposited by Peripheral Interface 603, the Peripheral Interface 603
Reservoir 601.
I/O subsystems 609, the I/O subsystems 609 can be by the input/output peripherals in equipment, such as touch-screen 612
With other input/control devicess 610, Peripheral Interface 603 is connected to.I/O subsystems 609 can include 6091 He of display controller
For controlling one or more input controllers 6092 of other input/control devicess 610.Wherein, one or more input controls
Device 6092 processed receives electric signal from other input/control devicess 610 or sends electric signal to other input/control devicess 610,
Other input/control devicess 610 can include physical button (pressing button, rocker buttons etc.), dial, slide switch, behaviour
Vertical pole, click on roller.What deserves to be explained is input controller 6092 can with it is following any one be connected:Keyboard, infrared port,
The instruction equipment of USB interface and such as mouse.
Touch-screen 612, the touch-screen 612 are the input interface and output interface between user terminal and user, can
User is shown to depending on output, visual output can include figure, text, icon, video etc..
Display controller 6091 in I/O subsystems 609 receives electric signal from touch-screen 612 or is sent out to touch-screen 612
Electric signals.Touch-screen 612 detects the contact on touch-screen, and the contact detected is converted to and shown by display controller 6091
The interaction of user interface object on touch-screen 612, that is, realize human-computer interaction, the user interface being shown on touch-screen 612
Icon that object can be the icon of running game, be networked to corresponding network etc..What deserves to be explained is equipment can also include light
Mouse, light mouse is not show the touch sensitive surface visually exported, or the extension of the touch sensitive surface formed by touch-screen.
RF circuits 605, are mainly used for establishing the communication of mobile phone and wireless network (i.e. network side), realize mobile phone and wireless network
The data receiver of network and transmission.Such as transmitting-receiving short message, Email etc..Specifically, RF circuits 605 receive and send RF letters
Number, RF signals are also referred to as electromagnetic signal, and RF circuits 605 convert electrical signals to electromagnetic signal or electromagnetic signal is converted to telecommunications
Number, and communicated by the electromagnetic signal with communication network and other equipment.RF circuits 605 can include being used to perform
The known circuit of these functions, it includes but not limited to antenna system, RF transceivers, one or more amplifiers, tuner, one
A or multiple oscillators, digital signal processor, CODEC (COder-DECoder, coder) chipset, user identifier mould
Block (Subscriber Identity Module, SIM) etc..
Voicefrequency circuit 606, is mainly used for receiving voice data from Peripheral Interface 603, which is converted to telecommunications
Number, and the electric signal is sent to loudspeaker 611.
Loudspeaker 611, for the voice signal for receiving mobile phone from wireless network by RF circuits 605, is reduced to sound
And play the sound to user.
Power management chip 608, the hardware for being connected by CPU602, I/O subsystem and Peripheral Interface 603 are supplied
Electricity and power management.
Control device, storage medium and the mobile terminal of the application service provided in above-described embodiment can perform the application and appoint
The control method for the application service that meaning embodiment is provided, possesses and performs the corresponding function module of this method and beneficial effect.Not
The ins and outs of detailed description in the above-described embodiments, reference can be made to the control for the application service that the application any embodiment is provided
Method.
The technical principle that above are only the preferred embodiment of the application and used.The application is not limited to spy described here
Determine embodiment, the various significant changes that can carry out for a person skilled in the art, readjust and substitute all without departing from
The protection domain of the application.Therefore, although being described in further detail by above example to the application, this Shen
Above example please be not limited only to, in the case where not departing from the application design, other more equivalence enforcements can also be included
Example, and scope of the present application is determined by the scope of claim.
Claims (10)
- A kind of 1. control method of application service, it is characterised in that including:Before mode is restarted according to setting and restarts destination service, the information on services of the destination service is obtained;Judge whether the information on services meets that condition is restarted in setting;If the information on services meets that condition is restarted in setting, the operation for restarting the destination service is performed;If the information on services, which is unsatisfactory for setting, restarts condition, the destination service is forbidden to restart.
- 2. according to the method described in claim 1, it is characterized in that, the information on services is including corresponding to service name, service User identifier, process identification (PID) and application Bao Mingzhong at least one of.
- 3. method according to claim 1 or 2, it is characterised in that it is described according to setting restart mode restart target clothes Before business, obtaining the information on services of the destination service includes:Setup parameter value is returned in the first setting function for passing through called to take before restarting destination service, to obtain the target The information on services of business, the setup parameter restart the destination service for instruction, and the first setting function includes onstart Function or onStartCommand functions.
- 4. method according to claim 1 or 2, it is characterised in that it is described according to setting restart mode restart target clothes Before business, obtaining the information on services of the destination service includes:By calling the 3rd setting function for being used to start service to restart in the second setting function for stopping service Before destination service, the information on services of the destination service is obtained, the second setting function includes onDestroy functions, institute Stating the 3rd setting function includes startService functions.
- 5. according to the method described in claim 3, it is characterized in that, the setup parameter value include START_STICKY or START_REDELIVER_INTENT。
- 6. according to the method described in claim 2, it is characterized in that, described judge whether the destination service meets that setting is restarted Condition includes:Judge the information on services whether in the first setting white list;Correspondingly,If the information on services meets that condition is restarted in setting, the operation that the destination service is restarted in execution includes:If institute Service name is stated in the first setting white list, then performs the operation for restarting the destination service;If the information on services is unsatisfactory for setting and restarts condition, forbid the destination service restart including:If the service name in the first setting white list, does not forbid the destination service to restart;Alternatively,It is described to judge whether the information on services meets that setting is restarted condition and included:Judge the user identifier, process identification (PID) and/ Or whether application bag name is in the second setting white list;Correspondingly,If the information on services meets that condition is restarted in setting, the operation that the destination service is restarted in execution includes:If institute User identifier, process identification (PID) and/or application bag name are stated in the second setting white list, then performs the behaviour for restarting the destination service Make;If the information on services is unsatisfactory for setting and restarts condition, forbid the destination service restart including:If the user identifier, process identification (PID) and/or application bag name in the second setting white list, do not forbid the target to take Business is restarted.
- 7. according to the method described in claim 6, it is characterized in that, further include:The first setting white list and the second setting white list are locally obtained from server or mobile terminal, described first sets Ding white ware list and the second setting white list are deposited in the mode that terminal local stores including file mode storage or database mode Storage.
- A kind of 8. control device of application service, it is characterised in that including:Information on services acquisition module, for before mode is restarted according to setting and restarts destination service, obtaining the destination service Information on services;Condition judgment module is restarted, for judging whether the information on services meets that condition is restarted in setting;Destination service restarts module, if meeting that condition is restarted in setting for the information on services, the target clothes are restarted in execution The operation of business;Destination service restarts disabled module, if being unsatisfactory for setting for the information on services restarts condition, forbids the target Server resets.
- 9. a kind of computer-readable recording medium, is stored thereon with computer program, it is characterised in that the program is held by processor The control method of the application service as described in any in claim 1-7 is realized during row.
- 10. a kind of mobile terminal, including memory, processor and storage are on a memory and the calculating that can run on a processor Machine program, it is characterised in that the processor is realized as described in any in claim 1-7 when performing the computer program The control method of application service.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711168326.5A CN107943270B (en) | 2017-11-21 | 2017-11-21 | Application service control method and device, storage medium and mobile terminal |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711168326.5A CN107943270B (en) | 2017-11-21 | 2017-11-21 | Application service control method and device, storage medium and mobile terminal |
Publications (2)
Publication Number | Publication Date |
---|---|
CN107943270A true CN107943270A (en) | 2018-04-20 |
CN107943270B CN107943270B (en) | 2020-09-01 |
Family
ID=61930522
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201711168326.5A Active CN107943270B (en) | 2017-11-21 | 2017-11-21 | Application service control method and device, storage medium and mobile terminal |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN107943270B (en) |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110347550A (en) * | 2019-06-10 | 2019-10-18 | 烽火通信科技股份有限公司 | The safety monitoring processing method and system of Android system terminal equipment |
CN112099757A (en) * | 2020-09-21 | 2020-12-18 | 珠海格力电器股份有限公司 | Application keep-alive method and device |
CN114006902A (en) * | 2021-10-27 | 2022-02-01 | 北京百度网讯科技有限公司 | Cloud mobile phone restarting method, device, equipment and storage medium |
CN114442790A (en) * | 2022-02-24 | 2022-05-06 | 中汽创智科技有限公司 | Resource management method and system for idle automobile application service |
CN115344860A (en) * | 2022-07-28 | 2022-11-15 | 荣耀终端有限公司 | Method for managing application program and electronic equipment |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105955817A (en) * | 2016-04-15 | 2016-09-21 | 北京小米移动软件有限公司 | Service process control method and device |
CN106095517A (en) * | 2016-06-28 | 2016-11-09 | 宇龙计算机通信科技(深圳)有限公司 | The method and device that a kind of end application runs |
CN106383727A (en) * | 2016-09-05 | 2017-02-08 | 深圳市金立通信设备有限公司 | Recent task list clearing optimization method and terminal |
CN106791090A (en) * | 2016-12-20 | 2017-05-31 | 广东欧珀移动通信有限公司 | A kind of mobile terminal restarts control method, device and mobile terminal |
CN107301086A (en) * | 2017-06-21 | 2017-10-27 | 深圳市万普拉斯科技有限公司 | Process handling method, device, mobile terminal and computer read/write memory medium |
-
2017
- 2017-11-21 CN CN201711168326.5A patent/CN107943270B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105955817A (en) * | 2016-04-15 | 2016-09-21 | 北京小米移动软件有限公司 | Service process control method and device |
CN106095517A (en) * | 2016-06-28 | 2016-11-09 | 宇龙计算机通信科技(深圳)有限公司 | The method and device that a kind of end application runs |
CN106383727A (en) * | 2016-09-05 | 2017-02-08 | 深圳市金立通信设备有限公司 | Recent task list clearing optimization method and terminal |
CN106791090A (en) * | 2016-12-20 | 2017-05-31 | 广东欧珀移动通信有限公司 | A kind of mobile terminal restarts control method, device and mobile terminal |
CN107301086A (en) * | 2017-06-21 | 2017-10-27 | 深圳市万普拉斯科技有限公司 | Process handling method, device, mobile terminal and computer read/write memory medium |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110347550A (en) * | 2019-06-10 | 2019-10-18 | 烽火通信科技股份有限公司 | The safety monitoring processing method and system of Android system terminal equipment |
CN112099757A (en) * | 2020-09-21 | 2020-12-18 | 珠海格力电器股份有限公司 | Application keep-alive method and device |
CN114006902A (en) * | 2021-10-27 | 2022-02-01 | 北京百度网讯科技有限公司 | Cloud mobile phone restarting method, device, equipment and storage medium |
CN114006902B (en) * | 2021-10-27 | 2023-08-11 | 北京百度网讯科技有限公司 | Cloud mobile phone restarting method, device, equipment and storage medium |
CN114442790A (en) * | 2022-02-24 | 2022-05-06 | 中汽创智科技有限公司 | Resource management method and system for idle automobile application service |
CN115344860A (en) * | 2022-07-28 | 2022-11-15 | 荣耀终端有限公司 | Method for managing application program and electronic equipment |
CN115344860B (en) * | 2022-07-28 | 2023-10-10 | 荣耀终端有限公司 | Method for managing application program and electronic equipment |
Also Published As
Publication number | Publication date |
---|---|
CN107943270B (en) | 2020-09-01 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107943270A (en) | Control method, device and the storage medium and mobile terminal of application service | |
CN107844342A (en) | Management-control method, device and the storage medium and mobile terminal of application program keep-alive | |
CN107395889B (en) | Method and device for reducing power consumption of mobile terminal, storage medium and mobile terminal | |
CN107944259A (en) | Using the management-control method of startup, device and storage medium and mobile terminal | |
CN106569585B (en) | A kind of method and terminal managing program process | |
CN107844341B (en) | Process starting control method and device, storage medium and mobile terminal | |
CN107861773A (en) | Associate management-control method, device, storage medium and the mobile terminal started | |
CN107748685A (en) | Application program launching control method, device, terminal device and storage medium | |
CN107783803B (en) | System optimization method and device of intelligent terminal, storage medium and intelligent terminal | |
CN107957913A (en) | Associate management-control method, device, storage medium and the mobile terminal started | |
CN107861830A (en) | Detection method, device, storage medium and the mobile terminal of application crash | |
CN107748698A (en) | Start control method, device, storage medium and the terminal of application with broadcast mode | |
CN107944257A (en) | Start control method, device, storage medium and the terminal of application with method of service | |
CN107831886B (en) | Control method and device for associated starting application, storage medium and intelligent terminal | |
CN107450838B (en) | Response method and device of black screen gesture, storage medium and mobile terminal | |
CN106484461A (en) | Service keepalive method and device in intelligent terminal | |
CN107957905A (en) | Method, apparatus, storage medium and the intelligent terminal of self-starting are applied in limitation | |
CN108536488A (en) | Using starting guide method, apparatus, storage medium and terminal device | |
CN107943269A (en) | Schedule job control method, device, terminal device and storage medium | |
CN107423064A (en) | Message treatment method, device, terminal device and storage medium | |
CN108093451A (en) | Control method, device and the storage medium and mobile terminal of random access | |
CN107885588A (en) | Control method, device and the storage medium and mobile terminal of application service | |
CN106528163A (en) | Page switching method and device | |
CN106815534A (en) | A kind of method for protecting privacy of user, device and mobile terminal | |
CN107862203A (en) | Control method, device, storage medium and the terminal of application program |
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 | ||
CB02 | Change of applicant information | ||
CB02 | Change of applicant information |
Address after: Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18 Applicant after: GUANGDONG OPPO MOBILE TELECOMMUNICATIONS Corp.,Ltd. Address before: Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18 Applicant before: GUANGDONG OPPO MOBILE TELECOMMUNICATIONS Corp.,Ltd. |
|
GR01 | Patent grant | ||
GR01 | Patent grant |