CN106341533A - Method and device for loading network resource in application - Google Patents
Method and device for loading network resource in application Download PDFInfo
- Publication number
- CN106341533A CN106341533A CN201610778162.7A CN201610778162A CN106341533A CN 106341533 A CN106341533 A CN 106341533A CN 201610778162 A CN201610778162 A CN 201610778162A CN 106341533 A CN106341533 A CN 106341533A
- Authority
- CN
- China
- Prior art keywords
- terminal capability
- capability rank
- page
- rank
- terminal
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04M—TELEPHONIC COMMUNICATION
- H04M1/00—Substation equipment, e.g. for use by subscribers
- H04M1/72—Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
- H04M1/724—User interfaces specially adapted for cordless or mobile telephones
- H04M1/72403—User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/60—Software deployment
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/70—Software maintenance or management
- G06F8/76—Adapting program code to run in a different environment; Porting
Abstract
The invention relates to a method and device for loading a network resource in an application. The method comprises that an application interface is entered; a performance parameter of hardware on which a local operation application relies is obtained; the capability level of a local terminal is determined among multiple preset terminal capability levels according to the performance parameter; a resource identification corresponding to the network resource to be loaded in the application interface is obtained; and the network resource corresponding to the obtained resource identification is loaded in a resource loading manner that matches the capability level of the terminal. The method and device provided by the invention can improve the compatibility of the application in different terminals.
Description
Technical field
The present invention relates to field of terminal technology, the method and apparatus of load networks resource in more particularly to a kind of application.
Background technology
With the progress of technology, the performance of terminal is overall to be improved constantly, and the installable application of terminal is also more and more abundanter,
The application that terminal is passed through to run thereon can realize various functions.Video Applications for viewing video are such as installed, just permissible
Watch various Online Videos by Video Applications.At present, apply compatibility on different terminals it is ensured that applying to improve
Trouble-free operation in terminal as much as possible, reduces the resource consumption of application various functions typically in development and application as far as possible,
Enable an application to be applied to various terminals.
However, enriching constantly with application function, the leeway reducing the resource consumption of application is very limited, and by force
Reducing resource consumption can lead to the realization of the partial function applied to be affected.Therefore, it is difficult at present effectively improve apply not
With the compatibility in terminal.
Content of the invention
Based on this it is necessary to be directed to the problems referred to above, provide a kind of compatibility that can effectively improve and apply on different terminals
The method and apparatus of load networks resource in the application of property.
A kind of method of load networks resource in application, comprising:
Enter application interface;
Obtain the performance parameter that local runtime applies relied on hardware;
Local terminal capability rank is determined from multiple default terminal capability ranks according to described performance parameter;
Obtain the corresponding resource identification of Internet resources to be loaded in described application interface;
Corresponding using the described resource identification loading acquisition with the resource load mode that described terminal capability rank matches
Described Internet resources.
The device of load networks resource in a kind of application, comprising:
Application interface module, for entering application interface;
Performance parameter acquisition module, applies the performance parameter of relied on hardware for obtaining local runtime;
Terminal capability rank determination module, for determining from multiple default terminal capability ranks according to described performance parameter
Local terminal capability rank;
Resource identification acquisition module, for obtaining Internet resources to be loaded in described application interface corresponding resource mark
Know;
Load-on module, for being loaded described in acquisition using the resource load mode matching with described terminal capability rank
The corresponding described Internet resources of resource identification.
The method and apparatus of load networks resource in above-mentioned application, applies the performance ginseng of relied on hardware using local runtime
Number judges local terminal capability rank, thus being loaded using the resource load mode matching with local terminal capability rank
Internet resources.The hardware performance of terminal makes a distinction according to different terminal capability ranks, and same application operates in different ends
On end, the resource load mode load networks resource that matched using the terminal capability rank with place terminal, improve application
Compatibility on different terminals.
Brief description
Fig. 1 is the systematic difference environment map of load networks resource in application in an embodiment;
Fig. 2 is the internal structure schematic diagram of terminal in an embodiment;
Fig. 3 is the schematic flow sheet of the method for load networks resource in application in an embodiment;
Fig. 4 is to determine local terminal energy according to performance parameter from multiple default terminal capability ranks in an embodiment
The schematic flow sheet of the step of power rank;
Fig. 5 is to determine local terminal according to performance parameter from multiple default terminal capability ranks in another embodiment
The schematic flow sheet of the step of ability grade;
Fig. 6 is to determine local terminal energy according to performance parameter from multiple default terminal capability ranks in an embodiment
The sequential chart of the step of power rank;
Fig. 7 is the schematic flow sheet of the method for load networks resource in application in another embodiment;
Fig. 8 is the application interface schematic diagram of the terminal display of high configuration level in an embodiment;
Fig. 9 is the application interface schematic diagram of the terminal display of middle configuration level in an embodiment;
Figure 10 is the application interface schematic diagram of the terminal display of low configuration level in an embodiment;
Figure 11 is the structured flowchart of the device of load networks resource in application in an embodiment;
Figure 12 is the structured flowchart of the device of load networks resource in application in another embodiment;
Figure 13 is the structured flowchart of the device of load networks resource in application in further embodiment;
Figure 14 is the structured flowchart of the device of load networks resource in application in another embodiment;
Figure 15 is the structured flowchart of the device of load networks resource in application in an embodiment.
Specific embodiment
In order that the objects, technical solutions and advantages of the present invention become more apparent, below in conjunction with drawings and Examples, right
The present invention is further elaborated.It should be appreciated that specific embodiment described herein is only in order to explain the present invention, and
It is not used in the restriction present invention.
Fig. 1 is the systematic difference environment map of load networks resource in application in an embodiment.With reference to Fig. 1, this system
Including terminal 110 server 120.Running in terminal 110 has application, and terminal 110 enters application interface;Obtaining local runtime should
Performance parameter with relied on hardware;Local terminal capability is determined from multiple default terminal capability ranks according to performance parameter
Rank;Obtain the corresponding resource identification of Internet resources to be loaded in application interface;Match using with terminal capability rank
Resource load mode loads, from server 120, the corresponding Internet resources of resource identification obtaining.Performance can also be joined by terminal 110
Number sends to server 120, and what the reception server 120 was fed back determines from multiple default terminal capability ranks according to performance parameter
Local terminal capability rank.
Fig. 2 is the internal structure schematic diagram of terminal in an embodiment.As shown in Fig. 2 this terminal include total by system
Processor, non-volatile memory medium, built-in storage, network interface, display screen and input equipment that line connects.Wherein, terminal
Non-volatile memory medium be stored with operating system, also include a kind of device of load networks resource in application, in this application
The method that the device of load networks resource is used for realizing load networks resource in a kind of application.This processor be used for provide calculate and
Control ability, supports the operation of whole terminal.Built-in storage in terminal loads in the application in non-volatile memory medium
The device of Internet resources provides running environment, and can be stored with this built-in storage computer-readable instruction, and this computer-readable refers to
Order is when executed by, the method that can make load networks resource in a kind of application of computing device.The display screen of terminal can
To be LCDs or electric ink display screen etc., input equipment can be on display screen cover touch layer it is also possible to
It is the button of setting, trace ball or Trackpad or external keyboard, Trackpad or mouse etc. in terminal enclosure.This is eventually
End can be mobile phone, panel computer, personal digital assistant, Wearable or television set etc..Those skilled in the art are permissible
Understand, the structure shown in Fig. 2, the only block diagram of the part-structure related to application scheme, do not constitute to the application
The restriction of the terminal that scheme is applied thereon, specific terminal can include ratio part more or less of shown in figure, or
Person combines some parts, or has different part arrangements.
Fig. 3 is the schematic flow sheet of the method for load networks resource in application in an embodiment.The present embodiment is with the party
Method is applied to terminal in above-mentioned Fig. 1 and illustrates, and with reference to Fig. 3, the method specifically includes following steps:
S302, enters application interface.
Application interface is the interactive interface that application provides.Terminal can start application after enter application interface it is also possible to
Application enters application interface when background state returns to foreground state.Terminal can when the triggering of default event is detected or
Current time meets to start during default time conditions to be applied.Default event such as clicks on event or the pressing of application icon
Event of physical button etc..Default time conditions such as current time reaches Preset Time, or current time with default when
Between between time difference be less than or equal to Preset Time poor.
S304, obtains the performance parameter that local runtime applies relied on hardware.
Local runtime application is the application that local terminal is run.Local runtime applies relied on hardware to be included in local end
In end, local runtime applies relied on hardware to include one of built-in storage (abbreviation internal memory) and processor or two kinds.Process
Device includes one of central processing unit (cpu) and graphic process unit (gpu) or two kinds.Performance parameter is that reflection hardware operation should
The concrete quantization parameter of performance.
In one embodiment, performance parameter includes one of internal memory performance parameter and processor performance parameter or two
Kind.Internal memory performance parameter such as total amount of memory or internal memory residue active volume etc., general memory total capacity or internal memory remain
Remaining active volume is higher, represents that internal memory performance is stronger.Processor performance parameter such as processor frequencies or processor core calculation
Or processor remaining available resource etc., general processor frequencies or processor core calculation or processor remaining available resource
Higher, represent that processor performance is stronger.Wherein internal memory residue active volume and processor remaining available resource can reflect accordingly hard
The instant state of part, can more accurately weigh hardware performance.
S306, determines local terminal capability rank according to performance parameter from multiple default terminal capability ranks.
Specifically, in advance terminal is divided rank according to wherein running the performance parameter applying relied on hardware, formed many
Individual discrete default terminal capability rank.Terminal can be according to the performance parameter obtaining, from multiple default terminal capability ranks really
The fixed terminal capability rank mated the most with local performance parameter.Illustrate, multiple default terminal capability ranks are such as high
Configuration level, middle configuration level and low configuration level.
In one embodiment, terminal can send performance parameter to server, and it is local that the reception server is fed back
Terminal capability rank, local terminal capability rank is selected from multiple default terminal capability ranks, and local terminal capability level
Do not match with the performance parameter sending.
S308, obtains the corresponding resource identification of Internet resources to be loaded in application interface.
Wherein, Internet resources refer to the resource from network, can be specifically picture on server, video data or
Person's voice data etc..From Network Capture and be buffered in local resource and fall within Internet resources.Resource identification is used for identifying accordingly
Internet resources.Loading refers to Internet resources are loaded in internal memory, and the Internet resources of loading can be used directly, and such as will add
The Internet resources carrying are shown or calculate.Resource identification can be url (the uniform resource of Internet resources
Locator, URL).Resource identification is used for identifying a kind of or a class Internet resources.
S310, loads, using with the resource load mode that terminal capability rank matches, the corresponding net of resource identification obtaining
Network resource.
In one embodiment, terminal can obtain configuration file corresponding with terminal capability rank, according in configuration file
Configuration parameter determine resource load mode, thus according to determine resource load mode load obtain resource identification corresponding
Internet resources.
Wherein, the resource load mode of Internet resources can be the control to multiple Internet resources loading sequences to be loaded
System.Such as resource load mode can be to load multiple Internet resources to be loaded simultaneously, or by multiple nets to be loaded
Network resource is according to fixed time interval Asynchronous loading, or multiple Internet resources just to be loaded synchronously load.Different
Resource load mode is different to the resource consumption of terminal hardware, and for different terminal capability ranks, the resource using adaptation adds
Load mode load networks resource, had both enabled basic function, can reduce the consumption to hardware as far as possible again.
Wherein, load simultaneously refer to that the request Concurrency simultaneously triggering for load networks resource delivers to server, and receive
The Internet resources of server feedback.Refer to be spaced loading at every fixed time wherein according to fixed time interval Asynchronous loading
One Internet resources, until by multiple Internet resources loadeds to be loaded.Synchronous loading refers to multiple nets to be loaded
One of network resource reloads another after loading success, until loaded.
In one embodiment, if being locally highest terminal capability rank, multiple networks that can be just to be loaded provide
Source loads simultaneously.If being locally non-highest terminal capability rank, can be by multiple Internet resources to be loaded according to fixation
Time interval Asynchronous loading.Terminal capability rank is lower, and time interval is longer.
Illustrate it is assumed that default terminal capability partition of the level is high configuration level, middle configuration level and low configuration stage
Not.For high configuration level, the resource load mode that can be loaded using multiple Internet resources simultaneously.For middle configuration level, can
Resource load mode with the time interval Asynchronous loading according to 20ms (millisecond) using multiple Internet resources.For low configuration stage
Not, then multiple Internet resources can be adopted according to the resource load mode of the time interval Asynchronous loading of 200ms.
The method of load networks resource in above-mentioned application, is judged using the performance parameter that local runtime applies relied on hardware
Local terminal capability rank, thus using the resource load mode load networks money matching with local terminal capability rank
Source.The hardware performance of terminal makes a distinction according to different terminal capability ranks, and same application operates in different terminals, adopts
The resource load mode load networks resource being matched with the terminal capability rank with place terminal, improves and applies different whole
Compatibility on end.It is additionally, since the application not needing to develop different editions with compatible different terminal, can carry to a certain extent
The efficiency of high development and application.
Fig. 4 is s306 in an embodiment, is determined local from multiple default terminal capability ranks according to performance parameter
The schematic flow sheet of the step of terminal capability rank.With reference to Fig. 4, step s306 specifically includes following steps:
S402, obtains each self-corresponding parameter value scope of multiple default terminal capability ranks.
Wherein, the corresponding parameter value scope of terminal capability rank, refers to belong to the terminal of this terminal capability rank
Hardware the optional span of performance parameter.There is not friendship in the parameter value scope between different terminal capability ranks
Collection.The corresponding parameter value scope of one terminal capability rank can include many sub- spans.Multiple default terminal capabilities
The union of rank self-corresponding parameter value scope can be performance parameter can selected value complete or collected works.
Illustrate it is assumed that multiple default terminal capability rank is respectively high configuration level, middle configuration level and low joins
Put rank.Then preset each self-corresponding parameter value scope of terminal capability rank to be respectively as follows:
High configuration level: memory size < 1g, or, cpu core number≤2 and memory size==1g.
Middle configuration level: memory size > 1g and memory size are less than 2g, or, cpu core number > 2 and memory size=
=1g.
Low configuration level: memory size > 2g.
S404, determines the parameter value scope including performance parameter from the parameter value scope obtaining.
Specifically, performance parameter can be compared one by one by terminal with each the parameter value scope obtaining, and determine and include this property
The parameter value scope of energy parameter.If performance parameter is multiple, terminal can be by every performance parameter and the parameter value obtaining
Corresponding with performance parameter in scope it is compared from span, so that it is determined that each including the sub- value of every performance parameter
The parameter value scope that scope is constituted.
S406, terminal capability rank default corresponding to the parameter value scope of determination is defined as local terminal capability level
Not.
In the present embodiment, multiple default terminal capability ranks each to should have parameter value scope, using the performance obtaining
Parameter and the parameter value scope obtaining, can accurately determine the terminal capability rank of local terminal, consequently facilitating locally eventually
End adopts suitable resource load mode load networks resource.
Fig. 5 is s306 in another embodiment, is determined locally according to performance parameter from multiple default terminal capability ranks
The step of terminal capability rank schematic flow sheet.With reference to Fig. 5, step s306 specifically includes following steps:
S502, by performance parameter and terminal models reporting parameters to server so that server is being stored with and terminating machine
The terminal capability rank that during the terminal capability rank of shape parameter coupling, feedback is mated with terminal models parameter, be not stored with and end
The terminal capability rank that during the terminal capability rank of terminal shape parameter coupling, feedback is mated with performance parameter.
Wherein, terminal models parameter refers to reflect the parameter of terminal type, can be the mainboard mark of local terminal, produce
The combination with one or more of terminal models known by trade mark.Terminal can will carry the level of performance parameter and terminal models parameter
Do not invite and ask transmission to server, judged whether the terminal capability rank mated with terminal models parameter by server.If depositing
, then server by mate terminal capability level feedback to terminal.If not existing, server is again from multiple default terminal energy
Determine, in power rank, the terminal capability rank mated with performance parameter, and by the terminal capability level feedback mated with performance parameter
To terminal.
S504, the reception server feedback terminal capability rank and as local terminal capability rank.
Specifically, what local terminal received has the terminal capability rank of server feedback, is and terminal models parameter
The terminal capability rank joined, or the terminal capability rank mated with performance parameter, local terminal is by the terminal receiving energy
Power rank is as local terminal capability rank.
In the present embodiment, even if due to performance parameter identical terminal, its hardware actual performance also can have differences, for
The terminal of specific model using the terminal capability rank different with the terminal capability rank being determined according to its performance parameter so that
In ground application interface, the compatibility of load networks resource is more preferable.
Fig. 6 is s306 in an embodiment, is determined local from multiple default terminal capability ranks according to performance parameter
The sequential chart of the step of terminal capability rank.With reference to Fig. 6, step s306 specifically includes following steps:
S602, terminal obtains performance parameter and the terminal models parameter of itself.
S604, terminal sends the level request carrying performance parameter and terminal models parameter to server.
S606, the suggested terminals ability grade that server lookup is mated with terminal models parameter.
S608, if server inquires, returns the terminal capability rank inquiring, if not inquiring, returns and performance
The acquiescence terminal capability rank of parameter coupling.
S610, if server returns suggested terminals ability grade, terminal adopts suggested terminals ability grade as local
Terminal capability rank;If server returns acquiescence terminal capability rank, terminal is using acquiescence terminal capability rank as this
The terminal capability rank on ground.
S612, terminal loads the required net of application using the resource load mode matching with local terminal capability rank
Network resource, to realize the application experience corresponding to local terminal capability rank.
In the present embodiment, even if due to performance parameter identical terminal, its hardware actual performance also can have differences, for
The terminal of specific model using the terminal capability rank different with the terminal capability rank being determined according to its performance parameter so that
In ground application interface, the compatibility of load networks resource is more preferable.
In one embodiment, application interface includes multiple pages of changeable display;S308 specifically includes: obtains application
The corresponding resource identification of Internet resources to be loaded in the current page of interface;When terminal capability rank is to allow to load non-present page
During the default terminal capability rank of the Internet resources in face, obtain network to be loaded in the page of the non-present page in multiple pages
The corresponding resource identification of resource;In this application, the method for load networks resource also includes: shows that in current page load works as
The Internet resources of the front page.
Fig. 7 is the schematic flow sheet of the method for load networks resource in application in another embodiment.With reference to Fig. 7, the party
Method specifically includes following steps:
S702, enters application interface.
S704, obtains the performance parameter that local runtime applies relied on hardware.
S706, determines local terminal capability rank according to performance parameter from multiple default terminal capability ranks.
S708, obtains the corresponding resource identification of Internet resources to be loaded in application interface current page.
Specifically, application interface includes multiple pages of changeable display, and each page is properly termed as a page card
(tab).Every time show one of multiple pages in application interface, and can when triggering page layout switch instruction multiple pages it
Between switch.When local terminal is arbitrarily to preset terminal capability rank, local terminal all can load the network money of current page
Source.
S710, when terminal capability rank is the default terminal capability rank allowing to load the Internet resources of the non-present page
When, obtain the corresponding resource identification of Internet resources to be loaded in the page of the non-present page in multiple pages.
S712, loads, using with the resource load mode that terminal capability rank matches, the corresponding net of resource identification obtaining
Network resource.
Specifically it is allowed to load the non-present page Internet resources default terminal capability rank, higher than do not allow load
The default terminal capability rank of the Internet resources of the non-present page.The resource identification obtaining includes net to be loaded in current page
The corresponding resource identification of network resource, can also include Internet resources to be loaded in the page of the non-present page corresponding resource mark
Know.
Further, the higher terminal of general terminal capability rank, memory size is sufficient, can load the net of the non-present page
Network resource, carries out prestrain with the Internet resources to the non-present page;The terminal that terminal capability rank is told somebody what one's real intentions are, content capacity compares
Little, only load the Internet resources of current page, prestrain is not carried out to the Internet resources of the non-present page.
S714, shows the Internet resources of the current page of loading in current page.
Specifically, if terminal capability rank is relatively low, only load the Internet resources of current page, terminal hardware money can be saved
Source;If terminal capability rank is higher, the Internet resources of the current page of loading not only can be shown, can also be non-by prestrain
The Internet resources of current page, to accelerate the switch speed between the page, improve Consumer's Experience.
S716, obtains page layout switch instruction.
Current page is switched to target pages according to page layout switch instruction by s718.
Specifically, page layout switch instruction can be moving direction instruction, and multiple page ordered arrangements, when getting movement side
To during instruction, current page is switched to another page on this moving direction instruction direction adjacent, this page is
Target pages.
In one embodiment, page layout switch instruction can be the selected instruction to target pages, show in application interface
There is the one-to-one page-tag with multiple pages, when the trigger action to target pages label is detected, the triggering page is cut
Change instruction, current page is switched to the corresponding target pages of target pages label.
S720, shows the Internet resources in target pages.
S722, the default terminal of the Internet resources of the page before being to need release to switch after switching the page when terminal capability rank
The Internet resources in page during ability grade, before release switching.
Illustrate it is assumed that multiple default terminal capability rank is respectively high configuration level, middle configuration level and low joins
Put rank.Then preset each self-corresponding configuration parameter of terminal capability rank can be described as:
High configuration level: the picture of prestrain all pages during display homepage;The switching page does not discharge the page before switching
The picture of middle loading.Wherein homepage when one of multiple pages page, be to enter the page directly displaying during application interface.
Middle configuration level: only load the picture of current page;The switching page does not discharge the picture of the loading of the page before switching.
Low configuration level: only load the picture of current page;The picture that the page before switching page release switching loads.
In the present embodiment, if only loading the Internet resources of current page, terminal hardware resource can be saved it is adaptable to hardware
The weaker terminal of performance.If loading the Internet resources of current page and the Internet resources of other pages of the non-present page, permissible
Realize rapidly switching between the page, be suitable for the stronger terminal of hardware performance.Network money in the page before release switching
Source, can ensure to switch the smoothness of the page, it is to avoid Caton phenomenon to a certain extent.Different terminals can be realized different
Consumer's Experience.
In one embodiment, in application, the method for load networks resource also includes: when terminal capability rank is to allow to show
Show background picture default terminal capability rank when, the background of application interface is set to default picture;When terminal capability rank
During for not allowing the default terminal capability rank showing Background Picture, the background of application interface is set to pre-set color value.
Specifically, for the terminal that terminal hardware performance is stronger, the terminal capability level allowing to show Background Picture can be adopted
Not, the background of application interface is set to default picture, such that it is able to provide the user more preferable interactive form.For terminal capabilities
Weaker terminal, can adopt the terminal capability rank not allowing to show Background Picture, the background of application interface is set to preset
Color value, to reduce the consumption to hardware resource.
In one embodiment, Internet resources include media data;In application, the method for load networks resource also includes: root
Configure the capacity of play buffer according to terminal capability rank;By the media data cache of the capacity less than or equal to configuration to broadcasting
In relief area;It is successively read media data to play out from play buffer.
Media data such as video data and/or voice data.Illustrate, for high configuration level, broadcasting can be set
The capacity of relief area is 100m;For middle configuration level, the capacity that can arrange play buffer is 80m;For low configuration level,
The capacity that broadcasting buffer area can be arranged is 30m.Media data is stored respective volume when receiving media data by terminal
In play buffer, play when from play buffer successively frame by frame reading media data play out.
In the present embodiment, for different terminal capability ranks, the play buffer of different capabilities is set, it is possible to achieve right
The reasonable utilization of memory source.
The principle of the method for load networks resource in above-mentioned application is described with a concrete application scene below.Default whole
End ability grade is divided into high configuration level, middle configuration level and low configuration level, and corresponding resource load mode configures such as
Under:
High configuration level: the background of each page adopts identical or different default picture;Prestrain during display homepage is owned
The picture of the page;The switching page does not discharge the picture loading in the page before switching;The capacity of setting play buffer is 100m.
Middle configuration level: the background of each page adopts identical or different default picture;Only load the picture of current page;
The switching page does not discharge the picture of the loading of the page before switching;The capacity of setting play buffer is 80m
Low configuration level: the background filling pre-set color value of each page;Only load the picture of current page;The switching page is released
Put the picture of the loading of the page before switching;The capacity that buffer area is play in setting is 30m.
With reference to Fig. 8, if terminal is high configuration level, load the picture of all pages when application interface is shown homepage,
The background of each page is using default picture, and the picture that the page does not load in releasing memory after handover, when playing video
The video data of 100m at most can be cached.With reference to Fig. 9, if terminal is middle configuration level, in application interface during displayed page only
Load the picture of current page, the background of each page, using default picture, can assume loading procedure during the switching page, and the page
The picture not loaded in releasing memory after handover, at most can cache the video counts of 80m when playing video when playing video
According to.With reference to Figure 10, if terminal is low configuration level, application interface only loads the picture of current page, often during displayed page
The background of the individual page adopts pre-set color value to replace, and can assume loading procedure, and the page will discharge after handover during the switching page
The picture of the page before the switching loading in internal memory, at most can cache the video data of 30m when playing video.
Figure 11 is the structured flowchart of the device 1100 of load networks resource in application in an embodiment.With reference to Figure 11, should
Specifically included with the device 1100 of middle load networks resource: application interface module 1101, performance parameter acquisition module 1102, terminal
Ability grade determining module 1103, resource identification acquisition module 1104 and load-on module 1105.
Application interface module 1101, for entering application interface.
Performance parameter acquisition module 1102, applies the performance parameter of relied on hardware for obtaining local runtime.
Terminal capability rank determination module 1103, for determining from multiple default terminal capability ranks according to performance parameter
Local terminal capability rank.
Resource identification acquisition module 1104, for obtaining Internet resources to be loaded in application interface corresponding resource mark
Know.
Load-on module 1105, for loading, using the resource load mode matching with terminal capability rank, the resource obtaining
Identify corresponding Internet resources.
The device 1100 of load networks resource in above-mentioned application, applies the performance parameter of relied on hardware using local runtime
Judge local terminal capability rank, thus net is loaded using the resource load mode matching with local terminal capability rank
Network resource.The hardware performance of terminal makes a distinction according to different terminal capability ranks, and same application operates in different terminals
On, the resource load mode load networks resource that matched using the terminal capability rank with place terminal, improve and apply
Compatibility on different terminals.It is additionally, since the application not needing to develop different editions with compatible different terminal, can necessarily journey
The efficiency of development and application is improved on degree.
In one embodiment, performance parameter includes one of internal memory performance parameter and processor performance parameter or two
Kind.
In one embodiment, terminal capability rank determination module 1103 is additionally operable to obtain multiple default terminal capability ranks
Each self-corresponding parameter value scope;The parameter value scope including performance parameter is determined from the parameter value scope obtaining;
Terminal capability rank default corresponding to the parameter value scope of determination is defined as local terminal capability rank.
In the present embodiment, multiple default terminal capability ranks each to should have parameter value scope, using the performance obtaining
Parameter and the parameter value scope obtaining, can accurately determine the terminal capability rank of local terminal, consequently facilitating locally eventually
End adopts suitable resource load mode load networks resource.
In one embodiment, terminal capability rank determination module 1103 is additionally operable to performance parameter and terminal models parameter
Report to server so that server is fed back and terminating machine when being stored with the terminal capability rank mated with terminal models parameter
The terminal capability rank of shape parameter coupling, feedback and property when not being stored with the terminal capability rank mated with terminal models parameter
The terminal capability rank of energy parameter coupling;The reception server feedback terminal capability rank and as local terminal capability level
Not.
In the present embodiment, even if due to performance parameter identical terminal, its hardware actual performance also can have differences, for
The terminal of specific model using the terminal capability rank different with the terminal capability rank being determined according to its performance parameter so that
In ground application interface, the compatibility of load networks resource is more preferable.
In one embodiment, application interface includes multiple pages of changeable display;Resource identification acquisition module 1104
It is additionally operable to obtain the corresponding resource identification of Internet resources to be loaded in application interface current page;When terminal capability rank is fair
When being permitted the default terminal capability rank of Internet resources loading the non-present page, obtain the page of the non-present page in multiple pages
In the corresponding resource identification of Internet resources to be loaded.With reference to Figure 12, device 1100 also includes: Internet resources display module
1106, for showing the Internet resources of the current page of loading in current page.
Figure 13 is the structured flowchart of the device 1100 of load networks resource in application in further embodiment.With reference to Figure 13,
Device 1100 also includes: page layout switch module 1107 and resource release module 1108.
Page layout switch module 1107, for obtaining page layout switch instruction;According to page layout switch instruction, current page is switched
For target pages.
Resource release module 1108, for being to need to discharge the net of the page before switching after switching the page when terminal capability rank
The Internet resources in page during the default terminal capability rank of network resource, before release switching.
Internet resources display module 1106 is additionally operable to show the Internet resources in target pages.
In the present embodiment, if only loading the Internet resources of current page, terminal hardware resource can be saved it is adaptable to hardware
The weaker terminal of performance.If loading the Internet resources of current page and the Internet resources of other pages of the non-present page, permissible
Realize rapidly switching between the page, be suitable for the stronger terminal of hardware performance.Network money in the page before release switching
Source, can ensure to switch the smoothness of the page, it is to avoid Caton phenomenon to a certain extent.Different terminals can be realized different
Consumer's Experience.
Figure 14 is the structured flowchart of the device 1100 of load networks resource in application in another embodiment.With reference to Figure 14,
Device 1100 also includes: background setup module 1109, for being the default end allowing to show Background Picture when terminal capability rank
During the ability grade of end, the background of application interface is set to default picture;When terminal capability rank is not allow display background figure
During the default terminal capability rank of piece, the background of application interface is set to pre-set color value.
Specifically, for the terminal that terminal hardware performance is stronger, the terminal capability level allowing to show Background Picture can be adopted
Not, the background of application interface is set to default picture, such that it is able to provide the user more preferable interactive form.For terminal capabilities
Weaker terminal, can adopt the terminal capability rank not allowing to show Background Picture, the background of application interface is set to preset
Color value, to reduce the consumption to hardware resource.
In one embodiment, Internet resources include media data.Figure 15 is load networks in application in an embodiment
The structured flowchart of the device 1100 of resource.With reference to Figure 14, device 1100 also includes: buffer pool size setup module 1110, caching
Module 1111 and playing module 1112.
Buffer pool size setup module 1110, for configuring the capacity of play buffer according to terminal capability rank.
Cache module 1111, for being less than or equal to the media data cache of the capacity configuring to play buffer by total amount
In.
Playing module 1112, plays out for being successively read media data from play buffer.
In the present embodiment, for different terminal capability ranks, the play buffer of different capabilities is set, it is possible to achieve right
The reasonable utilization of memory source.
One of ordinary skill in the art will appreciate that realizing all or part of flow process in above-described embodiment method, it is permissible
Instruct related hardware to complete by computer program, this program can be stored in a non-volatile computer and can read storage
In medium, this program is upon execution, it may include as the flow process of the embodiment of above-mentioned each method.Wherein, this storage medium can be magnetic
Dish, CD, read-only memory (read-only memory, rom) etc..
Each technical characteristic of above example can arbitrarily be combined, for making description succinct, not to above-described embodiment
In all possible combination of each technical characteristic be all described, as long as however, the combination of these technical characteristics does not have lance
Shield, is all considered to be the scope of this specification record.
Above example only have expressed the several embodiments of the present invention, and its description is more concrete and detailed, but can not
Therefore it is construed as limiting the scope of the patent.It should be pointed out that for the person of ordinary skill of the art,
On the premise of present inventive concept, some deformation can also be made and improve, these broadly fall into protection scope of the present invention.
Therefore, the protection domain of patent of the present invention should be defined by claims.
Claims (16)
1. a kind of application in load networks resource method, comprising:
Enter application interface;
Obtain the performance parameter that local runtime applies relied on hardware;
Local terminal capability rank is determined from multiple default terminal capability ranks according to described performance parameter;
Obtain the corresponding resource identification of Internet resources to be loaded in described application interface;
Load the corresponding institute of described resource identification obtaining using with the resource load mode that described terminal capability rank matches
State Internet resources.
2. method according to claim 1 is it is characterised in that described performance parameter includes internal memory performance parameter and processor
One of performance parameter or two kinds.
3. method according to claim 1 it is characterised in that described according to described performance parameter from multiple default terminal energy
Determine in power rank that the step of local terminal capability rank includes:
Obtain each self-corresponding parameter value scope of multiple default terminal capability ranks;
The parameter value scope including described performance parameter is determined from the parameter value scope obtaining;
Terminal capability rank default corresponding to the parameter value scope of determination is defined as local terminal capability rank.
4. method according to claim 1 it is characterised in that described according to described performance parameter from multiple default terminal energy
Determine in power rank that the step of local terminal capability rank includes:
By described performance parameter and terminal models reporting parameters to server so that described server is being stored with and described terminal
The terminal capability rank that during the terminal capability rank of type parameter coupling, feedback is mated with described terminal models parameter, is not storing
There is the terminal capability rank that during the terminal capability rank mated with described terminal models parameter, feedback is mated with described performance parameter;
Receive the terminal capability rank of described server feedback and as local terminal capability rank.
5. method according to claim 1 is it is characterised in that described application interface includes multiple pages of changeable display
Face;The described step obtaining the corresponding resource identification of Internet resources to be loaded in described application interface includes:
Obtain the corresponding resource identification of Internet resources to be loaded in described application interface current page;
When described terminal capability rank is the default terminal capability rank allowing to load the Internet resources of the non-present page, obtain
The corresponding resource identification of Internet resources to be loaded in the page of the non-present page in multiple pages;
Methods described also includes:
The Internet resources of the current page of loading are shown in current page.
6. method according to claim 5 is it is characterised in that methods described also includes:
Obtain page layout switch instruction;
Current page is switched to by target pages according to the instruction of described page layout switch;
Show the Internet resources in described target pages;
The default terminal capability of the Internet resources of the page before being to need release to switch after switching the page when described terminal capability rank
The Internet resources in page during rank, before release switching.
7. method according to claim 1 is it is characterised in that methods described also includes:
When described terminal capability rank is the default terminal capability rank allowing to show Background Picture, by described application interface
Background is set to default picture;
When described terminal capability rank is the default terminal capability rank not allowing to show Background Picture, by described application interface
Background be set to pre-set color value.
8. method according to claim 1 is it is characterised in that described Internet resources include media data;Methods described is also
Including:
Configure the capacity of play buffer according to described terminal capability rank;
By the media data cache of the described capacity less than or equal to configuration in described play buffer;
It is successively read media data from described play buffer to play out.
9. a kind of application in load networks resource device it is characterised in that include:
Application interface module, for entering application interface;
Performance parameter acquisition module, applies the performance parameter of relied on hardware for obtaining local runtime;
Terminal capability rank determination module, for determining locally according to described performance parameter from multiple default terminal capability ranks
Terminal capability rank;
Resource identification acquisition module, for obtaining the corresponding resource identification of Internet resources to be loaded in described application interface;
Load-on module, for loading, using the resource load mode matching with described terminal capability rank, the described resource obtaining
Identify corresponding described Internet resources.
10. device according to claim 9 is it is characterised in that described performance parameter includes internal memory performance parameter and process
One of device performance parameter or two kinds.
11. devices according to claim 9 are it is characterised in that described terminal capability rank determination module is additionally operable to obtain
The each self-corresponding parameter value scope of multiple default terminal capability rank;Determine from the parameter value scope obtaining described in including
The parameter value scope of performance parameter;Terminal capability rank default corresponding to the parameter value scope of determination is defined as local
Terminal capability rank.
12. devices according to claim 9 are it is characterised in that described terminal capability rank determination module is additionally operable to institute
State performance parameter and terminal models reporting parameters to server so that described server is being stored with and described terminal models parameter
The terminal capability rank mated with described terminal models parameter of feedback during the terminal capability rank of coupling, be not stored with described
The terminal capability rank that during the terminal capability rank of terminal models parameter coupling, feedback is mated with described performance parameter;Receive described
The terminal capability rank of server feedback as local terminal capability rank.
13. devices according to claim 9 are it is characterised in that described application interface includes multiple pages of changeable display
Face;Described resource identification acquisition module is additionally operable to obtain Internet resources to be loaded in described application interface current page corresponding
Resource identification;When described terminal capability rank is the default terminal capability rank allowing to load the Internet resources of the non-present page
When, obtain the corresponding resource identification of Internet resources to be loaded in the page of the non-present page in multiple pages;
Described device also includes:
Internet resources display module, for showing the Internet resources of the current page of loading in current page.
14. devices according to claim 13 are it is characterised in that described device also includes:
Page layout switch module, for obtaining page layout switch instruction;Current page is switched to by mesh according to the instruction of described page layout switch
The mark page;
Resource release module, for being the network money needing to discharge the page before switching after switching the page when described terminal capability rank
The Internet resources in page during the default terminal capability rank in source, before release switching;
Described Internet resources display module is additionally operable to show the Internet resources in described target pages.
15. devices according to claim 9 are it is characterised in that described device also includes:
Background setup module, for being the default terminal capability rank allowing to show Background Picture when described terminal capability rank
When, the background of described application interface is set to default picture;When described terminal capability rank is not allow to show Background Picture
Default terminal capability rank when, the background of described application interface is set to pre-set color value.
16. devices according to claim 9 are it is characterised in that described Internet resources include media data;Described device is also
Including:
Buffer pool size setup module, for configuring the capacity of play buffer according to described terminal capability rank;
Cache module, for being less than or equal to the media data cache of the described capacity configuring to described play buffer by total amount
In;
Playing module, plays out for being successively read media data from described play buffer.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610778162.7A CN106341533B (en) | 2016-08-30 | 2016-08-30 | The method and apparatus of load networks resource in |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610778162.7A CN106341533B (en) | 2016-08-30 | 2016-08-30 | The method and apparatus of load networks resource in |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106341533A true CN106341533A (en) | 2017-01-18 |
CN106341533B CN106341533B (en) | 2019-11-29 |
Family
ID=57823741
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610778162.7A Active CN106341533B (en) | 2016-08-30 | 2016-08-30 | The method and apparatus of load networks resource in |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106341533B (en) |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106941567A (en) * | 2017-03-27 | 2017-07-11 | 广州优视网络科技有限公司 | Show method, device and the user terminal of network picture |
CN107832142A (en) * | 2017-10-11 | 2018-03-23 | 广东欧珀移动通信有限公司 | The resource allocation method and equipment of application program |
CN110704184A (en) * | 2019-09-19 | 2020-01-17 | 海南车智易通信息技术有限公司 | Application memory optimization method and device and mobile terminal |
CN111010293A (en) * | 2019-11-27 | 2020-04-14 | 中国联合网络通信集团有限公司 | Virtual resource management method and device |
CN111147464A (en) * | 2019-12-18 | 2020-05-12 | 北京智明星通科技股份有限公司 | Method and device for determining servers among online rooms and electronic equipment |
WO2022028165A1 (en) * | 2020-08-04 | 2022-02-10 | 中兴通讯股份有限公司 | Cache management method, terminal, and storage medium |
WO2023066095A1 (en) * | 2021-10-21 | 2023-04-27 | 华为技术有限公司 | Rendering method and related apparatus |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20010020269A1 (en) * | 2000-02-02 | 2001-09-06 | Takahisa Kawade | Method of loading initial program in processor system |
CN101777068A (en) * | 2009-12-31 | 2010-07-14 | 优视科技有限公司 | Web page pre-reading and integrally browsing system for mobile communication equipment terminals and application method thereof |
CN102737037A (en) * | 2011-04-07 | 2012-10-17 | 北京搜狗科技发展有限公司 | Webpage pre-reading method, device and browser |
CN102740142A (en) * | 2012-06-13 | 2012-10-17 | 百视通网络电视技术发展有限责任公司 | Method for providing IPTV (Internet Protocol Television) service to different terminals and IPTV service system |
CN103984781A (en) * | 2014-06-11 | 2014-08-13 | 北京金山网络科技有限公司 | Webpage loading method and device |
CN104850415A (en) * | 2014-02-13 | 2015-08-19 | 腾讯科技(深圳)有限公司 | Method and apparatus for loading pages |
-
2016
- 2016-08-30 CN CN201610778162.7A patent/CN106341533B/en active Active
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20010020269A1 (en) * | 2000-02-02 | 2001-09-06 | Takahisa Kawade | Method of loading initial program in processor system |
CN101777068A (en) * | 2009-12-31 | 2010-07-14 | 优视科技有限公司 | Web page pre-reading and integrally browsing system for mobile communication equipment terminals and application method thereof |
CN102737037A (en) * | 2011-04-07 | 2012-10-17 | 北京搜狗科技发展有限公司 | Webpage pre-reading method, device and browser |
CN102740142A (en) * | 2012-06-13 | 2012-10-17 | 百视通网络电视技术发展有限责任公司 | Method for providing IPTV (Internet Protocol Television) service to different terminals and IPTV service system |
CN104850415A (en) * | 2014-02-13 | 2015-08-19 | 腾讯科技(深圳)有限公司 | Method and apparatus for loading pages |
CN103984781A (en) * | 2014-06-11 | 2014-08-13 | 北京金山网络科技有限公司 | Webpage loading method and device |
Cited By (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106941567A (en) * | 2017-03-27 | 2017-07-11 | 广州优视网络科技有限公司 | Show method, device and the user terminal of network picture |
WO2018176960A1 (en) * | 2017-03-27 | 2018-10-04 | 广州优视网络科技有限公司 | Network picture displaying method, device and user terminal |
CN107832142A (en) * | 2017-10-11 | 2018-03-23 | 广东欧珀移动通信有限公司 | The resource allocation method and equipment of application program |
CN110704184A (en) * | 2019-09-19 | 2020-01-17 | 海南车智易通信息技术有限公司 | Application memory optimization method and device and mobile terminal |
CN110704184B (en) * | 2019-09-19 | 2022-09-06 | 海南车智易通信息技术有限公司 | Application memory optimization method and device and mobile terminal |
CN111010293A (en) * | 2019-11-27 | 2020-04-14 | 中国联合网络通信集团有限公司 | Virtual resource management method and device |
CN111147464A (en) * | 2019-12-18 | 2020-05-12 | 北京智明星通科技股份有限公司 | Method and device for determining servers among online rooms and electronic equipment |
WO2022028165A1 (en) * | 2020-08-04 | 2022-02-10 | 中兴通讯股份有限公司 | Cache management method, terminal, and storage medium |
WO2023066095A1 (en) * | 2021-10-21 | 2023-04-27 | 华为技术有限公司 | Rendering method and related apparatus |
Also Published As
Publication number | Publication date |
---|---|
CN106341533B (en) | 2019-11-29 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106341533A (en) | Method and device for loading network resource in application | |
CN104113787B (en) | Based on the comment method of program, terminal, server and system | |
CN112004086B (en) | Video data processing method and device | |
CN110333947B (en) | Method, device, equipment and medium for loading subcontracting resources of game application | |
CN111050203B (en) | Video processing method and device, video processing equipment and storage medium | |
CN113041625B (en) | Live interface display method, device and equipment and readable storage medium | |
CN112616091B (en) | Virtual article sending method and device, computer equipment and storage medium | |
CN112184469B (en) | Group interaction method, device, equipment and storage medium | |
CN113485617A (en) | Animation display method and device, electronic equipment and storage medium | |
CN111061550A (en) | Task processing method, device, equipment and storage medium | |
CN113506086A (en) | Task issuing method and device, computer equipment and medium | |
CN113038273A (en) | Video frame processing method and device, storage medium and electronic equipment | |
CN113163213B (en) | Method, device and storage medium for live game | |
CN116016817A (en) | Video editing method, device, electronic equipment and storage medium | |
CN111443858A (en) | Application interface display method and device, terminal and storage medium | |
CN106375862A (en) | GIF picture acquisition method and apparatus, and terminal | |
CN110619513A (en) | Electronic resource obtaining method, electronic resource distributing method and related equipment | |
CN113468346B (en) | Resource processing method and device, electronic equipment and storage medium | |
CN113242453B (en) | Barrage playing method, server and computer readable storage medium | |
CN112492331B (en) | Live broadcast method, device, system and storage medium | |
CN112988552B (en) | Application program testing method, device, equipment and storage medium | |
CN111062709B (en) | Resource transfer mode recommendation method and device, electronic equipment and storage medium | |
CN112423099A (en) | Video loading method and device and electronic equipment | |
CN111984871A (en) | Friend recommendation method, friend recommendation display method, device and equipment | |
CN112423037B (en) | Television program playing method, device, terminal equipment and computer storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |