CN1996304A - Method and device for processing Web resource files in embedded device - Google Patents

Method and device for processing Web resource files in embedded device Download PDF

Info

Publication number
CN1996304A
CN1996304A CN 200610169769 CN200610169769A CN1996304A CN 1996304 A CN1996304 A CN 1996304A CN 200610169769 CN200610169769 CN 200610169769 CN 200610169769 A CN200610169769 A CN 200610169769A CN 1996304 A CN1996304 A CN 1996304A
Authority
CN
China
Prior art keywords
file
web resource
embedded device
application
compressed
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN 200610169769
Other languages
Chinese (zh)
Inventor
郑上闽
秦琳
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hangzhou H3C Technologies Co Ltd
Original Assignee
Hangzhou Huawei 3Com Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hangzhou Huawei 3Com Technology Co Ltd filed Critical Hangzhou Huawei 3Com Technology Co Ltd
Priority to CN 200610169769 priority Critical patent/CN1996304A/en
Publication of CN1996304A publication Critical patent/CN1996304A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The process method for an embedded equipment web resource document comprises the No. 1 document combined by embedded equipment web resource and application program document, and storing the No. 1 document into the flash memory of the embedded equipment. It also relates to a processing equipment for the web resource document of the embedded equipment, composed of storage module set inside the flash memory, with the No. 1 document being stored in the flash memory of the embedded equipment. It also relates to a web resource document processing equipment. It can effectively reduce the cost and operation complexity and network resource occupation, and improve the maintenance and version updating efficiency, with reduced manpower and cost.

Description

The disposal route and the device of the Web resource file of embedded device
Technical field
The present invention relates to the disposal route and the device of Web resource file, particularly the disposal route and the device of the Web resource file of embedded device belong to the communications field.
Background technology
Along with developing rapidly of Internet technology, Web browser becomes the most common mode of users' access internet with its friendly interface.For satisfying the requirement of different users at aspects such as function, visions, need to deposit a large amount of Web resource files in the Web server, as animation file, picture file and script file, as gif file, JPG file, html file, ASP file, jsp file, PHP file etc.Along with the user is more and more higher to the requirement of the Web page, the Web resource file on the server is more and more, and is also just increasing to the management difficulty of Web resource file.
Because the versatility and the ubiquity of Web client also begin to use the Web technology in the management of embedded device (for example switch, router), therefore the Web resource file in the embedded device is also needed to manage and safeguard.Complete Web resource file generally includes many catalogues and file, for ease of management, usually with these catalogues and document storage in a root directory.
Main storage medium in the embedded device is flash memory (Flash memory, be called for short flash memory), in the embedded device (as switch), the source code file of application program is stored in the flash memory through the application file that the compiling back forms, behind the embedded device electrifying startup application file is loaded into internal memory, the read-write of application programs file is after this all finished in internal memory.
In the prior art, embedded device is that Web resource file and application file are distinguished to the disposal route of Web resource file, and the Web resource file is is independently administered and maintained.In other words, existing embedded device is that application file and WEB resource file are stored in the flash memory mutually fully discretely.
The disposal route of the Web resource file of above-mentioned existing embedded device has the following disadvantages:
1, owing to is stored in Web resource file and application file in the flash memory fully discretely, therefore the renewal of Web resource file and the edition upgrading of application programs file are also needed independently to download respectively, take Internet resources, increased the complicated operation degree;
2, owing to be stored in Web resource file and application file in the flash memory fully discretely, therefore need the maintainer that the version Matching Relationship of Web resource file and application file is detected and safeguard, and when each edition upgrading, also need the version Matching Relationship of Web resource file and application file is checked verification, thereby reduced maintenance and version updating efficiency, increased human cost.
Summary of the invention
The objective of the invention is in order to overcome the defective of above-mentioned prior art, a kind of disposal route and device of Web resource packet of embedded device are provided, can reduce cost effectively and the complicated operation degree, reduce, improve and safeguard and version updating efficiency, reduce human cost the taking of Internet resources.
For achieving the above object, the invention provides a kind of disposal route of Web resource file of embedded device, comprise: the Web resource file and the application file of embedded device are combined into first file, and with this first file storage in the flash memory of this embedded device.
In technique scheme, by the Web resource file of embedded device and application file being combined into a file and being kept in the flash memory, but not of the prior artly be kept at Web resource file and application file in the flash memory independently of one another, thereby can realize the renewal of Web resource file and the edition upgrading of application programs file have been reduced taking and the complicated operation degree Internet resources by downloading and move the upgrade software bag uniformly; Simultaneously, do not need the maintainer that the version Matching Relationship of Web resource file and application file is detected and safeguard, when each edition upgrading, do not need the version Matching Relationship of Web resource file and application file is checked verification yet, thereby improved maintenance and version updating efficiency, reduced human cost.
Preferably, described Web resource file and application file with embedded device is combined into first file and can specifically comprises: the source code file of the application program of embedded device is compiled generate described application file, use the File Compress instrument with described Web resource file and described first file of described application file boil down to.
Preferably, described Web resource file and application file with embedded device is combined into first file and also can specifically comprises: use the File Compress instrument with described Web resource file boil down to Web resource compressed file, also successively deposit in one-dimension array for corresponding ASCII character each character conversion in the described Web resource compressed file successively then, set up a Web resource source code file that comprises this one-dimension array, use the file compilation tool that the source code file of described Web resource source code file with the application program of embedded device compiled then, obtain comprising described first file of Web resource compilation of source code file and described application file.
For realizing goal of the invention, the present invention also provides the treating apparatus of Web resource file in a kind of embedded device, comprise memory module, be located in the flash memory of embedded device, be used for first file storage that Web resource file and application file by this embedded device are combined flash memory at this embedded device.
In technique scheme, preserve the described file that combines by the memory module that in the flash memory of embedded device, is provided with, thereby realize that the Web resource file of embedded device and application file are combined into a file to be kept in the flash memory, but not of the prior art Web resource file and application file are kept in the flash memory independently of one another.Therefore, can realize by downloading and move the upgrade software bag uniformly, reduce taking and the complicated operation degree Internet resources to the renewal of Web resource file and the edition upgrading of application programs file; Simultaneously, do not need the maintainer that the version Matching Relationship of Web resource file and application file is detected and safeguard, when each edition upgrading, do not need the version Matching Relationship of Web resource file and application file is checked verification yet, thereby improved maintenance and version updating efficiency, reduced human cost.
For realizing goal of the invention, the present invention also provides a kind of Web resource file treating apparatus, comprises composite module, is used for the Web resource file and the application file of embedded device are combined into first file.
In technique scheme, by composite module the Web resource file and the application file of embedded device is combined into a file, thereby can the file that be combined into be kept in the flash memory of embedded device by the treating apparatus of Web resource file in the described embedded device.
In sum, the present invention is by being combined into a file with the Web resource file of embedded device and application file and being kept in the flash memory, but not of the prior art Web resource file and application file are kept in the flash memory independently of one another, thereby can reach minimizing taking and complicated operation degree, the useful technique effect that improves maintenance and version updating efficiency and reduce human cost to Internet resources.
Description of drawings
Fig. 1 is the schematic flow sheet of the embodiment one of the disposal route of the Web resource file of embedded device of the present invention;
Fig. 2 is the schematic flow sheet of the embodiment two of the disposal route of the Web resource file of embedded device of the present invention;
Fig. 3 is the schematic flow sheet of the embodiment three of the disposal route of the Web resource file of embedded device of the present invention;
Fig. 4 is another schematic flow sheet of the embodiment three of the disposal route of the Web resource file of embedded device of the present invention;
Fig. 5 is the another schematic flow sheet of the embodiment three of the disposal route of the Web resource file of embedded device of the present invention;
Fig. 6 is the flow process synoptic diagram again of the embodiment three of the disposal route of the Web resource file of embedded device of the present invention;
Fig. 7 is another schematic flow sheet of the embodiment three of the disposal route of the Web resource file of embedded device of the present invention;
Fig. 8 is the schematic flow sheet of the embodiment four of the disposal route of the Web resource file of embedded device of the present invention;
Fig. 9 is the structural representation of the embodiment one of the treating apparatus of Web resource file in the embedded device of the present invention;
Figure 10 is another structural representation of the embodiment one of the treating apparatus of Web resource file in the embedded device of the present invention;
Figure 11 is the structural representation of the embodiment two of Web resource file treating apparatus of the present invention;
Figure 12 is the structural representation of the embodiment four of Web resource file treating apparatus of the present invention.
Embodiment
Below in conjunction with drawings and Examples, technical scheme of the present invention is described in further detail.
Of the present inventionly be contemplated that substantially: in the prior art owing to be stored in Web resource file and application file in the flash memory fully discretely, thereby cause the renewal of Web resource file and the edition upgrading of application programs file are also needed independently to download respectively, Internet resources have been taken, increased the complicated operation degree, need version Matching Relationship to Web resource file and application file to detect simultaneously and safeguard, thereby maintenance and version updating efficiency have been reduced, increased the defective of human cost, a kind of disposal route and device of Web resource packet of embedded device are provided, by the Web resource file of embedded device and application file being combined into a file and being kept in the flash memory, but not of the prior artly be kept at Web resource file and application file in the flash memory independently of one another, thereby can realize the renewal of Web resource file and the edition upgrading of application programs file by downloading and move the upgrade software bag uniformly, reduce cost effectively and the complicated operation degree, minimizing takies Internet resources, improves and safeguards and version updating efficiency.
Conceive based on foregoing invention, the invention provides a kind of disposal route of Web resource file of embedded device, referring to the schematic flow sheet of embodiment shown in Figure 1, this embodiment one comprises: at first in step a the Web resource file and the application file of embedded device is combined into first file; Then in step b with this first file storage in the flash memory of this embedded device.
Present embodiment one is by being combined into a file with the Web resource file of embedded device and application file and being kept in the flash memory, but not of the prior artly be kept at Web resource file and application file in the flash memory independently of one another, thereby can realize the renewal of Web resource file and the edition upgrading of application programs file by downloading and move the upgrade software bag uniformly, for example, after step b, can comprise: the upgrade software bag that described embedded device is downloaded and operation is default, described default upgrade software bag is being used for of issuing in advance to the Web resource file of described first file and application file upgrades uniformly or the upgrading software bag, thereby has reduced taking and the complicated operation degree Internet resources; Simultaneously, do not need the maintainer that the version Matching Relationship of Web resource file and application file is detected and safeguard, when each edition upgrading, do not need the version Matching Relationship of Web resource file and application file is checked verification yet, thereby improved maintenance and version updating efficiency, reduced human cost.
Schematic flow sheet referring to the embodiment two of the disposal route of the Web resource file of embedded device of the present invention shown in Figure 2, step a can specifically comprise: at first in step a1, the source code file of the application program of embedded device compiled generate described application file, in step a2, use the File Compress instrument then with described Web resource file and described first file of described application file boil down to.In the present embodiment two by the File Compress instrument with Web resource file and described first file of application file boil down to, thereby reduced described first file taking in described first file in generation to the flash memory of embedded device.
In order further to reduce taking to the flash memory of embedded device, in the present embodiment two, step a2 also can specifically comprise: use the File Compress instrument with described application file boil down to application program compressed file, and use the File Compress instrument with described Web resource file boil down to Web resource compressed file, use the File Compress instrument with described application program compressed file and described first file of described Web resource compressed file boil down to then; Perhaps use the File Compress instrument with described application file boil down to application program compressed file, use the File Compress instrument then described application program compressed file and described first file of described Web resource file boil down to; Perhaps use the File Compress instrument with described Web resource file boil down to Web resource compressed file, use the File Compress instrument then described application file and described first file of described Web resource compressed file boil down to.
Referring to Fig. 3, in the present embodiment two, after step b, also can comprise step c, promptly behind the embedded device electrifying startup, use file decompression instrument obtains described application file and is loaded in the internal memory from described first file, the described application file of operation in internal memory; After embedded device receives that the user browses the request of the Web page, use file decompression instrument from described first file, to obtain described Web resource file, and this Web resource file is kept at carries out read-write operation in the flash memory, behind the read-write operation that finishes this Web resource file, this Web resource file of deletion from flash memory.In above-mentioned steps c, behind the embedded device electrifying startup, application file is loaded in the internal memory moves, and the Web resource file still is retained in the flash memory, thereby reduced taking the internal memory of embedded device.
The foregoing description two provides and has used the embodiment of File Compress instrument with described Web resource file and described first file of described application file boil down to, in the embodiment three of the disposal route of the Web of embedded device of the present invention resource file, provide the another kind of embodiment that generates described first file.
Referring to Fig. 4, compare with the foregoing description one, step a further specifically comprises in the present embodiment three: at first in step a10, the source code file of the application program of embedded device compiled generate described application file, and use the File Compress instrument described Web resource file boil down to Web resource compressed file; Then in step a20, the content of described Web resource compressed file and described application file merged constitute described first file, and in the file header of this first file, preserve and be used for identifying described application file in the position of described first file and the identification information of length.Described merging be meant with the content of described Web resource compressed file and described application file add and.Preferably, as shown in Figure 6, described merging can be the content of the described Web resource compressed file suffix as the content of described application file, constitutes described first file; And in the file header of this first file, preserve the identification information of the length be used to identify described application file.By this identification information when reading described application program compressed file, can read in described first file, be 0 to be the file content of the position of the length that described identification information identified from the side-play amount of the file content except that file header, as the content of described application program compressed file to side-play amount.
Perhaps, in order further to reduce taking to the flash memory of embedded device, referring to Fig. 5, described step a can specifically comprise: at first in step a100, the source code file of the application program of embedded device compiled generate described application file, and use the File Compress instrument, and use the File Compress instrument with described Web resource file boil down to Web resource compressed file with described application file boil down to application program compressed file; Then in step a200, the content of the content of described Web resource compressed file and described application program compressed file merged constitute described first file, and in the file header of this first file, preserve and be used for identifying described application program compressed file in the position of described first file and the identification information of length.Similarly, described merging can be the content of the described Web resource compressed file suffix as the content of described application program compressed file, constitutes described first file; And in the file header of this first file, preserve the identification information of the length be used to identify described application program compressed file.
In the present embodiment three, identify position and the length of described application program compressed file in described first file, so that when reading described application program compressed file, can obtain this application program compressed file according to this identification information by described identification information.For example, as shown in Figure 7, after step b, also can comprise step c1, promptly behind the embedded device electrifying startup, from described first file, obtain described application file or application program compressed file according to described identification information, if obtain the application program compressed file then use file decompression instrument that this application program compressed file is decompressed to obtain described application file, then this application file is loaded in the internal memory of embedded device and moves; After embedded device receives that the user browses the request of the Web page, obtain described Web resource compressed file according to described identification information, use file decompression instrument that this Web resource compressed file is decompressed and obtain described Web resource file, and this Web resource file is kept at carries out read-write operation in the flash memory, behind the read-write operation that finishes this Web resource file, this Web resource file of deletion from flash memory.In above-mentioned steps c1, behind the embedded device electrifying startup, application file is loaded in the internal memory moves, and the Web resource file still is retained in the flash memory, thereby reduced taking the internal memory of embedded device.
In the embodiment four of the disposal route of the Web of embedded device of the present invention resource file, another embodiment that generates described first file is provided, as shown in Figure 8, compare with the foregoing description one, step a can specifically comprise further described in the present embodiment four: at first in step a11, use the File Compress instrument with described Web resource file boil down to Web resource compressed file; Then in step a12, successively with each character conversion in the described Web resource compressed file for corresponding ASCII character and deposit in successively in the one-dimension array, set up a Web resource source code file that comprises this one-dimension array; For example, Web resource compressed file (as the compressed file of suffix .zip by name) is converted to the C language source code file, this C language source code file only comprises an one-dimension array, as this one-dimension array name is made as WebRes[], then read each character in the Web resource compressed file successively and be converted into corresponding ASCII character, a is converted to 65 as character, character b is converted to 66 etc., preface be docile and obedient in character after the conversion write WebRes[] array, the final lengths of this array is by the number decision of character in the described Web resource compressed file; At last in step a13, use the file compilation tool that described Web resource source code file is compiled (for example using C language source code file that C language compilation tool converts described Web resource compressed file to compile with the C language source code file of the application program of embedded device) with the source code file of the application program of embedded device, obtain comprising described first file of Web resource compilation of source code file and described application file.The present embodiment four-way is crossed the form that Web resource file and application file are combined into compiling file and is left in the flash memory of embedded device; thereby make the user can't obtain the source file of Web resource file; can strengthen security greatly; protect the possessory interests of Web resource file effectively, prevent that the source file of Web resource file from being obtained by other people without approval.
Further, in the present embodiment four, compile with application file after Web resource compressed file is converted to the ASCII character file, described ASCII character file forms described Web resource compilation of source code file after compiling; Therefore behind the embedded device electrifying startup, described first file can be loaded in the internal memory from flash memory, and move the described application file that comprises in described first file; And after embedded device received that the user browses the request of the Web page, embedded device can directly carry out read-write operation to the Web resource compilation of source code file that comprises in first file of preserving in the internal memory.Compare with the foregoing description two to three, the present embodiment four-way is crossed and all is loaded into described first file in the internal memory after embedded device starts, because the read or write speed of internal memory is higher than the read or write speed of flash memory, thereby improved read or write speed greatly to the Web resource file, simultaneously owing to all be loaded into described first file in the internal memory, thereby reduced visit density, can prolong the serviceable life of flash memory flash memory.
Based on the foregoing invention design, the present invention also provides the treating apparatus of Web resource file in a kind of embedded device.The embodiment one of the treating apparatus of Web resource file comprises memory module in the embedded device of the present invention, be located in the flash memory of embedded device and and be connected, be used for first file storage that Web resource file and application file by this embedded device are combined flash memory at this embedded device with described composite module.
In present embodiment one, preserve the Web resource file of embedded device and first file that application file combines by the memory module that in the flash memory of embedded device, is provided with, thereby realize the Web resource file of embedded device and application file being combined into a file and being kept in the flash memory, but not of the prior art Web resource file and application file are kept in the flash memory independently of one another.Therefore, can realize by downloading and move the upgrade software bag uniformly the renewal of Web resource file and the edition upgrading of application programs file, for example, as shown in Figure 9, present embodiment one also can comprise upgrading module 5, be located in the described embedded device and and be connected with described memory module 2, be used to download and move default upgrade software bag, described default upgrade software bag is used for described first file is upgraded uniformly or upgrades, thereby has reduced taking and the complicated operation degree Internet resources; Simultaneously, do not need the maintainer that the version Matching Relationship of Web resource file and application file is detected and safeguard, when each edition upgrading, do not need the version Matching Relationship of Web resource file and application file is checked verification yet, thereby improved maintenance and version updating efficiency, reduced human cost.
Referring to Figure 10, present embodiment one also can comprise: application file processing module 3, be located in the described embedded device and and be connected with memory module 2, be used for behind the embedded device electrifying startup, use file decompression instrument obtains application file and is loaded in the internal memory from first file, with the described application file of operation in internal memory; Web resource file processing module 4, be located in the embedded device and and be connected with memory module 2, be used for after embedded device receives that the user browses the request of the Web page, use file decompression instrument from first file, to obtain the Web resource file, and this Web resource file is kept at carries out read-write operation in the flash memory, behind the read-write operation that finishes this Web resource file, this Web resource file of deletion from flash memory.From the above, behind the embedded device electrifying startup, by application file processing module 3 application file is loaded in the internal memory and moves, and the Web resource file still is retained in the flash memory, thereby reduced taking the internal memory of embedded device.
Present embodiment one also can comprise: the second application file processing module, be located in the described embedded device and and be connected with described memory module, be used for behind the embedded device electrifying startup, from described first file, obtain described application file or application program compressed file according to described identification information, if obtain the application program compressed file then use file decompression instrument that this application program compressed file is decompressed to obtain described application file, then this application file is loaded in the internal memory of embedded device and moves; The 2nd Web resource file processing module, if be connected in the described embedded device and with described memory module, be used for after embedded device receives that the user browses the request of the Web page, obtain described Web resource compressed file according to described identification information, use file decompression instrument that this Web resource compressed file is decompressed and obtain described Web resource file, and this Web resource file is kept at carries out read-write operation in the flash memory, behind the read-write operation that finishes this Web resource file, this Web resource file of deletion from flash memory.By setting up above-mentioned module, behind the embedded device electrifying startup, application file is loaded in the internal memory moves, and the Web resource file still is retained in the flash memory, thereby reduced taking the internal memory of embedded device.
Present embodiment one also can comprise: the 3rd application file processing module, be located in the described embedded device and and be connected with described memory module, be used for behind the embedded device electrifying startup, described first file is loaded in the internal memory from flash memory, and moves the described application file that comprises in described first file; The 3rd Web resource file processing module, be located in the described embedded device and and be connected with described memory module, be used for after embedded device receives that the user browses the request of the Web page, the described Web resource compilation of source code file that comprises in described first file is carried out read-write operation.From the above, by after embedded device starts, all being loaded into described first file in the internal memory, because the read or write speed of internal memory is higher than the read or write speed of flash memory, thereby improved read or write speed greatly to the Web resource file, simultaneously owing to all be loaded into described first file in the internal memory, thereby reduced visit density, can prolong the serviceable life of flash memory flash memory.
Based on the foregoing invention design, the present invention also provides a kind of Web resource file treating apparatus.In the embodiment one of Web resource file treating apparatus of the present invention, comprise composite module, be used for the Web resource file and the application file of embedded device are combined into first file.This Web resource file treating apparatus can be located in the embedded device, also can be located at outside the embedded device, and it all should be within technical solution of the present invention scope required for protection.
Structural representation referring to the embodiment two of Web resource file treating apparatus of the present invention shown in Figure 11, be with the difference of the foregoing description one: composite module 1 also can comprise: collector 10 is used for the source code file of the application program of embedded device is compiled the generation application file; File Compress module 11 is connected with collector 10, is used to use application file boil down to first file of File Compress instrument with Web resource file and collector 10 compiling generations.Present embodiment two by the File Compress instrument with Web resource file and application file boil down to first file, thereby in described first file of generation, reduced described first file taking to the flash memory of embedded device.
In order further to reduce taking to flash memory, File Compress module 11 also can be used for: use the File Compress instrument with described application file boil down to application program compressed file, and use the File Compress instrument with described Web resource file boil down to Web resource compressed file, use the File Compress instrument with described application program compressed file and described first file of described Web resource compressed file boil down to then; Perhaps use the File Compress instrument with described application file boil down to application program compressed file, use the File Compress instrument then described application program compressed file and described first file of described Web resource file boil down to; Perhaps use the File Compress instrument with described Web resource file boil down to Web resource compressed file, use the File Compress instrument then described application file and described first file of described Web resource compressed file boil down to.
The foregoing description two provides and has used the embodiment of File Compress instrument with described Web resource file and described first file of described application file boil down to, in the embodiment three of Web resource file treating apparatus of the present invention, the another kind of embodiment that generates described first file is provided, composite module 1 can comprise: collector is used for source code file to the application program of embedded device and compiles and generate described application file; The File Compress module is connected with collector, is used to use the File Compress instrument with described Web resource file boil down to Web resource compressed file; File generating module, be connected with collector, File Compress module, the suffix of the content of the application file that the content that is used for Web resource compressed file that the File Compress module is generated generates as collector, constitute first file, and in the file header of this first file, preserve the identification information of the length be used to identify described application file.
Perhaps, in order further to reduce the taking of flash memory, composite module 1 also can comprise: collector is used for source code file to the application program of embedded device and compiles and generate described application file; The 3rd File Compress module is connected with collector, is used to use the File Compress instrument with described application file boil down to application program compressed file, and uses the File Compress instrument with described Web resource file boil down to Web resource compressed file; Second file generating module, be connected with described second File Compress module and memory module, be used for content with the content of described Web resource compressed file and described application program compressed file and merge and constitute described first file, and in the file header of this first file, preserve and be used for identifying described application program compressed file in the position of described first file and the identification information of length.
In the present embodiment three, identify position and the length of described application program compressed file in described first file, so that when reading described application program compressed file, can obtain this application program compressed file according to this identification information by described identification information.For example,
In the embodiment four of Web resource file treating apparatus of the present invention, another embodiment that generates described first file is provided, as shown in figure 12, composite module 1 can comprise: File Compress module 14 is used to use the File Compress instrument with described Web resource file boil down to Web resource compressed file; File conversion module 15, be connected with described File Compress module 14, be used for successively each character conversion with described Web resource compressed file for corresponding ASCII character and deposit in the one-dimension array successively, set up a Web resource source code file that comprises this one-dimension array, for example, Web resource compressed file (as the compressed file of suffix .zip by name) is converted to the C language source code file, this C language source code file only comprises an one-dimension array, as this one-dimension array name is made as WebRes[], then read each character in the Web resource compressed file successively and be converted into corresponding ASCII character, a is converted to 65 as character, character b is converted to 66 etc., preface be docile and obedient in character after the conversion write WebRes[] array, the final lengths of this array is by the number decision of character in the described Web resource compressed file; File collector 16, be connected with file conversion module 14, be used to use the file compilation tool that described Web resource source code file is compiled (for example using C language source code file that C language compilation tool converts described Web resource compressed file to compile with the C language source code file of the application program of embedded device) with the source code file of the application program of embedded device, obtain comprising described first file of Web resource compilation of source code file and described application file.The present embodiment four-way is crossed the form that Web resource file and application file are combined into compiling file and is left in the flash memory of embedded device; thereby make the user can't obtain the source file of Web resource file; can strengthen security greatly; protect the possessory interests of Web resource file effectively, prevent that the source file of Web resource file from being obtained by other people without approval.
Above embodiment is only in order to illustrating technical scheme of the present invention, but not the present invention is made restrictive sense.Although the present invention is had been described in detail with reference to above-mentioned preferred embodiment, those of ordinary skill in the art is to be understood that: it still can make amendment or be equal to replacement technical scheme of the present invention, and this modification or be equal to the spirit and scope that replacement does not break away from technical solution of the present invention.

Claims (18)

1, a kind of disposal route of Web resource file of embedded device is characterized in that, comprising: the Web resource file and the application file of embedded device are combined into first file, with this first file storage in the flash memory of this embedded device.
2, method according to claim 1, it is characterized in that, described Web resource file and application file with embedded device is combined into first file and specifically comprises: the source code file of the application program of embedded device is compiled generate described application file, use the File Compress instrument with described Web resource file and described first file of described application file boil down to.
3, method according to claim 2 is characterized in that, described use File Compress instrument specifically comprises described Web resource file and described first file of described application file boil down to:
Use the File Compress instrument with described application file boil down to application program compressed file, and use the File Compress instrument with described Web resource file boil down to Web resource compressed file, use the File Compress instrument with described application program compressed file and described first file of described Web resource compressed file boil down to then; Perhaps
Use the File Compress instrument with described application file boil down to application program compressed file, use the File Compress instrument then described application program compressed file and described first file of described Web resource file boil down to; Perhaps
Use the File Compress instrument with described Web resource file boil down to Web resource compressed file, use the File Compress instrument then described application file and described first file of described Web resource compressed file boil down to.
4, according to claim 2 or 3 described methods, it is characterized in that, described with the flash memory of this first file storage at this embedded device in after also comprise:
Behind the embedded device electrifying startup, use file decompression instrument obtains described application file and is loaded in the internal memory from described first file, the described application file of operation in internal memory;
After embedded device receives that the user browses the request of the Web page, use file decompression instrument from described first file, to obtain described Web resource file, and this Web resource file is kept at carries out read-write operation in the flash memory, behind the read-write operation that finishes this Web resource file, this Web resource file of deletion from flash memory.
5, method according to claim 1 is characterized in that, described Web resource file and application file with embedded device is combined into first file and specifically comprises:
The source code file of the application program of embedded device compiled generate described application file, and use the File Compress instrument with described Web resource file boil down to Web resource compressed file, then the content of described Web resource compressed file and described application file are merged and constitute described first file, and in the file header of this first file, preserve and be used for identifying described application file in the position of described first file and the identification information of length; Perhaps
The source code file of the application program of embedded device compiled generate described application file, and use the File Compress instrument with described application file boil down to application program compressed file, and use the File Compress instrument with described Web resource file boil down to Web resource compressed file, then the content of the content of described Web resource compressed file and described application program compressed file is merged and constitute described first file, and in the file header of this first file, preserve and be used for identifying described application program compressed file in the position of described first file and the identification information of length.
6, method according to claim 5 is characterized in that:
Described content and described application file with described Web resource compressed file merges and constitutes described first file and specifically comprise: with the content of the described Web resource compressed file suffix as the content of described application file, constitute described first file; Described identification information is used to identify the length of described application file;
The described content and the content of described application program compressed file with described Web resource compressed file merges and constitutes described first file and specifically comprise: with the content of the described Web resource compressed file suffix as the content of described application program compressed file, constitute described first file; Described identification information is used to identify the length of described application program compressed file.
7, according to claim 5 or 6 described methods, it is characterized in that, described with the flash memory of this first file storage at this embedded device in after also comprise:
Behind the embedded device electrifying startup, from described first file, obtain described application file or application program compressed file according to described identification information, if obtain the application program compressed file then use file decompression instrument that this application program compressed file is decompressed to obtain described application file, then this application file is loaded in the internal memory of embedded device and moves;
After embedded device receives that the user browses the request of the Web page, obtain described Web resource compressed file according to described identification information, use file decompression instrument that this Web resource compressed file is decompressed and obtain described Web resource file, and this Web resource file is kept at carries out read-write operation in the flash memory, behind the read-write operation that finishes this Web resource file, this Web resource file of deletion from flash memory.
8, method according to claim 1, it is characterized in that, described Web resource file and application file with embedded device is combined into first file and specifically comprises: use the File Compress instrument with described Web resource file boil down to Web resource compressed file, also successively deposit in one-dimension array for corresponding ASCII character each character conversion in the described Web resource compressed file successively then, set up a Web resource source code file that comprises this one-dimension array, use the file compilation tool that the source code file of described Web resource source code file with the application program of embedded device compiled then, obtain comprising described first file of Web resource compilation of source code file and described application file.
9, method according to claim 8 is characterized in that, described with the flash memory of this first file storage at this embedded device in after also comprise:
Behind the embedded device electrifying startup, described first file is loaded in the internal memory from flash memory, and moves the described application file that comprises in described first file;
After embedded device receives that the user browses the request of the Web page, the described Web resource compilation of source code file that comprises in described first file is carried out read-write operation.
10, method according to claim 1, it is characterized in that, described with the flash memory of this first file storage at this embedded device in after also comprise: described embedded device is downloaded the also default upgrade software bag of operation, and described default upgrade software bag is used for described first file is upgraded or upgrades.
11, the treating apparatus of Web resource file in a kind of embedded device, it is characterized in that: comprise memory module, be located in the flash memory of embedded device, be used for first file storage that Web resource file and application file by this embedded device are combined flash memory at this embedded device.
12, device according to claim 11 is characterized in that, also comprises:
The first application file processing module, be located in the described embedded device and and be connected with described memory module, be used for behind the embedded device electrifying startup, use file decompression instrument obtains described application file and is loaded in the internal memory from described first file, with the described application file of operation in internal memory;
The one Web resource file processing module, be located in the described embedded device and and be connected with described memory module, be used for after embedded device receives that the user browses the request of the Web page, use file decompression instrument from described first file, to obtain described Web resource file, and this Web resource file is kept at carries out read-write operation in the flash memory, behind the read-write operation that finishes this Web resource file, this Web resource file of deletion from flash memory.
13, device according to claim 11 is characterized in that, also comprises:
The second application file processing module, be located in the described embedded device and and be connected with described memory module, be used for behind the embedded device electrifying startup, from described first file, obtain described application file or application program compressed file according to described identification information, if obtain the application program compressed file then use file decompression instrument that this application program compressed file is decompressed to obtain described application file, then this application file is loaded in the internal memory of embedded device and moves;
The 2nd Web resource file processing module, be located in the described embedded device and and be connected with described memory module, be used for after embedded device receives that the user browses the request of the Web page, obtain described Web resource compressed file according to described identification information, use file decompression instrument that this Web resource compressed file is decompressed and obtain described Web resource file, and this Web resource file is kept at carries out read-write operation in the flash memory, behind the read-write operation that finishes this Web resource file, this Web resource file of deletion from flash memory.
14, device according to claim 11 is characterized in that, also comprises:
The 3rd application file processing module, be located in the described embedded device and and be connected with described memory module, be used for behind the embedded device electrifying startup, described first file is loaded in the internal memory from flash memory, and move the described application file that comprises in described first file;
The 3rd Web resource file processing module, be located in the described embedded device and and be connected with described memory module, be used for after embedded device receives that the user browses the request of the Web page, the described Web resource compilation of source code file that comprises in described first file is carried out read-write operation.
15, according to the arbitrary described device of claim 11-14, it is characterized in that, also comprise:
The upgrading module is located in the described embedded device and with described memory module and is connected, and is used to download and move default upgrade software bag, and described default upgrade software bag is used for described first file is upgraded or upgrades.
16, a kind of Web resource file treating apparatus is characterized in that: comprise composite module, be used for the Web resource file and the application file of embedded device are combined into first file.
17, device according to claim 16 is characterized in that, described composite module comprises:
Collector is used for source code file to the application program of embedded device and compiles and generate described application file;
The first File Compress module is connected with described collector, is used to use application file boil down to described first file of File Compress instrument with described Web resource file and described collector compiling generation.
18, device according to claim 16 is characterized in that, described composite module comprises:
The second File Compress module is used to use the File Compress instrument with described Web resource file boil down to Web resource compressed file;
The file conversion module, be connected with the described second File Compress module, be used for successively each character conversion with described Web resource compressed file for corresponding ASCII character and deposit in successively in the one-dimension array, set up a Web resource source code file that comprises this one-dimension array;
The file collector, be connected with described file conversion module, be used to use the file compilation tool that the source code file of described Web resource source code file with the application program of embedded device compiled, obtain comprising described first file of Web resource compilation of source code file and described application file.
CN 200610169769 2006-12-28 2006-12-28 Method and device for processing Web resource files in embedded device Pending CN1996304A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN 200610169769 CN1996304A (en) 2006-12-28 2006-12-28 Method and device for processing Web resource files in embedded device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN 200610169769 CN1996304A (en) 2006-12-28 2006-12-28 Method and device for processing Web resource files in embedded device

Publications (1)

Publication Number Publication Date
CN1996304A true CN1996304A (en) 2007-07-11

Family

ID=38251395

Family Applications (1)

Application Number Title Priority Date Filing Date
CN 200610169769 Pending CN1996304A (en) 2006-12-28 2006-12-28 Method and device for processing Web resource files in embedded device

Country Status (1)

Country Link
CN (1) CN1996304A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104932930A (en) * 2015-06-15 2015-09-23 上海斐讯数据通信技术有限公司 Method for using resource file in embedded system and system thereof
CN111309391A (en) * 2020-01-20 2020-06-19 北京无限光场科技有限公司 Application program starting method, device, equipment and medium
CN111796853A (en) * 2020-07-16 2020-10-20 深圳市千分一智能技术有限公司 Firmware upgrading method, system, equipment and computer storage medium

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104932930A (en) * 2015-06-15 2015-09-23 上海斐讯数据通信技术有限公司 Method for using resource file in embedded system and system thereof
CN111309391A (en) * 2020-01-20 2020-06-19 北京无限光场科技有限公司 Application program starting method, device, equipment and medium
CN111796853A (en) * 2020-07-16 2020-10-20 深圳市千分一智能技术有限公司 Firmware upgrading method, system, equipment and computer storage medium

Similar Documents

Publication Publication Date Title
CN100447740C (en) System and method for intra-package delta compression of data
KR101143027B1 (en) Self-describing software image update components
US7836396B2 (en) Automatically collecting and compressing style attributes within a web document
CN110249307A (en) System and method for executing primary contract on block chain
CN104781785B (en) For application native code is generated from intermediate language code
CN112015396B (en) DSL-based intelligent contract code generation method, device, equipment and storage medium
CN111095338A (en) System and method for executing different types of blockchain contracts
CN105893008A (en) Method and device for customizing multi-channel installation package
US20100281463A1 (en) XML based scripting framework, and methods of providing automated interactions with remote systems
CN101866315B (en) Test method and system of software development tool
CN100442236C (en) Method and system for use of MD4 checksum and link transactions across machines
CN105765527A (en) Method and apparatus for custom software development kit (SDK) generation
CN107707625A (en) Foreground resource based on Maven is packed and carries out version management and the method used
CN106502746A (en) The packaging method and device of application program
EP2122514A1 (en) Live entities internet store service
CN102722386A (en) Method and device for generating firmware over the air (FOTA) upgrade pack
CN106796525A (en) On-demand loading dynamic script language codes are used with reducing internal memory
CN101882156A (en) Controllable cache method and system of Silverlight client side
CN113641591B (en) Test case generation method and device and test method and device
CN102141991A (en) Method and system for web server
CN101208690B (en) Translating expressions in computing environment
CN108509215A (en) System software replacing method and device, terminal equipment and storage medium
CN106951270A (en) A kind of code process method, system and server
CN110213290A (en) Data capture method, API gateway and storage medium
CN110266792A (en) Address conversion method, device, equipment and computer readable 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
C12 Rejection of a patent application after its publication
RJ01 Rejection of invention patent application after publication