WO2016197814A1 - Junk file identification and management method, identification device, management device and terminal - Google Patents

Junk file identification and management method, identification device, management device and terminal Download PDF

Info

Publication number
WO2016197814A1
WO2016197814A1 PCT/CN2016/083174 CN2016083174W WO2016197814A1 WO 2016197814 A1 WO2016197814 A1 WO 2016197814A1 CN 2016083174 W CN2016083174 W CN 2016083174W WO 2016197814 A1 WO2016197814 A1 WO 2016197814A1
Authority
WO
WIPO (PCT)
Prior art keywords
file
junk file
junk
attribute data
policy
Prior art date
Application number
PCT/CN2016/083174
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 WO2016197814A1 publication Critical patent/WO2016197814A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/17Details of further file system functions
    • G06F16/1727Details of free space management performed by the file system
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/17Details of further file system functions
    • G06F16/1724Details of de-fragmentation performed by the file system

Definitions

  • This document relates to, but is not limited to, the field of computer technology, and in particular, to a garbage file identification and management method, an identification device, a management device and a terminal.
  • the commonly used junk file identification method is: the user selects a file to be judged, and then adds the file to a certain detection application, and the detection application uses the preset garbage judgment model to identify the file added by the user. Not a junk file. If it is identified that a file is a junk file, the detection application suggests to the user to clean up the junk file.
  • the preset garbage judgment model is agnostic to the user, and the model is unchanged during use, but many files in the terminal are different according to the usage mode and the use time. The degree of garbage will change. The method based on the preset model to identify the junk file is less adaptable, which will produce errors and reduce the accuracy of the judgment.
  • the embodiment of the invention provides a garbage file identification and management method, a recognition device, a management device and a terminal, and solves the problem that the method for identifying a junk file in the related art has poor adaptability and low accuracy.
  • a method for identifying junk files comprising:
  • the storage object is determined to be a junk file according to the actual value of each element in the storage target element set and the threshold matching condition of the corresponding element in the preset junk file determination policy.
  • the method before the obtaining the actual value of each element in the storage object feature set according to the current target attribute data of the storage object in the file system, the method further includes:
  • the storage object comprises: a file and/or a folder.
  • the target attribute data includes operation attribute data and/or size attribute data, the element including an operation attribute element set according to the operation attribute data and/or a size attribute element set according to the size attribute data.
  • the threshold matching case includes: whether an actual value of the operation attribute element matches a threshold of the operation attribute element;
  • the threshold matching case includes whether an actual value of the size attribute element matches a threshold of the size attribute element.
  • the target attribute data further includes display status attribute data
  • the element further includes a status display element set according to the display status attribute data
  • the threshold matching situation includes: whether an actual value of the status display element matches a threshold of the status display element.
  • the operation attribute data includes at least one of an operation type, an operation time, and an operation time interval
  • the operation attribute element includes an operation type element, an operation time element, and At least one of the operational time interval elements
  • the size attribute data includes at least one of a current size of the storage object, a size change amount of the storage object within the preset time period, and a space size of the storage area where the storage object is located;
  • the size attribute element includes a current size element of the storage object, The storage object size change amount element and at least one of the space size elements of the storage area in which the storage object is located.
  • the method for identifying the junk file further includes: receiving a policy modification instruction sent by the user, and modifying the junk file judgment policy according to the policy modification instruction.
  • the policy modification instruction includes an element adjustment instruction for adjusting an element of the junk file judgment policy; and the modifying the junk file judgment policy includes: concentrating the element according to the element adjustment instruction The elements are updated, and the junk file judgment strategy is updated according to the updated feature set;
  • the policy modification instruction includes an element threshold adjustment instruction for adjusting a threshold of an element of the junk file judgment policy; and the modifying the junk file judgment policy includes: corresponding to the element tune threshold The threshold of the element is updated, and the junk file judgment policy is updated according to the updated threshold.
  • a garbage file management method comprising:
  • the managing the junk file includes:
  • a junk file identification device comprising:
  • An analysis module configured to obtain an actual value of each element in the storage object feature set according to a current target attribute data of the storage object in the file system; the element is stored according to a file system The object's target attribute data is set;
  • the judging module is configured to determine whether the storage object is a junk file according to an actual value of each element in the storage target element set and a threshold matching condition of a corresponding element in a junk file judging policy set in advance.
  • the garbage file identification device further includes:
  • the policy setting module is configured to acquire a feature set including at least one element, and set the junk file judgment policy according to a threshold of at least one of the elements.
  • the target attribute data includes operation attribute data and/or size attribute data, the element including an operation attribute element set according to the operation attribute data and/or a size attribute element set according to the size attribute data.
  • the target attribute data further includes display status attribute data
  • the element further includes a status display element set according to the display status attribute data
  • the garbage file identification device further includes:
  • a receiving module configured to receive a policy modification instruction sent by a user
  • the receiving module includes a first receiving submodule configured to receive an element adjustment instruction, where the element adjustment instruction includes a policy modification instruction for adjusting an element of the junk file determining policy; the modifying module The first modification submodule is configured to update the elements in the feature set according to the element adjustment instruction, and update the junk file determination policy according to the updated feature set;
  • the receiving module includes a second receiving submodule configured to receive an element threshold adjustment instruction, where the element threshold adjustment instruction includes a policy modification instruction for adjusting a threshold of an element of the junk file determination policy;
  • the modification module includes a second modification submodule, configured to update the threshold of the corresponding element according to the element adjustment threshold instruction, and update the junk file determination policy according to the updated threshold.
  • a junk file management device comprising:
  • the garbage file identification device described above is configured to identify the junk file in the terminal file system
  • a management module configured to manage the junk file.
  • the management module includes a management submodule:
  • a terminal comprising the above-described junk file identification device and the above-described junk file management device; the junk file identification device being included in the junk file management device; the junk file identification device being set to be garbage in a terminal file system The file is identified; the junk file management device is configured to manage the junk file identified by the junk file identification device.
  • a computer readable storage medium storing computer executable instructions for performing the above method.
  • the solution provided by the embodiment of the present invention can utilize the target attribute data of the storage object in the file system, set a feature set including at least one element according to the target attribute data, and set a garbage that can determine the junk file according to the threshold value of the element.
  • the file judgment strategy and then according to the actual target attribute data of the storage object in the file system, obtain the actual value of the element, and determine whether the storage object is a junk file according to the actual value of each element in the storage object element set and the junk file judgment policy.
  • the solution provided by the embodiment of the present invention has higher judgment accuracy, and the garbage file judgment strategy adopted by the embodiment of the present invention is set according to the element set by the target attribute data of the actual storage object, and may be different according to the selected element.
  • the solution provided by the embodiment of the present invention has good adaptability.
  • the optional solution of the embodiment of the present invention selects the operation attribute data and/or the size attribute data in the target attribute data of the storage object.
  • the requirements of the junk file judging policy may be different for different users.
  • the optional solution of the embodiment of the present invention may further modify the junk file judging policy according to the policy modification command sent by the user.
  • FIG. 1 is a schematic flowchart of a garbage file identification method according to Embodiment 1 of the present invention.
  • FIG. 2 is a schematic flowchart of a garbage file identification method according to an alternative embodiment of the present invention.
  • FIG. 3 is a schematic flowchart of a garbage file management method according to Embodiment 2 of the present invention.
  • FIG. 4 is a schematic diagram of a terminal according to Embodiment 3 of the present invention.
  • FIG. 5 is a schematic diagram of a junk file identification apparatus according to a third embodiment of the present invention.
  • FIG. 6 is a schematic diagram of a junk file management apparatus according to a third embodiment of the present invention.
  • FIG. 7 is a schematic diagram of a terminal according to an example of Embodiment 3 of the present invention.
  • FIG. 8 is a schematic flowchart of a method for cleaning a junk file according to Embodiment 4 of the present invention.
  • the system or application will generate corresponding files or folders, and these files or folders have their own corresponding attribute data.
  • the attribute data of the corresponding file or folder will also be updated, such as reading, writing, modifying, etc., and other attribute data corresponding to the data and files related to these operations will be recorded by the terminal.
  • the embodiment is based on the in-depth mining of these raw data to identify junk files.
  • Embodiment 1 is a diagrammatic representation of Embodiment 1:
  • This embodiment provides a method for cleaning a junk file that can more accurately determine and clean the junk file, improve the judging efficiency, and reduce the judging time.
  • steps S102-S103 For the method, refer to FIG. 1, including steps S102-S103:
  • S102 Obtain an actual value of each element in the storage object feature set according to the current actual target attribute data of the storage object in the file system; the element is set according to target attribute data of the storage object in the file system;
  • S103 Determine whether the storage object is a junk file according to the actual value of each element in the storage object element set and the threshold matching condition of the corresponding element in the preset junk file judgment policy.
  • the method is as shown in FIG. 2, and before step S102, the method may further include:
  • S101 Acquire a feature set including at least one element, and set the junk file judgment policy according to a threshold of at least one element.
  • the storage object in the file system includes files and/or folders, and may also include data stored in the terminal in other forms, which is gradually generated by the system or different applications during use, and the time is longer. Long, the number and size of files will increase, which will affect the speed of the terminal. In order to restore the operation speed of the terminal and improve the user experience, files and/or folders need to be cleaned up.
  • the present embodiment analyzes the garbage level of the storage object based on the data index of each aspect of each storage object in the file system, and of course stores the data of the object. There are various indicators, and not all data is helpful for judgment. Therefore, the present embodiment selects the target attribute data of the storage object as a basis.
  • the target attribute data selected in this embodiment includes but is not limited to one or more of the following: operation attribute data, size attribute data, and display state attribute data
  • the operation attribute data includes one or more related to the storage object operation.
  • Data for example, data related to the storage object operation type, data related to the operation time of the storage object, and data related to the operation time interval of the storage object
  • the size attribute data includes data related to the size of the storage object, For example, the current size of the storage object in the storage area, the size of the storage area where the storage object is located, and the size of the storage object in a certain period of time.
  • the size attribute data herein may also include a folder.
  • the number of child files; the display state attribute data is data related to one or more display states of the storage object, such as the originator of the storage object, the format of the storage object (is a file/folder), whether the storage object is readable, Whether the storage object is writable, the storage object is displayed/hidden Vietnamese and so on.
  • the elements set according to the target attribute data in S101 respectively include one or more of the following: an operation attribute element set according to the operation attribute data, a size attribute element set according to the size attribute data, and a status display according to the display status attribute data.
  • an operation attribute element set according to the operation attribute data a size attribute element set according to the size attribute data
  • a status display according to the display status attribute data a status display according to the display status attribute data.
  • none of the above three elements can be separately selected for use in formulating a junk file judgment strategy to determine junk files.
  • the operation attribute element and/or the size attribute element are selected as the basic element to formulate a junk file judgment strategy, and when the storage object element set includes the operation attribute element, the threshold matching situation includes: whether the actual value of the operation attribute element is The threshold of the operational attribute element matches;
  • the match case includes whether the actual value of the size attribute element matches the threshold of the size attribute element.
  • the operation attribute element of the embodiment includes an operation type element, an operation time element, and an operation time interval element
  • the operation type element includes all operation actions of the monitored file, such as deleting, creating, moving, copying, and opening. , modification, read and write permission modification, etc.
  • operation time elements include the time corresponding to each of the above operations, such as the time of creating the file, the time to modify the file, etc.
  • the operation time interval element can be regarded as derived from the operation time For the time period, the time interval between the current modification time and the current time interval, the time interval between the last time the file was opened, and the current time interval, etc., when setting the junk file judgment policy according to the above elements, it is necessary to set a threshold for the corresponding element, and the threshold value of the element refers to It is the condition that the selected element is satisfied.
  • the threshold here can be not only a specific value, but also a message indicating a certain state.
  • the junk file judgment strategy can be set according to the threshold of the element.
  • the selected element is the above operation time element, then the threshold is the time-related value, the selected element is the operation type element, and the threshold is an operation type.
  • the garbage policy based on the above operational attribute elements includes the following methods:
  • the operation type element is selected, and the junk file judgment policy can be set to determine the file as a junk file when it is detected that the type of operation performed on a file is deleted.
  • the junk file judgment strategy can be set to a certain operation time of a file before a certain time point, determine the file as a junk file, for example, the setting can be, the file modification time is all in August 2015 Before the 8th, the file was determined to be a junk file. Match above It means that if the actual modification time of the file is August 6, 2015, the actual value of the modification time of the file matches the threshold of the modification time in the junk file judgment policy.
  • the junk file judgment strategy can be limited to a certain operation distance of a file from the current maximum time interval, beyond the interval, the file is determined to be a junk file, for example, the setting may be, the file last accessed time If the current duration is more than 10 days, the file is determined to be a junk file. It can also be set within one week of the current time. The effective activity time of the owner of the file is less than 30s, and the file is determined to be a junk file.
  • the size attribute element of the embodiment includes a storage object current size element, a storage object size change quantity element, and a size element of the storage area where the storage object is located, and the storage element current size element includes a storage object size, if The storage object is a folder, the element refers to the overall size of the folder; the storage object size change amount element includes the amount of change of the size of the storage object in a certain period of time, and may be incremented or deviated; the storage area where the storage object is located The size element includes the total size of the storage area where the storage object is located, and the threshold corresponding to the size element is a numerical condition that the amount of change of a certain size or size satisfies.
  • the garbage determination condition set only according to the size element of the storage area in which the storage object is located may be combined with the garbage determination condition determined according to other elements to determine the junk file, and the garbage is determined according to the above-mentioned size attribute element.
  • the strategy includes the following ways:
  • junk file judgment strategy can be: a single file cumulative write size exceeds 1G, or the overall size of the folder exceeds 800M.
  • the storage object size change amount element, the junk file judgment strategy can be set as: the storage object size change amount exceeds a certain value within a certain period of time, and is determined to be a junk file, for example, may be, within 7 days according to the current time, a file The increment is over 300M and it is determined that the file may be a junk file.
  • the above matching means that if the file has an actual size increment of 200M within 7 days from the current time, the actual value of the storage object size change amount element of the file and the storage object size change amount element in the junk file judgment policy. The thresholds are not matched.
  • the file is judged to be a junk file
  • the increment of a file exceeds 300M, and the remaining space of the file is less than 10%, and the file size accounts for top 10 in the partition, and the file is judged to be a junk file;
  • the increment of a file exceeds 300M, and the cumulative write size of the file exceeds 1G, and the remaining space of the file is less than 10%, and the file size accounts for top10 in the partition, and the judgment is made.
  • the file is a junk file.
  • the matching situation includes: whether the actual value of the status display element matches the threshold of the status display element.
  • the status display element of the embodiment includes a format element, indicating whether the storage object is a file or a folder; a readable attribute element indicating whether the file is readable; a writable attribute element indicating whether the file is writable; a founder element, Represents the originator of the storage object; shows/hides the feature, indicating whether the storage object is hidden or displayed.
  • the garbage policy includes the following methods:
  • the junk file judgment strategy can be set to, the storage object is a file, or the storage object is a folder.
  • the junk file judgment strategy can be set to, the storage object can be read or the storage object can be written, and the file may be a junk file.
  • the junk file judgment strategy can be set to, the founder of the storage object is an application or system that is prone to garbage, such as the file founder is QQ, WeChat, Weibo and other applications that are prone to garbage.
  • the above matching means that if the originator of the file is QQ, the actual value of the founder element of the file matches the threshold of the founder element in the junk file judgment policy.
  • the junk file judgment policy can be set to, if the file or folder is a hidden file, the file or folder is not determined as a junk file.
  • garbage file judgment policy set according to the above four state display element settings may be selected to obtain a new junk file judgment strategy.
  • the prepared junk file judgment strategy can be freely combined into a new junk file judgment strategy; optionally, according to the status display
  • the junk file judgment strategy for element development is used together with the junk file judgment strategy based on other factors.
  • the junk file judging policy based on the operation attribute element and the size attribute element may be a set of junk judgment conditions set according to the respective sub-elements, for example, the read/write time of a file has been more than 7 days, and the file is accumulated. If the size of the file reaches or exceeds 1 GB, and the owner (application or system) of the file is active for less than or equal to 30 s in a week, the file is determined to be a junk file.
  • the junk file judgment strategy may be that the last operation time of a file is before October 30, the file read/write time interval has been more than 7 days, and the file is a non-hidden file.
  • the file is determined to be a junk file.
  • the garbage file judgment strategy based on the three elements can be: the last operation time of a file is before October 30; and the file size exceeds 1G; and the remaining space of the file partition is less than 10%; and the file is within one week.
  • the increment is more than 800M, and the file is determined to be a junk file.
  • the elements of this embodiment can also be set according to other data available for data mining.
  • other junk file judgment strategies can also be developed.
  • the junk file judging policy is set by the above manner, more than one selected element is selected, and the set junk file judging strategy is more than one. For a certain storage object, not all the actual values of the elements match.
  • the junk file judges the threshold of the elements in the strategy, but only matches a part. Then, a judgment rule can be set at this time, and the junk file is judged according to the actual matching condition.
  • the judging rule may be that the storage object element has elements in the set. The actual value is matched with the threshold of the corresponding element in the junk file judgment strategy.
  • these elements must include at least one of the above-mentioned operation attribute element and size attribute element, and the number of matching elements is greater than the preset.
  • a value is determined to determine that the storage object is a junk file.
  • the selected elements are the operation time interval element, the operation time element, the storage object current size element, and the status display element.
  • the junk file judgment strategy set according to these elements is: 1.
  • the file last accessed time is longer than 10 days from the current time. 2
  • the size of the file exceeds 1G
  • the founder of the storage object is an application or system that is prone to garbage, such as the file founder is QQ, WeChat, Weibo, etc.
  • the application, 4 file modification time is all before August 8, 2015.
  • the junk file judging policy may be set such that the actual value of the element in the storage object feature set matches at least the threshold of the element in the strategy 1, or the actual value of the element in the storage object element set matches at least the threshold of the element in the strategy 2; In addition, the number of matching elements in the storage target element set exceeds two, and it is determined that the storage object is a junk file.
  • the junk file judging policy set in the embodiment S101 may be preset on the terminal, so the S101 may also directly obtain the preset junk file judging policy.
  • the method further includes:
  • the policy modification instruction sent by the user is received, and the junk file judgment policy is modified according to the modification instruction of the policy.
  • the policy modification instruction may include a component adjustment instruction or a threshold adjustment instruction for adjusting an element of the junk file judgment policy; and the policy modification instruction is a component adjustment instruction, the junk file judgment strategy
  • the modifying includes: updating the elements in the feature set according to the element adjustment instruction, updating the junk file judgment strategy according to the updated feature set; updating the element in the feature set includes deleting or adding the element in the feature set, In the junk file judgment strategy, the corresponding junk file judgment strategy is deleted or added accordingly, and when the current target attribute data of the storage object is obtained, the acquired target attribute data also has corresponding correspondingly as the element is added or deleted. Delete or increase.
  • the junk file judgment policy set according to the element in the junk file judgment policy is also deleted, and when the target attribute data of the storage object is obtained, the storage object is not obtained.
  • the size data of the storage area is not obtained.
  • the policy modification instruction is a threshold adjustment instruction for adjusting a threshold of an element of the junk file judgment policy
  • the modifying the junk file judgment policy includes: updating a threshold of the corresponding element according to the threshold adjustment instruction, according to the updated The threshold update policy of the junk file, for example, the threshold adjustment instruction indicates that the threshold of the policy of “the size of the file exceeds 1G” is modified to 900M, and the updated junk file determination policy is “the size of the file exceeds 900M”.
  • the original attribute data on the terminal is fully utilized.
  • a feature set containing at least one feature is set, and a junk file judgment strategy is set according to the elements, and then the actual value of the element is obtained, and the actual value of the element is obtained, and then according to the actual value.
  • the threshold matching of the corresponding elements in the junk file judgment strategy, and determining whether the storage object is a junk file, such a judging method has good adaptability and high judgment accuracy.
  • Embodiment 2 is a diagrammatic representation of Embodiment 1:
  • This embodiment provides a garbage management method for managing the identified junk file.
  • the method includes steps S201 to S202:
  • the step S202 includes:
  • the first type directly delete the junk file
  • the junk file is presented to the user for confirmation, and the junk file is managed according to the first confirmation instruction of the user, including: if the first confirmation instruction is to delete the file, the junk file is directly deleted, if the first confirmation command is If the file is not deleted, the file is renamed to a non-spam file.
  • the junk file and the junk file judging policy corresponding to the junk file are presented to the user for confirmation, and the junk file is managed according to the second confirmation instruction of the user, including: if the second confirming instruction is to delete the file, directly The junk file is deleted, and if the second confirmation command is not deleting the file, the file is reclassified as a non-spam file.
  • the junk file may be marked as the file to be cleaned, and the identified junk file may be processed after the certain rules are met.
  • the rule may also be other conditions, such as a preset deletion period, and the terminal is configured to delete according to a preset. Periodically delete files scanned during the deletion period, or set the rule to delete junk files in the area when the remaining space of the storage object is less than a certain threshold.
  • This embodiment provides users with different management methods to manage the identified junk files, which can meet the different needs of users and enhance the user's sense of use, especially for presenting junk files and junk file judgment strategies for users, so that users can intuitively understand The junk file and its decision strategy help the user finally determine which files need to be deleted.
  • Embodiment 3 is a diagrammatic representation of Embodiment 3
  • the terminal includes:
  • the junk file identification device 31 is configured to identify the junk file in the terminal file system
  • the junk file management device 32 is configured to manage the junk files identified by the junk file identification device;
  • the junk file identification device 31 is included in the junk file management device 32.
  • the junk file discriminating device 31 and the junk file managing device 32 will be described in detail below with reference to Figs.
  • the junk file identification device 31 includes:
  • the analyzing module 312 is configured to obtain an actual value of each element in the storage object element set according to the current target attribute data of the storage object in the file system; the element is set according to the target attribute data of the storage object in the file system;
  • the determining module 313 is configured to determine whether the storage object is a junk file according to the actual value of each element in the storage target element set and the threshold matching condition of the corresponding element in the preset junk file judgment policy;
  • the junk file identification device 31 may further include:
  • the policy setting module 311 is configured to acquire a feature set including at least one element, and set the junk file determination policy according to a threshold of the at least one element.
  • the storage objects in this embodiment include files and/or folders.
  • This embodiment utilizes data pointers of one or more aspects of a storage object in a file system.
  • the data may be recorded when the storage object is created, or may be related information recorded during use. This information is very complicated. In order to make better use of the information, the storage object is selected in this embodiment.
  • the target attribute data is used.
  • the target attribute data includes operation attribute data and/or size attribute data
  • the element includes an operation attribute element set according to the operation attribute data and/or a size attribute element set according to the size attribute data.
  • the target attribute data further includes display status attribute data
  • the element further includes a status display element set according to the display status attribute data
  • the garbage file identifying apparatus 31 of the present embodiment further includes:
  • the receiving module 314 is configured to receive a policy modification instruction sent by the user, and the modifying module 315 is configured to modify the junk file judgment policy according to the policy modification instruction.
  • the policy modification instruction may include a component adjustment instruction or a threshold adjustment instruction; the receiving module 314 includes a first receiving submodule 3141 configured to receive an element adjustment instruction, where the element adjustment instruction is an element for determining a junk file policy The policy modification instruction to make adjustments.
  • the modification module 315 includes a first modification sub-module 3151: configured to update elements in the feature set according to the element adjustment instruction, and update the policy according to the updated feature set; the first modification sub-module 3151 updates the elements in the feature set Including, deleting or adding the elements in the feature set, correspondingly deleting or adding the corresponding junk file judgment strategy in the junk file judgment strategy, and correspondingly, the analysis module 312 acquires the target when acquiring the current target attribute data of the storage object. Attribute data will also be deleted or added as the feature is added or deleted.
  • the junk file judgment policy set according to the element in the junk file judgment policy is also deleted, and when the target attribute data of the storage object is obtained, the storage object is not obtained.
  • the size data of the storage area is not obtained.
  • the receiving module 314 includes a second receiving submodule 3142, configured to receive a component adjustment instruction
  • the element threshold adjustment instruction is a policy modification instruction for adjusting a threshold of an element of the junk file determination policy.
  • the modification module 315 includes a second modification sub-module 3152: configured to update elements in the feature set according to the element adjustment instruction, and update the policy according to the updated feature set; for example, the second modification sub-module 3152 according to the size of the file
  • the threshold of the policy exceeding 1G is modified to a threshold modification command of 900M, and the original junk file judgment policy is updated to "the file size exceeds 900M.”
  • the junk file management device 32 includes:
  • the junk file identification device 31 is configured to identify the junk file in the terminal file system
  • the management module 321 is configured to manage the junk files.
  • the management module 321 of the embodiment further includes a management submodule 3211:
  • the junk file is set to present the junk file to the user for confirmation, and manage the junk file according to the first confirmation instruction of the user. If the first confirmation instruction is to delete the file, the junk file is directly deleted, if the first confirmation instruction is not deleting the file. , the file is changed to a non-spam file.
  • FIG. 7 is a schematic diagram of an example of a terminal 3 including the modules, sub-modules involved in the alternative of the junk file identification device 31 described above, and modules involved in the alternative of the junk file management device 32. , sub-modules.
  • the elements set according to the attribute data of the storage object can be acquired, and then the junk file judging policy is set according to the threshold values of the elements, and the actual elements of the storage object are analyzed according to the obtained attribute data of the storage object.
  • the value, according to the actual value and the threshold matching condition of the corresponding element in the junk file judgment strategy, determines whether the storage object is a junk file, and then selects the management method to manage the junk file, and the terminal of the embodiment can quickly and accurately identify the junk.
  • Embodiment 4 is a diagrammatic representation of Embodiment 4:
  • a method for judging whether a file is a junk file is taken as an example to describe a method for cleaning a junk file.
  • the junk file judging policy is preset on the terminal, as shown in FIG. The process includes the following steps S401 to S409:
  • These data include, but are not limited to, the read/write type of the file, the read/write time, the read/write size, and the size change of the file after reading and writing.
  • S402 Acquire a feature set, where the elements in the feature set are set according to related data of the recorded file;
  • S406 judging whether the file is a junk file according to the junk file judgment strategy and the actual value of the element, if the judgment result is yes, proceed to S407, and if the judgment result is no, return to S401;
  • S408 receiving the user's instruction, if the user's instruction is to delete the junk file, go to S409, if the user's instruction is not to delete the file, go to S410;
  • S410 The junk file is changed to a non-spam file.
  • Embodiment 5 is a diagrammatic representation of Embodiment 5:
  • a computer readable storage medium storing computer executable instructions for performing the method of Embodiment 1 or Embodiment 2 above.
  • modules or steps of the embodiments of the present invention can be implemented by a general computing device, which can be concentrated on a single computing device or distributed over a network composed of multiple computing devices. Alternatively, they may be implemented by program code executable by the computing device such that they may be stored in a storage medium (ROM/RAM, diskette, optical disk) by a computing device, and in some cases The steps shown or described may be performed in an order different than that herein, or they may be separately fabricated into an integrated circuit module, or a plurality of modules or steps thereof may be implemented as a single integrated circuit module. Therefore, embodiments of the invention are not limited to any particular combination of hardware and software.
  • the solution provided by the embodiment of the present invention has a high judgment accuracy, and the garbage file judgment strategy adopted by the embodiment of the present invention is set according to the element set by the target attribute data of the actual storage object, and may be based on the selected element.
  • the solution provided by the embodiment of the present invention has good adaptability.

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)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

Disclosed are a junk file identification and management method, an identification device, a management device and a terminal. The junk file identification method comprises: obtaining an actual value of each element in an element set of a stored object in a file system according to current actual target attribute data of the stored object; the elements being set according to the target attribute data of the stored object in the file system; and judging whether the stored object is a junk file according to the matching condition between the actual value of each element in the element set of the stored object and a threshold of a corresponding element in a pre-set junk file judgement policy.

Description

垃圾文件识别及管理方法、识别装置、管理装置和终端Garbage file identification and management method, identification device, management device and terminal 技术领域Technical field
本文涉及但不限于计算机技术领域,尤其涉及一种垃圾文件识别及管理方法、识别装置、管理装置和终端。This document relates to, but is not limited to, the field of computer technology, and in particular, to a garbage file identification and management method, an identification device, a management device and a terminal.
背景技术Background technique
随着科学技术的发展,人们对电脑、手机等终端的依赖越来越大,对其运行速度的要求也越来越高。而在使用一段时间之后,越来越多的垃圾文件的生成却使得终端出现如卡顿、内存及内外置存储空间不足等的情况,十分影响终端的使用。为了恢复终端的运行速度,需要对终端的垃圾文件进行清理,释放更多的存储空间。With the development of science and technology, people are increasingly dependent on computers, mobile phones and other terminals, and their speed requirements are getting higher and higher. After a period of use, more and more junk files are generated, which causes the terminal to have such problems as stuck, memory, and insufficient internal and external storage space, which greatly affects the use of the terminal. In order to restore the running speed of the terminal, it is necessary to clean the junk files of the terminal and release more storage space.
相关技术中,一般采用的垃圾文件识别方法是:用户选定需要判断的文件,然后将该文件添加到某个检测应用中,检测应用利用自身预设的垃圾判断模型去识别用户添加的文件是不是垃圾文件。如果识别出某文件是垃圾文件,检测应用就给用户建议清理掉垃圾文件。在相关技术的清理方法中,预设的垃圾判断模型对用户而而言是不可知的,该模型在使用过程中是不变的,但是终端中的很多文件随着使用模式和使用时间的不同,垃圾程度会发生变化,基于预设模型去识别垃圾文件的方法适应性较差,会产生误差,降低判断的准确性。In the related art, the commonly used junk file identification method is: the user selects a file to be judged, and then adds the file to a certain detection application, and the detection application uses the preset garbage judgment model to identify the file added by the user. Not a junk file. If it is identified that a file is a junk file, the detection application suggests to the user to clean up the junk file. In the cleaning method of the related art, the preset garbage judgment model is agnostic to the user, and the model is unchanged during use, but many files in the terminal are different according to the usage mode and the use time. The degree of garbage will change. The method based on the preset model to identify the junk file is less adaptable, which will produce errors and reduce the accuracy of the judgment.
发明内容Summary of the invention
以下是对本文详细描述的主题的概述。本概述并非是为了限制权利要求的保护范围。The following is an overview of the topics detailed in this document. This Summary is not intended to limit the scope of the claims.
本发明实施例提供一种垃圾文件识别及管理方法、识别装置、管理装置和终端,解决相关技术中识别垃圾文件的方法具有的适应性差、准确性低的问题。The embodiment of the invention provides a garbage file identification and management method, a recognition device, a management device and a terminal, and solves the problem that the method for identifying a junk file in the related art has poor adaptability and low accuracy.
本发明实施例采用如下技术方案。 The embodiments of the present invention adopt the following technical solutions.
一种垃圾文件识别方法,包括:A method for identifying junk files, comprising:
根据所述文件系统中存储对象当前的目标属性数据得到该存储对象要素集中每个要素的实际值;所述要素是根据文件系统中存储对象的目标属性数据设置的;Obtaining an actual value of each element in the storage object feature set according to the current target attribute data of the storage object in the file system; the element is set according to target attribute data of the storage object in the file system;
根据所述存储对象要素集中每个要素的实际值和预先设置的垃圾文件判断策略中对应要素的阈值匹配情况,判断该存储对象是否为垃圾文件。The storage object is determined to be a junk file according to the actual value of each element in the storage target element set and the threshold matching condition of the corresponding element in the preset junk file determination policy.
可选地,所述根据所述文件系统中存储对象当前的目标属性数据得到该存储对象要素集中每个要素的实际值前还包括:Optionally, before the obtaining the actual value of each element in the storage object feature set according to the current target attribute data of the storage object in the file system, the method further includes:
获取包含至少一个要素的要素集,根据至少一个所述要素的阈值设置所述垃圾文件判断策略。Obtaining a feature set including at least one element, and setting the junk file judgment policy according to a threshold of at least one of the elements.
可选地,所述存储对象包括:文件和/或文件夹。Optionally, the storage object comprises: a file and/or a folder.
可选地,所述目标属性数据包括操作属性数据和/或大小属性数据,所述要素包括根据所述操作属性数据设置的操作属性要素和/或根据所述大小属性数据设置的大小属性要素。Optionally, the target attribute data includes operation attribute data and/or size attribute data, the element including an operation attribute element set according to the operation attribute data and/or a size attribute element set according to the size attribute data.
可选地,所述存储对象要素集包括操作属性要素时,所述阈值匹配情况包括:所述操作属性要素的实际值是否与该操作属性要素的阈值匹配;Optionally, when the set of stored object elements includes an operation attribute element, the threshold matching case includes: whether an actual value of the operation attribute element matches a threshold of the operation attribute element;
所述存储对象要素集包括大小属性要素时,所述阈值匹配情况包括:所述大小属性要素的实际值是否与该大小属性要素的阈值匹配。When the storage object element set includes a size attribute element, the threshold matching case includes whether an actual value of the size attribute element matches a threshold of the size attribute element.
可选地,所述目标属性数据还包括显示状态属性数据,所述要素还包括根据所述显示状态属性数据设置的状态显示要素。Optionally, the target attribute data further includes display status attribute data, and the element further includes a status display element set according to the display status attribute data.
可选地,所述存储对象要素集包括状态显示要素时,所述阈值匹配情况包括:所述状态显示要素的实际值是否与该状态显示要素的阈值匹配。Optionally, when the storage object feature set includes a status display element, the threshold matching situation includes: whether an actual value of the status display element matches a threshold of the status display element.
可选地,所述目标属性数据包括操作属性数据时,所述操作属性数据包括操作类型、操作时间、操作时间间隔中的至少一种,所述操作属性要素包括操作类型要素、操作时间要素和操作时间间隔要素中的至少一种;Optionally, when the target attribute data includes operation attribute data, the operation attribute data includes at least one of an operation type, an operation time, and an operation time interval, and the operation attribute element includes an operation type element, an operation time element, and At least one of the operational time interval elements;
所述目标属性数据包括大小属性数据时,所述大小属性数据包括存储对象当前大小、存储对象在预设时间段内的大小变化量、和存储对象所在存储区的空间大小中的至少一种;所述大小属性要素包括存储对象当前大小要素、 存储对象大小变化量要素、和存储对象所在存储区的空间大小要素中的至少一种。When the target attribute data includes the size attribute data, the size attribute data includes at least one of a current size of the storage object, a size change amount of the storage object within the preset time period, and a space size of the storage area where the storage object is located; The size attribute element includes a current size element of the storage object, The storage object size change amount element and at least one of the space size elements of the storage area in which the storage object is located.
可选地,所述的垃圾文件识别方法还包括:接收用户发送的策略修改指令,根据所述策略修改指令对所述垃圾文件判断策略进行修改。Optionally, the method for identifying the junk file further includes: receiving a policy modification instruction sent by the user, and modifying the junk file judgment policy according to the policy modification instruction.
可选地,所述策略修改指令包括用于对所述垃圾文件判断策略的要素进行调整的要素调整指令;所述对垃圾文件判断策略进行修改包括:根据所述要素调整指令对所述要素集中的要素进行更新,根据更新后的要素集更新所述垃圾文件判断策略;Optionally, the policy modification instruction includes an element adjustment instruction for adjusting an element of the junk file judgment policy; and the modifying the junk file judgment policy includes: concentrating the element according to the element adjustment instruction The elements are updated, and the junk file judgment strategy is updated according to the updated feature set;
或,所述策略修改指令包括用于对所述垃圾文件判断策略的要素的阈值进行调整的要素阈值调整指令;所述对垃圾文件判断策略进行修改包括:根据所述要素调阈值整指令对对应要素的阈值进行更新,根据更新后的阈值更新所述垃圾文件判断策略。Or the policy modification instruction includes an element threshold adjustment instruction for adjusting a threshold of an element of the junk file judgment policy; and the modifying the junk file judgment policy includes: corresponding to the element tune threshold The threshold of the element is updated, and the junk file judgment policy is updated according to the updated threshold.
一种垃圾文件管理方法,包括:A garbage file management method, comprising:
通过上述的垃圾文件的识别方法识别出垃圾文件;Identifying the junk file by the above method of identifying the junk file;
对所述垃圾文件进行管理。Manage the junk files.
可选地,所述对垃圾文件进行管理包括:Optionally, the managing the junk file includes:
将所述垃圾文件删除;Delete the junk file;
或者将所述垃圾文件呈现给用户进行确认,根据用户的第一确认指令对所述垃圾文件进行管理;Or presenting the junk file to the user for confirmation, and managing the junk file according to the first confirmation instruction of the user;
或者将所述垃圾文件和所述垃圾文件判断策略呈现给用户进行确认,根据用户的第二确认指令对所述垃圾文件进行管理。Or presenting the junk file and the junk file judging policy to the user for confirmation, and managing the junk file according to the second confirmation instruction of the user.
一种垃圾文件识别装置,包括:A junk file identification device comprising:
分析模块,设置成根据所述文件系统中存储对象当前的目标属性数据得到该存储对象要素集中每个要素的实际值;所述要素是根据文件系统中存储 对象的目标属性数据设置的;An analysis module configured to obtain an actual value of each element in the storage object feature set according to a current target attribute data of the storage object in the file system; the element is stored according to a file system The object's target attribute data is set;
判断模块,设置成根据所述存储对象要素集中每个要素的实际值和预先设置的垃圾文件判断策略中对应要素的阈值匹配情况,判断该存储对象是否为垃圾文件。The judging module is configured to determine whether the storage object is a junk file according to an actual value of each element in the storage target element set and a threshold matching condition of a corresponding element in a junk file judging policy set in advance.
可选地,所述的垃圾文件识别装置还包括:Optionally, the garbage file identification device further includes:
策略设置模块,设置成获取包含至少一个要素的要素集,根据至少一个所述要素的阈值设置所述垃圾文件判断策略。The policy setting module is configured to acquire a feature set including at least one element, and set the junk file judgment policy according to a threshold of at least one of the elements.
可选地,所述目标属性数据包括操作属性数据和/或大小属性数据,所述要素包括根据所述操作属性数据设置的操作属性要素和/或根据所述大小属性数据设置的大小属性要素。Optionally, the target attribute data includes operation attribute data and/or size attribute data, the element including an operation attribute element set according to the operation attribute data and/or a size attribute element set according to the size attribute data.
可选地,所述目标属性数据还包括显示状态属性数据,所述要素还包括根据所述显示状态属性数据设置的状态显示要素。Optionally, the target attribute data further includes display status attribute data, and the element further includes a status display element set according to the display status attribute data.
可选地,所述的垃圾文件识别装置,还包括:Optionally, the garbage file identification device further includes:
接收模块,设置成接收用户发送的策略修改指令;a receiving module, configured to receive a policy modification instruction sent by a user;
修改模块,设置成根据所述策略修改指令对所述垃圾文件判断策略进行修改。And modifying the module, configured to modify the junk file judgment policy according to the policy modification instruction.
可选地,所述接收模块包括第一接收子模块,设置成接收要素调整指令,所述要素调整指令包括用于对所述垃圾文件判断策略的要素进行调整的策略修改指令;所述修改模块包括第一修改子模块,设置成根据所述要素调整指令对所述要素集中的要素进行更新,根据更新后的要素集更新所述垃圾文件判断策略;Optionally, the receiving module includes a first receiving submodule configured to receive an element adjustment instruction, where the element adjustment instruction includes a policy modification instruction for adjusting an element of the junk file determining policy; the modifying module The first modification submodule is configured to update the elements in the feature set according to the element adjustment instruction, and update the junk file determination policy according to the updated feature set;
或,所述接收模块包括第二接收子模块,设置成接收要素阈值调整指令,所述要素阈值调整指令包括用于对所述垃圾文件判断策略的要素的阈值进行调整的策略修改指令;所述修改模块包括第二修改子模块,设置成根据所述要素调阈值整指令对对应要素的阈值进行更新,根据更新后的阈值更新所述垃圾文件判断策略。Or the receiving module includes a second receiving submodule configured to receive an element threshold adjustment instruction, where the element threshold adjustment instruction includes a policy modification instruction for adjusting a threshold of an element of the junk file determination policy; The modification module includes a second modification submodule, configured to update the threshold of the corresponding element according to the element adjustment threshold instruction, and update the junk file determination policy according to the updated threshold.
一种垃圾文件管理装置,包括: A junk file management device, comprising:
上述的垃圾文件识别装置,设置成对终端文件系统中的垃圾文件进行识别;The garbage file identification device described above is configured to identify the junk file in the terminal file system;
管理模块,设置成对所述垃圾文件进行管理。A management module configured to manage the junk file.
可选地,所述管理模块包括管理子模块:Optionally, the management module includes a management submodule:
设置成将所述垃圾文件删除;Set to delete the junk file;
或者设置成将所述垃圾文件呈现给用户进行确认,根据用户的第一确认指令对所述垃圾文件进行管理;Or setting to present the junk file to the user for confirmation, and managing the junk file according to the first confirmation instruction of the user;
或者设置成将所述垃圾文件和所述垃圾文件判断策略呈现给用户进行确认,根据用户的第二确认指令对所述垃圾文件进行管理。Or setting to present the junk file and the junk file judging policy to the user for confirmation, and managing the junk file according to the second confirmation instruction of the user.
一种终端,包括上述的垃圾文件识别装置和上述的垃圾文件管理装置;所述垃圾文件识别装置包含在所述垃圾文件管理装置中;所述垃圾文件识别装置设置成对终端文件系统中的垃圾文件进行识别;所述垃圾文件管理装置设置成对所述垃圾文件识别装置识别出的垃圾文件进行管理。A terminal comprising the above-described junk file identification device and the above-described junk file management device; the junk file identification device being included in the junk file management device; the junk file identification device being set to be garbage in a terminal file system The file is identified; the junk file management device is configured to manage the junk file identified by the junk file identification device.
一种计算机可读存储介质,存储有计算机可执行指令,所述计算机可执行指令用于执行上述方法。有益效果:A computer readable storage medium storing computer executable instructions for performing the above method. Beneficial effects:
采用本发明实施例提供的方案能够利用文件系统中的存储对象的目标属性数据,根据所述目标属性数据设置包含至少一个要素的要素集,又根据所述要素的阈值设置能判断垃圾文件的垃圾文件判断策略,然后根据文件系统中存储对象当前的实际目标属性数据,得到要素的实际值,根据存储对象要素集中每个要素的实际值和垃圾文件判断策略判断该存储对象是否为垃圾文件,本发明实施例提供的方案具有较高的判断准确性,又因为本发明实施例采用的垃圾文件判断策略是根据由实际的存储对象的目标属性数据设置的要素设置的,可以根据选取的要素的不同而适应不同的需要,所以本发明实施例提供的方案具有很好的适应性。The solution provided by the embodiment of the present invention can utilize the target attribute data of the storage object in the file system, set a feature set including at least one element according to the target attribute data, and set a garbage that can determine the junk file according to the threshold value of the element. The file judgment strategy, and then according to the actual target attribute data of the storage object in the file system, obtain the actual value of the element, and determine whether the storage object is a junk file according to the actual value of each element in the storage object element set and the junk file judgment policy. The solution provided by the embodiment of the present invention has higher judgment accuracy, and the garbage file judgment strategy adopted by the embodiment of the present invention is set according to the element set by the target attribute data of the actual storage object, and may be different according to the selected element. The solution provided by the embodiment of the present invention has good adaptability.
为了提高判断的准确性,且更好地利用已有资源,本发明实施例的可选方案在存储对象的目标属性数据中选择操作属性数据和/或大小属性数据来 作为设置要素的重要数据来源,并根据这两个数据分别设置操作属性要素和大小属性要素。In order to improve the accuracy of the judgment and make better use of the existing resources, the optional solution of the embodiment of the present invention selects the operation attribute data and/or the size attribute data in the target attribute data of the storage object. As an important data source for setting elements, and setting the operation attribute elements and size attribute elements separately based on these two data.
考虑到不同的用户对垃圾文件判断策略的要求可能会不同,为了适应实际需要和提高判断准确性,本发明实施例的可选方案还可以根据用户发送的策略修改指令去修改垃圾文件判断策略。In addition, the requirements of the junk file judging policy may be different for different users. In order to adapt to the actual needs and improve the judging accuracy, the optional solution of the embodiment of the present invention may further modify the junk file judging policy according to the policy modification command sent by the user.
在阅读并理解了附图和详细描述后,可以明白其它方面。Other aspects will be apparent upon reading and understanding the drawings and detailed description.
附图概述BRIEF abstract
图1为本发明实施例一提供的垃圾文件识别方法流程示意图;1 is a schematic flowchart of a garbage file identification method according to Embodiment 1 of the present invention;
图2为本发明实施例一可选方案提供的垃圾文件识别方法流程示意图;2 is a schematic flowchart of a garbage file identification method according to an alternative embodiment of the present invention;
图3为本发明实施例二提供的垃圾文件管理方法流程示意图;3 is a schematic flowchart of a garbage file management method according to Embodiment 2 of the present invention;
图4为本发明实施例三提供的终端的示意图;4 is a schematic diagram of a terminal according to Embodiment 3 of the present invention;
图5为本发明实施例三的垃圾文件识别装置的示意图;FIG. 5 is a schematic diagram of a junk file identification apparatus according to a third embodiment of the present invention; FIG.
图6为本发明实施例三的垃圾文件管理装置的示意图;6 is a schematic diagram of a junk file management apparatus according to a third embodiment of the present invention;
图7为本发明实施例三的例子的终端的示意图;7 is a schematic diagram of a terminal according to an example of Embodiment 3 of the present invention;
图8为本发明实施例四提供的垃圾文件的清理方法流程示意图。FIG. 8 is a schematic flowchart of a method for cleaning a junk file according to Embodiment 4 of the present invention.
本发明的实施方式Embodiments of the invention
在终端的使用过程中,系统或应用会产生与之对应的文件或文件夹,这些文件或文件夹都有自己对应的属性数据。运行系统或应用,相应的文件或文件夹的属性数据也会随之更新,比如进行读写、修改等操作,与这些操作相关的数据和文件对应的其他属性数据都会被终端记录下来,本申请的实施例就是基于对这些原始数据的深入挖掘,来鉴别出垃圾文件的。During the use of the terminal, the system or application will generate corresponding files or folders, and these files or folders have their own corresponding attribute data. Run the system or application, the attribute data of the corresponding file or folder will also be updated, such as reading, writing, modifying, etc., and other attribute data corresponding to the data and files related to these operations will be recorded by the terminal. The embodiment is based on the in-depth mining of these raw data to identify junk files.
实施例一:Embodiment 1:
本实施例提供一种能更准确地判断并清理垃圾文件,提高判断效率,减少判断时间的垃圾文件清理方法,该方法请参见图1,包括步骤S102~S103: This embodiment provides a method for cleaning a junk file that can more accurately determine and clean the junk file, improve the judging efficiency, and reduce the judging time. For the method, refer to FIG. 1, including steps S102-S103:
S102:根据文件系统中存储对象当前的实际目标属性数据得到该存储对象要素集中每个要素的实际值;所述要素是根据文件系统中存储对象的目标属性数据设置的;S102: Obtain an actual value of each element in the storage object feature set according to the current actual target attribute data of the storage object in the file system; the element is set according to target attribute data of the storage object in the file system;
S103:根据存储对象要素集中每个要素的实际值和预先设置的垃圾文件判断策略中对应要素的阈值匹配情况,判断该存储对象是否为垃圾文件。S103: Determine whether the storage object is a junk file according to the actual value of each element in the storage object element set and the threshold matching condition of the corresponding element in the preset junk file judgment policy.
可选地,所述方法如图2所示,步骤S102前还可以包括:Optionally, the method is as shown in FIG. 2, and before step S102, the method may further include:
S101:获取包含至少一个要素的要素集,根据至少一个要素的阈值设置所述垃圾文件判断策略。S101: Acquire a feature set including at least one element, and set the junk file judgment policy according to a threshold of at least one element.
可选地,所述文件系统中的存储对象包括文件和/或文件夹,当然也可以包括以其他形式存储在终端中的数据,是系统或不同应用在使用的过程中逐渐产生的,时间越长,文件的数量和大小都会增长,会对终端运行的速度产生影响,为了恢复终端的操作速度,提高用户的体验,需要对文件和/或文件夹进行清理。Optionally, the storage object in the file system includes files and/or folders, and may also include data stored in the terminal in other forms, which is gradually generated by the system or different applications during use, and the time is longer. Long, the number and size of files will increase, which will affect the speed of the terminal. In order to restore the operation speed of the terminal and improve the user experience, files and/or folders need to be cleaned up.
为了提高垃圾对象的判断准确性,也为了充分利用已有的数据,本实施例以文件系统中每个存储对象每方面的数据指标为基础,来分析存储对象的垃圾程度,当然存储对象的数据指标多种多样,并不是所有的数据都对判断有帮助,所以本实施例选取了存储对象的目标属性数据作为基础。In order to improve the judgment accuracy of the garbage object and to make full use of the existing data, the present embodiment analyzes the garbage level of the storage object based on the data index of each aspect of each storage object in the file system, and of course stores the data of the object. There are various indicators, and not all data is helpful for judgment. Therefore, the present embodiment selects the target attribute data of the storage object as a basis.
可选地,本实施例选取的目标属性数据包括但不限于以下一种或多种:操作属性数据、大小属性数据和显示状态属性数据,操作属性数据包含一种或多种与存储对象操作有关的数据,比如,与存储对象操作类型相关的数据、与存储对象的操作时间相关的数据、以及与存储对象的操作时间间隔相关的数据;大小属性数据包括了与存储对象的大小相关的数据,比如存储对象在所在存储区域的当前大小、存储对象所在存储区域的空间大小、存储对象在某段时间内的大小的变化量,如果存储对象是文件夹,这里的大小属性数据还可以包括文件夹的子文件数量;显示状态属性数据是与存储对象的一种或多种显示状态有关的数据,比如存储对象的创始者、存储对象的格式(是文件/文件夹)、存储对象是否可读、存储对象是否可写、存储对象是显示/隐 藏等。Optionally, the target attribute data selected in this embodiment includes but is not limited to one or more of the following: operation attribute data, size attribute data, and display state attribute data, and the operation attribute data includes one or more related to the storage object operation. Data, for example, data related to the storage object operation type, data related to the operation time of the storage object, and data related to the operation time interval of the storage object; the size attribute data includes data related to the size of the storage object, For example, the current size of the storage object in the storage area, the size of the storage area where the storage object is located, and the size of the storage object in a certain period of time. If the storage object is a folder, the size attribute data herein may also include a folder. The number of child files; the display state attribute data is data related to one or more display states of the storage object, such as the originator of the storage object, the format of the storage object (is a file/folder), whether the storage object is readable, Whether the storage object is writable, the storage object is displayed/hidden Tibetan and so on.
对应的,S101中根据目标属性数据设置的要素相应包括以下一种或多种:根据操作属性数据设置的操作属性要素、根据大小属性数据设置的大小属性要素、根据显示状态属性数据设置的状态显示要素;可选地,上述的三种要素并不都能够单独选取出来用于制定垃圾文件判断策略判断垃圾文件。Correspondingly, the elements set according to the target attribute data in S101 respectively include one or more of the following: an operation attribute element set according to the operation attribute data, a size attribute element set according to the size attribute data, and a status display according to the display status attribute data. Element; Optionally, none of the above three elements can be separately selected for use in formulating a junk file judgment strategy to determine junk files.
可选地,选取上述的操作属性要素和/或大小属性要素作为基础要素制定垃圾文件判断策略,存储对象要素集包括操作属性要素时,所述阈值匹配情况包括:操作属性要素的实际值是否与该操作属性要素的阈值匹配;Optionally, the operation attribute element and/or the size attribute element are selected as the basic element to formulate a junk file judgment strategy, and when the storage object element set includes the operation attribute element, the threshold matching situation includes: whether the actual value of the operation attribute element is The threshold of the operational attribute element matches;
存储对象要素集包括大小属性要素时,匹配情况包括:大小属性要素的实际值是否与该大小属性要素的阈值匹配。When a storage object feature set includes a size attribute element, the match case includes whether the actual value of the size attribute element matches the threshold of the size attribute element.
可选地,本实施例的操作属性要素包括操作类型要素、操作时间要素、操作时间间隔要素,上述的操作类型要素包括监控到的文件的所有操作动作,如删除,创建,移动,复制、打开、修改,可读写权限修改等等;操作时间要素包括对应于上述每种操作的时间,比如创建文件的时间、修改文件的时间等等;操作时间间隔要素可以看作根据操作时间衍生出来的时间段,如上次修改时间距离当前的时长间隔、上次打开文件的时间距离当前的时长间隔等,根据上述的要素设置垃圾文件判断策略时,需要为对应的要素设置阈值,要素的阈值指的是选中的要素满足的条件,这里的阈值不仅可以是某个具体的数值,还可以是表示某种状态的信息。Optionally, the operation attribute element of the embodiment includes an operation type element, an operation time element, and an operation time interval element, and the operation type element includes all operation actions of the monitored file, such as deleting, creating, moving, copying, and opening. , modification, read and write permission modification, etc.; operation time elements include the time corresponding to each of the above operations, such as the time of creating the file, the time to modify the file, etc.; the operation time interval element can be regarded as derived from the operation time For the time period, the time interval between the current modification time and the current time interval, the time interval between the last time the file was opened, and the current time interval, etc., when setting the junk file judgment policy according to the above elements, it is necessary to set a threshold for the corresponding element, and the threshold value of the element refers to It is the condition that the selected element is satisfied. The threshold here can be not only a specific value, but also a message indicating a certain state.
当选取好要素之后就可以根据要素的阈值设置垃圾文件判断策略,选中的要素是上述的操作时间要素,那么阈值就是与时间有关的数值,选中的要素是操作类型要素,阈值就是某个操作类型,根据上述的操作属性要素制的定垃圾策略包括以下几种方式:After selecting the good elements, the junk file judgment strategy can be set according to the threshold of the element. The selected element is the above operation time element, then the threshold is the time-related value, the selected element is the operation type element, and the threshold is an operation type. The garbage policy based on the above operational attribute elements includes the following methods:
一、选中操作类型要素,垃圾文件判断策略可以设置为,当检测到对某个文件进行的操作的类型是删除的时候,将该文件判定为垃圾文件。First, the operation type element is selected, and the junk file judgment policy can be set to determine the file as a junk file when it is detected that the type of operation performed on a file is deleted.
二、选中操作时间要素,垃圾文件判断策略可以设置为某文件的某种操作时间在某个时间点之前,判定该文件为垃圾文件,比如设置可以是,文件的修改时间全在2015年8月8号之前,判定该文件为垃圾文件。上述的匹配 指的是,如果该文件的实际修改时间是2015年8月6号,则该文件的修改时间的实际值就与垃圾文件判断策略中的修改时间的阈值是匹配的。Second, select the operation time element, the junk file judgment strategy can be set to a certain operation time of a file before a certain time point, determine the file as a junk file, for example, the setting can be, the file modification time is all in August 2015 Before the 8th, the file was determined to be a junk file. Match above It means that if the actual modification time of the file is August 6, 2015, the actual value of the modification time of the file matches the threshold of the modification time in the junk file judgment policy.
三、选中操作时间间隔要素,垃圾文件判断策略可以限定为某文件的某种操作距离当前的最大时间间隔,超过该间隔,判定该文件为垃圾文件,比如设置可以是,文件上次访问的时间距离当前的时长超过10天,判定该文件为垃圾文件,也可以设置具当前时间一周之内,文件的所有者的有效活动时间小于30s,判定该文件为垃圾文件。Third, select the operation time interval element, the junk file judgment strategy can be limited to a certain operation distance of a file from the current maximum time interval, beyond the interval, the file is determined to be a junk file, for example, the setting may be, the file last accessed time If the current duration is more than 10 days, the file is determined to be a junk file. It can also be set within one week of the current time. The effective activity time of the owner of the file is less than 30s, and the file is determined to be a junk file.
四、选择操作类型要素、操作时间要素、操作时间间隔要素中的至少两种要素去设置垃圾判断处理,如文件的修改时间全在2015年8月8号之前且文件上次访问的时间距离当前的时长超过10天,判定该文件是垃圾文件。当然也可以任一个要素匹配阈值时就判定文件为垃圾文件。4. Select at least two elements of the operation type element, the operation time element, and the operation time interval element to set the garbage judgment processing, such as the modification time of the file before August 8th, 2015 and the time when the file was last accessed from the current time The duration is more than 10 days, and the file is judged to be a junk file. Of course, it is also possible to determine that the file is a junk file when any of the elements match the threshold.
可选地,本实施例的大小属性要素包括存储对象当前大小要素、存储对象大小变化量要素、和存储对象所在存储区的大小要素等,上述的存储对象当前大小要素包括存储对象的大小,如果存储对象是文件夹,该要素指的就是文件夹的整体大小;存储对象大小变化量要素包括存储对象在某段时间内的大小变化的量,可以或增量或差量;存储对象所在存储区的大小要素包括存储对象所在的存储区域的总的大小,对应与大小要素设置的阈值是某种大小或大小的变化量满足的数值条件。Optionally, the size attribute element of the embodiment includes a storage object current size element, a storage object size change quantity element, and a size element of the storage area where the storage object is located, and the storage element current size element includes a storage object size, if The storage object is a folder, the element refers to the overall size of the folder; the storage object size change amount element includes the amount of change of the size of the storage object in a certain period of time, and may be incremented or deviated; the storage area where the storage object is located The size element includes the total size of the storage area where the storage object is located, and the threshold corresponding to the size element is a numerical condition that the amount of change of a certain size or size satisfies.
上述的几种大小属性要素中,只根据存储对象所在存储区的大小要素设置的垃圾判断条件可以和根据其他要素制定的垃圾判断条件组合来判断垃圾文件,根据上述的大小属性要素制的定垃圾策略包括以下几种方式:Among the above-mentioned several size attribute elements, the garbage determination condition set only according to the size element of the storage area in which the storage object is located may be combined with the garbage determination condition determined according to other elements to determine the junk file, and the garbage is determined according to the above-mentioned size attribute element. The strategy includes the following ways:
一、选中存储对象当前大小要素,垃圾文件判断策略可以是:单个文件累计写入大小超过1G,或文件夹的整体大小超过800M等。First, select the current size of the storage object, junk file judgment strategy can be: a single file cumulative write size exceeds 1G, or the overall size of the folder exceeds 800M.
二、存储对象大小变化量要素,垃圾文件判断策略可以设置为:某段时间内存储对象大小变化量超过某个值,判定为垃圾文件,比如可以是,在据当前时间7天内,某文件的增量超过300M,判定该文件可能为垃圾文件。上述的匹配指的是,如果该文件在距离当前时间7天内的实际大小增量200M,则该文件的存储对象大小变化量要素的实际值就与垃圾文件判断策略中的存储对象大小变化量要素的阈值是不匹配的。 Second, the storage object size change amount element, the junk file judgment strategy can be set as: the storage object size change amount exceeds a certain value within a certain period of time, and is determined to be a junk file, for example, may be, within 7 days according to the current time, a file The increment is over 300M and it is determined that the file may be a junk file. The above matching means that if the file has an actual size increment of 200M within 7 days from the current time, the actual value of the storage object size change amount element of the file and the storage object size change amount element in the junk file judgment policy. The thresholds are not matched.
三、选中存储对象当前大小要素和存储对象大小变化量要素中任一种或全选,与存储对象所在存储区的大小要素组合来设置垃圾文件判断策略,3. Select any one or all of the storage object current size element and the storage object size change quantity element, and combine with the size element of the storage area where the storage object is located to set the junk file judgment strategy.
如单个文件累计写入大小超过1G,且文件所在分区剩余空间不足10%,而该文件大小在该分区占top 10(前十),判断该文件是垃圾文件;If the accumulated write size of a single file exceeds 1G, and the remaining space of the partition where the file is located is less than 10%, and the file size is in the top 10 (top ten) of the partition, the file is judged to be a junk file;
或距当前7周之内,某文件的增量超过300M,且文件所在分区剩余空间不足10%,而该文件大小在该分区占top 10,判断该文件是垃圾文件;Or within 7 weeks from the current, the increment of a file exceeds 300M, and the remaining space of the file is less than 10%, and the file size accounts for top 10 in the partition, and the file is judged to be a junk file;
或距当前7周之内,某文件的增量超过300M,且该文件的累计写入大小超过1G,且该文件所在分区剩余空间不足10%,而该文件大小在该分区占top10,判断该文件是垃圾文件。Or within 7 weeks from the current, the increment of a file exceeds 300M, and the cumulative write size of the file exceeds 1G, and the remaining space of the file is less than 10%, and the file size accounts for top10 in the partition, and the judgment is made. The file is a junk file.
可选地,本实施例的存储对象要素集包括状态显示要素时,匹配情况包括:状态显示要素的实际值是否与该状态显示要素的阈值匹配。Optionally, when the storage object element set of the embodiment includes the status display element, the matching situation includes: whether the actual value of the status display element matches the threshold of the status display element.
可选地,本实施例的状态显示要素包括格式要素,表示存储对象是文件还是文件夹;可读属性要素,表示文件是否可读;可写属性要素,表示文件是否可写;创始者要素,表示存储对象的创始者;显示/隐藏要素,表示存储对象是隐藏还是显示状态。Optionally, the status display element of the embodiment includes a format element, indicating whether the storage object is a file or a folder; a readable attribute element indicating whether the file is readable; a writable attribute element indicating whether the file is writable; a founder element, Represents the originator of the storage object; shows/hides the feature, indicating whether the storage object is hidden or displayed.
根据上述的状态显示要素制的定垃圾策略包括以下几种方式:According to the above state display element system, the garbage policy includes the following methods:
一、只选格式要素,垃圾文件判断策略可以设置为,存储对象是文件、或存储对象是文件夹。First, only select the format elements, the junk file judgment strategy can be set to, the storage object is a file, or the storage object is a folder.
二、只选可读属性要素或可写属性要素,垃圾文件判断策略可以设置为,存储对象可读或存储对象可写,文件可能是垃圾文件。Second, only select the readable attribute element or the writable attribute element, the junk file judgment strategy can be set to, the storage object can be read or the storage object can be written, and the file may be a junk file.
三、只选创始者要素,垃圾文件判断策略可以设置为,存储对象的创始者是容易产生垃圾的应用或系统,如文件创始者是QQ、微信、微博等易产生垃圾的应用。上述的匹配指的是,如果该文件的创始者是QQ,则该文件的创始者要素的实际值就与垃圾文件判断策略中的创始者要素的阈值是匹配的。Third, only the founder element, the junk file judgment strategy can be set to, the founder of the storage object is an application or system that is prone to garbage, such as the file founder is QQ, WeChat, Weibo and other applications that are prone to garbage. The above matching means that if the originator of the file is QQ, the actual value of the founder element of the file matches the threshold of the founder element in the junk file judgment policy.
四、只选显示/隐藏要素,垃圾文件判断策略可以设置为,文件或文件夹是隐藏文件,则不将文件或文件夹判定为垃圾文件。4. Only select/hide elements, the junk file judgment policy can be set to, if the file or folder is a hidden file, the file or folder is not determined as a junk file.
另外、可以选择上述的根据上述四种状态显示要素设置的垃圾文件判断策略任意组合得到新的垃圾文件判断策略。 In addition, the garbage file judgment policy set according to the above four state display element settings may be selected to obtain a new junk file judgment strategy.
上述根据三大类要素中的一种或多种:操作属性要素、大小属性要素、状态显示要素,制定的垃圾文件判断策略可以随意组合成新的垃圾文件判断策略;可选地,根据状态显示要素制定的垃圾文件判断策略和根据其他的要素制定的垃圾文件判断策略一起使用。According to one or more of the three categories of elements: the operation attribute element, the size attribute element, and the status display element, the prepared junk file judgment strategy can be freely combined into a new junk file judgment strategy; optionally, according to the status display The junk file judgment strategy for element development is used together with the junk file judgment strategy based on other factors.
根据操作属性要素和大小属性要素制定的垃圾文件判断策略可以是根据各自的子要素设置的垃圾判断条件的集合,例如,某文件的读写时间距目前已经超过7天以上,且该文件累计写入大小达到或超过1GB以上,且一周内该文件的所有者(应用或系统)有效活动的时间小于等于30s,判定该文件为垃圾文件。The junk file judging policy based on the operation attribute element and the size attribute element may be a set of junk judgment conditions set according to the respective sub-elements, for example, the read/write time of a file has been more than 7 days, and the file is accumulated. If the size of the file reaches or exceeds 1 GB, and the owner (application or system) of the file is active for less than or equal to 30 s in a week, the file is determined to be a junk file.
根据操作属性要素和状态显示要素制定的垃圾文件判断策略可以是,某文件最后一次的操作时间在10月30号之前,文件的读写时间距目前已经超过7天以上,且文件是非隐藏文件,判定该文件为垃圾文件。According to the operation attribute element and the status display element, the junk file judgment strategy may be that the last operation time of a file is before October 30, the file read/write time interval has been more than 7 days, and the file is a non-hidden file. The file is determined to be a junk file.
根据三大要素制定的垃圾文件判断策略可以是:某文件最后一次的操作时间在10月30号之前;且文件的大小超过1G;且文件所在分区剩余的空间不足10%;且文件在一周内的增量超过800M,判定该文件为垃圾文件。The garbage file judgment strategy based on the three elements can be: the last operation time of a file is before October 30; and the file size exceeds 1G; and the remaining space of the file partition is less than 10%; and the file is within one week. The increment is more than 800M, and the file is determined to be a junk file.
当然,除了上述的属性数据外,本实施例要素还可以根据其它可供数据挖掘的数据来设置。除了上述的示例外,也可以制定其它垃圾文件判断策略。Of course, in addition to the above attribute data, the elements of this embodiment can also be set according to other data available for data mining. In addition to the above examples, other junk file judgment strategies can also be developed.
可选地,如果通过上述的方式设置垃圾文件判断策略时,选中的要素不止一个,设置的垃圾文件判断策略也不止一个,可能对某个存储对象而言,不是所有的要素的实际值都匹配垃圾文件判断策略中的要素的阈值,而是只能匹配一部分,那么这时候可以再设置一个判断规则,根据实际的匹配情况来判断垃圾文件,该判断规则可以是,存储对象要素集中有要素的实际值与垃圾文件判断策略中对应要素的阈值匹配的要素,当然,这些要素中必须包含上述提到的操作属性要素和大小属性要素中的至少一种,而且匹配的要素的个数大于预设的某个数值,才判断该存储对象为垃圾文件。例如选中的要素是操作时间间隔要素、操作时间要素、存储对象当前大小要素、状态显示要素,根据这些要素设置的垃圾文件判断策略为:1、文件上次访问的时间距离当前的时长超过10天,2、文件的大小超过1G,3、存储对象的创始者是容易产生垃圾的应用或系统,如文件创始者是QQ、微信、微博等易产生垃圾 的应用,4、文件的修改时间全在2015年8月8号之前。垃圾文件判断策略可以设置为,存储对象要素集中的要素的实际值至少与策略1中的要素的阈值匹配,或存储对象要素集中的要素的实际值至少与策略2中的要素的阈值匹配;在此基础上,存储对象要素集中的匹配的要素的个数超过2个,判断存储对象为垃圾文件。Optionally, if the junk file judging policy is set by the above manner, more than one selected element is selected, and the set junk file judging strategy is more than one. For a certain storage object, not all the actual values of the elements match. The junk file judges the threshold of the elements in the strategy, but only matches a part. Then, a judgment rule can be set at this time, and the junk file is judged according to the actual matching condition. The judging rule may be that the storage object element has elements in the set. The actual value is matched with the threshold of the corresponding element in the junk file judgment strategy. Of course, these elements must include at least one of the above-mentioned operation attribute element and size attribute element, and the number of matching elements is greater than the preset. A value is determined to determine that the storage object is a junk file. For example, the selected elements are the operation time interval element, the operation time element, the storage object current size element, and the status display element. The junk file judgment strategy set according to these elements is: 1. The file last accessed time is longer than 10 days from the current time. 2, the size of the file exceeds 1G, 3, the founder of the storage object is an application or system that is prone to garbage, such as the file founder is QQ, WeChat, Weibo, etc. The application, 4, file modification time is all before August 8, 2015. The junk file judging policy may be set such that the actual value of the element in the storage object feature set matches at least the threshold of the element in the strategy 1, or the actual value of the element in the storage object element set matches at least the threshold of the element in the strategy 2; In addition, the number of matching elements in the storage target element set exceeds two, and it is determined that the storage object is a junk file.
本实施例S101中设置的垃圾文件判断策略可以是预先设置在终端上的,所以S101也可以是直接获取预设的垃圾文件判断策略。The junk file judging policy set in the embodiment S101 may be preset on the terminal, so the S101 may also directly obtain the preset junk file judging policy.
不同终端上的存储对象的属性数据不尽相同,所以不同的用户对垃圾文件判断策略的要求可能会有不同。为了满足用户的需求和提高本发明在不同终端的适应性,可选地,本实施例中,所述方法还包括:The attribute data of storage objects on different terminals are different, so different users may have different requirements for junk file judgment policies. In order to meet the requirements of the user and improve the adaptability of the present invention to different terminals, optionally, in this embodiment, the method further includes:
接收用户发送的策略修改指令,根据用该策略修改指令对垃圾文件判断策略进行修改。The policy modification instruction sent by the user is received, and the junk file judgment policy is modified according to the modification instruction of the policy.
可选地,所述策略修改指令可以包括用于对垃圾文件判断策略的要素进行调整的要素调整指令或是阈值调整指令;所述策略修改指令是要素调整指令时,所述对垃圾文件判断策略进行修改包括:根据所述要素调整指令对所述要素集中的要素进行更新,根据更新后的要素集更新所述垃圾文件判断策略;对要素集中的要素更新包括,删除或增加要素集中的要素,在垃圾文件判断策略里会相应地删除或增加相应的垃圾文件判断策略,而且在获取存储对象的当前的目标属性数据时,获取的目标属性数据也会随着要素的增加或删除而有相应的删除或增加。例如当要素集中删除存储对象所在存储区的大小要素,垃圾文件判断策略中根据该要素设置的垃圾文件判断策略也会被删除,在获取存储对象的目标属性数据时,也不会获取存储对象所在存储区的大小数据。Optionally, the policy modification instruction may include a component adjustment instruction or a threshold adjustment instruction for adjusting an element of the junk file judgment policy; and the policy modification instruction is a component adjustment instruction, the junk file judgment strategy The modifying includes: updating the elements in the feature set according to the element adjustment instruction, updating the junk file judgment strategy according to the updated feature set; updating the element in the feature set includes deleting or adding the element in the feature set, In the junk file judgment strategy, the corresponding junk file judgment strategy is deleted or added accordingly, and when the current target attribute data of the storage object is obtained, the acquired target attribute data also has corresponding correspondingly as the element is added or deleted. Delete or increase. For example, when the feature element deletes the size element of the storage area where the storage object is located, the junk file judgment policy set according to the element in the junk file judgment policy is also deleted, and when the target attribute data of the storage object is obtained, the storage object is not obtained. The size data of the storage area.
策略修改指令是用于对垃圾文件判断策略的要素的阈值进行调整的阈值调整指令时,所述对垃圾文件判断策略进行修改包括:根据阈值调整指令对对应要素的阈值进行更新,根据更新后的阈值更新所述垃圾文件判断策略,例如阈值调整指令指示将“文件的大小超过1G”这条策略的阈值修改为900M,则更新后的垃圾文件判断策略是“文件的大小超过900M”。The policy modification instruction is a threshold adjustment instruction for adjusting a threshold of an element of the junk file judgment policy, and the modifying the junk file judgment policy includes: updating a threshold of the corresponding element according to the threshold adjustment instruction, according to the updated The threshold update policy of the junk file, for example, the threshold adjustment instruction indicates that the threshold of the policy of “the size of the file exceeds 1G” is modified to 900M, and the updated junk file determination policy is “the size of the file exceeds 900M”.
采用本实施例的垃圾文件识别方法,充分利用了终端上原始的属性数据, 并根据这些属性数据设置了包含至少一个要素的要素集,又根据这些要素设置了垃圾文件判断策略,然后在获取存储对象当前的实际属性数据的基础上,得到要素的实际值,再根据实际值和垃圾文件判断策略中对应要素的阈值匹配情况,判断存储对象是否为垃圾文件,这样的判断方法具有良好的适应性,和较高的判断准确性。By adopting the junk file identification method of the embodiment, the original attribute data on the terminal is fully utilized. According to the attribute data, a feature set containing at least one feature is set, and a junk file judgment strategy is set according to the elements, and then the actual value of the element is obtained, and the actual value of the element is obtained, and then according to the actual value. And the threshold matching of the corresponding elements in the junk file judgment strategy, and determining whether the storage object is a junk file, such a judging method has good adaptability and high judgment accuracy.
实施例二:Embodiment 2:
本实施例提供了一种垃圾管理方法,对识别出的垃圾文件进行管理,参见图3,包括步骤S201~S202:This embodiment provides a garbage management method for managing the identified junk file. Referring to FIG. 3, the method includes steps S201 to S202:
S201:通过实施例一所述的垃圾文件识别方法识别出垃圾文件;S201: Identify the junk file by using the junk file identification method described in the first embodiment;
S202:对垃圾文件进行管理。S202: Manage garbage files.
在识别出垃圾文件之后,就需要对垃圾文件进行处理,但是垃圾文件中可能会有用户自身需要的文件,例如长时间没有读取的视频或照片,虽然被判断垃圾文件,但是实际上可能是用户需要保留的,如果清理了,会造成用户数据的丢失。为了避免这种情况,可选地,本实施例为用户提供了垃圾文件的不同管理方式供用户选择,所述步骤S202包括:After the junk file is identified, the junk file needs to be processed, but the junk file may have files that the user needs, such as videos or photos that have not been read for a long time. Although it is judged as junk files, it may actually be If the user needs to keep it, if it is cleaned up, the user data will be lost. In order to avoid this situation, the embodiment provides the user with different management modes of the junk file for the user to select. The step S202 includes:
第一种,直接将垃圾文件删除;The first type, directly delete the junk file;
第二种,将垃圾文件呈现给用户进行确认,根据用户的第一确认指令对垃圾文件进行管理,包括:如果第一确认指令为删除文件,则直接删除该垃圾文件,如果第一确认指令为不删除文件,则将该文件改判为非垃圾文件。Secondly, the junk file is presented to the user for confirmation, and the junk file is managed according to the first confirmation instruction of the user, including: if the first confirmation instruction is to delete the file, the junk file is directly deleted, if the first confirmation command is If the file is not deleted, the file is renamed to a non-spam file.
第三种,将垃圾文件和与该垃圾文件对应的垃圾文件判断策略呈现给用户进行确认,根据用户的第二确认指令对垃圾文件进行管理,包括:如果第二确认指令为删除文件,则直接删除该垃圾文件,如果第二确认指令为不删除文件,则将该文件改判为非垃圾文件。Thirdly, the junk file and the junk file judging policy corresponding to the junk file are presented to the user for confirmation, and the junk file is managed according to the second confirmation instruction of the user, including: if the second confirming instruction is to delete the file, directly The junk file is deleted, and if the second confirmation command is not deleting the file, the file is reclassified as a non-spam file.
如果用户选择上述的第二或第三种对垃圾文件的管理方法,那么在垃圾文件识别完成后,可以先将垃圾文件标记为待清理文件,等到满足一定规则后再对识别出的垃圾文件进行处理,该规则除了收到上述用户发送的确认指令外,还可以是其他的条件,例如预设删除周期,规定终端按照预设的删除 周期删除在该删除周期内扫描到的文件,或者将该规则设置为当存储对象所在区域剩余空间小于一定阈值的时候,删除区域内的垃圾文件等等。If the user selects the second or third management method for the junk file mentioned above, after the junk file identification is completed, the junk file may be marked as the file to be cleaned, and the identified junk file may be processed after the certain rules are met. Processing, in addition to receiving the confirmation command sent by the user, the rule may also be other conditions, such as a preset deletion period, and the terminal is configured to delete according to a preset. Periodically delete files scanned during the deletion period, or set the rule to delete junk files in the area when the remaining space of the storage object is less than a certain threshold.
本实施例为用户提供了不同的管理方式来管理识别出的垃圾文件,能满足用户的不同需要,提升用户使用感,尤其是为用户呈现垃圾文件和垃圾文件判断策略,让用户能直观的了解垃圾文件和它的判定策略,帮助用户最终确定哪些文件需要删除。This embodiment provides users with different management methods to manage the identified junk files, which can meet the different needs of users and enhance the user's sense of use, especially for presenting junk files and junk file judgment strategies for users, so that users can intuitively understand The junk file and its decision strategy help the user finally determine which files need to be deleted.
实施例三:Embodiment 3:
本实施例提供一种终端3,该终端请参见图4,包括:This embodiment provides a terminal 3. Referring to FIG. 4, the terminal includes:
垃圾文件识别装置31,设置成对终端文件系统中的垃圾文件进行识别;The junk file identification device 31 is configured to identify the junk file in the terminal file system;
垃圾文件管理装置32,设置成对垃圾文件的识别装置识别出的垃圾文件进行管理;The junk file management device 32 is configured to manage the junk files identified by the junk file identification device;
其中,所述垃圾文件识别装置31包含在所述垃圾文件管理装置32中。The junk file identification device 31 is included in the junk file management device 32.
下面结合图5、6分别对垃圾文件识别装置31和垃圾文件管理装置32进行详细的说明。The junk file discriminating device 31 and the junk file managing device 32 will be described in detail below with reference to Figs.
垃圾文件识别装置31,参见图7,包括:The junk file identification device 31, see Fig. 7, includes:
分析模块312,设置成根据文件系统中存储对象当前的目标属性数据得到该存储对象要素集中每个要素的实际值;所述要素是根据文件系统中存储对象的目标属性数据设置的;The analyzing module 312 is configured to obtain an actual value of each element in the storage object element set according to the current target attribute data of the storage object in the file system; the element is set according to the target attribute data of the storage object in the file system;
判断模块313,设置成根据存储对象要素集中每个要素的实际值和预先设置的垃圾文件判断策略中对应要素的阈值匹配情况,判断该存储对象是否为垃圾文件;The determining module 313 is configured to determine whether the storage object is a junk file according to the actual value of each element in the storage target element set and the threshold matching condition of the corresponding element in the preset junk file judgment policy;
所述垃圾文件识别装置31还可以包括:The junk file identification device 31 may further include:
策略设置模块311,设置成获取包含至少一个要素的要素集,根据至少一个要素的阈值设置所述垃圾文件判断策略。The policy setting module 311 is configured to acquire a feature set including at least one element, and set the junk file determination policy according to a threshold of the at least one element.
可选地,本实施例中的存储对象包括文件和/或文件夹。Optionally, the storage objects in this embodiment include files and/or folders.
本实施例利用的是文件系统中的存储对象的一个或多个方面的数据指 标,这些数据可能是存储对象在被创建时记录下来的,也可能是在使用过程中记录下的相关信息,这些信息十分繁杂,为了更好地利用该信息,本实施例中选取了存储对象的目标属性数据来使用。This embodiment utilizes data pointers of one or more aspects of a storage object in a file system. The data may be recorded when the storage object is created, or may be related information recorded during use. This information is very complicated. In order to make better use of the information, the storage object is selected in this embodiment. The target attribute data is used.
可选地,所述目标属性数据包括操作属性数据和/或大小属性数据,要素包括根据操作属性数据设置的操作属性要素和/或根据大小属性数据设置的大小属性要素。Optionally, the target attribute data includes operation attribute data and/or size attribute data, and the element includes an operation attribute element set according to the operation attribute data and/or a size attribute element set according to the size attribute data.
可选地,所述目标属性数据还包括显示状态属性数据,对应的,要素还包括根据显示状态属性数据设置的状态显示要素。Optionally, the target attribute data further includes display status attribute data, and correspondingly, the element further includes a status display element set according to the display status attribute data.
上述要素的内容,和根据要素设置垃圾文件判断策略的方法参见本发明的实施例一。The content of the above elements and the method of setting the junk file judging policy according to the elements are referred to the first embodiment of the present invention.
不同终端上的存储对象的属性数据不尽相同,所以不同的用户对垃圾文件判断策略的要求可能会有不同。为了满足用户的需求和提高本发明在不同终端的适应性,可选地,本实施的垃圾文件识别装置31还包括:The attribute data of storage objects on different terminals are different, so different users may have different requirements for junk file judgment policies. In order to meet the needs of the user and improve the adaptability of the present invention to different terminals, the garbage file identifying apparatus 31 of the present embodiment further includes:
接收模块314,设置成接收用户发送的策略修改指令,和修改模块315:设置成根据策略修改指令对垃圾文件判断策略进行修改。The receiving module 314 is configured to receive a policy modification instruction sent by the user, and the modifying module 315 is configured to modify the junk file judgment policy according to the policy modification instruction.
可选地,策略修改指令可以包括要素调整指令或是阈值调整指令;接收模块314包括第一接收子模块3141,设置成接收要素调整指令,该要素调整指令是用于对垃圾文件判断策略的要素进行调整的策略修改指令。相应地,修改模块315包括第一修改子模块3151:设置成根据要素调整指令对要素集中的要素进行更新,根据更新后的要素集更新策略;上述第一修改子模块3151对要素集中的要素更新包括,删除或增加要素集中的要素,在垃圾文件判断策略里会相应地删除或增加相应的垃圾文件判断策略,相应地,分析模块312在获取存储对象的当前的目标属性数据时,获取的目标属性数据也会随着要素的增加或删除而有相应的删除或增加。例如当要素集中删除存储对象所在存储区的大小要素,垃圾文件判断策略中根据该要素设置的垃圾文件判断策略也会被删除,在获取存储对象的目标属性数据时,也不会获取存储对象所在存储区的大小数据。Optionally, the policy modification instruction may include a component adjustment instruction or a threshold adjustment instruction; the receiving module 314 includes a first receiving submodule 3141 configured to receive an element adjustment instruction, where the element adjustment instruction is an element for determining a junk file policy The policy modification instruction to make adjustments. Correspondingly, the modification module 315 includes a first modification sub-module 3151: configured to update elements in the feature set according to the element adjustment instruction, and update the policy according to the updated feature set; the first modification sub-module 3151 updates the elements in the feature set Including, deleting or adding the elements in the feature set, correspondingly deleting or adding the corresponding junk file judgment strategy in the junk file judgment strategy, and correspondingly, the analysis module 312 acquires the target when acquiring the current target attribute data of the storage object. Attribute data will also be deleted or added as the feature is added or deleted. For example, when the feature element deletes the size element of the storage area where the storage object is located, the junk file judgment policy set according to the element in the junk file judgment policy is also deleted, and when the target attribute data of the storage object is obtained, the storage object is not obtained. The size data of the storage area.
或者接收模块314包括第二接收子模块3142,设置成接收要素调整指令, 该要素阈值调整指令是用于对垃圾文件判断策略的要素的阈值进行调整的策略修改指令。相应地,修改模块315包括第二修改子模块3152:设置成根据要素调整指令对要素集中的要素进行更新,根据更新后的要素集更新策略;例如第二修改子模块3152根据将“文件的大小超过1G”这条策略的阈值修改为900M的阈值修改指令,将原垃圾文件判断策略更新为“文件的大小超过900M”。Or the receiving module 314 includes a second receiving submodule 3142, configured to receive a component adjustment instruction, The element threshold adjustment instruction is a policy modification instruction for adjusting a threshold of an element of the junk file determination policy. Correspondingly, the modification module 315 includes a second modification sub-module 3152: configured to update elements in the feature set according to the element adjustment instruction, and update the policy according to the updated feature set; for example, the second modification sub-module 3152 according to the size of the file The threshold of the policy exceeding 1G is modified to a threshold modification command of 900M, and the original junk file judgment policy is updated to "the file size exceeds 900M."
垃圾文件管理装置32,参见图6,包括:The junk file management device 32, see Fig. 6, includes:
垃圾文件识别装置31,设置成对终端文件系统中的垃圾文件进行识别;The junk file identification device 31 is configured to identify the junk file in the terminal file system;
管理模块321,设置成对垃圾文件进行管理。The management module 321 is configured to manage the junk files.
可选地,为了给用户通过不同的管理垃圾文件的方法,本实施例的管理模块321,还包括管理子模块3211:Optionally, in order to provide the user with a different method for managing the junk file, the management module 321 of the embodiment further includes a management submodule 3211:
设置成直接将垃圾文件删除;Set to delete junk files directly;
或设置成将垃圾文件呈现给用户进行确认,根据用户的第一确认指令对垃圾文件进行管理,如果第一确认指令为删除文件,则直接删除该垃圾文件,如果第一确认指令为不删除文件,则将该文件改判为非垃圾文件。Or set to present the junk file to the user for confirmation, and manage the junk file according to the first confirmation instruction of the user. If the first confirmation instruction is to delete the file, the junk file is directly deleted, if the first confirmation instruction is not deleting the file. , the file is changed to a non-spam file.
或设置成将垃圾文件和与该垃圾文件对应的垃圾文件判断策略呈现给用户进行确认,根据用户的第二确认指令对垃圾文件进行管理,如果第二确认指令为删除文件,则直接删除该垃圾文件,如果第二确认指令为不删除文件,则将该文件改判为非垃圾文件。Or set to present the junk file and the junk file judging policy corresponding to the junk file to the user for confirmation, and manage the junk file according to the second confirmation instruction of the user, and if the second confirmation command is to delete the file, directly delete the junk. File, if the second confirmation command is to not delete the file, the file is changed to a non-spam file.
图7为终端3的一个例子的示意图,所述终端包括上面所描述的垃圾文件识别装置31的可选方案中涉及的模块、子模块,以及垃圾文件管理装置32的可选方案中涉及的模块、子模块。7 is a schematic diagram of an example of a terminal 3 including the modules, sub-modules involved in the alternative of the junk file identification device 31 described above, and modules involved in the alternative of the junk file management device 32. , sub-modules.
采用本实施例的终端,能获取到根据存储对象的属性数据设置的要素,然后根据这些要素的阈值设置垃圾文件判断策略,根据获取的存储对象当前的属性数据分析得到存储对象对应的要素的实际值,根据该实际值和垃圾文件判断策略中对应要素的阈值匹配情况,判断存储对象是否为垃圾文件,然后再选择管理方法对垃圾文件进行管理,本实施例的终端能快速准确的识别出垃圾文件,然后根据用户选取的管理方式对垃圾文件进行管理,使判断准 确性和用户使用感都得到了提升。With the terminal of the embodiment, the elements set according to the attribute data of the storage object can be acquired, and then the junk file judging policy is set according to the threshold values of the elements, and the actual elements of the storage object are analyzed according to the obtained attribute data of the storage object. The value, according to the actual value and the threshold matching condition of the corresponding element in the junk file judgment strategy, determines whether the storage object is a junk file, and then selects the management method to manage the junk file, and the terminal of the embodiment can quickly and accurately identify the junk. File, and then manage the junk files according to the management mode selected by the user, so that the judgment is accurate Both the certainty and the sense of user use have improved.
实施例四:Embodiment 4:
本实施例以判断某一文件是否为垃圾文件为例,来对垃圾文件的清理方法做一个详细的描述,本实施例中,垃圾文件判断策略是预先设置在终端上的,请参见图8,流程包括如下步骤S401~S409:In this embodiment, a method for judging whether a file is a junk file is taken as an example to describe a method for cleaning a junk file. In this embodiment, the junk file judging policy is preset on the terminal, as shown in FIG. The process includes the following steps S401 to S409:
S401:当某文件被访问时,记录该文件的相关数据;S401: When a file is accessed, record related data of the file;
这些数据包括但不限于文件的读/写类型,读/写时间,读写大小,读写后该文件的大小变化等。These data include, but are not limited to, the read/write type of the file, the read/write time, the read/write size, and the size change of the file after reading and writing.
S402:获取要素集,该要素集中的要素是根据记录的文件的相关数据设置的;S402: Acquire a feature set, where the elements in the feature set are set according to related data of the recorded file;
S403:获取垃圾文件判断策略;S403: Acquire a junk file judgment strategy;
S404:获取该文件当前的目标属性数据;S404: Obtain current target attribute data of the file.
S405:基于文件当前的目标属性数据分析得到要素的实际值;S405: Analyze an actual value of the element based on the current target attribute data of the file;
S406:根据垃圾文件判断策略和要素的实际值判断该文件是否为垃圾文件,如果判断结果为是,进入S407,如果判断结果为否,返回S401;S406: judging whether the file is a junk file according to the junk file judgment strategy and the actual value of the element, if the judgment result is yes, proceed to S407, and if the judgment result is no, return to S401;
S407:将垃圾文件和与之对应的垃圾文件判断策略呈现给用户;S407: Presenting the junk file and the corresponding junk file judgment strategy to the user;
S408:接收用户的指令,如果用户的指令是删除垃圾文件,进入S409,如果用户的指令是不删除该文件,进入S410;S408: receiving the user's instruction, if the user's instruction is to delete the junk file, go to S409, if the user's instruction is not to delete the file, go to S410;
S409:删除用户选中的垃圾文件;S409: Delete the junk file selected by the user;
S410:将该垃圾文件改判为非垃圾文件。S410: The junk file is changed to a non-spam file.
实施例五:Embodiment 5:
一种计算机可读存储介质,存储有计算机可执行指令,所述计算机可执行指令用于执行上述实施例一或实施例二的方法。 A computer readable storage medium storing computer executable instructions for performing the method of Embodiment 1 or Embodiment 2 above.
显然,本领域的技术人员应该明白,上述本发明实施例的模块或步骤可以用通用的计算装置来实现,它们可以集中在单个的计算装置上,或者分布在多个计算装置所组成的网络上,可选地,它们可以用计算装置可执行的程序代码来实现,从而,可以将它们存储在存储介质(ROM/RAM、磁碟、光盘)中由计算装置来执行,并且在某些情况下,可以以不同于此处的顺序执行所示出或描述的步骤,或者将它们分别制作成集成电路模块,或者将它们中的多个模块或步骤制作成单个集成电路模块来实现。所以,本发明实施例不限制于任何特定的硬件和软件结合。Obviously, those skilled in the art should understand that the above modules or steps of the embodiments of the present invention can be implemented by a general computing device, which can be concentrated on a single computing device or distributed over a network composed of multiple computing devices. Alternatively, they may be implemented by program code executable by the computing device such that they may be stored in a storage medium (ROM/RAM, diskette, optical disk) by a computing device, and in some cases The steps shown or described may be performed in an order different than that herein, or they may be separately fabricated into an integrated circuit module, or a plurality of modules or steps thereof may be implemented as a single integrated circuit module. Therefore, embodiments of the invention are not limited to any particular combination of hardware and software.
工业实用性Industrial applicability
本发明实施例提供的方案具有较高的判断准确性,又因为本发明实施例采用的垃圾文件判断策略是根据由实际的存储对象的目标属性数据设置的要素设置的,可以根据选取的要素的不同而适应不同的需要,所以本发明实施例提供的方案具有很好的适应性。 The solution provided by the embodiment of the present invention has a high judgment accuracy, and the garbage file judgment strategy adopted by the embodiment of the present invention is set according to the element set by the target attribute data of the actual storage object, and may be based on the selected element. The solution provided by the embodiment of the present invention has good adaptability.

Claims (21)

  1. 一种垃圾文件识别方法,包括:A method for identifying junk files, comprising:
    根据所述文件系统中存储对象当前的目标属性数据得到该存储对象要素集中每个要素的实际值;所述要素是根据文件系统中存储对象的目标属性数据设置的;Obtaining an actual value of each element in the storage object feature set according to the current target attribute data of the storage object in the file system; the element is set according to target attribute data of the storage object in the file system;
    根据所述存储对象要素集中每个要素的实际值和预先设置的垃圾文件判断策略中对应要素的阈值匹配情况,判断该存储对象是否为垃圾文件。The storage object is determined to be a junk file according to the actual value of each element in the storage target element set and the threshold matching condition of the corresponding element in the preset junk file determination policy.
  2. 如权利要求1所述的垃圾文件识别方法,其中,所述根据所述文件系统中存储对象当前的目标属性数据得到该存储对象要素集中每个要素的实际值前还包括:The junk file identification method according to claim 1, wherein the obtaining the actual value of each element in the storage object element set according to the current target attribute data of the storage object in the file system further comprises:
    获取包含至少一个要素的要素集,根据至少一个所述要素的阈值设置所述垃圾文件判断策略。Obtaining a feature set including at least one element, and setting the junk file judgment policy according to a threshold of at least one of the elements.
  3. 如权利要求1所述的垃圾文件识别方法,其中,所述存储对象包括:文件和/或文件夹。The junk file identifying method according to claim 1, wherein said storage object comprises: a file and/or a folder.
  4. 如权利要求1所述的垃圾文件识别方法,其中,所述目标属性数据包括操作属性数据和/或大小属性数据,所述要素包括根据所述操作属性数据设置的操作属性要素和/或根据所述大小属性数据设置的大小属性要素。The junk file identifying method according to claim 1, wherein said target attribute data includes operation attribute data and/or size attribute data, said element including an operation attribute element set according to said operation attribute data, and/or The size attribute element set by the size attribute data.
  5. 如权利要求4所述的垃圾文件识别方法,其中,所述存储对象要素集包括操作属性要素时,所述阈值匹配情况包括:所述操作属性要素的实际值是否与该操作属性要素的阈值匹配;The junk file identifying method according to claim 4, wherein, when the set of storage object elements includes an operation attribute element, the threshold matching case includes: whether an actual value of the operation attribute element matches a threshold of the operation attribute element ;
    所述存储对象要素集包括大小属性要素时,所述阈值匹配情况包括:所述大小属性要素的实际值是否与该大小属性要素的阈值匹配。When the storage object element set includes a size attribute element, the threshold matching case includes whether an actual value of the size attribute element matches a threshold of the size attribute element.
  6. 如权利要求4所述的垃圾文件识别方法,其中,所述目标属性数据还包括显示状态属性数据,所述要素还包括根据所述显示状态属性数据设置的状态显示要素。The junk file identifying method according to claim 4, wherein the target attribute data further includes display state attribute data, and the element further includes a status display element set according to the display state attribute data.
  7. 如权利要求6所述的垃圾文件识别方法,其中,所述存储对象要素集包括状态显示要素时,所述阈值匹配情况包括:所述状态显示要素的实际值是否与该状态显示要素的阈值匹配。 The junk file identifying method according to claim 6, wherein when the set of storage object elements includes a status display element, the threshold matching case includes: whether an actual value of the status display element matches a threshold of the status display element .
  8. 如权利要求4所述的垃圾文件识别方法,其中,所述目标属性数据包括操作属性数据时,所述操作属性数据包括操作类型、操作时间、操作时间间隔中的至少一种,所述操作属性要素包括操作类型要素、操作时间要素和操作时间间隔要素中的至少一种;The junk file identifying method according to claim 4, wherein, when the target attribute data includes operation attribute data, the operation attribute data includes at least one of an operation type, an operation time, and an operation time interval, the operation attribute The feature includes at least one of an operation type element, an operation time element, and an operation time interval element;
    所述目标属性数据包括大小属性数据时,所述大小属性数据包括存储对象当前大小、存储对象在预设时间段内的大小变化量、和存储对象所在存储区的空间大小中的至少一种;所述大小属性要素包括存储对象当前大小要素、存储对象大小变化量要素、和存储对象所在存储区的空间大小要素中的至少一种。When the target attribute data includes the size attribute data, the size attribute data includes at least one of a current size of the storage object, a size change amount of the storage object within the preset time period, and a space size of the storage area where the storage object is located; The size attribute element includes at least one of a storage object current size element, a storage object size change amount element, and a spatial size element of a storage area in which the storage object is located.
  9. 如权利要求1~8任一项所述的垃圾文件识别方法,还包括:接收用户发送的策略修改指令,根据所述策略修改指令对所述垃圾文件判断策略进行修改。The junk file identification method according to any one of claims 1 to 8, further comprising: receiving a policy modification instruction sent by the user, and modifying the junk file judgment policy according to the policy modification instruction.
  10. 如权利要求9所述的垃圾文件识别方法,其中,所述策略修改指令包括用于对所述垃圾文件判断策略的要素进行调整的要素调整指令;所述对垃圾文件判断策略进行修改包括:根据所述要素调整指令对所述要素集中的要素进行更新,根据更新后的要素集更新所述垃圾文件判断策略;The junk file identification method according to claim 9, wherein the policy modification instruction includes an element adjustment instruction for adjusting an element of the junk file judgment policy; and the modifying the junk file judgment policy includes: The element adjustment instruction updates an element in the feature set, and updates the junk file determination policy according to the updated feature set;
    或,所述策略修改指令包括用于对所述垃圾文件判断策略的要素的阈值进行调整的要素阈值调整指令;所述对垃圾文件判断策略进行修改包括:根据所述要素调阈值整指令对对应要素的阈值进行更新,根据更新后的阈值更新所述垃圾文件判断策略。Or the policy modification instruction includes an element threshold adjustment instruction for adjusting a threshold of an element of the junk file judgment policy; and the modifying the junk file judgment policy includes: corresponding to the element tune threshold The threshold of the element is updated, and the junk file judgment policy is updated according to the updated threshold.
  11. 一种垃圾文件管理方法,包括:A garbage file management method, comprising:
    通过如权利要求1~10任一项所述的垃圾文件的识别方法识别出垃圾文件;Identifying a junk file by the method for identifying a junk file according to any one of claims 1 to 10;
    对所述垃圾文件进行管理。Manage the junk files.
  12. 如权利要求11所述的垃圾文件管理方法,其中,所述对垃圾文件进行管理包括:The junk file management method according to claim 11, wherein said managing the junk file comprises:
    将所述垃圾文件删除;Delete the junk file;
    或者将所述垃圾文件呈现给用户进行确认,根据用户的第一确认指令对 所述垃圾文件进行管理;Or presenting the junk file to the user for confirmation, according to the user's first confirmation instruction The junk file is managed;
    或者将所述垃圾文件和所述垃圾文件判断策略呈现给用户进行确认,根据用户的第二确认指令对所述垃圾文件进行管理。Or presenting the junk file and the junk file judging policy to the user for confirmation, and managing the junk file according to the second confirmation instruction of the user.
  13. 一种垃圾文件识别装置,包括:A junk file identification device comprising:
    分析模块,设置成根据所述文件系统中存储对象当前的目标属性数据得到该存储对象要素集中每个要素的实际值;所述要素是根据文件系统中存储对象的目标属性数据设置的;The analyzing module is configured to obtain an actual value of each element in the storage object element set according to the current target attribute data of the storage object in the file system; the element is set according to target attribute data of the storage object in the file system;
    判断模块,设置成根据所述存储对象要素集中每个要素的实际值和预先设置的垃圾文件判断策略中对应要素的阈值匹配情况,判断该存储对象是否为垃圾文件。The judging module is configured to determine whether the storage object is a junk file according to an actual value of each element in the storage target element set and a threshold matching condition of a corresponding element in a junk file judging policy set in advance.
  14. 如权利要求13所述的垃圾文件识别装置,还包括:The junk file identification device of claim 13 further comprising:
    策略设置模块,设置成获取包含至少一个要素的要素集,根据至少一个所述要素的阈值设置所述垃圾文件判断策略。The policy setting module is configured to acquire a feature set including at least one element, and set the junk file judgment policy according to a threshold of at least one of the elements.
  15. 如权利要求13所述的垃圾文件识别装置,其中,所述目标属性数据包括操作属性数据和/或大小属性数据,所述要素包括根据所述操作属性数据设置的操作属性要素和/或根据所述大小属性数据设置的大小属性要素。The junk file identifying apparatus according to claim 13, wherein said target attribute data includes operation attribute data and/or size attribute data, said element including an operation attribute element set according to said operation attribute data, and/or The size attribute element set by the size attribute data.
  16. 如权利要求15所述的垃圾文件识别装置,其中,所述目标属性数据还包括显示状态属性数据,所述要素还包括根据所述显示状态属性数据设置的状态显示要素。The junk file discriminating device according to claim 15, wherein said target attribute data further includes display state attribute data, and said element further includes a status display element set in accordance with said display state attribute data.
  17. 如权利要求13~16任一项所述的垃圾文件识别装置,还包括:The junk file identification device according to any one of claims 13 to 16, further comprising:
    接收模块,设置成接收用户发送的策略修改指令;a receiving module, configured to receive a policy modification instruction sent by a user;
    修改模块,设置成根据所述策略修改指令对所述垃圾文件判断策略进行修改。And modifying the module, configured to modify the junk file judgment policy according to the policy modification instruction.
  18. 如权利要求17所述的垃圾文件识别装置,其中,所述接收模块包括第一接收子模块,设置成接收要素调整指令,所述要素调整指令包括用于对所述垃圾文件判断策略的要素进行调整的策略修改指令;所述修改模块包括第一修改子模块,设置成根据所述要素调整指令对所述要素集中的要素进行更新,根据更新后的要素集更新所述垃圾文件判断策略; The junk file identifying apparatus according to claim 17, wherein said receiving module comprises a first receiving submodule configured to receive an element adjustment instruction, said element adjustment instruction including an element for determining said junk file judging policy The modified policy modification instruction includes: the first modification submodule, configured to update the elements in the feature set according to the element adjustment instruction, and update the junk file determination policy according to the updated feature set;
    或,所述接收模块包括第二接收子模块,设置成接收要素阈值调整指令,所述要素阈值调整指令包括用于对所述垃圾文件判断策略的要素的阈值进行调整的策略修改指令;所述修改模块包括第二修改子模块,设置成根据所述要素调阈值整指令对对应要素的阈值进行更新,根据更新后的阈值更新所述垃圾文件判断策略。Or the receiving module includes a second receiving submodule configured to receive an element threshold adjustment instruction, where the element threshold adjustment instruction includes a policy modification instruction for adjusting a threshold of an element of the junk file determination policy; The modification module includes a second modification submodule, configured to update the threshold of the corresponding element according to the element adjustment threshold instruction, and update the junk file determination policy according to the updated threshold.
  19. 一种垃圾文件管理装置,包括:A junk file management device, comprising:
    如权利要求13~18任一项所述的垃圾文件识别装置,设置成对终端文件系统中的垃圾文件进行识别;The junk file identifying apparatus according to any one of claims 13 to 18, configured to identify a junk file in the terminal file system;
    管理模块,设置成对所述垃圾文件进行管理。A management module configured to manage the junk file.
  20. 如权利要求19所述的垃圾文件管理装置,其中,所述管理模块包括管理子模块:The junk file management apparatus according to claim 19, wherein said management module comprises a management sub-module:
    设置成将所述垃圾文件删除;Set to delete the junk file;
    或者设置成将所述垃圾文件呈现给用户进行确认,根据用户的第一确认指令对所述垃圾文件进行管理;Or setting to present the junk file to the user for confirmation, and managing the junk file according to the first confirmation instruction of the user;
    或者设置成将所述垃圾文件和所述垃圾文件判断策略呈现给用户进行确认,根据用户的第二确认指令对所述垃圾文件进行管理。Or setting to present the junk file and the junk file judging policy to the user for confirmation, and managing the junk file according to the second confirmation instruction of the user.
  21. 一种终端,包括如权利要求13~18任一项所述的垃圾文件识别装置和如权利要求19或20所述的垃圾文件管理装置,所述垃圾文件识别装置包含在所述垃圾文件管理装置中;所述垃圾文件识别装置设置成对终端文件系统中的垃圾文件进行识别;所述垃圾文件管理装置设置成对所述垃圾文件识别装置识别出的垃圾文件进行管理。 A terminal comprising the junk file identification device according to any one of claims 13 to 18 and the junk file management device according to claim 19 or 20, wherein the junk file identification device is included in the junk file management device The garbage file identification device is configured to identify the junk file in the terminal file system; the junk file management device is configured to manage the junk file identified by the junk file identification device.
PCT/CN2016/083174 2015-11-18 2016-05-24 Junk file identification and management method, identification device, management device and terminal WO2016197814A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201510807437.0A CN106708912B (en) 2015-11-18 2015-11-18 Junk file identification and management method, identification device, management device and terminal
CN201510807437.0 2015-11-18

Publications (1)

Publication Number Publication Date
WO2016197814A1 true WO2016197814A1 (en) 2016-12-15

Family

ID=57502878

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2016/083174 WO2016197814A1 (en) 2015-11-18 2016-05-24 Junk file identification and management method, identification device, management device and terminal

Country Status (2)

Country Link
CN (1) CN106708912B (en)
WO (1) WO2016197814A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111263936A (en) * 2017-08-22 2020-06-09 深圳传音通讯有限公司 Electronic terminal and junk file processing method thereof

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108021630B (en) * 2017-11-21 2021-03-30 深圳市雷鸟网络传媒有限公司 Junk file cleaning method, intelligent terminal and computer readable storage medium
CN108255930B (en) * 2017-11-30 2020-06-05 维沃移动通信有限公司 Data cleaning method of mobile terminal and mobile terminal
CN109656875B (en) * 2018-12-05 2023-05-16 广东小天才科技有限公司 Classification management method and device for storage space, terminal and storage medium
CN111177075B (en) * 2019-12-26 2022-04-22 浪潮电子信息产业股份有限公司 Junk data identification method and system, electronic equipment and storage medium
CN112131189A (en) * 2020-09-29 2020-12-25 珠海海鸟科技有限公司 Method and device for cleaning junk files and electronic equipment

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101464904A (en) * 2009-01-09 2009-06-24 华为技术有限公司 File identification method and device
CN103530424A (en) * 2013-10-31 2014-01-22 北京奇虎科技有限公司 Useless file detection method and device
CN103631934A (en) * 2013-12-06 2014-03-12 贝壳网际(北京)安全技术有限公司 Garbage-file detecting method and device

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2012167392A2 (en) * 2011-06-06 2012-12-13 ETH Zürich Method and devices for secure deletion of data in a log structured file system

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101464904A (en) * 2009-01-09 2009-06-24 华为技术有限公司 File identification method and device
CN103530424A (en) * 2013-10-31 2014-01-22 北京奇虎科技有限公司 Useless file detection method and device
CN103631934A (en) * 2013-12-06 2014-03-12 贝壳网际(北京)安全技术有限公司 Garbage-file detecting method and device

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111263936A (en) * 2017-08-22 2020-06-09 深圳传音通讯有限公司 Electronic terminal and junk file processing method thereof

Also Published As

Publication number Publication date
CN106708912B (en) 2021-06-25
CN106708912A (en) 2017-05-24

Similar Documents

Publication Publication Date Title
WO2016197814A1 (en) Junk file identification and management method, identification device, management device and terminal
US10275355B2 (en) Method and apparatus for cleaning files in a mobile terminal and associated mobile terminal
US9607278B2 (en) Systems and methods for supporting social productivity using relevancy scoring
US20180181725A1 (en) User-generated content permissions status analysis system and method
US9825890B2 (en) Systems and methods for supporting social productivity using thresholding
US9813450B1 (en) Metadata-based verification of artifact quality policy compliance
US9817997B2 (en) User-generated content permissions status analysis system and method
CN106031127B (en) Method and apparatus for management of applications
CN105700819B (en) Method and system for network data storage
US20130006996A1 (en) Clustering E-Mails Using Collaborative Information
US20190188804A1 (en) Platform for automated social media regulatory compliance monitoring
CN103150079A (en) Application icon management method and device based on Firefox OS (Operation System) platform
CN108108127A (en) A kind of file reading and system
CN108647935B (en) Financial voucher generation rule updating method and device
US10021050B2 (en) Secure conversation and document binder
US11275795B2 (en) System and method for in-place record content management
WO2016110203A1 (en) File path storing and local file accessing method and device
CN107835986A (en) The data manipulation method and electronic equipment of a kind of electronic equipment
CN106815232A (en) Catalog management method, apparatus and system
WO2023226461A1 (en) Multi-domain data fusion method and device, and storage medium
US9183388B2 (en) Injustice detecting system, injustice detecting device and injustice detecting method
JP5845961B2 (en) Information processing apparatus and information processing program
CN112632266B (en) Data writing method and device, computer equipment and readable storage medium
JP6651915B2 (en) Information processing apparatus and information processing program
CN108073712B (en) Method and device for deleting main data in information system and computer equipment

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: 16806712

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: 16806712

Country of ref document: EP

Kind code of ref document: A1