CN111026717A - Cache file cleaning method - Google Patents
Cache file cleaning method Download PDFInfo
- Publication number
- CN111026717A CN111026717A CN201911156749.4A CN201911156749A CN111026717A CN 111026717 A CN111026717 A CN 111026717A CN 201911156749 A CN201911156749 A CN 201911156749A CN 111026717 A CN111026717 A CN 111026717A
- Authority
- CN
- China
- Prior art keywords
- cache
- file
- cleaning
- cache data
- preset
- 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
Links
- 238000004140 cleaning Methods 0.000 title claims abstract description 41
- 238000000034 method Methods 0.000 title claims abstract description 20
- 238000012217 deletion Methods 0.000 claims 1
- 230000037430 deletion Effects 0.000 claims 1
- 230000000717 retained effect Effects 0.000 claims 1
- 230000007774 longterm Effects 0.000 abstract description 3
- 230000003993 interaction Effects 0.000 description 3
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000004891 communication Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 230000002452 interceptive effect Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/10—File systems; File servers
- G06F16/16—File or folder operations, e.g. details of user interfaces specifically adapted to file systems
- G06F16/162—Delete operations
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/10—File systems; File servers
- G06F16/17—Details of further file system functions
- G06F16/172—Caching, prefetching or hoarding of files
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Data Mining & Analysis (AREA)
- Databases & Information Systems (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Human Computer Interaction (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
- Information Transfer Between Computers (AREA)
Abstract
The invention discloses a method for cleaning a cache file, which is characterized by comprising the following steps of: firstly, actively applying for the permission of cache cleaning to a user; if the user does not agree with the granted permission, the cache cleaning is not executed; if the user agrees to grant the authority, obtaining a cache file and an original file corresponding to the cache file; when a cache data deleting instruction is received, judging whether the cache data stored in the intelligent terminal meet a preset deleting condition; when the cache data meet the preset deleting condition, deleting the cache data meeting the preset deleting condition; when the cache data do not meet the preset deleting condition, the cache data which do not meet the preset deleting condition are reserved; the cleaning method is more intelligent, the cache files which need to be reserved and do not need to be reserved can be identified as far as possible, the cleaning mode and the cleaning method are more diversified, and meanwhile, the cleaning method can adapt to the use habits of users in long-term use and is more intelligent.
Description
Technical Field
The invention belongs to the technical field of user cache file processing, and relates to a cache file cleaning method.
Background
With the development of communication technology, mobile terminals have become more and more powerful. The user can not only communicate through the mobile terminal telephone, but also watch video, listen to music, store files and the like. In order to meet the requirements of various functions, the storage space of the mobile terminal is larger, but the number of loaded applications is larger, and the generated cache data is more and more accumulated along with the use of the mobile terminal. When too much cache data occupies the storage space, not only is the storage resource wasted, but also the running speed of the mobile terminal is affected, so that the data cached by the mobile terminal needs to be cleaned. More and more intelligent terminals (such as smart phones, tablet computers, notebook computers, desktop computers, all-in-one machines and the like) enter daily work and life of people. The user can perform information interaction with other users through the intelligent terminal, and also can acquire information such as words, videos or pictures from a network through the intelligent terminal. When a user performs information interaction with other users through an intelligent terminal, the generated interaction information (chat records and the like) needs to be stored to the local intelligent terminal; when a user acquires information through the intelligent terminal, the information to be acquired is downloaded to the intelligent terminal locally and stored according to the download address or the link address of the information. These data saved locally to the smart terminal are referred to as cache data (e.g., picture data, web browsing data, etc.). With the increase of the amount of the interactive information and/or the acquired information, a large amount of cache data will be generated in the intelligent terminal, and at present, the method for clearing the data cache mainly comprises the following steps: through downloading App cache for cleaning, when the running speed of the mobile terminal is poor, a user manually selects to clean the cache. However, when a large number of cache files are accumulated, a user cannot judge whether the cache files are important one by one, the important files are deleted when the user manually clears the cache, uncontrollable factors are large, and user experience is poor.
Disclosure of Invention
The invention aims to provide a cache file cleaning method, which solves the problem that useful files are mistakenly deleted when cache files are cleaned in the prior art.
The technical scheme adopted by the invention is as follows: a method for cleaning a cache file is characterized by comprising the following steps:
step 1: firstly, actively applying for the permission of cache cleaning to a user;
step 2, if the user does not agree with the granted permission, the cache cleaning is not executed;
and step 3: if the user agrees to grant the authority, obtaining a cache file and an original file corresponding to the cache file;
and 4, step 4: when a cache data deleting instruction is received, judging whether the cache data stored in the intelligent terminal meet a preset deleting condition;
and 5: when the cache data meet the preset deleting condition, deleting the cache data meeting the preset deleting condition;
step 6: when the cache data do not meet the preset deleting condition, the cache data which do not meet the preset deleting condition are reserved;
and 7: matching the cache information with the original file information;
and 8: matching the cache information with the original file information; when the file information in the cache information is not matched with the corresponding file information in the original file information, cleaning the cache file corresponding to the file information;
and step 9: matching the cache file with the original file, marking the cache file as a junk file when the cache file does not have the matched original file, and clearing the junk file;
step 10: acquiring a hotspot application with the running time length longer than the preset running time length in the terminal within a preset time period;
step 11: and when a cache data cleaning instruction is detected, cleaning the cache data to be cleaned.
In step 5, the preset deleting condition includes a collection state of the cache data, an access state of the cache data, a storage time of the cache data, and an index table state of the cache data.
When the collected cache data is accessed within a first preset time, the accessed cache data is reserved.
And when the file package name in the virtual machine cache package name is not matched with the corresponding file package name in the installed file package name, marking the cache file corresponding to the file package name as invalid.
The comparison is to compare the cache file with the original file in the software, and to distinguish and mark the cache file as a junk file and a normal file.
The invention has the beneficial effects that: the cleaning method is more intelligent, firstly, the cache files which are not matched with the original files are cleaned, frequently used cache files are marked, cleaning is avoided, the cache files which are not frequently used are marked, cleaning is carried out, the cache files which are frequently cleaned and frequently appear are marked, and repeated cleaning and downloading are avoided; the invention can identify the cache files which need to be reserved and the cache files which do not need to be reserved as far as possible, has more diversified cleaning modes and methods, can adapt to the use habits of users in long-term use and is more intelligent.
Detailed Description
The technical solution of the present invention will be described in detail with reference to the specific embodiments.
A method for cleaning a cache file is characterized by comprising the following steps:
step 1: firstly, actively applying for the permission of cache cleaning to a user;
step 2, if the user does not agree with the granted permission, the cache cleaning is not executed;
and step 3: if the user agrees to grant the authority, obtaining a cache file and an original file corresponding to the cache file;
and 4, step 4: when a cache data deleting instruction is received, judging whether the cache data stored in the intelligent terminal meet a preset deleting condition;
and 5: when the cache data meet the preset deleting condition, deleting the cache data meeting the preset deleting condition;
step 6: when the cache data do not meet the preset deleting condition, the cache data which do not meet the preset deleting condition are reserved;
and 7: matching the cache information with the original file information;
and 8: matching the cache information with the original file information; when the file information in the cache information is not matched with the corresponding file information in the original file information, cleaning the cache file corresponding to the file information;
and step 9: matching the cache file with the original file, marking the cache file as a junk file when the cache file does not have the matched original file, and clearing the junk file;
step 10: acquiring a hotspot application with the running time length longer than the preset running time length in the terminal within a preset time period;
step 11: and when a cache data cleaning instruction is detected, cleaning the cache data to be cleaned.
In step 5, the preset deleting condition includes a collection state of the cache data, an access state of the cache data, a storage time of the cache data, and an index table state of the cache data.
When the collected cache data is accessed within a first preset time, the accessed cache data is reserved.
And when the file package name in the virtual machine cache package name is not matched with the corresponding file package name in the installed file package name, marking the cache file corresponding to the file package name as invalid.
The comparison is to compare the cache file with the original file in the software, and to distinguish and mark the cache file as a junk file and a normal file.
The cleaning method is more intelligent, firstly, the cache files which are not matched with the original files are cleaned, frequently used cache files are marked, cleaning is avoided, the cache files which are not frequently used are marked, cleaning is carried out, the cache files which are frequently cleaned and frequently appear are marked, and repeated cleaning and downloading are avoided; the invention can identify the cache files which need to be reserved and the cache files which do not need to be reserved as far as possible, has more diversified cleaning modes and methods, can adapt to the use habits of users in long-term use and is more intelligent.
Claims (5)
1. A method for cleaning a cache file is characterized by comprising the following steps:
step 1: firstly, actively applying for the permission of cache cleaning to a user;
step 2, if the user does not agree with the granted permission, the cache cleaning is not executed;
and step 3: if the user agrees to grant the authority, obtaining a cache file and an original file corresponding to the cache file;
and 4, step 4: when a cache data deleting instruction is received, judging whether the cache data stored in the intelligent terminal meet a preset deleting condition;
and 5: when the cache data meet the preset deleting condition, deleting the cache data meeting the preset deleting condition;
step 6: when the cache data do not meet the preset deleting condition, the cache data which do not meet the preset deleting condition are reserved;
and 7: matching the cache information with the original file information;
and 8: matching the cache information with the original file information; when the file information in the cache information is not matched with the corresponding file information in the original file information, cleaning the cache file corresponding to the file information;
and step 9: matching the cache file with the original file, marking the cache file as a junk file when the cache file does not have the matched original file, and clearing the junk file;
step 10: acquiring a hotspot application with the running time length longer than the preset running time length in the terminal within a preset time period;
step 11: and when a cache data cleaning instruction is detected, cleaning the cache data to be cleaned.
2. The method for clearing the cache file according to claim 1, wherein in the step 5, the preset deletion condition includes a collection state of the cache data, an access state of the cache data, a storage time of the cache data, and an index table state of the cache data.
3. The method for clearing the cache file according to claim 2, wherein when the collected cache data is accessed within a first preset time, the accessed cache data is retained.
4. The method according to claim 1, wherein when a file package name in the virtual machine cache package name does not match a file package name corresponding to the file package name in the installed file package name, the cache file corresponding to the file package name is identified as invalid.
5. The method for cleaning up the cache file according to claim 1, wherein the comparison specifically is to compare the cache file with an original file in software, and to distinguish and mark the cache file as a junk file and a normal file.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201911156749.4A CN111026717A (en) | 2019-11-22 | 2019-11-22 | Cache file cleaning method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201911156749.4A CN111026717A (en) | 2019-11-22 | 2019-11-22 | Cache file cleaning method |
Publications (1)
Publication Number | Publication Date |
---|---|
CN111026717A true CN111026717A (en) | 2020-04-17 |
Family
ID=70202799
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201911156749.4A Pending CN111026717A (en) | 2019-11-22 | 2019-11-22 | Cache file cleaning method |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111026717A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112035529A (en) * | 2020-09-11 | 2020-12-04 | 北京字跳网络技术有限公司 | Caching method and device, electronic equipment and computer readable storage medium |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104484484A (en) * | 2015-01-08 | 2015-04-01 | 北京奇虎科技有限公司 | Method and device for removing cache file |
CN105095107A (en) * | 2014-05-04 | 2015-11-25 | 腾讯科技(深圳)有限公司 | Buffer memory data cleaning method and apparatus |
CN105893278A (en) * | 2016-03-30 | 2016-08-24 | 北京金山安全软件有限公司 | System cache garbage cleaning method and device and terminal equipment |
CN109408414A (en) * | 2018-09-30 | 2019-03-01 | 湖北华联博远科技有限公司 | A kind of software cache cleaner method and system |
-
2019
- 2019-11-22 CN CN201911156749.4A patent/CN111026717A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105095107A (en) * | 2014-05-04 | 2015-11-25 | 腾讯科技(深圳)有限公司 | Buffer memory data cleaning method and apparatus |
CN104484484A (en) * | 2015-01-08 | 2015-04-01 | 北京奇虎科技有限公司 | Method and device for removing cache file |
CN105893278A (en) * | 2016-03-30 | 2016-08-24 | 北京金山安全软件有限公司 | System cache garbage cleaning method and device and terminal equipment |
CN109408414A (en) * | 2018-09-30 | 2019-03-01 | 湖北华联博远科技有限公司 | A kind of software cache cleaner method and system |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112035529A (en) * | 2020-09-11 | 2020-12-04 | 北京字跳网络技术有限公司 | Caching method and device, electronic equipment and computer readable storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN105302832A (en) | File management method and apparatus | |
WO2013143393A1 (en) | Method and system utilizing cloud computation for scanning files of device | |
CN105095107A (en) | Buffer memory data cleaning method and apparatus | |
WO2013143391A1 (en) | Method and system for cleaning up files on device | |
CN100579122C (en) | Method for realizing browse service COOKIE of wireless application protocol gateway | |
CN102693075B (en) | On-screen data management system and method | |
CN106062693A (en) | Desktop sharing method and mobile terminal | |
CN104778172B (en) | Webpage information prefetches processing method, device and corresponding web page browsing device | |
CN104679581A (en) | Method and device for running program in background | |
CN102929960A (en) | Self-adaption method and system of theme music | |
CN111026717A (en) | Cache file cleaning method | |
CN103034669A (en) | System for providing user data storage environment using network-based file system | |
CN106406747A (en) | Hard disk storage management method and apparatus for mobile terminal | |
CN107332966A (en) | A kind of backup method of address list information | |
CN111741462B (en) | Terminal application permission change acquisition method, terminal and USIM | |
US20180341427A1 (en) | Method and apparatus for managing storage space, and electronic device | |
CN103365860A (en) | Method, device and terminal for processing web pages | |
CN1602100A (en) | Method of backup of cell phone note based on STK or UTK tech | |
KR102037556B1 (en) | Method and device for upgrading telephone number in wireless terminal self-adaptive network upgrade | |
CN102932960A (en) | Exchange system and exchange method for electronic business cards | |
CN103841253A (en) | Method and terminal for adding contact persons | |
CN106357865A (en) | Method and system for deleting contact information | |
CN110020290B (en) | Webpage resource caching method and device, storage medium and electronic device | |
CN103095891A (en) | Method, device and terminal of quickly inputting information of business card | |
US9788192B2 (en) | Making subscriber data addressable as a device in a mobile data network |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20200417 |
|
RJ01 | Rejection of invention patent application after publication |