CN103793248A - Method and device for upgrading application program - Google Patents

Method and device for upgrading application program Download PDF

Info

Publication number
CN103793248A
CN103793248A CN201410033251.XA CN201410033251A CN103793248A CN 103793248 A CN103793248 A CN 103793248A CN 201410033251 A CN201410033251 A CN 201410033251A CN 103793248 A CN103793248 A CN 103793248A
Authority
CN
China
Prior art keywords
application program
directory address
component object
address
current
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
CN201410033251.XA
Other languages
Chinese (zh)
Other versions
CN103793248B (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.)
Beijing Qihoo Technology Co Ltd
Original Assignee
Beijing Qihoo Technology Co Ltd
Qizhi Software Beijing 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 Beijing Qihoo Technology Co Ltd, Qizhi Software Beijing Co Ltd filed Critical Beijing Qihoo Technology Co Ltd
Priority to CN201410033251.XA priority Critical patent/CN103793248B/en
Publication of CN103793248A publication Critical patent/CN103793248A/en
Application granted granted Critical
Publication of CN103793248B publication Critical patent/CN103793248B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Stored Programmes (AREA)

Abstract

The invention discloses a method and device for upgrading an application program. The method comprises the steps of acquiring an installation package of the application program to be upgraded, extracting specified component object information from the installation package, determining a specified component object in the application program according to the specified component object information, and loading the specified component object by means of the specified component object information. The method and device for upgrading the application program are used for solving the problem that the program upgrading processes are complicated, the application program can be upgraded without upgrading operation conducted by a user, upgrading can be achieved quickly, and user experience is improved.

Description

A kind of method of application program updating and device
Technical field
The present invention relates to the technical field of data processing, be specifically related to a kind of method of application program updating, and, a kind of device of application program updating.
Background technology
In specific implementation, application program is through use after a while, will progressively show self some leaks and defect, these leaks and defect cannot meet the requirement of growing application program, therefore application developers must regular or irregular application programs itself leak and defect are repaired and are corrected, therefore constantly produce the installation kit of new application program, to meet the requirement of application program updating.
When user will upgrade application program, the installation kit that need to first download this application program is put into assigned address, then removes to use this installation kit, conventionally understands ejection system prompting frame, and user carries out corresponding operation this application program of just can upgrading according to prompting.In addition, because the upgrading of application program is a lasting process, so can constantly there is new installation kit, user also needs constantly to upgrade, and for certain customers, escalation process is more loaded down with trivial details, and need to expend the regular hour, user's experience effect is poor.
Summary of the invention
In view of the above problems, the present invention is proposed to a kind of method of a kind of application program updating that overcomes the problems referred to above or address the above problem is at least in part provided, and, a kind of device of application program updating.
According to one aspect of the present invention, a kind of method of application program updating is provided, comprising:
Obtain the installation kit of application program to be upgraded;
From described installation kit, extract the component object information of specifying;
Component object information according to described appointment is determined the component object of specifying in described application program;
Adopt the component object information of described appointment to load the component object of described appointment.
Alternatively, the component object information of described appointment comprises the directory address of current Classloader, and the component object of specifying in described application program comprises Classloader;
The step that the component object information that described employing is specified loads the component object of described appointment comprises:
Adopt reflective object in described application program to obtain the directory address of the primitive class loader in described application program;
The directory address of primitive class loader is revised as to the directory address of current Classloader.
Load described Classloader from the directory address of described current Classloader.
Alternatively, the component object information of described appointment comprises the directory address of current application object, and the component object of specifying in described application program comprises application;
The step that the component object information that described employing is specified loads the component object of described appointment comprises:
Adopt reflective object in described application program to obtain the directory address of the original application object in described application program;
The directory address of original application object is revised as to the directory address of current application object.
Load described application from the directory address of described current application object.
Alternatively, the component object information of described appointment comprises the directory address of current resource data, and the component object of specifying in described application program comprises resource data;
The step that the component object information that described employing is specified loads the component object of described appointment comprises:
Adopt reflective object in described application program to obtain the directory address of the raw resource data in described application program;
The directory address of raw resource data is revised as to the directory address of current resource data.
Load described resource data from the directory address of described current resource data.
Alternatively, the component object information of described appointment comprises the directory address of current package manager, and the component object of specifying in described application program comprises package manager;
The step that the component object information that described employing is specified loads the component object of described appointment comprises:
Adopt reflective object in described application program to obtain the directory address of the original packet manager in described application program;
The directory address of original packet manager is revised as to the directory address of current package manager.
Load described package manager from the directory address of described current package manager.
According to a further aspect in the invention, provide a kind of device of application program updating, having comprised:
Acquisition module, is suitable for obtaining the installation kit of application program to be upgraded;
Extraction module, is suitable for extracting the component object information of specifying from described installation kit;
Determination module, is suitable for determining the component object of specifying in described application program according to the component object information of described appointment;
Load-on module, is suitable for adopting the component object information of described appointment to load the component object of described appointment.
Alternatively, the component object information of described appointment comprises the directory address of current Classloader, and the component object of specifying in described application program comprises Classloader;
Described load-on module comprises:
The first address acquisition submodule, is suitable for adopting reflective object in described application program to obtain the directory address of the primitive class loader in described application program;
Submodule is revised in the first address, is suitable for the directory address of primitive class loader to be revised as the directory address of current Classloader.
First loads submodule, is suitable for loading described Classloader from the directory address of described current Classloader.
Alternatively, the component object information of described appointment comprises the directory address of current application object, and the component object of specifying in described application program comprises application;
Described load-on module comprises:
The second address acquisition submodule, is suitable for adopting reflective object in described application program to obtain the directory address of the original application object in described application program;
Submodule is revised in the second address, is suitable for the directory address of original application object to be revised as the directory address of current application object.
Second loads submodule, is suitable for loading described application from the directory address of described current application object.
Alternatively, the component object information of described appointment comprises the directory address of current resource data, and the component object of specifying in described application program comprises resource data;
Described load-on module comprises:
The 3rd address acquisition submodule, is suitable for adopting reflective object in described application program to obtain the directory address of the raw resource data in described application program;
Submodule is revised in the 3rd address, is suitable for the directory address of raw resource data to be revised as the directory address of current resource data.
The 3rd loads submodule, is suitable for loading described resource data from the directory address of described current resource data.
Alternatively, the component object information of described appointment comprises the directory address of current package manager, and the component object of specifying in described application program comprises package manager;
Described load-on module comprises:
The four-address is obtained submodule, is suitable for adopting reflective object in described application program to obtain the directory address of the original packet manager in described application program;
The four-address is revised submodule, is suitable for the directory address of original packet manager to be revised as the directory address of current package manager.
The 4th loads submodule, is suitable for loading described package manager from the directory address of described current package manager.
According to the method for a kind of application program updating of the present invention, and, a kind of device of application program updating, can get after the installation kit of application program, extract the component object information of specifying according in bag, and determine the assignment component object in application program according to the component object information of specifying, adopt the component object information of this appointment to load the component object of specifying, break the authority of android regulation, by by subject component by original load address, be redirected to address new in installation kit and carry out charging assembly object, realize the auto-update of application program, solve thus the loaded down with trivial details problem of legacy application escalation process, do not need user to carry out updating operation can to complete the upgrading of application program yet, obtain and completed fast upgrading, improve the beneficial effect of user experience.
Above-mentioned explanation is only the general introduction of technical solution of the present invention, in order to better understand technological means of the present invention, and can be implemented according to the content of instructions, and for above and other objects of the present invention, feature and advantage can be become apparent, below especially exemplified by the specific embodiment of the present invention.
Accompanying drawing explanation
By reading below detailed description of the preferred embodiment, various other advantage and benefits will become cheer and bright for those of ordinary skills.Accompanying drawing is only for the object of preferred implementation is shown, and do not think limitation of the present invention.And in whole accompanying drawing, represent identical parts by identical reference symbol.In the accompanying drawings:
Fig. 1 shows a kind of flow chart of steps of embodiment of the method for application program updating according to an embodiment of the invention;
Fig. 2 shows the structured flowchart of a kind of device embodiment of application program updating according to an embodiment of the invention.
Embodiment
Exemplary embodiment of the present disclosure is described below with reference to accompanying drawings in more detail.Although shown exemplary embodiment of the present disclosure in accompanying drawing, but should be appreciated that and can realize the disclosure and the embodiment that should do not set forth limits here with various forms.On the contrary, it is in order more thoroughly to understand the disclosure that these embodiment are provided, and can be by the those skilled in the art that conveys to complete the scope of the present disclosure.
With reference to Fig. 1, show a kind of flow chart of steps of embodiment of the method for application program updating according to an embodiment of the invention, specifically can comprise the steps:
Step 101, obtains the installation kit of application program to be upgraded;
In an embodiment of the present invention, application program can be the version that is applicable to the version of computing equipment or is applicable to mobile device.For example, the mobile phone HELPER APPLICATION of computing equipment version, as the mobile phone HELPER APPLICATION of PC version, or the mobile phone HELPER APPLICATION of mobile device version, as the mobile phone HELPER APPLICATION of Android version.
In specific implementation, a lot of application programs are installed in terminal device, can comprise application program and the built-in application program of system of user installation.The terminal device at application program place can be preset testing mechanism and detect whether there is new APK(Android Package, installation kit), for example, can, in installing terminal equipment mobile phone assistant or other application programs, there is which application program to need upgrading in order to inquire about this terminal device.Particularly, in the time that mobile phone assistant detects that the application program that need to upgrade is more, the mobile phone assistant of terminal equipment side can will install the application package name of application and application version number with the processing of Gzip format compression, the form of then asking by HTTP sends to network side server, thereby get the audit authentication through safety detection center, green non-poisonous, the APK of safety.Adopt mobile phone assistant to obtain the mode of application A PK, can save flow, and faster, more convenient, more safely obtain Internet resources.
In actual applications; mobile phone assistant can be set to detect once every predetermined time interval; in the time detecting that network side server exists new APK; the form of asking by HTTP or other modes are obtained APK; in order to protect the new APK getting; facilitate user management or data to read; can be stored to the position of appointment; such as being installed in mobile device internal memory or mobile device SD card; in addition, can also adopt intelligent mode to be installed to suitable position according to the feature of APK (size of APK).In specific implementation, can pay the utmost attention to APK is stored in SD card, facilitate user management, can not take because of mobile device internal memory, and cause the slack-off of mobile device speed simultaneously.For example, APK can be stored in: sdcard/download/data.
Certainly, in actual applications, can be also that server is issued while having new APK, initiatively this APK is sent to terminal device, the embodiment of the present invention is not restricted this.
Step 102 is extracted the component object information of specifying from described installation kit;
In actual applications, corresponding configuration information can be set in advance in application program, wherein, the indication information of securing component object information can be set in described configuration information, in the time getting the APK of application program of band upgrading, from APK, obtain the component object information of appointment according to configuration information.
Step 103, determines the component object of specifying in described application program according to the component object information of described appointment;
In embodiments of the present invention, can from APK, extract the component object information of specifying, then determine and in application program, need the component object of upgrading according to component object information.
Step 104, adopts the component object information of described appointment to load the component object of described appointment.
In a preferred embodiment of the present invention, the component object information of described appointment comprises the directory address of current Classloader, and the component object of specifying in described application program can comprise Classloader;
Described step 104 can comprise following sub-step:
Sub-step S11, adopts reflective object in described application program to obtain the directory address of the primitive class loader in described application program;
Sub-step S12, is revised as the directory address of primitive class loader the directory address of current Classloader.
Sub-step S13, loads described Classloader from the directory address of described current Classloader.
In embodiments of the present invention, due in Android system, some undocumented functions cannot directly be called by api interface, therefore adopt JAVA reflex mechanism to call some undocumented functions, carry out the upgrading of real application program.Particularly, JAVA reflex mechanism be in application program in running status, for any one class, can both know all properties and the method for this class; For any one object, can both call its any one method and attribute; The function of the method for the information of this Dynamic Acquisition and dynamic call object is called the reflex mechanism of JAVA language.
In the time running application, first move JVM(Java virtual machine), then the class of application program is loaded into the operation of JVM the inside, this part of the class of responsible loading application programs is exactly Classloader.In embodiments of the present invention, the object of revising Classloader is to revise the code of application program, and the code of concrete modification can comprise the class in application program.Adopt JAVA reflex mechanism the directory address of original Classloader in application program to be revised as to the directory address of Classloader in new APK, in the time that application program loads again, can directly load from the directory address of new Classloader, the class that amended Classloader need to load in the time of application program launching is also modified, so just can realize for example increase of the new function of application program, the upgrading of the application program such as modification of BUG in application program.
In a preferred embodiment of the present invention, the component object information of described appointment can comprise the directory address of current application object, and the component object of specifying in described application program can comprise application;
Described step 104 can comprise following sub-step:
Sub-step S21, adopts reflective object in described application program to obtain the directory address of the original application object in described application program;
Sub-step S22, is revised as the directory address of original application object the directory address of current application object.
Sub-step S23, loads described application from the directory address of described current application object.
In embodiments of the present invention, the object of revising application is to revise the enable logic order in application program, particularly, i.e. and the loading sequence of the class in application program.In specific implementation, through the use of application program a period of time, find that in application program, adopting other orders to carry out loading classes can use application program better, or, application program has increased new function by revising Classloader, can adopt reflex mechanism the load address of application to be revised as to the load address of application in new APK, in the time that loading again, application program can directly load from the directory address of new application, in application program just there is variation in the enable logic of class order, for example, when application program launching, startup is newly increased to funtion part.
In a preferred embodiment of the present invention, the component object information of described appointment comprises the directory address of current resource data, and the component object of specifying in described application program comprises resource data;
Described step 104 can comprise following sub-step:
Sub-step S31, adopts reflective object in described application program to obtain the directory address of the raw resource data in described application program;
Sub-step S32, is revised as the directory address of raw resource data the directory address of current resource data.
Sub-step S33, loads described resource data from the directory address of described current resource data.
In specific implementation, described resource data can be picture resource or text resource, for example, and theme, wallpaper, the tinkle of bells, software, music, game, video, e-book etc.Resource data has file attribute information, and wherein, file attribute information comprises the size of resource, the type of resource, the version number of resource, mark of resource etc.
Picture resource or text resource need often to upgrade in practice, for example application program may need to increase accordingly icon due to the increase of new function, in embodiments of the present invention, only the picture in application program need to be revised as to the middle loading of the picture from new APK, can be directly in the time that application program loads again load from the directory address of new picture, complete the renewal of the picture in application program with this.
In a preferred embodiment of the present invention, the component object information of described appointment comprises the directory address of current package manager, and the component object of specifying in described application program comprises package manager;
Described step 104 can comprise following sub-step:
Sub-step S41, adopts reflective object in described application program to obtain the directory address of the original packet manager in described application program;
Sub-step S42, is revised as the directory address of original packet manager the directory address of current package manager.
Sub-step S43, loads described package manager from the directory address of described current package manager.
In specific implementation, the load address of package manager that can also application programs is modified, to illustrate that this application program has realized renewal to a certain extent, particularly, the directory address of the package manager in application program can be repositioned onto in the address of package manager in APK, in the time that loading again, application program can directly load from the directory address of new package manager, for example, scripting utility loads after package manager and is shown as 9.0 versions, reorientates after loading behind package manager address and is shown as 9.1 versions.
Adopt in embodiments of the present invention and be redirected and reflection technology is realized the auto-update of application program.In the time getting new APK, obtain the directory address of assignment component object in this APK, and according to the directory address of described assignment component, the directory address of appointment part object original in application program is revised as to the directory address of assignment component object in new APK, in the time that application program loads assignment component object again, just no longer load from the directory address of original appointment part object, but directly from new APK the directory address of assignment component object load, solve thus the loaded down with trivial details problem of legacy application escalation process, do not need user to carry out updating operation can to complete the upgrading of application program yet, obtain and completed fast upgrading, improve the beneficial effect of user experience.In practice, can also adopt retransmission technique to realize the upgrading of application program, in the time need to loading the component object of specifying from the directory address of original appointment part object, the directory address that jumps to the assignment component of new APK removes to load the component object of specifying.
It should be noted that, for embodiment of the method, for simple description, therefore it is all expressed as to a series of combination of actions, but those skilled in the art should know, the present invention is not subject to the restriction of described sequence of movement, because according to the present invention, some step can adopt other orders or carry out simultaneously.Secondly, those skilled in the art also should know, the embodiment described in instructions all belongs to preferred embodiment, and related action and module might not be that the present invention is necessary.
With reference to Fig. 2, show the structured flowchart of a kind of device embodiment of application program updating according to an embodiment of the invention, specifically can comprise as lower module:
Acquisition module 201, is suitable for obtaining the installation kit of application program to be upgraded;
Extraction module 202, is suitable for extracting the component object information of specifying from described installation kit;
Determination module 203, is suitable for determining the component object of specifying in described application program according to the component object information of described appointment;
Load-on module 204, is suitable for adopting the component object information of described appointment to load the component object of described appointment.
In a preferred embodiment of the present invention, the component object information of described appointment comprises the directory address of current Classloader, and the component object of specifying in described application program comprises Classloader;
Described load-on module 204 can comprise:
The first address acquisition submodule, is suitable for adopting reflective object in described application program to obtain the directory address of the primitive class loader in described application program;
Submodule is revised in the first address, is suitable for the directory address of primitive class loader to be revised as the directory address of current Classloader.
First loads submodule, is suitable for loading described Classloader from the directory address of described current Classloader.
In a preferred embodiment of the present invention, the component object information of described appointment comprises the directory address of current application object, and the component object of specifying in described application program comprises application;
Described load-on module 204 can comprise:
The second address acquisition submodule, is suitable for adopting reflective object in described application program to obtain the directory address of the original application object in described application program;
Submodule is revised in the second address, is suitable for the directory address of original application object to be revised as the directory address of current application object.
Second loads submodule, is suitable for loading described application from the directory address of described current application object.
In a preferred embodiment of the present invention, the component object information of described appointment comprises the directory address of current resource data, and the component object of specifying in described application program comprises resource data;
Described load-on module 204 can comprise:
The 3rd address acquisition submodule, is suitable for adopting reflective object in described application program to obtain the directory address of the raw resource data in described application program;
Submodule is revised in the 3rd address, is suitable for the directory address of raw resource data to be revised as the directory address of current resource data.
The 3rd loads submodule, is suitable for loading described resource data from the directory address of described current resource data.
In a preferred embodiment of the present invention, the component object information of described appointment comprises the directory address of current package manager, and the component object of specifying in described application program comprises package manager;
Described load-on module 204 can comprise:
The four-address is obtained submodule, is suitable for adopting reflective object in described application program to obtain the directory address of the original packet manager in described application program;
The four-address is revised submodule, is suitable for the directory address of original packet manager to be revised as the directory address of current package manager.
The 4th loads submodule, is suitable for loading described package manager from the directory address of described current package manager.
For device embodiment, because it is substantially similar to embodiment of the method, so description is fairly simple, relevant part is referring to the part explanation of embodiment of the method.
The algorithm providing at this is intrinsic not relevant to any certain computer, virtual system or miscellaneous equipment with demonstration.Various general-purpose systems also can with based on using together with this teaching.According to description above, it is apparent constructing the desired structure of this type systematic.In addition, the present invention is not also for any certain programmed language.It should be understood that and can utilize various programming languages to realize content of the present invention described here, and the description of above language-specific being done is in order to disclose preferred forms of the present invention.
In the instructions that provided herein, a large amount of details are described.But, can understand, embodiments of the invention can be put into practice in the situation that there is no these details.In some instances, be not shown specifically known method, structure and technology, so that not fuzzy understanding of this description.
Similarly, be to be understood that, in order to simplify the disclosure and to help to understand one or more in each inventive aspect, in the above in the description of exemplary embodiment of the present invention, each feature of the present invention is grouped together into single embodiment, figure or sometimes in its description.But, the method for the disclosure should be construed to the following intention of reflection: the present invention for required protection requires than the more feature of feature of clearly recording in each claim.Or rather, as reflected in claims below, inventive aspect is to be less than all features of disclosed single embodiment above.Therefore, claims of following embodiment are incorporated to this embodiment thus clearly, and wherein each claim itself is as independent embodiment of the present invention.
Those skilled in the art are appreciated that and can the module in the equipment in embodiment are adaptively changed and they are arranged in one or more equipment different from this embodiment.Module in embodiment or unit or assembly can be combined into a module or unit or assembly, and can put them in addition multiple submodules or subelement or sub-component.At least some in such feature and/or process or unit are mutually repelling, and can adopt any combination to combine all processes or the unit of disclosed all features in this instructions (comprising claim, summary and the accompanying drawing followed) and disclosed any method like this or equipment.Unless clearly statement in addition, in this instructions (comprising claim, summary and the accompanying drawing followed) disclosed each feature can be by providing identical, be equal to or the alternative features of similar object replaces.
In addition, those skilled in the art can understand, although embodiment more described herein comprise some feature rather than further feature included in other embodiment, the combination of the feature of different embodiment means within scope of the present invention and forms different embodiment.For example, in the following claims, the one of any of embodiment required for protection can be used with array mode arbitrarily.
All parts embodiment of the present invention can realize with hardware, or realizes with the application program module of moving on one or more processor, or realizes with their combination.It will be understood by those of skill in the art that and can use in practice microprocessor or digital signal processor (DSP) to realize according to the some or all functions of the some or all parts in the application program updating equipment of the embodiment of the present invention.The present invention can also be embodied as part or all equipment or the device program (for example, computer program and computer program) for carrying out method as described herein.Realizing program of the present invention and can be stored on computer-readable medium like this, or can there is the form of one or more signal.Such signal can be downloaded and obtain from internet website, or provides on carrier signal, or provides with any other form.
It should be noted above-described embodiment the present invention will be described rather than limit the invention, and those skilled in the art can design alternative embodiment in the case of not departing from the scope of claims.In the claims, any reference symbol between bracket should be configured to limitations on claims.Word " comprises " not to be got rid of existence and is not listed as element or step in the claims.Being positioned at word " " before element or " one " does not get rid of and has multiple such elements.The present invention can be by means of including the hardware of some different elements and realizing by means of the computing machine of suitably programming.In the unit claim of having enumerated some devices, several in these devices can be to carry out imbody by same hardware branch.The use of word first, second and C grade does not represent any order.Can be title by these word explanations.
A kind of method that the invention discloses A1, application program updating, comprising:
Obtain the installation kit of application program to be upgraded;
From described installation kit, extract the component object information of specifying;
Component object information according to described appointment is determined the component object of specifying in described application program;
Adopt the component object information of described appointment to load the component object of described appointment.
A2, method as described in claim A1, is characterized in that, the component object information of described appointment comprises the directory address of current Classloader, and the component object of specifying in described application program comprises Classloader;
The step that the component object information that described employing is specified loads the component object of described appointment comprises:
Adopt reflective object in described application program to obtain the directory address of the primitive class loader in described application program;
The directory address of primitive class loader is revised as to the directory address of current Classloader.
Load described Classloader from the directory address of described current Classloader.
A3, method as described in claim A1 or A2, is characterized in that, the component object information of described appointment comprises the directory address of current application object, and the component object of specifying in described application program comprises application;
The step that the component object information that described employing is specified loads the component object of described appointment comprises:
Adopt reflective object in described application program to obtain the directory address of the original application object in described application program;
The directory address of original application object is revised as to the directory address of current application object.
Load described application from the directory address of described current application object.
A4, method as described in claim A3, is characterized in that, the component object information of described appointment comprises the directory address of current resource data, and the component object of specifying in described application program comprises resource data;
The step that the component object information that described employing is specified loads the component object of described appointment comprises:
Adopt reflective object in described application program to obtain the directory address of the raw resource data in described application program;
The directory address of raw resource data is revised as to the directory address of current resource data.
Load described resource data from the directory address of described current resource data.
A5, method as described in claim A4, is characterized in that, the component object information of described appointment comprises the directory address of current package manager, and the component object of specifying in described application program comprises package manager;
The step that the component object information that described employing is specified loads the component object of described appointment comprises:
Adopt reflective object in described application program to obtain the directory address of the original packet manager in described application program;
The directory address of original packet manager is revised as to the directory address of current package manager.
Load described package manager from the directory address of described current package manager.
The device that the invention also discloses B6, a kind of application program updating, comprising:
Acquisition module, is suitable for obtaining the installation kit of application program to be upgraded;
Extraction module, is suitable for extracting the component object information of specifying from described installation kit;
Determination module, is suitable for determining the component object of specifying in described application program according to the component object information of described appointment;
Load-on module, is suitable for adopting the component object information of described appointment to load the component object of described appointment.
B7, device as described in claim B6, is characterized in that, the component object information of described appointment comprises the directory address of current Classloader, and the component object of specifying in described application program comprises Classloader;
Described load-on module comprises:
The first address acquisition submodule, is suitable for adopting reflective object in described application program to obtain the directory address of the primitive class loader in described application program;
Submodule is revised in the first address, is suitable for the directory address of primitive class loader to be revised as the directory address of current Classloader.
First loads submodule, is suitable for loading described Classloader from the directory address of described current Classloader.
B8, device as described in claim B6 or B7, is characterized in that, the component object information of described appointment comprises the directory address of current application object, and the component object of specifying in described application program comprises application;
Described load-on module comprises:
The second address acquisition submodule, is suitable for adopting reflective object in described application program to obtain the directory address of the original application object in described application program;
Submodule is revised in the second address, is suitable for the directory address of original application object to be revised as the directory address of current application object.
Second loads submodule, is suitable for loading described application from the directory address of described current application object.
B9, device as described in claim B8, is characterized in that, the component object information of described appointment comprises the directory address of current resource data, and the component object of specifying in described application program comprises resource data;
Described load-on module comprises:
The 3rd address acquisition submodule, is suitable for adopting reflective object in described application program to obtain the directory address of the raw resource data in described application program;
Submodule is revised in the 3rd address, is suitable for the directory address of raw resource data to be revised as the directory address of current resource data.
The 3rd loads submodule, is suitable for loading described resource data from the directory address of described current resource data.
B10, device as described in claim B9, is characterized in that, the component object information of described appointment comprises the directory address of current package manager, and the component object of specifying in described application program comprises package manager;
Described load-on module comprises:
The four-address is obtained submodule, is suitable for adopting reflective object in described application program to obtain the directory address of the original packet manager in described application program;
The four-address is revised submodule, is suitable for the directory address of original packet manager to be revised as the directory address of current package manager.
The 4th loads submodule, is suitable for loading described package manager from the directory address of described current package manager.

Claims (10)

1. a method for application program updating, comprising:
Obtain the installation kit of application program to be upgraded;
From described installation kit, extract the component object information of specifying;
Component object information according to described appointment is determined the component object of specifying in described application program;
Adopt the component object information of described appointment to load the component object of described appointment.
2. the method for claim 1, is characterized in that, the component object information of described appointment comprises the directory address of current Classloader, and the component object of specifying in described application program comprises Classloader;
The step that the component object information that described employing is specified loads the component object of described appointment comprises:
Adopt reflective object in described application program to obtain the directory address of the primitive class loader in described application program;
The directory address of primitive class loader is revised as to the directory address of current Classloader.
Load described Classloader from the directory address of described current Classloader.
3. method as claimed in claim 1 or 2, is characterized in that, the component object information of described appointment comprises the directory address of current application object, and the component object of specifying in described application program comprises application;
The step that the component object information that described employing is specified loads the component object of described appointment comprises:
Adopt reflective object in described application program to obtain the directory address of the original application object in described application program;
The directory address of original application object is revised as to the directory address of current application object.
Load described application from the directory address of described current application object.
4. method as claimed in claim 3, is characterized in that, the component object information of described appointment comprises the directory address of current resource data, and the component object of specifying in described application program comprises resource data;
The step that the component object information that described employing is specified loads the component object of described appointment comprises:
Adopt reflective object in described application program to obtain the directory address of the raw resource data in described application program;
The directory address of raw resource data is revised as to the directory address of current resource data.
Load described resource data from the directory address of described current resource data.
5. method as claimed in claim 4, is characterized in that, the component object information of described appointment comprises the directory address of current package manager, and the component object of specifying in described application program comprises package manager;
The step that the component object information that described employing is specified loads the component object of described appointment comprises:
Adopt reflective object in described application program to obtain the directory address of the original packet manager in described application program;
The directory address of original packet manager is revised as to the directory address of current package manager.
Load described package manager from the directory address of described current package manager.
6. a device for application program updating, comprising:
Acquisition module, is suitable for obtaining the installation kit of application program to be upgraded;
Extraction module, is suitable for extracting the component object information of specifying from described installation kit;
Determination module, is suitable for determining the component object of specifying in described application program according to the component object information of described appointment;
Load-on module, is suitable for adopting the component object information of described appointment to load the component object of described appointment.
7. device as claimed in claim 6, is characterized in that, the component object information of described appointment comprises the directory address of current Classloader, and the component object of specifying in described application program comprises Classloader;
Described load-on module comprises:
The first address acquisition submodule, is suitable for adopting reflective object in described application program to obtain the directory address of the primitive class loader in described application program;
Submodule is revised in the first address, is suitable for the directory address of primitive class loader to be revised as the directory address of current Classloader.
First loads submodule, is suitable for loading described Classloader from the directory address of described current Classloader.
8. the device as described in claim 6 or 7, is characterized in that, the component object information of described appointment comprises the directory address of current application object, and the component object of specifying in described application program comprises application;
Described load-on module comprises:
The second address acquisition submodule, is suitable for adopting reflective object in described application program to obtain the directory address of the original application object in described application program;
Submodule is revised in the second address, is suitable for the directory address of original application object to be revised as the directory address of current application object.
Second loads submodule, is suitable for loading described application from the directory address of described current application object.
9. device as claimed in claim 8, is characterized in that, the component object information of described appointment comprises the directory address of current resource data, and the component object of specifying in described application program comprises resource data;
Described load-on module comprises:
The 3rd address acquisition submodule, is suitable for adopting reflective object in described application program to obtain the directory address of the raw resource data in described application program;
Submodule is revised in the 3rd address, is suitable for the directory address of raw resource data to be revised as the directory address of current resource data.
The 3rd loads submodule, is suitable for loading described resource data from the directory address of described current resource data.
10. device as claimed in claim 9, is characterized in that, the component object information of described appointment comprises the directory address of current package manager, and the component object of specifying in described application program comprises package manager;
Described load-on module comprises:
The four-address is obtained submodule, is suitable for adopting reflective object in described application program to obtain the directory address of the original packet manager in described application program;
The four-address is revised submodule, is suitable for the directory address of original packet manager to be revised as the directory address of current package manager.
The 4th loads submodule, is suitable for loading described package manager from the directory address of described current package manager.
CN201410033251.XA 2014-01-23 2014-01-23 Method and device for upgrading application program Active CN103793248B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410033251.XA CN103793248B (en) 2014-01-23 2014-01-23 Method and device for upgrading application program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410033251.XA CN103793248B (en) 2014-01-23 2014-01-23 Method and device for upgrading application program

Publications (2)

Publication Number Publication Date
CN103793248A true CN103793248A (en) 2014-05-14
CN103793248B CN103793248B (en) 2017-02-01

Family

ID=50668963

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410033251.XA Active CN103793248B (en) 2014-01-23 2014-01-23 Method and device for upgrading application program

Country Status (1)

Country Link
CN (1) CN103793248B (en)

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104182255A (en) * 2014-08-20 2014-12-03 青岛海信宽带多媒体技术有限公司 Method and terminal for upgrading library files of system application
CN105279005A (en) * 2015-11-30 2016-01-27 北京奇艺世纪科技有限公司 Application software updating method and device
CN105320551A (en) * 2015-11-30 2016-02-10 北京奇艺世纪科技有限公司 Application software updating method and device
CN105335201A (en) * 2015-11-30 2016-02-17 北京奇艺世纪科技有限公司 Application software updating method and device
WO2016058334A1 (en) * 2014-10-16 2016-04-21 小米科技有限责任公司 Upgrade method, apparatus and device
CN105867953A (en) * 2015-01-21 2016-08-17 中国移动通信集团云南有限公司 Application upgrading package generation method, application upgrading method and corresponding apparatuses
CN106484488A (en) * 2015-08-31 2017-03-08 深圳市金锐显数码科技有限公司 Integrated cloud compilation method and system
CN108304722A (en) * 2017-12-21 2018-07-20 广州小鹏汽车科技有限公司 A kind of software installation packet and its generation method, upgrade method and system
CN114245152A (en) * 2021-11-03 2022-03-25 武汉斗鱼鱼乐网络科技有限公司 Identification picture loading method and device, storage medium and electronic equipment

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100442233C (en) * 2007-01-31 2008-12-10 华为技术有限公司 Method and system for implementing dynamic upgrade of application system
US8752032B2 (en) * 2007-02-23 2014-06-10 Irdeto Canada Corporation System and method of interlocking to protect software-mediated program and device behaviours
US8495621B2 (en) * 2009-06-15 2013-07-23 Microsoft Corporation Catalog-based software component management
CN102073525B (en) * 2011-01-20 2016-03-02 中兴通讯股份有限公司 Based on dynamic update method and the device of the Web service system of Java platform

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104182255B (en) * 2014-08-20 2017-11-21 青岛海信宽带多媒体技术有限公司 A kind of the library file upgrade method and terminal of system application
CN104182255A (en) * 2014-08-20 2014-12-03 青岛海信宽带多媒体技术有限公司 Method and terminal for upgrading library files of system application
WO2016058334A1 (en) * 2014-10-16 2016-04-21 小米科技有限责任公司 Upgrade method, apparatus and device
CN105867953A (en) * 2015-01-21 2016-08-17 中国移动通信集团云南有限公司 Application upgrading package generation method, application upgrading method and corresponding apparatuses
CN105867953B (en) * 2015-01-21 2019-04-26 中国移动通信集团云南有限公司 Application program updating packet generation method and application program updating method and corresponding intrument
CN106484488A (en) * 2015-08-31 2017-03-08 深圳市金锐显数码科技有限公司 Integrated cloud compilation method and system
CN106484488B (en) * 2015-08-31 2019-09-03 深圳市金锐显数码科技有限公司 Integrated cloud Compilation Method and system
CN105335201A (en) * 2015-11-30 2016-02-17 北京奇艺世纪科技有限公司 Application software updating method and device
CN105320551A (en) * 2015-11-30 2016-02-10 北京奇艺世纪科技有限公司 Application software updating method and device
CN105279005A (en) * 2015-11-30 2016-01-27 北京奇艺世纪科技有限公司 Application software updating method and device
CN105335201B (en) * 2015-11-30 2019-06-14 北京奇艺世纪科技有限公司 A kind of application software update method and device
CN108304722A (en) * 2017-12-21 2018-07-20 广州小鹏汽车科技有限公司 A kind of software installation packet and its generation method, upgrade method and system
CN114245152A (en) * 2021-11-03 2022-03-25 武汉斗鱼鱼乐网络科技有限公司 Identification picture loading method and device, storage medium and electronic equipment

Also Published As

Publication number Publication date
CN103793248B (en) 2017-02-01

Similar Documents

Publication Publication Date Title
CN103793248A (en) Method and device for upgrading application program
CN105786538B (en) software upgrading method and device based on android system
CN108847950B (en) Electronic device, cloud system software automatic deployment method and storage medium
CN107451474B (en) Software bug fixing method and device for terminal
CN107038085B (en) Method, device and system for repairing client application
US10176327B2 (en) Method and device for preventing application in an operating system from being uninstalled
CN104375861A (en) Installation-free operation method and device for application programs based on Android platform and terminal
CN103530156A (en) Method and device for dynamically loading and calling program
US9063819B2 (en) Extensible patch management
CN106406961A (en) Method and device for loading and providing application based on browser
CN103034546B (en) The method and device of inter-application communication in iOS system
WO2017041499A1 (en) Software upgrade method and system, and computer-readable storage medium
TW201917569A (en) Android dynamic framework and method thereof
JP6198229B2 (en) Installation engine and package format for parallelizable and reliable installation
US20200379742A1 (en) Validation of configurations of factory installations
CN108089870B (en) Method and apparatus for repairing applications
KR20180098584A (en) Method and apparatus for executing APP program
CN103530155A (en) Method and device for installing application program
CN108037914B (en) Method and device for developing android native system by combining js
CN106778270B (en) Malicious application detection method and system
CN112882733B (en) Application updating method and device, electronic equipment and storage medium
CN110502251B (en) Application installation method and device
CN102902564A (en) Method and device for installing patches
CN110362320B (en) Command implementation method and device of application development platform
CN112835677A (en) Sandbox-based inherent data protection method and system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20220803

Address after: Room 801, 8th floor, No. 104, floors 1-19, building 2, yard 6, Jiuxianqiao Road, Chaoyang District, Beijing 100015

Patentee after: BEIJING QIHOO TECHNOLOGY Co.,Ltd.

Address before: 100088 room 112, block D, 28 new street, new street, Xicheng District, Beijing (Desheng Park)

Patentee before: BEIJING QIHOO TECHNOLOGY Co.,Ltd.

Patentee before: Qizhi software (Beijing) Co.,Ltd.