MHTML Parsing via Boundary String Segmentation

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing methods for processing webpages in archive formats like MHTML on mobile terminals are inefficient due to the need for complex decoding and encoding operations, particularly with base64 and quoted-printable formats, which hinder seamless display and storage of multimedia content.

Innovation Solution

A method and apparatus for mobile terminals that parse MHTML files to extract file header information, divide content into blocks, perform base64 and quoted-printable decoding, and display or encode them for storage, utilizing a processor and memory to handle HTML, CSS, and JavaScript data alongside images.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If complex decoding and encoding operations (base64, quoted-printable) are performed on MHTML files, then the webpage content can be processed and displayed, but the processing efficiency deteriorates and time consumption increases

Engineering Contradiction:
Improvewebpage display capabilityVSAvoidprocessing efficiency
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent segments the MHTML file processing into distinct blocks separated by boundary strings. Each block contains specific content types (HTML, images, CSS, JavaScript) that are independently decoded using appropriate methods. This segmentation allows parallel processing of different content types and eliminates the need for sequential complex decoding of the entire file, thereby improving processing efficiency while maintaining reliable webpage display.

Inventive Principle:
Principle #1Segmentation

2Stability of the object's composition

If MHTML files are stored as single archive format, then all resources are consolidated, but the file size increases and storage efficiency deteriorates

Engineering Contradiction:
Improveresource consolidationVSAvoidfile size
Core Design Contradiction:
Stability of the object's compositionVSQuantity of substance

Solution Approach 1:

The patent extracts image data from the MHTML archive and stores it in a separate, optimized image database rather than embedding it within the HTML structure. This extraction reduces the overall file size of the webpage archive while maintaining resource consolidation through centralized storage management. The boundary string delimiters enable efficient extraction without processing the entire archive structure.

Inventive Principle:
Principle #2Taking out (Extraction)

3Ease of operation

If boundary strings are used to divide webpage content into blocks, then content organization is improved, but the parsing complexity increases

Engineering Contradiction:
Improvecontent organizationVSAvoidparsing complexity
Core Design Contradiction:
Ease of operationVSDevice complexity

Solution Approach 1:

The patent introduces boundary strings as intermediary delimiters that clearly mark the beginning and end of different content blocks within the MHTML file. These standardized delimiters serve as a simple parsing mechanism that reduces complexity compared to nested structures or complex markup languages. The boundary strings enable straightforward identification and extraction of content blocks without requiring sophisticated parsing algorithms.

Inventive Principle:
Principle #24Intermediary (Mediator)

Data Source

PatentUS10552508B2Method and apparatus for processing a webpage
Publication Date: 2020.02.04 TENCENT TECHNOLOGY (SHENZHEN) CO LTD
  • US10552508B2 patent drawing
  • US10552508B2 patent drawing
  • US10552508B2 patent drawing

AI summary

According to an example of the present disclosure, a mobile terminal recognizes a webpage in an archive format in a browser of the mobile terminal, parses the webpage in the archive format to obtain file header information, obtains boundary strings and a character encoding format according to the file header information, performs a content dividing and content decoding operation to the webpage in the archive format, and displays data obtained via the content dividing and content decoding operation in form of a webpage.