CN104008155A - Resource control method and device, and electronic device - Google Patents

Resource control method and device, and electronic device Download PDF

Info

Publication number
CN104008155A
CN104008155A CN201410220130.6A CN201410220130A CN104008155A CN 104008155 A CN104008155 A CN 104008155A CN 201410220130 A CN201410220130 A CN 201410220130A CN 104008155 A CN104008155 A CN 104008155A
Authority
CN
China
Prior art keywords
page
preserved
page data
loaded
data
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.)
Pending
Application number
CN201410220130.6A
Other languages
Chinese (zh)
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 Kingsoft Internet Science and Technology Co Ltd
Original Assignee
Beijing Kingsoft Internet Science and 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 Beijing Kingsoft Internet Science and Technology Co Ltd filed Critical Beijing Kingsoft Internet Science and Technology Co Ltd
Priority to CN201410220130.6A priority Critical patent/CN104008155A/en
Publication of CN104008155A publication Critical patent/CN104008155A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/957Browsing optimisation, e.g. caching or content distillation
    • G06F16/9574Browsing optimisation, e.g. caching or content distillation of access to content, e.g. by caching

Abstract

The invention provides a resource control method and device, and an electronic device. The method includes the following steps that a plurality of loaded pages in a browser type application program are obtained; at least one page in the pages is obtained to serve as the page to be preserved; the loaded page data of the page to be preserved are obtained from an internal storage, and the page data are preserved to a local; after preservation, the page data are deleted from the internal storage. According to the resource control method, the page data of at least one page in the loaded pages are preserved to the local, and after preservation, the page data are deleted from the internal storage, so that resources occupied by at least one page are released, the internal storage occupation is lowered, the operation speed of the browser type application program is sped up, and user experience is improved.

Description

Resource control method, device and electronic equipment
Technical field
The present invention relates to field of computer technology, relate in particular to a kind of resource control method, device and electronic equipment.
Background technology
Along with the development of electronic technology and Internet technology, the electronic products such as computing machine, mobile terminal have become the main tool of user's obtaining information.Particularly, by being arranged on the browser class application program in computing machine, mobile terminal etc., user can obtain the network information quickly and easily.
Wherein, browser class application program, in the time providing the network information to user, need to load corresponding webpage.Particularly, first browser class application program receives URL (the Uniform Resource Locator of user's input, URL(uniform resource locator)), then send request to corresponding server according to this URL, and the web data sending according to this request receiving server, carry out webpage according to web data afterwards and play up, and in a window, rendering result is showed to user.
But, realizing in process of the present invention, in inventor's invention prior art, at least there is following problem: if user asks multiple URL, browser class application program can correspondingly be opened multiple browser windows, and need to create multiple processes of playing up, and each process of playing up can take certain internal memory.If it is too much therefore to play up process, causes EMS memory occupation amount also to increase, and then cause the travelling speed of browser class application program slack-off.
Summary of the invention
The present invention is intended at least one of solve the problems of the technologies described above.
For this reason, first object of the present invention is to propose a kind of resource control method.The method has reduced EMS memory occupation amount, has accelerated the travelling speed of browser class application program, has promoted user's experience.
Second object of the present invention is to propose a kind of resource control.
The 3rd object of the present invention is to propose a kind of electronic equipment.
To achieve these goals, the resource control method of first aspect present invention embodiment, comprises the following steps: obtain the multiple pages that loaded in browser class application program; Obtain at least one page in described multiple page as the page to be preserved; The page data that described in obtaining from internal memory, the page to be preserved has loaded, and described page data is saved to this locality; After preserving, from internal memory, delete described page data.
The resource control method of the embodiment of the present invention, by the page data of at least one page in the multiple pages that loaded is saved to this locality, and from internal memory, delete page data after preserving, thereby discharge the shared memory source of at least one page, reduce EMS memory occupation amount, and then accelerated the travelling speed of browser class application program, promote user's experience.
To achieve these goals, the resource control of second aspect present invention embodiment, comprising: page acquisition module, the multiple pages that loaded for obtaining browser class application program; Page acquisition module to be preserved, at least one page of obtaining described multiple pages as the page to be preserved; Page data acquisition module, the page data having loaded for the page to be preserved described in obtaining from internal memory; Page data is preserved module, for described page data is saved to this locality; And page data removing module, for delete described page data from internal memory after described page data preservation module is preserved described page data.
The resource control of the embodiment of the present invention, by the page data of at least one page in the multiple pages that loaded is saved to this locality, and from internal memory, delete page data after preserving, thereby discharge the shared memory source of at least one page, reduce EMS memory occupation amount, and then accelerated the travelling speed of browser class application program, promote user's experience.
To achieve these goals, the electronic equipment of third aspect present invention embodiment, comprising: shell, screen, processor, storer and circuit board; Described screen is placed on described shell, and described circuit board is placed in the interior volume that described shell surrounds, and described processor and described storer are arranged on described circuit board; Described storer is for stores executable programs code; Described processor moves the program corresponding with described executable program code by reading the executable program code of storing in described storer, for: obtain the multiple pages that loaded in browser class application program; Obtain at least one page in described multiple page as the page to be preserved; And the page data that described in obtaining, the page to be preserved has loaded, and described page data is saved to this locality from internal memory; After preserving, from internal memory, delete described page data.
The electronic equipment of the embodiment of the present invention, by the page data of at least one page in the multiple pages that loaded is saved to this locality, and from internal memory, delete page data after preserving, thereby discharge the shared memory source of at least one page, reduce EMS memory occupation amount, and then accelerated the travelling speed of browser class application program, promote user's experience.
The aspect that the present invention is additional and advantage in the following description part provide, and part will become obviously from the following description, or recognize by practice of the present invention.
Brief description of the drawings
The present invention above-mentioned and/or additional aspect and advantage will become from the following description of the accompanying drawings of embodiments obviously and easily and understand, wherein,
Fig. 1 is the process flow diagram of resource control method according to an embodiment of the invention;
Fig. 2 is the process flow diagram of resource control according to an embodiment of the invention;
Fig. 3 is the process flow diagram of resource control according to an embodiment of the invention;
Fig. 4 is the process flow diagram of resource control method according to an embodiment of the invention;
Fig. 5 is the structural representation of resource control according to an embodiment of the invention;
Fig. 6 is the structural representation of resource control according to an embodiment of the invention.
Embodiment
Describe embodiments of the invention below in detail, the example of described embodiment is shown in the drawings, and wherein same or similar label represents same or similar element or has the element of identical or similar functions from start to finish.Be exemplary below by the embodiment being described with reference to the drawings, only for explaining the present invention, and can not be interpreted as limitation of the present invention.On the contrary, embodiments of the invention comprise all changes, amendment and the equivalent within the scope of spirit and the intension that falls into additional claims.
In description of the invention, it will be appreciated that, term " first ", " second " etc. are only for describing object, and can not be interpreted as instruction or hint relative importance.In description of the invention, it should be noted that, unless otherwise clearly defined and limited, term " is connected ", " connection " should be interpreted broadly, and for example, can be to be fixedly connected with, and can be also to removably connect, or connects integratedly; Can be mechanical connection, can be also electrical connection; Can be to be directly connected, also can indirectly be connected by intermediary.For the ordinary skill in the art, can concrete condition understand above-mentioned term concrete meaning in the present invention.In addition,, in description of the invention, except as otherwise noted, the implication of " multiple " is two or more.
Any process of otherwise describing in process flow diagram or at this or method are described and can be understood to, represent to comprise that one or more is for realizing module, fragment or the part of code of executable instruction of step of specific logical function or process, and the scope of the preferred embodiment of the present invention comprises other realization, wherein can be not according to order shown or that discuss, comprise according to related function by the mode of basic while or by contrary order, carry out function, this should be understood by embodiments of the invention person of ordinary skill in the field.
At present, user, in the time using browser class application program to obtain the network information, can open multiple browser windows conventionally; but; increasing of the browser window quantity of opening along with user, EMS memory occupation amount also increases, and then causes the travelling speed of browser class application program slack-off.In order to address the above problem, the present invention proposes a kind of method for managing resource for browser class application program, device and client, in the time that user opens multiple browser window, it is local to reduce EMS memory occupation amount by page data corresponding part browser window is saved to, thereby the travelling speed of having accelerated browser class application program, has promoted user's experience.
Describe according to the resource control method of the embodiment of the present invention, device and electronic equipment below with reference to accompanying drawing.
Fig. 1 is the process flow diagram of resource control method according to an embodiment of the invention.As shown in Figure 1, resource control method comprises the following steps.
S101, obtains the multiple pages that loaded in browser class application program.
Particularly, first obtain the multiple pages that loaded in browser class application program, multiple pages of showing respectively in multiple browser windows that user opens.
More specifically, browser class application program, in the time providing the network information to user, need to load the corresponding page.For example, first browser class application program receives the URL of user's input, then send request to corresponding server according to this URL, and the page data sending according to this request receiving server, create afterwards the process of playing up, and by playing up process, page data is played up, and in a window, rendering result is showed to user.In above-mentioned page loading procedure, the general corresponding window of each URL, and one of correspondence is played up process.If user opens multiple pages, ask multiple URL, correspondingly open multiple browser windows, and need to create multiple processes of playing up.Wherein, each process of playing up takies certain internal memory.
S102, obtains at least one page in multiple pages as the page to be preserved.
Particularly, if user has opened multiple pages, can take so more memory source, thereby make the travelling speed of browser class application program slack-off, therefore, in order to reduce taking of memory source, need to obtain at least one page in multiple pages as the page to be preserved for follow-up processing.
S103 obtains the page data that the page to be preserved has loaded from internal memory, and page data is saved to this locality.
Particularly, from internal memory, obtain the page data that the page to be preserved has loaded, wherein, page data refers to, browser class application program, in the time providing the network information to user, need to load corresponding webpage, the data that the page that server can send to browser class application program loads.
More specifically, obtain the page data that the page to be preserved loaded from internal memory after, page data is saved to this locality, for example, the local memory device such as disk, hard disk.
S104 deletes page data after preserving from internal memory.
Particularly, page data is saved to local again page data deletion afterwards, can discharges thus the shared memory source of the page to be preserved, thereby reduce taking of memory source.
The resource control method of the embodiment of the present invention, by the page data of at least one page in the multiple pages that loaded is saved to this locality, and from internal memory, delete page data after preserving, thereby discharge the shared memory source of at least one page, reduce EMS memory occupation amount, and then accelerated the travelling speed of browser class application program, promote user's experience.
Fig. 2 is the process flow diagram of resource control method according to an embodiment of the invention.Describe in detail and obtain at least one page in multiple pages process as the page to be preserved below in conjunction with Fig. 2, particularly, as shown in Figure 2, resource control method comprises the following steps.
S201, obtains the multiple pages that loaded in browser class application program.
S202, in the loading moment of obtaining respectively multiple pages, by loading, the moment exceedes Preset Time threshold value apart from the time interval of current time and the screening of the page in unactivated state is the page to be preserved.
Particularly, first obtain the load time of multiple pages.For example, user has opened multiple pages, obtains respectively the loading moment of each page of opening, taking a page as example, loads the moment to refer to the time point of opening this page and page data and show completely user.
In one embodiment of the invention, obtain after the load time of multiple pages, it is the page to be preserved that the load time is exceeded to the screening of Preset Time threshold value and the page in unactivated state.Wherein, Preset Time threshold value can be set according to the load time of opened multiple pages, or according to other condition, because usually setting, in embodiments of the present invention Preset Time threshold value was not limited.In addition, in the page of unactivated state, namely refer to the current not page in state of activation, for example, user is current not at the page that uses, do not browsing.
For example, the page load time in window 1 is 9: 01: 30, the page load time in window 2 is 9: 01: 50, the page load time in window 3 is 9: 03: 10, current time is 9: 06: 40, if Preset Time threshold value is 5 minutes, the page load time is that the page in the window 1 of 9: 01: 30 can be the page to be preserved.
S203, obtains current displayed page, and determines the distance between the window that window corresponding to multiple pages is corresponding with current displayed page, and the corresponding page of window that distance exceedes predeterminable range threshold value is screened is the page to be preserved.
Particularly, first obtain current displayed page, then determine the distance between the window that window corresponding to multiple pages and current displayed page are corresponding.Wherein, for the distance of the window of a window in the window of browser and current displayed page, illustrate below, suppose that user has opened 5 pages in browser, respectively corresponding 5 windows, from left to right by 5 windows called after window 1 respectively, window 2, window 3, window 4, window 5, the window of supposing again current displayed page is window 4, window 1 is 3 with the distance of the window of current displayed page so, window 2 is 2 with the distance of the window of current displayed page, window 3 is 1 with the distance of the window of current displayed page, window 5 is 1 with the distance of the window of current displayed page.
Afterwards, be the page to be preserved by corresponding the window that exceedes predeterminable range threshold value page screening.For example, if predeterminable range threshold value is 2, be the page to be preserved by the page screening of window 3 correspondences.Should be understood that, above-mentioned example only understand for convenience the embodiment of the present invention for example, can not serve as limiting the scope of the invention, in an embodiment of the present invention predeterminable range threshold value is not limited.
S204, obtains current displayed page, and in multiple pages, filters out with the page of the dereferenced of current displayed page as the page to be preserved.
Particularly, be the page to be preserved by the dereferenced webpage screening of current displayed page.For example, " dazzle national wind most " if the content that current displayed page is shown is song, another displaying content is that the page of novel " hour generation " is exactly the dereferenced webpage of current displayed page so.
In addition, if some page is the page of opening according to the sublink in current displayed page, be associating web pages, otherwise be dereferenced webpage.For example, multiple news subpage frames of being opened by same news home are associating web pages, if irrelevant with this news home, would be dereferenced webpage.
Wherein, the execution of above-mentioned S202, S203, S204 is in order to filter out the page to be preserved, and selects an enforcement.Can also according to the actual window of opening number, select the one or more enforcements in S202, S203, S204.
S205 obtains the page data that the page to be preserved has loaded from internal memory, and page data is saved to this locality.
S206 deletes page data after preserving from internal memory.
The resource control method of the embodiment of the present invention, by according to one or more in three preset rules, the multiple pages that loaded being screened, makes the selection result more accurate.The page data of the page to be preserved after screening is saved to this locality, and delete page data after preserving, and discharge the shared memory source of the page to be preserved, reduce EMS memory occupation amount, and then accelerated the travelling speed of browser class application program, promote user's experience.
Fig. 3 is the process flow diagram of resource control method according to an embodiment of the invention.Describe in detail and from internal memory, obtain the page data that the page to be preserved loaded and page data is saved to local process below in conjunction with Fig. 3, particularly, as shown in Figure 3, resource control method comprises the following steps.
S301, obtains the multiple pages that loaded in browser class application program.
S302, in the loading moment of obtaining respectively multiple pages, by loading, the moment exceedes Preset Time threshold value apart from the time interval of current time and the screening of the page in unactivated state is the page to be preserved.
S303, obtains current displayed page, and determines the distance between the window that window corresponding to multiple pages is corresponding with current displayed page, and the corresponding page of window that distance exceedes predeterminable range threshold value is screened is the page to be preserved.
S304, obtains current displayed page, and in multiple pages, filters out with the page of the dereferenced of current displayed page as the page to be preserved.
Wherein, the execution of above-mentioned S302, S303, S304 is in order to filter out the page to be preserved, and selects an enforcement.Can also according to the actual window of opening number, select the one or more enforcements in S302, S303, S304.
S305, the process of playing up of definite page to be preserved.
For example, browser class application program, in the time providing the network information to user, need to load and play up the corresponding page.First, browser class application program receives the URL of user's input, then send request to corresponding server according to this URL, and the page data sending according to this request receiving server, the process of playing up is afterwards carried out page rendering according to page data, and in a window, rendering result is showed to user.Wherein, the process of playing up of the page to be preserved has taken certain internal memory.
S306 obtains the page data of the page to be preserved that the process of playing up loaded from internal memory.
S307, set up the index information of page data, and page data is saved to this locality by manipulative indexing information.
S308 deletes page data after preserving from internal memory.
For example, user can input corresponding URL while searching for information by browser class application program, can set up the index information of page data by URL, corresponding page data can be saved to this locality according to index information, and preserve after by playing up into deletion page data, thereby minimizing internal memory occupancy.
In addition, if user in subsequent operation, need again to show being saved to the page that local page data is corresponding, can, by URL reading and saving at local page data, and the page data reading be reloaded with displayed page.
The resource control method of the embodiment of the present invention, by setting up the index information of page data of the page to be preserved, page data is saved to this locality, and preserve after by playing up process-kill page data, thereby reduce memory source occupancy, and then accelerated the travelling speed of browser class application program, promote user's experience.
Fig. 4 is the process flow diagram of resource control method according to an embodiment of the invention.Describe below in conjunction with Fig. 4 the page data that this locality has been preserved in detail and reload the process with displayed page, particularly, as shown in Figure 4, resource control method comprises the following steps.
S401, obtains the multiple pages that loaded in browser class application program.
S402, in the loading moment of obtaining respectively multiple pages, by loading, the moment exceedes Preset Time threshold value apart from the time interval of current time and the screening of the page in unactivated state is the page to be preserved.
S403, obtains current displayed page, and determines the distance between the window that window corresponding to multiple pages is corresponding with current displayed page, and the corresponding page of window that distance exceedes predeterminable range threshold value is screened is the page to be preserved.
S404, obtains current displayed page, and in multiple pages, filters out with the page of the dereferenced of current displayed page as the page to be preserved.
Wherein, the execution of above-mentioned S402, S403, S404 is in order to filter out the page to be preserved, and selects an enforcement.Can also according to the actual window of opening number, select the one or more enforcements in S402, S403, S404.
S405, the process of playing up of definite page to be preserved.
S406 obtains the page data of the page to be preserved that the process of playing up loaded from internal memory.
S407, set up the index information of page data, and page data is saved to this locality by manipulative indexing information.
S408 deletes page data after preserving from internal memory.
S409, the page that receives input is shown instruction.
Particularly, for example, the page of user being opened by step before screens, and the page data of the page to be preserved after screening has been kept to this locality, and user may need in follow-up operation again to show being saved to the page that local page data is corresponding.So in the time that user need to show that certain has been kept at the page corresponding to local page data again, input page is shown instruction, again shows preserving the page to control browser class application program.
S410, determine the page show instruction corresponding treat displayed page, and judge whether this locality has preserved the page data for the treatment of that displayed page has loaded.
Particularly, receive the page and show after instruction, determine the page show instruction corresponding treat displayed page, and judge whether this locality has preserved the page data for the treatment of that displayed page has loaded.For example, can show that the URL of user's input in instruction searches the local page data for the treatment of that displayed page has loaded of whether having preserved by the page.
S411, has preserved the page data for the treatment of that displayed page has loaded if local, treat displayed page by treating that page data that displayed page has loaded reloads to show.
S412, in the time that browser class application program exits, deletes the page data of this locality storage.
Particularly, for example, when user uses end, while exiting browser class application program, the page data of this locality storage is deleted.
In one embodiment of the invention, step S412 is optional.
The resource control method of the embodiment of the present invention by the page data of at least one page in the multiple pages that loaded is saved to this locality, and is deleted page data, thereby has been discharged the shared memory source of at least one page after preserving; When user need to when being saved to the page that local page data is corresponding and again showing, can reload the corresponding page data of this locality storage with displayed page, promote user's experience.
In order to realize above-described embodiment, the present invention also proposes a kind of resource control.
Fig. 5 is the structural representation of resource control according to an embodiment of the invention.As shown in Figure 5, resource control comprises: page acquisition module 100, page acquisition module 200 to be preserved, page data acquisition module 300, page data are preserved module 400 and page data removing module 500.
Wherein, multiple pages that page acquisition module 100 has loaded for obtaining browser class application program.
Particularly, first obtain the multiple pages that loaded in browser class application program, multiple pages of showing respectively in multiple browser windows that user opens.
More specifically, browser class application program, in the time providing the network information to user, need to load the corresponding page.For example, first browser class application program receives the URL of user's input, then send request to corresponding server according to this URL, and the page data sending according to this request receiving server, create afterwards the process of playing up, and by playing up process, page data is played up, and in a window, rendering result is showed to user.In above-mentioned page loading procedure, the general corresponding window of each URL, and one of correspondence is played up process.If user opens multiple pages, ask multiple URL, correspondingly open multiple browser windows, and need to create multiple processes of playing up.Wherein, each process of playing up takies certain internal memory.
Page acquisition module 200 to be preserved at least one page of obtaining multiple pages as the page to be preserved.
Particularly, if user has opened multiple pages, can take so more memory source, thereby make the travelling speed of browser class application program slack-off, therefore, in order to reduce taking of memory source, need to obtain at least one page in multiple pages as the page to be preserved for follow-up processing.
Page data acquisition module 300 is for obtaining the page data that the page to be preserved has loaded from internal memory.
Particularly, page data acquisition module 300 obtains the page data that the page to be preserved has loaded from internal memory, wherein, page data refers to, browser class application program is in the time providing the network information to user, need to load to corresponding webpage the data that the page that server can send to browser class application program loads.
Page data is preserved module 400 for page data is saved to this locality.Page data removing module 500 for deleting page data from internal memory after page data preservation module 400 is preserved page data.
Particularly, after page data acquisition module 300 obtains the page data that the page to be preserved loaded, page data is preserved module 400 page data is saved to this locality, for example, and the local memory device such as disk, hard disk.After page data is saved to this locality, page data removing module 500 is deleted the page data of having preserved from internal memory, can discharge thus the shared memory source of the page to be preserved, thereby has reduced taking of memory source.
The resource control of the embodiment of the present invention, by the page data of at least one page in the multiple pages that loaded is saved to this locality, and from internal memory, delete page data after preserving, thereby discharge the shared memory source of at least one page, reduce EMS memory occupation amount, and then accelerated the travelling speed of browser class application program, promote user's experience.
In one embodiment of the invention, page acquisition module 200 to be preserved is also for according to the number of the actual window of opening, and selects one or more in following three preset rules, obtains at least one page in multiple pages as the page to be preserved:
(1) obtain respectively loading moment of multiple pages, by loading, the moment exceedes Preset Time threshold value apart from the time interval of current time and the screening of the page in unactivated state is the page to be preserved.
Particularly, first obtain the load time of multiple pages.For example, user has opened multiple pages, obtains respectively the loading moment of each page of opening, taking a page as example, loads the moment to refer to the time point of opening this page and page data and show completely user.
In one embodiment of the invention, obtain after the load time of multiple pages, it is the page to be preserved that the load time is exceeded to the screening of Preset Time threshold value and the page in unactivated state.Wherein, Preset Time threshold value can be set according to the load time of opened multiple pages, or according to other condition, because usually setting, in embodiments of the present invention Preset Time threshold value was not limited.In addition, in the page of unactivated state, namely refer to the current not page in state of activation, for example, user is current not at the page that uses, do not browsing.
For example, the page load time in window 1 is 9: 01: 30, the page load time in window 2 is 9: 01: 50, the page load time in window 3 is 9: 03: 10, current time is 9: 06: 40, if Preset Time threshold value is 5 minutes, the page load time is that the page in the window 1 of 9: 01: 30 can be the page to be preserved.
(2) obtain current displayed page, and determine the distance between the window that window corresponding to multiple pages is corresponding with current displayed page, and the corresponding page of window that distance exceedes predeterminable range threshold value is screened is the page to be preserved.
Particularly, first obtain current displayed page, then determine the distance between the window that window corresponding to multiple pages and current displayed page are corresponding.Wherein, for the distance of the window of a window in the window of browser and current displayed page, illustrate below, suppose that user has opened 5 pages in browser, respectively corresponding 5 windows, from left to right by 5 windows called after window 1 respectively, window 2, window 3, window 4, window 5, the window of supposing again current displayed page is window 4, window 1 is 3 with the distance of the window of current displayed page so, window 2 is 2 with the distance of the window of current displayed page, window 3 is 1 with the distance of the window of current displayed page, window 5 is 1 with the distance of the window of current displayed page.
Afterwards, be the page to be preserved by corresponding the window that exceedes predeterminable range threshold value page screening.For example, if predeterminable range threshold value is 2, be the page to be preserved by the page screening of window 3 correspondences.Should be understood that, above-mentioned example only understand for convenience the embodiment of the present invention for example, can not serve as limiting the scope of the invention, in an embodiment of the present invention predeterminable range threshold value is not limited.
(3) obtain current displayed page, and in multiple pages, filter out with the page of the dereferenced of current displayed page as the page to be preserved.
Particularly, be the page to be preserved by the dereferenced webpage screening of current displayed page.For example, " dazzle national wind most " if the content that current displayed page is shown is song, another displaying content is that the page of novel " hour generation " is exactly the dereferenced webpage of current displayed page so.
In addition, if some page is the page of opening according to the sublink in current displayed page, be associating web pages, otherwise be dereferenced webpage.For example, multiple news subpage frames of being opened by same news home are associating web pages, if irrelevant with this news home, would be dereferenced webpage.
In one embodiment of the invention, page data acquisition module 300 is specifically for determining the process of playing up of the page to be preserved, and from internal memory, obtains the page data of the page to be preserved that the process of playing up loaded; Page data is preserved module 400 specifically for setting up the index information of page data, and page data is saved to this locality by manipulative indexing information.
For example, browser class application program, in the time providing the network information to user, need to load and play up the corresponding page.First, browser class application program receives the URL of user's input, then send request to corresponding server according to this URL, and the page data sending according to this request receiving server, the process of playing up is afterwards carried out page rendering according to page data, and in a window, rendering result is showed to user.Wherein, the process of playing up of the page to be preserved has taken certain internal memory.
For example, user can input corresponding URL while searching for information by browser class application program, can set up the index information of page data by URL, corresponding page data can be saved to this locality according to index information, and preserve after by playing up into deletion page data, thereby minimizing internal memory occupancy.
In addition, if user in subsequent operation, need again to show being saved to the page that local page data is corresponding, can, by URL reading and saving at local page data, and the page data reading be reloaded with displayed page.
Fig. 6 is the structural representation of resource control according to an embodiment of the invention.As shown in Figure 6, resource control comprises: page acquisition module 100, page acquisition module 200 to be preserved, page data acquisition module 300, page data are preserved module 400, page data removing module 500, displaying command reception module 600, judge module 700, reloaded module 800 and removing module 900.
Wherein, multiple pages that page acquisition module 100 has loaded for obtaining browser class application program.Page acquisition module 200 to be preserved at least one page of obtaining multiple pages as the page to be preserved.Page data acquisition module 300 is for obtaining the page data that the page to be preserved has loaded from internal memory.Page data is preserved module 400 for page data is saved to this locality.The page data of page data removing module 500 for deleting from internal memory after preserving.
Show that command reception module 500 is for receiving the page displaying instruction of input.
Particularly, for example, the page of user being opened by above-mentioned module screens, and the page data of the page to be preserved after screening has been kept to this locality, and user may need in follow-up operation again to show being saved to the page that local page data is corresponding.So, in the time that user need to show that certain has been kept at the page corresponding to local page data again, input page is shown instruction, again shows preserving the page to control browser class application program, and browser class application program receives the page of input and shows instruction.
Judge module 700 for determine the page show instruction corresponding treat displayed page, and judge whether this locality has preserved the page data for the treatment of that displayed page has loaded.
Particularly, after receiving page displaying instruction, what the definite page displaying of judge module 700 instruction was corresponding treats displayed page, and judges the local page data for the treatment of that displayed page has loaded of whether having preserved.For example, judge module 700 can show that the URL of user's input in instruction searches the local page data for the treatment of that displayed page has loaded of whether having preserved by the page.
Reload module 800 for judge module 700 judgement is local while having preserved the page data having loaded until displayed page, treat displayed page by treating that page data that displayed page has loaded reloads to show.
Removing module 900, in the time that browser class application program exits, is deleted the page data of this locality storage.
Particularly, for example, when user uses end, while exiting browser class application program, the page data of this locality storage is deleted.
In one embodiment of the invention, removing module 900 is optional.
The resource control of the embodiment of the present invention by the page data of at least one page in the multiple pages that loaded is saved to this locality, and is deleted page data, thereby has been discharged the shared memory source of at least one page after preserving; When user need to when being saved to the page that local page data is corresponding and again showing, can reload the corresponding page data of this locality storage with displayed page, promote user's experience.
In order to realize above-described embodiment, the present invention also proposes a kind of electronic equipment.
A kind of electronic equipment, comprising: shell, screen, processor, storer and circuit board; Screen is placed on shell, and circuit board is placed in the interior volume that shell surrounds, and processor and storer are arranged on circuit board; Storer is for stores executable programs code; Processor moves the program corresponding with executable program code by the executable program code of storing in read memory, for carrying out following steps:
S101 ', obtains the multiple pages that loaded in browser class application program.
Particularly, first obtain the multiple pages that loaded in browser class application program, in multiple browser windows that user opens corresponding multiple pages of showing.
More specifically, browser class application program, in the time providing the network information to user, need to load the corresponding page.For example, first browser class application program receives the URL of user's input, then send request to corresponding server according to this URL, and the page data sending according to this request receiving server, create afterwards the process of playing up, and by playing up process, page data is played up, and in a window, rendering result is showed to user.In above-mentioned page loading procedure, the general corresponding window of each URL, and one of correspondence is played up process.If user opens multiple pages, ask multiple URL, correspondingly open multiple browser windows, and need to create multiple processes of playing up.Wherein, each process of playing up takies certain internal memory.
S102 ', obtains at least one page in multiple pages as the page to be preserved.
Particularly, if user has opened multiple pages, can take so more memory source, thereby make the travelling speed of browser class application program slack-off, therefore, in order to reduce taking of memory source, need to obtain at least one page in multiple pages as the page to be preserved for follow-up processing.
S103 ' obtains the page data that the page to be preserved has loaded from internal memory, and page data is saved to this locality.
Particularly, from internal memory, obtain the page data that the page to be preserved has loaded, wherein, page data refers to, browser class application program, in the time providing the network information to user, need to load corresponding webpage, the data that the page that server can send to browser class application program loads.
More specifically, obtain the page data that the page to be preserved loaded from internal memory after, page data is saved to this locality, for example, the local memory device such as disk, hard disk.
S104 ' deletes page data after preserving from internal memory.
Particularly, page data is saved to local again page data deletion afterwards, can discharges thus the shared memory source of the page to be preserved, thereby reduce taking of memory source.
The electronic equipment of the embodiment of the present invention, by the page data of at least one page in the multiple pages that loaded is saved to this locality, and from internal memory, delete page data after preserving, thereby discharge the shared memory source of at least one page, reduce EMS memory occupation amount, and then accelerated the travelling speed of browser class application program, promote user's experience.
In one embodiment of the invention, processor also for: obtain respectively the loading moment of multiple pages, by loading the moment, to exceed the screening of Preset Time threshold value and the page in unactivated state apart from the time interval of current time be the page to be preserved; Or
Obtain current displayed page, and determine the distance between the window that window corresponding to multiple pages is corresponding with current displayed page, and the corresponding page of window that distance exceedes predeterminable range threshold value is screened is the page to be preserved; Or
Obtain current displayed page, and in multiple pages, filter out with the page of the dereferenced of current displayed page as the page to be preserved.
In one embodiment of the invention, processor also for: determine the process of playing up of the page to be preserved; From internal memory, obtain the page data of the page to be preserved that the process of playing up loaded; And set up the index information of page data, and page data is saved to this locality by manipulative indexing information.
In one embodiment of the invention, processor also for: receive input the page show instruction; Determine the page show instruction corresponding treat displayed page, and judge whether this locality has preserved the page data for the treatment of that displayed page has loaded; And if the local page data for the treatment of that displayed page has loaded of having preserved, treat displayed page by treating that page data that displayed page has loaded reloads to show.
In one embodiment of the invention, processor also for: in the time that browser class application program exits, the page data of this locality storage is deleted.
Should be appreciated that each several part of the present invention can realize with hardware, software, firmware or their combination.In the above-described embodiment, multiple steps or method can realize with being stored in software or the firmware carried out in storer and by suitable instruction execution system.For example, if realized with hardware, the same in another embodiment, can realize by any one in following technology well known in the art or their combination: there is the discrete logic for data-signal being realized to the logic gates of logic function, there is the special IC of suitable combinational logic gate circuit, programmable gate array (PGA), field programmable gate array (FPGA) etc.
In the description of this instructions, the description of reference term " embodiment ", " some embodiment ", " example ", " concrete example " or " some examples " etc. means to be contained at least one embodiment of the present invention or example in conjunction with specific features, structure, material or the feature of this embodiment or example description.In this manual, the schematic statement of above-mentioned term is not necessarily referred to identical embodiment or example.And specific features, structure, material or the feature of description can be with suitable mode combination in any one or more embodiment or example.
Although illustrated and described embodiments of the invention, those having ordinary skill in the art will appreciate that: in the situation that not departing from principle of the present invention and aim, can carry out multiple variation, amendment, replacement and modification to these embodiment, scope of the present invention is limited by claim and equivalent thereof.

Claims (15)

1. a resource control method, is characterized in that, comprises the following steps:
Obtain the multiple pages that loaded in browser class application program;
Obtain at least one page in described multiple page as the page to be preserved; And
The page data that described in obtaining from internal memory, the page to be preserved has loaded, and described page data is saved to this locality;
After preserving, from internal memory, delete described page data.
2. resource control method according to claim 1, is characterized in that, described at least one page of obtaining in described multiple page specifically comprise as the page to be preserved:
Obtain respectively the loading moment of described multiple pages, it is the page to be preserved that the described loading moment is exceeded to the screening of Preset Time threshold value and the page in unactivated state apart from the time interval of current time; Or
Obtain current displayed page, and determine the distance between the window that window corresponding to described multiple pages is corresponding with described current displayed page, and the corresponding page of window that described distance exceedes predeterminable range threshold value is screened is the page to be preserved; Or
Obtain current displayed page, and in described multiple pages, filter out with the page of the dereferenced of described current displayed page as the page to be preserved.
3. resource control method according to claim 1 and 2, is characterized in that, the page data that described in obtaining from internal memory, the page to be preserved has loaded, and described page data is saved to this locality, comprising:
The process of playing up of the page to be preserved described in determining;
The process of playing up described in obtaining from internal memory loaded described in the page data of the page to be preserved;
Set up the index information of described page data, and described page data is saved to described this locality by corresponding described index information.
4. resource control method according to claim 3, is characterized in that, also comprises:
The page that receives input is shown instruction;
Determine the described page show instruction corresponding treat displayed page;
Judge described this locality is treated the page data that displayed page has loaded described in whether having preserved; And
If the page data that displayed page has loaded is treated described in having preserved in described this locality, described in the described page data for the treatment of that displayed page has loaded being reloaded to show, treat displayed page.
5. resource control method according to claim 4, is characterized in that, also comprises:
In the time that described browser class application program exits, the described page data of described local storage is deleted.
6. a resource control, is characterized in that, comprising:
Page acquisition module, the multiple pages that loaded for obtaining browser class application program;
Page acquisition module to be preserved, at least one page of obtaining described multiple pages as the page to be preserved;
Page data acquisition module, the page data having loaded for the page to be preserved described in obtaining from internal memory;
Page data is preserved module, for described page data is saved to this locality; And
Page data removing module, for deleting described page data from internal memory after described page data preservation module is preserved described page data.
7. resource control according to claim 6, is characterized in that, described in page acquisition module to be preserved also for:
Obtain respectively the loading moment of described multiple pages, it is the page to be preserved that the described loading moment is exceeded to the screening of Preset Time threshold value and the page in unactivated state apart from the time interval of current time; Or
Obtain current displayed page, and determine the distance between the window that window corresponding to described multiple pages is corresponding with described current displayed page, and by the corresponding page of window that described distance exceedes predeterminable range threshold value screen be described in the page to be preserved; Or
Obtain current displayed page, and in described multiple pages, filter out with the page of the dereferenced of described current displayed page as the page to be preserved.
8. according to the resource control described in claim 6 or 7, it is characterized in that, described page data acquisition module is specifically for the process of playing up of the page to be preserved described in determining, and the process of playing up described in obtaining from internal memory loaded described in the page data of the page to be preserved; Described page data is preserved module specifically for setting up the index information of described page data, and described page data is saved to described this locality by corresponding described index information.
9. resource control according to claim 8, is characterized in that, also comprises:
Show command reception module, show instruction for the page that receives input;
Judge module, for determine the described page show instruction corresponding treat displayed page, and judge described this locality is treated the page data that displayed page has loaded described in whether having preserved; And
Reload module, when judge the page data that described this locality loaded until displayed page described in having preserved at described judge module, described in the described page data for the treatment of that displayed page has loaded is reloaded to show, treat displayed page.
10. resource control according to claim 9, is characterized in that, also comprises:
Removing module, in the time that described browser class application program exits, deletes the described page data of described local storage.
11. 1 kinds of electronic equipments, is characterized in that, comprising: shell, screen, processor, storer and circuit board;
Described screen is placed on described shell, and described circuit board is placed in the interior volume that described shell surrounds, and described processor and described storer are arranged on described circuit board;
Described storer is for stores executable programs code;
Described processor moves the program corresponding with described executable program code by reading the executable program code of storing in described storer, for:
Obtain the multiple pages that loaded in browser class application program;
Obtain at least one page in described multiple page as the page to be preserved; And
The page data that described in obtaining from internal memory, the page to be preserved has loaded, and described page data is saved to this locality;
After preserving, from internal memory, delete described page data.
12. electronic equipments according to claim 11, is characterized in that, described processor also for:
Obtain respectively the loading moment of described multiple pages, it is the page to be preserved that the described loading moment is exceeded to the screening of Preset Time threshold value and the page in unactivated state apart from the time interval of current time; Or
Obtain current displayed page, and determine the distance between the window that window corresponding to described multiple pages is corresponding with described current displayed page, and the corresponding page of window that described distance exceedes predeterminable range threshold value is screened is the page to be preserved; Or
Obtain current displayed page, and in described multiple pages, filter out with the page of the dereferenced of described current displayed page as the page to be preserved.
13. according to the electronic equipment described in claim 11 or 12, it is characterized in that, described processor also for:
The process of playing up of the page to be preserved described in determining;
The process of playing up described in obtaining from internal memory loaded described in the page data of the page to be preserved;
Set up the index information of described page data, and described page data is saved to described this locality by corresponding described index information.
14. electronic equipments according to claim 13, is characterized in that, described processor also for:
The page that receives input is shown instruction;
Determine the described page show instruction corresponding treat displayed page;
Judge described this locality is treated the page data that displayed page has loaded described in whether having preserved; And
If the page data that displayed page has loaded is treated described in having preserved in described this locality, described in the described page data for the treatment of that displayed page has loaded being reloaded to show, treat displayed page.
15. electronic equipments according to claim 14, is characterized in that, described processor also for:
In the time that described browser class application program exits, the described page data of described local storage is deleted.
CN201410220130.6A 2014-05-22 2014-05-22 Resource control method and device, and electronic device Pending CN104008155A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410220130.6A CN104008155A (en) 2014-05-22 2014-05-22 Resource control method and device, and electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410220130.6A CN104008155A (en) 2014-05-22 2014-05-22 Resource control method and device, and electronic device

Publications (1)

Publication Number Publication Date
CN104008155A true CN104008155A (en) 2014-08-27

Family

ID=51368812

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410220130.6A Pending CN104008155A (en) 2014-05-22 2014-05-22 Resource control method and device, and electronic device

Country Status (1)

Country Link
CN (1) CN104008155A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105930537A (en) * 2016-06-23 2016-09-07 乐视控股(北京)有限公司 Page storing method and electronic equipment
CN106354791A (en) * 2016-08-24 2017-01-25 乐视控股(北京)有限公司 Browser webpage window processing method and device
CN109558229A (en) * 2018-11-23 2019-04-02 北京小米移动软件有限公司 Browser control method and device
CN109684576A (en) * 2018-12-14 2019-04-26 平安城市建设科技(深圳)有限公司 Web page resources lazyness loads monitoring method, device, equipment and storage medium

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120060083A1 (en) * 2009-02-26 2012-03-08 Song Yuan Method for Use in Association With A Multi-Tab Interpretation and Rendering Function
CN102880616A (en) * 2011-07-15 2013-01-16 腾讯科技(深圳)有限公司 Browser page loading method and device

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120060083A1 (en) * 2009-02-26 2012-03-08 Song Yuan Method for Use in Association With A Multi-Tab Interpretation and Rendering Function
CN102880616A (en) * 2011-07-15 2013-01-16 腾讯科技(深圳)有限公司 Browser page loading method and device

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105930537A (en) * 2016-06-23 2016-09-07 乐视控股(北京)有限公司 Page storing method and electronic equipment
WO2017219524A1 (en) * 2016-06-23 2017-12-28 乐视控股(北京)有限公司 Page saving method and electronic device
CN106354791A (en) * 2016-08-24 2017-01-25 乐视控股(北京)有限公司 Browser webpage window processing method and device
CN109558229A (en) * 2018-11-23 2019-04-02 北京小米移动软件有限公司 Browser control method and device
CN109684576A (en) * 2018-12-14 2019-04-26 平安城市建设科技(深圳)有限公司 Web page resources lazyness loads monitoring method, device, equipment and storage medium

Similar Documents

Publication Publication Date Title
CN108845816B (en) Application program updating method, system, computer device and storage medium
US10712915B2 (en) Information presentation using a client on a terminal
CN107832100A (en) A kind of loading method and its terminal of APK plug-in units
CN111159436A (en) Method and device for recommending multimedia content and computing equipment
CN104461632A (en) Web App loading method and device
CN104008155A (en) Resource control method and device, and electronic device
CN106961454A (en) Document down loading method, device and terminal device
CN112114849B (en) Resource updating method and device
CN103501327B (en) Method for down loading and device based on mobile terminal application
CN104268229A (en) Resource obtaining method and device based on multi-process browser
CN104216740A (en) Application software management method and device and terminal
CN104462283A (en) Method, device and client for requesting webpage elements in mobile terminal
CN104239567A (en) Method and device for processing dimension in data warehouse
CN106649654A (en) Data updating method and device
CN104050001A (en) Resource processing method, device and equipment based on Android system
CN103324679B (en) Control method and equipment that in a kind of caching server, data update
CN106899558B (en) Access request processing method and device and storage medium
CN106598649A (en) Application program installation method and device, and electronic equipment
CN106470351B (en) Page display method and page display device
CN112528125A (en) Method and device for avoiding content repeated recommendation, electronic equipment and storage medium
CN116226150A (en) Data processing method, device, equipment and medium based on distributed database
CN114637946A (en) Resource data processing method and device and electronic equipment
CN104717286A (en) Data processing method, terminal, server and system
CN115203603A (en) Table page rendering method and device, electronic device and storage medium
CN105278987B (en) A kind of information processing method and electronic equipment

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20140827

RJ01 Rejection of invention patent application after publication