CN110895473A - Self-starting keep-alive system and method based on android mobile device - Google Patents

Self-starting keep-alive system and method based on android mobile device Download PDF

Info

Publication number
CN110895473A
CN110895473A CN201810972699.6A CN201810972699A CN110895473A CN 110895473 A CN110895473 A CN 110895473A CN 201810972699 A CN201810972699 A CN 201810972699A CN 110895473 A CN110895473 A CN 110895473A
Authority
CN
China
Prior art keywords
class
android
starting
alive
self
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
Application number
CN201810972699.6A
Other languages
Chinese (zh)
Other versions
CN110895473B (en
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.)
Shandong Huaruan Goldencis Software Co Ltd
Original Assignee
Shandong Huaruan Goldencis Software 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 Shandong Huaruan Goldencis Software Co Ltd filed Critical Shandong Huaruan Goldencis Software Co Ltd
Priority to CN201810972699.6A priority Critical patent/CN110895473B/en
Publication of CN110895473A publication Critical patent/CN110895473A/en
Application granted granted Critical
Publication of CN110895473B publication Critical patent/CN110895473B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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
    • G06F9/44505Configuring for program initiating, e.g. using registry, configuration files
    • 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
    • G06F9/44594Unloading
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Stored Programmes (AREA)
  • Telephone Function (AREA)

Abstract

The invention discloses a self-starting keep-alive system and a self-starting keep-alive method based on android mobile equipment, wherein the self-starting keep-alive system comprises a service class and an activity class which are defined, and a configuration file is automatically generated by the system in the process of defining the class; declaring the defined service class and activity class in a configuration file; setting a transparent default desktop, and then jumping to a system default desktop; displaying the application software in a running module in the android device; the method comprises the steps of keep-alive self-starting, wherein when the android device is restarted, a process is forcibly killed or one-key cleaning is carried out, application software in a running service module displayed in an interface is protected to survive, and therefore three mechanisms of starting self-starting, background continuous running of a program and process keep-alive and prevention and killing of the application are integrated.

Description

Self-starting keep-alive system and method based on android mobile device
Technical Field
The invention relates to the technical field of mobile internet, in particular to a self-starting keep-alive system and a self-starting keep-alive method based on android mobile equipment.
Background
At present, for the running fluency of respective systems and the safety of mobile phones, all mobile phone manufacturers on the market basically can always live in the background, and moreover, some OS systems can carry out white list and self-starting default release on APP with large user size, but for common third-party applications, the common third-party applications cannot always be released on various OS systems deeply customized by domestic mobile phone manufacturers based on Android
Survivability and power-on self-start.
In the existing solution, a user is generally guided to start a self-starting switch on various OS systems by manual guidance, or the APP of the user is forcibly brushed into the system by adopting a root mode to be used as a system application, and the user just adopts various modes similar to a home barrel APP for mutual awakening and various multi-process and double-process keep-alive modes.
Although self-starting and process keep-alive on partial equipment can be finally solved through the method in the scheme, the scheme has great limitations and poor adaptability to various Android equipment, when one-key cleaning or process killing is carried out on the Android high-version, both double-process guard and multi-process guard can be killed, and in addition, the root mode is adopted to achieve difficulty and complexity, because the safety control of the Android mobile phone by domestic mobile phone manufacturers is more and more strict, the steps of obtaining the root authority are more and more complicated, and the time cost and the implementation cost are too high for developers of third-party APP.
Disclosure of Invention
Technical problem to be solved
Aiming at the defects of the prior art, the invention provides a self-starting protection system and a self-starting protection method based on android mobile equipment, solves the problems of complicated adaptation and high difficulty of various android equipment, and realizes integration of three mechanisms of starting self-starting, background continuous running of programs and process keep-alive and prevention and killing of applications.
(II) technical scheme
In order to achieve the purpose, the invention is realized by the following technical scheme: a self-starting keep-alive system based on android mobile equipment comprises:
the definition module is used for defining a service class and an activity class, and a system automatically generates a configuration file in the process of defining the class module;
the configuration module is used for defining the transparent android system starter in the configuration file of the activity class;
the setting module is used for setting the defined transparent android system starter as a default starter, and the desktop is displayed as a default desktop;
the jumping module jumps to a default desktop of the android device system by applying an application programming interface in the android system in the activity class;
the display module starts the defined service class after the jump is completed so as to display the application software in the android device;
and the keep-alive self-starting module is used for protecting the application software in the running service module displayed in the interface to survive when equipment is restarted, a forced killing process or one-key cleaning is carried out.
Preferably, the methods of rewriting the life cycle of the service class are performed in the service class declaration.
Preferably, the configuration module is further configured to declare a defined service class and an activity class in the configuration file, where the service class declaration is used to detect the service class, and register a process at the same time as the service class declaration, so that a service class running in the system views the effect of self-start keep-alive; changing the theme to a theme that is not displayed at all in the declaration of the activity class to set the activity class to a class that is only allowed to be not displayed.
Preferably, seven methods of rewriting the life cycle of the activity class in the activity class, and a log printing operation is performed in several methods of rewriting the life cycle of the service class for quick troubleshooting.
A self-starting keep-alive method based on an android mobile device comprises the following steps:
defining a service class and an activity class, and automatically generating a configuration file by a system in the process of defining the class;
defining the transparent android system starter in the configuration file of the activity class;
setting a default desktop, and after application software on the desktop sets default attributes of the desktop, clicking a Home key on android equipment or restarting a mobile phone, and selecting a defined transparent android system starter, wherein the desktop is set as the default desktop;
jumping to a default desktop, and jumping to the default desktop of the android device system by applying an application programming interface in the android system in the activity class;
the application software is displayed in a running module in the android device, and the application software is displayed in the android device by starting the defined service class;
the method comprises the steps of keep-alive self-starting, wherein when the android device is restarted, forced killing processes or cleaned by one key, application software in the running service module displayed in the interface is protected to survive.
Preferably, the methods of rewriting the life cycle of the service class are performed in the service class declaration.
Preferably, the configuration file is further configured to declare a defined service class and an activity class, where the service class declaration is used to detect the service class, and a process is registered at the same time as the service class declaration, so that a running service class in the system views the effect of self-start keep-alive; changing the theme to a theme that is not displayed at all in the declaration of the activity class to set the activity class to a class that is only allowed to be not displayed.
Preferably, seven methods of rewriting the life cycle of the activity class in the activity class, and a log printing operation is performed in several methods of rewriting the life cycle of the service class for quick troubleshooting.
(III) advantageous effects
The invention has the following beneficial effects:
1. the Root authority is not required to be acquired by the android device, and only the default desktop needs to be replaced on the android device;
2. hard requirements on android equipment hardware, an android system-based deep customization system of each large mobile phone manufacturer and installed application software are not required;
3. the stability is good, and the condition that the executed task can be deleted by shutdown or forced killing does not exist;
4. the adaptability is good, and functions such as keep-alive self-starting prevention and killing can be realized as long as a default desktop can be set;
5. powerful, several kinds of function unifications such as start-up self-starting, process keep-alive, service are prevented killing can be satisfied simultaneously in a function setting.
Drawings
FIG. 1 is a flow chart of a self-starting keep-alive system based on an android mobile device;
FIG. 2 is a flow chart of a self-starting keep-alive method based on an android mobile device;
FIG. 3 illustrates a method of use of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Android, Android: the operating system is a Linux-based free and open source code operating system, is mainly used for mobile equipment such as smart phones and tablet computers, and is led and developed by Google corporation and the open mobile phone alliance.
APP, application software: the mobile phone software mainly refers to software installed on a smart phone, and overcomes the defects and individuation of an original system.
And OS: and (4) operating the system.
Theme, topic: theme for setting each android project and various project classes
Subject matter not shown at all: completely undisplayed theme for setting each android item
intent-filter: the label in the Android project configuration file is used for setting one or more filters for the component.
action: declaring the operation that the component can perform, the value must be a string about the operation and not a class constant.
category: to declare the Intent type of acceptance.
Root, a unique super user existing in UNIX system, Linux distribution such as Ubuntu and archlinux, and Android system.
Android system starter: the android desktop starting method is one of main program components in the android system, and the android desktop cannot be started if no android system starter exists in the android system.
Embodiments of the invention: referring to fig. 1, a self-starting keep-alive system based on an android mobile device includes:
the system comprises a definition module, a definition module and a configuration module, wherein the definition module is used for defining a service class and an activity class, a system automatically generates a configuration file in the process of defining the class module, the service class in an android needs to be defined, several methods in the life cycle of the service class are rewritten in the service class, related log printing operation and related functions are executed in each rewritten method, and the purpose of the log printing operation is to rapidly debug and serve as evidence after the log printing operation is disputed; defining an activity class in an android, rewriting seven methods in the lifecycle of the class, and executing corresponding logic in each method.
The configuration module is used for declaring the defined service class and activity class in the configuration file, the purpose of declaring the service class is to enable the system to detect the service so as to execute a method defined to be realized in the service class, and simultaneously, a process is registered in the declared service class so that the running service modules in the system can be more conveniently viewed when package activity and self-starting effect are viewed; setting the theme of the activity class in an activity class declaration file as a completely undisplayed theme, setting the configuration to set the activity class as a class which is only allowed to be undisplayed, so as to realize a method only in a life cycle of the activity class, setting one or more filters for components by using an intent-filter tag in a configuration file after the activity class is run but nothing is displayed, and adding an action and a category attribute in the filter for defining a transparent android system launcher.
The method comprises the steps that a setting module runs on android equipment after application software for defining attributes of an android system starter is set, a Home key is clicked or a mobile phone is restarted, a popup window of a default android system starter is selected by a user, the user can select a self-defined transparent android system starter, and the activity class is set to be a class which is only allowed to be not displayed in a step configuration module, so that a default desktop of the current system can be directly displayed. Therefore, the default desktop displayed as a system can be seen, and the actually set current transparent android system starter is the transparent android system starter customized by a developer, so that the purposes of keeping alive and self-starting are achieved.
And the jumping module is used for realizing the operation of jumping to each android equipment system with a default desktop in the activity class defined in the definition class module, finding the package name and the starting class name of the default transparent android system starter, and carrying out loading jumping by using an application programming interface provided by android.
And the display module and the transparent android system starter start the declared service class in the configuration module after the definition of the transparent android system starter is completed, so that the main service and the main process of the application software are displayed in the running service module of the android device.
And the keep-alive self-starting module is used for protecting the application software in the running service module displayed in the interface to survive when equipment is restarted, a forced killing process or one-key cleaning is carried out.
Embodiments of the invention: referring to fig. 2, a self-starting keep-alive method based on an android mobile device includes:
defining a service class and an activity class, automatically generating a configuration file by a system in the process of defining a class module, defining the service class in an android, rewriting a plurality of methods in the life cycle of the service class in the service class, and executing related log printing operation and related functions in each rewritten method, wherein the purpose of the log printing operation is to rapidly debug and serve as evidence after the log printing operation is disputed; defining an activity class in an android, rewriting seven methods in the lifecycle of the class, and executing corresponding logic in each method.
The method comprises the steps that defined service classes and activity classes are declared in a configuration file, the purpose of declaring the service classes is to enable a system to detect the service so as to execute a method defined to be realized in the service classes, and simultaneously, a process is registered in the declared service classes so that running service modules in the system can be more conveniently viewed when package activity and self-starting effects are viewed; setting the theme of the activity class in an activity class declaration file as a completely undisplayed theme, setting the configuration to set the activity class as a class which is only allowed to be undisplayed, so as to realize a method only in a life cycle of the activity class, setting one or more filters for components by using an intent-filter tag in a configuration file after the activity class is run but nothing is displayed, and adding commands and classification attributes in the filters for defining the transparent android system launcher.
The method comprises the steps of setting a default desktop, running application software defining attributes of an android system starter on android equipment, clicking a Home key or restarting a mobile phone to enable a user to select a popup window of the default android system starter, and checking a self-defined android system starter. Therefore, the default desktop displayed as a system can be seen, and the actually set current transparent android system starter is the transparent android system starter customized by a developer, so that the purposes of keeping alive and self-starting are achieved.
Jumping to a default desktop, realizing the operation of jumping to each android equipment system with the default desktop in an activity class defined in a definition class module, finding the package name and the starting class name of a default transparent android system starter, and carrying out loading jumping by using an application programming interface provided by android.
The application software is displayed in a running module of the android device, and the definition of the transparent android system starter is completed and then the declared service class in the configuration module is opened, so that the main service and the main process of the application software are displayed in the running service module of the android device.
And the keep-alive self-starting is used for protecting the application software in the running service module displayed in the interface to survive when equipment is restarted, a forced killing process or one-key cleaning is carried out.
The use method of the invention comprises the following steps: referring to fig. 1-3, in a first step, a new android project is created, and then a desktop setup activity class and a service class are declared, which are declared and registered in a configuration file.
And secondly, adding a default desktop name and a starting class name of the current equipment according to the current mobile phone model in the desktop setting class.
And thirdly, installing the application software on the android device, clicking a home key or restarting the device, selecting a default desktop, and checking the application of the device as the default desktop.
And fourthly, after the third step is finished, the current default desktop is the desktop setting class set in the second step, and the self-defined desktop setting class is the class which only executes the method and does not display the interface, so that the current desktop can directly execute the jump to the default desktop of the factory self-provided mobile phone according to the current mobile phone model, the practical default desktop is the self-defined transparent android system starter, and the desktop is seen in sense and is still self-provided by the original system.

Claims (8)

1. A self-starting keep-alive system based on an android mobile device, comprising:
the definition module is used for defining a service class and an activity class, and a system automatically generates a configuration file in the process of defining the class module;
the configuration module is used for defining the transparent android system starter in the configuration file of the activity class;
the setting module is used for setting the defined transparent android system starter as a default starter, and the desktop is displayed as a default desktop;
the jumping module jumps to a default desktop of the android device system by applying an application programming interface in the android system in the activity class;
the display module starts the defined service class after the jump is completed so as to display the application software in the android device;
and the keep-alive self-starting module is used for protecting the application software in the running service module displayed in the interface to survive when equipment is restarted, a forced killing process or one-key cleaning is carried out.
2. The android mobile device-based self-starting keep-alive system of claim 1, wherein: the method for rewriting the life cycle of the service class in the defined service class, and the method for rewriting the life cycle of the service class in the service class declaration.
3. The android mobile device-based self-starting keep-alive system of claim 1, wherein: the configuration module is further used for declaring a defined service class and an activity class in the configuration file, wherein the service class declaration is used for detecting the service class, and a process is registered at the same time of the service class declaration and is used for checking the self-starting keep-alive effect of the service class running in the system; changing the theme to a theme that is not displayed at all in the declaration of the activity class to set the activity class to a class that is only allowed to be not displayed.
4. The android mobile device-based self-starting keep-alive system of claim 1, wherein: seven methods of rewriting the activity class lifecycle in the activity class, and performing a log printing operation among the methods of rewriting the service class lifecycle for quick troubleshooting.
5. A self-starting keep-alive method based on an android mobile device is characterized in that:
defining a service class and an activity class, and automatically generating a configuration file by a system in the process of defining the class;
defining the transparent android system starter in the configuration file of the activity class;
setting a default desktop, and after application software on the desktop sets default attributes of the desktop, clicking a Home key on android equipment or restarting a mobile phone, and selecting a defined transparent android system starter, wherein the desktop is set as the default desktop;
jumping to a default desktop, and jumping to the default desktop of the android device system by applying an application programming interface in the android system in the activity class;
the application software is displayed in a running module in the android device, and the application software is displayed in the android device by starting the defined service class;
the method comprises the steps of keep-alive self-starting, wherein when the android device is restarted, forced killing processes or cleaned by one key, application software in the running service module displayed in the interface is protected to survive.
6. The android mobile device-based self-starting keep-alive method of claim 5, wherein: the method for rewriting the life cycle of the service class in the defined service class, and the method for rewriting the life cycle of the service class in the service class declaration.
7. The android mobile device-based self-starting keep-alive method of claim 5, wherein: the configuration file is also used for declaring a defined service class and an activity class, the service class declaration is used for detecting the service class, and a process is registered at the same time of the service class declaration and is used for checking the self-starting keep-alive effect of the service class running in the system; changing the theme to a theme that is not displayed at all in the declaration of the activity class to set the activity class to a class that is only allowed to be not displayed.
8. The android mobile device-based self-starting keep-alive method of claim 5, wherein: seven methods of rewriting the activity class lifecycle in the activity class, and performing a log printing operation among the methods of rewriting the service class lifecycle for quick troubleshooting.
CN201810972699.6A 2018-08-24 2018-08-24 Self-starting keep-alive system and method based on android mobile equipment Active CN110895473B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810972699.6A CN110895473B (en) 2018-08-24 2018-08-24 Self-starting keep-alive system and method based on android mobile equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810972699.6A CN110895473B (en) 2018-08-24 2018-08-24 Self-starting keep-alive system and method based on android mobile equipment

Publications (2)

Publication Number Publication Date
CN110895473A true CN110895473A (en) 2020-03-20
CN110895473B CN110895473B (en) 2023-05-02

Family

ID=69784739

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810972699.6A Active CN110895473B (en) 2018-08-24 2018-08-24 Self-starting keep-alive system and method based on android mobile equipment

Country Status (1)

Country Link
CN (1) CN110895473B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111901677A (en) * 2020-07-24 2020-11-06 海信视像科技股份有限公司 Method for uniformly controlling process starting and display equipment
CN115033305A (en) * 2022-06-27 2022-09-09 Oppo广东移动通信有限公司 Application identification method and device, storage medium and electronic equipment

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050080940A1 (en) * 2003-10-09 2005-04-14 International Business Machines Corporation System and method for dynamically assigning I/O priority
CA2614795A1 (en) * 2006-12-27 2008-06-27 Yaron Mayer System and method for improving the efficiency, comfort, and/or reliability in operating systems, such as for example windows
CN105045643A (en) * 2015-09-01 2015-11-11 北京奇虎科技有限公司 Starting method and device of Launchers in Android system
WO2016059564A1 (en) * 2014-10-17 2016-04-21 Hand Me In Partial access screen lock
CN106537288A (en) * 2016-10-21 2017-03-22 北京小米移动软件有限公司 Application autostart control method and device
CN106845218A (en) * 2016-12-22 2017-06-13 山东华软金盾软件股份有限公司 A kind of word auditing method of mobile device

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050080940A1 (en) * 2003-10-09 2005-04-14 International Business Machines Corporation System and method for dynamically assigning I/O priority
CA2614795A1 (en) * 2006-12-27 2008-06-27 Yaron Mayer System and method for improving the efficiency, comfort, and/or reliability in operating systems, such as for example windows
WO2016059564A1 (en) * 2014-10-17 2016-04-21 Hand Me In Partial access screen lock
CN105045643A (en) * 2015-09-01 2015-11-11 北京奇虎科技有限公司 Starting method and device of Launchers in Android system
CN106537288A (en) * 2016-10-21 2017-03-22 北京小米移动软件有限公司 Application autostart control method and device
CN106845218A (en) * 2016-12-22 2017-06-13 山东华软金盾软件股份有限公司 A kind of word auditing method of mobile device

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111901677A (en) * 2020-07-24 2020-11-06 海信视像科技股份有限公司 Method for uniformly controlling process starting and display equipment
CN115033305A (en) * 2022-06-27 2022-09-09 Oppo广东移动通信有限公司 Application identification method and device, storage medium and electronic equipment

Also Published As

Publication number Publication date
CN110895473B (en) 2023-05-02

Similar Documents

Publication Publication Date Title
CN106648863B (en) Android application installation package, application target process keep-alive method and system
US9355017B2 (en) Automated error checking system for a software application and method therefor
CN102236621B (en) Computer interface information configuration system and method
CN102999387B (en) Process running gear and method
CN105183457B (en) Method and device for monitoring interface life cycle callback
CN106502747A (en) A kind of method of application upgrade and mobile terminal
CN104615462B (en) Cross-platform Mobile solution generation service end and system
US8423970B2 (en) Method, computer program product, and hardware product for handling breakpoints in an asynchronous debug model
US11960869B2 (en) Android penetration method and device for implementing silent installation based on accessibility services
CN105068881A (en) Method, device and system for repairing abnormal operation of application program
CN111382048B (en) Management method and device for mobile equipment on true machine test platform
CN112286656B (en) Applet simulation method, apparatus, electronic device, and computer-readable storage medium
CN104125504B (en) Deployment method, device and system based on continuous integration
CN105740139B (en) A kind of debugging embedded software method based on virtual environment
CN103077111A (en) Method and system for locating continuous integration failed case
CN110895473A (en) Self-starting keep-alive system and method based on android mobile device
WO2016037553A1 (en) Method and apparatus for closing application program
CN113051088B (en) Program loading method, device, equipment and computer readable medium
WO2018094908A1 (en) Method and device for waking application program of terminal
CN109634659A (en) Method, apparatus, equipment and the storage medium that a kind of couple of BMC is controlled
CN104484176B (en) A kind of Android system window object acquisition methods and device
WO2016003850A1 (en) Rule-based activation of behaviors in an extensible software application
CN104317685A (en) Starting method of calculator system
CN105760208A (en) Computer program compiling method and apparatus
CN106126425B (en) Function traversal method and system based on Android automated test frame

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
GR01 Patent grant
GR01 Patent grant
PP01 Preservation of patent right

Effective date of registration: 20231113

Granted publication date: 20230502

PP01 Preservation of patent right