WO2017101344A1 - 数据下载方法、装置及终端 - Google Patents
数据下载方法、装置及终端 Download PDFInfo
- Publication number
- WO2017101344A1 WO2017101344A1 PCT/CN2016/088674 CN2016088674W WO2017101344A1 WO 2017101344 A1 WO2017101344 A1 WO 2017101344A1 CN 2016088674 W CN2016088674 W CN 2016088674W WO 2017101344 A1 WO2017101344 A1 WO 2017101344A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- data
- priority
- data file
- storage space
- downloading
- 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.)
- Ceased
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/06—Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L65/00—Network arrangements, protocols or services for supporting real-time applications in data packet communication
- H04L65/40—Support for services or applications
Definitions
- the present disclosure relates to the field of data download technologies, and in particular, to a data download method, apparatus, and terminal.
- the data file is generally downloaded to the user terminal device before viewing the downloaded local file. To enhance the user's visual or auditory experience.
- the user in the process of downloading data, the user generally downloads a data file or downloads multiple data files at the same time, and the data file causes the data file according to the download resource or the network speed difference of the data file during the download process.
- the download speed has changed, which may cause multiple data files downloaded by the user to be downloaded at different times.
- the data file that is downloaded at the same time if there is a user who needs to implement the data file that is first viewed or can be downloaded, it is likely that other data files are downloaded more frequently, and other data files are downloaded faster and occupy the terminal. Storage space, once the remaining storage space of the terminal is insufficient, the data file will be interrupted for download.
- the present disclosure provides a data download method, apparatus, and terminal.
- a data download method comprising:
- a data downloading apparatus comprising:
- a detecting unit configured to detect whether a first data download instruction of the first data file that needs to complete the download is received
- a space reservation unit configured to reserve a first storage space for the first data file when receiving the first data download instruction
- a downloading unit configured to download the first data file to the first storage space.
- a terminal comprising some or all of the units of a data downloading apparatus provided by the second aspect of the present disclosure.
- a terminal comprising:
- a memory for storing processor executable instructions
- processor is configured to:
- a non-transitory computer readable storage medium wherein the storage medium may store instructions that, when executed, may implement a data downloading method provided by the first aspect of the present invention Some or all of the steps in each implementation.
- a data downloading method provided by an embodiment of the present disclosure includes: detecting whether a first data downloading instruction of a first data file that needs to be downloaded is received; and receiving the first data downloading instruction The data file reserves a first storage space; the first data file is downloaded to the first storage space.
- the data information corresponding to the data file download is stored in the reserved storage space, so that the data information is downloaded.
- the data file is covered in the storage space, which effectively avoids the occurrence of data loss due to insufficient storage space in the terminal during the data file downloading process, and effectively improves the efficiency of data downloading.
- FIG. 1 is a schematic flowchart of a data downloading method according to an exemplary embodiment
- FIG. 2 is a schematic flowchart of a data downloading method step S101 according to an exemplary embodiment
- FIG. 3 is a schematic flowchart diagram of a data downloading method based on step S101 according to an exemplary embodiment
- FIG. 4 is a schematic flowchart of obtaining priorities of multiple data download instructions according to another exemplary embodiment
- FIG. 5 is a schematic flowchart of step S102 in a data downloading method according to an exemplary embodiment
- FIG. 6 is a schematic flowchart of step S103 in a data downloading method according to an exemplary embodiment
- FIG. 7 is a schematic structural diagram of a data download apparatus according to an exemplary embodiment
- FIG. 8 is a detailed structural diagram of another data downloading device downloading unit according to an exemplary embodiment
- FIG. 9 is a detailed structural diagram of a detecting unit according to an exemplary embodiment.
- FIG. 10 is a schematic structural diagram of still another data download apparatus according to an exemplary embodiment
- FIG. 11 is a schematic structural diagram of another data download apparatus according to an exemplary embodiment.
- FIG. 12 is a detailed structural diagram of a space reservation unit according to an exemplary embodiment
- FIG. 13 is a schematic structural diagram of a terminal according to an exemplary embodiment.
- FIG. 1 is a flowchart of a data downloading method, which is applied to a terminal, such as a mobile terminal, according to an exemplary embodiment.
- the method includes the following steps:
- step S101 it is detected whether a first data download instruction of the first data file that needs to be downloaded is received. Otherwise, the process ends and the data file can be downloaded according to the relevant technology.
- the terminal when downloading data, the terminal downloads one or more data files at the same time, for example, when the user clicks to download multiple data files, but in order to ensure that the user can complete the viewing after the download is completed.
- the data file needs to be downloaded.
- the data file is the first data file that needs to be downloaded in the present embodiment.
- the first data download instruction is a download instruction that needs to complete the first data file download and store in the terminal storage space.
- the first data download instruction is confirmed by detecting the identity identification identifier of the first data download instruction, and the identity identification identifier may be a character string, and the identity identification identifier may indicate that the server is capable of responding to the identity identifier of the downloaded data file.
- the first data downloading instruction may also be a data downloading instruction corresponding to the data file that the user does not specify, but is determined according to the time sequence of starting downloading of each data file when the user initially clicks the download, so that the downloading time is started.
- the earliest data file is the first data file.
- step S102 When receiving the first data download instruction of the first data file that needs to be completed, in step S102, a first storage space is reserved for the first data file.
- the first storage space is a storage space in the terminal that stores the first data file, and the first storage space is completely stored in the first storage space.
- the size is at least the same as the data size of the first data file, or slightly larger than the data size of the first data file. Therefore, after the first storage space needs to be reserved in the remaining storage space in the terminal, the data information corresponding to the downloaded first data file is conveniently stored in the first storage space.
- the size of the first storage space may be smaller than the remaining storage space of the memory in the terminal; of course, the size of the first storage space may also be greater than the remaining storage space of the memory in the terminal; if the first storage If the space is larger than the remaining storage space of the memory in the terminal, the user needs to clear unnecessary information in the terminal to ensure that the first storage space can be reserved, and the data information corresponding to the first data file is conveniently stored.
- step S103 the first data file is downloaded to the first storage space.
- the first storage space is data information for storing the first data file. Therefore, when the first data file is downloaded, the data information of the first data file can be stored in the downloading process.
- the first storage space may be stored in the first storage space after the data information of the first data file is completely downloaded.
- the first storage space is reserved in the remaining storage space of the terminal, so that the remaining storage space in the terminal is occupied, so that the data information corresponding to the first data file is used. After the download is completed, it can be stored in the first storage space, ensuring that the first data file can be completely downloaded, ensuring the user's viewing effect, and effectively improving the reliability of the data download and the user experience.
- FIG. 2 is a flowchart of another data downloading method according to an exemplary embodiment, where the data downloading method includes the following steps:
- step S1011 a data download instruction of a plurality of data files transmitted by the user is received.
- the user may receive multiple data download instructions of multiple data files at the same time, or receive a data download instruction of a data file; when receiving a data download instruction of a data file, the user may directly perform step S102. Just fine.
- step S1012 When receiving the data download instruction of the plurality of data files, in step S1012, the priority of the data download instruction corresponding to the plurality of data files is acquired.
- the priority of the data downloading instruction is that the data file corresponding to the data downloading instruction is preferentially downloaded and stored in the terminal.
- the data downloading instruction may carry a priority identification identifier, and the priority identification is performed.
- the identifier can be a string, and the identifier string is determined by the priority identifier. The priority of the data download instruction, thereby determining the priority when downloading the data file corresponding to the data download instruction.
- the priority identification identifier is a time identifier in which the data file starts to be downloaded
- the priority identification identifiers of the two data download instructions are the first time identifier and the second time identifier, respectively, and the time indicated by the first time identifier is earlier than
- the time indicated by the second time identifier indicates that the data download instruction corresponding to the first time identifier has a higher priority than the data download instruction corresponding to the second time identifier.
- step S1013 the data file corresponding to the data download instruction with the highest priority is determined to be the first data file, and it is determined that the first data download instruction is received.
- the priority of the data download instruction corresponding to the plurality of data files is obtained in step S1012, so that the priority of the data file download can be known, and the data with the highest priority can be determined according to the priority.
- the data file corresponding to the download instruction is the first data file that the user needs to complete the download in the embodiment of the present disclosure, so as to determine that the data download instruction corresponding to the first data file is received, and the data download instruction is the step described in step S101.
- the first data download instruction is the step described in step S101.
- the first data file and the first data download instruction proposed in the embodiment of the present disclosure do not indicate the priority of the data, and the main purpose is to distinguish the data files that the user needs to download preferentially when the plurality of data files exist simultaneously. Different data files are distinguished.
- the priority of the data file downloading can be determined from the data downloading instructions corresponding to the plurality of data files, thereby determining the data file that needs to be downloaded, and storing the data file corresponding to the reserved first storage space, thereby effectively avoiding more
- the data files are downloaded at the same time, and the highest priority data download and storage cannot be determined, which effectively improves the reliability of data download.
- the present disclosure also provides another embodiment of the data downloading method.
- the flow chart of the download method As shown in FIG. 3, the method may include the following steps:
- Step S1014 Receive a priority change instruction sent from the user.
- the priority change instruction is an instruction for the user to change the data file download priority sent by the user, and the changed data file is determined to be the user by changing the priority of the data file download. Need to complete the data file downloaded and stored.
- step S1015 the identification identifier carried by the priority change instruction is extracted.
- the priority change instruction may include an identification identifier indicating an identifier of the data download instruction, and confirming, by the identity identification identifier, which data download instruction corresponding to the data file is changed by the priority change instruction.
- the identification identifier may be a character string, for example, the identity identifier is a four-digit binary string, such as 0010.
- step S1016 a data download instruction matching the identification identifier is queried.
- the data downloading instruction may be pre-stored with its own identification identifier, and the identification identifier is the same as the identifier, or may be a character string. After receiving the identity identification identifier, the character string of the identification identifier is obtained, and the identifier is obtained.
- the identification identifier of the data download instruction downloaded by all the data files determines that the same data download instruction as the identification identifier is the data file whose priority needs to be changed. For example, the character strings of the data downloading commands A, B, and C corresponding to the three data files respectively are 0010, 0011, and 0100. If the identity identification identifier of the priority change command received is 0011, the corresponding query is performed.
- the data file that needs to be changed in priority is the data file corresponding to the data download instruction B.
- step S1017 the data download instruction matching the identification identifier is changed to the first data download instruction having the highest priority.
- the priority of the data download instruction may be changed, and the download priority of the data file corresponding to the data download instruction is changed to the highest priority. Therefore, the data file is stored in the generated first storage space after the data download is completed.
- the user When the data file is simultaneously downloaded, the user is used to indicate the storage priority of a certain data file, so as to generate a matching first storage space corresponding to the data file, so that the data file can be downloaded.
- the data file After being stored in the first storage space, the data file is prevented from being downloaded due to other files occupying the storage space in the terminal during the downloading process, thereby causing data loss, thereby effectively improving the reliability of data downloading.
- the step S1012 may include, for example, Next steps:
- step S10121 When receiving the data download instruction of the plurality of data files, in step S10121, the priority identification identifier of the data download instruction is extracted.
- the data download instruction may be pre-stored with a priority identification identifier, and the priority identification identifier may be a character string.
- the priority identification identifier may include a time identification bit and a priority identification bit, and the priority identification bit has a higher priority than the time identification bit.
- step S10122 the priority of the plurality of data download instructions is determined according to the priority identification identifier.
- the priority of the data file downloading may refer to only the time identifier of the priority identification identifier. For example, the earlier the download time is, the higher the priority is, and the priority identification identifier is prioritized.
- the characters of the level flag are the same; if the priority of the data download instruction needs to be changed, the highest priority can be obtained by changing the character of the priority flag to distinguish the priority identification of other data download instructions, for example: three data download instructions
- the downloading time of A, B, and C starts increasing sequentially (that is, the data downloading instruction A is earlier than the data downloading instructions B and C), and the characters of the priority marking bits corresponding to the data downloading instructions A, B, and C are the same. 0, this indicates that the data download command A has the highest priority.
- the character of the priority flag corresponding to the data download command B is changed to 1, and the data is now
- the download instruction B has the highest priority, and the data download instructions A and C can still be arranged according to the priority of the time stamp bits.
- the priority of the data downloading instruction can be distinguished by the time identification bit in the priority identification identifier of the data downloading instruction and the priority level of the priority identification bit itself, and the characters in the bit are identified according to the time identification bit or the priority level.
- the string determines the priority of the data download instruction, and finally determines the priority order of all data download instructions, and further determines the highest priority data download instruction.
- FIG. 5 a schematic flowchart of another data downloading method is provided in the embodiment of the present disclosure, where the method includes the following steps:
- Step S1021 Acquire a size of the storage space of the first data file.
- the first storage space corresponding to the first data file needs to be reserved for storing the first data file. Since the size of the generated first storage space should be at least the same as the file size of the first data file, it is necessary to obtain the size of the storage space of the first data file.
- the data download instruction of the data file may include the file size of the corresponding data file, or the file size identifier of the data file carried in the data download instruction, and the file size of the data file is stored (general case)
- the file size of the data file is the size of the storage space of the data file, so that after receiving the first data download instruction, the size of the storage space of the data file corresponding to the data download instruction can be directly obtained.
- step S1022 When the size of the first data file storage space is obtained, in step S1022, a virtual data file is generated.
- the data information of the first data file can be completely downloaded and stored in the terminal.
- a virtual data file needs to be generated, and the virtual data file also occupies the storage space of the terminal memory, but the virtual data file does not have substantial data information, and the first After the data file is downloaded, the virtual data file is overwritten and stored in the storage space occupied by the virtual data file.
- the size of the virtual data file storage space is the same as the storage space of the first data file, so that the data information that facilitates the first data file download can be completely stored in the storage space occupied by the virtual data file.
- the virtual data file is stored in step S1023.
- step S1022 a virtual data file having the same size as the first data file storage space is generated, so that the virtual data file is stored in the memory of the terminal, and the storage space occupied by the virtual data file is occupied by the storage, and the occupied storage space is occupied. That is, it is a first storage space for storing data information corresponding to the first data file.
- the storage space of the terminal memory is occupied by generating a virtual data file, and the storage space is a storage space for storing the first data file that needs to be downloaded, thereby ensuring that the first data file can be downloaded.
- FIG. 6 is a flowchart of still another data downloading method according to an exemplary embodiment, where the data downloading method includes the following steps:
- step S1031 a data stream corresponding to the first data file is extracted.
- step S1032 the data information corresponding to the data stream is acquired.
- the data stream corresponds to the data information of the first data file, so that the corresponding data information is sequentially acquired through the data stream, until all the data information corresponding to the first data file is completely downloaded, thereby
- the data information downloaded by the data file is stored in the first storage space such that the first data file completely covers the virtual data file.
- the corresponding data information is obtained according to the data flow of the first data file, so that the data information is stored in the first storage that has been generated.
- the space it is avoided that other data files occupy the storage space in the terminal, which effectively solves the problem that the terminal suddenly has no storage space during the data file downloading process and cannot continue to download data information, resulting in data loss.
- FIG. 7 is a block diagram of a device for downloading data according to an exemplary embodiment.
- the data downloading device can be applied to a terminal, such as a mobile phone or a tablet computer.
- the apparatus includes a detecting unit 10, a space reserve unit 20, and a download unit 30.
- the detecting unit 10 is configured to detect whether a first data download instruction sent by the user that needs to complete the downloading of the first data file is received;
- the space reservation unit 20 is configured to reserve a first storage space for the first data file when receiving the first data download instruction
- the download unit 30 is configured to download the first data file to the first storage space.
- the size of the first storage space reserved by the space reservation unit 20 is the same as the storage space size of the first data file, where the first storage space is used to store data information corresponding to the first data file, and the first A storage space is less than or equal to the size of the remaining storage space of the terminal.
- the first storage space for storing the first data file is reserved in the remaining storage space in the terminal.
- the storage space of the first data file is pre-empted in the terminal memory, so that the first data file that the user needs to download is successfully downloaded, and the data in the first data file cannot be downloaded due to the lack of storage space in the terminal memory.
- the download unit 30 of the device includes: a second extraction subunit 31 and a second acquisition subunit 32, the first The extraction subunit 31 is electrically connected to the second acquisition subunit 32.
- the second extraction subunit 31 is configured to extract a data stream corresponding to the first data file
- the second obtaining sub-unit 32 is configured to acquire data information corresponding to the data stream corresponding to the first data file, and store the data information in the first storage space.
- the device stores the first data file that the user needs to complete the download in the generated first storage space, and improves the integrity of the data file download by occupying the storage space of the terminal memory in advance.
- the above detecting unit 10 may include: a first receiving subunit 11, a priority acquiring subunit 12, and a determining receiving subunit 13.
- the first receiving subunit 11 is configured to receive a data download instruction of a plurality of data files sent by a user;
- the priority acquisition sub-unit 12 is configured to acquire a priority of a data download instruction corresponding to each of the plurality of data files;
- the receiving subunit 13 is configured to determine that the data file corresponding to the highest priority data download instruction is the first data file that needs to be downloaded, and determines that the first data download instruction is received.
- the priority of the data download instruction may be set according to the start download time of the data file, and the earlier the data file starts to download, the higher the priority of the data download instruction corresponding to the data file. Therefore, it is determined that the data file with the earliest downloading time is the highest priority data file, so that a matching first storage space is generated for the data file for storing the data file.
- the apparatus may further include: a second receiving subunit 14, a first extracting subunit 15, an instruction query unit 16, and an instruction changing unit 17.
- the second receiving subunit 14 is configured to receive a priority change instruction sent from a user;
- the priority change instruction is used to change the priority of the data download instruction corresponding to the plurality of data files;
- the first extraction sub-unit 15 is configured to extract an identity identification identifier carried by the priority change instruction; wherein the identity identification identifier may represent a corresponding data download instruction;
- the instruction query unit 16 is configured to query a data download instruction that matches the identification identifier
- the instruction change unit 17 is configured to change the data download command to the first data download command having the highest priority.
- the priority identifier is set in the data downloading instruction, and the priority identifier includes a time identifier and a priority identifier, and the priority identifier indicates a priority higher than a priority indicated by the time identifier.
- the time identifier bit can be expressed as the time when the data file starts to be downloaded, and the earlier the data file starts to download, the higher the priority, the priority flag can be changed by simple assignment.
- the priority acquisition sub-unit 12 includes an identification flag extraction unit 121 and a priority determination unit 122. among them,
- the identification identifier extraction unit 121 is configured to extract a priority identification identifier of the data download instruction, where the priority identification identifier includes a time identification bit and a priority identification bit, and the priority identification bit has a higher priority than the The priority of the time stamp bit;
- the priority determining unit 122 is configured to determine a priority of the plurality of the data downloading instructions based on the priority identifying identifier.
- the space reservation unit 20 includes a first acquisition subunit 21, a generation subunit 22, and a storage subunit 23.
- the first obtaining sub-unit 21 is configured to acquire the size of the first data file storage space; wherein the size of the first data file storage space is the same as the size of the generated first storage space;
- the generating sub-unit 22 is configured to generate a virtual data file; wherein the size of the storage space occupied by the virtual data file is the same as the size of the first data file storage space;
- the storage sub-unit 23 is configured to store the virtual data file, and the storage space corresponding to the virtual data file is the first storage space.
- the embodiment of the present disclosure further provides a terminal, which includes some or all of the modules in each implementation manner of the data downloading device provided by the embodiment shown in FIG. 7 to FIG. 12 .
- FIG. 13 is a schematic structural diagram of a terminal 800 according to an exemplary embodiment.
- the terminal 800 can be a mobile terminal, such as a mobile phone or a tablet computer, and the terminal 800 can also be a terminal device such as a computer or the like.
- a terminal may include one or more of the following components: a processing component, a memory, a power component, a multimedia component, an audio component, an input/output (I/O) interface, a sensor component, and a communication component.
- Processing component 802 typically controls the overall operation of terminal 800, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations.
- Processing component 802 can include one or more processors 820 to execute instructions to perform all or part of the steps of the above described methods.
- processing component 802 can include one or more modules to facilitate interaction between component 802 and other components.
- processing component 802 can include a multimedia module to facilitate interaction between multimedia component 808 and processing component 802.
- Memory 804 is configured to store various types of data to support operation at terminal 800. Examples of such data include instructions for any application or method operating on terminal 800, contact data, phone book data, messages, pictures, videos, and the like.
- the memory 804 can be implemented by any type of volatile or non-volatile storage device, or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read only memory (EEPROM), erasable.
- SRAM static random access memory
- EEPROM electrically erasable programmable read only memory
- EPROM Electrically erasable programmable read only memory
- PROM Programmable Read Only Memory
- ROM Read Only Memory
- Magnetic Memory Flash Memory
- Disk Disk or Optical Disk.
- Power component 806 provides power to various components of terminal 800.
- Power component 806 can include a power management system, one or more power sources, and other components associated with generating, managing, and distributing power for terminal 800.
- the multimedia component 808 includes a screen that provides an output interface between the terminal 800 and the user.
- the screen can include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen can be implemented as a touch screen to receive input signals from the user.
- the touch panel includes one or more touch sensors to sense touches, slides, and gestures on the touch panel. The touch sensor may sense not only the boundary of the touch or sliding action, but also the duration and pressure associated with the touch or slide operation.
- the multimedia component 808 includes a front camera and/or a rear camera. When the terminal 800 is in an operation mode such as a shooting mode or a video mode, The front camera and/or rear camera can receive external multimedia data. Each front and rear camera can be a fixed optical lens system or have focal length and optical zoom capabilities.
- the audio component 810 is configured to output and/or input an audio signal.
- the audio component 810 includes a microphone (MIC) that is configured to receive an external audio signal when the terminal 800 is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode.
- the received audio signal may be further stored in memory 804 or transmitted via communication component 816.
- the audio component 810 also includes a speaker for outputting an audio signal.
- the I/O interface 812 provides an interface between the processing component 802 and the peripheral interface module, which may be a keyboard, a click wheel, a button, or the like. These buttons may include, but are not limited to, a home button, a volume button, a start button, and a lock button.
- Sensor assembly 814 includes one or more sensors for providing terminal 800 with various aspects of status assessment.
- sensor component 814 can detect an open/closed state of terminal 800, a relative positioning of components, such as the display and keypad of terminal 800, and sensor component 814 can also detect a change in position of a component of terminal 800 or terminal 800. The presence or absence of contact of the user with the terminal 800, the orientation or acceleration/deceleration of the terminal 800 and the temperature change of the terminal 800.
- Sensor assembly 814 can include a proximity sensor configured to detect the presence of nearby objects without any physical contact.
- Sensor assembly 814 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications.
- the sensor assembly 814 can also include an acceleration sensor, a gyro sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
- Communication component 816 is configured to facilitate wired or wireless communication between terminal 800 and other devices.
- the terminal 800 can access a wireless network based on a communication standard such as WiFi, 2G or 3G, or a combination thereof.
- communication component 816 receives broadcast signals or broadcast associated information from an external broadcast management system via a broadcast channel.
- the communication component 816 also includes a near field communication (NFC) module to facilitate short range communication.
- NFC near field communication
- the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
- RFID radio frequency identification
- IrDA infrared data association
- UWB ultra-wideband
- Bluetooth Bluetooth
- terminal 800 may be implemented by one or more application specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable A gate array (FPGA), controller, microcontroller, microprocessor, or other electronic component implementation for performing the above methods.
- ASICs application specific integrated circuits
- DSPs digital signal processors
- DSPDs digital signal processing devices
- PLDs programmable logic devices
- FPGA field programmable A gate array
- controller microcontroller, microprocessor, or other electronic component implementation for performing the above methods.
- non-transitory computer readable storage medium comprising instructions, such as a memory 804 comprising instructions executable by processor 820 of terminal 800 to perform the above method.
- the non-transitory computer readable storage medium may be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, and an optical data storage device.
- a non-transitory computer readable storage medium when instructions in the storage medium are executed by a processor of a terminal, to enable a terminal to perform a data downloading method, the method comprising:
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Multimedia (AREA)
- Information Transfer Between Computers (AREA)
Abstract
本公开是关于一种数据下载方法、装置及终端,其中,该数据下载方法包括:检测是否接收到需要完成下载的第一数据文件的第一数据下载指令;当接收到所述第一数据下载指令时,为所述第一数据文件预留第一存储空间;将所述第一数据文件下载至所述第一存储空间。本公开实施例通过将对应该数据文件下载的数据信息存储在该预留的存储空间内,使得下载完数据信息的数据文件覆盖于该存储空间内,有效避免在数据文件下载过程中由于终端内存储空间不足无法继续下载造成数据丢失等现象的出现,有效提高数据下载的效率。
Description
本申请要求于2015年12月15日提交中国专利局、申请号为201510931609.5、发明名称为“数据下载方法、装置及终端”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
本公开涉及数据下载技术领域,尤其涉及一种数据下载方法、装置及终端。
用户为了保证在观看视频或听音乐过程中的流畅程度,如果涉及到数据文件较大的视频或音乐的话,一般都会选择将数据文件事先下载到用户终端设备上,然后再观看下载后的本地文件,从而提升用户的视觉或听觉体验。
相关技术中,在进行数据下载的过程中,用户一般会下载一个数据文件或者同时下载多个数据文件,数据文件在进行下载过程中根据数据文件的下载资源或网速差异等多少造成数据文件的下载速度发生有所改变,可能会造成用户同时下载的多个数据文件分别在不同时间内下载完成。在同时下载的数据文件中,如果有用户需要实现最先观看或能够下载完成的数据文件的情况下,很可能会因为其他数据文件下载资源较多,造成其他数据文件下载速度较快占用终端的存储空间,一旦终端剩余的存储空间不足,那么该数据文件就会中断下载。
目前,很有可能出现数据文件中断下载时间较长或其他原因造成该数据文件的数据包丢失,虽然可以通过暂停其他数据文件的下载或者删除其他无用数据等为该数据文件腾出存储空间,使得该数据文件能够继续下载,但是,在这种情况下还是有可能出现上述情况,即使最终数据文件下载完成也无法观看。
发明内容
为克服相关技术中存在的问题,本公开提供一种数据下载方法、装置及终端。
根据本公开实施例的第一方面,提供一种数据下载方法,该方法包括:
检测是否接收到需要完成下载的第一数据文件的第一数据下载指令;
当接收到所述第一数据下载指令时,为所述第一数据文件预留第一存储空间;
将所述第一数据文件下载至所述第一存储空间。
根据本公开实施例的第二方面,提供一种数据下载装置,该装置包括:
检测单元,用于检测是否接收到需要完成下载的第一数据文件的第一数据下载指令;
空间预留单元,用于当接收到所述第一数据下载指令时,为所述第一数据文件预留第一存储空间;
下载单元,用于将所述第一数据文件下载至所述第一存储空间。
根据本公开实施例的第三方面,提供一种终端,该终端包括本公开第二方面提供的一种数据下载装置的部分或全部单元。
根据本公开实施例的第四方面,提供一种终端,该终端包括:
处理器;
用于存储处理器可执行指令的存储器;
其中,所述处理器被配置为:
检测是否接收到需要完成下载的第一数据文件的第一数据下载指令;
当接收到所述第一数据下载指令时,为所述第一数据文件预留第一存储空间;
将所述第一数据文件下载至所述第一存储空间。
根据本公开实施例的第五方面,提供一种非临时性计算机可读存储介质,其中,该存储介质可存储有指令,该指令执行时可实现本发明第一方面提供一种数据下载方法的各实现方式中的部分或全部步骤。
本公开的实施例提供的技术方案可以包括以下有益效果:
本公开实施例提供的一种数据下载方法,包括:检测是否接收到需要完成下载的第一数据文件的第一数据下载指令;当接收到所述第一数据下载指令时,为所述第一数据文件预留第一存储空间;将所述第一数据文件下载至所述第一存储空间。
应用本公开实施例提供的方法,通过对需要完成下载的数据文件事先预留一个存储空间,从而将对应该数据文件下载的数据信息存储在该预留的存储空间内,使得下载完数据信息的数据文件覆盖于该存储空间内,有效避免在数据文件下载过程中由于终端内存储空间不足无法继续下载造成数据丢失等现象的出现,有效提高数据下载的效率。
应当理解的是,以上的一般描述和后文的细节描述仅是示例性和解释性的,并不能限制本公开。
此处的附图被并入说明书中并构成本说明书的一部分,示出了符合本发明的实施例,并与说明书一起用于解释本发明的原理。
为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,对于本领域普通技术人员而言,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。
图1为根据一示例性实施例提供的一种数据下载方法的流程示意图;
图2为根据一示例性实施例提供的数据下载方法步骤S101的流程示意图;
图3为根据一示例性实施例提供的基于步骤S101的数据下载方法的流程示意图;
图4为根据另一示例性实施例提供的获取多个数据下载指令的优先级的流程示意图;
图5为根据一示例性实施例提供的数据下载方法中步骤S102的流程示意图;
图6为根据一示例性实施例提供的数据下载方法中步骤S103的流程示意图;
图7为根据一示例性实施例提供的一种数据下载装置的结构示意图;
图8为根据一示例性实施例提供的另一种数据下载装置下载单元的详细结构示意图;
图9为根据一示例性实施例提供的检测单元的详细结构示意图;
图10为根据一示例性实施例提供的又一种数据下载装置的结构示意图;
图11为根据一示例性实施例提供的另一种数据下载装置的结构示意图;
图12为根据一示例性实施例提供的空间预留单元的详细结构示意图;
图13为根据一示例性实施例提供的一种终端的结构示意图。
这里将详细地对示例性实施例进行说明,其示例表示在附图中。下面的描述涉及附图时,除非另有表示,不同附图中的相同数字表示相同或相似的要素。以下示例性实施例中所描述的实施方式并不代表与本发明相一致的所有实施方式。相反,它们仅是与如所附权利要求书中所详述的、本发明的一些方面相一致的装置和方法的例子。
图1是根据一示例性实施例示出的一种数据下载方法的流程图,该方法应用在终端上,例如移动终端,该方法包括如下步骤:
在步骤S101中,检测是否接收到需要完成下载的第一数据文件的第一数据下载指令。否则,结束流程,可按照相关技术下载数据文件。
在本公开实施例中,终端在下载数据的时候,都会同时下载一个或多个数据文件,例如:当用户点击下载多个数据文件时,但是,为了保证能够在下载完成后能够完成查看自己想要查看的数据文件,则需要将该数据文件完成下载,该数据文件即为本实施例提出的需要完成下载的第一数据文件。该第一数据下载指令即为需要完成第一数据文件下载、并存储于终端存储空间的下载指令。通过检测第一数据下载指令的身份识别标识来确认是否接收到该第一数据下载指令,该身份识别标识可以为字符串,身份识别标识可以表示服务器能够响应下载的数据文件的身份识别标识。
另外,该第一数据下载指令也可以是用户没有指定的数据文件对应的数据下载指令,而是按照用户最初点击下载时,每个数据文件的开始下载的时间顺序来定,从而使得开始下载时间最早的数据文件即为第一数据文件。
当接收到需要完成下载的第一数据文件的第一数据下载指令时,在步骤S102中,为所述第一数据文件预留第一存储空间。
该第一存储空间即为存储第一数据文件的终端内的存储空间,为了保证第一数据文件下载完成的数据信息能够完全存储于该第一存储空间,该第一存储空间
的大小至少与第一数据文件的数据大小相同,或者略大于第一数据文件的数据大小。从而生成需要在该终端内剩余的存储空间中预留该第一存储空间后,从而便于将下载的第一数据文件对应的数据信息均存储于该第一存储空间。
另外,在本公开实施例中,该第一存储空间的大小可以小于终端内存储器的剩余存储空间;当然,该第一存储空间的大小也可以大于终端内存储器的剩余存储空间;如果第一存储空间大于终端内存储器的剩余存储空间,则需要用户清除一些终端内不必要的信息,保证能够预留出该第一存储空间,便于存储第一数据文件对应的数据信息。
在步骤S103中,将所述第一数据文件下载至所述第一存储空间。
该第一存储空间即为用于存储该第一数据文件的数据信息,因此,当下载该第一数据文件时,可以在下载的过程中即可将该第一数据文件的数据信息存储于该第一存储空间内;也可以在第一数据文件的数据信息全部下载完成后,存储于该第一存储空间内。
应用该方法,能够在下载该第一数据文件时,事先在终端的剩余存储空间中预留该第一存储空间,从而将终端内部分剩余存储空间占用,使得该第一数据文件对应的数据信息下载完成后能够存储在该第一存储空间内,保证该第一数据文件能够完全下载,保证用户观看效果,有效提高数据下载的可靠性和用户体验效果。
图2是根据一示例性实施例示出的另一种数据下载方法的流程图,该数据下载方法包括以下步骤:
在步骤S1011中,接收用户发送的多个数据文件的数据下载指令。
本公开实施例中,用户可以同时接收多个数据文件的多个数据下载指令,也可以接收一个数据文件的数据下载指令;当接收一个数据文件的数据下载指令时,则可以直接按照步骤S102执行即可。
当接收到多个数据文件的数据下载指令时,在步骤S1012中,获取所述多个数据文件分别对应的数据下载指令的优先级。
该数据下载指令的优先级即为该数据下载指令对应的数据文件优先完成下载并存储于终端的顺序,在本公开实施例中,该数据下载指令可以携带有优先级识别标识,该优先级识别标识可以为字符串,通过该优先级识别标识字符串判断
该数据下载指令的优先级,进而确定与数据下载指令对应的数据文件进行下载时的优先级。例如,该优先级识别标识为数据文件开始下载的时间标识时,如果两个数据下载指令的优先级识别标识分别为第一时间标识和第二时间标识,且第一时间标识表示的时间早于第二时间标识表示的时间,则表示该第一时间标识对应的数据下载指令的优先级高于第二时间标识对应的数据下载指令。
当获取到数据下载指令的优先级时,在步骤S1013中,确定优先级最高的数据下载指令对应的数据文件为所述第一数据文件,并确定接收到所述第一数据下载指令。
在本公开实施例中,步骤S1012中获取到多个数据文件分别对应的数据下载指令的优先级,从而便可知道数据文件下载的优先级,根据优先级的大小即可确定优先级最高的数据下载指令对应的数据文件即为本公开实施例中用户需要完成下载的第一数据文件,从而确定接收该第一数据文件对应的数据下载指令,且该数据下载指令即为步骤S101中所述的第一数据下载指令。
另外,在本公开实施例中提出的第一数据文件以及第一数据下载指令并非表示其优先级的高低,主要是为了区别多个数据文件同时存在时,将用户需要优先下载完成的数据文件与其他数据文件进行区分。
应用该方法,能够从多个数据文件对应的数据下载指令中确定数据文件下载的优先级,从而确定需要完成下载的数据文件,并对应预留第一存储空间存储该数据文件,从而有效避免多个数据文件同时下载、无法确定最高优先级数据下载并存储的情况,有效提高数据下载的可靠性。
上述实施例中提出的数据下载方法中,可以实现存在多个数据文件同时下载、且用户没有另外指定需要下载哪一个数据文件的情况,该优先级即可按照用户点击下载数据文件时的开始时间。但是,在实际操作过程中,用户很有可能根据需要随时改变数据文件下载的优先级,因此,本公开还提供了另外一种数据下载方法的实施例方式,具体可参看图3所示的数据下载方法的流程示意图。如图3所示,该方法可以包括如下步骤:
步骤S1014:接收来自用户发送的优先级变更指令。
在本公开实施例中,优先级变更指令为用户发送的用户变更数据文件下载优先级的指令,通过变更数据文件下载的优先级,确定该变更后的数据文件为用户
需要完成下载并存储的数据文件。
当接收到优先级变更指令,在步骤S1015中,提取所述优先级变更指令携带的身份识别标识。
该优先级变更指令中可以包括身份识别标识,该身份识别标识表示数据下载指令的标识,通过身份识别标识确认该优先级变更指令用于变更哪一个数据文件对应的数据下载指令。在本公开实施例中,该身份识别标识可以为字符串,例如,身份识别标识为四位二进制字符串,如0010。
当提取到优先级变更指令的身份识别标识时,在步骤S1016中,查询与所述身份识别标识相匹配的数据下载指令。
其中,该数据下载指令中可以预先存储有自身的识别标识,且该识别标识与身份识别标识相同,也可以为字符串,接收到该身份识别标识后,获取该识别标识的字符串,通过查询所有数据文件下载的数据下载指令的识别标识,确定与该身份识别标识相同的数据下载指令即为需要变更优先级的数据文件。例如:目前有三个数据文件的数据下载指令A、B和C分别对应的识别标识的字符串为0010、0011和0100,如果接收到的该优先级变更指令的身份识别标识为0011,则对应查询的需要更改优先级的数据文件为数据下载指令B对应的数据文件。
当查询到与所述身份识别标识相匹配的数据下载指令时,在步骤S1017中,将与所述身份识别标识相匹配的数据下载指令变更为优先级最高的第一数据下载指令。
本公开实施例中,在查询到需要变更下载优先级的数据下载指令后,即可更改该数据下载指令的优先级,将该数据下载指令对应的数据文件的下载优先级变为最高优先级,从而使该数据文件完成数据下载之后存储于生成的第一存储空间内。
应用该方法,能够在多个数据文件同时下载时,用户用于指示某个数据文件的存储优先级,从而为该数据文件对应生成一匹配的第一存储空间,便于该数据文件能够在下载完成后存储于该第一存储空间,从而避免数据文件在下载过程中因为其他文件占用终端内的存储空间导致该数据文件无法完成下载、造成数据丢失的情况,从而有效提高数据下载的可靠性。
基于图3之上,在本公开实施例中,如图4所示,该步骤S1012可以包括如
下步骤:
当接收到多个数据文件的数据下载指令时,在步骤S10121中,提取所述数据下载指令的优先级识别标识。
其中,在本实施例中,该数据下载指令可以预先存储有优先级识别标识,该优先级识别标识可以为字符串。该优先级识别标识可以包括时间标识位和优先级标识位,且优先级标识位的优先级高于时间标识位的优先级,当接收到多个数据文件的数据下载指令时,需要分别提取每一个数据文件对应的数据下载指令的优先级识别标识。
当提取到所述优先级识别标识,在步骤S10122中,根据所述优先级识别标识,确定多个所述数据下载指令的优先级。
在本公开实施例中,通常情况下,数据文件下载时的优先级可以仅参考优先级识别标识的时间标识位,如开始下载时间越早优先级越高,且此时优先级识别标识的优先级标识位的字符均相同;如果需要变更数据下载指令的优先级,则可通过改变优先级标识位的字符区别其他数据下载指令的优先级识别标识获得最高优先权,例如:三个数据下载指令A、B、C开始下载时间依次增大(即数据下载指令A的时间早于数据下载指令B和C),且数据下载指令A、B、C分别对应的优先级标识位的字符相同均为0,此时则表示数据下载指令A的优先级最高,当需要变更数据下载指令C的优先级时,则将该数据下载指令B对应的优先级标识位的字符变更为1,则此时数据下载指令B的优先级最高,数据下载指令A和C可以仍按照时间标识位的优先级排列。
上述实施方式仅为解释该实施例列举的优选实施例方式,在具体实施过程中并不限于上述实施方式,其他相同或相近的实施方式都归为本公开实施例,在此不再详述。
应用该方法,能够通过数据下载指令的优先级识别标识中的时间标识位和优先级标识位自身的优先级级别区分数据下载指令的优先级,并根据时间标识位或优先级标识位内的字符串确定数据下载指令的优先级,最终确定所有数据下载指令的优先级次序,进一步可以确定出最高优先级的数据下载指令。
如图5所示,为本公开实施例提供了另外一种数据下载方法的流程示意图,该方法包括如下步骤:
步骤S1021:获取所述第一数据文件存储空间的大小。
当确定接收到用户需要完成下载的第一数据文件的第一数据下载指令时,需要预留与该第一数据文件相对应的第一存储空间,用于存储该第一数据文件。由于生成的该第一存储空间的大小至少应该与第一数据文件的文件大小相同,因此,需要通过获取该第一数据文件的存储空间的大小。
另外,在本公开实施例中,数据文件的数据下载指令可以包括对应的数据文件的文件大小,或者,数据下载指令中携带有数据文件的文件大小标识,存储该数据文件的文件大小(一般情况下,数据文件的文件大小即为数据文件存储的存储空间的大小),从而接收到该第一数据下载指令后,可以直接获取该数据下载指令对应的数据文件的存储空间的大小。
当获取到第一数据文件存储空间的大小时,在步骤S1022中,生成一虚拟数据文件。
在本公开实施例中,为了保证终端的存储器中具有存储该第一数据文件的存储空间,使得该第一数据文件的数据信息能够完整下载,并存储于终端内。为了保证具有能够存储该第一数据文件的存储空间,需要生成一虚拟数据文件,该虚拟数据文件同样占用该终端存储器的存储空间,只是该虚拟数据文件内部没有实质的数据信息,需要该第一数据文件下载完成后覆盖掉该虚拟数据文件,从而存储于该虚拟数据文件所占用的存储空间。
另外,该虚拟数据文件存储空间的大小与第一数据文件的存储空间的大小相同,从而,便于第一数据文件下载的数据信息能够完全存储于该虚拟数据文件所占用的存储空间内。
当生成所述虚拟数据文件时,在步骤S1023中,存储所述虚拟数据文件。
在步骤S1022中,生成与第一数据文件存储空间大小相同的虚拟数据文件,从而将该虚拟数据文件存储于该终端的存储器,通过存储该虚拟数据文件占用存储器的存储空间,且占用的存储空间即为用于存储第一数据文件对应数据信息的第一存储空间。
应用该方法,通过生成虚拟数据文件来占用终端存储器的存储空间,且该存储空间即为用于存储需要完成下载的第一数据文件对应存储的存储空间,从而保证第一数据文件能够完成下载。
图6是根据一示例性实施例示出的又一种数据下载方法的流程图,该数据下载方法包括以下步骤:
在步骤S1031中,提取所述第一数据文件对应的数据流。
当生成第一存储空间,或者生成虚拟数据文件并将该虚拟数据文件存储于终端存储器后,提取该第一数据文件的数据流,该数据流即对应该第一数据文件需要下载的数据预先存储的具有顺序的被读取一次数据的序列。
当提取到所述第一数据文件对应的数据流时,在步骤S1032中,获取所述数据流对应的数据信息。
在本公开实施例中,该数据流对应第一数据文件的数据信息,从而通过数据流依次获取对应的数据信息,直到该第一数据文件对应的所有数据信息全部被下载完成,从而将该第一数据文件下载的数据信息存储到该第一存储空间内,使得该第一数据文件完全覆盖该虚拟数据文件。
通过上述实施方式,生成与第一数据文件的存储空间大小相同的第一存储空间之后,根据第一数据文件的数据流获取相应的数据信息,从而将数据信息均存储于已经生成的第一存储空间内,避免被其他数据文件占用终端内的存储空间,有效解决数据文件下载过程中终端突然没有存储空间而无法继续下载数据信息,导致数据丢失的问题。
图7是根据一示例性实施例示出的一种数据下载的装置框图。该数据下载装置可以应用于终端中,例如:手机或平板电脑等。参考图7,该装置包括检测单元10、空间预留单元20和下载单元30。
该检测单元10被配置为检测是否接收到用户发送的需要完成下载的第一数据文件的第一数据下载指令;
空间预留单元20被配置为当接收到所述第一数据下载指令时,为所述第一数据文件预留第一存储空间;
下载单元30被配置为将所述第一数据文件下载至所述第一存储空间。
其中,该空间预留单元20预留的第一存储空间的大小与该第一数据文件的存储空间大小相同,该第一存储空间用于存储该第一数据文件对应的数据信息,且该第一存储空间小于或等于终端剩余存储空间的大小。
当应用该装置时,如果用户需要下载数据文件,为了避免下载数据文件时其他数据文件占用终端存储器的存储空间,从而在终端中剩余存储空间中预留存储第一数据文件的第一存储空间,使得终端存储器中事先占用第一数据文件的存储空间,能够保证用户需要下载的第一数据文件下载成功,避免下载中途由于终端存储器没有存储空间无法下载、第一数据文件中数据信息丢失的情况。
在本公开一实施例中,在图7所示实施例的基础上,如图8所示,该装置的下载单元30包括:第二提取子单元31和第二获取子单元32,该第一提取子单元31与第二获取子单元32电连接。
该第二提取子单元31被配置为提取第一数据文件对应的数据流;
该第二获取子单元32被配置为获取第一数据文件对应的数据流对应的数据信息,并将该数据信息存储于第一存储空间。
应用该装置,将用户需要完成下载的第一数据文件存储于生成的第一存储空间,通过提前占用终端存储器存储空间的方式,提高数据文件下载的完整性。
在本公开另一实施例中,如图9所示,上述检测单元10可以包括:第一接收子单元11、优先级获取子单元12和确定接收子单元13。
该第一接收子单元11被配置为接收用户发送的多个数据文件的数据下载指令;
优先级获取子单元12被配置为获取多个数据文件分别对应的数据下载指令的优先级;
确定接收子单元13被配置为确定优先级最高的数据下载指令对应的数据文件为需要完成下载的第一数据文件,并确定接收到该第一数据下载指令。
在该装置中,数据下载指令的优先级可以按照数据文件的开始下载时间设定优先级,数据文件开始下载的时间越早,数据文件对应的数据下载指令的优先级越高。从而确定开始下载时间最早的数据文件为优先级最高的数据文件,从而针对该数据文件生成与之匹配的第一存储空间,用于存储该数据文件。
在图9所示实施例的基础上,如图10所示,该装置还可以包括:第二接收子单元14、第一提取子单元15、指令查询单元16和指令变更单元17。
该第二接收子单元14被配置为接收来自用户发送的优先级变更指令;其中,
该优先级变更指令用于变更多个数据文件对应的数据下载指令的优先级;
第一提取子单元15被配置为提取所述优先级变更指令携带的身份识别标识;其中,该身份识别标识可以表示相应的数据下载指令;
指令查询单元16被配置为查询与所述身份识别标识相匹配的数据下载指令;
指令变更单元17被配置为将所述数据下载指令变更为优先级最高的第一数据下载指令。
其中,该数据下载指令中设置有优先级识别标识,且该优先级识别标识包括时间标识位和优先级标识位,且优先级标识位表示的优先级高于时间标识位表示的优先级,该时间标识位可以表示为数据文件开始下载的时间,且数据文件开始下载的时间越早优先级越高,该优先级标识位可以通过简单赋值的方式改变优先级。
基于上述图9之上,如图11所示,该优先级获取子单元12包括识别标识提取单元121和优先级确定单元122。其中,
该识别标识提取单元121被配置为提取所述数据下载指令的优先级识别标识,所述优先级识别标识包括时间标识位和优先级标识位,且所述优先级标识位的优先级高于所述时间标识位的优先级;
优先级确定单元122被配置为根据所述优先级识别标识,确定多个所述数据下载指令的优先级。
在本公开另一实施例中,如图12所示,上述空间预留单元20包括:第一获取子单元21、生成子单元22和存储子单元23。
该第一获取子单元21被配置为获取所述第一数据文件存储空间的大小;其中,该第一数据文件存储空间的大小与生成的第一存储空间的大小相同;
生成子单元22被配置为生成一虚拟数据文件;其中,该虚拟数据文件的所占的存储空间的大小与该第一数据文件存储空间的大小相同;
存储子单元23被配置为存储该虚拟数据文件,且该虚拟数据文件对应的存储空间为第一存储空间。
关于上述实施例中的装置,其中各个单元执行操作的具体方式已经在有关该方法的实施例中进行了详细描述,此处将不做详细阐述说明。
本公开实施例还提供了一种终端,该终端包括本公开图7-图12所述实施例提供的一种数据下载装置的各实现方式中的部分或全部模块。
图13是根据一示例性实施例示出的一种终端800的结构示意图。例如,终端800可以是移动终端,如手机或平板电脑等,终端800也可以是终端设备,如计算机等。
参照图13,终端可以包括以下一个或多个组件:处理组件,存储器,电源组件,多媒体组件,音频组件,输入/输出(I/O)的接口,传感器组件,以及通信组件。
处理组件802通常控制终端800的整体操作,诸如与显示,电话呼叫,数据通信,相机操作和记录操作相关联的操作。处理组件802可以包括一个或多个处理器820来执行指令,以完成上述的方法的全部或部分步骤。此外,处理组件802可以包括一个或多个模块,便于处理组件802和其他组件之间的交互。例如,处理组件802可以包括多媒体模块,以方便多媒体组件808和处理组件802之间的交互。
存储器804被配置为存储各种类型的数据以支持在终端800的操作。这些数据的示例包括用于在终端800上操作的任何应用程序或方法的指令,联系人数据,电话簿数据,消息,图片,视频等。存储器804可以由任何类型的易失性或非易失性存储设备或者它们的组合实现,如静态随机存取存储器(SRAM),电可擦除可编程只读存储器(EEPROM),可擦除可编程只读存储器(EPROM),可编程只读存储器(PROM),只读存储器(ROM),磁存储器,快闪存储器,磁盘或光盘。
电源组件806为终端800的各种组件提供电力。电源组件806可以包括电源管理系统,一个或多个电源,及其他为终端800生成、管理和分配电力相关联的组件。
多媒体组件808包括在所述终端800和用户之间的提供一个输出接口的屏幕。在一些实施例中,屏幕可以包括液晶显示器(LCD)和触摸面板(TP)。如果屏幕包括触摸面板,屏幕可以被实现为触摸屏,以接收来自用户的输入信号。触摸面板包括一个或多个触摸传感器以感测触摸、滑动和触摸面板上的手势。所述触摸传感器可以不仅感测触摸或滑动动作的边界,而且还检测与所述触摸或滑动操作相关的持续时间和压力。在一些实施例中,多媒体组件808包括一个前置摄像头和/或后置摄像头。当终端800处于操作模式,如拍摄模式或视频模式时,
前置摄像头和/或后置摄像头可以接收外部的多媒体数据。每个前置摄像头和后置摄像头可以是一个固定的光学透镜系统或具有焦距和光学变焦能力。
音频组件810被配置为输出和/或输入音频信号。例如,音频组件810包括一个麦克风(MIC),当终端800处于操作模式,如呼叫模式、记录模式和语音识别模式时,麦克风被配置为接收外部音频信号。所接收的音频信号可以被进一步存储在存储器804或经由通信组件816发送。在一些实施例中,音频组件810还包括一个扬声器,用于输出音频信号。
I/O接口812为处理组件802和外围接口模块之间提供接口,上述外围接口模块可以是键盘,点击轮,按钮等。这些按钮可包括但不限于:主页按钮、音量按钮、启动按钮和锁定按钮。
传感器组件814包括一个或多个传感器,用于为终端800提供各个方面的状态评估。例如,传感器组件814可以检测到终端800的打开/关闭状态,组件的相对定位,例如所述组件为终端800的显示器和小键盘,传感器组件814还可以检测终端800或终端800一个组件的位置改变,用户与终端800接触的存在或不存在,终端800方位或加速/减速和终端800的温度变化。传感器组件814可以包括接近传感器,被配置用来在没有任何的物理接触时检测附近物体的存在。传感器组件814还可以包括光传感器,如CMOS或CCD图像传感器,用于在成像应用中使用。在一些实施例中,该传感器组件814还可以包括加速度传感器,陀螺仪传感器,磁传感器,压力传感器或温度传感器。
通信组件816被配置为便于终端800和其他设备之间有线或无线方式的通信。终端800可以接入基于通信标准的无线网络,如WiFi,2G或3G,或它们的组合。在一个示例性实施例中,通信组件816经由广播信道接收来自外部广播管理系统的广播信号或广播相关信息。在一个示例性实施例中,所述通信组件816还包括近场通信(NFC)模块,以促进短程通信。例如,在NFC模块可基于射频识别(RFID)技术,红外数据协会(IrDA)技术,超宽带(UWB)技术,蓝牙(BT)技术和其他技术来实现。
在示例性实施例中,终端800可以被一个或多个应用专用集成电路(ASIC)、数字信号处理器(DSP)、数字信号处理设备(DSPD)、可编程逻辑器件(PLD)、现场可编程门阵列(FPGA)、控制器、微控制器、微处理器或其他电子元件实现,用于执行上述方法。
在示例性实施例中,还提供了一种包括指令的非临时性计算机可读存储介质,例如包括指令的存储器804,上述指令可由终端800的处理器820执行以完成上述方法。例如,所述非临时性计算机可读存储介质可以是ROM、随机存取存储器(RAM)、CD-ROM、磁带、软盘和光数据存储设备等。
一种非临时性计算机可读存储介质,当所述存储介质中的指令由终端的处理器执行时,使得终端能够执行一种数据下载方法,所述方法包括:
检测是否接收到需要完成下载的第一数据文件的第一数据下载指令;
如果接收到所述第一数据下载指令,生成与第一数据文件相对应的第一存储空间,所述第一存储空间用于存储所述第一数据文件对应的数据信息。
该存储介质中的指令在执行时,除了实现上述方法外,还可以实现图1-图6所示实施例提供的一种数据下载方法的各实现方式中的部分或全部步骤。
需要说明的是,在本文中,诸如“第一”和“第二”等之类的关系术语仅仅用来将一个实体或者操作与另一个实体或操作区分开来,而不一定要求或者暗示这些实体或操作之间存在任何这种实际的关系或者逆序。而且,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、装置或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、装置或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括所述要素的过程、方法、装置或者设备中还存在另外的相同要素。
本领域技术人员在考虑说明书及实践这里公开的发明后,将容易想到本发明的其它实施方案。本申请旨在涵盖本发明的任何变型、用途或者适应性变化,这些变型、用途或者适应性变化遵循本发明的一般性原理并包括本公开未公开的本技术领域中的公知常识或惯用技术手段。说明书和实施例仅被视为示例性的,本发明的真正范围和精神由下面的权利要求指出。
应当理解的是,本发明并不局限于上面已经描述并在附图中示出的精确结构,并且可以在不脱离其范围进行各种修改和改变。本发明的范围仅由所附的权利要求来限制。
Claims (12)
- 一种数据下载方法,其特征在于,包括:检测是否接收到需要完成下载的第一数据文件的第一数据下载指令;当接收到所述第一数据下载指令时,为所述第一数据文件预留第一存储空间;将所述第一数据文件下载至所述第一存储空间。
- 根据权利要求1所述的数据下载方法,其特征在于,所述检测是否接收到需要完成下载的第一数据文件的第一数据下载指令包括:接收用户发送的多个数据文件的数据下载指令;获取所述多个数据文件分别对应的数据下载指令的优先级;确定优先级最高的数据下载指令对应的数据文件为所述第一数据文件,并确定接收到所述第一数据下载指令。
- 根据权利要求2所述的数据下载方法,其特征在于,还包括:接收来自用户发送的优先级变更指令;提取所述优先级变更指令携带的身份识别标识;查询与所述身份识别标识相匹配的数据下载指令;将与所述身份识别标识相匹配的数据下载指令变更为优先级最高的第一数据下载指令。
- 根据权利要求2所述的数据下载方法,其特征在于,所述获取所述多个数据文件分别对应的数据下载指令的优先级包括:提取所述数据下载指令的优先级识别标识,所述优先级识别标识包括时间标识位和优先级标识位,且所述优先级标识位的优先级高于所述时间标识位的优先级;根据所述优先级识别标识,确定多个所述数据下载指令的优先级。
- 根据权利要求1所述的数据下载方法,其特征在于,所述为所述第一数据文件预留第一存储空间包括:获取所述第一数据文件存储空间的大小;生成一虚拟数据文件,所述虚拟数据文件与所述第一数据文件的存储空间大小相同;存储所述虚拟数据文件,所述虚拟数据文件对应的存储空间为所述第一存储空间。
- 一种数据下载装置,其特征在于,包括:检测单元,用于检测是否接收到需要完成下载的第一数据文件的第一数据下载指令;空间预留单元,用于当接收到所述第一数据下载指令时,为所述第一数据文件预留第一存储空间;下载单元,用于将所述第一数据文件下载至所述第一存储空间。
- 根据权利要求6所述的数据下载装置,其特征在于,所述检测单元包括:第一接收子单元,用于接收用户发送的多个数据文件的数据下载指令;优先级获取子单元,用于获取所述多个数据文件分别对应的数据下载指令的优先级;确定接收子单元,用于确定优先级最高的数据下载指令对应的所述第一数据文件,并确定接收到所述第一数据下载指令。
- 根据权利要求7所述的数据下载装置,其特征在于,所述装置还包括:第二接收子单元,用于接收来自用户发送的优先级变更指令;第一提取子单元,用于提取所述优先级变更指令携带的身份识别标识;指令查询单元,用于查询与所述身份识别标识相匹配的数据下载指令;指令变更单元,用于将与所述身份识别标识相匹配的数据下载指令变更为优先级最高的第一数据下载指令。
- 根据权利要求7所述的数据下载装置,其特征在于,所述优先级获取子单元包括:识别标识提取单元,用于提取所述数据下载指令的优先级识别标识,所述优先级识别标识包括时间标识位和优先级标识位,且所述优先级标识位的优先级高于所述时间标识位的优先级;优先级确定单元,用于根据所述优先级识别标识,确定多个所述数据下载指令的优先级。
- 根据权利要求6所述的数据下载装置,其特征在于,所述空间预留单元包括;第一获取子单元,用于获取所述第一数据文件存储空间的大小;生成子单元,用于生成一虚拟数据文件,所述虚拟数据文件与所述第一数据文件的存储空间大小相同;存储子单元,用于存储所述虚拟数据文件,所述虚拟数据文件对应的存储空间为所述第一存储空间。
- 一种终端,其特征在于,包括权利要求6-10任一项所述的数据下载装置。
- 一种终端,其特征在于,包括:处理器;用于存储处理器可执行指令的存储器;其中,所述处理器被配置为:检测是否接收到需要完成下载的第一数据文件的第一数据下载指令;当接收到所述第一数据下载指令时,为所述第一数据文件预留第一存储空间;将所述第一数据文件下载至所述第一存储空间。
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| US15/240,374 US20170171296A1 (en) | 2015-12-15 | 2016-08-18 | Method and electronic device for downloading data |
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201510931609.5A CN105897846A (zh) | 2015-12-15 | 2015-12-15 | 数据下载方法、装置及终端 |
| CN201510931609.5 | 2015-12-15 |
Related Child Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| US15/240,374 Continuation US20170171296A1 (en) | 2015-12-15 | 2016-08-18 | Method and electronic device for downloading data |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2017101344A1 true WO2017101344A1 (zh) | 2017-06-22 |
Family
ID=57002415
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2016/088674 Ceased WO2017101344A1 (zh) | 2015-12-15 | 2016-07-05 | 数据下载方法、装置及终端 |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN105897846A (zh) |
| WO (1) | WO2017101344A1 (zh) |
Families Citing this family (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN111402110A (zh) * | 2020-02-26 | 2020-07-10 | 无线生活(北京)信息技术有限公司 | 下载资源处理方法及装置 |
Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101098470A (zh) * | 2006-06-28 | 2008-01-02 | 腾讯科技(深圳)有限公司 | 一种基于p2p技术的流媒体节目播放/接收方法及装置 |
| CN101447207A (zh) * | 2008-12-30 | 2009-06-03 | 深圳华为通信技术有限公司 | 一种媒体录制方法及装置 |
| CN103488492A (zh) * | 2012-06-14 | 2014-01-01 | 中兴通讯股份有限公司 | 阅读器设备及其固件升级方法及装置 |
| CN103916693A (zh) * | 2014-04-02 | 2014-07-09 | 深圳如果技术有限公司 | 一种预留存储空间的方法及其装置 |
Family Cites Families (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| KR20040009097A (ko) * | 2002-07-22 | 2004-01-31 | 삼성전자주식회사 | 이동통신단말기에서 메모리 관리 장치 및 방법 |
| CN101997853A (zh) * | 2009-08-31 | 2011-03-30 | 中兴通讯股份有限公司 | 数据下载方法及终端 |
| CN102231163B (zh) * | 2011-06-30 | 2014-09-03 | 北京金山软件有限公司 | 将指定文件优先同步更新的系统及方法 |
| CN103581269A (zh) * | 2012-08-07 | 2014-02-12 | 百度在线网络技术(北京)有限公司 | 云端离线下载方法、系统及其装置 |
-
2015
- 2015-12-15 CN CN201510931609.5A patent/CN105897846A/zh active Pending
-
2016
- 2016-07-05 WO PCT/CN2016/088674 patent/WO2017101344A1/zh not_active Ceased
Patent Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101098470A (zh) * | 2006-06-28 | 2008-01-02 | 腾讯科技(深圳)有限公司 | 一种基于p2p技术的流媒体节目播放/接收方法及装置 |
| CN101447207A (zh) * | 2008-12-30 | 2009-06-03 | 深圳华为通信技术有限公司 | 一种媒体录制方法及装置 |
| CN103488492A (zh) * | 2012-06-14 | 2014-01-01 | 中兴通讯股份有限公司 | 阅读器设备及其固件升级方法及装置 |
| CN103916693A (zh) * | 2014-04-02 | 2014-07-09 | 深圳如果技术有限公司 | 一种预留存储空间的方法及其装置 |
Also Published As
| Publication number | Publication date |
|---|---|
| CN105897846A (zh) | 2016-08-24 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| JP6072362B2 (ja) | アプリケーションプログラムの処理方法、装置、プログラム及び記憶媒体 | |
| RU2637474C2 (ru) | Способ и устройство для управления фоновым приложением и терминальным устройством | |
| JP6423872B2 (ja) | ビデオ分類方法および装置 | |
| CN107066172B (zh) | 移动终端的文件传输方法及装置 | |
| WO2016029685A1 (zh) | 一种路由器管理应用与路由器固件的兼容方法和装置 | |
| WO2017071088A1 (zh) | 图像获取方法及装置 | |
| WO2016204993A1 (en) | Pairing of nearby devices using a synchronized cue signal | |
| CN109947671B (zh) | 一种地址转换方法、装置、电子设备及储存介质 | |
| WO2015123937A1 (zh) | 一种分屏处理方法、装置及计算机存储介质 | |
| US10001919B2 (en) | Apparatus for providing integrated functions of dial and calculator and method thereof | |
| WO2017088247A1 (zh) | 输入处理方法、装置及设备 | |
| WO2016011717A1 (zh) | 用于轻应用的消息推送方法、装置、终端及服务器 | |
| WO2016150104A1 (zh) | 应用主题的加载方法及装置 | |
| WO2015176483A1 (zh) | 标签创建方法、装置及终端 | |
| CN106203167A (zh) | 应用权限管理方法及装置 | |
| CN107491681B (zh) | 指纹信息处理方法及装置 | |
| CN104935613A (zh) | 场景同步方法、终端、服务器及系统 | |
| RU2632396C2 (ru) | Способ и устройство для управления подключаемым модулем маршрутизатора | |
| CN107463372B (zh) | 一种数据驱动的页面更新方法和装置 | |
| CN106383731B (zh) | 一种数据迁移方法及移动终端 | |
| JP2017510221A (ja) | アプリケーション起動方法、装置、プログラム及び記録媒体 | |
| CN111767006B (zh) | 数据处理方法及装置 | |
| US20150286361A1 (en) | Single gesture video capture and share | |
| WO2017101344A1 (zh) | 数据下载方法、装置及终端 | |
| US20170048292A1 (en) | Electronic device and method for providing content |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 16874406 Country of ref document: EP Kind code of ref document: A1 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |
|
| 122 | Ep: pct application non-entry in european phase |
Ref document number: 16874406 Country of ref document: EP Kind code of ref document: A1 |