WO2012075942A1 - Web page browsing method, browser and mobile terminal - Google Patents

Web page browsing method, browser and mobile terminal Download PDF

Info

Publication number
WO2012075942A1
WO2012075942A1 PCT/CN2011/083619 CN2011083619W WO2012075942A1 WO 2012075942 A1 WO2012075942 A1 WO 2012075942A1 CN 2011083619 W CN2011083619 W CN 2011083619W WO 2012075942 A1 WO2012075942 A1 WO 2012075942A1
Authority
WO
WIPO (PCT)
Prior art keywords
data
mobile terminal
file system
local file
webpage
Prior art date
Application number
PCT/CN2011/083619
Other languages
French (fr)
Chinese (zh)
Inventor
梁捷
Original Assignee
广州市动景计算机科技有限公司
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 广州市动景计算机科技有限公司 filed Critical 广州市动景计算机科技有限公司
Publication of WO2012075942A1 publication Critical patent/WO2012075942A1/en

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

Definitions

  • the present invention relates to the field of mobile communications, and in particular to a mobile terminal based web browsing method, a browser, and a mobile terminal having the same. Background technique
  • steps 1), 2), and 3) are very time consuming in the above four steps, and usually take several seconds to ten seconds. Can be completed.
  • steps 1), 2), and 3) are very time consuming in the above four steps, and usually take several seconds to ten seconds. Can be completed.
  • most of the medium and low-end mobile phones only have a dozen or more megabytes of memory, so there is often a situation in which the memory is exhausted after the mobile terminal opens multiple web pages. Close some webpages and release some memory to continue to open new webpages, which greatly affects the user's online experience through mobile terminals.
  • the present invention uses a local caching mechanism in a mobile terminal to cache the result data of the web page analysis and the typesetting to a memory with a large amount of storage in the mobile terminal, and then read the cached data in the memory when necessary. It not only saves the time of networking, analysis, and typesetting processes required to browse the web, but also saves the memory and traffic of the mobile terminal.
  • a webpage browsing method including: determining, according to a submitted webpage open request, whether cached data of a requested webpage exists in a local file system of a mobile terminal, the cached data having a suitable The first data structure of the mobile terminal local storage and call processing; if the cached data of the requested webpage exists in the local file system of the mobile terminal, the cached data of the requested webpage is directly extracted from the local file system of the mobile terminal. Display; otherwise, the mobile terminal analyzes, formats, and converts the acquired webpage raw data into the result data suitable for display by the mobile terminal after acquiring the original data of the requested webpage through networking.
  • the method may further include: converting the result data into the memory block having the first data structure; and writing the memory block to a local file system of the mobile terminal In, as cached data.
  • the step of directly extracting cached data of the requested webpage from the local file system of the mobile terminal for display may include: reading a cache of the requested webpage from the local file system Data; converting the read cached data into result data suitable for display by the mobile terminal; and displaying the result data on the mobile terminal.
  • the result data includes structural body data of all controls of the webpage
  • the control structure data includes analyzing the original data of the webpage, and the information position, height, and width after the typesetting And basic property information of the control.
  • the mobile terminal cleans the cached data in the local file system according to a preset rule to delete cache data that is not used for a long time, and release the storage space of the local file system.
  • the method may further include: establishing a dynamic cache record in a local file system of the mobile terminal, dynamically recording information of the cached data in the local file system of the mobile terminal; The terminal determines whether the cached data of the requested webpage exists in the local file system according to the dynamic cache record in the local file system.
  • a browser including: a cache determining unit, configured to determine, according to a submitted webpage open request, whether cached data of the requested webpage exists in a local file system of the mobile terminal; a data extracting unit, configured to: when the cached data of the requested webpage exists in a local file system of the mobile terminal, extract cached data of the requested webpage from a local file system of the mobile terminal, for displaying on the mobile terminal a webpage raw data obtaining and processing unit, configured to acquire, by the network, the original data of the requested webpage when the cached data of the requested webpage does not exist in the local file system of the mobile terminal, and obtain the original webpage of the obtained webpage
  • the data is analyzed, typeset, and converted into result data suitable for display by the mobile terminal for display on the mobile terminal.
  • the browser may further include: a cache data establishing unit, configured to establish, based on the result data, cache data suitable for storage locally on the mobile terminal.
  • the cache data establishing unit may include: a memory block generating module, configured to convert the result data into a memory block; and a writing module, configured to use the memory block as The cached data is written to the local file system of the mobile terminal to establish cached data of the mobile terminal.
  • the memory block generating module may include: a format conversion module, configured to convert the result data into a binary format by a shift according to a rule; and a memory block forming module, configured to The data in the converted binary format is appended to the structure memory block in the form of a binary stream.
  • the browser may further include: a cache data dynamic recording unit, configured to dynamically record dynamic cache record information of the cache data in the local file system of the mobile terminal, where the cache The judging unit judges whether the cache data of the requested webpage exists in the local file system according to the dynamic cache record information recorded by the cache data dynamic recording unit.
  • a mobile terminal including a browser as described above. After adopting the above technical solution for establishing a local caching mechanism for the browsed webpage, the mobile terminal can fully utilize the idle time to cache the result data of the downloaded, analyzed, and typeset webpage into the local file system with large storage capacity of the mobile terminal, and browse again. The webpage only needs to read the data in the local file system of the mobile terminal and directly display it, which saves the time of downloading, analyzing and typographical networking, and effectively improves the browsing efficiency of the user.
  • FIG. 1 is a flow chart showing a webpage browsing method of a mobile terminal according to the present invention
  • FIG. 2 is a block diagram showing a structure of a browser according to the present invention
  • FIG. 3 is a block diagram showing an example of a cache data establishing unit in FIG. 2;
  • the web page raw data is analyzed (step S104), typeset (step S105), converted into result data composed of data types of different formats suitable for display by the mobile terminal; and then according to the knot
  • the data is displayed on the mobile terminal to the requested webpage (step S106); and the result data is converted into a memory block, and finally the memory block is stored as cache data to a local cache of the mobile terminal, and the data structure of the cached data is suitable.
  • the local file system may be a memory in the mobile terminal.
  • the result data here contains different structure data of all the controls (text, hyperlink, edit box, button, picture, etc.) of the webpage.
  • the structure data of the control is composed of data types of different formats, usually including the download of the network.
  • the original web page data is analyzed, the information position, height, width, and basic properties of the control are information. Since the data structure suitable for the result data displayed by the mobile terminal is not suitable for the storage of the local file system of the mobile terminal, in the present invention, in the process of writing the result data to the local file system of the mobile terminal, The result data needs to be converted into a first data structure suitable for local storage and call processing of the mobile terminal, and then stored locally in the mobile terminal.
  • the specific process is: first converting the result data of all controls of the webpage into memory by means of memory block conversion. Block data, and then writing the converted memory block data to the local file system of the mobile terminal for caching; correspondingly, extracting the cached data of the required webpage from the local file system
  • the display is performed, the memory block data of the required web page is read from the local file system, and then the memory block data is converted into result data suitable for display by the mobile terminal for display.
  • the conversion from the result data to the memory block data is mainly realized by the data shift conversion method.
  • the result data of all the controls of the webpage is converted into a binary format by shifting according to the rules, and then the converted binary format data can be added to form a binary stream, which is a large file storage system suitable for the local file system. Memory block.
  • char* buf is the final memory block and the space is large enough.
  • the conversion manner of converting the memory block data stored in the local file system into the result data is opposite to the manner of converting the result data from the result data to the memory block data, first
  • the whole memory block data representing the web page is decomposed into a single structure memory block, and then the structure memory block is separately decomposed into a binary format, and finally the binary format is inversely shifted into the data type required by the result data.
  • the local file system of the mobile terminal refers to a mobile phone card stored in the mobile terminal (eg,
  • the mobile terminal After the result data is written to the local file system of the mobile terminal, if the result is stored, it is possible to enable the mobile terminal to have more memory processing data of the front end, thereby improving the data processing capability of the mobile terminal.
  • the mobile terminal In order to make full use of the storage space of the mobile terminal, in the present invention, the mobile terminal also uses the preset rules (such as the number of times the webpage is browsed within a prescribed time, the security level of the webpage, the content classification of the webpage, etc.) to the file system.
  • the cached data is cleaned to delete the cached data of the webpage that is less likely to be used or reused for a long time, and to release the storage space of the file system, thereby improving the utilization of the storage space of the mobile terminal.
  • a dynamic cache record is also established in the local file system of the mobile terminal for dynamically recording information of the cached data in the local file system of the mobile terminal.
  • the mobile terminal can conveniently determine whether the cached data of the requested webpage exists in the local file system, cache data that needs to be extracted quickly, and timely and effectively manage the cached data according to the record information, thereby improving the movement.
  • Utilization of terminal storage space. 2 is a block diagram showing the structure of a browser 10 in accordance with the present invention. As shown in FIG.
  • the present invention further provides a browser 10, including a cache determination unit 1, a cache data extraction unit 2, a webpage original data acquisition and processing unit 3, and cache data, corresponding to the webpage browsing method of the mobile terminal.
  • Unit 4 is established.
  • the cache judging unit 1 is configured to determine, according to the webpage open request submitted by the user, whether the cached data of the requested webpage exists in the local file system of the mobile terminal.
  • the webpage original data acquisition and processing unit 3 obtains the original data of the requested webpage through networking, and analyzes the acquired raw data of the webpage, The typesetting is converted into result data suitable for display by the mobile terminal.
  • the result data consists of data types in different formats.
  • the browser 10 may further include a cache data establishing unit 4, configured to convert the result data into memory block data having a first data structure suitable for local storage and call processing of the mobile terminal, and The memory block data is written as cache data into a local file system of the mobile terminal to establish cache data of the mobile terminal.
  • the cache data establishing unit 4 may include a memory block generating unit 41 for generating memory block data based on the result data; and a writing unit 42 for using the The memory block data is written as cache data in the local file system of the mobile terminal to establish cache data of the mobile terminal.
  • the memory block generating unit 41 may further include a format conversion module (not shown) for using the result data by shifting by rules. Converting to a binary format; and a memory block data forming module (not shown) for appending the converted binary format data to a structured memory block in the form of a binary stream. Then, the writing unit 42 stores the memory block as cache data in the local file system of the mobile terminal to establish cache data of the mobile terminal.
  • the result data includes structural data of all controls of the webpage, and the control structure data includes information about the original data of the webpage, information position, height, width, and basic property information of the control.
  • the number of caches is further included.
  • the management unit (not shown), after the cache data establishing unit 4 converts the result data into a memory block and stores the data as cache data to the local file system of the mobile terminal, it is determined whether the result data is currently browsed. If not, delete the result data in the memory of the mobile terminal to release the memory.
  • the cache data management unit further cleans the cached data in the file system according to a preset rule to delete cache data that is not used for a long time, and release the storage space of the file system.
  • the browser may further be provided with a cached data dynamic recording unit (not shown) for dynamically recording a dynamic cache record of information of the cached data in the local file system of the mobile terminal, so that the mobile terminal records the cache according to the dynamic cache.
  • a cached data dynamic recording unit (not shown) for dynamically recording a dynamic cache record of information of the cached data in the local file system of the mobile terminal, so that the mobile terminal records the cache according to the dynamic cache.
  • the cache data dynamic recording unit may be disposed outside the cache data management unit or in the cache data management unit.
  • FIG. 4 shows a block schematic diagram of a mobile terminal 20 in accordance with the present invention, the mobile terminal 20 including a browser 10 as described above. 4)
  • the browser herein may include various variations of the browser in accordance with the present invention.
  • the mobile terminal of the present invention is typically a variety of terminal devices that may perform web browsing, such as mobile phones, personal digital assistants, etc., and thus the scope of protection of the present invention should not be limited to a particular type of mobile terminal.
  • the method according to the invention can also be implemented as a computer program executed by a CPU.
  • the computer program is executed by the CPU, the above-described functions defined in the method of the present invention are performed.
  • the above method steps and system elements can also be implemented with a controller or processor and a computer readable storage device for storing a computer program that causes the controller or processor to perform the steps or unit functions described above.
  • non-volatile memory may include read only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash Memory.
  • Volatile memory can include random access memory (RAM), which can act as external cache memory.
  • RAM can be obtained in a variety of forms, such as synchronous RAM (DRAM), dynamic RAM.
  • DRAM Direct Rambus RAM
  • SDRAM Synchronous DRAM
  • DDR SDRAM Double Data Rate SDRAM
  • ESDRAM Enhanced SDRAM
  • SLDRAM Synchronous Link DRAM
  • DRRAM Direct Rambus RAM
  • DSP digital signal processor
  • ASIC dedicated Integrated circuit
  • FPGA field programmable gate array
  • a general purpose processor may be a microprocessor, but in the alternative, the processor may be any conventional processor, controller, microcontroller or state machine.
  • the processor can also be implemented as a combination of computing devices, e.g., a combination of a DSP and a microprocessor, a plurality of microprocessors, one or more microprocessors in conjunction with a DSP core, or any other such configuration.
  • the steps of a method or algorithm described in connection with the disclosure herein may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two.
  • the software module can reside in RAM memory, flash memory, ROM memory, EPROM memory, EEPROM memory, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
  • An exemplary storage medium is coupled to the processor, such that the processor can read information from or write information to the storage medium.
  • the storage medium can be integrated with the processor.
  • the processor and the storage medium can reside in an ASIC.
  • the ASIC can reside in the user terminal.
  • the processor and the storage medium may reside as discrete components in the user terminal.

Landscapes

  • Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Between Computers (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The present invention provides a web page browsing method of a mobile terminal: according to a submitted web page open request, judging whether buffered data of a requested web page exists in a local file system of a mobile terminal; if yes, directly extracting the buffered data of the requested web page from the local file system of the mobile terminal for display; otherwise, the mobile terminal acquiring original data of the requested web page through networking, and then analyzing and typesetting the acquired original data of the web page, so as to convert the original data to result data applicable to being displayed by the mobile terminal for display. The present invention can effectively reduce time of the process of networking, analyzing and typesetting performed by the mobile terminal, and can save the memory and traffic of the mobile terminal.

Description

说 明 书 网页浏览方法、 浏览器以及移动终端 技术领域  Description book web browsing method, browser and mobile terminal
本发明涉及移动通信领域, 具体地说, 涉及一种基于移动终端的网页浏 览方法、 浏览器以及具有该浏览器的移动终端。 背景技术  The present invention relates to the field of mobile communications, and in particular to a mobile terminal based web browsing method, a browser, and a mobile terminal having the same. Background technique
通过移动终端设备登陆网络并浏览网页, 依靠其不受时间、 地点、 设备 等限制的灵活性和自主性, 成为现如今更为热门和广泛的上网途径。 在使用 移动终端进行上网浏览的过程中, 要实现最终的网页浏览通常需要通过以下 四个步骤来实现:  By accessing the network and browsing the web through mobile devices, relying on its flexibility and autonomy that is not limited by time, location, equipment, etc., it has become a more popular and widely used way of surfing. In the process of using the mobile terminal to browse the Internet, the final web page browsing usually needs to be implemented in the following four steps:
1 )联网获取网页原始数据;  1) accessing the original data of the webpage by networking;
2 )分析网页原始数据;  2) analyzing the original data of the webpage;
3 )根据移动终端的屏幕大小、 网页中的文字、 图片大小等因素对网页进 行重新排版;  3) re-layout the webpage according to factors such as the screen size of the mobile terminal, the text in the webpage, the size of the image, and the like;
4 )将重新排版后的网页显示在移动终端的屏幕上。  4) Display the re-formatted web page on the screen of the mobile terminal.
由于移动终端上网的数据传输速度以及移动终端本身的数据处理能力的 限制, 在上述四个步骤中, 步骤 1 ) 、 2 ) 、 3 )都是非常耗时的, 通常需要几 秒到十几秒才能完成。 并且, 由于目前手机的内存资源有限, 大部分的中、 低端手机只有十几兆、 甚至只有几兆的内存, 因此, 经常会产生在移动终端 打开多个网页后内存耗尽的情形, 需要关闭部分网页、 释放部分内存才能继 续打开新的网页, 大大影响用户通过移动终端进行的上网体验。  Due to the data transmission speed of the mobile terminal and the data processing capability of the mobile terminal itself, steps 1), 2), and 3) are very time consuming in the above four steps, and usually take several seconds to ten seconds. Can be completed. Moreover, due to the limited memory resources of mobile phones, most of the medium and low-end mobile phones only have a dozen or more megabytes of memory, so there is often a situation in which the memory is exhausted after the mobile terminal opens multiple web pages. Close some webpages and release some memory to continue to open new webpages, which greatly affects the user's online experience through mobile terminals.
而且, 如果用户需要再次浏览刚浏览过的网页, 则需要重新执行上面的 四个步骤, 不但浪费用户的上网时间, 而且由于需要在相对较短的时间内进 行重复数据的下载, 还浪费了用户的流量。 发明内容 基于现有技术中存在的上述问题, 本发明在移动终端使用本地緩存机制, 把网页分析、 排版后的结果数据緩存到移动终端中存储量大的存储器, 需要 时再读取存储器中的緩存数据, 从而不但节省浏览网页所需要的联网、 分析、 排版过程的时间, 还能够节省移动终端的内存和流量。 Moreover, if the user needs to browse the webpage that has just been browsed again, the above four steps need to be re-executed, which not only wastes the user's online time, but also wastes the user because of the need to download the repeated data in a relatively short time. Traffic. Summary of the invention Based on the above problems existing in the prior art, the present invention uses a local caching mechanism in a mobile terminal to cache the result data of the web page analysis and the typesetting to a memory with a large amount of storage in the mobile terminal, and then read the cached data in the memory when necessary. It not only saves the time of networking, analysis, and typesetting processes required to browse the web, but also saves the memory and traffic of the mobile terminal.
根据本发明的一个方面, 提供了一种网页浏览方法, 包括: 根据提交的 网页打开请求, 判断在移动终端的本地文件系统中是否存在所请求的网页的 緩存数据, 所述緩存数据具有适于移动终端本地存储及调用处理的第一数据 结构; 如果在移动终端的本地文件系统中存在所请求的网页的緩存数据, 则 直接从移动终端的本地文件系统中提取所请求的网页的緩存数据进行显示; 否则移动终端在通过联网获取所请求的网页的原始数据后对所获取的网页原 始数据进行分析、 排版, 并转换为适于移动终端显示的结果数据进行显示。  According to an aspect of the present invention, a webpage browsing method is provided, including: determining, according to a submitted webpage open request, whether cached data of a requested webpage exists in a local file system of a mobile terminal, the cached data having a suitable The first data structure of the mobile terminal local storage and call processing; if the cached data of the requested webpage exists in the local file system of the mobile terminal, the cached data of the requested webpage is directly extracted from the local file system of the mobile terminal. Display; otherwise, the mobile terminal analyzes, formats, and converts the acquired webpage raw data into the result data suitable for display by the mobile terminal after acquiring the original data of the requested webpage through networking.
在上述方面的一个或多个示例中, 所述方法还可以包括: 将所述结果数 据转换为所述具有第一数据结构的内存块; 以及将所述内存块写入移动终端 的本地文件系统中, 作为緩存数据。  In one or more examples of the above aspects, the method may further include: converting the result data into the memory block having the first data structure; and writing the memory block to a local file system of the mobile terminal In, as cached data.
在上述方面的一个或多个示例中, 将所述结果数据转换为内存块的步骤 可以包括: 通过移位按规则将由不同结构体组成的结果数据转换为二进制格 式, 其中所述结构体由不同格式的数据类型组成, 以及将所转换的二进制格 式的数据追加组成二进制流形式的结构体内存块。  In one or more examples of the above aspects, the step of converting the result data into a memory block may include: converting result data composed of different structures into a binary format by shifting according to a rule, wherein the structure is different The data type of the format is composed, and the data in the converted binary format is appended to the structure memory block in the form of a binary stream.
在上述方面的一个或多个示例中, 从移动终端的本地文件系统中直接提 取所请求的网页的緩存数据进行显示的步骤可以包括: 从所述本地文件系统 中读取所请求的网页的緩存数据; 将所读取的緩存数据转换为适于移动终端 显示的结果数据; 以及在所述移动终端上显示所述结果数据。  In one or more examples of the above aspects, the step of directly extracting cached data of the requested webpage from the local file system of the mobile terminal for display may include: reading a cache of the requested webpage from the local file system Data; converting the read cached data into result data suitable for display by the mobile terminal; and displaying the result data on the mobile terminal.
在上述方面的一个或多个示例中, 所述结果数据包括网页的所有控件的 结构体数据, 所述控件结构体数据包括对所述网页原始数据进行分析、 排版 后的信息位置、 高度、 宽度以及控件基本属性信息。  In one or more examples of the foregoing aspect, the result data includes structural body data of all controls of the webpage, and the control structure data includes analyzing the original data of the webpage, and the information position, height, and width after the typesetting And basic property information of the control.
在上述方面的一个或多个示例中, 所述移动终端根据预设的规则对所述 本地文件系统中的緩存数据进行清理, 以删除长期不用的緩存数据, 释放所 述本地文件系统的存储空间。 在上述方面的一个或多个示例中, 所述方法还可以包括: 在所述移动终 端的本地文件系统中建立动态緩存记录, 动态记录移动终端的本地文件系统 中緩存数据的信息; 所述移动终端根据本地文件系统中的动态緩存记录来判 断本地文件系统中是否存在所请求的网页的緩存数据。 In one or more examples of the foregoing aspect, the mobile terminal cleans the cached data in the local file system according to a preset rule to delete cache data that is not used for a long time, and release the storage space of the local file system. . In one or more examples of the above aspect, the method may further include: establishing a dynamic cache record in a local file system of the mobile terminal, dynamically recording information of the cached data in the local file system of the mobile terminal; The terminal determines whether the cached data of the requested webpage exists in the local file system according to the dynamic cache record in the local file system.
根据本发明的另一方面, 提供了一种浏览器, 包括: 緩存判断单元, 用 于根据提交的网页打开请求, 判断在移动终端的本地文件系统中是否存在所 请求的网页的緩存数据; 緩存数据提取单元, 用于在移动终端的本地文件系 统中存在所述所请求的网页的緩存数据时, 从移动终端的本地文件系统中提 取所请求的网页的緩存数据, 以供在移动终端上显示; 网页原始数据获取及 处理单元, 用于在移动终端的本地文件系统中不存在所述所请求的网页的緩 存数据时, 通过联网获取所请求的网页的原始数据, 并对所获取的网页原始 数据进行分析、 排版, 转换为适于移动终端显示的结果数据, 以供在移动终 端上显示。  According to another aspect of the present invention, a browser is provided, including: a cache determining unit, configured to determine, according to a submitted webpage open request, whether cached data of the requested webpage exists in a local file system of the mobile terminal; a data extracting unit, configured to: when the cached data of the requested webpage exists in a local file system of the mobile terminal, extract cached data of the requested webpage from a local file system of the mobile terminal, for displaying on the mobile terminal a webpage raw data obtaining and processing unit, configured to acquire, by the network, the original data of the requested webpage when the cached data of the requested webpage does not exist in the local file system of the mobile terminal, and obtain the original webpage of the obtained webpage The data is analyzed, typeset, and converted into result data suitable for display by the mobile terminal for display on the mobile terminal.
在上述方面的一个或多个示例中, 所述浏览器还可以包括: 緩存数据建 立单元, 用于基于所述结果数据建立适于在移动终端本地存储的緩存数据。  In one or more examples of the above aspect, the browser may further include: a cache data establishing unit, configured to establish, based on the result data, cache data suitable for storage locally on the mobile terminal.
在上述方面的一个或多个示例中, 所述緩存数据建立单元可以包括: 内 存块生成模块, 用于将所述结果数据转换为内存块; 以及写入模块, 用于将 所述内存块作为緩存数据写入到移动终端的本地文件系统中, 以建立所述移 动终端的緩存数据。  In one or more examples of the above aspect, the cache data establishing unit may include: a memory block generating module, configured to convert the result data into a memory block; and a writing module, configured to use the memory block as The cached data is written to the local file system of the mobile terminal to establish cached data of the mobile terminal.
在上述方面的一个或多个示例中, 所述内存块生成模块可以包括: 格式 转换模块, 用于通过移位按规则将所述结果数据转换为二进制格式; 以及内 存块形成模块, 用于将所转换的二进制格式的数据追加组成二进制流形式的 结构体内存块。  In one or more examples of the above aspect, the memory block generating module may include: a format conversion module, configured to convert the result data into a binary format by a shift according to a rule; and a memory block forming module, configured to The data in the converted binary format is appended to the structure memory block in the form of a binary stream.
在上述方面的一个或多个示例中, 所述浏览器还可以包括: 緩存数据动 态记录单元, 用于动态记录移动终端的本地文件系统中的緩存数据的动态緩 存记录信息, 其中, 所述緩存判断单元根据所述緩存数据动态记录单元记录 的动态緩存记录信息, 判断本地文件系统中是否存在所请求的网页的緩存数 据。 根据本发明的另一方面, 提供了一种移动终端, 包括如上所述的浏览器。 采用上述为浏览过的网页建立本地緩存机制的技术方案后, 移动终端能 够充分利用空闲时间把下载、 分析、 排版后的网页的结果数据緩存到移动终 端存储量大的本地文件系统中, 再次浏览该网页时仅需再读取移动终端本地 文件系统中的数据直接进行显示即可, 节省了联网下载、 分析、 排版的时间, 有效提高了用户的浏览效率。 附图说明 In one or more examples of the above aspect, the browser may further include: a cache data dynamic recording unit, configured to dynamically record dynamic cache record information of the cache data in the local file system of the mobile terminal, where the cache The judging unit judges whether the cache data of the requested webpage exists in the local file system according to the dynamic cache record information recorded by the cache data dynamic recording unit. According to another aspect of the present invention, a mobile terminal is provided, including a browser as described above. After adopting the above technical solution for establishing a local caching mechanism for the browsed webpage, the mobile terminal can fully utilize the idle time to cache the result data of the downloaded, analyzed, and typeset webpage into the local file system with large storage capacity of the mobile terminal, and browse again. The webpage only needs to read the data in the local file system of the mobile terminal and directly display it, which saves the time of downloading, analyzing and typographical networking, and effectively improves the browsing efficiency of the user. DRAWINGS
通过下面结合附图对其实施例进行描述, 本发明的上述特征和技术优点 将会变得更加清楚和容易理解。  The above features and technical advantages of the present invention will become more apparent and understood from
图 1示出了根据本发明的移动终端的网页浏览方法的流程示意图; 图 2示出了根据本发明的浏览器的方框结构示意图;  1 is a flow chart showing a webpage browsing method of a mobile terminal according to the present invention; FIG. 2 is a block diagram showing a structure of a browser according to the present invention;
图 3示出了图 2中的緩存数据建立单元的一个示例的方框示意图; 以及  FIG. 3 is a block diagram showing an example of a cache data establishing unit in FIG. 2;
具体实施方式 detailed description
下面结合附图和具体实施例对本发明做进一步详细的描述。  The present invention will be further described in detail below with reference to the drawings and specific embodiments.
图 1是表示本发明移动终端的网页浏览方法的流程示意图。 如图 1所示, 本发明提供的移动终端的网页浏览方法, 包括如下步骤:  1 is a flow chart showing a webpage browsing method of a mobile terminal of the present invention. As shown in FIG. 1, the webpage browsing method of the mobile terminal provided by the present invention includes the following steps:
当用户在移动终端提交打开网页请求(步骤 S101 )之后, 移动终端并不 直接联网进行网页的下载, 而是先判断本地文件系统中是否存在所请求的网 页的緩存数据(步骤 S102 ) 。 如果在移动终端的本地文件系统中存在所述所 请求的网页的緩存数据, 则直接从移动终端的本地文件系统中提取所请求的 网页的緩存数据, 然后根据该緩存数据在移动终端上显示所请求的网页; 否 则, 如果在移动终端的本地文件系统中不存在所述所请求的网页的緩存数据, 则移动终端通过联网获取所请求的网页的原始数据(步骤 S103 ) , 并对所获 取的网页原始数据进行分析(步骤 S104 ) 、 排版(步骤 S105 ) , 转换为适于 移动终端显示的、 由不同格式的数据类型组成的结果数据; 然后根据所述结 果数据在移动终端显示所请求的网页 (步骤 S106 ) ; 并将所述结果数据转换 为内存块, 最后将所述内存块作为緩存数据存储至移动终端的本地緩存, 该 緩存数据的数据结构适于移动终端本地存储、 调用处理。 这里, 作为示例, 本地文件系统可以是移动终端中的存储器。 After the user submits the open webpage request (step S101) at the mobile terminal, the mobile terminal does not directly download the webpage directly, but first determines whether the cached data of the requested webpage exists in the local file system (step S102). If the cached data of the requested webpage exists in the local file system of the mobile terminal, the cached data of the requested webpage is directly extracted from the local file system of the mobile terminal, and then displayed on the mobile terminal according to the cached data. The requested webpage; otherwise, if the cached data of the requested webpage does not exist in the local file system of the mobile terminal, the mobile terminal acquires the original data of the requested webpage through networking (step S103), and acquires the acquired data. The web page raw data is analyzed (step S104), typeset (step S105), converted into result data composed of data types of different formats suitable for display by the mobile terminal; and then according to the knot The data is displayed on the mobile terminal to the requested webpage (step S106); and the result data is converted into a memory block, and finally the memory block is stored as cache data to a local cache of the mobile terminal, and the data structure of the cached data is suitable. Store and call processing locally on the mobile terminal. Here, as an example, the local file system may be a memory in the mobile terminal.
本发明本地緩存机制的实现是建立在能够供移动终端查询、 利用的緩存 数据库的基础上的, 在移动终端将所述结果数据转换为适于移动终端本地存 储、 调用处理的第一数据结构写入移动终端的本地文件系统后, 就建立或者 实时更新了移动终端本地的緩存数据库, 从而能够在用户再次浏览该网页时 不用再次联网下载而直接从移动终端本地提取该网页数据。  The implementation of the local cache mechanism of the present invention is based on a cache database that can be queried and utilized by the mobile terminal, and the mobile terminal converts the result data into a first data structure suitable for local storage and call processing of the mobile terminal. After entering the local file system of the mobile terminal, the local cache database of the mobile terminal is established or updated in real time, so that the webpage data can be directly extracted from the mobile terminal directly when the user browses the webpage again without downloading again.
利用图 1 所示的为浏览过的网页建立本地緩存数据的方法, 能够使得移 动终端充分利用空闲时间把下载、 分析、 排版后的网页的结果数据緩存到移 动终端中存储量大的本地文件系统, 从而在再次浏览该网页时, 不必重新进 行耗时的联网下载、 分析、 排版过程, 仅需再读取移动终端本地文件系统中 的数据直接进行显示即可, 从而有效节省了的用户的时间和流量。  The method for establishing local cache data for the browsed webpage shown in FIG. 1 enables the mobile terminal to fully utilize the idle time to cache the result data of the downloaded, analyzed, and typeset webpage to a local file system with a large storage capacity in the mobile terminal. Therefore, when browsing the webpage again, it is not necessary to re-run the time-consuming network downloading, analysis, and typesetting process, and only need to read the data in the local file system of the mobile terminal to directly display, thereby effectively saving the user's time. And traffic.
在利用手机等移动终端进行上网浏览的过程中, 由于移动终端本身硬件 的限制,通常能够在普通的 PC浏览器上正常浏览的网页并不能在移动终端上 正常显示, 需要在移动终端对原始的网页数据进行分析、 重新排版的处理, 生成适于移动终端显示的结果数据后才能够在移动终端上进行浏览。  In the process of browsing the Internet by using a mobile terminal such as a mobile phone, due to the limitation of the hardware of the mobile terminal itself, a webpage that can normally be browsed on a normal PC browser cannot be normally displayed on the mobile terminal, and needs to be original on the mobile terminal. The webpage data is analyzed and re-formatted, and the result data suitable for display by the mobile terminal is generated before being browsed on the mobile terminal.
这里的结果数据包含网页的所有控件 (文本、 超链接、 编辑框、 按钮、 图片等) 的不同的结构体数据, 控件的结构体数据又由不同格式的数据类型 组成, 通常包含对联网下载的原始网页数据进行分析、 排版后的信息位置、 高度、 宽度以及控件的基本属性等信息。 由于这种适于移动终端显示的结果 数据的数据结构并不适于移动终端本地文件系统的存储, 因此, 在本发明中, 在将所述结果数据写入移动终端的本地文件系统的过程中, 需要将所述结果 数据转换为适于移动终端本地存储、 调用处理的第一数据结构后存储在移动 终端本地, 具体过程为: 先通过内存块转换的方式将网页所有控件的结果数 据转换成内存块数据, 然后再把转换后的内存块数据写入移动终端的本地文 件系统进行緩存; 相应地, 在从本地文件系统中提取需要的网页的緩存数据 进行显示时, 先从本地文件系统中读取所需要的网页的内存块数据, 然后再 将该内存块数据转换为适于移动终端显示的结果数据进行显示。 The result data here contains different structure data of all the controls (text, hyperlink, edit box, button, picture, etc.) of the webpage. The structure data of the control is composed of data types of different formats, usually including the download of the network. The original web page data is analyzed, the information position, height, width, and basic properties of the control are information. Since the data structure suitable for the result data displayed by the mobile terminal is not suitable for the storage of the local file system of the mobile terminal, in the present invention, in the process of writing the result data to the local file system of the mobile terminal, The result data needs to be converted into a first data structure suitable for local storage and call processing of the mobile terminal, and then stored locally in the mobile terminal. The specific process is: first converting the result data of all controls of the webpage into memory by means of memory block conversion. Block data, and then writing the converted memory block data to the local file system of the mobile terminal for caching; correspondingly, extracting the cached data of the required webpage from the local file system When the display is performed, the memory block data of the required web page is read from the local file system, and then the memory block data is converted into result data suitable for display by the mobile terminal for display.
由于数据格式的差异性, 在将网页控件的结果数据转换为适于大量存储 的内存块数据的过程中, 大部分的数据类型都需要转换。 由于任何数据都可 以通过移位按照一定的规则转换为二进制格式, 因此, 在本发明的一个具体 实施方式中, 主要是用数据移位的转换方式来实现从结果数据到内存块数据 的转换。 首先, 将网页所有控件的结果数据均通过移位按规则转换为二进制 格式, 然后所转换的二进制格式的数据通过追加就可以组成一个二进制流, 这个二进制流就是一个适于本地文件系统存储的大的内存块。  Due to the variability of the data format, most of the data types need to be converted in the process of converting the result data of the web page control into the memory block data suitable for mass storage. Since any data can be converted to a binary format by shifting according to a certain rule, in a specific embodiment of the present invention, the conversion from the result data to the memory block data is mainly realized by the data shift conversion method. First, the result data of all the controls of the webpage is converted into a binary format by shifting according to the rules, and then the converted binary format data can be added to form a binary stream, which is a large file storage system suitable for the local file system. Memory block.
关于如何通过追加的方式将所转换的二进制格式的数据组成为一个二进 制流, 下面以 C/C++语言描述其实现方法:  On how to compose the converted binary format data into a binary stream by appending, the following describes its implementation in C/C++:
假设 char* buf 是最终的内存块, 空间足够大。  Suppose char* buf is the final memory block and the space is large enough.
1、 将整数 n转换成二进制流, 由于整数占用四个字节  1, the integer n is converted to a binary stream, because the integer occupies four bytes
Int n;  Int n;
char Str[32];  Char Str[32];
Str[0] = n»24;  Str[0] = n»24;
Str[l] = n»16;  Str[l] = n»16;
Str[2] = n»8;  Str[2] = n»8;
Str[3] = n»0;  Str[3] = n»0;
Str[4] = '\0';  Str[4] = '\0';
Strcat(buf, Str);
Figure imgf000008_0001
Strcat(buf, Str);
Figure imgf000008_0001
2、 将字符串" abed"转换成二进制流  2, the string "abed" is converted to a binary stream
char Str[32] = "abed";  Char Str[32] = "abed";
Strcat(buf, Str);
Figure imgf000008_0002
也就是说, 由于结果数据是由不同的结构体组成的, 而结构体又是由不 同格式的数据类型组成的, 因此, 在转换过程中, 首先把组成一个网页的所 有结果数据的结构体的所有数据类型都分别转换成二进制格式, 然后结构体 的二进制数据追加成结构体内存块; 当把所有结果数据的结构体都转换成内 存块之后, 一个个内存块追加在一起就实现了结果数据向内存块数据的转换。
Strcat(buf, Str);
Figure imgf000008_0002
That is to say, since the result data is composed of different structures, and the structure is composed of data types of different formats, in the conversion process, first, the structure of all the result data constituting a web page is All data types are converted into binary format, and then the binary data of the structure is added to the structure memory block. When all the structure data of the result data is converted into a memory block, the memory blocks are added together to realize the result data. Conversion to memory block data.
相应地, 在从本地文件系统中提取网页的緩存数据的过程中, 将本地文 件系统中存储的内存块数据转换为结果数据的转换方式与上述从结果数据向 内存块数据的转换方式相反, 先将表示该网页的整体内存块数据分解为一个 个结构体内存块, 然后再分别对结构体内存块进行分解为二进制格式, 最后 对二进制格式进行逆向的移位转换为结果数据所要求的数据类型即可。  Correspondingly, in the process of extracting the cache data of the webpage from the local file system, the conversion manner of converting the memory block data stored in the local file system into the result data is opposite to the manner of converting the result data from the result data to the memory block data, first The whole memory block data representing the web page is decomposed into a single structure memory block, and then the structure memory block is separately decomposed into a binary format, and finally the binary format is inversely shifted into the data type required by the result data. Just fine.
本发明中,移动终端的本地文件系统指的是存储在移动终端的手机卡(如 In the present invention, the local file system of the mobile terminal refers to a mobile phone card stored in the mobile terminal (eg,
SIM卡)或者存储卡(如 SD卡、 CF卡等插入式存储卡) 中的文件系统。 SIM card) or file system in a memory card (such as a SD card, CF card, etc.).
另外, 在将结果数据写入移动终端的本地文件系统之后, 如果所述结果 存, 这样, 能够使得移动终端能够有更多的内存处理前端的数据, 从而提高 移动终端的数据处理能力。  In addition, after the result data is written to the local file system of the mobile terminal, if the result is stored, it is possible to enable the mobile terminal to have more memory processing data of the front end, thereby improving the data processing capability of the mobile terminal.
为了充分利用移动终端的存储空间, 在本发明中, 移动终端还根据预设 的规则 (如网页在规定的时间内的浏览次数、 网页的安全级别、 网页的内容 分类等)对所述文件系统中的緩存数据进行清理, 以删除长期不用或者重复 应用的可能性较小的网页緩存数据, 以及使释放所述文件系统的存储空间, 提高移动终端存储空间的利用率。  In order to make full use of the storage space of the mobile terminal, in the present invention, the mobile terminal also uses the preset rules (such as the number of times the webpage is browsed within a prescribed time, the security level of the webpage, the content classification of the webpage, etc.) to the file system. The cached data is cleaned to delete the cached data of the webpage that is less likely to be used or reused for a long time, and to release the storage space of the file system, thereby improving the utilization of the storage space of the mobile terminal.
为了对移动终端本地文件系统中的緩存数据进行有效的管理, 便于在进 行网页浏览时的查找、 提取和对利用率低的緩存数据进行及时的清理, 在本 发明的一个优选实施方式中, 在移动终端的本地文件系统中还建立了动态緩 存记录, 用于动态记录移动终端的本地文件系统中緩存数据的信息。 通过该 动态緩存记录, 移动终端就可以方便地判断本地文件系统中是否存在所请求 的网页的緩存数据、 快速定位需要提取的緩存数据, 以及根据记录信息对緩 存数据进行及时有效的管理, 提高移动终端存储空间的利用率。 图 2示出了根据本发明的浏览器 10的方框结构示意图。 如图 2所示, 与 上述移动终端的网页浏览方法相对应, 本发明还提供一种浏览器 10, 包括緩 存判断单元 1、 緩存数据提取单元 2、 网页原始数据获取及处理单元 3和緩存 数据建立单元 4。 其中, 緩存判断单元 1用于根据用户提交的网页打开请求, 判断在移动终端的本地文件系统中是否存在所请求的网页的緩存数据。 In order to effectively manage the cached data in the local file system of the mobile terminal, it is convenient to perform the search, extraction and timely cleaning of the cached data with low utilization during web browsing. In a preferred embodiment of the present invention, A dynamic cache record is also established in the local file system of the mobile terminal for dynamically recording information of the cached data in the local file system of the mobile terminal. Through the dynamic cache record, the mobile terminal can conveniently determine whether the cached data of the requested webpage exists in the local file system, cache data that needs to be extracted quickly, and timely and effectively manage the cached data according to the record information, thereby improving the movement. Utilization of terminal storage space. 2 is a block diagram showing the structure of a browser 10 in accordance with the present invention. As shown in FIG. 2, the present invention further provides a browser 10, including a cache determination unit 1, a cache data extraction unit 2, a webpage original data acquisition and processing unit 3, and cache data, corresponding to the webpage browsing method of the mobile terminal. Unit 4 is established. The cache judging unit 1 is configured to determine, according to the webpage open request submitted by the user, whether the cached data of the requested webpage exists in the local file system of the mobile terminal.
如果在移动终端的本地文件系统中存在所请求的网页的緩存数据, 则緩 存数据提取单元 2直接从移动终端的本地文件系统中提取所请求的网页的緩 存数据, 以供在移动终端的浏览器上进行显示。  If the cached data of the requested webpage exists in the local file system of the mobile terminal, the cached data extracting unit 2 directly extracts the cached data of the requested webpage from the local file system of the mobile terminal for use in the browser of the mobile terminal. Displayed on.
如果在移动终端的本地文件系统中不存在所请求的网页的緩存数据, 则 网页原始数据获取及处理单元 3通过联网获取所请求的网页的原始数据, 并 对所获取的网页原始数据进行分析、 排版, 转换为适于移动终端显示的结果 数据。 通常, 所述结果数据由不同格式的数据类型组成。  If the cached data of the requested webpage does not exist in the local file system of the mobile terminal, the webpage original data acquisition and processing unit 3 obtains the original data of the requested webpage through networking, and analyzes the acquired raw data of the webpage, The typesetting is converted into result data suitable for display by the mobile terminal. Typically, the result data consists of data types in different formats.
此外, 优选地, 所述浏览器 10还可以包括緩存数据建立单元 4, 用于将 所述结果数据转换为具有适于移动终端本地存储、 调用处理的第一数据结构 的内存块数据, 并将所述内存块数据作为緩存数据写入移动终端的本地文件 系统中以建立所述移动终端的緩存数据。 在本发明的其它实施例中, 如图所 述, 緩存数据建立单元 4可以包括内存块生成单元 41 , 用于基于所述结果数 据生成内存块数据; 以及写入单元 42, 用于将所述内存块数据作为緩存数据 写入移动终端的本地文件系统中, 以建立所述移动终端的緩存数据。  In addition, the browser 10 may further include a cache data establishing unit 4, configured to convert the result data into memory block data having a first data structure suitable for local storage and call processing of the mobile terminal, and The memory block data is written as cache data into a local file system of the mobile terminal to establish cache data of the mobile terminal. In other embodiments of the present invention, as shown in the figure, the cache data establishing unit 4 may include a memory block generating unit 41 for generating memory block data based on the result data; and a writing unit 42 for using the The memory block data is written as cache data in the local file system of the mobile terminal to establish cache data of the mobile terminal.
与上述移动终端的网页浏览方法相对应, 在本发明的一个示例中, 所述 内存块生成单元 41还可以包括格式转换模块(未示出) , 用于通过移位按规 则将所述结果数据转换为二进制格式; 以及内存块数据形成模块(未示出 ) , 用于将所转换的二进制格式的数据追加组成二进制流形式的结构体内存块。 然后, 写入单元 42将所述内存块作为緩存数据存储至移动终端的本地文件系 统中以建立所述移动终端的緩存数据。 其中, 结果数据包括网页的所有控件 的结构体数据, 控件结构体数据包括对所述网页原始数据进行分析、 排版后 的信息位置、 高度、 宽度以及控件基本属性信息。  Corresponding to the webpage browsing method of the mobile terminal, in an example of the present invention, the memory block generating unit 41 may further include a format conversion module (not shown) for using the result data by shifting by rules. Converting to a binary format; and a memory block data forming module (not shown) for appending the converted binary format data to a structured memory block in the form of a binary stream. Then, the writing unit 42 stores the memory block as cache data in the local file system of the mobile terminal to establish cache data of the mobile terminal. The result data includes structural data of all controls of the webpage, and the control structure data includes information about the original data of the webpage, information position, height, width, and basic property information of the control.
另外, 在本发明提供的移动终端的一个优选实施方式中, 还包括緩存数 据管理单元(图中未示出) , 用以在緩存数据建立单元 4将结果数据转换为 内存块并作为緩存数据存储至移动终端的本地文件系统之后, 判断所述结果 数据是否当前浏览的网页, 如果不是, 则删除移动终端内存中的所述结果数 据以释放内存。 并且, 緩存数据管理单元还根据预设的规则对所述文件系统 中的緩存数据进行清理, 以删除长期不用的緩存数据, 释放所述文件系统的 存储空间。 In addition, in a preferred implementation manner of the mobile terminal provided by the present invention, the number of caches is further included. According to the management unit (not shown), after the cache data establishing unit 4 converts the result data into a memory block and stores the data as cache data to the local file system of the mobile terminal, it is determined whether the result data is currently browsed. If not, delete the result data in the memory of the mobile terminal to release the memory. Moreover, the cache data management unit further cleans the cached data in the file system according to a preset rule to delete cache data that is not used for a long time, and release the storage space of the file system.
进一步, 所述浏览器还可以设置有緩存数据动态记录单元(未示出) , 用以动态记录移动终端的本地文件系统中緩存数据的信息的动态緩存记录, 以便移动终端根据所述动态緩存记录来判断本地文件系统中是否存在所请求 的网页的緩存数据。 所述緩存数据动态记录单元可以设置在緩存数据管理单 元之外, 也可以设置在緩存数据管理单元之中。  Further, the browser may further be provided with a cached data dynamic recording unit (not shown) for dynamically recording a dynamic cache record of information of the cached data in the local file system of the mobile terminal, so that the mobile terminal records the cache according to the dynamic cache. To determine whether the cached data of the requested web page exists in the local file system. The cache data dynamic recording unit may be disposed outside the cache data management unit or in the cache data management unit.
图 4示出了根据本发明的移动终端 20的方框示意图, 该移动终端 20包 括如上所述的浏览器 10。 4艮显然, 这里的浏览器可以包括根据本发明的浏览 器的各种变型。  Figure 4 shows a block schematic diagram of a mobile terminal 20 in accordance with the present invention, the mobile terminal 20 including a browser 10 as described above. 4) Obviously, the browser herein may include various variations of the browser in accordance with the present invention.
本发明所述的移动终端典型的可为各种可能进行网页浏览的终端设备, 例如手机、 个人数字助理等, 因此本发明的保护范围不应限定为某种特定类 型的移动终端。  The mobile terminal of the present invention is typically a variety of terminal devices that may perform web browsing, such as mobile phones, personal digital assistants, etc., and thus the scope of protection of the present invention should not be limited to a particular type of mobile terminal.
此外, 根据本发明的方法还可以被实现为由 CPU执行的计算机程序。 在 该计算机程序被 CPU执行时, 执行本发明的方法中限定的上述功能。  Furthermore, the method according to the invention can also be implemented as a computer program executed by a CPU. When the computer program is executed by the CPU, the above-described functions defined in the method of the present invention are performed.
此外, 上述方法步骤以及系统单元也可以利用控制器或处理器以及用于 存储使得控制器或处理器实现上述步骤或单元功能的计算机程序的计算机可 读存储设备实现。  Moreover, the above method steps and system elements can also be implemented with a controller or processor and a computer readable storage device for storing a computer program that causes the controller or processor to perform the steps or unit functions described above.
此外, 应该明白的是, 本文所述的计算机可读存储设备(例如, 存储器) 可以是易失性存储器或非易失性存储器, 或者可以包括易失性存储器和非易 失性存储器两者。 作为例子而非限制性的, 非易失性存储器可以包括只读存 储器(ROM ) 、 可编程 ROM ( PROM ) 、 电可编程 ROM ( EPROM ) 、 电可 擦写可编程 ROM ( EEPROM )或快闪存储器。 易失性存储器可以包括随机存 取存储器(RAM ) , 该 RAM 可以充当外部高速緩存存储器。 作为例子而非 限制性的, RAM可以以多种形式获得, 比如同步 RAM ( DRAM )、动态 RAM ( DRAM )、 同步 DRAM ( SDRAM )、双数据速率 SDRAM ( DDR SDRAM )、 增强 SDRAM ( ESDRAM )、 同步链路 DRAM ( SLDRAM ) 以及直接 Rambus RAM ( DRRAM ) 。 所公开的方面的存储设备意在包括但不限于这些和其它 合适类型的存储器。 Moreover, it should be understood that the computer readable storage devices (eg, memory) described herein can be either volatile memory or nonvolatile memory, or can include both volatile and nonvolatile memory. By way of example and not limitation, non-volatile memory may include read only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash Memory. Volatile memory can include random access memory (RAM), which can act as external cache memory. By way of example and not limitation, RAM can be obtained in a variety of forms, such as synchronous RAM (DRAM), dynamic RAM. (DRAM), Synchronous DRAM (SDRAM), Double Data Rate SDRAM (DDR SDRAM), Enhanced SDRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), and Direct Rambus RAM (DRRAM). Storage devices of the disclosed aspects are intended to comprise, without being limited to, these and other suitable types of memory.
本领域技术人员还将明白的是, 结合这里的公开所描述的各种示例性逻 辑块、 模块、 电路和算法步骤可以被实现为电子硬件、 计算机软件或两者的 组合。 为了清楚地说明硬件和软件的这种可互换性, 已经就各种示意性组件、 方块、 模块、 电路和步骤的功能对其进行了一般性的描述。 这种功能是被实 现为软件还是被实现为硬件取决于具体应用以及施加给整个系统的设计约 但是这种实现决定不应被解释为导致脱离本发明的范围。  Those skilled in the art will also appreciate that the various exemplary logical blocks, modules, circuits, and algorithm steps described in connection with the disclosure herein can be implemented as electronic hardware, computer software, or combinations of both. To clearly illustrate this interchangeability of hardware and software, a general description of the various illustrative components, blocks, modules, circuits, and steps has been described. Whether such functionality is implemented as software or as hardware depends on the particular application and design applied to the overall system. However, such implementation decisions should not be construed as causing a departure from the scope of the invention.
结合这里的公开所描述的各种示例性逻辑块、 模块和电路可以利用被设 计成用于执行这里所述功能的下列部件来实现或执行: 通用处理器、 数字信 号处理器(DSP ) 、 专用集成电路(ASIC ) 、 现场可编程门阵列 (FPGA )或 其它可编程逻辑器件、 分立门或晶体管逻辑、 分立的硬件组件或者这些部件 的任何组合。 通用处理器可以是微处理器, 但是可替换地, 处理器可以是任 何传统处理器、 控制器、 微控制器或状态机。 处理器也可以被实现为计算设 备的组合, 例如, DSP 和微处理器的组合、 多个微处理器、 一个或多个微处 理器结合 DSP核、 或任何其它这种配置。  The various exemplary logic blocks, modules, and circuits described in connection with the disclosure herein can be implemented or executed with the following components designed to perform the functions described herein: general purpose processor, digital signal processor (DSP), dedicated Integrated circuit (ASIC), field programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic, discrete hardware components, or any combination of these components. A general purpose processor may be a microprocessor, but in the alternative, the processor may be any conventional processor, controller, microcontroller or state machine. The processor can also be implemented as a combination of computing devices, e.g., a combination of a DSP and a microprocessor, a plurality of microprocessors, one or more microprocessors in conjunction with a DSP core, or any other such configuration.
结合这里的公开所描述的方法或算法的步骤可以直接包含在硬件中、 由 处理器执行的软件模块中或这两者的组合中。软件模块可以驻留在 RAM存储 器、 快闪存储器、 ROM存储器、 EPROM存储器、 EEPROM存储器、 寄存器、 硬盘、 可移动盘、 CD-ROM、 或本领域已知的任何其它形式的存储介质中。 示例性的存储介质被耦合到处理器, 使得处理器能够从该存储介质中读取信 息或向该存储介质写入信息。 在一个替换方案中, 所述存储介质可以与处理 器集成在一起。 处理器和存储介质可以驻留在 ASIC中。 ASIC可以驻留在用 户终端中。 在一个替换方案中, 处理器和存储介质可以作为分立组件驻留在 用户终端中。  The steps of a method or algorithm described in connection with the disclosure herein may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two. The software module can reside in RAM memory, flash memory, ROM memory, EPROM memory, EEPROM memory, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art. An exemplary storage medium is coupled to the processor, such that the processor can read information from or write information to the storage medium. In an alternative, the storage medium can be integrated with the processor. The processor and the storage medium can reside in an ASIC. The ASIC can reside in the user terminal. In an alternative, the processor and the storage medium may reside as discrete components in the user terminal.
尽管前面公开的内容示出了本发明的示例性实施例, 但是应当注意, 在 不背离权利要求限定的本发明的范围的前提下, 可以进行多种改变和修改。 根据这里描述的发明实施例的方法权利要求的功能、 步骤和 /或动作不需以任 何特定顺序执行。 此外, 尽管本发明的元素可以以个体形式描述或要求, 但 是也可以设想多个, 除非明确限制为单数。 While the foregoing disclosure shows exemplary embodiments of the present invention, it should be understood that various changes and modifications may be made without departing from the scope of the invention. The functions, steps and/or actions of the method claims in accordance with the embodiments of the invention described herein are not required What is the specific order of execution. In addition, although elements of the invention may be described or claimed in the form of an individual, many are contemplated, unless explicitly limited to the singular.
尽管已经结合详细示出并描述的优选实施例公开了本发明, 但是本领域 技术人员应当理解, 对于上述本发明所提出的方法和装置, 还可以在不脱离 本发明内容的基础上做出各种改进。 因此, 本发明的保护范围应当由所附的 权利要求书的内容确定。  Although the present invention has been disclosed in connection with the preferred embodiments shown and described in detail, those skilled in the art will understand that the method and apparatus of the present invention described above may be made without departing from the scope of the invention. Improvements. Therefore, the scope of the invention should be determined by the content of the appended claims.

Claims

权 利 要 求 书 Claim
1、 一种网页浏览方法, 包括: 1. A web browsing method, comprising:
根据提交的网页打开请求, 判断在移动终端的本地文件系统中是否存在 所请求的网页的緩存数据, 所述緩存数据具有适于移动终端本地存储及调用 处理的第一数据结构;  Determining, according to the submitted webpage open request, whether the cached data of the requested webpage exists in the local file system of the mobile terminal, the cached data having a first data structure suitable for local storage and invocation processing of the mobile terminal;
如果在移动终端的本地文件系统中存在所请求的网页的緩存数据, 则直 接从移动终端的本地文件系统中提取所请求的网页的緩存数据进行显示; 否 则  If the cached data of the requested webpage exists in the local file system of the mobile terminal, the cached data of the requested webpage is directly extracted from the local file system of the mobile terminal for display; otherwise
移动终端在通过联网获取所请求的网页的原始数据后对所获取的网页原 始数据进行分析、 排版, 并转换为适于移动终端显示的结果数据进行显示。  After acquiring the original data of the requested webpage through networking, the mobile terminal analyzes, formats, and converts the obtained webpage original data into a result data suitable for display by the mobile terminal.
2、 如权利要求 1所述的方法, 还包括:  2. The method of claim 1 further comprising:
将所述结果数据转换为所述具有第一数据结构的内存块; 以及  Converting the result data into the memory block having the first data structure;
将所述内存块写入移动终端的本地文件系统中, 作为緩存数据。  The memory block is written into the local file system of the mobile terminal as cache data.
3、 如权利要求 2所述的方法, 其中, 将所述结果数据转换为内存块的步 骤包括:  3. The method of claim 2, wherein the step of converting the result data into a memory block comprises:
通过移位按规则将由不同结构体组成的结果数据转换为二进制格式, 其 中所述结构体由不同格式的数据类型组成, 以及  Converting result data composed of different structures into a binary format by shifting by rules, wherein the structures are composed of data types of different formats, and
将所转换的二进制格式的数据追加组成二进制流形式的结构体内存块。 The data in the converted binary format is appended to the structure memory block in the form of a binary stream.
4、 按照权利要求 3所述的方法, 其中, 从移动终端的本地文件系统中直 接提取所请求的网页的緩存数据进行显示的步骤包括: 4. The method according to claim 3, wherein the step of directly extracting the cached data of the requested webpage from the local file system of the mobile terminal for display comprises:
从所述本地文件系统中读取所请求的网页的緩存数据;  Reading cached data of the requested webpage from the local file system;
将所读取的緩存数据转换为适于移动终端显示的结果数据; 以及 在所述移动终端上显示所述结果数据。  Converting the read cached data into result data suitable for display by the mobile terminal; and displaying the result data on the mobile terminal.
5、 按照权利要求 4所述的方法,  5. The method of claim 4,
所述结果数据包括网页的所有控件的结构体数据, 所述控件结构体数据 包括对所述网页原始数据进行分析、 排版后的信息位置、 高度、 宽度以及控 件基本属性信息。 The result data includes structural data of all controls of the webpage, and the control structure data includes information of the original data of the webpage, information position, height, width, and basic property information of the control.
6、 按照权利要求 1所述的方法, 6. The method of claim 1 wherein
所述移动终端根据预设的规则对所述本地文件系统中的緩存数据进行清 理, 以删除长期不用的緩存数据, 释放所述本地文件系统的存储空间。  And the mobile terminal clears the cached data in the local file system according to a preset rule to delete the cached data that is not used for a long time, and release the storage space of the local file system.
7、 按照权利要求 1所述的方法, 还包括:  7. The method of claim 1 further comprising:
在所述移动终端的本地文件系统中建立动态緩存记录, 动态记录移动终 端的本地文件系统中緩存数据的信息;  Establishing a dynamic cache record in the local file system of the mobile terminal, and dynamically recording information of the cached data in the local file system of the mobile terminal;
所述移动终端根据本地文件系统中的动态緩存记录来判断本地文件系统 中是否存在所请求的网页的緩存数据。  The mobile terminal determines whether the cached data of the requested webpage exists in the local file system according to the dynamic cache record in the local file system.
8、 一种浏览器, 包括:  8. A browser, comprising:
緩存判断单元, 用于根据提交的网页打开请求, 判断在移动终端的本地 文件系统中是否存在所请求的网页的緩存数据;  a cache judging unit, configured to determine, according to the submitted webpage open request, whether the cached data of the requested webpage exists in the local file system of the mobile terminal;
緩存数据提取单元, 用于在移动终端的本地文件系统中存在所述所请求 的网页的緩存数据时, 从移动终端的本地文件系统中提取所请求的网页的緩 存数据, 以供在移动终端上显示;  a cache data extracting unit, configured to: when the cached data of the requested webpage exists in a local file system of the mobile terminal, extract the cached data of the requested webpage from the local file system of the mobile terminal, for the mobile terminal Display
网页原始数据获取及处理单元, 用于在移动终端的本地文件系统中不存 在所述所请求的网页的緩存数据时, 通过联网获取所请求的网页的原始数据, 并对所获取的网页原始数据进行分析、 排版, 转换为适于移动终端显示的结 果数据, 以供在移动终端上显示。  a webpage raw data acquisition and processing unit, configured to acquire, by the network, the original data of the requested webpage when the cached data of the requested webpage does not exist in the local file system of the mobile terminal, and obtain the original data of the webpage obtained Perform analysis, typesetting, and conversion to result data suitable for display by the mobile terminal for display on the mobile terminal.
9、 如权利要求 8所述的浏览器, 还包括:  9. The browser of claim 8, further comprising:
緩存数据建立单元, 用于基于所述结果数据建立适于在移动终端本地存 储的緩存数据。  And a cache data establishing unit, configured to establish, based on the result data, cache data suitable for being stored locally on the mobile terminal.
10、 按照权利要求 9所述的浏览器, 其中, 所述緩存数据建立单元包括: 内存块生成模块, 用于将所述结果数据转换为内存块; 以及  The browser according to claim 9, wherein the cache data establishing unit comprises: a memory block generating module, configured to convert the result data into a memory block;
写入模块, 用于将所述内存块作为緩存数据写入到移动终端的本地文件 系统中, 以建立所述移动终端的緩存数据。  And a writing module, configured to write the memory block as cache data to a local file system of the mobile terminal to establish cache data of the mobile terminal.
11、 如权利要求 10所述的浏览器, 其中, 所述内存块生成模块包括: 格式转换模块, 用于通过移位按规则将所述结果数据转换为二进制格式; 以及 内存块形成模块, 用于将所转换的二进制格式的数据追加组成二进制流 形式的结构体内存块。 The browser of claim 10, wherein the memory block generating module comprises: a format conversion module, configured to convert the result data into a binary format by a shift according to a rule; The memory block forming module is configured to append the converted binary format data into a structured memory block in a binary stream form.
12、 如权利要求 8所述的浏览器, 还包括: 緩存数据动态记录单元, 用 于动态记录移动终端的本地文件系统中的緩存数据的动态緩存记录信息, 其中, 所述緩存判断单元根据所述緩存数据动态记录单元记录的动态緩 存记录信息, 判断本地文件系统中是否存在所请求的网页的緩存数据。  The browser of claim 8, further comprising: a cache data dynamic recording unit, configured to dynamically record dynamic cache record information of the cache data in the local file system of the mobile terminal, wherein the cache determination unit is configured according to The dynamic cache record information recorded by the cache data dynamic record unit is determined, and whether the cache data of the requested web page exists in the local file system is determined.
13、 一种移动终端, 包括如权利要求 8到 12中任何一个所述的浏览器。  A mobile terminal comprising the browser of any one of claims 8 to 12.
PCT/CN2011/083619 2010-12-09 2011-12-07 Web page browsing method, browser and mobile terminal WO2012075942A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201010581608XA CN102033917A (en) 2010-12-09 2010-12-09 Webpage browsing method for mobile terminal and mobile terminal applying same
CN201010581608.X 2010-12-09

Publications (1)

Publication Number Publication Date
WO2012075942A1 true WO2012075942A1 (en) 2012-06-14

Family

ID=43886810

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2011/083619 WO2012075942A1 (en) 2010-12-09 2011-12-07 Web page browsing method, browser and mobile terminal

Country Status (2)

Country Link
CN (1) CN102033917A (en)
WO (1) WO2012075942A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
RU2729053C1 (en) * 2016-11-22 2020-08-04 Бейдзин Цзиндун Сенчури Трэйдинг Ко., Лтд. Method and device for online preview of document

Families Citing this family (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102033917A (en) * 2010-12-09 2011-04-27 广州市动景计算机科技有限公司 Webpage browsing method for mobile terminal and mobile terminal applying same
CN102364461A (en) * 2011-06-30 2012-02-29 广州市动景计算机科技有限公司 Page content data acquisition method and server
CN102929877B (en) * 2011-08-08 2016-02-17 阿里巴巴集团控股有限公司 List data on webpage is generated method and the device of form document
CN102323890B (en) * 2011-08-23 2013-08-28 百度在线网络技术(北京)有限公司 Web page processing method, device and system for wireless terminal
CN102982044A (en) * 2011-09-07 2013-03-20 腾讯科技(深圳)有限公司 Method and device for webpage browsing
CN102508700B (en) * 2011-09-30 2017-05-24 广州市动景计算机科技有限公司 Method and device for quickly recovering webpage of mobile terminal
CN104142966A (en) * 2013-09-26 2014-11-12 腾讯科技(深圳)有限公司 Web page displaying method and client
CN104142965A (en) * 2013-09-26 2014-11-12 腾讯科技(深圳)有限公司 Social application based webpage browsing method and device as well as terminal device
CN104778169B (en) * 2014-01-09 2018-10-19 深圳桑菲消费通信有限公司 A kind of Web browser method, device and mobile terminal
CN106294365A (en) * 2015-05-15 2017-01-04 阿里巴巴集团控股有限公司 The page data processing method of a kind of single page web application and equipment
CN105045593B (en) * 2015-07-29 2019-05-10 百度在线网络技术(北京)有限公司 Method and apparatus for drawing the page
CN105701153B (en) * 2015-12-29 2019-03-22 北京金山安全软件有限公司 Method and device for reading webpage resources and electronic equipment
CN108009167A (en) * 2016-10-31 2018-05-08 北大方正集团有限公司 Column update method and device based on CMS system
CN108959446A (en) * 2018-06-13 2018-12-07 佛山市车品匠汽车用品有限公司 A kind of Web browser method and system of mobile terminal
CN111767495A (en) * 2019-04-01 2020-10-13 北京沃东天骏信息技术有限公司 Method and system for synthesizing webpage

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101710327A (en) * 2009-12-04 2010-05-19 深圳创维数字技术股份有限公司 Method for caching local temporary files into embedded browser
CN101883168A (en) * 2009-05-08 2010-11-10 北京闻言科技有限公司 Method for efficiently managing cache files at mobile phone client
CN102033917A (en) * 2010-12-09 2011-04-27 广州市动景计算机科技有限公司 Webpage browsing method for mobile terminal and mobile terminal applying same

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101075236A (en) * 2006-06-12 2007-11-21 腾讯科技(深圳)有限公司 Apparatus and method for accelerating browser webpage display
CN101150803B (en) * 2007-10-24 2011-08-24 优视科技有限公司 Method for micro-browser to process network data, micro-browser and its server

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101883168A (en) * 2009-05-08 2010-11-10 北京闻言科技有限公司 Method for efficiently managing cache files at mobile phone client
CN101710327A (en) * 2009-12-04 2010-05-19 深圳创维数字技术股份有限公司 Method for caching local temporary files into embedded browser
CN102033917A (en) * 2010-12-09 2011-04-27 广州市动景计算机科技有限公司 Webpage browsing method for mobile terminal and mobile terminal applying same

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
RU2729053C1 (en) * 2016-11-22 2020-08-04 Бейдзин Цзиндун Сенчури Трэйдинг Ко., Лтд. Method and device for online preview of document
US11256773B2 (en) 2016-11-22 2022-02-22 Beijing Jingdong Shangke Information Technology Co., Ltd. Document online preview method and device

Also Published As

Publication number Publication date
CN102033917A (en) 2011-04-27

Similar Documents

Publication Publication Date Title
WO2012075942A1 (en) Web page browsing method, browser and mobile terminal
US9916285B2 (en) Generating a preview of a web page for a mobile terminal
CN100530186C (en) Method and system for processing buffer
US9881015B2 (en) Method and system for previewing file information
WO2016101757A1 (en) Image processing method and device based on mobile device
CN103338249B (en) Caching method and device
WO2013097667A1 (en) Web page content loading control method and device
WO2013034094A1 (en) Webpage browsing method and device, and storage medium
WO2012072046A1 (en) Webpage rendering method, device, and system
CN103123630A (en) Method, system, mobile terminal and server for obtaining webpage contents
WO2015085732A1 (en) Terminal memory processing method and apparatus, and terminal
CN103425765A (en) Method and device for extracting webpage text and method and system for webpage preview
WO2014173193A1 (en) Webpage pre-reading method, apparatus to which the method is applied, and storage medium
WO2016107464A1 (en) Method and device for implementing card-type desktop
CN111159594A (en) Information processing method, information processing device and terminal equipment
TWI410817B (en) Method and system for storing internet bookmark and computer program product using the method
CN110888843A (en) Cross-host sparse file copying method, device, equipment and storage medium
TWI634421B (en) Electronic apparatus for data access and data access method therefor
JP3445912B2 (en) Hypertext automatic acquisition device
JP6088853B2 (en) COMMUNICATION DEVICE, COMMUNICATION METHOD, AND COMMUNICATION PROGRAM
JP2013020395A (en) Information processing apparatus, information processing method and program
WO2015154680A1 (en) File processing method, device, and network system
CN104933045B (en) Network information browsing method and network information browsing apparatus
WO2012119496A1 (en) Pre-reading method and equipment
CN115495020A (en) File processing method and device, electronic equipment and readable storage medium

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 11846709

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 11846709

Country of ref document: EP

Kind code of ref document: A1