CN112306576B - Method for modifying built-in number of android device application program - Google Patents

Method for modifying built-in number of android device application program Download PDF

Info

Publication number
CN112306576B
CN112306576B CN202011211121.2A CN202011211121A CN112306576B CN 112306576 B CN112306576 B CN 112306576B CN 202011211121 A CN202011211121 A CN 202011211121A CN 112306576 B CN112306576 B CN 112306576B
Authority
CN
China
Prior art keywords
storage
android
script
modifying
text file
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.)
Active
Application number
CN202011211121.2A
Other languages
Chinese (zh)
Other versions
CN112306576A (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.)
Shenzhen Sed Wireless Communication Technology Co ltd
Original Assignee
Shenzhen Sed Wireless Communication Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Sed Wireless Communication Technology Co ltd filed Critical Shenzhen Sed Wireless Communication Technology Co ltd
Priority to CN202011211121.2A priority Critical patent/CN112306576B/en
Publication of CN112306576A publication Critical patent/CN112306576A/en
Application granted granted Critical
Publication of CN112306576B publication Critical patent/CN112306576B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

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
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/382Information transfer, e.g. on bus using universal interface adapter
    • G06F13/385Information transfer, e.g. on bus using universal interface adapter for adaptation of a particular data processing system to different peripheral devices
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/16File or folder operations, e.g. details of user interfaces specifically adapted to file systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/16File or folder operations, e.g. details of user interfaces specifically adapted to file systems
    • G06F16/162Delete operations
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/62Protecting access to data via a platform, e.g. using keys or access control rules
    • G06F21/6218Protecting access to data via a platform, e.g. using keys or access control rules to a system of files or objects, e.g. local or distributed file system or database
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2213/00Indexing scheme relating to interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F2213/0042Universal serial bus [USB]
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Abstract

The invention discloses a method for modifying an application program built-in number of an android device, which comprises the following steps: s1, starting an App, and enabling a system to execute initialization operation by calling an onCreate method of a ContentProvider through Application of the Application; s2, connecting the PC end with the android terminal; s3, executing the script and obtaining the number; s4, modifying the acquired storage number text, and then executing a script for setting a storage file to store the storage number text in the android terminal; s5, after the script is executed, the device is automatically restarted, the number takes effect, the built-in number of the android device can be conveniently modified through the PC, other third-party apks are not required to be installed, network requirements and restrictions are avoided, the operation is simple, the built-in number of the android device can be quickly obtained and modified only by executing the script, and the data are visual.

Description

Method for modifying built-in number of android device application program
Technical Field
The invention relates to the technical field of modification of built-in numbers of application programs of android systems, in particular to a method for modifying built-in numbers of application programs of android devices.
Background
At present, in the android device application, the number of the dialing application is stored in a database mode, the contact application creates a folder storing the number and a database file in a packet name folder generated by a corresponding app under a data/data directory of a file system, the file format is db, then the data is provided for other applications, such as the dialing application for inquiring and modifying, and the PC is connected with the android device through a USB to directly modify the number data under a data/data path without permission.
In order to solve the problem that the built-in number of the application of the android device cannot be directly modified after the USB connection is used by the PC, the common technology in the market is to install mobile phone management software such as a mobile phone assistant on the PC computer, then connect the USB of the android device to the PC computer, obtain corresponding data access permission by installing a corresponding mobile phone assistant app on the mobile phone, and then operate the number data of the installation device across applications by using the contentsreslayer. The method for installing the third-party mobile phone management application is complex, networking operation is required, the efficiency is low, and excessive apps are developed and installed to android equipment, so that the waste of equipment storage resources is easily caused, and the problem of difficult maintenance is caused.
Disclosure of Invention
The invention aims to provide a method for modifying an application program built-in number of an android device, so as to solve the problems in the background technology.
In order to achieve the above purpose, the present invention provides the following technical solutions: a method for modifying the built-in number of an application program of an android device comprises the following steps:
s1, starting an App, and enabling a system to execute initialization operation by calling an onCreate method of a ContentProvider through Application of the Application;
s2, connecting the PC end with the android terminal;
s3, executing the script and obtaining the number;
s4, modifying the acquired storage number text, and then executing a script for setting a storage file to store the storage number text in the android terminal;
s5, after the script is executed, the equipment is automatically restarted, and the number is effective.
Preferably, it is determined whether the text file stored in S1 exists.
Preferably, if present, the process proceeds directly to the subsequent step.
Preferably, if not, a stored text file is created under an externally stored designated path, and the initial number data is written into the stored text, after which the stored file will serve as the source of the application number data.
Preferably, in S2, the PC terminal and the android terminal are connected using USB.
Preferably, in S3, the script for obtaining the stored number text is executed, so that the stored number text in the android terminal can be obtained under the same path of the script, that is, the number data is obtained.
The invention has at least the following beneficial effects:
the method and the device can effectively solve the problem that the PC modifies the built-in number of the application of the android device, and provide a more friendly operation mode for the phenomenon that the non-screen android device cannot be operated through an interface.
The method can conveniently modify the built-in number of the android device through the PC, does not need to install other third-party apks, has no network requirements and restrictions, is simple to operate, can quickly acquire and modify the built-in number of the android device by executing the script, and has visual data. Especially, for the android equipment without a screen or the android equipment which can not be applied through interface operation, the corresponding modification requirement can be better solved.
According to the invention, firstly, the access authority of the file to be modified is released by modifying the storage position of the stored number file, so that the file can be accessed through the adb command of the conventional access android device, then the number data is stored by using the format of txt, the data is more convenient to operate, the software for opening the db file is not required to be additionally installed, and the txt modification number can be opened by using the text editor of the PC. Finally, the invention also encapsulates and integrates the adb command, integrates a plurality of adb commands into the script, reduces the difficulty of number modification maintenance operation, ensures that an operator can finish the operation of modifying the built-in number of the android device without too much related knowledge, and simultaneously reduces the error probability caused by the command problem in the number modification process.
Drawings
FIG. 1 is a schematic block diagram of a PC modified android device built-in number of the present invention;
FIG. 2 is a flow chart of the android device app creation number data of the present invention;
fig. 3 is a flow chart of the PC modified android device application number of the present invention.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present invention, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
Referring to fig. 1-3, the present invention provides a technical solution: a method for modifying the built-in number of an application program of an android device comprises the following steps:
s1, starting an App, and enabling a system to execute initialization operation by calling an onCreate method of a ContentProvider through Application of the Application;
s2, connecting the PC end with the android terminal;
s3, executing the script and obtaining the number;
s4, modifying the acquired storage number text, and then executing a script for setting a storage file to store the storage number text in the android terminal;
s5, after the script is executed, the equipment is automatically restarted, and the number is effective.
And judging whether the text file stored in the S1 exists or not.
If so, directly entering the subsequent step.
If the application number data does not exist, a storage text file is created under an appointed path stored outside, initial number data is written into the storage text, and then the storage file is used as a source of the application number data.
In S2, the PC side and the android terminal are connected using USB.
In S3, executing the script for acquiring the stored number text, the stored number text in the android terminal can be acquired under the same path of the script, namely the number data is acquired.
Compared with the method for operating the number of the android device by using the third party management software, the method for directly root the android device and fully releasing the permission of the android device is more convenient to achieve the method of directly accessing the number storage file, but is safer, is more unfavorable for maintaining the stability of the internal system of the android device, and can not achieve the purpose of quickly modifying the built-in number because the common number storage format of the android system is db file, and the android device can be opened only by installing corresponding software on a PC.
If the data files of other application programs which do not influence the running stability of the android system in the system are required to be modified through the PC, the method can be used, the thought is consistent with the method, the original storage path of the files is changed, the files are stored outside the android device, the files are more beneficial to external access, then the data are operated more easily through modifying the storage format, and the data are operated through adb or an integrated script of the adb.
As shown in fig. 1, in the android terminal, the app application directly performs CRUD deletion and verification operations on the number data in the external storage through the file operation class, connects the operations through the ContentProvider, and provides the operations for other applications to use. The number data is stored in the external storage, and the android terminal can directly operate the number data file in the external storage by an adb command only by opening usb for debugging and connecting the PC with the upper security Zhuo Zhongduan. The invention makes script for integrating adb command, directly executes script for obtaining number storage file, obtains number data file on PC, modifies built-in number according to preset one line of number setting, inputs number data file into android terminal through script for storing storage file into equipment, and then the equipment is restarted automatically, and number data is effective after restarting.
In the method, the invention judges whether a number storage text file in an external storage exists or not by calling a file operation class, if not, the storage text file is created under a specified path of the external storage, initial number data is written into the storage text, then the storage file is used as a source of Application number data, and the ContentProvider indirectly operates the number in the storage file through the file operation class.
As shown in fig. 3, in the present invention, when the built-in number of the android terminal needs to be modified by using the USB connection through the PC, the stored number text in the android terminal can be obtained under the same path of the script, namely, the number data is obtained, as long as the USB is connected with the PC and the android terminal, and then the script for obtaining the stored number text in the present invention is executed. And then modifying the acquired storage number text, then executing a script for setting the storage file to store the storage number text in the android terminal, and automatically restarting the device after the script is executed so as to enable the latest configured number to take effect.
The invention has the following key points:
the method does not use the storage mode of storing the calling number by using the db file of the database which is usually used by An Zhuozhong, and adopts txt text format for storage;
the text storage position is changed from the original system internal storage to external storage so as to increase the accessible authority of the text;
after the USB is connected with the PC and the android device, the terminal number can be directly modified, the limit of common android mobile phones, tablets and the like to be operated through a screen interface is broken, and the method is more friendly and more applicable to the android device without a screen display interface;
the root equipment is not needed, and the stability of the equipment is protected.
For the android device application layer, other applications can still acquire the number data through the contentdesolver, so that the compatibility of the system is maintained.
It is noted that relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus.
Although embodiments of the present invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made therein without departing from the principles and spirit of the invention, the scope of which is defined in the appended claims and their equivalents.

Claims (4)

1. The method for modifying the built-in number of the application program of the android device is characterized by comprising the following steps of:
s1, starting an App, and executing initialization operation;
s2, connecting the PC end with the android terminal by using a USB;
s3, modifying the storage position of the number storage text file of the android terminal, placing the storage position into external storage of the android terminal, executing a script of the number storage text file obtained by the PC terminal from the external storage, obtaining the built-in number of the application program of the android device, and obtaining the stored number text at the PC terminal; before the android terminal is placed in external storage, judging whether a number storage text file in the external storage exists or not by calling a file operation class, if not, creating the number storage text file under a specified path of the external storage, writing initial number data into the number storage text file, and then taking the number storage text file as a source of application number data; the script is made through integration of adb commands, the script for obtaining the number storage file is directly executed, and the number storage text file is obtained on the PC side;
s4, modifying the acquired number storage text file at the PC end, and then executing a script for setting the storage file to store the number storage text file modified by the PC end in the android terminal;
and S5, after the script is executed, automatically restarting the equipment to enable the number to be effective.
2. The method for modifying an android device application built-in number as recited in claim 1, wherein: and S3, executing a script for acquiring the number storage text file, and acquiring the number storage text file in the android terminal under the same path of the script, namely acquiring the number data.
3. The method for modifying an android device application built-in number as recited in claim 1, wherein: in S1, the initialization operation is performed by the system by calling the onCreate method of ContentProvider through Application of the Application.
4. The method for modifying an android device application built-in number as recited in claim 1, wherein: in S1, the number data is stored in txt format.
CN202011211121.2A 2020-11-03 2020-11-03 Method for modifying built-in number of android device application program Active CN112306576B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011211121.2A CN112306576B (en) 2020-11-03 2020-11-03 Method for modifying built-in number of android device application program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011211121.2A CN112306576B (en) 2020-11-03 2020-11-03 Method for modifying built-in number of android device application program

Publications (2)

Publication Number Publication Date
CN112306576A CN112306576A (en) 2021-02-02
CN112306576B true CN112306576B (en) 2023-11-07

Family

ID=74332717

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011211121.2A Active CN112306576B (en) 2020-11-03 2020-11-03 Method for modifying built-in number of android device application program

Country Status (1)

Country Link
CN (1) CN112306576B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114567859B (en) * 2022-01-26 2023-10-13 银盛通信有限公司 Method for batch outside-jacket limit setting of mobile resale system machine cards

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104461760A (en) * 2014-11-28 2015-03-25 北京奇虎科技有限公司 Script issuing method, device and system
CN106776294A (en) * 2016-11-29 2017-05-31 任子行网络技术股份有限公司 Android mobile phone automated testing method and system
CN107870835A (en) * 2017-10-25 2018-04-03 深圳市艾特智能科技有限公司 Hardware adjustment method, system, readable storage medium storing program for executing and intelligent terminal
CN108287784A (en) * 2017-01-09 2018-07-17 腾讯科技(深圳)有限公司 A kind of webpage adjustment method and device

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9298480B2 (en) * 2009-02-26 2016-03-29 Red Hat, Inc. Programmatic editing of text files
US20130290234A1 (en) * 2012-02-02 2013-10-31 Visa International Service Association Intelligent Consumer Service Terminal Apparatuses, Methods and Systems

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104461760A (en) * 2014-11-28 2015-03-25 北京奇虎科技有限公司 Script issuing method, device and system
CN106776294A (en) * 2016-11-29 2017-05-31 任子行网络技术股份有限公司 Android mobile phone automated testing method and system
CN108287784A (en) * 2017-01-09 2018-07-17 腾讯科技(深圳)有限公司 A kind of webpage adjustment method and device
CN107870835A (en) * 2017-10-25 2018-04-03 深圳市艾特智能科技有限公司 Hardware adjustment method, system, readable storage medium storing program for executing and intelligent terminal

Also Published As

Publication number Publication date
CN112306576A (en) 2021-02-02

Similar Documents

Publication Publication Date Title
US10922102B2 (en) Method of controlling applications in a terminal and terminal
US20200089718A1 (en) Inferred user identity in content distribution
CN103473502A (en) Method and system for acquiring Root rights of android-based mobile terminal
CN103826215A (en) Method and apparatus for carrying out root authority management at terminal equipment
WO2021098354A1 (en) Method and apparatus for android penetration achieving silent installation on basis of accessibility service
WO2019051948A1 (en) Method, apparatus, server, and storage medium for processing monitoring data
CN110399227B (en) Data access method, device and storage medium
WO2019205828A1 (en) Android service framework, and method and device for implementing extended service
CN112306576B (en) Method for modifying built-in number of android device application program
CN103885763A (en) Operating system resource access method and system
CN111857777A (en) System updating method and device based on double-core intelligent electric meter and computer equipment
CN113835921A (en) Method, device, equipment and storage medium for processing interface service exception
WO2017140154A1 (en) Method and system for security information management based on intelligent platform
CN114598687A (en) Method, system and terminal for capturing HTTPS data packet
WO2012065464A1 (en) Software installation method and device
CN117056904A (en) Application privacy compliance judging method, device, computer equipment and medium
CN112000321A (en) Method and device for realizing undo and/or redo of three-dimensional detection software
CN108920945B (en) root authority obtaining and deleting method and device, terminal equipment and storage medium
CN106295320A (en) A kind of android system customized desktop based on white list
CN112632032B (en) Data migration method and device, storage medium and terminal equipment
CN110472170B (en) Method and system for accessing three-dimensional security platform based on browser plug-in
CN114238021A (en) SDK interface positioning method, device, equipment and computer storage medium
CN114610239A (en) Method and device for operating file in portable memory by mobile terminal
CN109558375B (en) Optimized file storage method, storage medium, equipment and system
CN108959061B (en) Application function management method, terminal and device

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