CN108733489A - Data processing method, device, electronic equipment and storage medium - Google Patents

Data processing method, device, electronic equipment and storage medium Download PDF

Info

Publication number
CN108733489A
CN108733489A CN201810450123.3A CN201810450123A CN108733489A CN 108733489 A CN108733489 A CN 108733489A CN 201810450123 A CN201810450123 A CN 201810450123A CN 108733489 A CN108733489 A CN 108733489A
Authority
CN
China
Prior art keywords
terminal
pending data
data
stored
caching
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201810450123.3A
Other languages
Chinese (zh)
Inventor
杨欣霖
魏为
彭飞
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing 58 Information Technology Co Ltd
Original Assignee
Beijing 58 Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing 58 Information Technology Co Ltd filed Critical Beijing 58 Information Technology Co Ltd
Priority to CN201810450123.3A priority Critical patent/CN108733489A/en
Publication of CN108733489A publication Critical patent/CN108733489A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5011Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals
    • G06F9/5022Mechanisms to release resources

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

Data processing method, device, electronic equipment and storage medium provided in an embodiment of the present invention, in data processing method, terminal obtains pending data;Pending data is stored in and caches by terminal;Pending data in terminal-pair caching is handled;The pending data stored in terminal deletion caching.After pending data is stored in caching and is handled by terminal in the embodiment of the present invention, pending data is removed from the cache, so that terminal ensures to reduce unnecessary caching consumption in the case of terminal fluency when handling data.

Description

Data processing method, device, electronic equipment and storage medium
Technical field
The present invention relates to terminal technology more particularly to a kind of data processing method, device, electronic equipment and storage mediums.
Background technology
Caching is the memory space for storing pending data in terminal, and the central processing unit in terminal is arranged more In (Central Processing Unit, CPU).Since caching is relative to the rapid reading speed of memory, terminal is in processing number According to when will usually be handled after the data duplicate cache in the storage device of terminal.
In the prior art, it can be provided using IOS operating system using the terminal of IOS operating system when handling picture Two kinds of application programming interfaces (Application Programming Interface, API).At the first In the method that imageNamed series As PI is provided, terminal is handled after pending picture is all stored in caching, to improve figure Piece service efficiency.But the API of imageNamed series is unable to control caching release, increases the alarm probability of caching.Second In the method that the non-imageNamed series As PI of kind is provided, pending picture will not be stored in and cache by terminal, but directly from memory It is middle to call pending picture, and i.e. release picture after use.But it is the API of non-imageNamed series larger more Picture when being reused, page interim card can be caused not smooth.
Therefore, how to make the terminal of IOS operating system when handling picture, reduced in the case where ensureing terminal fluency The technical issues of unnecessary caching consumption is current urgent need to resolve.
Invention content
A kind of data processing method of offer of the embodiment of the present invention, device, electronic equipment and storage medium, make terminal handle When picture, ensure to reduce unnecessary caching consumption in the case of terminal fluency.
In a first aspect, the embodiment of the present invention provides a kind of data processing method, including:
Terminal obtains pending data;
The pending data is stored in and caches by the terminal;
The pending data in being cached described in the terminal-pair is handled;
The pending data stored in being cached described in the terminal deletion.
In a kind of possible realization method of first aspect of the embodiment of the present invention, stored in being cached described in the terminal deletion The pending data, including:
The terminal deletes the pending number stored in the caching according to the memory service condition of the terminal According to.
In a kind of possible realization method of first aspect of the embodiment of the present invention, the terminal is according to the memory of the terminal Service condition deletes the pending data stored in the caching, including:
If the memory that the operating system for obtaining the terminal is sent out alerts, the institute stored in being cached described in the terminal deletion State pending data.
In a kind of possible realization method of first aspect of the embodiment of the present invention, stored in being cached described in the terminal deletion The pending data, including:
If the data volume stored in the caching of the terminal is more than first threshold, stored in being cached described in the terminal deletion The pending data.
In a kind of possible realization method of first aspect of the embodiment of the present invention, stored in being cached described in the terminal deletion The pending data, including:
If the data volume of the pending data is more than second threshold, stored in being cached described in the terminal deletion described Pending data.
In a kind of possible realization method of first aspect of the embodiment of the present invention, the terminal deposits the pending data Before entering caching, further include:
The terminal judges whether the pending data meets preset condition;
It is cached if so, the pending data is stored in by the terminal.
In a kind of possible realization method of first aspect of the embodiment of the present invention, the preset condition includes:
It is big that the number of processes of pending data described in the terminal-pair is more than first threshold, the size of the pending data It is unsatisfactory for preset standard in the performance of second threshold, the memory headroom deficiency third threshold value of the terminal or the terminal.
Second aspect, the embodiment of the present invention provide a kind of data processing equipment, including:
Acquisition module, for obtaining pending data;
Cache module is cached for the pending data to be stored in;
Processing module, for handling the pending data in the caching;
Removing module, for deleting the pending data stored in the caching.
In a kind of possible realization method of second aspect of the embodiment of the present invention, removing module is specifically used for, according to described The memory service condition of terminal deletes the pending data stored in the caching.
In a kind of possible realization method of second aspect of the embodiment of the present invention, removing module is specifically used for, if obtaining institute The memory warning that the operating system of terminal is sent out is stated, the pending data stored in the caching is deleted.
In a kind of possible realization method of second aspect of the embodiment of the present invention, removing module is specifically used for, if the end The data volume stored in the caching at end is more than first threshold, deletes the pending data stored in the caching.
In a kind of possible realization method of second aspect of the embodiment of the present invention, removing module is specifically used for, if described wait for The data volume for handling data is more than second threshold, deletes the pending data stored in the caching.
In a kind of possible realization method of second aspect of the embodiment of the present invention, further include:Judgment module, the judgement mould Block is for judging whether the pending data meets preset condition;
It is cached if so, the pending data is stored in by the cache module.
In a kind of possible realization method of second aspect of the embodiment of the present invention, the preset condition includes:
It is big that the number of processes of pending data described in the terminal-pair is more than first threshold, the size of the pending data It is unsatisfactory for preset standard in the performance of second threshold, the memory headroom deficiency third threshold value of the terminal or the terminal.
The third aspect, the embodiment of the present invention provide a kind of electronic equipment, including:
Processor;And
Memory, the executable instruction for storing the processor;
Wherein, the processor is configured to execute at the data described in first aspect via the executable instruction is executed Reason method.
Fourth aspect, the embodiment of the present invention provide a kind of computer readable storage medium, are stored thereon with computer program, The data processing method described in first aspect is realized when the computer program is executed by processor.
Data processing method, device, electronic equipment and storage medium provided in an embodiment of the present invention, data processing method In, terminal obtains pending data;Pending data is stored in and caches by terminal;At pending data in terminal-pair caching Reason;The pending data stored in terminal deletion caching.By being directed to pending data deposit caching simultaneously in the embodiment of the present invention After being handled, pending data is removed from the cache, so that terminal when handling data, ensures terminal fluency In the case of reduce the consumption of unnecessary caching.
Description of the drawings
It, below will be to embodiment or existing in order to clearly demonstrate the embodiment of the present invention or technical solution in the prior art Attached drawing is briefly described needed in technology description, it should be apparent that, the accompanying drawings in the following description is the present invention Some embodiments of embodiment, for those of ordinary skill in the art, without having to pay creative labor, also It can be obtain other attached drawings according to these attached drawings.
Fig. 1 is the flow diagram of data processing method embodiment one provided in an embodiment of the present invention;
Fig. 2 is the flow diagram of data processing method embodiment two provided in an embodiment of the present invention;
Fig. 3 is the flow diagram of data processing method embodiment three provided in an embodiment of the present invention;
Fig. 4 is the structural schematic diagram of data processing equipment embodiment one provided in an embodiment of the present invention;
Fig. 5 is the structural schematic diagram of data processing equipment embodiment two provided in an embodiment of the present invention;
Fig. 6 is the hardware architecture diagram of electronic equipment provided in an embodiment of the present invention.
Specific implementation mode
In order to make the object, technical scheme and advantages of the embodiment of the invention clearer, below in conjunction with the embodiment of the present invention In attached drawing, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that described embodiment is A part of the embodiment of the embodiment of the present invention, instead of all the embodiments.Based on the embodiment in the embodiment of the present invention, this field The every other embodiment that those of ordinary skill is obtained without making creative work, belongs to implementation of the present invention The range of example protection.
Fig. 1 is the flow diagram of data processing method embodiment one provided in an embodiment of the present invention as shown in Figure 1, originally Embodiment provide data processing method include:
S101:Terminal obtains pending data.
Wherein, the executive agent of the embodiment of the present invention can be the terminal for having data processing function.Terminal can also claim For terminal Terminal, user equipment (user equipment, UE), mobile station (mobile station, MS), mobile terminal (mobile terminal, MT) etc..Terminal can be mobile phone (mobile phone), tablet computer (Pad), band wireless receiving and dispatching The computer of function, virtual reality (Virtual Reality, VR) terminal device, augmented reality (Augmented Reality, AR) in terminal device, the wireless terminal in Industry Control (industrial control), unmanned (self driving) Wireless terminal, the wireless terminal in remote operation (remote medical surgery), intelligent grid (smart grid) In wireless terminal, the wireless terminal in transportation safety (transportation safety), smart city (smart city) In wireless terminal, the wireless terminal etc. in wisdom family (smart home).
Specifically, terminal obtains pending data from the storage device of terminal in S101.Memory space can be Hard disk, safe digital card (Secure Digital Memory Card, SDcard) or external the depositing of terminal connection of terminal Store up equipment.Such as when terminal needs to handle a data, being read by processor for terminal is pending in storage device Data.In this step, terminal only carries out pre-read without doing any operation to pending data.
Optionally, the terminal in the embodiment of the present invention is the terminal using IOS systems, then pending data is to be built in end Picture in the application package at end.It is supported in addition, data pending in the embodiment of the present invention can be all mobile phones itself Picture format.
S102:Pending data is stored in and caches by terminal.
Specifically, the pending data obtained in S101 is stored in the caching of terminal by terminal, in processing from caching It reads and writees, to ensure speed and fluency of the terminal when handling data.
S103:Pending data in terminal-pair caching is handled.
Specifically, the pending data that caching is stored in terminal-pair S102 is handled.Wherein, terminal can pass through center Processor (Central Processing Unit, CPU) handles pending data, specific this implementation of processing mode Example is not specifically limited.
S104:The pending data stored in terminal deletion caching.
Specifically, in a kind of embodiment for removing caching of the embodiment of the present application, when terminal stores in S103 is to caching Pending data handled after, by caching pending data delete.Caching is accounted for by reducing pending data With the time, the service efficiency of the caching of terminal can be improved.
Optionally, terminal can be in the case where pending data meets certain condition, to what is stored in caching in S104 Pending data is deleted, and several possible realization methods are by being shown below.
To sum up, in data processing method provided in this embodiment, terminal obtains pending data;Terminal is by pending data Deposit caching;Pending data in terminal-pair caching is handled;The pending data stored in terminal deletion caching.Cause This, is cached by being directed to pending data deposit and after being handled, pending data is removed from the cache, so that eventually Hold reduces unnecessary caching when handling data in the case of fluency of the guarantee terminal using caching process data disappears Consumption.
Further, the first possible realization method of the S104 in above-described embodiment is:When terminal by S103 to slow After the pending data of storage is handled, terminal deletes the pending data stored in caching immediately.
I.e. terminal stores data be disposed into caching after delete immediately, to the maximum extent reduce data to end The occupancy for holding caching, improves the utilization ratio of caching.
Alternatively, second of possible realization method of S104 in above-described embodiment is:Terminal is deleted according to memory service condition Except the pending data stored in caching.
Wherein, the caching of terminal can be realized by a part of space of terminal memory, thus terminal EMS memory occupation compared with When big, the pending data stored in caching can be deleted according to the service condition of memory.
Such as:If the memory warning that the operating system of terminal is sent out, the pending data that terminal deletion stores in caching. Wherein, the operating system of terminal can be detected the memory of terminal, and after EMS memory occupation reaches predetermined threshold value, send out interior Warning is deposited, warning terminal-pair memory is discharged.Then terminal waits for after operating system sends out memory warning what is stored in caching Processing data are deleted, to discharge caching.
I.e. terminal is not deleted after pending data is stored in caching every time and is disposed, but is being grasped immediately After system sends out memory warning, the data crossed to all terminal processes stored in caching are deleted, and empty all delay Deposit space.To reduce the frequent operation discharged to caching after data of the terminal in caching per treatment, and in terminal Operating system send out memory warning after, in time to caching discharge, improve the utilization ratio and release efficiency of caching.
Alternatively, S104 the third possible realization method in above-described embodiment is:If the number stored in the caching of terminal It is more than first threshold according to amount, then the pending data stored in terminal deletion caching.
Wherein, terminal is all deleted to the pending data stored in caching after complete pending data per treatment It removes.But after certain processing pending data, if the total amount of data that terminal stores in caching at this time is more than first threshold, eventually Delete all pending datas stored in caching in end.
Such as:First threshold is set as 50M, and after the accumulative processing n times pending data of terminal, the number stored in caching 45M is had reached according to amount, the pending data size of the N+1 times processing is 6M.After then pending data deposit is cached, eventually The pending data total amount stored in the caching at end is 51M, is more than first threshold, then terminal has been handled pending at the N+1 times After data, all 51M data stored in caching are deleted.After reducing data of the terminal in caching per treatment To the frequent operation that is discharged of caching, and when data volume reaches the first predetermined threshold value in the caching of terminal, in time to caching It is discharged, improves the utilization ratio and release efficiency of caching.
Alternatively, the 4th kind of possible realization method of S104 in above-described embodiment is:If the pending number obtained in S101 According to data volume be more than second threshold, then the pending data that stores in terminal deletion caching.
Wherein, terminal is all deleted to the pending data stored in caching after complete pending data per treatment It removes.But after complete pending data per treatment, the data volume size of pending data is judged, if pending data Data volume is more than second threshold, then is removed from the cache the pending data.Optionally, what is stored in terminal deletion caching waits for All data stored in caching are deleted while handling data.Such as:Second threshold is set as 20M, then certain processing of terminal The size of pending data be 21M, then terminal judges data volume more than second threshold after handle the pending data, The pending data stored in will being cached after then having handled is deleted.Spatial cache is accounted on a large scale to reduce With, and do not deleted immediately when data volume is less than second threshold, reduce data of the terminal in caching per treatment The frequent operation that caching is discharged afterwards, and the data more than second threshold are in time discharging caching, to carry The utilization ratio and release efficiency of high level cache.
It should be noted that terminal can be using various to being deposited in caching in any one or a variety of the various embodiments described above The mode that the pending data of storage is deleted.I.e. all realization methods can realize by same terminal, by terminal according to using feelings The attribute of condition and pending data selects different realization methods, when meeting one of condition or meet institute The data in caching are deleted after having ready conditions.
Further, Fig. 2 is the flow diagram of data processing method embodiment two provided in an embodiment of the present invention.Such as figure In the above-described embodiments, S102 further includes before 2 embodiment:
S1012:Terminal judges whether pending data meets preset condition, if pending data meets preset condition, eventually End executes step S102, pending data is stored in the caching of terminal, and carried out to the pending data in caching by S103 Processing.
Specifically, in step S1012, terminal judges whether the pending data obtained in S101 meets preset condition. Optionally, preset condition may include four kinds:The number of processes of terminal-pair pending data is more than first threshold, pending The performance that the size of data is more than second threshold, the memory headroom deficiency third threshold value of terminal or terminal is unsatisfactory for pre- bidding It is accurate.
Wherein, in the first above-mentioned preset condition, if the number of processes of terminal-pair pending data is more than first threshold When, terminal may need repeatedly to be read and writen pending data, then terminal will be called when handling data and frequently be waited for The spatial cache for handling data deposit terminal reads and writees in processing from caching, to ensure terminal when handling data Fluency.Optionally, the number of processes of terminal-pair pending data can be by event to be processed to pending data Number of processes, can also be the accumulative number for handling the pending data of terminal.
In above-mentioned second of preset condition, if the size of the data volume of pending data is more than second threshold, terminal Speed is slower when reading and writing the larger data of data volume from memory, therefore data volume is more than waiting for for second threshold by terminal In the caching for handling data deposit terminal, speed is read and write with the raising pending data larger to data volume.
In the third above-mentioned preset condition, if terminal when judging whether pending data meets preset condition, at this time The memory headroom of terminal is occupied and insufficient third threshold value by other data, then needs the pending number that will originally read in memory According in storage to caching, the possibility occurred and the utilization rate for improving caching are alerted to reduce memory.
In above-mentioned 4th kind of preset condition, if the performance of terminal is unsatisfactory for preset standard, pending data is stored Into caching, and is read from caching and pending data is handled.Specifically, the preset standard of performance can be according to waiting locating The characteristics of managing data is adjusted, such as:Pending data is rendering multi-dimensional picture, and the processor of terminal is needed to be at least up to One arithmetic speed.If judging, the arithmetic speed of the terminal is less than the first arithmetic speed, and pending data is stored in terminal In caching, from the speed angle for reading data is reduced, the deficiency of processor performance is made up, improves the processing speed to pending data Degree.
In addition, first threshold, second threshold, third threshold value and preset standard in above-mentioned 4th kind of preset condition can be with It is adjusted according to pending data, or is adjusted according to the occupancy situation of memory, caching by terminal.And terminal is treated Whether processing data, which meet above-mentioned four kinds of preset conditions, can also be carried out at the same time judgement, and step is executed if meeting any preset condition Rapid S102.
Further, in S102, pending data is stored in the caching of terminal by terminal, is specifically included:
S1021:Terminal creates the first spatial cache in the caching of terminal.
S1022:Pending data is stored in the first spatial cache by terminal.
Wherein, the first spatial cache is specially arranged in terminal in the buffer, is stored in pending data for executing in S102 The operation of caching.
Optionally, if terminal is that IOS operating system terminal, S1021 is used to specifically include:Terminal passes through IOS operating system Caching NSCahe classes the first spatial cache is created in the caching of terminal;S1022 is specifically included:Terminal will by NSCahe classes Pending data is stored in the first spatial cache.Wherein, NSCache classes are the cache classes that iOS operating systems provide.The present embodiment is logical It crosses NSCache classes and creates the first spatial cache in the caching of terminal as caching container, and realized in the first spatial cache Addition is deleted, the operation of batch deletion pending data, and NSCache classes are thread-safes.When pending data is figure When piece, the Key of NSCache is the title of picture.
Optionally, (manager is for operating by customized manager .h in IOS operating system in the present embodiment Addition that NSCache classes cache pending data, deletion, reading) code realizes that step is:
1, the system function function library of Foundation.h is imported;
2, definition one is macro so that in follow-up code, can call this macro by way of calling, realize and managed to caching Manage the realization of function;
3, a class is defined, such integrated NSObject;
4, the method for creating a singleton;
5, the attribute of the class of caching is safeguarded by NSCache classes.
Specifically, terminal creates the first spatial cache based on NScache classes in the caching of terminal, and according in S1012 Judging result determine whether pending data needs to store to the first spatial cache.Optionally, it is created in IOS operating system The classification UIImage+LocalCache of UIImage is built, that is, creates API to judge that it is default that pending data meets in S1012 After condition, NSCache classes are notified to execute the caching to pending data by the API.Specifically, it is with pending data For picture, the API is for calling above-mentioned manager .h to control caching.Can include parameter cache in API, Such as when cache is YES, needs NSCache classes to be stored in pending data and cache, when cache is NO, does not need Pending data is stored in and caches by NSCache classes.
Fig. 3 is the flow diagram of data processing method embodiment three provided in an embodiment of the present invention.Fig. 3 is above-mentioned API A kind of possible implementation flow chart, as shown in Fig. 2, the present embodiment flow includes:The pending picture of S201 pre-acquiring, and S201 judges whether picture format is compatible with the picture handled by NSCache classes, and flow is exited if incompatible and returns to null value;If Whether picture compatible then that pre-acquiring is judged in S203 needs to cache, the same S102 of judgment mode.If it need not cache directly Return to Target Photo;If desired it caches then in S204 access cache managers, and whether to judge the pre-acquiring picture in S205 It is buffered.Target Photo is returned if buffered;After S206 executes caching if not caching, Target Photo is returned.
Further, in above-mentioned S1012, if pending data is unsatisfactory for preset condition, terminal deposits pending data Enter the memory of terminal, and the pending data in memory is handled.
Specifically, if judging in S1012, pending data is unsatisfactory for above-mentioned preset condition, and terminal deposits pending data In the memory for entering terminal, and reads the pending data in memory and handled.Wherein, when terminal is to use IOS operating system Terminal when, terminal can be passed through by ICF (image With Contents Of File) method in IOS operating system The path of pending picture obtains pending picture, and pending picture is loaded into the memory of terminal, for SS later Pending data is handled.Wherein, ICF methods are the API for the acquisition picture resource that IOS operating system provides, and belong to non- The API of imageNamed series.In addition, can be cached to avoid the pending picture of terminal-pair using ICF methods.
Therefore, the present embodiment judges whether pending data meets preset condition by S1012, and respectively according to two kinds of numbers According to the selection under the different situations of processing mode, data processing is realized in the case where ensureing terminal smoothness degree, is reduced eventually Hold unnecessary memory consumption.Such as:In the above embodiments of the present application, such as certain pictures need frequently to render, such as fast When needing constantly to render picture in the dynamic list of ski-running, picture is stored in by caching by S102 at this time and to picture at Reason, Loads Image, speed is very fast, it is ensured that fluency from caching.And under the scene without the concern for fluency, then Pending data is handled, reads in picture to memory and handles from hard disk, without will produce unnecessary caching.
To sum up, in data processing method provided in an embodiment of the present invention, terminal is by judging whether pending data meets Preset condition will be handled in pending data access to caching or memory.Particularly, if terminal is operated using IOS When the terminal of system, terminal is used in conjunction with each other by ICF methods and NSCache classes.When pending data meets preset condition, Storage and and reading pending data in the spatial cache that NSCache classes create;When pending data is unsatisfactory for default item Part, by ICF methods directly from storage device read it is pending store to when memory and subsequent processing from reading and waiting in memory Data are managed in the case where ensureing terminal smoothness degree, reduce the unnecessary memory consumption of terminal, reach accurate control The purpose of pending data caching and release processed.Meanwhile also effectively reduce the memory average peak of terminal, reduce terminal by Lead to the probability of program crashing in low memory.
Fig. 4 is the structural schematic diagram of data processing equipment embodiment one provided in an embodiment of the present invention.As shown in figure 4, this Embodiment data processing equipment 40 includes:Acquisition module 401, cache module 402 and processing module 403 and removing module 404.Its In, acquisition module 401 from the storage device of terminal for obtaining pending data;Judgment module cache module 402 is for sentencing Whether disconnected pending data meets preset condition;It, will be pending if processing module 403 meets preset condition for pending data Data are stored in the caching of terminal, and handle the pending data in caching;If processing module 403 is additionally operable to pending number According to preset condition is unsatisfactory for, pending data is stored in the memory of terminal, and the pending data in memory is carried out at processing Reason module 403 is for handling the pending data in caching;Removing module 404 be used for deletes cache in store wait locating Manage data.
Optionally, 404 processing module 403 of removing module is specifically used for, and according to the memory service condition of terminal, deletes caching The pending data stored in space.The first spatial cache is created in the caching of terminal;Pending data deposit first is delayed Deposit space.
Optionally, 404 specific processing module 403 of removing module is additionally operable to, if obtain terminal operating system send out it is interior Warning is deposited, the pending data stored in spatial cache is deleted.Delete the pending data stored in the first spatial cache.
Optionally, 404 specific processing module 403 of removing module is additionally operable to, if the data volume stored in the caching of terminal is big In first threshold, the pending data that is stored in spatial cache memory service condition or the first spatial cache according to terminal are deleted Service condition, delete the pending data that stores in the first spatial cache.
Optionally, removing module 404 is specifically used for, if the data volume of pending data is more than second threshold, deletes caching The pending data stored in space.
Fig. 5 is the structural schematic diagram of data processing equipment embodiment two provided in an embodiment of the present invention.As shown in figure 5, this Embodiment data processing equipment 40 includes:Acquisition module 401, cache module 402 and processing module 403, removing module 404 and sentence Disconnected module 405.Wherein, data processing equipment on the basis of above-described embodiment further includes:Judgment module 405 is waited for for judging Whether processing data meet preset condition;It is cached if so, pending data is stored in by cache module 402.
Optionally, preset condition includes:The number of processes of terminal-pair pending data is more than first threshold, pending data Size be more than second threshold, the memory headroom deficiency third threshold value of terminal or terminal performance be unsatisfactory for preset standard.
Data processing equipment provided in an embodiment of the present invention can be used for executing above-mentioned data processing method, realization method Similar with technique effect, details are not described herein again for the embodiment of the present invention.
It can carry out the division of function module, example in the embodiment of the present invention to data processing equipment according to above method example Such as, each function can be corresponded to and divide each function module, two or more functions can also be integrated at one It manages in module.The form that hardware had both may be used in above-mentioned integrated module is realized, the form of software function module can also be used It realizes.It should be noted that being schematical, only a kind of logic to the division of module in each embodiment of the embodiment of the present invention Function divides, formula that in actual implementation, there may be another division manner.
Fig. 6 is the hardware architecture diagram of electronic equipment provided in an embodiment of the present invention.As shown in fig. 6, the electronic equipment 60 include:Memory 61 and processor 62;
Memory 61, for storing computer program;
Processor 62, the computer program for executing memory storage, to realize the data processing in above-described embodiment Method.The specific associated description that may refer in preceding method embodiment.
Optionally, memory 61 can also be integrated with processor 62 either independent.
When device except the memory 61 is independently of processor 62, the electronic equipment 60 can also include:
Bus 63, for connecting the memory 61 and processor 62.
Electronic equipment provided in an embodiment of the present invention can be used for executing above-mentioned data processing method, realization method and skill Art effect is similar, and details are not described herein again for the embodiment of the present invention.
The embodiment of the present invention also provides a kind of electronic equipment, and the electronic equipment is any shown in above-described embodiment for executing Data processing method in each step.
The embodiment of the present invention also provides a kind of readable storage medium storing program for executing, and computer program is stored in readable storage medium storing program for executing, when When at least one processor for the device that message is sent executes the computer program, the device that message is sent executes above-described embodiment Any data processing method.
The embodiment of the present invention also provides a kind of program product, which includes computer program, the computer program It is stored in readable storage medium storing program for executing.At least one processor of form validation device can read the calculating from readable storage medium storing program for executing Machine program, at least one processor executes the device that the computer program so that message is sent, and to execute above-described embodiment any described Method.
In several embodiments that the embodiment of the present invention is provided, it should be understood that disclosed device and method, it can be with It realizes by another way.For example, apparatus embodiments described above are merely indicative, for example, the module It divides, only a kind of division of logic function, formula that in actual implementation, there may be another division manner, such as multiple modules can be tied Another system is closed or is desirably integrated into, or some features can be ignored or not executed.Another point, it is shown or discussed Mutual coupling, direct-coupling or communication connection can be the INDIRECT COUPLING or logical by some interfaces, device or module Letter connection can be electrical, machinery or other forms.
The module illustrated as separating component may or may not be physically separated, aobvious as module The component shown may or may not be physical unit, you can be located at a place, or may be distributed over multiple In network element.Some or all of module therein can be selected according to the actual needs to realize the embodiment of the present invention Purpose.
In addition, each function module in each embodiment of the embodiment of the present invention can be integrated in a processing unit, Can also be that modules physically exist alone, it can also be during two or more modules be integrated in one unit.Above-mentioned mould Block at unit both may be used hardware form realize, can also be realized in the form of hardware adds SFU software functional unit.
The above-mentioned integrated module realized in the form of software function module, can be stored in one and computer-readable deposit In storage media.Above-mentioned software function module is stored in a storage medium, including some instructions are used so that a computer Equipment (can be personal computer, server or the network equipment etc.) or processor (English:Processor this Shen) is executed Please each embodiment the method part steps.
It should be understood that above-mentioned processor can be central processing unit (English:Central Processing Unit, letter Claim:CPU), it can also be other general processors, digital signal processor (English:Digital Signal Processor, Referred to as:DSP), application-specific integrated circuit (English:Application Specific Integrated Circuit, referred to as: ASIC) etc..General processor can be microprocessor or the processor can also be any conventional processor etc..In conjunction with hair The step of bright disclosed method, can be embodied directly in hardware processor and execute completion, or with hardware in processor and soft Part block combiner executes completion.
Memory may include high-speed RAM memory, it is also possible to and further include non-volatile memories NVM, for example, at least one Magnetic disk storage can also be USB flash disk, mobile hard disk, read-only memory, disk or CD etc..
Bus can be industry standard architecture (Industry Standard Architecture, ISA) bus, outer Portion's apparatus interconnection (Peripheral Component, PCI) bus or extended industry-standard architecture (Extended Industry Standard Architecture, EISA) bus etc..Bus can be divided into address bus, data/address bus, control Bus etc..For ease of indicating, the bus in illustrations does not limit only a bus or a type of bus.
Above computer readable storage medium storing program for executing can be by any kind of volatibility or non-volatile memory device or Combination thereof realizes that, such as static RAM (SRAM), electrically erasable programmable read-only memory (EEPROM) can Erasable programmable read-only memory (EPROM) (EPROM), programmable read only memory (PROM), read-only memory (ROM), magnetic memory, Flash memory, disk or CD.Storage medium can be any usable medium that general or specialized computer can access.
One of ordinary skill in the art will appreciate that:Realize that all or part of step of above-mentioned each method embodiment can lead to The relevant hardware of program instruction is crossed to complete.Program above-mentioned can be stored in a computer read/write memory medium.The journey When being executed, execution includes the steps that above-mentioned each method embodiment to sequence;And storage medium above-mentioned includes:ROM, RAM, magnetic disc or The various media that can store program code such as person's CD.
Finally it should be noted that:The above various embodiments is only to illustrate the technical solution of the embodiment of the present invention, rather than to it Limitation;Although the embodiment of the present invention is described in detail with reference to foregoing embodiments, those skilled in the art It should be understood that:Its still can with technical scheme described in the above embodiments is modified, either to which part or All technical features carries out equivalent replacement;And these modifications or replacements, it does not separate the essence of the corresponding technical solution this hair The range of bright each embodiment technical solution of embodiment.

Claims (10)

1. a kind of data processing method, which is characterized in that including:
Terminal obtains pending data;
The pending data is stored in and caches by the terminal;
The pending data in being cached described in the terminal-pair is handled;
The pending data stored in being cached described in the terminal deletion.
2. according to the method described in claim 1, it is characterized in that, what is stored in being cached described in the terminal deletion described waits locating Data are managed, including:
The terminal deletes the pending data stored in the caching according to the memory service condition of the terminal.
3. according to the method described in claim 2, it is characterized in that, the terminal according to the memory service condition of the terminal, The pending data stored in the caching is deleted, including:
If the warning of memory that the operating system for obtaining the terminal is sent out, what is stored in being cached described in the terminal deletion described waits for Handle data.
4. according to the method described in claim 1, it is characterized in that, what is stored in being cached described in the terminal deletion described waits locating Data are managed, including:
If the data volume stored in the caching of the terminal is more than first threshold, the institute stored in being cached described in the terminal deletion State pending data.
5. according to the method described in claim 1, it is characterized in that, what is stored in being cached described in the terminal deletion described waits locating Data are managed, including:
If the data volume of the pending data is more than second threshold, what is stored in caching described in the terminal deletion described waits locating Manage data.
6. according to claim 1-5 any one of them methods, which is characterized in that the pending data is stored in by the terminal Before caching, further include:
The terminal judges whether the pending data meets preset condition;
It is cached if so, the pending data is stored in by the terminal.
7. according to the method described in claim 6, it is characterized in that, the preset condition includes:
The number of processes of pending data described in the terminal-pair is more than first threshold, the size of the pending data is more than the The performance of two threshold values, the memory headroom deficiency third threshold value of the terminal or the terminal is unsatisfactory for preset standard.
8. a kind of data processing equipment, which is characterized in that including:
Acquisition module, for obtaining pending data;
Cache module is cached for the pending data to be stored in;
Processing module, for handling the pending data in the caching;
Removing module, for deleting the pending data stored in the caching.
9. a kind of electronic equipment, which is characterized in that including:
Processor;And
Memory, the executable instruction for storing the processor;
Wherein, the processor is configured to carry out any numbers of perform claim requirement 1-7 via the execution executable instruction According to processing method.
10. a kind of computer readable storage medium, is stored thereon with computer program, which is characterized in that the computer program Claim 1-7 any data processing methods are realized when being executed by processor.
CN201810450123.3A 2018-05-11 2018-05-11 Data processing method, device, electronic equipment and storage medium Pending CN108733489A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810450123.3A CN108733489A (en) 2018-05-11 2018-05-11 Data processing method, device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810450123.3A CN108733489A (en) 2018-05-11 2018-05-11 Data processing method, device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN108733489A true CN108733489A (en) 2018-11-02

Family

ID=63937325

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810450123.3A Pending CN108733489A (en) 2018-05-11 2018-05-11 Data processing method, device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN108733489A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111935497A (en) * 2020-09-18 2020-11-13 武汉中科通达高新技术股份有限公司 Video stream management method and data server for traffic police system
CN112445827A (en) * 2020-11-26 2021-03-05 中孚信息股份有限公司 Data security processing system, method and device in cloud office environment

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102622347A (en) * 2011-01-26 2012-08-01 腾讯科技(深圳)有限公司 Image management method and movable terminal
CN104808952A (en) * 2015-05-05 2015-07-29 百度在线网络技术(北京)有限公司 Data caching method and device
CN105095107A (en) * 2014-05-04 2015-11-25 腾讯科技(深圳)有限公司 Buffer memory data cleaning method and apparatus

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102622347A (en) * 2011-01-26 2012-08-01 腾讯科技(深圳)有限公司 Image management method and movable terminal
CN105095107A (en) * 2014-05-04 2015-11-25 腾讯科技(深圳)有限公司 Buffer memory data cleaning method and apparatus
CN104808952A (en) * 2015-05-05 2015-07-29 百度在线网络技术(北京)有限公司 Data caching method and device

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111935497A (en) * 2020-09-18 2020-11-13 武汉中科通达高新技术股份有限公司 Video stream management method and data server for traffic police system
CN111935497B (en) * 2020-09-18 2021-01-12 武汉中科通达高新技术股份有限公司 Video stream management method and data server for traffic police system
CN112445827A (en) * 2020-11-26 2021-03-05 中孚信息股份有限公司 Data security processing system, method and device in cloud office environment

Similar Documents

Publication Publication Date Title
CN111352861B (en) Memory compression method and device and electronic equipment
CN103473142B (en) Virtual machine migration method under a kind of cloud computing operating system and device
CN109614377A (en) File delet method, device, equipment and the storage medium of distributed file system
EP3958120A1 (en) Method and device for anonymous page management, terminal device, and readable storage medium
US10437519B2 (en) Method and mobile terminal for processing write request
CN107943854B (en) Credit investigation service query method, apparatus and computer readable storage medium
CN110780823B (en) Small object memory management method, small object memory management device, electronic equipment and computer readable medium
CN110109868A (en) Method, apparatus and computer program product for index file
CN110209493A (en) EMS memory management process, device, electronic equipment and storage medium
CN108052396A (en) A kind of resource allocation methods and system
CN112529994B (en) Three-dimensional model graph rendering method, electronic device and readable storage medium thereof
CN108733489A (en) Data processing method, device, electronic equipment and storage medium
US10657678B2 (en) Method, apparatus and device for creating a texture atlas to render images
CN110727607A (en) Memory recovery method and device and electronic equipment
CN101877666A (en) Method and device for receiving multi-application program message based on zero copy mode
CN110399101A (en) A kind of Write-operation process method of disk, device, system and storage medium
CN108549534B (en) Graphical user interface redrawing method, terminal device and computer-readable storage medium
CN110908797B (en) Call request data processing method, device, equipment, storage medium and system
CN115421919A (en) Memory management method and device, memory manager, equipment and storage medium
CN106201918A (en) A kind of method and system quickly discharged based on big data quantity and extensive caching
CN102270179B (en) For the data Storage and Processing method based on sheet unit and the system thereof of CAD system
CN112541140A (en) List loading method, terminal device, electronic device and storage medium
CN108259380A (en) Method, system and the ethernet controller of Frame processes
CN109710187A (en) Read command accelerated method, device, computer equipment and the storage medium of NVMe SSD main control chip
CN106537321A (en) Method and device for accessing file, and storage system

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