CN112069140A - Method, device, equipment and medium for compressing and decompressing data - Google Patents
Method, device, equipment and medium for compressing and decompressing data Download PDFInfo
- Publication number
- CN112069140A CN112069140A CN202010855878.9A CN202010855878A CN112069140A CN 112069140 A CN112069140 A CN 112069140A CN 202010855878 A CN202010855878 A CN 202010855878A CN 112069140 A CN112069140 A CN 112069140A
- Authority
- CN
- China
- Prior art keywords
- application
- data
- application icon
- character string
- compressed data
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 77
- 230000004044 response Effects 0.000 claims description 23
- 230000006837 decompression Effects 0.000 claims description 22
- 238000009434 installation Methods 0.000 claims description 18
- 238000007906 compression Methods 0.000 claims description 17
- 230000006835 compression Effects 0.000 claims description 16
- 238000012790 confirmation Methods 0.000 claims description 12
- 238000011084 recovery Methods 0.000 claims description 8
- 101100134058 Caenorhabditis elegans nth-1 gene Proteins 0.000 claims description 3
- 230000008569 process Effects 0.000 abstract description 23
- 238000010586 diagram Methods 0.000 description 27
- 238000013144 data compression Methods 0.000 description 9
- 238000004590 computer program Methods 0.000 description 7
- 230000006870 function Effects 0.000 description 6
- 238000012545 processing Methods 0.000 description 6
- 230000008859 change Effects 0.000 description 5
- 230000006399 behavior Effects 0.000 description 3
- 238000012986 modification Methods 0.000 description 3
- 230000004048 modification Effects 0.000 description 3
- 238000012217 deletion Methods 0.000 description 2
- 230000037430 deletion Effects 0.000 description 2
- 238000005516 engineering process Methods 0.000 description 2
- 239000000725 suspension Substances 0.000 description 2
- 238000011161 development Methods 0.000 description 1
- 238000007726 management method Methods 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/10—File systems; File servers
- G06F16/17—Details of further file system functions
- G06F16/174—Redundancy elimination performed by the file system
- G06F16/1744—Redundancy elimination performed by the file system using compression, e.g. sparse files
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/01—Input arrangements or combined input and output arrangements for interaction between user and computer
- G06F3/048—Interaction techniques based on graphical user interfaces [GUI]
- G06F3/0481—Interaction techniques based on graphical user interfaces [GUI] based on specific properties of the displayed interaction object or a metaphor-based environment, e.g. interaction with desktop elements like windows or icons, or assisted by a cursor's changing behaviour or appearance
- G06F3/04817—Interaction techniques based on graphical user interfaces [GUI] based on specific properties of the displayed interaction object or a metaphor-based environment, e.g. interaction with desktop elements like windows or icons, or assisted by a cursor's changing behaviour or appearance using icons
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/01—Input arrangements or combined input and output arrangements for interaction between user and computer
- G06F3/048—Interaction techniques based on graphical user interfaces [GUI]
- G06F3/0484—Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
- G06F3/04847—Interaction techniques to control parameter settings, e.g. interaction with sliders or dials
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/01—Input arrangements or combined input and output arrangements for interaction between user and computer
- G06F3/048—Interaction techniques based on graphical user interfaces [GUI]
- G06F3/0484—Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
- G06F3/0485—Scrolling or panning
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Human Computer Interaction (AREA)
- Data Mining & Analysis (AREA)
- Databases & Information Systems (AREA)
- User Interface Of Digital Computer (AREA)
Abstract
The application relates to the technical field of computers, and provides a method, a device, equipment and a medium for compressing and decompressing data, which are used for solving the problem of complex operation in the process of compressing data. The method comprises the following steps: and responding to a first operation of moving the application icon to the target file frame, acquiring application data associated with the application icon, compressing the application data to obtain compressed data, and displaying the application icon in the target file frame. According to the method, a user does not need to search data to be compressed from a large amount of data, the application icon is directly moved to the target file frame, the application data related to the application icon can be obtained, the application data are compressed, the operation of the user can be simplified relatively, the storage space of the terminal can be saved, and the terminal storage occupied by the application data is reduced.
Description
Technical Field
The present application relates to the field of computer technologies, and in particular, to a method, an apparatus, a device, and a medium for compressing and decompressing data.
Background
With the continuous development of computer technology, terminals have become essential things in people's lives. In order to meet the requirements of work entertainment, a user can install a large number of applications in the terminal, but the storage space of the terminal is limited, and the user can install too many applications in the terminal, so that the user can occupy too much storage space of the terminal, and in addition, the user can use the applications for too long time, and the applications can generate a large amount of user data.
At present, if data in the terminals are compressed, a user needs to search the data to be compressed from a large amount of data, then compression software in the terminal is selected, and the terminal compresses according to the selected data.
Disclosure of Invention
The embodiment of the application provides a method, a device, equipment and a medium for compressing and decompressing data, which are used for solving the problem of complex operation in the process of compressing data.
In a first aspect, a method for compressing data is provided, including:
responding to a first operation of moving an application icon to a target file frame, and acquiring application data associated with the application icon; the application data comprises one or two of installation data corresponding to the application or use data of the application;
and compressing the application data to obtain compressed data, and displaying the application icon in the target file frame.
In the embodiment of the application, when a user needs to compress application data of an application, the user only needs to move the application icon of the application to the target file frame, and then the terminal can obtain the application data associated with the application icon and compress the application data. In addition, according to the application, the application data of the application are compressed, so that the storage space of the terminal can be saved, and the terminal storage occupied by the application data is reduced. Moreover, the application data is compressed and the icons are managed in a centralized manner. And the application icon is displayed in the target file frame, so that the user can visually check the compressed application data.
In one possible embodiment, in response to a first operation of moving an application icon to a target file frame, acquiring application data associated with the application icon includes:
responding to the first operation, and displaying a first prompt interface; the first prompt interface is used for indicating whether to confirm whether to compress the application data corresponding to the application icon;
and responding to the confirmation operation performed on the first prompt interface, and acquiring the application data associated with the application icon.
In this embodiment, a first operation of the user is detected, a first prompt interface is displayed, the user is instructed to confirm whether to compress application data corresponding to the application icon, and after the user confirms compression, application data associated with the application icon is acquired, so that the situation that the user mistakenly moves the application icon to compress an application that does not need to be compressed is avoided.
In a possible embodiment, the compressing the application data to obtain compressed data includes:
compressing each file in the plurality of files to obtain a plurality of compressed data packets;
and compressing the plurality of compressed data packets to obtain compressed data.
In this embodiment, each file is compressed to obtain a plurality of compressed data packets, and then the plurality of compressed data packets are compressed to obtain final compressed data, and the accuracy of the compression result is ensured by a layer-by-layer compression method.
In a possible embodiment, compressing the plurality of compressed data packets to obtain compressed data includes:
reading the current character string of each compressed data packet;
if the current character string is the character string read for the first time in each compressed data packet, encoding the current character string according to an identifier; the identifier is used for indicating that the current character string is a character string read for the first time, and is obtained according to the length of the current character string;
if the current character string is the character string read for the Nth time in each compressed data packet, encoding the current character string by using a finger-back distance and a repetition length to obtain compressed data; and N is greater than or equal to 2, the pointing back distance is the distance offset between the current character string and the character string read for the (N-1) th time, and the repetition length is the length of the current character string.
In this embodiment, the current character string is divided into the character string read for the first time and the character string read for the nth time, encoding is performed separately, the character string read for the nth time is processed by using the finger-back distance and the repetition length, and subsequent decompression processing can be facilitated. Moreover, the character string is processed in the compression process instead of processing a single character, so that the compression efficiency can be improved.
In a second aspect, a method for decompressing data is provided, including:
in response to a second operation of moving a first application icon out of a target file frame, acquiring compressed application data associated with the first application icon; wherein the compressed application data comprises one or both of installation data or usage data for an application;
decompressing the compressed application data to obtain application data, and deleting the first application icon in the target file frame.
In the embodiment, the application icon is moved out of the target file frame, the compressed data associated with the application icon is obtained and decompressed, and the application data is obtained, so that a user does not need to search data to be decompressed from a large amount of compressed data, and can realize decompression of the compressed data only by moving the corresponding application icon, and the operation of the user is relatively simplified. And the user data before compression can not be lost, and the user can normally run the application without resetting and re-networking for downloading the application, so that the flow and the waiting time can be relatively saved.
In one possible embodiment, in response to a second operation of moving a first application icon out of a target file box, obtaining compressed data associated with the first application icon comprises:
responding to the second operation, and displaying a second prompt interface; the second prompt interface is used for indicating whether to recover application data corresponding to the application icon;
and responding to the recovery operation performed on the second prompt interface, and acquiring the compressed data associated with the application icon.
In this embodiment, a second operation of the user is detected, a second prompt interface is displayed, the user is instructed to confirm whether to recover application data corresponding to the application icon, and compressed data associated with the application icon is acquired only after the user confirms recovery, so that the situation that the user mistakenly moves the application icon to decompress the application that does not need decompression is avoided.
In a possible embodiment, after displaying the second prompt interface in response to the second operation, the method includes:
in response to the confirmation that the operation is not recovered, deleting the application icon and the compressed data associated with the application icon;
in this embodiment, by displaying the second prompt interface, it is detected that the user does not resume the confirmation, that is, after the user confirms that the user does not resume the confirmation, the unnecessary applications, including the application icon of the application and the compressed data associated with the application icon, are deleted, so that the terminal storage occupied by the compressed data can be reduced, and the storage space of the terminal is further saved.
In one possible embodiment, the target file box includes the first application icon and the second application icon, and the method further includes one or both of:
in response to a moving operation of the first application icon or the second application icon, detecting that a distance between the first application icon and the second application icon in the target file box is smaller than or equal to a first threshold value, and generating a subfile box in the target file box, wherein the subfile box comprises the first application icon and the second application icon; or the like, or, alternatively,
responding to the movement operation of the first application icon or the second application icon, detecting that the distance between the first application icon and the second application icon in the target file frame is smaller than or equal to a second threshold value, and moving the position of the first application icon to the position of the second application icon; wherein the first threshold is less than the second threshold.
In this embodiment, the user can visually check the compressed icons of the application data through the target file frame, and the user can also perform centralized management on the application icons, and place the related application icons in the same subfile frame according to the preference of the user, or exchange the positions of any two application icons, thereby satisfying various requirements of the user.
In a possible embodiment, the compressing the compressed data by compressing a plurality of compressed data packets, and decompressing the compressed data to obtain the application data includes:
decompressing the compressed data to obtain a plurality of compressed data packets;
and decompressing the plurality of compressed data packets to obtain application data.
In this embodiment, when decompressing the compressed data, a plurality of compressed data packets may be obtained first, and then the plurality of compressed data packets are decompressed respectively to obtain the application data, and the accuracy of the decompression result is ensured by a layer-by-layer decompression method.
In a possible embodiment, decompressing the plurality of compressed data packets to obtain the application data includes:
reading the current coding value of each compressed data packet;
if the current coded value contains an identifier, determining that a character string corresponding to the current coded value is a character string read for the first time, and decoding the current coded value according to the identifier;
if the current coding value contains a finger-back distance and a repetition length, determining that a character string corresponding to the current coding value is an Nth read character string, finding the character string read for the Nth-1 th time according to the finger-back distance, and obtaining the character string corresponding to the current coding value according to the repetition length to obtain the application data; and N is greater than or equal to 2, the pointing back distance is a distance offset between the character string corresponding to the current coded value and the character string read for the (N-1) th time, and the repetition length is the length of the character string corresponding to the current coded value.
In this embodiment, the data packet is decompressed through the identifier of the current coding value in the data packet, the return distance, the repetition length, and the like, so as to obtain the application data.
In a third aspect, a data compression apparatus is provided, including:
an acquisition module: the method comprises the steps of responding to a first operation of moving an application icon to a target file frame, and acquiring application data related to the application icon; the application data comprises one or two of installation data corresponding to the application or use data of the application;
a compression module: and the application icon display module is used for compressing the application data to obtain compressed data and displaying the application icon in the target file frame.
In a possible embodiment, the obtaining module is configured to:
responding to the first operation, and displaying a first prompt interface; the first prompt interface is used for indicating whether to confirm whether to compress the application data corresponding to the application icon;
and responding to the confirmation operation performed on the first prompt interface, and acquiring the application data associated with the application icon.
In one possible embodiment, the compression module is configured to:
compressing each file in the plurality of files to obtain a plurality of compressed data packets;
and compressing the plurality of compressed data packets to obtain compressed data.
In one possible embodiment, the compression module is configured to:
reading the current character string in each compressed data packet;
if the current character string is the character string read for the first time in each compressed data packet, encoding the current character string according to an identifier; the identifier is used for indicating that the current character string is a character string read for the first time, and is obtained according to the length of the current character string;
if the current character string is the character string read for the Nth time in each compressed data packet, encoding the current character string by using a finger-back distance and a repetition length to obtain compressed data; and N is greater than or equal to 2, the pointing back distance is the distance offset between the current character string and the character string read for the (N-1) th time, and the repetition length is the length of the current character string.
In a fourth aspect, a data decompression apparatus includes:
an acquisition module: the second operation for responding to the first application icon being moved out of the target file frame is used for acquiring compressed data associated with the first application icon; the compressed data comprises one or two of installation data corresponding to the compressed application or use data of the compressed application;
a decompression module: the application icon deleting module is used for decompressing the compressed data, obtaining application data and deleting the first application icon in the target file frame.
In a possible embodiment, the obtaining module is configured to:
responding to the second operation, and displaying a second prompt interface; the second prompt interface is used for indicating whether to recover application data corresponding to the application icon;
and responding to the recovery operation performed on the second prompt interface, and acquiring the compressed data associated with the application icon.
In a possible embodiment, the obtaining module is configured to:
and in response to the confirmation that the operation is not recovered in the second prompt interface, deleting the application icon and the compressed data associated with the application icon.
In a possible embodiment, the target file box includes the first application icon and a second application icon, and the obtaining module is configured to:
in response to the moving operation of the first application icon or the second application icon, detecting that the distance between the first application icon and the second application icon in the target file box is smaller than or equal to a first threshold value, and creating a subfile box in the target file box, wherein the subfile box comprises the first application icon and the second application icon; or the like, or, alternatively,
responding to the movement operation of the first application icon or the second application icon, detecting that the distance between the first application icon and the second application icon in the target file frame is smaller than or equal to a second threshold value, and moving the position of the first application icon to the position of the second application icon; wherein the first threshold is less than the second threshold.
In one possible embodiment, the decompression module is configured to:
decompressing the compressed data to obtain a plurality of compressed data packets;
and decompressing the plurality of compressed data packets to obtain application data.
In one possible embodiment, the decompression module is configured to:
reading the current coding value of each compressed data packet;
if the current coded value contains an identifier, determining that a character string corresponding to the current coded value is a character string read for the first time, and decoding the current coded value according to the identifier;
if the current coding value contains a finger-back distance and a repetition length, determining that a character string corresponding to the current coding value is an Nth read character string, finding the character string read for the Nth-1 th time according to the finger-back distance, and obtaining the character string corresponding to the current coding value according to the repetition length to obtain the application data; and N is greater than or equal to 2, the pointing back distance is a distance offset between the character string corresponding to the current coded value and the character string read for the (N-1) th time, and the repetition length is the length of the character string corresponding to the current coded value.
In a fifth aspect, there is provided a computer device comprising:
at least one processor, and
a memory communicatively coupled to the at least one processor;
wherein the memory stores instructions executable by the at least one processor, the at least one processor implementing the method of any one of the first or second aspects by executing the instructions stored by the memory.
In a sixth aspect, there is provided a computer readable storage medium having stored thereon computer instructions which, when run on a computer, cause the computer to perform the method of any of the first or second aspects.
Drawings
Fig. 1 is a schematic view of an application scenario of a data compression and decompression method according to an embodiment of the present application;
fig. 2 is a flowchart of a data compression method according to an embodiment of the present application;
fig. 3 is an exemplary diagram of an interface change of a terminal in a process of creating a target file box according to an embodiment of the present application;
fig. 4 is a diagram illustrating an example of interface changes of a terminal in a data compression process according to an embodiment of the present application;
fig. 5 is a flowchart of a data decompression method according to an embodiment of the present application;
fig. 6 is an exemplary diagram of an interface change of a terminal in an application shift process of a target file box according to an embodiment of the present application;
fig. 7 is a flowchart of a data decompression method according to an embodiment of the present application;
fig. 8 is a diagram illustrating an example of interface changes of a terminal in a process of decompressing data according to an embodiment of the present application;
fig. 9 is a schematic structural diagram of an apparatus for compressing data according to an embodiment of the present disclosure;
fig. 10 is a schematic structural diagram of an apparatus for decompressing data according to an embodiment of the present application;
fig. 11 is a schematic structural diagram of a computer device according to an embodiment of the present application.
Detailed Description
In order to better understand the technical solutions provided by the embodiments of the present application, the following detailed description is made with reference to the drawings and specific embodiments.
Nowadays, various applications related to life entertainment emerge in large quantities, and as the functions of the applications are more and more, the storage space occupied by the applications is larger and larger, and in order to meet the needs of life entertainment, a large number of applications are often installed on a terminal by a user, and application data occupy excessive storage space of the terminal, and in addition, if the user uses a certain application for a long time, the application also generates a large amount of user data.
At present, if data in the terminals are to be compressed, a user needs to search data to be compressed from a large amount of data, then compression software in the terminal is selected, and the terminal compresses the data according to the data selected by the user.
In view of this, an embodiment of the present application provides a method for compressing and decompressing data, and the following introduces an application scenario related to the embodiment of the present application.
The method for compressing and decompressing data in the embodiment of the present application may be executed by a terminal, where the terminal may be, for example, a mobile phone, a computer, and the like, and specifically may be implemented by a target application in the terminal, where the target application is, for example, a widget in the terminal, or a client pre-installed in the terminal, or a sub-application embedded in a third-party application in the terminal. Unlike the application, the gadget can realize the process of compressing and decompressing data without the support of a background server.
Referring to fig. 1, an application scenario diagram of a data compression and decompression method is shown, or may be understood as a structural example diagram of a terminal, where the terminal 110 includes a plurality of applications and an applet 120, and the plurality of applications include a first application 130 and a second application 140.
When the user wants to use the widget 120, the user may click on the target file box in the widget 120, and the terminal 110 displays the target file box on the main interface. Of course, the terminal 110 may create a plurality of object file boxes on one main interface of the terminal 110 or create one object file box on each main interface, respectively, in response to an operation by the user. Alternatively, the object file frame may be automatically generated by the widget 120, and the object file frame is displayed at a preset position of the terminal 110 without any operation by the user.
When a user needs to compress the application data of the first application 130, the application icon of the first application 130 may be moved to the target file frame, and when the terminal 110 detects that a new application icon exists in the target file frame, the application data corresponding to the application icon is obtained and compressed. The process of how to compress the application data will be described below.
When the user needs to use the first application 130, the application icon of the first application 130 may be moved out of the target file frame, and when the terminal 110 detects that a certain application icon is absent in the target file frame, the terminal acquires the compressed data corresponding to the application icon and decompresses the compressed data, thereby acquiring the application data and recovering the normal use of the application. The process of how to decompress the data will be described below.
Based on the application scenario discussed in fig. 1, a method for compressing data according to an embodiment of the present application is described below.
Referring to fig. 2, a flow chart of a data compression method is shown, the method including:
s201: and displaying the target file frame.
A plurality of application icons are displayed in the target file frame, so that a user can visually see the compressed application. One or more object file frames may be displayed on a main interface of the terminal 110, and each object file frame may also be displayed on each main interface. Of course, the target file box may be displayed at other positions of the terminal 110. The following describes an example of a manner in which the target file box is created and displayed:
firstly, the method comprises the following steps: the terminal 110 displays an object file box in response to a user's object manipulation with respect to the widget 120.
Specifically, the user presses the main interface of the terminal 110 for a long time, and the terminal 110 displays a setting interface including the widget 120 in response to the user's operation. The widget 120 may be displayed on a status bar. The widget 120 includes a target file frame corresponding to a target application in the terminal, the user drags or clicks the target file frame, and the terminal 110 displays the target file frame on the main interface in response to the dragging or clicking operation of the target file frame.
II, secondly: the terminal 110 is pre-installed with a target application, a user performs a target operation on the target application, and the terminal 110 creates a target file frame corresponding to the target application in response to the target operation. The target operation is, for example, a long-press operation of an icon of the target application.
Thirdly, the method comprises the following steps: the terminal 110 creates a target file frame in advance and displays the target file frame at a preset position of the main interface. For example, the application icon of the target application preinstalled in the terminal 110 is the target file box.
For example, fig. 3 shows a variation example diagram of a terminal interface in the process of creating a target file frame, wherein (1) in fig. 3 shows an example diagram of a setting interface on which a widget 120 is displayed, wherein a dotted arrow pointed to a desktop by the widget 120 indicates that a user drags or clicks the target file frame in the widget 120, the terminal 110 shows an example diagram of the target file frame as shown in (2) in fig. 3, and in the interface shown in (2) in fig. 3, the target file frame is displayed in a main interface of the terminal 110.
S202: and responding to a first operation of moving the application icon to the target file frame, and displaying a first prompt interface.
The application associated with the application icon is different from the application associated with the target file box. As discussed above, the target file frame is a target application corresponding to the compressed data, and the application icon refers to an icon of an application that the user wants to compress. When the user wants to compress the application data associated with the application icon, the user may drag or click the application icon, and the terminal 110 detects a first operation of the user moving the application icon to the target file box, such as a sliding operation, a dragging operation, and the like, and displays a first prompt interface. The first prompt interface is used for indicating a user to confirm whether to compress the application data corresponding to the application icon. The first prompt interface comprises a first key and a second key, the first key is used for confirming that application data corresponding to the application icon is compressed, and the second key is used for confirming that application data corresponding to the application icon is not compressed. The key may be an entity operation key, a touch key, a suspension key, or other keys, and is not limited in particular.
For example, fig. 4 shows an exemplary diagram of interface changes of a terminal during data compression, and (1) in fig. 4 shows an exemplary diagram of a main interface before data compression, which displays a first application 130, a second application 140, and a target file box. The dotted arrow pointing to the target file frame by the first application indicates that the user moves the icon of the first application 130 into the target file frame, the terminal 110 displays an exemplary diagram of the first interface as shown in (2) in fig. 4, where a "yes" icon displayed in the first interface represents a first key, a "no" icon represents a second key, when the user clicks the "yes" key, the user confirms that the application data corresponding to the application icon is compressed, and when the user clicks the "no" key, the user does not compress the application data corresponding to the application icon.
S203: and responding to the confirmation operation in the first prompt interface, and acquiring the application data associated with the application icon.
When the terminal 110 detects that the user clicks the first key, which is equivalent to the user performing an operation of confirming that the application data associated with the application icon is compressed, the terminal 110 acquires the application data associated with the application icon. For example, the terminal 110 prestores a corresponding relationship between each application icon and a storage address of the application data, and after the terminal 110 determines an application icon that needs to be compressed by a user, the terminal directly indexes the corresponding storage address according to the application icon. Of course, there may be one or more storage addresses corresponding to the application data of an application, and when there are multiple storage addresses, the terminal 110 obtains the corresponding data from the storage addresses respectively.
The application data refers to various layers of data related to the application, and specifically includes data of the application layer itself, for example, installation data of the application, and data of the user layer, for example, one or two of usage data of the application, the installation data of the application includes data generated in the process of installing the application, the installation data may also include an installation package of the application, and the usage data of the application includes personal account information of the user in the application, behavior data of the user is recorded, cache data generated in the process of using the application, and the like.
Data generated during the installation of the application, such as registration data of the application, a link of an application icon, and the like. The personal account information includes a login account, a login password, and the like. And recording behavior data of the user, for example, data related to historical operation behavior of the user in the application, such as web page addresses accessed by the user through the history of the application, and the like. The user uses the cached data generated during the application process, such as chat records, transmitted pictures, files, and the like.
When a user compresses an application, the user does not generally need to use the application, but does not exclude that the application still runs in the background, but the user wants to compress the application, at this time, the terminal 110 may forcibly close the application, and after forcibly closing the application, obtain application data of the application.
Certainly, the application data of a certain application cannot be compressed due to the permission problem, and then the terminal 110 may only obtain the data in the permission corresponding to the application to compress the data in the permission.
S204: and compressing the application data to obtain compressed data, and displaying the application icon in the target file frame.
As discussed above, the application data includes multiple levels of data, and the data corresponding to each level may be composed of multiple files, or the multiple levels of data of the application data may be composed of multiple files. For example, the installation data of the application may be composed of a plurality of files such as a registry of the application, a link of an application icon, and the like, or the installation data of the user is one file and the usage data of the user is one file. Since each file may have different format, during the compression process, the format corresponding to each file is stored so as to be decompressed and restored to the file type before compression.
When compressing the application data, the terminal 110 may compress each file included in the application data to obtain a plurality of compressed data packets, and then compress the plurality of compressed data packets to obtain final compressed data. The compression process is the same whether compressing a file or compressing a data packet, and the following description will be given by taking compressing a file as an example:
the current string is read. The current character string refers to a character string that the terminal 110 needs to compress currently, and any character that needs to be processed can be regarded as the current character string.
If the current character string is the character string read for the first time, and the character string read for the first time means that the current character string does not appear in the process of reading the file before, the terminal 110 encodes the current character string by using an identifier, wherein the identifier is used for indicating that the current character string is the character string read for the first time, and the identifier is related to the length of the current character string.
If the current character string is the character string read for the nth time, N is an integer greater than or equal to 2, and the character string read for the nth time indicates that the current character string appears in the process of reading the file before, the terminal 110 encodes the current character string by using a finger-back distance and a repetition length to obtain compressed data, wherein the finger-back distance is a distance offset between the current character string and the character string read for the (N-1) th time, and the repetition length is the length of the current character string.
For example, when a character string in a certain file to be compressed is "AABAABAAB", and "AAB" is read, the "AAB" does not appear in the previous process of reading the file, and the "AAB" is determined to be the character string read for the first time, and the encoding result of the "AAB" is: "(03) h, AAB", etc., wherein (03) h is an identifier. When "aabab" is processed, it is found that "AAB" appears during the previous reading of the document, the length of "aabab" is 6, so the repetition length is 6, the distance between the first character "a" in "aabab" and the first character "a" in "AAB" appearing before is 3, so the finger-back distance is 3, and "aabab" is represented by "(03) h, (06) h", according to the finger-back distance and the repetition length, so the encoding result of the character string "aababaab": "(03) h, AAB, ((03) h, (06) h)".
In a possible embodiment, it is determined whether the current character string is the character string read for the nth time, and character comparison may be performed one by one in a sliding window manner.
In a possible embodiment, an lzo (lempel Ziv obeshumer) algorithm is adopted in the data compression process, the first read character string is stored in a hash table, the first read character string and the position of the first read character string are stored in the hash table, when the current character string is read each time, whether the current character string is the nth read character string is judged according to whether hash collision occurs, and the hash collision indicates that the values obtained after hash operation of different character strings are the same. An example of the process by which the LZO algorithm compresses a string is as follows:
and reading the current character string, and carrying out Hash operation on the current character string.
And if the first hash operation does not generate hash collision, determining that the current character string is the character string read for the Nth time, and encoding the current character string by using the back pointing distance and the repetition length.
And if the first hash operation generates hash collision, performing the second hash operation, if the second hash operation does not generate collision, determining the current character string as the character string read for the Nth time, and encoding the current character string by using the finger-back distance and the repetition length.
And if the second hash operation still generates hash conflicts, determining the current character string as the character string read for the first time, encoding the current character string by using the identifier, writing the current character string into the hash table, and expanding the dictionary to reduce the time for searching the longest matching string each time, wherein the process for searching the longest matching string is the process for searching the character string read for the Nth time.
For example, when the character string "AABAABAAB" to be processed is read as "AAB", it is a new character string, and after the hash operation, the obtained position is stored in the hash table, and "AAB" is encoded with an identifier, that is, "(03) h, AAB". When the AABAAB is read again, determining the AABAAB as a character string read for the Nth time through the first hash operation if no hash collision is generated, namely repeating the character string with the previous character string, and coding the AABAAB by using a finger-back distance and a repetition length, namely, ((03) h, (06) h); if hash collision is generated, performing hash operation for the second time, if no collision is generated in the hash operation for the second time, determining that the AABAAB is the character string read for the Nth time, and encoding the current character string by using the finger-back distance and the repetition length, namely, ((03) h, (06) h); and if the hash collision is still generated in the second hash operation, determining the AABAAB as the character string read for the first time, encoding the current character string by using the identifier, writing the AABAAB into the hash table, and expanding the dictionary.
For example, with continued reference to fig. 4, after the user clicks the "yes" button in (2) of fig. 4, the terminal 110 displays an example of an interface of the terminal after the compression is completed as in (3) of fig. 4, and in the interface shown in (3) of fig. 4, an application icon of the first application 130 that has been compressed is displayed in the target file box.
As an embodiment, S202 in fig. 2 is an optional step.
As an embodiment, after compressing the application data corresponding to the application icon, or detecting that the user moves the application icon into the target file frame, the terminal 110 deletes the application icon that was previously and independently displayed in the terminal 110, that is, the application icon is displayed in the target file frame and is not displayed elsewhere.
After repeating the above steps for multiple times, multiple application icons are stored in the target file frame, and the terminal 110 may adjust or further sort the application icons according to the relevant operations of the user on the icons.
For example, the target file frame includes a first application icon and a second application icon, when the user wants to sort the first application icon and the second application icon, the user may move the first application icon, and the terminal 110 detects that the distance between the first application icon and the second application icon in the target file frame is less than or equal to a first threshold, creates a subfile frame in the target file frame, where the subfile frame includes the first application icon and the second application icon.
For example, fig. 5 shows an example of interface change of a terminal during application classification of a target file frame, and (1) in fig. 5 shows an example of an interface before application classification of the target file frame, in which a first application icon and a second application icon are displayed. The dotted arrow pointing to the second application from the first application indicates that the user moves the first application icon so that the distance between the first application icon and the second application icon is less than or equal to the first threshold, and the terminal 110 displays an example of the interface after application classification of the target file box shown as (2) in fig. 5, in the interface shown as (2) in fig. 5, the target file box displays a subfile box in which the first application icon and the second application icon are displayed.
Or, when the user wants to move the second application icon to the position of the first application icon, the user may move the first application icon, and the terminal 110 detects that the distance between the first application icon and the second application icon in the target file frame is less than or equal to a second threshold, and then exchanges the position of the second application icon with the position of the first application icon, where the first threshold is less than the second threshold.
For example, fig. 6 shows an example of an interface change of a terminal during application shift of a target file frame, and (1) in fig. 6 shows an example of an interface before application shift of the target file frame, in which a first application icon and a second application icon are displayed. The dotted arrow pointing to the second application from the first application indicates that when the user moves the first application icon so that the distance between the first application icon and the second application icon is less than or equal to the second threshold, the terminal 110 displays an example image of the interface after the application shift of the target file frame shown in (2) in fig. 6, and in the interface shown in (2) in fig. 6, the position of the second application icon and the first application icon have been interchanged.
In a possible embodiment, when a user wants to use an application in the target file frame, an operation of moving the application icon out of the target file frame may be performed, and the terminal 110 detects the operation, acquires compressed data corresponding to the application icon, and decompresses the compressed data, thereby acquiring application data of the application. Further, after the application data is decompressed, the application icon in the target file frame may be deleted and independently displayed in the main interface of the terminal 110.
Based on the same inventive concept, please refer to fig. 7, which shows a flowchart of a data decompression method, the method includes:
s701: and responding to a second operation of moving the first application icon out of the target file frame, and displaying a second prompt interface.
When the user wants to use the first application 130, the user drags or clicks the application icon, the terminal 110 detects a second operation of the user to move the application icon out of the target file box, the second operation being, for example, a sliding operation, a dragging operation, etc., and displays a second prompt interface. And the second prompt interface is used for indicating whether to confirm whether to recover the application data corresponding to the application icon. The second prompt interface comprises a third key and a fourth key, the third key is used for confirming recovery of application data corresponding to the application icon, and the fourth key is used for confirming deletion of the application data corresponding to the application icon. The key may be an entity operation key, a touch key, or various keys such as a suspension key, which is not limited specifically.
For example, fig. 8 shows an exemplary diagram of an interface change of the terminal during data decompression, and (1) in fig. 8 shows an exemplary diagram of a compressed object file box, which displays the first application 130. The dotted arrow pointing to the desktop by the first application 130 indicates that the user moves the icon of the first application 130 out of the destination file box, the terminal 110 displays an exemplary diagram of a second interface as shown in (2) in fig. 8, the "resume" icon displayed in the second interface represents a third key, the "delete" icon represents a fourth key, when the user clicks the "resume" key, the user confirms that the compressed data corresponding to the application icon is restored, and when the user clicks the "delete" key, the user confirms that the compressed data corresponding to the application icon is deleted.
S702: and in response to the recovery operation performed on the second prompt interface, acquiring the compressed data associated with the application icon.
When the terminal 110 detects that the user clicks the third key, which is equivalent to the user performing an operation of confirming recovery of the application data corresponding to the application icon, the terminal 110 obtains the compressed data associated with the application icon. The compressed data includes one or both of installation data of the compressed application or usage data of the compressed application.
Further, in response to the confirmation performed on the second prompt interface not to resume the operation, the application icon and the compressed data associated with the application icon are deleted.
When the terminal 110 detects that the user clicks the fourth key, which is equivalent to the user performing an operation of confirming that the application data corresponding to the application icon is not recovered, the terminal 110 deletes the application icon and the compressed data associated with the application icon.
S703: and decompressing the compressed data to obtain application data, and deleting the first application icon in the target file frame.
As discussed above, the compressed data is obtained by compressing a plurality of compressed data packets, and when decompressing the compressed data, the terminal 110 first obtains a plurality of compressed data packets, and then decompresses each compressed data packet to obtain the application data. The decompression process is the same whether the compressed data or the data packet is decompressed, and the decompression of a certain data packet is taken as an example and described as follows:
the current encoded value is read. The current code value refers to a code value that the terminal 110 needs to decompress currently, and any character that needs to be decompressed can be regarded as the current code value.
And if the current coded value contains the identifier, determining that the character string corresponding to the current coded value is the character string read for the first time, and decoding the current coded value according to the identifier.
If the current code value contains a back-pointing distance and a repetition length, determining that a character string corresponding to the current code value is an Nth read character string, wherein N is an integer greater than or equal to 2, the Nth read character string indicates that the current character string appears in the process of reading the file before, finding the Nth read character string by the terminal 110 according to the back-pointing distance, and then obtaining the character string corresponding to the current code value according to the repetition length, wherein the back-pointing distance is a distance offset between the character string corresponding to the current code value and the character string read in the (N-1) th time, and the repetition length is the character string length corresponding to the current code value.
For example, when the character string of the compressed data to be decompressed is "(03) h, AAB, ((03) h, (06) h)", and the identifier "(03) h" is read, the 3 characters "AAB" following the identifier are determined as the character string read for the first time. When the "((03) h, (06) h)" is read, the character string corresponding to the "((03) h, (06) h)" is determined to be the character string read for the nth time, the character string "AAB" read for the (N-1) th time is found according to the distance 3, and the character string corresponding to the "((03) h, (06) h)" is obtained to be the "AABAAB" according to the length 6, so that the decoding result of the "((03) h,010110, ((03) h, (06) h)" is the "AABAABAAB".
For example, with continued reference to fig. 8, after the user clicks the "resume" button in (2) of fig. 8, the terminal 110 displays an exemplary diagram of a main interface after decompression is completed as in (3) of fig. 8, in which an application icon and a target file box of the first application 130 are displayed.
In one possible embodiment, a plurality of application icons are stored in the target file frame, and the terminal 110 may adjust or further arrange the application icons according to the user's associated operations on the icons.
For example, the target file frame includes a first application icon and a second application icon, when the user wants to sort the first application icon and the second application icon, the user may move the first application icon, and the terminal 110 detects that the distance between the first application icon and the second application icon in the target file frame is less than or equal to a first threshold, creates a subfile frame in the target file frame, where the subfile frame includes the first application icon and the second application icon.
Or, when the user wants to move the second application icon to the position of the first application icon, the user may move the first application icon, and the terminal 110 detects that the distance between the first application icon and the second application icon in the target file frame is less than or equal to a second threshold, moves the position of the second application icon to the position of the first application icon, and moves the first application to the right by one position, where the first threshold is less than the second threshold.
After the terminal 110 decompresses the compressed data associated with a certain application icon, the application icon is independently displayed in the main interface of the terminal 110 to indicate that the application can be normally used, and the deletion of the application icon in the target file frame indicates that the compressed data associated with the application icon has been deleted.
It should be noted that the terminal 110 may perform the above-described embodiments of fig. 2 and 7 simultaneously or only any one of them.
Based on the same inventive concept, the present application provides an apparatus for compressing data, which is disposed in the terminal 110 discussed above, and with reference to fig. 9, the apparatus includes:
an acquisition module 901: the application icon display method comprises the steps of responding to a first operation of moving an application icon to a target file frame, and obtaining application data related to the application icon; wherein the application data comprises one or both of installation data of the application or usage data of the application;
the compression module 902: the method is used for compressing the application data, obtaining compressed data and displaying the application icon in the target file frame.
In a possible embodiment, the obtaining module 901 is specifically configured to:
responding to the first operation, and displaying a first prompt interface; the first prompt interface is used for indicating whether to confirm whether to compress application data corresponding to the application icon;
and responding to the confirmation operation performed on the first prompt interface, and acquiring the application data associated with the application icon.
In a possible embodiment, the compression module 902 is specifically configured to:
compressing each file in the plurality of files to obtain a plurality of compressed data packets;
and compressing the plurality of compressed data packets to obtain compressed data.
In a possible embodiment, the compression module 902 is specifically configured to:
reading the current character string of each compressed data packet;
if the current character string is the character string read for the first time in each compressed data packet, encoding the current character string according to the identifier; the identifier is used for indicating that the current character string is a character string read for the first time, and is obtained according to the length of the current character string;
if the current character string is the character string read for the Nth time in each compressed data packet, encoding the current character string by using the back pointing distance and the repetition length to obtain compressed data; wherein, N is greater than or equal to 2, the pointing back distance is the distance offset between the current character string and the character string read in the (N-1) th time, and the repetition length is the length of the current character string.
Based on the same inventive concept, the present application provides an apparatus for decompressing data, which is disposed in the terminal 110 discussed above, and with reference to fig. 10, the apparatus includes:
the acquisition module 1001: the second operation for responding to the first application icon being moved out of the target file frame is used for acquiring compressed data associated with the first application icon; the compressed data comprises one or two of installation data of the compressed application or use data of the compressed application;
the decompression module 1002: and the system is used for decompressing the compressed data, obtaining application data and deleting the first application icon in the target file frame.
In a possible embodiment, the obtaining module 1001 is specifically configured to:
responding to the second operation, and displaying a second prompt interface; the second prompt interface is used for indicating whether application data corresponding to the application icon is recovered;
and in response to the recovery operation performed on the second prompt interface, acquiring the compressed data associated with the application icon.
In a possible embodiment, the obtaining module 1001 is specifically configured to:
and in response to the confirmation that the operation is not recovered in the second prompt interface, deleting the application icon and the compressed data associated with the application icon.
In a possible embodiment, the target file frame includes a first application icon and a second application icon, and the obtaining module 1001 is specifically configured to:
responding to the moving operation of the first application icon or the second application icon, detecting that the distance between the first application icon and the second application icon in the target file frame is smaller than or equal to a first threshold value, and generating a subfile frame in the target file frame, wherein the subfile frame comprises the first application icon and the second application icon; or, in response to the moving operation of the first application icon or the second application icon, detecting that the distance between the first application icon and the second application icon in the target file frame is smaller than or equal to a second threshold value, and moving the position of the first application icon to the position of the second application icon; wherein the first threshold is less than the second threshold.
In a possible embodiment, the decompression module 1002 is specifically configured to:
decompressing the compressed data to obtain a plurality of compressed data packets;
and decompressing the plurality of compressed data packets to obtain application data.
In a possible embodiment, the decompression module 1002 is specifically configured to:
reading the current coding value of each compressed data packet;
if the current coded value contains the identifier, determining that the character string corresponding to the current coded value is the character string read for the first time, and decoding the current coded value according to the identifier;
if the current coded value contains the finger-back distance and the repetition length, determining that the character string corresponding to the current coded value is the character string read for the Nth time, finding the character string read for the (N-1) th time according to the finger-back distance, and obtaining the character string corresponding to the current coded value according to the repetition length so as to obtain application data; and N is greater than or equal to 2, the pointing-back distance is the distance offset between the character string corresponding to the current code value and the character string read for the (N-1) th time, and the repetition length is the length of the character string corresponding to the current code value.
Based on the same inventive concept, the present application provides a computer device, please refer to fig. 11, which is equivalent to the terminal 110 discussed above, and the device includes:
at least one processor 1101, and
a memory 1102 communicatively connected to the at least one processor 1101;
wherein the memory 1102 stores instructions executable by the at least one processor 1101, the at least one processor 1101 implements the method of compressing data or the method of decompressing data discussed above by executing the instructions stored by the memory 1102.
As an example, the processor 1101 in fig. 11 may implement the method of compressing data or the method of decompressing data discussed above, and the processor 1101 may also implement the functions of the apparatus discussed above in fig. 9 or fig. 10.
Based on the same inventive concept, embodiments of the present application provide a computer-readable storage medium storing computer instructions that, when executed on a computer, cause the computer to perform a method of compressing data or a method of decompressing data as discussed above.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
It will be apparent to those skilled in the art that various changes and modifications may be made in the present application without departing from the spirit and scope of the application. Thus, if such modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is intended to include such modifications and variations as well.
Claims (14)
1. A method of compressing data, comprising:
responding to a first operation of moving an application icon to a target file frame, and acquiring application data associated with the application icon; wherein the application data comprises one or both of installation data of the application or usage data of the application;
and compressing the application data to obtain compressed data, and displaying the application icon in the target file frame.
2. The method of claim 1, wherein obtaining application data associated with an application icon in response to a first operation of moving the application icon to a target file box comprises:
responding to the first operation, and displaying a first prompt interface; the first prompt interface is used for indicating whether to confirm whether to compress the application data corresponding to the application icon;
and responding to the confirmation operation performed on the first prompt interface, and acquiring the application data associated with the application icon.
3. The method of claim 1, wherein the application data comprises a plurality of files, and compressing the application data to obtain compressed data comprises:
compressing each file in the plurality of files to obtain a plurality of compressed data packets;
and compressing the plurality of compressed data packets to obtain compressed data.
4. The method of claim 3, wherein compressing the plurality of compressed data packets to obtain compressed data comprises:
reading the current character string of each compressed data packet;
if the current character string is the character string read for the first time in each compressed data packet, encoding the current character string according to an identifier; the identifier is used for indicating that the current character string is a character string read for the first time, and is obtained according to the length of the current character string;
if the current character string is the character string read for the Nth time in each compressed data packet, encoding the current character string by using a finger-back distance and a repetition length to obtain compressed data; and N is greater than or equal to 2, the pointing back distance is the distance offset between the current character string and the character string read for the (N-1) th time, and the repetition length is the length of the current character string.
5. A method of decompressing data, comprising:
responding to a second operation of moving a first application icon out of a target file frame, and acquiring compressed data associated with the first application icon; wherein the compressed data comprises one or both of installation data of the compressed application or usage data of the compressed application;
and decompressing the compressed data to obtain application data, and deleting the first application icon in the target file frame.
6. The method of claim 5, wherein obtaining compressed data associated with a first application icon in response to a second operation of moving the first application icon out of a target file box comprises:
responding to the second operation, and displaying a second prompt interface; the second prompt interface is used for indicating whether to recover application data corresponding to the application icon;
and responding to the recovery operation performed on the second prompt interface, and acquiring the compressed data associated with the application icon.
7. The method of claim 6, after displaying the second prompt interface in response to the second operation, comprising:
and in response to the confirmation that the operation is not recovered in the second prompt interface, deleting the application icon and the compressed data associated with the application icon.
8. The method of claim 5, wherein the target file box includes the first application icon and a second application icon, the method further comprising one or both of:
in response to the moving operation of the first application icon or the second application icon, detecting that the distance between the first application icon and the second application icon in the target file box is smaller than or equal to a first threshold value, and creating a subfile box in the target file box, wherein the subfile box comprises the first application icon and the second application icon; or the like, or, alternatively,
responding to the movement operation of the first application icon or the second application icon, detecting that the distance between the first application icon and the second application icon in the target file frame is smaller than or equal to a second threshold value, and moving the position of the first application icon to the position of the second application icon; wherein the first threshold is less than the second threshold.
9. The method of claim 5, wherein the compressed data is obtained by compressing a plurality of compressed data packets, and decompressing the compressed data to obtain application data, comprises:
decompressing the compressed data to obtain a plurality of compressed data packets;
and decompressing the plurality of compressed data packets to obtain application data.
10. The method of claim 9, wherein decompressing the plurality of compressed data packets to obtain application data comprises:
reading the current coding value of each compressed data packet;
if the current coded value contains an identifier, determining that a character string corresponding to the current coded value is a character string read for the first time, and decoding the current coded value according to the identifier;
if the current coding value contains a finger-back distance and a repetition length, determining that a character string corresponding to the current coding value is an Nth read character string, finding the Nth-1 th read character string according to the finger-back distance, and obtaining the character string corresponding to the current coding value according to the repetition length to obtain application data; and N is greater than or equal to 2, the pointing back distance is a distance offset between the character string corresponding to the current coded value and the character string read for the (N-1) th time, and the repetition length is the length of the character string corresponding to the current coded value.
11. An apparatus for compressing data, comprising:
an acquisition module: the method comprises the steps of responding to a first operation of moving an application icon to a target file frame, and acquiring application data related to the application icon; wherein the application data comprises one or both of installation data of the application or usage data of the application;
a compression module: and the application icon display module is used for compressing the application data to obtain compressed data and displaying the application icon in the target file frame.
12. An apparatus for decompressing data, comprising:
an acquisition module: the second operation for responding to the first application icon being moved out of the target file frame is used for acquiring compressed data associated with the first application icon; wherein the compressed data comprises one or both of installation data of the compressed application or usage data of the compressed application;
a decompression module: the application icon deleting module is used for decompressing the compressed data, obtaining application data and deleting the first application icon in the target file frame.
13. A computer device, comprising:
at least one processor, and
a memory communicatively coupled to the at least one processor;
wherein the memory stores instructions executable by the at least one processor, the at least one processor implementing the method of any one of claims 1-4 or 5-10 by executing the instructions stored by the memory.
14. A computer-readable storage medium having stored thereon computer instructions which, when executed on a computer, cause the computer to perform the method of any one of claims 1-4 or 5-10.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010855878.9A CN112069140A (en) | 2020-08-24 | 2020-08-24 | Method, device, equipment and medium for compressing and decompressing data |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010855878.9A CN112069140A (en) | 2020-08-24 | 2020-08-24 | Method, device, equipment and medium for compressing and decompressing data |
Publications (1)
Publication Number | Publication Date |
---|---|
CN112069140A true CN112069140A (en) | 2020-12-11 |
Family
ID=73659253
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202010855878.9A Pending CN112069140A (en) | 2020-08-24 | 2020-08-24 | Method, device, equipment and medium for compressing and decompressing data |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112069140A (en) |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105988805A (en) * | 2015-02-12 | 2016-10-05 | 广东欧珀移动通信有限公司 | Management method for application programs and mobile terminal |
CN109101154A (en) * | 2018-08-10 | 2018-12-28 | 珠海格力电器股份有限公司 | Mobile terminal file storage method, storage system and mobile terminal |
CN109690519A (en) * | 2017-06-16 | 2019-04-26 | 华为技术有限公司 | A kind of document handling method and mobile terminal |
CN109889204A (en) * | 2018-12-24 | 2019-06-14 | 医渡云(北京)技术有限公司 | Method, the accelerator card of a kind of FPGA and its compressed data |
US20200142604A1 (en) * | 2018-11-02 | 2020-05-07 | EMC IP Holding Company LLC | Using variable sized uncompressed data blocks to address file positions when simultaneously compressing multiple blocks |
-
2020
- 2020-08-24 CN CN202010855878.9A patent/CN112069140A/en active Pending
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105988805A (en) * | 2015-02-12 | 2016-10-05 | 广东欧珀移动通信有限公司 | Management method for application programs and mobile terminal |
CN109690519A (en) * | 2017-06-16 | 2019-04-26 | 华为技术有限公司 | A kind of document handling method and mobile terminal |
CN109101154A (en) * | 2018-08-10 | 2018-12-28 | 珠海格力电器股份有限公司 | Mobile terminal file storage method, storage system and mobile terminal |
US20200142604A1 (en) * | 2018-11-02 | 2020-05-07 | EMC IP Holding Company LLC | Using variable sized uncompressed data blocks to address file positions when simultaneously compressing multiple blocks |
CN109889204A (en) * | 2018-12-24 | 2019-06-14 | 医渡云(北京)技术有限公司 | Method, the accelerator card of a kind of FPGA and its compressed data |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10264039B2 (en) | Streaming content and placeholders | |
CN101957730B (en) | Messaging device and information processing method | |
KR102128138B1 (en) | Hydration and dehydration with placeholders | |
CN107229420B (en) | Data storage method, reading method, deleting method and data operating system | |
US10423527B2 (en) | Memory management and image display for mobile devices | |
CN106909855B (en) | File hiding method and device | |
US9864736B2 (en) | Information processing apparatus, control method, and recording medium | |
US20070067362A1 (en) | Undo function for unzipped files | |
CN112114999A (en) | Data backup method, data recovery method, data backup device, data recovery device and electronic equipment | |
CN112748863B (en) | Method, electronic device and computer program product for processing data | |
KR20200015773A (en) | File processing method and mobile terminal | |
CN107408242B (en) | Providing interactive previews of content within communications | |
CN114329298B (en) | Page presentation method and device, electronic equipment and storage medium | |
CN102737205B (en) | Protection comprises can the file of editing meta-data | |
JP2012150720A (en) | File management device and program | |
CN110119386B (en) | Data processing method, data processing apparatus, medium, and computing device | |
CN105893471B (en) | Data processing method and electronic equipment | |
CN110674084A (en) | Method, apparatus, and computer-readable storage medium for data protection | |
CN106484691B (en) | data storage method and device of mobile terminal | |
CN113268453A (en) | Log information compression storage method and device | |
CN112069140A (en) | Method, device, equipment and medium for compressing and decompressing data | |
CN107515704B (en) | Method and device for previewing compressed file | |
CN111858158B (en) | Data processing method and device and electronic equipment | |
US10248335B2 (en) | Reducing a size of backup data in storage | |
CN102567460B (en) | Method for image asynchronous decoding in document loading |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20201211 |