[go: up one dir, main page]

CN106027597B - A kind of method and server of offline file transmission - Google Patents

A kind of method and server of offline file transmission Download PDF

Info

Publication number
CN106027597B
CN106027597B CN201610274784.6A CN201610274784A CN106027597B CN 106027597 B CN106027597 B CN 106027597B CN 201610274784 A CN201610274784 A CN 201610274784A CN 106027597 B CN106027597 B CN 106027597B
Authority
CN
China
Prior art keywords
terminal device
server
file
target file
resource
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.)
Expired - Fee Related
Application number
CN201610274784.6A
Other languages
Chinese (zh)
Other versions
CN106027597A (en
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 Qihoo Technology Co Ltd
Original Assignee
Beijing Qihoo Technology Co Ltd
Qizhi Software Beijing 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 Qihoo Technology Co Ltd, Qizhi Software Beijing Co Ltd filed Critical Beijing Qihoo Technology Co Ltd
Priority to CN201610274784.6A priority Critical patent/CN106027597B/en
Publication of CN106027597A publication Critical patent/CN106027597A/en
Application granted granted Critical
Publication of CN106027597B publication Critical patent/CN106027597B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0481Interaction techniques based on graphical user interfaces [GUI] based on specific properties of the displayed interaction object or a metaphor-based environment, e.g. interaction with desktop elements like windows or icons, or assisted by a cursor's changing behaviour or appearance
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • H04L43/0805Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability
    • H04L43/0811Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability by checking connectivity
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/55Push-based network services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/56Provisioning of proxy services
    • H04L67/568Storing data temporarily at an intermediate stage, e.g. caching
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/56Provisioning of proxy services
    • H04L67/568Storing data temporarily at an intermediate stage, e.g. caching
    • H04L67/5683Storage of data provided by user terminals, i.e. reverse caching

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Environmental & Geological Engineering (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Telephonic Communication Services (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The invention discloses a kind of method of offline file transmission, system, terminal device and servers, the method comprise the steps that file destination resource is sent in first server by suspension windows in first terminal equipment side when first terminal equipment does not detect the access of second terminal equipment;The download address for receiving the file destination resource that the first server returns is flanked in first terminal equipment, the download address of the file destination resource is that the first server is generated according to the file destination resource;Packet is constructed according to the download address of the file destination resource in first terminal equipment side and is sent in second server.The present invention can reduce the limitation of file resource transmission, improve user experience.

Description

一种离线文件传输的方法以及服务器An offline file transfer method and server

本发明专利申请是申请日为2013年11月26日、申请号为 201310612011.0、名称为“一种离线文件传输的方法、系统、终端设备以及服务器”的中国发明专利申请的分案申请。The patent application for the present invention is a divisional application of a Chinese invention patent application with an application date of November 26, 2013, an application number of 201310612011.0, and the title of "A method, system, terminal device and server for offline file transmission".

技术领域technical field

本发明涉及文件传输技术领域,具体涉及一种离线文件传输的方法、一种用于离线文件传输的终端设备、一种离线文件传输的系统,以及一种用于离线文件传输的服务器。The present invention relates to the technical field of file transmission, in particular to a method for offline file transmission, a terminal device for offline file transmission, a system for offline file transmission, and a server for offline file transmission.

背景技术Background technique

随着移动通信技术的快速发展,如手机等移动设备已经广泛应用在学习、娱乐、工作等方面,在人们的日常生活中扮演着越来越重要的角色。With the rapid development of mobile communication technology, mobile devices such as mobile phones have been widely used in learning, entertainment, work, etc., and play an increasingly important role in people's daily life.

由于移动设备的功能越来越多样,因此就需要与计算设备连接,进行数据传输。例如,将计算设备中的办公文件传输到移动设备中,方便随时查看;又如,将移动设备中的照片等传输到计算设备中,进行图像处理、保存等操作。As the functions of mobile devices become more and more diverse, they need to be connected to computing devices for data transmission. For example, transferring office files in a computing device to a mobile device for easy viewing at any time; another example, transferring photos, etc. in the mobile device to the computing device for image processing, saving, and other operations.

通常,移动设备可以采用数据线和计算设备进行连接,此时,可以将移动设备看作是计算设备上的一个移动存储设备,从而通过数据线可以使移动设备和计算设备实现数据传输。但通过数据线的方式进行移动设备和计算设备的连接,需要时刻携带数据线,操作麻烦,并且长期使用容易导致USB接口磨损。Usually, the mobile device can be connected to the computing device by using a data cable. In this case, the mobile device can be regarded as a mobile storage device on the computing device, so that data transmission can be realized between the mobile device and the computing device through the data cable. However, connecting the mobile device and the computing device by means of a data cable requires carrying the data cable at all times, which is troublesome to operate, and the long-term use may easily lead to wear and tear of the USB interface.

因此,移动设备与计算设备之间进行无线连接的方式应运而生。对于无线连接而言,主要有以下情况:Therefore, the wireless connection between the mobile device and the computing device came into being. For wireless connections, there are mainly the following situations:

1、有无线路由1. There is a wireless router

这种方式是移动设备通过wifi连到路由,计算设备通过wifi或网线连到路由;在移动设备上用websharing、虚拟数据线、文件大师等软件开通ftp服务,计算设备上用浏览器打开ftp后,进行文件传输。This method is that the mobile device is connected to the router through wifi, and the computing device is connected to the router through wifi or network cable; use websharing, virtual data cable, file master and other software to open the ftp service on the mobile device, and use the browser to open the ftp service on the computing device. , to perform a file transfer.

2、没有无线路由,计算设备有无线网卡2. There is no wireless router, and the computing device has a wireless network card

2.1无线网卡支持mywifi技术2.1 Wireless network card supports mywifi technology

把计算设备设为wifi热点(xp下手工设置,win7下手工设置或用 connectify软件),移动设备通过wifi连到计算设备;在移动设备上用 websharing、虚拟数据线、文件大师等软件开通ftp服务,计算设备上用浏览器打开ftp后进行文件传输。Set the computing device as a wifi hotspot (manually set under xp, manually set under win7 or use connectify software), and connect the mobile device to the computing device through wifi; use websharing, virtual data cable, file master and other software to open ftp service on the mobile device , and use the browser to open ftp on the computing device for file transfer.

2.2无线网卡不支持mywifi技术2.2 The wireless network card does not support mywifi technology

把移动设备wifi热点打开,计算设备通过wifi连到移动设备;在移动设备上用websharing、虚拟数据线、文件大师等软件开通ftp服务,计算设备上用浏览器打开ftp后进行文件传输。Turn on the wifi hotspot of the mobile device, and connect the computing device to the mobile device through wifi; open the ftp service on the mobile device with software such as websharing, virtual data cable, file master, etc., and use the browser to open the ftp on the computing device to transfer files.

然而,无线连接的情况下,需要计算设备与移动设备同时处于在线状态时,才能在双方之间进行文件的传输,如果文件的接收方不在线,便无法成功将文件发送给接收方,从而给使用者带来了不便,降低了用户体验。However, in the case of a wireless connection, the file transfer between the two parties can only be performed when the computing device and the mobile device are online at the same time. If the recipient of the file is not online, the file cannot be successfully sent to the recipient. It brings inconvenience to the user and reduces the user experience.

发明内容SUMMARY OF THE INVENTION

鉴于上述问题,提出了本发明以便提供一种克服上述问题或者至少部分地解决上述问题的一种离线文件传输的方法和相应的一种离线文件传输的系统、一种用于离线文件传输的终端设备、一种用于离线文件传输的服务器。In view of the above problems, the present invention is proposed to provide an offline file transfer method and a corresponding offline file transfer system and a terminal for offline file transfer that overcome the above problems or at least partially solve the above problems device, a server for offline file transfer.

依据本发明的一个方面,提供了一种离线文件传输的方法,包括:According to one aspect of the present invention, a method for offline file transfer is provided, comprising:

当第一终端设备没有检测到第二终端设备的接入时,在第一终端设备侧通过悬浮窗口将目标文件资源发送至第一服务器中;When the first terminal device does not detect the access of the second terminal device, sending the target file resource to the first server through the floating window on the side of the first terminal device;

在第一终端设备侧接收所述第一服务器返回的所述目标文件资源的下载地址,所述目标文件资源的下载地址为所述第一服务器依据所述目标文件资源生成;receiving, at the first terminal device side, the download address of the target file resource returned by the first server, where the download address of the target file resource is generated by the first server according to the target file resource;

在第一终端设备侧依据所述目标文件资源的下载地址构建信息包并发送至第二服务器中。The information package is constructed on the side of the first terminal device according to the download address of the target file resource and sent to the second server.

可选地,在所述在第一终端设备侧通过悬浮窗口将目标文件资源发送至第一服务器中的步骤之前,还包括:Optionally, before the step of sending the target file resource to the first server through the floating window on the side of the first terminal device, the method further includes:

检测用户针对悬浮窗口发起的指定操作,所述指定操作包括用户将目标文件资源拖送到悬浮窗口的操作,和/或,用户点击悬浮窗口上的文件选定按钮,在第一终端设备弹出的文件路径选择窗口中选择目标文件资源的路径的操作;Detecting a specified operation initiated by the user on the floating window, the specified operation includes the operation of the user dragging the target file resource to the floating window, and/or, the user clicks the file selection button on the floating window, and the first terminal device pops up The operation of selecting the path of the target file resource in the file path selection window;

当检测到所述指定操作时,发出提醒消息询问用户是否需要离线发送目标文件资源;When the specified operation is detected, a reminder message is sent to ask the user whether the target file resource needs to be sent offline;

所述在第一终端设备侧通过悬浮窗口将目标文件资源发送至第一服务器中的步骤包括:The step of sending the target file resource to the first server through the floating window on the side of the first terminal device includes:

在接收到用户发送的离线确认指令后,通过悬浮窗口将所述目标文件资源发送至第一服务器中,所述离线确认指令为用户指示的确认离线发送所述目标文件资源的指令。After receiving the offline confirmation instruction sent by the user, the target file resource is sent to the first server through the floating window, and the offline confirmation instruction is an instruction instructed by the user to confirm the offline sending of the target file resource.

可选地,所述在第一终端设备侧通过悬浮窗口将目标文件资源发送至第一服务器中的步骤包括:Optionally, the step of sending the target file resource to the first server through the floating window on the side of the first terminal device includes:

在第一终端设备侧依据所述用户针对悬浮窗口的指定操作生成文件发送请求;Generate a file sending request on the side of the first terminal device according to the user's specified operation on the floating window;

在第一终端设备侧将所述文件发送请求发送至第一服务器中;sending the file sending request to the first server on the side of the first terminal device;

在第一终端设备侧接收所述第一服务器返回的文件响应消息;receiving, on the side of the first terminal device, a file response message returned by the first server;

在第一终端设备侧依据所述文件响应消息将所述目标文件资源发送至第一服务器中。The first terminal device side sends the target file resource to the first server according to the file response message.

可选地,所述在第一终端设备侧依据所述文件响应消息将所述目标文件资源发送至第一服务器中的步骤包括:Optionally, the step of sending the target file resource to the first server on the first terminal device side according to the file response message includes:

在第一终端设备侧依据所述文件响应消息对将所述目标文件资源进行加密;Encrypting the target file resource according to the file response message at the first terminal device side;

将所述加密后的目标文件资源发送至第一服务器中。Send the encrypted target file resource to the first server.

可选地,所述目标文件资源为第一终端侧依据用户发出的文件资源选定指令获得的文件资源;所述文件资源选定指令为用户在第一终端设备侧展示的文件资源下载列表中选择的对某文件资源的下载指令,或者,所述文件资源选定指令为用户在第一终端设备侧存储的文件资源中选择的对某文件资源的选定指令。Optionally, the target file resource is a file resource obtained by the first terminal side according to a file resource selection instruction sent by the user; the file resource selection instruction is in the file resource download list displayed by the user on the first terminal device side. The selected download instruction for a certain file resource, or the file resource selection instruction is a selection instruction for a certain file resource selected by the user from the file resources stored on the side of the first terminal device.

可选地,所述在第一终端设备侧依据所述目标文件资源的下载地址构建信息包并发送至第二服务器中的步骤包括:Optionally, the step of constructing an information package on the first terminal device side according to the download address of the target file resource and sending it to the second server includes:

在第一终端设备侧获取所述目标文件资源的文件属性信息;Obtain the file attribute information of the target file resource on the side of the first terminal device;

在第一终端设备侧构建所述目标文件资源的下载地址以及所述文件属性信息的信息包;constructing the download address of the target file resource and the information package of the file attribute information on the side of the first terminal device;

在第一终端设备侧将所述信息包发送至第二服务器中。The information packet is sent to the second server on the side of the first terminal device.

可选地,所述方法还包括:Optionally, the method further includes:

在第一终端设备侧接收第三服务器发送的信息确认指令;receiving an information confirmation instruction sent by the third server on the side of the first terminal device;

在第一终端设备侧将所述信息确认指令展示给用户;presenting the information confirmation instruction to the user on the side of the first terminal device;

接收用户选择的确认信息,并将所述确认信息发送至第二服务器中。The confirmation information selected by the user is received, and the confirmation information is sent to the second server.

可选地,所述信息确认指令包括第二终端设备的标识,所述确认信息包括第一确认信息以及第二确认信息,所述第一确认信息为依据用户选定的确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;所述第二确认信息为依据用户选定的不确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息。Optionally, the information confirmation instruction includes the identifier of the second terminal device, the confirmation information includes first confirmation information and second confirmation information, and the first confirmation information is to confirm the second terminal according to the user's selection. The information generated by the second terminal device corresponding to the identification of the device as the file recipient; the second confirmation information is based on the user's selection not to confirm that the second terminal device corresponding to the identification of the second terminal device is the file recipient generated information.

可选地,所述方法还包括:Optionally, the method further includes:

在第一终端设备侧生成文件发送列表,所述文件发送列表为通过所述悬浮窗口进行离线发送的目标文件资源组织成的列表。A file sending list is generated on the side of the first terminal device, where the file sending list is a list organized by target file resources to be sent offline through the floating window.

可选地,所述文件发送列表中针对每个目标文件资源具有文件发送状态信息,所述文件发送状态信息包括成功发送状态、正在发送状态、等待发送状态以及发送失败状态。Optionally, the file sending list has file sending status information for each target file resource, and the file sending status information includes a successful sending status, a sending status, a waiting status for sending, and a sending failure status.

可选地,所述目标文件资源的文件属性信息还包括目标文件资源的大小、目标文件资源的类型、目标文件资源的版本号、目标文件资源的标识。Optionally, the file attribute information of the target file resource further includes the size of the target file resource, the type of the target file resource, the version number of the target file resource, and the identifier of the target file resource.

可选地,所述目标文件资源的类型包括主题、壁纸、铃声、软件、音乐、游戏、视频、电子书。Optionally, the types of the target file resources include themes, wallpapers, ringtones, software, music, games, videos, and e-books.

可选地,所述第一服务器为文件服务器,所述第二服务器为应用服务器,所述第三服务器为推送服务器。Optionally, the first server is a file server, the second server is an application server, and the third server is a push server.

根据本发明的另一方面,提供了一种离线文件传输的方法,包括:According to another aspect of the present invention, a method for offline file transfer is provided, comprising:

在第二服务器侧接收第一终端设备侧发送的信息包;receiving, at the second server side, the information packet sent by the first terminal device side;

所述第二服务器获取所述第一终端设备的标识;obtaining, by the second server, the identifier of the first terminal device;

在第二服务器侧的预设的关联关系列表中查找与所述第一终端设备的标识存在关联关系的第二终端设备的标识;Searching for the identifier of the second terminal device that has an associated relationship with the identifier of the first terminal device in the preset association relationship list on the second server side;

在第二服务器侧依据所述第二终端设备的标识生成文件获取消息发送至第三服务器中。On the second server side, a file acquisition message is generated according to the identifier of the second terminal device and sent to the third server.

可选地,在所述依据所述第二终端设备的标识生成文件获取消息发送至第三服务器中的步骤之前,还包括:Optionally, before the step of generating the file acquisition message according to the identifier of the second terminal device and sending it to the third server, the method further includes:

在第二服务器侧生成信息确认指令;generating an information confirmation instruction on the second server side;

在第二服务器侧将所述信息确认指令发送至第三服务器中,由第三服务器发送至第一终端设备侧;Send the information confirmation instruction to the third server on the second server side, and the third server sends it to the first terminal device side;

在第二服务器侧接收第一终端设备返回的确认信息。The confirmation information returned by the first terminal device is received at the second server side.

可选地,所述信息确认指令包括第二终端设备的标识,所述确认信息包括第一确认信息以及第二确认信息,所述第一确认信息为依据用户选定的确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;所述第二确认信息为依据用户选定的不确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;Optionally, the information confirmation instruction includes the identifier of the second terminal device, the confirmation information includes first confirmation information and second confirmation information, and the first confirmation information is to confirm the second terminal according to the user's selection. The information generated by the second terminal device corresponding to the identification of the device as the file recipient; the second confirmation information is based on the user's selection not to confirm that the second terminal device corresponding to the identification of the second terminal device is the file recipient information generated;

所述方法还包括:The method also includes:

若所述确认信息为第一确认信息,则执行所述在第二服务器侧依据所述第二终端设备的标识生成文件获取消息发送至第三服务器中的步骤;If the confirmation information is the first confirmation information, executing the step of generating a file acquisition message on the second server side according to the identifier of the second terminal device and sending it to the third server;

若所述确认信息为第二确认信息,则在第二服务器侧重新获取第二终端设备的标识。If the confirmation information is the second confirmation information, the identifier of the second terminal device is re-acquired on the second server side.

根据本发明的另一方面,提供了一种离线文件传输的方法,包括:According to another aspect of the present invention, a method for offline file transfer is provided, comprising:

在第三服务器侧接收第二服务器发送的文件获取消息,所述文件获取消息包括第二终端设备的标识;receiving, at the third server side, a file acquisition message sent by the second server, where the file acquisition message includes the identifier of the second terminal device;

在第三服务器侧检测到所述第二终端设备的标识对应的第二终端设备在线时,将所述文件获取消息发送至所述第二终端设备侧。When the third server side detects that the second terminal device corresponding to the identifier of the second terminal device is online, the file acquisition message is sent to the second terminal device side.

可选地,所述检测所述第二终端设备的标识对应的第二终端设备在线的步骤包括:Optionally, the step of detecting that the second terminal device corresponding to the identifier of the second terminal device is online includes:

在第三服务器侧获取所有已经接入的终端设备的标识;Obtain the identifiers of all connected terminal devices on the third server side;

在第三服务器侧判断所述所有接入的终端设备的标识中是否存在与所述第二终端设备的标识相同的终端设备;Judging on the third server side whether there is a terminal device identical to the identifier of the second terminal device in the identifiers of all the connected terminal devices;

若是,则判定所述第二终端设备的标识对应的第二终端设备在线。If so, it is determined that the second terminal device corresponding to the identifier of the second terminal device is online.

可选地,所述方法还包括:Optionally, the method further includes:

在第三服务器侧接收第二服务器发送的信息确认指令;在第三服务器侧将所述信息确认指令发送至第一终端设备中。The information confirmation instruction sent by the second server is received at the third server side; the information confirmation instruction is sent to the first terminal device at the third server side.

根据本发明的另一方面,提供了一种离线文件传输的方法,包括:According to another aspect of the present invention, a method for offline file transfer is provided, comprising:

在第二终端设备侧接收第三服务器发送的文件获取消息;receiving, on the second terminal device side, the file acquisition message sent by the third server;

在第二终端设备侧依据所述文件获取消息从第二服务器中获取对应的信息包,所述信息包包括目标文件资源的下载地址;The second terminal device side obtains a corresponding information package from the second server according to the file obtaining message, where the information package includes the download address of the target file resource;

在第二终端设备侧依据所述目标文件资源的下载地址从第一服务器中下载对应的目标文件资源。The second terminal device side downloads the corresponding target file resource from the first server according to the download address of the target file resource.

可选地,所述信息包包括文件属性信息,所述文件属性信息包括目标文件资源的类型,所述目标文件资源的类型包括主题、壁纸、铃声、软件、音乐、游戏、视频、电子书,所述的方法还包括:Optionally, the information package includes file attribute information, the file attribute information includes the type of target file resource, and the type of the target file resource includes theme, wallpaper, ringtone, software, music, game, video, e-book, The method also includes:

若所述目标文件资源的类型为主题、壁纸、铃声、音乐、视频、电子书,则将所述目标文件资源存储在第二终端设备侧;If the type of the target file resource is theme, wallpaper, ringtone, music, video, e-book, then the target file resource is stored on the second terminal device side;

若所述目标文件资源的类型为软件和/或游戏,则直接安装所述目标文件资源。If the type of the target file resource is software and/or a game, the target file resource is directly installed.

可选地,在所述在第二终端设备侧接收第三服务器发送的文件获取消息的步骤之前,还包括:Optionally, before the step of receiving the file acquisition message sent by the third server on the second terminal device side, the method further includes:

在第二终端设备侧监听网络状态,所述网络状态包括当前网络可用;Monitor the network status on the second terminal device side, where the network status includes current network availability;

若当前网络可用,则在第二终端设备侧连接当前网络;If the current network is available, connect the current network on the second terminal device side;

在第二终端设备侧连接所述第三服务器。The third server is connected on the second terminal device side.

可选地,若所述第二终端设备为移动设备,所述在第二终端设备侧监听网络状态的步骤包括:Optionally, if the second terminal device is a mobile device, the step of monitoring the network status on the second terminal device side includes:

在所述第二终端设备侧注册网络状态变化接收服务ConnctionChangeReceiver;Register the network state change receiving service ConnctionChangeReceiver on the second terminal device side;

在第二终端设备侧采用所述网络状态变化接收服务 ConnctionChangeReceiver接收系统服务SystemService发出的广播 CONNECTIVITY_CHANGE;On the second terminal device side, use the network state change receiving service ConnctionChangeReceiver to receive the broadcast CONNECTIVITY_CHANGE sent by the system service SystemService;

若所述广播CONNECTIVITY_CHANGE调用的方法 wifiNetInfo.isConnected()返回的布尔值为真,则判定当前网络可用;If the boolean value returned by the method wifiNetInfo.isConnected() called by the broadcast CONNECTIVITY_CHANGE is true, it is determined that the current network is available;

若所述广播CONNECTIVITY_CHANGE调用的方法wifiNetInfo.isConnected()返回的布尔值为真,则判定当前网络不可用。If the boolean value returned by the method wifiNetInfo.isConnected() called by the broadcast CONNECTIVITY_CHANGE is true, it is determined that the current network is unavailable.

可选地,若所述第二终端设备为计算设备,所述在第二终端设备侧监听网络状态的步骤包括:Optionally, if the second terminal device is a computing device, the step of monitoring the network status on the second terminal device side includes:

在第二终端设备侧调用网络接口API查询当前的网络状态。The network interface API is called on the second terminal device side to query the current network status.

根据本发明的另一方面,提供了一种用于离线文件传输的终端设备,包括:According to another aspect of the present invention, a terminal device for offline file transfer is provided, comprising:

目标文件资源发送模块,适于在第一终端设备没有检测到第二终端设备的接入时,在第一终端设备侧通过悬浮窗口将目标文件资源发送至第一服务器中;The target file resource sending module is adapted to send the target file resource to the first server through the floating window on the side of the first terminal device when the first terminal device does not detect the access of the second terminal device;

下载地址接收模块,适于在第一终端设备侧接收所述第一服务器返回的所述目标文件资源的下载地址,所述目标文件资源的下载地址为所述第一服务器依据所述目标文件资源生成;A download address receiving module, adapted to receive the download address of the target file resource returned by the first server on the side of the first terminal device, where the download address of the target file resource is the first server according to the target file resource. generate;

下载地址发送模块,适于在第一终端设备侧依据所述目标文件资源的下载地址构建信息包并发送至第二服务器中。The download address sending module is adapted to construct an information package on the side of the first terminal device according to the download address of the target file resource and send it to the second server.

可选地,所述终端设备还包括:Optionally, the terminal device further includes:

检测模块,适于在所述在第一终端设备侧通过悬浮窗口将目标文件资源发送至第一服务器中之前,检测用户针对悬浮窗口发起的指定操作,所述指定操作包括用户将目标文件资源拖送到悬浮窗口的操作,和/或,用户点击悬浮窗口上的文件选定按钮,在第一终端设备弹出的文件路径选择窗口中选择目标文件资源的路径的操作;The detection module is adapted to detect a specified operation initiated by the user on the floating window before the target file resource is sent to the first server through the floating window on the side of the first terminal device, and the specified operation includes dragging the target file resource by the user The operation of sending to the floating window, and/or, the user clicks the file selection button on the floating window, and selects the path of the target file resource in the file path selection window popped up by the first terminal device;

提醒消息发送模块,适于在检测到所述指定操作时,发出提醒消息询问用户是否需要离线发送目标文件资源;a reminder message sending module, adapted to send a reminder message to ask the user whether the target file resource needs to be sent offline when the designated operation is detected;

所述目标文件资源发送模块还适于:The target file resource sending module is further adapted to:

在接收到用户发送的离线确认指令后,通过悬浮窗口将所述目标文件资源发送至第一服务器中,所述离线确认指令为用户指示的确认离线发送所述目标文件资源的指令。After receiving the offline confirmation instruction sent by the user, the target file resource is sent to the first server through the floating window, and the offline confirmation instruction is an instruction instructed by the user to confirm the offline sending of the target file resource.

可选地,所述目标文件资源发送模块还适于:Optionally, the target file resource sending module is further adapted to:

在第一终端设备侧依据所述用户针对悬浮窗口的指定操作生成文件发送请求;Generate a file sending request on the side of the first terminal device according to the user's specified operation on the floating window;

在第一终端设备侧将所述文件发送请求发送至第一服务器中;sending the file sending request to the first server on the side of the first terminal device;

在第一终端设备侧接收所述第一服务器返回的文件响应消息;receiving, on the side of the first terminal device, a file response message returned by the first server;

在第一终端设备侧依据所述文件响应消息将所述目标文件资源发送至第一服务器中。The first terminal device side sends the target file resource to the first server according to the file response message.

可选地,所述目标文件资源发送模块还适于:Optionally, the target file resource sending module is further adapted to:

在第一终端设备侧依据所述文件响应消息对将所述目标文件资源进行加密;Encrypting the target file resource according to the file response message at the first terminal device side;

将所述加密后的目标文件资源发送至第一服务器中。Send the encrypted target file resource to the first server.

可选地,所述目标文件资源为第一终端侧依据用户发出的文件资源选定指令获得的文件资源;所述文件资源选定指令为用户在第一终端设备侧展示的文件资源下载列表中选择的对某文件资源的下载指令,或者,所述文件资源选定指令为用户在第一终端设备侧存储的文件资源中选择的对某文件资源的选定指令。Optionally, the target file resource is a file resource obtained by the first terminal side according to a file resource selection instruction issued by the user; the file resource selection instruction is in the file resource download list displayed by the user on the first terminal device side. The selected download instruction for a certain file resource, or, the file resource selection instruction is a selection instruction for a certain file resource selected by the user from the file resources stored on the side of the first terminal device.

可选地,所述下载地址发送模块还适于:Optionally, the download address sending module is further adapted to:

在第一终端设备侧获取所述目标文件资源的文件属性信息;Obtain the file attribute information of the target file resource on the side of the first terminal device;

在第一终端设备侧构建所述目标文件资源的下载地址以及所述文件属性信息的信息包;constructing the download address of the target file resource and the information package of the file attribute information on the side of the first terminal device;

在第一终端设备侧将所述信息包发送至第二服务器中。The information packet is sent to the second server on the side of the first terminal device.

可选地,所述终端设备还包括:Optionally, the terminal device further includes:

信息确认指令发送模块,适于在第一终端设备侧接收第三服务器发送的信息确认指令;an information confirmation instruction sending module, adapted to receive the information confirmation instruction sent by the third server on the side of the first terminal device;

展示模块,适于在第一终端设备侧将所述信息确认指令展示给用户;a presentation module, adapted to present the information confirmation instruction to the user on the side of the first terminal device;

确认信息接收模块,适于接收用户选择的确认信息,并将所述确认信息发送至第二服务器中。The confirmation information receiving module is adapted to receive confirmation information selected by the user, and send the confirmation information to the second server.

可选地,所述信息确认指令包括第二终端设备的标识,所述确认信息包括第一确认信息以及第二确认信息,所述第一确认信息为依据用户选定的确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;所述第二确认信息为依据用户选定的不确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息。Optionally, the information confirmation instruction includes the identifier of the second terminal device, the confirmation information includes first confirmation information and second confirmation information, and the first confirmation information is to confirm the second terminal according to the user's selection. The information generated by the second terminal device corresponding to the identification of the device as a file receiver; the second confirmation information is based on the user's selection not to confirm that the second terminal device corresponding to the identification of the second terminal device is a file receiver generated information.

可选地,所述终端设备还包括:Optionally, the terminal device further includes:

文件发送列表生成模块,适于在第一终端设备侧生成文件发送列表,所述文件发送列表为通过所述悬浮窗口进行离线发送的目标文件资源组织成的列表。The file sending list generating module is adapted to generate a file sending list on the side of the first terminal device, and the file sending list is a list organized by target file resources to be sent offline through the floating window.

可选地,所述文件发送列表中针对每个目标文件资源具有文件发送状态信息,所述文件发送状态信息包括成功发送状态、正在发送状态、等待发送状态以及发送失败状态。Optionally, the file sending list has file sending status information for each target file resource, and the file sending status information includes a successful sending status, a sending status, a waiting status for sending, and a sending failure status.

可选地,所述目标文件资源的文件属性信息还包括目标文件资源的大小、目标文件资源的类型、目标文件资源的版本号、目标文件资源的标识。Optionally, the file attribute information of the target file resource further includes the size of the target file resource, the type of the target file resource, the version number of the target file resource, and the identifier of the target file resource.

可选地,所述目标文件资源的类型包括主题、壁纸、铃声、软件、音乐、游戏、视频、电子书。Optionally, the types of the target file resources include themes, wallpapers, ringtones, software, music, games, videos, and e-books.

可选地,所述第一服务器为文件服务器,所述第二服务器为应用服务器,所述第三服务器为推送服务器。Optionally, the first server is a file server, the second server is an application server, and the third server is a push server.

根据本发明的另一方面,提供了一种用于离线文件传输的服务器,包括:According to another aspect of the present invention, there is provided a server for offline file transfer, comprising:

信息包接收模块,适于在第二服务器侧接收第一终端设备侧发送的信息包;an information packet receiving module, adapted to receive, on the second server side, an information packet sent by the first terminal device side;

设备标识获取模块,适于所述第二服务器获取所述第一终端设备的标识;a device identification acquiring module, adapted for the second server to acquire the identification of the first terminal device;

设备标识查找模块,适于在第二服务器侧的预设的关联关系列表中查找与所述第一终端设备的标识存在关联关系的第二终端设备的标识;a device identification search module, adapted to search for the identification of the second terminal device that has an association relationship with the identification of the first terminal device in a preset association relationship list on the second server side;

第一文件获取消息发送模块,适于在第二服务器侧依据所述第二终端设备的标识生成文件获取消息发送至第三服务器中。The first file acquisition message sending module is adapted to generate a file acquisition message on the second server side according to the identifier of the second terminal device and send it to the third server.

可选地,所述服务器还包括:Optionally, the server further includes:

信息确认指令生成模块,适于在所述依据所述第二终端设备的标识生成文件获取消息发送至第三服务器中之前,在第二服务器侧生成信息确认指令;an information confirmation instruction generation module, adapted to generate an information confirmation instruction on the second server side before the file acquisition message is generated according to the identifier of the second terminal device and sent to the third server;

信息确认指令发送模块,适于在第二服务器侧将所述信息确认指令发送至第三服务器中,由第三服务器发送至第一终端设备侧;an information confirmation instruction sending module, adapted to send the information confirmation instruction on the second server side to the third server, and the third server sends it to the first terminal device side;

确认消息接收模块,适于在第二服务器侧接收第一终端设备返回的确认信息。The confirmation message receiving module is adapted to receive confirmation information returned by the first terminal device on the second server side.

可选地,所述信息确认指令包括第二终端设备的标识,所述确认信息包括第一确认信息以及第二确认信息,所述第一确认信息为依据用户选定的确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;所述第二确认信息为依据用户选定的不确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;Optionally, the information confirmation instruction includes the identifier of the second terminal device, the confirmation information includes first confirmation information and second confirmation information, and the first confirmation information is to confirm the second terminal according to the user's selection. The information generated by the second terminal device corresponding to the identification of the device as the file recipient; the second confirmation information is based on the user's selection not to confirm that the second terminal device corresponding to the identification of the second terminal device is the file recipient information generated;

所述服务器还包括:The server also includes:

调用模块,适于在所述确认信息为第一确认信息时,调用第一文件获取消息发送模块;a calling module, adapted to call the first file acquisition message sending module when the confirmation information is the first confirmation information;

标识获取模块,适于在所述确认信息为第二确认信息时,在第二服务器侧重新获取第二终端设备的标识。The identification acquisition module is adapted to re-acquire the identification of the second terminal device on the second server side when the confirmation information is the second confirmation information.

根据本发明的另一方面,提供了一种用于离线文件传输的服务器,包括:According to another aspect of the present invention, there is provided a server for offline file transfer, comprising:

第一文件获取消息接收模块,适于在第三服务器侧接收第二服务器发送的文件获取消息,所述文件获取消息包括第二终端设备的标识;a first file acquisition message receiving module, adapted to receive, on the third server side, a file acquisition message sent by a second server, where the file acquisition message includes an identifier of the second terminal device;

第二文件获取消息发送模块,适于在第三服务器侧检测到所述第二终端设备的标识对应的第二终端设备在线时,将所述文件获取消息发送至所述第二终端设备侧。The second file obtaining message sending module is adapted to send the file obtaining message to the second terminal device side when the third server side detects that the second terminal device corresponding to the identifier of the second terminal device is online.

可选地,所述第二文件获取消息发送模块还适于:Optionally, the second file acquisition message sending module is further adapted to:

在第三服务器侧获取所有已经接入的终端设备的标识;Obtain the identifiers of all connected terminal devices on the third server side;

在第三服务器侧判断所述所有接入的终端设备的标识中是否存在与所述第二终端设备的标识相同的终端设备;Judging on the third server side whether there is a terminal device identical to the identifier of the second terminal device in the identifiers of all the connected terminal devices;

若是,则判定所述第二终端设备的标识对应的第二终端设备在线。If so, it is determined that the second terminal device corresponding to the identifier of the second terminal device is online.

可选地,所述服务器还包括:Optionally, the server further includes:

信息确认指令接收模块,适于在第三服务器侧接收第二服务器发送的信息确认指令;an information confirmation instruction receiving module, adapted to receive the information confirmation instruction sent by the second server on the third server side;

信息确认指令发送模块,适于在第三服务器侧将所述信息确认指令发送至第一终端设备中。The information confirmation instruction sending module is adapted to send the information confirmation instruction to the first terminal device on the third server side.

根据本发明的另一方面,提供了一种用于离线文件传输的终端设备,包括:According to another aspect of the present invention, a terminal device for offline file transfer is provided, comprising:

第二文件获取消息接收模块,适于在第二终端设备侧接收第三服务器发送的文件获取消息;The second file acquisition message receiving module is adapted to receive the file acquisition message sent by the third server on the second terminal device side;

信息包获取模块,适于在第二终端设备侧依据所述文件获取消息从第二服务器中获取对应的信息包,所述信息包包括目标文件资源的下载地址;an information package acquisition module, adapted to acquire a corresponding information package from the second server according to the file acquisition message on the second terminal device side, where the information package includes a download address of the target file resource;

目标文件资源下载模块,适于在第二终端设备侧依据所述目标文件资源的下载地址从第一服务器中下载对应的目标文件资源。The target file resource downloading module is adapted to download the corresponding target file resource from the first server on the second terminal device side according to the download address of the target file resource.

可选地,所述信息包包括文件属性信息,所述文件属性信息包括目标文件资源的类型,所述目标文件资源的类型包括主题、壁纸、铃声、软件、音乐、游戏、视频、电子书,所述的终端设备还包括:Optionally, the information package includes file attribute information, the file attribute information includes the type of target file resource, and the type of the target file resource includes theme, wallpaper, ringtone, software, music, game, video, e-book, The terminal equipment also includes:

若所述目标文件资源的类型为主题、壁纸、铃声、音乐、视频、电子书,则将所述目标文件资源存储在第二终端设备侧;If the type of the target file resource is theme, wallpaper, ringtone, music, video, e-book, then the target file resource is stored on the second terminal device side;

若所述目标文件资源的类型为软件和/或游戏,则直接安装所述目标文件资源。If the type of the target file resource is software and/or a game, the target file resource is directly installed.

可选地,所述终端设备还包括:Optionally, the terminal device further includes:

监听模块,适于在所述在第二终端设备侧接收第三服务器发送的文件获取消息之前,在第二终端设备侧监听网络状态,所述网络状态包括当前网络可用;a monitoring module, adapted to monitor a network state on the second terminal device side before receiving the file acquisition message sent by the third server on the second terminal device side, where the network state includes current network availability;

第一连接模块,适于若当前网络可用,则在第二终端设备侧连接当前网络;a first connection module, adapted to connect to the current network at the second terminal device side if the current network is available;

第二连接模块,适于在第二终端设备侧连接所述第三服务器。The second connection module is adapted to connect to the third server on the side of the second terminal device.

可选地,若所述第二终端设备为移动设备,所述监听模块还适于:Optionally, if the second terminal device is a mobile device, the monitoring module is further adapted to:

在所述第二终端设备侧注册网络状态变化接收服务 ConnctionChangeReceiver;Register the network state change receiving service ConnctionChangeReceiver on the second terminal device side;

在第二终端设备侧采用所述网络状态变化接收服务 ConnctionChangeReceiver接收系统服务SystemService发出的广播 CONNECTIVITY_CHANGE;On the second terminal device side, use the network state change receiving service ConnctionChangeReceiver to receive the broadcast CONNECTIVITY_CHANGE sent by the system service SystemService;

若所述广播CONNECTIVITY_CHANGE调用的方法 wifiNetInfo.isConnected()返回的布尔值为真,则判定当前网络可用;If the boolean value returned by the method wifiNetInfo.isConnected() called by the broadcast CONNECTIVITY_CHANGE is true, it is determined that the current network is available;

若所述广播CONNECTIVITY_CHANGE调用的方法 wifiNetInfo.isConnected()返回的布尔值为真,则判定当前网络不可用。If the boolean value returned by the method wifiNetInfo.isConnected() called by the broadcast CONNECTIVITY_CHANGE is true, it is determined that the current network is unavailable.

可选地,若所述第二终端设备为计算设备,所述在第二终端设备侧监听网络状态的步骤包括:Optionally, if the second terminal device is a computing device, the step of monitoring the network status on the second terminal device side includes:

在第二终端设备侧调用网络接口API查询当前的网络状态。The network interface API is called on the second terminal device side to query the current network status.

根据本发明的另一方面,提供了一种离线文件传输的系统,包括:第一终端设备、文件服务器、应用服务器,推送服务器、第二终端设备,其中,According to another aspect of the present invention, an offline file transmission system is provided, including: a first terminal device, a file server, an application server, a push server, and a second terminal device, wherein,

所述第一终端设备,适于当第一终端设备没有检测到第二终端设备的接入时,通过悬浮窗口将待发送的目标文件资源发送至文件服务器中,并接收所述文件服务器返回的所述目标文件资源的下载地址,以及,将所述目标文件资源的下载地址构建信息包发送至应用服务器中;The first terminal device is adapted to, when the first terminal device does not detect the access of the second terminal device, send the target file resource to be sent to the file server through the floating window, and receive the data returned by the file server. The download address of the target file resource, and sending the download address of the target file resource to construct an information package to the application server;

所述文件服务器,适于接收所述目标文件资源,依据所述目标文件资源生成对应的目标文件资源的下载地址并发送至第一终端设备中;The file server is adapted to receive the target file resource, generate a download address of the corresponding target file resource according to the target file resource, and send it to the first terminal device;

所述应用服务器,适于接收所述信息包,依据所述信息包中携带的第一终端设备的标识在预设的关联关系列表中查找与所述第一终端设备的标识存在关联关系的第二终端设备的标识,以及,依据所述第二终端设备的标识生成文件获取消息发送至推送服务器中;The application server is adapted to receive the information packet, and according to the identification of the first terminal device carried in the information packet, search for the first terminal device that has an association relationship with the identification of the first terminal device in the preset association relationship list. The identifier of the second terminal device, and generating a file acquisition message according to the identifier of the second terminal device and sending it to the push server;

所述推送服务器,适于在检测到所述第二终端设备的标识对应的第二终端设备在线时,将所述文件获取消息发送至所述第二终端设备侧;The push server is adapted to send the file acquisition message to the second terminal device side when detecting that the second terminal device corresponding to the identifier of the second terminal device is online;

所述第二终端设备,适于依据所述文件获取消息从应用服务器中获取对应的信息包,以及,依据所述信息包携带的目标文件资源的下载地址从文件服务器中下载对应的目标文件资源。The second terminal device is adapted to obtain the corresponding information package from the application server according to the file obtaining message, and download the corresponding target file resource from the file server according to the download address of the target file resource carried in the information package. .

可选地,所述第一终端设备还适于:Optionally, the first terminal device is further adapted to:

依据用户针对悬浮窗口的指定操作生成文件发送请求;Generate a file sending request according to the user's specified operation on the floating window;

将所述文件发送请求发送至文件服务器中;sending the file sending request to the file server;

接收所述文件服务器返回的文件响应消息;receiving a file response message returned by the file server;

依据所述文件响应消息将所述目标文件资源发送至文件服务器中。The target file resource is sent to the file server according to the file response message.

可选地,所述目标文件资源的文件属性信息还包括目标文件资源的大小、目标文件资源的类型、目标文件资源的版本号、目标文件资源的标识。Optionally, the file attribute information of the target file resource further includes the size of the target file resource, the type of the target file resource, the version number of the target file resource, and the identifier of the target file resource.

可选地,所述目标文件资源的类型包括主题、壁纸、铃声、软件、音乐、游戏、视频、电子书。Optionally, the types of the target file resources include themes, wallpapers, ringtones, software, music, games, videos, and e-books.

可选地,所述第二终端设备还适于:Optionally, the second terminal device is further adapted to:

在所述目标文件资源的类型为主题、壁纸、铃声、音乐、视频、电子书时,将所述目标文件资源存储在第二终端设备侧;When the type of the target file resource is theme, wallpaper, ringtone, music, video, and e-book, storing the target file resource on the side of the second terminal device;

在所述目标文件资源的类型为软件和/或游戏时,直接安装所述目标文件资源。When the type of the target file resource is software and/or a game, the target file resource is directly installed.

与背景技术相比,本发明具有如下有益效果:Compared with the background technology, the present invention has the following beneficial effects:

在本发明中,第一终端设备与第二终端设备在进行文件资源的传输时,可以不同时处于在线状态,即第一终端设备在线时先将目标文件资源上传至后台服务器,此时第二终端设备不一定需要在线,当第二终端设备在线时再到后台服务器中下载所述目标文件资源,从而减少了文件资源传输的限制,提高用户体验。In the present invention, when the first terminal device and the second terminal device transmit the file resources, they may not be online at the same time, that is, the first terminal device first uploads the target file resources to the background server when online The terminal device does not necessarily need to be online, and when the second terminal device is online, the target file resource is downloaded from the background server, thereby reducing the limitation of file resource transmission and improving user experience.

上述说明仅是本发明技术方案的概述,为了能够更清楚了解本发明的技术手段,而可依照说明书的内容予以实施,并且为了让本发明的上述和其它目的、特征和优点能够更明显易懂,以下特举本发明的具体实施方式。The above description is only an overview of the technical solutions of the present invention, in order to be able to understand the technical means of the present invention more clearly, it can be implemented according to the content of the description, and in order to make the above and other purposes, features and advantages of the present invention more obvious and easy to understand , the following specific embodiments of the present invention are given.

附图说明Description of drawings

通过阅读下文优选实施方式的详细描述,各种其他的优点和益处对于本领域普通技术人员将变得清楚明了。附图仅用于示出优选实施方式的目的,而并不认为是对本发明的限制。而且在整个附图中,用相同的参考符号表示相同的部件。在附图中:Various other advantages and benefits will become apparent to those of ordinary skill in the art upon reading the following detailed description of the preferred embodiments. The drawings are for the purpose of illustrating preferred embodiments only and are not to be considered limiting of the invention. Also, the same components are denoted by the same reference numerals throughout the drawings. In the attached image:

图1示出了本发明的一种离线文件传输的方法实施例一的步骤流程图;FIG. 1 shows a flow chart of the steps of Embodiment 1 of an offline file transmission method according to the present invention;

图2示出了本发明的一种离线文件传输的方法实施例二的步骤流程图;FIG. 2 shows a flow chart of steps of Embodiment 2 of an offline file transmission method of the present invention;

图3示出了本发明的一种离线文件传输的方法实施例三的步骤流程图;FIG. 3 shows a flow chart of steps of Embodiment 3 of a method for offline file transmission according to the present invention;

图4示出了本发明的一种离线文件传输的方法实施例四的步骤流程图;FIG. 4 shows a flowchart of the steps of Embodiment 4 of an offline file transmission method of the present invention;

图5示出了本发明的一种离线文件传输的方法实施例五的步骤流程图;FIG. 5 shows a flowchart of the steps of Embodiment 5 of an offline file transmission method according to the present invention;

图6示出了本发明的一种离线文件传输的方法实施例一中离线文件发送提醒示意图;6 shows a schematic diagram of an offline file sending reminder in Embodiment 1 of an offline file transmission method of the present invention;

图7示出了本发明的一种离线文件传输的方法实施例一中悬浮窗口指定操作示意图;FIG. 7 shows a schematic diagram of a designation operation of a floating window in Embodiment 1 of an offline file transfer method of the present invention;

图8示出了本发明的一种离线文件传输的方法实施例一中离线提醒示意图;8 shows a schematic diagram of offline reminder in Embodiment 1 of an offline file transmission method of the present invention;

图9示出了本发明的一种用于离线文件传输的终端设备实施例一的结构框图;9 shows a structural block diagram of Embodiment 1 of a terminal device for offline file transmission according to the present invention;

图10示出了本发明的一种用于离线文件传输的服务器实施例一的结构框图;FIG. 10 shows a structural block diagram of Embodiment 1 of a server for offline file transfer according to the present invention;

图11示出了本发明的一种用于离线文件传输的服务器实施例二的结构框图;11 shows a structural block diagram of a second embodiment of a server for offline file transfer according to the present invention;

图12示出了本发明的一种用于离线文件传输的终端设备实施例二的结构框图;12 shows a structural block diagram of Embodiment 2 of a terminal device for offline file transmission according to the present invention;

图13示出了本发明的一种离线文件传输的系统实施例的结构框图。FIG. 13 shows a structural block diagram of an embodiment of an offline file transmission system of the present invention.

具体实施方式Detailed ways

下面将参照附图更详细地描述本公开的示例性实施例。虽然附图中显示了本公开的示例性实施例,然而应当理解,可以以各种形式实现本公开而不应被这里阐述的实施例所限制。相反,提供这些实施例是为了能够更透彻地理解本公开,并且能够将本公开的范围完整的传达给本领域的技术人员。Exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be embodied in various forms and should not be limited by the embodiments set forth herein. Rather, these embodiments are provided so that the present disclosure will be more thoroughly understood, and will fully convey the scope of the present disclosure to those skilled in the art.

参照图1,示出了本发明的一种离线文件传输的方法实施例一的步骤流程图,本发明实施例从第一终端设备侧进行说明,其中,所述第一终端设备为目标文件资源的发送方,本发明实施例可以包括如下步骤:Referring to FIG. 1, a flow chart of steps of Embodiment 1 of an offline file transmission method of the present invention is shown. The embodiment of the present invention is described from the side of a first terminal device, wherein the first terminal device is a target file resource The sender, the embodiment of the present invention may include the following steps:

步骤101,当第一终端设备没有检测到第二终端设备的接入时,在第一终端设备侧通过悬浮窗口将目标文件资源发送至第一服务器中;Step 101, when the first terminal device does not detect the access of the second terminal device, send the target file resource to the first server through the floating window on the side of the first terminal device;

其中,所述目标文件资源为第一终端侧依据用户发出的文件资源选定指令获得的文件资源;所述文件资源选定指令为用户在第一终端设备侧展示的文件资源下载列表中选择的对某文件资源的下载指令,或者,所述文件资源选定指令为用户在第一终端设备侧存储的文件资源中选择的对某文件资源的选定指令。Wherein, the target file resource is the file resource obtained by the first terminal side according to the file resource selection instruction sent by the user; the file resource selection instruction is the file resource selected by the user in the file resource download list displayed by the first terminal device side A download instruction for a certain file resource, or, the file resource selection instruction is a selection instruction for a certain file resource selected by the user from the file resources stored on the side of the first terminal device.

在本发明的一种优选实施例中,在所述101步骤之前,还可以包括:检测用户针对悬浮窗口发起的指定操作,所述指定操作包括用户将目标文件资源拖送到悬浮窗口的操作,和/或,用户点击悬浮窗口上的文件选定按钮,在第一终端设备弹出的文件路径选择窗口中选择目标文件资源的路径的操作;In a preferred embodiment of the present invention, before the step 101, it may further include: detecting a specified operation initiated by the user with respect to the floating window, where the specified operation includes an operation of the user dragging the target file resource to the floating window, And/or, the user clicks the file selection button on the floating window, and selects the path of the target file resource in the file path selection window popped up by the first terminal device;

当检测到所述指定操作时,发出提醒消息询问用户是否需要离线发送目标文件资源;When the specified operation is detected, a reminder message is sent to ask the user whether the target file resource needs to be sent offline;

所述步骤101具体可以为:The step 101 may specifically be:

在接收到用户发送的离线确认指令后,通过悬浮窗口将所述目标文件资源发送至第一服务器中,所述离线确认指令为用户指示的确认离线发送所述目标文件资源的指令。After receiving the offline confirmation instruction sent by the user, the target file resource is sent to the first server through the floating window, and the offline confirmation instruction is an instruction instructed by the user to confirm the offline sending of the target file resource.

在本发明的一种优选实施例中,所述步骤101可以包括如下子步骤:In a preferred embodiment of the present invention, the step 101 may include the following sub-steps:

子步骤S11,在第一终端设备侧依据用户针对悬浮窗口的指定操作生成文件发送请求;Sub-step S11, generating a file sending request on the side of the first terminal device according to the user's specified operation for the floating window;

子步骤S12,在第一终端设备侧将所述文件发送请求发送至第一服务器中;Sub-step S12, sending the file sending request to the first server on the side of the first terminal device;

子步骤S13,在第一终端设备侧接收所述第一服务器返回的文件响应消息;Sub-step S13, receiving the file response message returned by the first server on the side of the first terminal device;

子步骤S14,在第一终端设备侧依据所述文件响应消息将所述目标文件资源发送至第一服务器中。Sub-step S14, the first terminal device side sends the target file resource to the first server according to the file response message.

在本发明的一种优选实施例中,所述子步骤S14进一步可以包括如下子步骤:In a preferred embodiment of the present invention, the sub-step S14 may further include the following sub-steps:

子步骤S141,在第一终端设备侧依据所述文件响应消息对将所述目标文件资源进行加密;Sub-step S141, encrypting the target file resource on the first terminal device side according to the file response message;

子步骤S142,将所述加密后的目标文件资源发送至第一服务器中。Sub-step S142, sending the encrypted target file resource to the first server.

步骤102,在第一终端设备侧接收所述第一服务器返回的所述目标文件资源的下载地址,所述目标文件资源的下载地址为所述第一服务器依据所述目标文件资源生成;Step 102: Receive the download address of the target file resource returned by the first server at the first terminal device side, where the download address of the target file resource is generated by the first server according to the target file resource;

步骤103,在第一终端设备侧依据所述目标文件资源的下载地址构建信息包并发送至第二服务器中。Step 103, constructing an information package on the side of the first terminal device according to the download address of the target file resource and sending it to the second server.

在本发明的一种优选实施例中,所述步骤103可以包括如下子步骤:In a preferred embodiment of the present invention, the step 103 may include the following sub-steps:

在第一终端设备侧获取所述目标文件资源的文件属性信息;Obtain the file attribute information of the target file resource on the side of the first terminal device;

在第一终端设备侧构建所述目标文件资源的下载地址以及所述文件属性信息的信息包;constructing the download address of the target file resource and the information package of the file attribute information on the side of the first terminal device;

在第一终端设备侧将所述信息包发送至第二服务器中。The information packet is sent to the second server on the side of the first terminal device.

其中,所述目标文件资源的文件属性信息还可以包括目标文件资源的大小、目标文件资源的类型、目标文件资源的版本号、目标文件资源的标识。The file attribute information of the target file resource may further include the size of the target file resource, the type of the target file resource, the version number of the target file resource, and the identifier of the target file resource.

作为本发明实施例的一种优选示例,所述目标文件资源的类型包括主题、壁纸、铃声、软件、音乐、游戏、视频、电子书。As a preferred example of the embodiment of the present invention, the types of the target file resources include themes, wallpapers, ringtones, software, music, games, videos, and e-books.

在本发明的一种优选实施例中,所述方法还可以包括:In a preferred embodiment of the present invention, the method may further include:

在第一终端设备侧接收第三服务器发送的信息确认指令;receiving an information confirmation instruction sent by the third server on the side of the first terminal device;

在第一终端设备侧将所述信息确认指令展示给用户;presenting the information confirmation instruction to the user on the side of the first terminal device;

接收用户选择的确认信息,并将所述确认信息发送至第二服务器中。The confirmation information selected by the user is received, and the confirmation information is sent to the second server.

在本发明的一种优选实施例中,所述信息确认指令包括第二终端设备的标识,所述确认信息包括第一确认信息以及第二确认信息,所述第一确认信息为依据用户选定的确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;所述第二确认信息为依据用户选定的不确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息。In a preferred embodiment of the present invention, the information confirmation instruction includes an identifier of the second terminal device, the confirmation information includes first confirmation information and second confirmation information, and the first confirmation information is selected according to the user. The information generated by confirming that the second terminal device corresponding to the identifier of the second terminal device is the file recipient; 2. Information generated by the terminal device as the recipient of the file.

在本发明的一种优选实施例中,所述方法还可以包括:In a preferred embodiment of the present invention, the method may further include:

在第一终端设备侧生成文件发送列表,所述文件发送列表为通过所述悬浮窗口进行离线发送的目标文件资源组织成的列表。A file sending list is generated on the side of the first terminal device, where the file sending list is a list organized by target file resources to be sent offline through the floating window.

在本发明的一种优选实施例中,所述文件发送列表中针对每个目标文件资源具有文件发送状态信息,所述文件发送状态信息包括成功发送状态、正在发送状态、等待发送状态以及发送失败状态。In a preferred embodiment of the present invention, the file sending list has file sending status information for each target file resource, and the file sending status information includes successful sending status, sending status, waiting to send status, and sending failure state.

需要说明的是,所述第一服务器为文件服务器,所述第二服务器为应用服务器,所述第三服务器为推送服务器。It should be noted that the first server is a file server, the second server is an application server, and the third server is a push server.

参照图2,示出了本发明的一种离线文件传输的方法实施例二的步骤流程图,本发明实施例从第二服务器侧进行说明,其中,所述第二服务器为应用服务器,本发明实施例可以包括如下步骤:Referring to FIG. 2, it shows a flowchart of steps of Embodiment 2 of an offline file transfer method of the present invention. The embodiment of the present invention is described from the second server side, wherein the second server is an application server, and the present invention Embodiments may include the following steps:

步骤201,在第二服务器侧接收第一终端设备侧发送的信息包;Step 201, receiving at the second server side the information packet sent by the first terminal device side;

步骤202,所述第二服务器获取所述第一终端设备的标识;Step 202, the second server obtains the identifier of the first terminal device;

步骤203,在第二服务器侧的预设的关联关系列表中查找与所述第一终端设备的标识存在关联关系的第二终端设备的标识;Step 203: Search for an identifier of a second terminal device that has an associated relationship with the identifier of the first terminal device in a preset association relationship list on the second server side;

步骤204,在第二服务器侧依据所述第二终端设备的标识生成文件获取消息发送至第三服务器中。Step 204: Generate a file acquisition message on the second server side according to the identifier of the second terminal device and send it to the third server.

在本发明的一种优选实施例中,在步骤203之前,还包括:In a preferred embodiment of the present invention, before step 203, the method further includes:

在第二服务器侧生成信息确认指令;generating an information confirmation instruction on the second server side;

在第二服务器侧将所述信息确认指令发送至第三服务器中,由第三服务器发送至第一终端设备侧;Send the information confirmation instruction to the third server on the second server side, and the third server sends it to the first terminal device side;

在第二服务器侧接收第一终端设备返回的确认信息。The confirmation information returned by the first terminal device is received at the second server side.

在本发明的一种优选实施例中,所述信息确认指令包括第二终端设备的标识,所述确认信息包括第一确认信息以及第二确认信息,所述第一确认信息为依据用户选定的确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;所述第二确认信息为依据用户选定的不确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;In a preferred embodiment of the present invention, the information confirmation instruction includes an identifier of the second terminal device, the confirmation information includes first confirmation information and second confirmation information, and the first confirmation information is selected according to the user. The information generated by confirming that the second terminal device corresponding to the identifier of the second terminal device is the file recipient; 2. Information generated by the terminal device as the recipient of the file;

所述方法还包括:The method also includes:

若所述确认信息为第一确认信息,则执行所述在第二服务器侧依据所述第二终端设备的标识生成文件获取消息发送至第三服务器中的步骤;If the confirmation information is the first confirmation information, executing the step of generating a file acquisition message on the second server side according to the identifier of the second terminal device and sending it to the third server;

若所述确认信息为第二确认信息,则在第二服务器侧重新获取第二终端设备的标识。If the confirmation information is the second confirmation information, the identifier of the second terminal device is re-acquired on the second server side.

其中,所述第一服务器为文件服务器,所述第二服务器为应用服务器,所述第三服务器为推送服务器。The first server is a file server, the second server is an application server, and the third server is a push server.

参照图3,示出了本发明的一种离线文件传输的方法实施例三的步骤流程图,本发明实施例从第三服务器侧进行说明,其中,所述第三服务器为推送服务器,本发明实施例可以包括如下步骤:Referring to FIG. 3 , a flowchart of steps of Embodiment 3 of an offline file transmission method of the present invention is shown. The embodiment of the present invention is described from the side of a third server, wherein the third server is a push server, and the present invention Embodiments may include the following steps:

步骤301,在第三服务器侧接收第二服务器发送的文件获取消息,所述文件获取消息包括第二终端设备的标识;Step 301: Receive a file acquisition message sent by a second server on the third server side, where the file acquisition message includes an identifier of the second terminal device;

步骤302,在第三服务器侧检测到所述第二终端设备的标识对应的第二终端设备在线时,将所述文件获取消息发送至所述第二终端设备侧。Step 302: When the third server side detects that the second terminal device corresponding to the identifier of the second terminal device is online, the file acquisition message is sent to the second terminal device side.

在本发明的一种优选实施例中,所述步骤302可以包括如下子步骤:In a preferred embodiment of the present invention, the step 302 may include the following sub-steps:

子步骤S31,在第三服务器侧获取所有已经接入的终端设备的标识;Sub-step S31, acquiring the identifiers of all connected terminal devices on the third server side;

子步骤S32,在第三服务器侧判断所述所有接入的终端设备的标识中是否存在与所述第二终端设备的标识相同的终端设备;Sub-step S32, judge on the third server side whether there is a terminal device identical to the identifier of the second terminal device in the identifiers of all the connected terminal devices;

子步骤S33,在第三服务器侧判定所述所有接入的终端设备的标识中存在与所述第二终端设备的标识相同的终端设备时,判定所述第二终端设备的标识对应的第二终端设备在线。Sub-step S33, when the third server side determines that the identifiers of all the connected terminal devices have the same terminal device as the identifier of the second terminal device, determine the second terminal device corresponding to the identifier of the second terminal device. The terminal device is online.

在本发明的一种优选实施例中,所述方法还包括:In a preferred embodiment of the present invention, the method further includes:

在第三服务器侧接收第二服务器发送的信息确认指令;receiving, on the third server side, an information confirmation instruction sent by the second server;

在第三服务器侧将所述信息确认指令发送至第一终端设备中。The information confirmation instruction is sent to the first terminal device on the third server side.

需要说明的是,所述第一服务器为文件服务器,所述第二服务器为应用服务器,所述第三服务器为推送服务器。It should be noted that the first server is a file server, the second server is an application server, and the third server is a push server.

参照图4,示出了本发明的一种离线文件传输的方法实施例四的步骤流程图,本发明实施例从第二终端设备侧进行说明,其中,所述第二终端设备为目标文件资源的接收方,本发明实施例可以包括如下步骤:Referring to FIG. 4 , a flowchart of steps in Embodiment 4 of an offline file transmission method according to the present invention is shown. The embodiment of the present invention is described from the side of a second terminal device, where the second terminal device is a target file resource Receiver, the embodiment of the present invention may include the following steps:

步骤401,在第二终端设备侧接收第三服务器发送的文件获取消息;Step 401, receiving a file acquisition message sent by a third server on the second terminal device side;

步骤402,在第二终端设备侧依据所述文件获取消息从第二服务器中获取对应的信息包,所述信息包包括目标文件资源的下载地址;Step 402, on the second terminal device side, obtain a corresponding information package from the second server according to the file obtaining message, where the information package includes the download address of the target file resource;

步骤403,在第二终端设备侧依据所述目标文件资源的下载地址从第一服务器中下载对应的目标文件资源。Step 403 , on the second terminal device side, download the corresponding target file resource from the first server according to the download address of the target file resource.

在本发明的一种优选实施例中,所述信息包包括文件属性信息,所述文件属性信息可以包括目标文件资源的类型,所述目标文件资源的类型包括主题、壁纸、铃声、软件、音乐、游戏、视频、电子书,所述的方法还可以包括:In a preferred embodiment of the present invention, the information package includes file attribute information, and the file attribute information may include the type of the target file resource, and the type of the target file resource includes themes, wallpapers, ringtones, software, music , games, videos, e-books, the method may also include:

若所述目标文件资源的类型为主题、壁纸、铃声、音乐、视频、电子书,则将所述目标文件资源存储在第二终端设备侧;If the type of the target file resource is theme, wallpaper, ringtone, music, video, e-book, then the target file resource is stored on the second terminal device side;

若所述目标文件资源的类型为软件和/或游戏,则直接安装所述目标文件资源。If the type of the target file resource is software and/or a game, the target file resource is directly installed.

在本发明的一种优选实施例中,在所述步骤401之前,还可以包括:In a preferred embodiment of the present invention, before the step 401, it may further include:

在第二终端设备侧监听网络状态,所述网络状态包括当前网络可用以及当前网络不可用;Monitor the network status on the second terminal device side, where the network status includes the current network available and the current network unavailable;

若当前网络可用,则在第二终端设备侧连接当前网络;If the current network is available, connect the current network on the second terminal device side;

在第二终端设备侧连接所述第三服务器。The third server is connected on the second terminal device side.

在本发明的一种优选实施例中,若所述第二终端设备为移动设备,所述在第二终端设备侧监听网络状态的步骤包括:In a preferred embodiment of the present invention, if the second terminal device is a mobile device, the step of monitoring the network status on the second terminal device side includes:

在所述第二终端设备侧注册网络状态变化接收服务 ConnctionChangeReceiver;Register the network state change receiving service ConnctionChangeReceiver on the second terminal device side;

在第二终端设备侧采用所述网络状态变化接收服务 ConnctionChangeReceiver接收系统服务SystemService发出的广播CONNECTIVITY_CHANGE;On the second terminal device side, use the network state change receiving service ConnctionChangeReceiver to receive the broadcast CONNECTIVITY_CHANGE sent by the system service SystemService;

若所述广播CONNECTIVITY_CHANGE调用的方法wifiNetInfo.isConnected()返回的布尔值为真,则判定当前网络可用;If the boolean value returned by the method wifiNetInfo.isConnected() called by the broadcast CONNECTIVITY_CHANGE is true, it is determined that the current network is available;

若所述广播CONNECTIVITY_CHANGE调用的方法 wifiNetInfo.isConnected()返回的布尔值为真,则判定当前网络不可用。If the boolean value returned by the method wifiNetInfo.isConnected() called by the broadcast CONNECTIVITY_CHANGE is true, it is determined that the current network is unavailable.

在本发明的另一种优选实施例中,若所述第二终端设备为计算设备,所述在第二终端设备侧监听网络状态的步骤包括:In another preferred embodiment of the present invention, if the second terminal device is a computing device, the step of monitoring the network status on the second terminal device side includes:

在第二终端设备侧调用网络接口API查询当前的网络状态。The network interface API is called on the second terminal device side to query the current network status.

需要说明的是,所述第一服务器为文件服务器,所述第二服务器为应用服务器,第三服务器为推送服务器。It should be noted that the first server is a file server, the second server is an application server, and the third server is a push server.

参照图5,示出了本发明的一种离线文件传输的方法实施例五的步骤流程图,在本发明实施例中,所述第一终端设备为目标文件资源的发送方,所述第二终端设备为目标文件资源的接收方,所述第一终端设备和/或所述第二终端设备可以为移动设备或计算设备,其中,所述计算设备是一种能够按照程序运行,自动、高速处理海量数据的智能电子设备,如台式电脑、笔记本电脑等。所述移动设备是一种可以在移动中使用的计算设备,如手机,本发明实施例对第一终端设备以及第二终端设备的类型无需加以限制。Referring to FIG. 5 , a flowchart of steps in Embodiment 5 of an offline file transmission method of the present invention is shown. In this embodiment of the present invention, the first terminal device is a sender of target file resources, and the second The terminal device is the recipient of the target file resource, and the first terminal device and/or the second terminal device may be a mobile device or a computing device, wherein the computing device is a Intelligent electronic devices that process massive amounts of data, such as desktop computers, laptops, etc. The mobile device is a computing device that can be used in movement, such as a mobile phone, and there is no need to limit the types of the first terminal device and the second terminal device in this embodiment of the present invention.

本发明实施例可以包括如下步骤:This embodiment of the present invention may include the following steps:

步骤501,在第一终端设备侧依据用户发出的文件资源选定指令获取对应的目标文件资源;Step 501, obtaining a corresponding target file resource on the side of the first terminal device according to a file resource selection instruction issued by a user;

在本发明的一种优选实施例中,所述文件资源选定指令可以为用户在第一终端设备侧展示的文件资源下载列表中选择的对某文件资源的下载指令。具体而言,在第一终端设备侧安装有第一客户端程序,所述第一客户端程序中展示有海量免费的文件资源以供用户下载,用户可以从该第一客户端程序的文件资源中选择自己喜欢的文件资源进行下载。在实际中,当用户通过鼠标或点触操作在第一客户端程序展示的文件资源的下载列表中选定自己喜欢的文件资源后,即生成对应的文件资源下载指令,第一客户端程序接收到所述文件资源下载指令后,从服务器中下载对应的文件资源作为目标文件资源存储到第一终端设备侧。In a preferred embodiment of the present invention, the file resource selection instruction may be a download instruction for a certain file resource selected by the user in the file resource download list displayed on the side of the first terminal device. Specifically, a first client program is installed on the side of the first terminal device, and a large number of free file resources are displayed in the first client program for the user to download, and the user can download the file resources from the first client program Choose your favorite file resource to download. In practice, after the user selects his favorite file resource from the download list of file resources displayed by the first client program through a mouse or touch operation, the corresponding file resource download instruction is generated, and the first client program receives After the file resource download instruction is received, the corresponding file resource is downloaded from the server as a target file resource and stored on the side of the first terminal device.

在实际中,所述第一客户端程序在计算机侧开启一悬浮窗口用于目标文件资源的传输,当用户在第一终端设备侧开启第一客户端程序时,第一客户端程序可以在悬浮窗口中或在第一终端设备的预设位置弹出弹窗提醒用户可以发送离线文件资源到第二终端设备上,即第一终端设备不连接第二终端设备也能随时发文件资源(如图6所示)。In practice, the first client program opens a floating window on the computer side for the transmission of target file resources. When the user opens the first client program on the first terminal device side, the first client program can be suspended in the floating window. A pop-up window pops up in the window or at the preset position of the first terminal device to remind the user that offline file resources can be sent to the second terminal device, that is, the first terminal device can send file resources at any time without connecting to the second terminal device (as shown in Figure 6). shown).

具体来说,悬浮窗口的作用在于,当主程序的窗口在最小化时,还可以提示用户看到该程序的运行状态,并可以通过点击这些小窗口,快捷地打开主程序的窗口。悬浮窗口包含了一个可以供用户访问的预设入口,在屏幕上显示悬浮窗口后,用户可以通过该预设入口访问预设内容或执行预设操作。例如,用户通过点击预设入口可以启动托送发文件的操作。Specifically, the function of the floating window is that when the window of the main program is minimized, it can also prompt the user to see the running status of the program, and can quickly open the window of the main program by clicking on these small windows. The floating window includes a preset entry that can be accessed by the user. After the floating window is displayed on the screen, the user can access preset content or perform preset operations through the preset entry. For example, the user can start the operation of sending the file by clicking on the preset entry.

在本发明的另一种优选实施例中,所述文件资源选定指令可以为用户在第一终端设备侧存储的文件资源中选择的对某文件资源的选定指令。具体而言,用户还可以在第一终端侧存储的已有文件资源中选择某文件资源作为目标文件资源。In another preferred embodiment of the present invention, the file resource selection instruction may be a selection instruction for a certain file resource selected by the user from the file resources stored on the side of the first terminal device. Specifically, the user may also select a certain file resource from the existing file resources stored on the side of the first terminal as the target file resource.

作为本实施例的一种优选示例,所述目标文件资源具有文件属性信息,所述文件属性信息可以包括目标文件资源的大小、目标文件资源的类型、目标文件资源的版本号、目标文件资源的标识等等。其中,所述目标文件资源的类型可以包括主题、壁纸、铃声、软件、音乐、游戏、视频、电子书等多种类型。As a preferred example of this embodiment, the target file resource has file attribute information, and the file attribute information may include the size of the target file resource, the type of the target file resource, the version number of the target file resource, the logo, etc. Wherein, the types of the target file resources may include themes, wallpapers, ringtones, software, music, games, videos, e-books, and other types.

步骤502,当第一终端设备没有检测到第二终端设备的接入时,在第一终端设备侧通过悬浮窗口将所述目标文件资源发送至文件服务器中;Step 502, when the first terminal device does not detect the access of the second terminal device, send the target file resource to the file server through the floating window on the side of the first terminal device;

具体而言,在第一终端设备侧获取到目标文件资源后,第一终端设备采用所述第一客户端程序检测是否有第二终端设备接入,在没有第二终端设备接入的情况下,第一客户端程序检测用户有没有针对悬浮窗口发起指定操作。其中,所述针对悬浮窗口发起的指定操作可以有多种方式,参考图7所示的悬浮窗口指定操作示意图,作为本实施例的一种优选示例,所述用户针对悬浮窗口发起的指定操作可以包括用户将目标文件资源拖送到悬浮窗口的操作,即用户从第一终端侧存储的文件资源中选择目标文件资源后,直接将目标文件资源拖到悬浮窗口中的操作。作为本实施例的另一种优选示例,所述用户针对悬浮窗口发起的指定操作可以包括用户点击悬浮窗口上的文件选定按钮,在第一终端设备弹出的文件路径选择窗口中选择目标文件资源的路径的操作,例如,所述文件选定按钮可以为图7所示的“选择要发送的文件”的功能按钮,点击文件选定按钮后,第一终端设备侧会弹出文件路径选择窗口,用户可以在该文件路径选择窗口中选择目标文件资源的路径。Specifically, after the first terminal device side acquires the target file resource, the first terminal device uses the first client program to detect whether there is access by the second terminal device, and in the case of no access by the second terminal device , the first client program detects whether the user initiates a specified operation on the floating window. Wherein, the designated operation initiated for the floating window may be in various ways. Referring to the schematic diagram of the designated operation of the floating window shown in FIG. 7 , as a preferred example of this embodiment, the designated operation initiated by the user for the floating window may be: It includes the operation of dragging the target file resource to the floating window by the user, that is, the operation of directly dragging the target file resource into the floating window after the user selects the target file resource from the file resources stored on the side of the first terminal. As another preferred example of this embodiment, the specified operation initiated by the user on the floating window may include that the user clicks a file selection button on the floating window, and selects the target file resource in the file path selection window popped up by the first terminal device For example, the file selection button can be the function button of "select the file to be sent" shown in Figure 7. After clicking the file selection button, a file path selection window will pop up on the side of the first terminal device, The user can select the path of the target file resource in the file path selection window.

第一客户端程序检测到用户针对悬浮窗口发起指定操作时,第一客户端程序可以发出提醒消息来询问用户是否需要离线发送目标文件资源,具体来说,所述提醒消息可以通过在悬浮窗口中或在第一终端设备的预设位置弹出弹窗来展示给用户,在接收到用户选定的离线确认指令后,离线发送所述目标文件资源。其中,所述离线确认指令为用户指示的确认离线发送所述目标文件资源的指令。所述离线确认指令可以体现为用户点击弹窗中的“确认发送离线文件”等类似功能按钮而触发的指令。When the first client program detects that the user initiates a specified operation on the floating window, the first client program can send a reminder message to ask the user whether the target file resource needs to be sent offline. Or a pop-up window pops up at a preset position of the first terminal device to be displayed to the user, and after receiving the offline confirmation instruction selected by the user, the target file resource is sent offline. The offline confirmation instruction is an instruction instructed by the user to confirm that the target file resource is sent offline. The offline confirmation instruction may be embodied as an instruction triggered by the user clicking a "confirm sending offline file" and other similar function buttons in the pop-up window.

另一方面,若用户指示不需要离线发送目标文件资源,可以点击弹窗中的“不发送离线文件”等类似功能按钮来触发不发送离线文件的指令,此时,所述目标文件资源在所述悬浮窗口中处于等待发送状态。On the other hand, if the user indicates that the target file resource does not need to be sent offline, the user can click the "Do not send offline file" and other similar function buttons in the pop-up window to trigger the instruction not to send the offline file. At this time, the target file resource is in the Waiting to send in the above floating window.

在实际应用中,用户触发离线确认指令或触发不发送离线文件的指令的方式可以有多种,除了上述的点击“确认发送离线文件”、“不发送离线文件”等类似功能按钮,以实现目标文件资源的离线发送与否触发外,若第一终端设备中安装有重力感应装置,还可以通过摇动第一终端设备来触发重力感应装置,进而实现对所述目标文件资源的离线发送与否的触发。本发明实施例中,所述摇动可以理解为能够触发重力感应装置的任意操作,如上下或左右晃动所述移动设备等,本发明实施例对具体的操作不做限定。In practical applications, there are many ways for users to trigger an offline confirmation instruction or an instruction not to send offline files, except for the above-mentioned clicks of “Confirm to send offline files”, “Do not send offline files” and other similar function buttons to achieve the goal In addition to whether the offline sending of the file resource is triggered, if a gravity sensing device is installed in the first terminal device, the gravity sensing device can also be triggered by shaking the first terminal device, thereby realizing the offline sending of the target file resource. trigger. In the embodiment of the present invention, the shaking can be understood as any operation that can trigger the gravity sensing device, such as shaking the mobile device up and down or left and right, and the embodiment of the present invention does not limit the specific operation.

在本发明的一种优选实施例中,当接收到用户发送的离线确认指令后,步骤502进一步可以为,在第一终端设备侧依据所述用户针对悬浮窗口的指定操作生成文件发送请求;在第一终端设备侧将所述文件发送请求发送至文件服务器中;在第一终端设备侧接收所述文件服务器返回的文件响应消息;在第一终端设备侧依据所述文件响应消息将所述目标文件资源发送至文件服务器中。具体来说,所述文件发送请求可以包括目标文件资源的大小,文件服务器接收到所述文件发送请求后,依据所述目标文件资源的大小判断自身的内存大小是否大于所述目标文件资源的大小,若大于,则文件服务器返回文件响应消息,以通知第一终端设备上传目标文件资源;否则,文件服务器不返回文件响应消息。若第一终端设备在预设时间段内接收到文件响应消息,则将依据所述文件响应消息将所述目标文件资源发送至文件服务器中;若第一终端设备在预设时间段内没有接收到文件响应消息,则不将所述目标文件资源发送至文件服务器中,此时,所述目标文件资源在所述悬浮窗口中处于等待发送状态。In a preferred embodiment of the present invention, after receiving the offline confirmation instruction sent by the user, step 502 may further be: generating a file sending request on the side of the first terminal device according to the user's designated operation for the floating window; The first terminal device side sends the file sending request to the file server; the first terminal device side receives the file response message returned by the file server; the first terminal device side sends the target The file resource is sent to the file server. Specifically, the file sending request may include the size of the target file resource. After receiving the file sending request, the file server determines whether its own memory size is larger than the size of the target file resource according to the size of the target file resource. , if it is greater than , the file server returns a file response message to notify the first terminal device to upload the target file resource; otherwise, the file server does not return a file response message. If the first terminal device receives the file response message within the preset time period, it will send the target file resource to the file server according to the file response message; if the first terminal device does not receive the file response message within the preset time period When the file response message is received, the target file resource is not sent to the file server, and at this time, the target file resource is in a waiting state in the floating window.

在实际中,为了保障目标文件资源的安全,第一客户端程序在上传所述目标文件资源之前,可以先按照第一预设规则对所述目标文件资源进行加密后再上传至文件服务器中,所述第一预设规则可以为所述第一客户端程序与后台服务器预先约定的加密解密规则。In practice, in order to ensure the security of the target file resource, before uploading the target file resource, the first client program may encrypt the target file resource according to the first preset rule before uploading it to the file server. The first preset rule may be an encryption and decryption rule pre-agreed by the first client program and the background server.

步骤503,文件服务器生成所述目标文件资源的下载地址并返回第一终端设备侧;Step 503, the file server generates the download address of the target file resource and returns it to the first terminal device side;

具体而言,所述文件服务器是共享文件的服务器,用于存储目标文件资源。在实际应用中,所述文件服务器中只保存预设时间段内的目标文件资源,文件服务器可以对存储的目标文件资源进行周期性或不定期地检测,若检测到有目标文件资源的存储的时间超过预设时间段,则删除所述目标文件资源。其中,所述预设时间段可以为针对每个目标文件资源的存入时间为开始时间设置的时间段(如一个月,超过存入时间一个月的目标文件资源将被删除);或者,所述预设时间还可以为文件服务器为所有存储的文件资源统一设定的时间界限(如2013年7月10号前存储的目标文件资源将删除)。Specifically, the file server is a server for sharing files and is used for storing target file resources. In practical applications, the file server only saves the target file resources within a preset time period, and the file server may periodically or irregularly detect the stored target file resources. If the time exceeds the preset time period, the target file resource is deleted. Wherein, the preset time period may be the time period set as the start time for the storage time of each target file resource (for example, one month, the target file resource exceeding the storage time for one month will be deleted); The preset time may also be a time limit uniformly set by the file server for all stored file resources (for example, the target file resources stored before July 10, 2013 will be deleted).

文件服务器接收到目标文件资源后,获取该目标文件资源在文件服务器侧的存储地址,将所述存储地址按照第二预设规则生成所述目标文件资源的下载地址,对所述目标文件资源的下载地址按照第一预设规则加密后返回第一终端设备侧。After receiving the target file resource, the file server obtains the storage address of the target file resource on the file server side, and generates the download address of the target file resource from the storage address according to the second preset rule. The download address is encrypted according to the first preset rule and returned to the first terminal device side.

在具体实现中,用户可以选定一个或多个目标文件资源,并通过所述悬浮窗口进行发送,此时第一终端设备可以采用所述第一客户端程序生成文件发送列表,所述文件发送列表为通过所述悬浮窗口进行离线发送的目标文件资源组织成的列表,第一终端侧将所述文件发送列表展示在悬浮窗口的预设位置或第一终端设备界面的其他预设位置。所述文件发送列表中具有针对每个目标文件资源的文件发送状态信息,所述文件发送状态信息可以包括成功发送状态、正在发送状态、等待发送状态以及发送失败状态。其中,所述文件发送状态信息是指文件发送至文件服务器的状态信息,所述成功发送状态为在预设时间段内接收到文件服务器返回的对应的下载地址的状态;所述发送失败状态为在预设时间段内没有接收到文件服务器返回的对应的下载地址的状态。In a specific implementation, the user can select one or more target file resources and send them through the floating window. At this time, the first terminal device can use the first client program to generate a file sending list, and the file sending The list is a list of target file resources to be sent offline through the floating window, and the first terminal side displays the file sending list at a preset position of the floating window or other preset positions on the interface of the first terminal device. The file sending list has file sending status information for each target file resource, and the file sending status information may include successful sending status, sending status, waiting for sending status, and sending failure status. Wherein, the file sending status information refers to the status information of the file being sent to the file server, the successful sending status is the status of receiving the corresponding download address returned by the file server within a preset time period; the sending failure status is The status of the corresponding download address returned by the file server is not received within the preset time period.

在实际应用中,文件状态列表中还可以展示查看向导信息,所述查看向导信息用于指导用户如何在第二终端设备中接收并查看离线文件资源。In practical applications, viewing guide information may also be displayed in the file status list, where the viewing guide information is used to instruct the user how to receive and view offline file resources in the second terminal device.

步骤504,在第一终端设备侧构建所述目标文件资源的下载地址以及所述文件属性信息的信息包并发送至应用服务器中;Step 504, constructing the download address of the target file resource and the information package of the file attribute information on the side of the first terminal device and sending them to the application server;

应用于本发明实施例,第一终端设备侧采用第一客户端程序接收到文件服务器返回的目标文件资源的下载地址后,对该目标文件资源的下载地址按照第一预设规则进行解密,然后构建所述目标文件资源的下载地址以及所述文件属性信息的信息包,并对所述信息包采用第一预设规则进行加密后发送至应用服务器中。Applied to the embodiment of the present invention, after receiving the download address of the target file resource returned by the file server by using the first client program, the first terminal device side decrypts the download address of the target file resource according to the first preset rule, and then decrypts the download address of the target file resource. The download address of the target file resource and the information package of the file attribute information are constructed, and the information package is encrypted using the first preset rule and sent to the application server.

需要说明的是,所述信息包实际上是一种记录有目标文件资源的下载地址以及所述文件属性信息的数据结构。It should be noted that the information package is actually a data structure in which the download address of the target file resource and the file attribute information are recorded.

步骤505,应用服务器获取所述第一终端设备的标识,并在预设的关联关系列表中查找与所述第一终端设备的标识存在关联关系的第二终端设备的标识;Step 505, the application server obtains the identifier of the first terminal device, and searches the preset association relationship list for the identifier of the second terminal device that has an associated relationship with the identifier of the first terminal device;

具体而言,所述预设的关联关系列表中存储有发生过连接的第一终端设备的标识与第二终端设备的标识之间的关联关系。所述关联关系生成的过程可以为(以第一终端设备为计算设备,第二终端设备为移动设备的情况举例):Specifically, the preset association relationship list stores the association relationship between the identifier of the first terminal device that has been connected and the identifier of the second terminal device. The process of generating the association relationship may be (taking the first terminal device as a computing device and the second terminal device as a mobile device as an example):

首先计算设备接收移动设备发送的建立长连接的通知消息,通知消息中包括移动设备的标识;若计算设备允许建立长连接,则计算设备将移动设备的标识和计算设备的标识发送至应用服务器,由应用服务器在关联关系列表中记录移动设备和计算设备的关联关系。First, the computing device receives the notification message for establishing a long connection sent by the mobile device, and the notification message includes the identifier of the mobile device; if the computing device allows the establishment of a long connection, the computing device sends the identifier of the mobile device and the identifier of the computing device to the application server, The association relationship between the mobile device and the computing device is recorded by the application server in the association relationship list.

具体地,建立移动设备和计算设备之间的关联关系,主要包括如下步骤:Specifically, establishing an association relationship between a mobile device and a computing device mainly includes the following steps:

1、移动设备在应用服务器上进行认证;1. The mobile device is authenticated on the application server;

1.1在移动设备启动第二客户端程序(即手机助手);1.1 Start the second client program (ie, mobile phone assistant) on the mobile device;

1.2在移动设备上输入手机号后,移动设备将该设备的IMEI和手机号一并发送给应用服务器;1.2 After entering the mobile phone number on the mobile device, the mobile device sends the IMEI and mobile phone number of the device to the application server;

1.3应用服务器向移动设备发送带有认证码的短信;1.3 The application server sends a text message with an authentication code to the mobile device;

1.4在移动设备上输入该认证码,然后发给应用服务器;1.4 Enter the authentication code on the mobile device and send it to the application server;

1.5应用服务器根据该认证码、移动设备号以及IMEI来确定该移动设备的标识为该移动设备所拥有。1.5 The application server determines that the identity of the mobile device is owned by the mobile device according to the authentication code, the mobile device number and the IMEI.

2.在计算设备处2. At the computing device

2.1在计算设备上启动手机助手;2.1 Start the mobile assistant on the computing device;

2.2输入移动设备的手机号后,计算设备将移动设备的手机号和MID一并发送给应用服务器;2.2 After entering the mobile phone number of the mobile device, the computing device sends the mobile phone number and MID of the mobile device to the application server;

2.3应用服务器根据接收到的计算设备的MID、手机号在数据库中查询该手机号所对应的移动设备是否在该应用服务器处进行了认证,如果进行了认证,则在关联关系列表中建立计算设备的MID、手机号、该移动设备的 IMEI的对应关系,例如把它们作为一条记录存储在关联关系列表中;否则向移动设备发出邀请,邀请流程如下:2.3 The application server inquires in the database whether the mobile device corresponding to the mobile phone number has been authenticated at the application server according to the received MID and mobile phone number of the computing device, and if authenticated, establishes the computing device in the association list The corresponding relationship between the MID, mobile phone number, and IMEI of the mobile device, for example, store them as a record in the association list; otherwise, send an invitation to the mobile device, and the invitation process is as follows:

2.3.1应用服务器向移动设备发送一条邀请短信,邀请短信中为一激活链接地址;2.3.1 The application server sends an invitation text message to the mobile device, and the invitation text message contains an activation link address;

2.3.2移动设备接收到该短信时,会弹出一个绑定允许对话框,用户点击确定后,会将该激活链接中的信息发送给应用服务器,应用服务器接收到绑定确认请求后,将该移动设备和对应计算设备绑定。2.3.2 When the mobile device receives the short message, a binding permission dialog box will pop up. After the user clicks OK, the information in the activation link will be sent to the application server. After receiving the binding confirmation request, the application server will The mobile device is bound to the corresponding computing device.

关联关系列表结构是The relationship list structure is

消息的数据库表是:The database table for messages is:

具体地,移动设备的标识是mobile1,计算设备的标识是desktop1,当移动设备要和计算设备进行关联的时候,长连接将这个关联请求发送给计算设备,计算设备同意确认后这个关联mobile1<-->desktop1建立起来了。当应用服务器收到信息包后,应用服务器中还记录了desktop1<-->信息包 file1的映射关系。应用服务器在接收到信息包后,对其进行解密,并获取所述第一终端设备的标识,随后在所述预设的关联关系列表中查找与所述第一终端设备的标识关联的第二终端设备的标识。在实际应用中,所述预设的关联关系列表中所述第一终端设备的标识与所述第二终端设备的标识之间的关联关系存在如下情况:Specifically, the identification of the mobile device is mobile1, and the identification of the computing device is desktop1. When the mobile device is to be associated with the computing device, the long connection sends the association request to the computing device. After the computing device agrees to confirm, the association mobile1<- ->desktop1 is established. After the application server receives the information packet, the application server also records the mapping relationship of desktop1<-->information packet file1. After receiving the information packet, the application server decrypts it, obtains the identifier of the first terminal device, and then searches the preset association relationship list for a second terminal device associated with the identifier of the first terminal device. The identification of the terminal device. In practical applications, the association relationship between the identifier of the first terminal device and the identifier of the second terminal device in the preset association relationship list is as follows:

(1)第一终端设备的标识只与一台第二终端设备的标识对应。在这种情况下,应用服务器选择所述第二终端设备的标识作为所述目标文件资源的接收方。(1) The identifier of the first terminal device only corresponds to the identifier of one second terminal device. In this case, the application server selects the identifier of the second terminal device as the recipient of the target file resource.

(2)第一终端设备的标识与多台第二终端设备的标识对应。在这种情况下,由于在实际中,预设的关联关系列表中还可以存储所述第一终端设备的标识与各第二终端设备的标识最新的发生连接的时间,此时,应用服务器可以根据所述第一终端设备的标识与各第二终端设备的标识最新的发生连接的时间选择最近发生连接的第二终端设备的标识(即最后一台与第一终端设备发生连接的第二终端设备)作为目标文件资源的接收方。(2) The identifier of the first terminal device corresponds to the identifiers of multiple second terminal devices. In this case, since in practice, the preset association relationship list can also store the latest connection time between the identifier of the first terminal device and the identifier of each second terminal device, at this time, the application server can According to the latest connection time between the identifier of the first terminal device and the identifier of each second terminal device, select the identifier of the second terminal device connected recently (that is, the last second terminal connected to the first terminal device). device) as the recipient of the target file resource.

应用服务器获取到作为目标文件资源接收方的第二终端设备的标识后,生成信息确认指令,并通过推送服务器(push服务器)将所述信息确认指令发送至第一终端设备侧,所述信息确认指令包括第二终端设备的标识,所述信息确认指令用于告知第一终端设备确认是否将目标文件资源发送至所述选择的第二终端设备的标识中。如图8所示的离线提醒示意图,第一终端设备在接收到所述信息确认指令后,可以采用第一客户端程序将所述目标文件资源将要发送的第二设备的标识以弹窗等形式展示给用户,若用户选择“立即发送”,说明用户确认所述目标文件资源发送至所述第二终端设备的标识,则第一终端设备侧生成第一确认信息发送至应用服务器侧。此外,若用户的意图不是将所述目标文件资源发送至所述第二终端设备的标识中,用户可以选择“换台设备”等字样的按钮,则第一终端设备侧生成第二确认信息发送至应用服务器中,此时,用户可以将需要接收目标文件资源的第二终端设备接入第一终端设备中,以接收目标文件资源;若用户没有接入任何第二终端设备,则应用服务器再查找所述预设的关联关系列表中是否存在其他与所述第一终端设备的标识关联的第二终端设备的标识,若存在,则获取次最近发生连接的第二终端设备的标识生成信息确认指令发送至第一终端设备侧,以此类推;否则,应用服务器生成连接提醒消息发送至第一终端设备侧,以通知用户连接需要接受目标文件资源的第二终端设备。After the application server obtains the identifier of the second terminal device that is the recipient of the target file resource, it generates an information confirmation instruction, and sends the information confirmation instruction to the first terminal device through a push server (push server), and the information confirmation The instruction includes the identifier of the second terminal device, and the information confirmation instruction is used to inform the first terminal device to confirm whether to send the target file resource to the identifier of the selected second terminal device. As shown in the schematic diagram of offline reminder shown in FIG. 8 , after receiving the information confirmation instruction, the first terminal device can use the first client program to display the identifier of the second device to which the target file resource is to be sent in the form of a pop-up window or the like It is displayed to the user, if the user selects "send immediately", indicating that the user confirms that the target file resource is sent to the identifier of the second terminal device, the first terminal device side generates first confirmation information and sends it to the application server side. In addition, if the user's intention is not to send the target file resource to the identifier of the second terminal device, the user can select a button with words such as "channel changing device", and the first terminal device side generates a second confirmation message to send To the application server, at this time, the user can connect the second terminal device that needs to receive the target file resource to the first terminal device to receive the target file resource; if the user does not access any second terminal device, the application server Find out whether there are other identifiers of the second terminal equipment associated with the identifiers of the first terminal equipment in the preset association relationship list, and if so, obtain the identification generation information of the second most recently connected second terminal equipment to confirm The instruction is sent to the first terminal device side, and so on; otherwise, the application server generates a connection reminder message and sends it to the first terminal device side to notify the user to connect to the second terminal device that needs to accept the target file resource.

步骤506,在应用服务器侧依据所述第二终端设备的标识生成文件获取消息发送至推送服务器中;Step 506, generating a file acquisition message on the application server side according to the identifier of the second terminal device and sending it to the push server;

应用服务器接收到第一终端设备侧发送的第一确认信息后,依据所述第二终端设备的标识生成文件获取消息,并将所述文件获取消息发送至推送服务器(push服务器)中。其中,所述文件获取消息用于通知推送服务器在检测到所述第二终端设备的标识对应的第二终端设备在线时,将文件获取消息发送至所述第二终端设备中,以通知所述第二终端设备到应用服务器中获取所述信息包。After receiving the first confirmation information sent by the first terminal device, the application server generates a file acquisition message according to the identifier of the second terminal device, and sends the file acquisition message to a push server (push server). The file obtaining message is used to notify the push server to send the file obtaining message to the second terminal device when detecting that the second terminal device corresponding to the identifier of the second terminal device is online, so as to notify the The second terminal device obtains the information package from the application server.

步骤507,推送服务器侧检测到所述第二终端设备的标识对应的第二终端设备在线时,将所述文件获取消息发送至所述第二终端设备侧;Step 507, when the push server side detects that the second terminal device corresponding to the identifier of the second terminal device is online, it sends the file acquisition message to the second terminal device side;

在实际中,推送服务器用于将文件获取消息推送到对应的第二终端设备中。具体而言,推送服务器在接收到所述文件获取消息后,获取所述文件获取消息中携带的第二终端设备的标识,并在所有已经接入的终端设备的标识(终端设备一在线便会自动连接推送服务器)中查找与所述第二终端设备的标识相同的终端设备,若查找成功,则说明所述第二终端设备在线,否则,则说明所述第二终端设备不在线。In practice, the push server is used to push the file acquisition message to the corresponding second terminal device. Specifically, after receiving the file acquisition message, the push server acquires the identifier of the second terminal device carried in the file acquisition message, and displays the identifiers of all connected terminal devices (the terminal device will Automatically connect to the push server) to search for a terminal device with the same identification as the second terminal device, if the search is successful, it means that the second terminal device is online, otherwise, it means that the second terminal device is not online.

推送服务器在检测到所述第二终端设备在线时,则直接将所述文件获取消息发送至所述第二终端设备中;若检测到所述第二终端设备不在线(即离线),则等到所述第二终端设备在线上再将所述文件获取消息发送至所述第二终端设备中。When detecting that the second terminal device is online, the push server directly sends the file acquisition message to the second terminal device; if it detects that the second terminal device is not online (ie, offline), wait until The second terminal device sends the file acquisition message to the second terminal device online.

在具体实现中,第二终端设备的在线与否依据监听得到的网络状态而定。具体而言,在本发明的一种优选实施例中,若所述第二终端设备为安装有安卓系统的移动设备,其按照如下方式监听网络状态:In a specific implementation, whether the second terminal device is online or not is determined according to the network state obtained by monitoring. Specifically, in a preferred embodiment of the present invention, if the second terminal device is a mobile device with an Android system installed, it monitors the network status as follows:

网络状态是一个SystemService,可以通过 context.getSystemService(Stringname)获取,当网络状态发生变化的时候, SystemServic会发出android.net.conn.CONNECTIVITY_CHANGE广播,此时移动设备侧只需要注册一个service(服务),便可以在后台接收网络状态变化的广播,这个service可以为ConnctionChangeReceiver;处理接收到的广播,实现方法如下,在onReceive中添加网络状态判断:The network status is a SystemService, which can be obtained through context.getSystemService(Stringname). When the network status changes, SystemServic will send out android.net.conn.CONNECTIVITY_CHANGE broadcast. At this time, the mobile device side only needs to register a service (service), You can receive the broadcast of network status changes in the background. This service can be ConnctionChangeReceiver; to process the received broadcast, the implementation method is as follows. Add network status judgment in onReceive:

ConnectivityManager connectMgr=(ConnectivityManager)context.getSystemService(Context.CONNECTIVITY_SERVICE);ConnectivityManager connectMgr=(ConnectivityManager)context.getSystemService(Context.CONNECTIVITY_SERVICE);

NetworkInfo mobNetInfo= connectMgr.getNetworkInfo(ConnectivityManager.TYPE_MOBILE);NetworkInfo mobNetInfo = connectMgr.getNetworkInfo(ConnectivityManager.TYPE_MOBILE);

NetworkInfo wifiNetInfo= connectMgr.getNetworkInfo(ConnectivityManager.TYPE_WIFI);NetworkInfo wifiNetInfo = connectMgr.getNetworkInfo(ConnectivityManager.TYPE_WIFI);

其中,ConnectivityManager为获取当前系统服务信息;Among them, ConnectivityManager is to obtain the current system service information;

getNetworkInfo分别获取类型为MOBILE和WIFI两种联网方式的信息;getNetworkInfo obtains the information of the two networking methods of MOBILE and WIFI respectively;

通过判断mobNetInfo.isConnected()和wifiNetInfo.isConnected()返回的Boolean布尔值来确定当前联网状态,若返回的布尔值为true(或1),则说明当前网络可用,移动设备可进行连接;若返回的布尔值为false(或 0),则说明当前的网络不可用,移动设备不可进行连接。The current networking status is determined by judging the Boolean values returned by mobNetInfo.isConnected() and wifiNetInfo.isConnected(). If the returned Boolean value is true (or 1), it means that the current network is available and the mobile device can be connected; if it returns The boolean value of is false (or 0), which means that the current network is unavailable and the mobile device cannot connect.

在本发明的另一种优选实施例中,若所述第二终端设备为计算设备,其按照如下方式监听网络状态:若计算设备需要无线连接网络时,可以调用网络接口API获取当前的网络状态,若当前网络状态可用,则计算设备连接当前网络,否则,不连接当前网络。In another preferred embodiment of the present invention, if the second terminal device is a computing device, it monitors the network status as follows: if the computing device needs to wirelessly connect to the network, it can call the network interface API to obtain the current network status , if the current network status is available, the computing device is connected to the current network, otherwise, it is not connected to the current network.

步骤508,在第二终端设备侧依据所述文件获取消息从应用服务器中获取对应的信息包;Step 508, on the second terminal device side, obtain the corresponding information package from the application server according to the file obtaining message;

具体而言,第二终端设备侧安装有第二客户端程序,所述第二终端设备采用所述第二客户端程序接收推送服务器发送的文件获取消息,在在接收到所述文件获取消息时,可以将所述文件获取消息展示在第二终端的预设展示位置中,并以提示音或弹窗等形式通知用户有离线的文件资源,用户点击所述文件获取消息后即促使第二终端设备采用所述第二客户端程序到应用服务器中获取信息包。Specifically, a second client program is installed on the side of the second terminal device, and the second terminal device adopts the second client program to receive the file acquisition message sent by the push server, and when receiving the file acquisition message , the file acquisition message can be displayed in the preset display position of the second terminal, and the user is notified that there are offline file resources in the form of a prompt tone or a pop-up window. After the user clicks the file acquisition message, the second terminal is prompted to The device uses the second client program to obtain the information package from the application server.

步骤509,在第二终端设备侧依据所述目标文件资源的下载地址从文件服务器中下载对应的目标文件资源。Step 509, on the second terminal device side, download the corresponding target file resource from the file server according to the download address of the target file resource.

第二客户端程序获取到信息包后,解密所述信息包,获得所述信息包中的文件资源的下载地址,并依据所述文件资源的下载地址到文件服务器中获取对应的目标文件资源。After acquiring the information package, the second client program decrypts the information package, obtains the download address of the file resource in the information package, and obtains the corresponding target file resource from the file server according to the download address of the file resource.

进一步地,第二客户端程序解密所述信息包后,还可以获得所述目标文件资源的类型,并根据所述目标文件资源的类型进行如下操作:若所述目标文件资源的类型为主题、壁纸、铃声、音乐、视频、电子书等类型,则将所述目标文件资源存储在第二终端设备侧;若所述目标文件资源的类型为软件和/或游戏等安装类型,则直接安装所述目标文件资源。第二客户端程序在存储完文件资源或安装完文件资源后,可以在第二终端设备界面的预设展示位置以通知消息或弹窗的形式告知用户已安装的文件资源或已存储的文件资源的文件信息,其中,所述文件信息可以以列表的形式进行展现。Further, after the second client program decrypts the information package, it can also obtain the type of the target file resource, and perform the following operations according to the type of the target file resource: if the type of the target file resource is the subject, wallpaper, ringtone, music, video, e-book, etc., the target file resource is stored on the second terminal device side; if the target file resource is an installation type such as software and/or games, directly install all Describe the target file resource. After storing the file resources or installing the file resources, the second client program can notify the user of the installed file resources or the stored file resources in the form of a notification message or a pop-up window at the preset display position of the interface of the second terminal device The file information, wherein the file information can be presented in the form of a list.

在本发明实施例中,第一终端设备与第二终端设备在进行文件资源的传输时,可以不同时处于在线状态,即第一终端设备在线时先将目标文件资源上传至后台服务器,此时第二终端设备不一定需要在线,当第二终端设备在线时再到后台服务器中下载所述目标文件资源,从而减少了文件资源传输的限制,提高用户体验。In this embodiment of the present invention, the first terminal device and the second terminal device may not be online at the same time when transferring file resources, that is, the first terminal device first uploads the target file resource to the background server when it is online. The second terminal device does not necessarily need to be online, and when the second terminal device is online, the target file resource is downloaded from the background server, thereby reducing restrictions on file resource transmission and improving user experience.

对于方法实施例,为了简单描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本发明并不受所描述的动作顺序的限制,因为依据本发明,某些步骤可以采用其他顺序或者同时进行。其次,本领域技术人员也应该知悉,说明书中所描述的实施例均属于优选实施例,所涉及的动作和模块并不一定是本发明所必须的。The method embodiments are described as a series of action combinations for the sake of simple description, but those skilled in the art should know that the present invention is not limited by the described action sequence, because according to the present invention, some steps Other sequences or concurrently may be used. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present invention.

参照图9,示出了本发明的一种用于离线文件传输的终端设备实施例一的结构框图,所述的终端设备可以包括如下模块:Referring to FIG. 9 , a structural block diagram of Embodiment 1 of a terminal device for offline file transmission according to the present invention is shown. The terminal device may include the following modules:

目标文件资源发送模块601,适于在第一终端设备没有检测到第二终端设备的接入时,在第一终端设备侧通过悬浮窗口将目标文件资源发送至第一服务器中;The target file resource sending module 601 is adapted to send the target file resource to the first server on the side of the first terminal device through a floating window when the first terminal device does not detect the access of the second terminal device;

下载地址接收模块602,适于在第一终端设备侧接收所述第一服务器返回的所述目标文件资源的下载地址,所述目标文件资源的下载地址为所述第一服务器依据所述目标文件资源生成;The download address receiving module 602 is adapted to receive the download address of the target file resource returned by the first server on the side of the first terminal device, where the download address of the target file resource is the first server according to the target file. resource generation;

下载地址发送模块603,适于在第一终端设备侧依据所述目标文件资源的下载地址构建信息包并发送至第二服务器中。The download address sending module 603 is adapted to construct an information package on the side of the first terminal device according to the download address of the target file resource and send it to the second server.

在本发明的一种优选实施例中,还包括:In a preferred embodiment of the present invention, it also includes:

检测模块,适于在所述在第一终端设备侧通过悬浮窗口将目标文件资源发送至第一服务器中之前,检测用户针对悬浮窗口发起的指定操作,所述指定操作包括用户将目标文件资源拖送到悬浮窗口的操作,和/或,用户点击悬浮窗口上的文件选定按钮,在第一终端设备弹出的文件路径选择窗口中选择目标文件资源的路径的操作;The detection module is adapted to detect a specified operation initiated by the user on the floating window before the target file resource is sent to the first server through the floating window on the side of the first terminal device, and the specified operation includes dragging the target file resource by the user The operation of sending to the floating window, and/or, the user clicks the file selection button on the floating window, and selects the path of the target file resource in the file path selection window popped up by the first terminal device;

提醒消息发送模块,适于在检测到所述指定操作时,发出提醒消息询问用户是否需要离线发送目标文件资源;a reminder message sending module, adapted to send a reminder message to ask the user whether the target file resource needs to be sent offline when the designated operation is detected;

所述目标文件资源发送模块还适于:The target file resource sending module is further adapted to:

在接收到用户发送的离线确认指令后,通过悬浮窗口将所述目标文件资源发送至第一服务器中,所述离线确认指令为用户指示的确认离线发送所述目标文件资源的指令。After receiving the offline confirmation instruction sent by the user, the target file resource is sent to the first server through the floating window, and the offline confirmation instruction is an instruction instructed by the user to confirm the offline sending of the target file resource.

在本发明的一种优选实施例中,所述目标文件资源发送模块601还适于:In a preferred embodiment of the present invention, the target file resource sending module 601 is further adapted to:

在第一终端设备侧依据所述用户针对悬浮窗口的指定操作生成文件发送请求;Generate a file sending request on the side of the first terminal device according to the user's specified operation on the floating window;

在第一终端设备侧将所述文件发送请求发送至第一服务器中;sending the file sending request to the first server on the side of the first terminal device;

在第一终端设备侧接收所述第一服务器返回的文件响应消息;receiving, on the side of the first terminal device, a file response message returned by the first server;

在第一终端设备侧依据所述文件响应消息将所述目标文件资源发送至第一服务器中。The first terminal device side sends the target file resource to the first server according to the file response message.

在本发明的一种优选实施例中,所述目标文件资源发送模块还适于:In a preferred embodiment of the present invention, the target file resource sending module is further adapted to:

在第一终端设备侧依据所述文件响应消息对将所述目标文件资源进行加密;Encrypting the target file resource according to the file response message at the first terminal device side;

将所述加密后的目标文件资源发送至第一服务器中。Send the encrypted target file resource to the first server.

在本发明的一种优选实施例中,所述目标文件资源为第一终端侧依据用户发出的文件资源选定指令获得的文件资源;所述文件资源选定指令为用户在第一终端设备侧展示的文件资源下载列表中选择的对某文件资源的下载指令,或者,所述文件资源选定指令为用户在第一终端设备侧存储的文件资源中选择的对某文件资源的选定指令。In a preferred embodiment of the present invention, the target file resource is a file resource obtained by the first terminal side according to a file resource selection instruction issued by the user; the file resource selection instruction is the user on the first terminal device side. The download instruction for a certain file resource selected in the displayed file resource download list, or the file resource selection instruction is a selection instruction for a certain file resource selected by the user from the file resources stored on the side of the first terminal device.

在本发明的一种优选实施例中,所述下载地址发送模块还适于:In a preferred embodiment of the present invention, the download address sending module is further adapted to:

在第一终端设备侧获取所述目标文件资源的文件属性信息;Obtain the file attribute information of the target file resource on the side of the first terminal device;

在第一终端设备侧构建所述目标文件资源的下载地址以及所述文件属性信息的信息包;constructing the download address of the target file resource and the information package of the file attribute information on the side of the first terminal device;

在第一终端设备侧将所述信息包发送至第二服务器中。The information packet is sent to the second server on the side of the first terminal device.

在本发明的一种优选实施例中,还包括:In a preferred embodiment of the present invention, it also includes:

信息确认指令发送模块,适于在第一终端设备侧接收第三服务器发送的信息确认指令;an information confirmation instruction sending module, adapted to receive the information confirmation instruction sent by the third server on the side of the first terminal device;

展示模块,适于在第一终端设备侧将所述信息确认指令展示给用户;a presentation module, adapted to present the information confirmation instruction to the user on the side of the first terminal device;

确认信息接收模块,适于接收用户选择的确认信息,并将所述确认信息发送至第二服务器中。The confirmation information receiving module is adapted to receive confirmation information selected by the user, and send the confirmation information to the second server.

在本发明的一种优选实施例中,所述信息确认指令包括第二终端设备的标识,所述确认信息包括第一确认信息以及第二确认信息,所述第一确认信息为依据用户选定的确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;所述第二确认信息为依据用户选定的不确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息。In a preferred embodiment of the present invention, the information confirmation instruction includes an identifier of the second terminal device, the confirmation information includes first confirmation information and second confirmation information, and the first confirmation information is selected according to the user. The information generated by confirming that the second terminal device corresponding to the identifier of the second terminal device is the file recipient; 2. Information generated by the terminal device as the recipient of the file.

在本发明的一种优选实施例中,还包括:In a preferred embodiment of the present invention, it also includes:

文件发送列表生成模块,适于在第一终端设备侧生成文件发送列表,所述文件发送列表为通过所述悬浮窗口进行离线发送的目标文件资源组织成的列表。The file sending list generating module is adapted to generate a file sending list on the side of the first terminal device, and the file sending list is a list organized by target file resources to be sent offline through the floating window.

在本发明的一种优选实施例中,所述文件发送列表中针对每个目标文件资源具有文件发送状态信息,所述文件发送状态信息包括成功发送状态、正在发送状态、等待发送状态以及发送失败状态。In a preferred embodiment of the present invention, the file sending list has file sending status information for each target file resource, and the file sending status information includes successful sending status, sending status, waiting to send status, and sending failure state.

在本发明的一种优选实施例中,所述目标文件资源的文件属性信息还包括目标文件资源的大小、目标文件资源的类型、目标文件资源的版本号、目标文件资源的标识。In a preferred embodiment of the present invention, the file attribute information of the target file resource further includes the size of the target file resource, the type of the target file resource, the version number of the target file resource, and the identifier of the target file resource.

在本发明的一种优选实施例中,所述目标文件资源的类型包括主题、壁纸、铃声、软件、音乐、游戏、视频、电子书。In a preferred embodiment of the present invention, the types of the target file resources include themes, wallpapers, ringtones, software, music, games, videos, and e-books.

在本发明的一种优选实施例中,所述第一服务器为文件服务器,所述第二服务器为应用服务器,所述第三服务器为推送服务器。In a preferred embodiment of the present invention, the first server is a file server, the second server is an application server, and the third server is a push server.

参照图10,示出了本发明的一种用于离线文件传输的服务器实施例一的结构框图,所述的服务器可以包括如下模块:Referring to FIG. 10 , a structural block diagram of Embodiment 1 of a server for offline file transfer according to the present invention is shown. The server may include the following modules:

信息包接收模块701,适于在第二服务器侧接收第一终端设备侧发送的信息包;an information packet receiving module 701, adapted to receive, at the second server side, an information packet sent by the first terminal device side;

设备标识获取模块702,适于所述第二服务器获取所述第一终端设备的标识;A device identification obtaining module 702, adapted for the second server to obtain the identification of the first terminal device;

设备标识查找模块703,适于在第二服务器侧的预设的关联关系列表中查找与所述第一终端设备的标识存在关联关系的第二终端设备的标识;A device identification search module 703, adapted to search for the identification of the second terminal device that has an association relationship with the identification of the first terminal device in a preset association relationship list on the second server side;

第一文件获取消息发送模块704,适于在第二服务器侧依据所述第二终端设备的标识生成文件获取消息发送至第三服务器中。The first file acquisition message sending module 704 is adapted to generate a file acquisition message on the second server side according to the identifier of the second terminal device and send it to the third server.

在本发明的一种优选实施例中,还包括:In a preferred embodiment of the present invention, it also includes:

信息确认指令生成模块,适于在所述依据所述第二终端设备的标识生成文件获取消息发送至第三服务器中之前,在第二服务器侧生成信息确认指令;an information confirmation instruction generation module, adapted to generate an information confirmation instruction on the second server side before the file acquisition message is generated according to the identifier of the second terminal device and sent to the third server;

信息确认指令发送模块,适于在第二服务器侧将所述信息确认指令发送至第三服务器中,由第三服务器发送至第一终端设备侧;an information confirmation instruction sending module, adapted to send the information confirmation instruction on the second server side to the third server, and the third server sends it to the first terminal device side;

确认消息接收模块,适于在第二服务器侧接收第一终端设备返回的确认信息。The confirmation message receiving module is adapted to receive confirmation information returned by the first terminal device on the second server side.

在本发明的一种优选实施例中,所述信息确认指令包括第二终端设备的标识,所述确认信息包括第一确认信息以及第二确认信息,所述第一确认信息为依据用户选定的确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;所述第二确认信息为依据用户选定的不确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;In a preferred embodiment of the present invention, the information confirmation instruction includes an identifier of the second terminal device, the confirmation information includes first confirmation information and second confirmation information, and the first confirmation information is selected according to the user. The information generated by confirming that the second terminal device corresponding to the identifier of the second terminal device is the file recipient; 2. Information generated by the terminal device as the recipient of the file;

所述服务器还包括:The server also includes:

调用模块,适于在所述确认信息为第一确认信息时,调用第一文件获取消息发送模块;a calling module, adapted to call the first file acquisition message sending module when the confirmation information is the first confirmation information;

标识获取模块,适于在所述确认信息为第二确认信息时,在第二服务器侧重新获取第二终端设备的标识。The identification acquisition module is adapted to re-acquire the identification of the second terminal device on the second server side when the confirmation information is the second confirmation information.

在本发明的一种优选实施例中,所述第二服务器为应用服务器,所述第三服务器为推送服务器。In a preferred embodiment of the present invention, the second server is an application server, and the third server is a push server.

参照图11,示出了本发明的一种用于离线文件传输的服务器实施例二的结构框图,所述的服务器可以包括如下模块:Referring to FIG. 11 , a structural block diagram of Embodiment 2 of a server for offline file transfer according to the present invention is shown. The server may include the following modules:

第一文件获取消息接收模块801,适于在第三服务器侧接收第二服务器发送的文件获取消息,所述文件获取消息包括第二终端设备的标识;The first file acquisition message receiving module 801 is adapted to receive, on the third server side, a file acquisition message sent by a second server, where the file acquisition message includes an identifier of the second terminal device;

第二文件获取消息发送模块802,适于在第三服务器侧检测到所述第二终端设备的标识对应的第二终端设备在线时,将所述文件获取消息发送至所述第二终端设备侧。The second file obtaining message sending module 802 is adapted to send the file obtaining message to the second terminal device side when the third server side detects that the second terminal device corresponding to the identifier of the second terminal device is online .

在本发明的一种优选实施例中,所述第二文件获取消息发送模块还适于:In a preferred embodiment of the present invention, the second file acquisition message sending module is further adapted to:

在第三服务器侧获取所有已经接入的终端设备的标识;Obtain the identifiers of all connected terminal devices on the third server side;

在第三服务器侧判断所述所有接入的终端设备的标识中是否存在与所述第二终端设备的标识相同的终端设备;Judging on the third server side whether there is a terminal device identical to the identifier of the second terminal device in the identifiers of all the connected terminal devices;

若是,则判定所述第二终端设备的标识对应的第二终端设备在线。If so, it is determined that the second terminal device corresponding to the identifier of the second terminal device is online.

在本发明的一种优选实施例中,还包括:In a preferred embodiment of the present invention, it also includes:

信息确认指令接收模块,适于在第三服务器侧接收第二服务器发送的信息确认指令;an information confirmation instruction receiving module, adapted to receive the information confirmation instruction sent by the second server on the third server side;

信息确认指令发送模块,适于在第三服务器侧将所述信息确认指令发送至第一终端设备中。The information confirmation instruction sending module is adapted to send the information confirmation instruction to the first terminal device on the third server side.

在本发明的一种优选实施例中,所述第二服务器为应用服务器,所述第三服务器为推送服务器。In a preferred embodiment of the present invention, the second server is an application server, and the third server is a push server.

参照图12,示出了本发明的一种用于离线文件传输的终端设备实施例二的结构框图,所述的终端设备可以包括如下模块:Referring to FIG. 12 , it shows a structural block diagram of Embodiment 2 of a terminal device for offline file transmission according to the present invention. The terminal device may include the following modules:

第二文件获取消息接收模块901,适于在第二终端设备侧接收第三服务器发送的文件获取消息;The second file acquisition message receiving module 901 is adapted to receive the file acquisition message sent by the third server on the second terminal device side;

信息包获取模块902,适于在第二终端设备侧依据所述文件获取消息从第二服务器中获取对应的信息包,所述信息包包括目标文件资源的下载地址;The information package acquisition module 902 is adapted to acquire a corresponding information package from the second server according to the file acquisition message on the second terminal device side, where the information package includes the download address of the target file resource;

目标文件资源下载模块903,适于在第二终端设备侧依据所述目标文件资源的下载地址从第一服务器中下载对应的目标文件资源。The target file resource downloading module 903 is adapted to download the corresponding target file resource from the first server on the second terminal device side according to the download address of the target file resource.

在本发明的一种优选实施例中,所述信息包包括文件属性信息,所述文件属性信息包括目标文件资源的类型,所述目标文件资源的类型包括主题、壁纸、铃声、软件、音乐、游戏、视频、电子书,所述的终端设备还包括:In a preferred embodiment of the present invention, the information package includes file attribute information, the file attribute information includes the type of target file resource, and the type of the target file resource includes theme, wallpaper, ringtone, software, music, Games, videos, e-books, and the terminal equipment also includes:

若所述目标文件资源的类型为主题、壁纸、铃声、音乐、视频、电子书,则将所述目标文件资源存储在第二终端设备侧;If the type of the target file resource is theme, wallpaper, ringtone, music, video, e-book, then the target file resource is stored on the second terminal device side;

若所述目标文件资源的类型为软件和/或游戏,则直接安装所述目标文件资源。If the type of the target file resource is software and/or a game, the target file resource is directly installed.

在本发明的一种优选实施例中,所述终端设备还包括:In a preferred embodiment of the present invention, the terminal device further includes:

监听模块,适于在所述在第二终端设备侧接收第三服务器发送的文件获取消息之前,在第二终端设备侧监听网络状态,所述网络状态包括当前网络可用;a monitoring module, adapted to monitor a network state on the second terminal device side before receiving the file acquisition message sent by the third server on the second terminal device side, where the network state includes current network availability;

第一连接模块,适于若当前网络可用,则在第二终端设备侧连接当前网络;a first connection module, adapted to connect to the current network at the second terminal device side if the current network is available;

第二连接模块,适于在第二终端设备侧连接所述第三服务器。The second connection module is adapted to connect to the third server on the side of the second terminal device.

在本发明的一种优选实施例中,若所述第二终端设备为移动设备,所述监听模块还适于:In a preferred embodiment of the present invention, if the second terminal device is a mobile device, the monitoring module is further adapted to:

在所述第二终端设备侧注册网络状态变化接收服务 ConnctionChangeReceiver;Register the network state change receiving service ConnctionChangeReceiver on the second terminal device side;

在第二终端设备侧采用所述网络状态变化接收服务 ConnctionChangeReceiver接收系统服务SystemService发出的广播 CONNECTIVITY_CHANGE;On the second terminal device side, use the network state change receiving service ConnctionChangeReceiver to receive the broadcast CONNECTIVITY_CHANGE sent by the system service SystemService;

若所述广播CONNECTIVITY_CHANGE调用的方法 wifiNetInfo.isConnected()返回的布尔值为真,则判定当前网络可用;If the boolean value returned by the method wifiNetInfo.isConnected() called by the broadcast CONNECTIVITY_CHANGE is true, it is determined that the current network is available;

若所述广播CONNECTIVITY_CHANGE调用的方法 wifiNetInfo.isConnected()返回的布尔值为真,则判定当前网络不可用。If the boolean value returned by the method wifiNetInfo.isConnected() called by the broadcast CONNECTIVITY_CHANGE is true, it is determined that the current network is unavailable.

在本发明的另一种优选实施例中,若所述第二终端设备为移动设备,所述监听模块还适于:In another preferred embodiment of the present invention, if the second terminal device is a mobile device, the monitoring module is further adapted to:

在第二终端设备侧调用网络接口API查询当前的网络状态。The network interface API is called on the second terminal device side to query the current network status.

在本发明的一种优选实施例中,所述第一服务器为文件服务器,所述第二服务器为应用服务器,第三服务器为推送服务器。In a preferred embodiment of the present invention, the first server is a file server, the second server is an application server, and the third server is a push server.

参照图13,示出了本发明的一种离线文件传输的系统实施例的结构框图,所述的系统可以包括第一终端设备10、文件服务器20、应用服务器 30,推送服务器40、第二终端设备50,其中,Referring to FIG. 13, a structural block diagram of an embodiment of an offline file transfer system of the present invention is shown. The system may include a first terminal device 10, a file server 20, an application server 30, a push server 40, and a second terminal device 50, wherein,

所述第一终端设备10,适于当第一终端设备没有检测到第二终端设备的接入时,通过悬浮窗口将待发送的目标文件资源发送至文件服务器中,并接收所述文件服务器返回的所述目标文件资源的下载地址,以及,将所述目标文件资源的下载地址构建信息包发送至应用服务器中;The first terminal device 10 is adapted to send the target file resource to be sent to the file server through the floating window when the first terminal device does not detect the access of the second terminal device, and receive a response from the file server. The download address of the target file resource, and, the download address of the target file resource constructs the information package and sends it to the application server;

所述文件服务器20,适于接收所述目标文件资源,依据所述目标文件资源生成对应的目标文件资源的下载地址并发送至第一终端设备中;The file server 20 is adapted to receive the target file resource, generate a download address of the corresponding target file resource according to the target file resource, and send it to the first terminal device;

所述应用服务器30,适于接收所述信息包,依据所述信息包中携带的第一终端设备的标识在预设的关联关系列表中查找与所述第一终端设备的标识存在关联关系的第二终端设备的标识,以及,依据所述第二终端设备的标识生成文件获取消息发送至推送服务器中;The application server 30 is adapted to receive the information packet, and search for the identification of the first terminal device in the preset association relationship list according to the identification of the first terminal device carried in the information packet. The identifier of the second terminal device, and generating a file acquisition message according to the identifier of the second terminal device and sending it to the push server;

所述推送服务器40,适于在检测到所述第二终端设备的标识对应的第二终端设备在线时,将所述文件获取消息发送至所述第二终端设备侧;The push server 40 is adapted to send the file acquisition message to the second terminal device side when detecting that the second terminal device corresponding to the identifier of the second terminal device is online;

所述第二终端设备50,适于依据所述文件获取消息从应用服务器中获取对应的信息包,以及,依据所述信息包携带的目标文件资源的下载地址从文件服务器中下载对应的目标文件资源。The second terminal device 50 is adapted to obtain the corresponding information package from the application server according to the file obtaining message, and download the corresponding target file from the file server according to the download address of the target file resource carried in the information package. resource.

在本发明的一种优选实施例中,所述第一终端设备10还适于:In a preferred embodiment of the present invention, the first terminal device 10 is further adapted to:

依据用户针对悬浮窗口的指定操作生成文件发送请求;Generate a file sending request according to the user's specified operation on the floating window;

将所述文件发送请求发送至文件服务器中;sending the file sending request to the file server;

接收所述文件服务器返回的文件响应消息;receiving a file response message returned by the file server;

依据所述文件响应消息将所述目标文件资源发送至文件服务器中。The target file resource is sent to the file server according to the file response message.

在本发明的一种优选实施例中,所述目标文件资源的文件属性信息还包括目标文件资源的大小、目标文件资源的类型、目标文件资源的版本号、目标文件资源的标识。In a preferred embodiment of the present invention, the file attribute information of the target file resource further includes the size of the target file resource, the type of the target file resource, the version number of the target file resource, and the identifier of the target file resource.

在本发明的一种优选实施例中,所述目标文件资源的类型包括主题、壁纸、铃声、软件、音乐、游戏、视频、电子书。In a preferred embodiment of the present invention, the types of the target file resources include themes, wallpapers, ringtones, software, music, games, videos, and e-books.

在本发明的一种优选实施例中,所述第二终端设备50还适于:In a preferred embodiment of the present invention, the second terminal device 50 is further adapted to:

在所述目标文件资源的类型为主题、壁纸、铃声、音乐、视频、电子书时,将所述目标文件资源存储在第二终端设备侧;When the type of the target file resource is theme, wallpaper, ringtone, music, video, and e-book, storing the target file resource on the side of the second terminal device;

在所述目标文件资源的类型为软件和/或游戏时,直接安装所述目标文件资源。When the type of the target file resource is software and/or a game, the target file resource is directly installed.

在此提供的算法和显示不与任何特定计算设备、虚拟系统或者其它设备固有相关。各种通用系统也可以与基于在此的示教一起使用。根据上面的描述,构造这类系统所要求的结构是显而易见的。此外,本发明也不针对任何特定编程语言。应当明白,可以利用各种编程语言实现在此描述的本发明的内容,并且上面对特定语言所做的描述是为了披露本发明的最佳实施方式。The algorithms and displays provided herein are not inherently related to any particular computing device, virtual system, or other device. Various general-purpose systems can also be used with teaching based on this. The structure required to construct such a system is apparent from the above description. Furthermore, the present invention is not directed to any particular programming language. It is to be understood that various programming languages may be used to implement the inventions described herein, and that the descriptions of specific languages above are intended to disclose the best mode for carrying out the invention.

在此处所提供的说明书中,说明了大量具体细节。然而,能够理解,本发明的实施例可以在没有这些具体细节的情况下实践。在一些实例中,并未详细示出公知的方法、结构和技术,以便不模糊对本说明书的理解。In the description provided herein, numerous specific details are set forth. It will be understood, however, that embodiments of the invention may be practiced without these specific details. In some instances, well-known methods, structures and techniques have not been shown in detail in order not to obscure an understanding of this description.

类似地,应当理解,为了精简本公开并帮助理解各个发明方面中的一个或多个,在上面对本发明的示例性实施例的描述中,本发明的各个特征有时被一起分组到单个实施例、图、或者对其的描述中。然而,并不应将该公开的方法解释成反映如下意图:即所要求保护的本发明要求比在每个权利要求中所明确记载的特征更多的特征。更确切地说,如下面的权利要求书所反映的那样,发明方面在于少于前面公开的单个实施例的所有特征。因此,遵循具体实施方式的权利要求书由此明确地并入该具体实施方式,其中每个权利要求本身都作为本发明的单独实施例。Similarly, it is to be understood that in the above description of exemplary embodiments of the invention, various features of the invention are sometimes grouped together into a single embodiment, figure, or its description. This disclosure, however, should not be construed as reflecting an intention that the invention as claimed requires more features than are expressly recited in each claim. Rather, as the following claims reflect, inventive aspects lie in less than all features of a single foregoing disclosed embodiment. Thus, the claims following the Detailed Description are hereby expressly incorporated into this Detailed Description, with each claim standing on its own as a separate embodiment of this invention.

本领域那些技术人员可以理解,可以对实施例中的设备中的模块进行自适应性地改变并且把它们设置在与该实施例不同的一个或多个设备中。可以把实施例中的模块或单元或组件组合成一个模块或单元或组件,以及此外可以把它们分成多个子模块或子单元或子组件。除了这样的特征和/或过程或者单元中的至少一些是相互排斥之外,可以采用任何组合对本说明书(包括伴随的权利要求、摘要和附图)中公开的所有特征以及如此公开的任何方法或者设备的所有过程或单元进行组合。除非另外明确陈述,本说明书(包括伴随的权利要求、摘要和附图)中公开的每个特征可以由提供相同、等同或相似目的替代特征来代替。Those skilled in the art will understand that the modules in the device in the embodiment can be adaptively changed and arranged in one or more devices different from the embodiment. The modules or units or components in the embodiments may be combined into one module or unit or component, and further they may be divided into multiple sub-modules or sub-units or sub-assemblies. All features disclosed in this specification (including accompanying claims, abstract and drawings) and any method so disclosed may be employed in any combination, unless at least some of such features and/or procedures or elements are mutually exclusive. All processes or units of equipment are combined. Each feature disclosed in this specification (including accompanying claims, abstract and drawings) may be replaced by alternative features serving the same, equivalent or similar purpose, unless expressly stated otherwise.

此外,本领域的技术人员能够理解,尽管在此所述的一些实施例包括其它实施例中所包括的某些特征而不是其它特征,但是不同实施例的特征的组合意味着处于本发明的范围之内并且形成不同的实施例。例如,在下面的权利要求书中,所要求保护的实施例的任意之一都可以以任意的组合方式来使用。Furthermore, those skilled in the art will appreciate that although some of the embodiments described herein include certain features, but not others, included in other embodiments, that combinations of features of different embodiments are intended to be within the scope of the invention within and form different embodiments. For example, in the following claims, any of the claimed embodiments may be used in any combination.

本发明的各个部件实施例可以以硬件实现,或者以在一个或者多个处理器上运行的软件模块实现,或者以它们的组合实现。本领域的技术人员应当理解,可以在实践中使用微处理器或者数字信号处理器(DSP)来实现根据本发明实施例的离线文件传输设备中的一些或者全部部件的一些或者全部功能。本发明还可以实现为用于执行这里所描述的方法的一部分或者全部的设备或者终端设备程序(例如,第一终端设备程序和第一终端设备程序产品)。这样的实现本发明的程序可以存储在第一终端设备可读介质上,或者可以具有一个或者多个信号的形式。这样的信号可以从因特网网站上下载得到,或者在载体信号上提供,或者以任何其他形式提供。Various component embodiments of the present invention may be implemented in hardware, or in software modules running on one or more processors, or in a combination thereof. Those skilled in the art should understand that a microprocessor or a digital signal processor (DSP) may be used in practice to implement some or all of the functions of some or all of the components in the offline file transfer device according to the embodiment of the present invention. The present invention may also be implemented as a device or terminal device program (eg, a first terminal device program and a first terminal device program product) for performing part or all of the methods described herein. Such a program implementing the present invention may be stored on a medium readable by the first terminal device, or may be in the form of one or more signals. Such signals may be downloaded from Internet sites, or provided on carrier signals, or in any other form.

应该注意的是上述实施例对本发明进行说明而不是对本发明进行限制,并且本领域技术人员在不脱离所附权利要求的范围的情况下可设计出替换实施例。在权利要求中,不应将位于括号之间的任何参考符号构造成对权利要求的限制。单词“包含”不排除存在未列在权利要求中的元件或步骤。位于元件之前的单词“一”或“一个”不排除存在多个这样的元件。本发明可以借助于包括有若干不同元件的硬件以及借助于适当编程的第一终端设备来实现。在列举了若干终端设备的单元权利要求中,这些终端设备中的若干个可以是通过同一个硬件项来具体体现。单词第一、第二、以及第三等的使用不表示任何顺序。可将这些单词解释为名称。It should be noted that the above-described embodiments illustrate rather than limit the invention, and that alternative embodiments may be devised by those skilled in the art without departing from the scope of the appended claims. In the claims, any reference signs placed between parentheses shall not be construed as limiting the claim. The word "comprising" does not exclude the presence of elements or steps not listed in a claim. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The invention can be implemented by means of hardware comprising several different elements and by means of a suitably programmed first terminal device. In a unit claim enumerating several terminal devices, several of these terminal devices can be embodied by one and the same item of hardware. The use of the words first, second, and third, etc. do not denote any order. These words can be interpreted as names.

本发明的实施例公开了A1、一种离线文件传输的方法,包括:The embodiment of the present invention discloses A1, an offline file transmission method, comprising:

当第一终端设备没有检测到第二终端设备的接入时,在第一终端设备侧通过悬浮窗口将目标文件资源发送至第一服务器中;When the first terminal device does not detect the access of the second terminal device, sending the target file resource to the first server through the floating window on the side of the first terminal device;

在第一终端设备侧接收所述第一服务器返回的所述目标文件资源的下载地址,所述目标文件资源的下载地址为所述第一服务器依据所述目标文件资源生成;receiving, at the first terminal device side, the download address of the target file resource returned by the first server, where the download address of the target file resource is generated by the first server according to the target file resource;

在第一终端设备侧依据所述目标文件资源的下载地址构建信息包并发送至第二服务器中。The information package is constructed on the side of the first terminal device according to the download address of the target file resource and sent to the second server.

A2、如A1所述的方法,在所述在第一终端设备侧通过悬浮窗口将目标文件资源发送至第一服务器中的步骤之前,还包括:A2. The method according to A1, before the step of sending the target file resource to the first server through the floating window on the side of the first terminal device, further comprising:

检测用户针对悬浮窗口发起的指定操作,所述指定操作包括用户将目标文件资源拖送到悬浮窗口的操作,和/或,用户点击悬浮窗口上的文件选定按钮,在第一终端设备弹出的文件路径选择窗口中选择目标文件资源的路径的操作;Detecting a specified operation initiated by the user on the floating window, the specified operation includes the operation of the user dragging the target file resource to the floating window, and/or, the user clicks the file selection button on the floating window, and the first terminal device pops up The operation of selecting the path of the target file resource in the file path selection window;

当检测到所述指定操作时,发出提醒消息询问用户是否需要离线发送目标文件资源;When the specified operation is detected, a reminder message is sent to ask the user whether the target file resource needs to be sent offline;

所述在第一终端设备侧通过悬浮窗口将目标文件资源发送至第一服务器中的步骤包括:The step of sending the target file resource to the first server through the floating window on the side of the first terminal device includes:

在接收到用户发送的离线确认指令后,通过悬浮窗口将所述目标文件资源发送至第一服务器中,所述离线确认指令为用户指示的确认离线发送所述目标文件资源的指令。After receiving the offline confirmation instruction sent by the user, the target file resource is sent to the first server through the floating window, and the offline confirmation instruction is an instruction instructed by the user to confirm the offline sending of the target file resource.

A3、如A2所述的方法,所述在第一终端设备侧通过悬浮窗口将目标文件资源发送至第一服务器中的步骤包括:A3. The method according to A2, wherein the step of sending the target file resource to the first server through the floating window on the side of the first terminal device includes:

在第一终端设备侧依据所述用户针对悬浮窗口的指定操作生成文件发送请求;Generate a file sending request on the side of the first terminal device according to the user's specified operation on the floating window;

在第一终端设备侧将所述文件发送请求发送至第一服务器中;sending the file sending request to the first server on the side of the first terminal device;

在第一终端设备侧接收所述第一服务器返回的文件响应消息;receiving, on the side of the first terminal device, a file response message returned by the first server;

在第一终端设备侧依据所述文件响应消息将所述目标文件资源发送至第一服务器中。The first terminal device side sends the target file resource to the first server according to the file response message.

A4、如A3所述的方法,所述在第一终端设备侧依据所述文件响应消息将所述目标文件资源发送至第一服务器中的步骤包括:A4. The method according to A3, wherein the step of sending the target file resource to the first server on the first terminal device side according to the file response message includes:

在第一终端设备侧依据所述文件响应消息对将所述目标文件资源进行加密;Encrypting the target file resource according to the file response message at the first terminal device side;

将所述加密后的目标文件资源发送至第一服务器中。Send the encrypted target file resource to the first server.

A5、如A1所述的方法,所述目标文件资源为第一终端侧依据用户发出的文件资源选定指令获得的文件资源;所述文件资源选定指令为用户在第一终端设备侧展示的文件资源下载列表中选择的对某文件资源的下载指令,或者,所述文件资源选定指令为用户在第一终端设备侧存储的文件资源中选择的对某文件资源的选定指令。A5. The method according to A1, wherein the target file resource is the file resource obtained by the first terminal side according to the file resource selection instruction issued by the user; the file resource selection instruction is displayed by the user on the first terminal device side The download instruction for a certain file resource selected in the file resource download list, or the file resource selection instruction is a selection instruction for a certain file resource selected by the user from the file resources stored on the side of the first terminal device.

A6、如A1所述的方法,所述在第一终端设备侧依据所述目标文件资源的下载地址构建信息包并发送至第二服务器中的步骤包括:A6. The method according to A1, wherein the step of constructing an information package on the side of the first terminal device according to the download address of the target file resource and sending it to the second server includes:

在第一终端设备侧获取所述目标文件资源的文件属性信息;Obtain the file attribute information of the target file resource on the side of the first terminal device;

在第一终端设备侧构建所述目标文件资源的下载地址以及所述文件属性信息的信息包;constructing the download address of the target file resource and the information package of the file attribute information on the side of the first terminal device;

在第一终端设备侧将所述信息包发送至第二服务器中。The information packet is sent to the second server on the side of the first terminal device.

A7、如A1所述的方法,还包括:A7. The method of A1, further comprising:

在第一终端设备侧接收第三服务器发送的信息确认指令;receiving an information confirmation instruction sent by the third server on the side of the first terminal device;

在第一终端设备侧将所述信息确认指令展示给用户;presenting the information confirmation instruction to the user on the side of the first terminal device;

接收用户选择的确认信息,并将所述确认信息发送至第二服务器中。The confirmation information selected by the user is received, and the confirmation information is sent to the second server.

A8、如A7所述的方法,所述信息确认指令包括第二终端设备的标识,所述确认信息包括第一确认信息以及第二确认信息,所述第一确认信息为依据用户选定的确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;所述第二确认信息为依据用户选定的不确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息。A8. The method according to A7, wherein the information confirmation instruction includes an identifier of the second terminal device, the confirmation information includes first confirmation information and second confirmation information, and the first confirmation information is a confirmation selected by a user The information generated by the second terminal device corresponding to the identifier of the second terminal device as the file recipient; the second confirmation information is the second terminal corresponding to the identifier of the second terminal device selected by the user not to confirm the second terminal device Information generated by the device as a recipient of the file.

A9、如A1所述的方法,还包括:A9. The method of A1, further comprising:

在第一终端设备侧生成文件发送列表,所述文件发送列表为通过所述悬浮窗口进行离线发送的目标文件资源组织成的列表。A file sending list is generated on the side of the first terminal device, where the file sending list is a list organized by target file resources to be sent offline through the floating window.

A10、如A9所述的方法,所述文件发送列表中针对每个目标文件资源具有文件发送状态信息,所述文件发送状态信息包括成功发送状态、正在发送状态、等待发送状态以及发送失败状态。A10. The method according to A9, the file sending list has file sending status information for each target file resource, and the file sending status information includes successful sending status, sending status, waiting for sending status, and sending failure status.

A11、如A1所述的方法,所述目标文件资源的文件属性信息还包括目标文件资源的大小、目标文件资源的类型、目标文件资源的版本号、目标文件资源的标识。A11. The method according to A1, wherein the file attribute information of the target file resource further includes the size of the target file resource, the type of the target file resource, the version number of the target file resource, and the identifier of the target file resource.

A12、如A11所述的方法,所述目标文件资源的类型包括主题、壁纸、铃声、软件、音乐、游戏、视频、电子书。A12. The method according to A11, wherein the types of the target file resources include themes, wallpapers, ringtones, software, music, games, videos, and e-books.

A13、如A4至12任一项所述的方法,所述第一服务器为文件服务器,所述第二服务器为应用服务器,所述第三服务器为推送服务器。A13. The method according to any one of A4 to 12, wherein the first server is a file server, the second server is an application server, and the third server is a push server.

本发明的实施例还公开了B14、一种离线文件传输的方法,包括:The embodiment of the present invention also discloses B14, a method for offline file transmission, comprising:

在第二服务器侧接收第一终端设备侧发送的信息包;receiving, at the second server side, the information packet sent by the first terminal device side;

所述第二服务器获取所述第一终端设备的标识;obtaining, by the second server, the identifier of the first terminal device;

在第二服务器侧的预设的关联关系列表中查找与所述第一终端设备的标识存在关联关系的第二终端设备的标识;Searching for the identifier of the second terminal device that has an associated relationship with the identifier of the first terminal device in the preset association relationship list on the second server side;

在第二服务器侧依据所述第二终端设备的标识生成文件获取消息发送至第三服务器中。On the second server side, a file acquisition message is generated according to the identifier of the second terminal device and sent to the third server.

B15、如B14所述的方法,在所述依据所述第二终端设备的标识生成文件获取消息发送至第三服务器中的步骤之前,还包括:B15. The method according to B14, before the step of generating a file acquisition message according to the identifier of the second terminal device and sending it to the third server, further comprising:

在第二服务器侧生成信息确认指令;generating an information confirmation instruction on the second server side;

在第二服务器侧将所述信息确认指令发送至第三服务器中,由第三服务器发送至第一终端设备侧;Send the information confirmation instruction to the third server on the second server side, and the third server sends it to the first terminal device side;

在第二服务器侧接收第一终端设备返回的确认信息。The confirmation information returned by the first terminal device is received at the second server side.

B16、如B15所述的方法,所述信息确认指令包括第二终端设备的标识,所述确认信息包括第一确认信息以及第二确认信息,所述第一确认信息为依据用户选定的确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;所述第二确认信息为依据用户选定的不确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;B16. The method according to B15, wherein the information confirmation instruction includes an identifier of the second terminal device, the confirmation information includes first confirmation information and second confirmation information, and the first confirmation information is a confirmation selected by a user The information generated by the second terminal device corresponding to the identifier of the second terminal device as a file recipient; the second confirmation information is the second terminal corresponding to the identifier of the second terminal device selected by the user not to confirm the second terminal device Information generated by the device as a recipient of the file;

所述方法还包括:The method also includes:

若所述确认信息为第一确认信息,则执行所述在第二服务器侧依据所述第二终端设备的标识生成文件获取消息发送至第三服务器中的步骤;If the confirmation information is the first confirmation information, executing the step of generating a file acquisition message on the second server side according to the identifier of the second terminal device and sending it to the third server;

若所述确认信息为第二确认信息,则在第二服务器侧重新获取第二终端设备的标识。If the confirmation information is the second confirmation information, the identifier of the second terminal device is re-acquired on the second server side.

本发明的实施例还公开了C17、一种离线文件传输的方法,包括:The embodiment of the present invention also discloses C17, a method for offline file transmission, comprising:

在第三服务器侧接收第二服务器发送的文件获取消息,所述文件获取消息包括第二终端设备的标识;receiving, at the third server side, a file acquisition message sent by the second server, where the file acquisition message includes the identifier of the second terminal device;

在第三服务器侧检测到所述第二终端设备的标识对应的第二终端设备在线时,将所述文件获取消息发送至所述第二终端设备侧。When the third server side detects that the second terminal device corresponding to the identifier of the second terminal device is online, the file acquisition message is sent to the second terminal device side.

C18、如C17所述的方法,所述检测所述第二终端设备的标识对应的第二终端设备在线的步骤包括:C18. The method according to C17, wherein the step of detecting that the second terminal device corresponding to the identifier of the second terminal device is online includes:

在第三服务器侧获取所有已经接入的终端设备的标识;Obtain the identifiers of all connected terminal devices on the third server side;

在第三服务器侧判断所述所有接入的终端设备的标识中是否存在与所述第二终端设备的标识相同的终端设备;Judging on the third server side whether there is a terminal device identical to the identifier of the second terminal device in the identifiers of all the connected terminal devices;

若是,则判定所述第二终端设备的标识对应的第二终端设备在线。If so, it is determined that the second terminal device corresponding to the identifier of the second terminal device is online.

C19、如C17所述的方法,还包括:C19. The method of C17, further comprising:

在第三服务器侧接收第二服务器发送的信息确认指令;在第三服务器侧将所述信息确认指令发送至第一终端设备中。The information confirmation instruction sent by the second server is received at the third server side; the information confirmation instruction is sent to the first terminal device at the third server side.

本发明的实施例还公开了D20、一种离线文件传输的方法,包括:The embodiment of the present invention also discloses D20, a method for offline file transmission, including:

在第二终端设备侧接收第三服务器发送的文件获取消息;receiving, on the second terminal device side, the file acquisition message sent by the third server;

在第二终端设备侧依据所述文件获取消息从第二服务器中获取对应的信息包,所述信息包包括目标文件资源的下载地址;The second terminal device side obtains a corresponding information package from the second server according to the file obtaining message, where the information package includes the download address of the target file resource;

在第二终端设备侧依据所述目标文件资源的下载地址从第一服务器中下载对应的目标文件资源。The second terminal device side downloads the corresponding target file resource from the first server according to the download address of the target file resource.

D21、如D20所述的方法,所述信息包包括文件属性信息,所述文件属性信息包括目标文件资源的类型,所述目标文件资源的类型包括主题、壁纸、铃声、软件、音乐、游戏、视频、电子书,所述的方法还包括:D21. The method according to D20, wherein the information package includes file attribute information, the file attribute information includes types of target file resources, and the types of target file resources include themes, wallpapers, ringtones, software, music, games, video, e-book, and the method further includes:

若所述目标文件资源的类型为主题、壁纸、铃声、音乐、视频、电子书,则将所述目标文件资源存储在第二终端设备侧;If the type of the target file resource is theme, wallpaper, ringtone, music, video, e-book, then the target file resource is stored on the second terminal device side;

若所述目标文件资源的类型为软件和/或游戏,则直接安装所述目标文件资源。If the type of the target file resource is software and/or a game, the target file resource is directly installed.

D22、如D20所述的方法,在所述在第二终端设备侧接收第三服务器发送的文件获取消息的步骤之前,还包括:D22. The method according to D20, before the step of receiving the file acquisition message sent by the third server on the second terminal device side, further comprising:

在第二终端设备侧监听网络状态,所述网络状态包括当前网络可用;Monitor the network status on the second terminal device side, where the network status includes current network availability;

若当前网络可用,则在第二终端设备侧连接当前网络;If the current network is available, connect the current network on the second terminal device side;

在第二终端设备侧连接所述第三服务器。The third server is connected on the second terminal device side.

D23、如D22所述的方法,若所述第二终端设备为移动设备,所述在第二终端设备侧监听网络状态的步骤包括:D23. The method according to D22, if the second terminal device is a mobile device, the step of monitoring the network status on the second terminal device side includes:

在所述第二终端设备侧注册网络状态变化接收服务 ConnctionChangeReceiver;Register the network state change receiving service ConnctionChangeReceiver on the second terminal device side;

在第二终端设备侧采用所述网络状态变化接收服务 ConnctionChangeReceiver接收系统服务SystemService发出的广播 CONNECTIVITY_CHANGE;On the second terminal device side, use the network state change receiving service ConnctionChangeReceiver to receive the broadcast CONNECTIVITY_CHANGE sent by the system service SystemService;

若所述广播CONNECTIVITY_CHANGE调用的方法 wifiNetInfo.isConnected()返回的布尔值为真,则判定当前网络可用;If the boolean value returned by the method wifiNetInfo.isConnected() called by the broadcast CONNECTIVITY_CHANGE is true, it is determined that the current network is available;

若所述广播CONNECTIVITY_CHANGE调用的方法 wifiNetInfo.isConnected()返回的布尔值为真,则判定当前网络不可用。If the boolean value returned by the method wifiNetInfo.isConnected() called by the broadcast CONNECTIVITY_CHANGE is true, it is determined that the current network is unavailable.

D24、如D22所述的方法,若所述第二终端设备为计算设备,所述在第二终端设备侧监听网络状态的步骤包括:D24. The method according to D22, if the second terminal device is a computing device, the step of monitoring the network status on the second terminal device side includes:

在第二终端设备侧调用网络接口API查询当前的网络状态。The network interface API is called on the second terminal device side to query the current network status.

本发明的实施例还公开E25、一种用于离线文件传输的终端设备,包括:The embodiment of the present invention also discloses E25, a terminal device for offline file transmission, comprising:

目标文件资源发送模块,适于在第一终端设备没有检测到第二终端设备的接入时,在第一终端设备侧通过悬浮窗口将目标文件资源发送至第一服务器中;The target file resource sending module is adapted to send the target file resource to the first server through the floating window on the side of the first terminal device when the first terminal device does not detect the access of the second terminal device;

下载地址接收模块,适于在第一终端设备侧接收所述第一服务器返回的所述目标文件资源的下载地址,所述目标文件资源的下载地址为所述第一服务器依据所述目标文件资源生成;A download address receiving module, adapted to receive the download address of the target file resource returned by the first server on the side of the first terminal device, where the download address of the target file resource is the first server according to the target file resource. generate;

下载地址发送模块,适于在第一终端设备侧依据所述目标文件资源的下载地址构建信息包并发送至第二服务器中。The download address sending module is adapted to construct an information package on the side of the first terminal device according to the download address of the target file resource and send it to the second server.

E26、如E25所述的终端设备,还包括:E26. The terminal device according to E25, further comprising:

检测模块,适于在所述在第一终端设备侧通过悬浮窗口将目标文件资源发送至第一服务器中之前,检测用户针对悬浮窗口发起的指定操作,所述指定操作包括用户将目标文件资源拖送到悬浮窗口的操作,和/或,用户点击悬浮窗口上的文件选定按钮,在第一终端设备弹出的文件路径选择窗口中选择目标文件资源的路径的操作;The detection module is adapted to detect a specified operation initiated by the user on the floating window before the target file resource is sent to the first server through the floating window on the side of the first terminal device, and the specified operation includes dragging the target file resource by the user The operation of sending to the floating window, and/or, the user clicks the file selection button on the floating window, and selects the path of the target file resource in the file path selection window popped up by the first terminal device;

提醒消息发送模块,适于在检测到所述指定操作时,发出提醒消息询问用户是否需要离线发送目标文件资源;a reminder message sending module, adapted to send a reminder message to ask the user whether the target file resource needs to be sent offline when the designated operation is detected;

所述目标文件资源发送模块还适于:The target file resource sending module is further adapted to:

在接收到用户发送的离线确认指令后,通过悬浮窗口将所述目标文件资源发送至第一服务器中,所述离线确认指令为用户指示的确认离线发送所述目标文件资源的指令。After receiving the offline confirmation instruction sent by the user, the target file resource is sent to the first server through the floating window, and the offline confirmation instruction is an instruction instructed by the user to confirm the offline sending of the target file resource.

E27、如E26所述的终端设备,所述目标文件资源发送模块还适于:E27. The terminal device according to E26, wherein the target file resource sending module is further adapted to:

在第一终端设备侧依据所述用户针对悬浮窗口的指定操作生成文件发送请求;Generate a file sending request on the side of the first terminal device according to the user's specified operation on the floating window;

在第一终端设备侧将所述文件发送请求发送至第一服务器中;sending the file sending request to the first server on the side of the first terminal device;

在第一终端设备侧接收所述第一服务器返回的文件响应消息;receiving, on the side of the first terminal device, a file response message returned by the first server;

在第一终端设备侧依据所述文件响应消息将所述目标文件资源发送至第一服务器中。The first terminal device side sends the target file resource to the first server according to the file response message.

E28、如E27所述的终端设备,所述目标文件资源发送模块还适于:E28. The terminal device according to E27, wherein the target file resource sending module is further adapted to:

在第一终端设备侧依据所述文件响应消息对将所述目标文件资源进行加密;Encrypting the target file resource according to the file response message at the first terminal device side;

将所述加密后的目标文件资源发送至第一服务器中。Send the encrypted target file resource to the first server.

E29、如E25所述的终端设备,所述目标文件资源为第一终端侧依据用户发出的文件资源选定指令获得的文件资源;所述文件资源选定指令为用户在第一终端设备侧展示的文件资源下载列表中选择的对某文件资源的下载指令,或者,所述文件资源选定指令为用户在第一终端设备侧存储的文件资源中选择的对某文件资源的选定指令。E29. The terminal device according to E25, wherein the target file resource is a file resource obtained by the first terminal side according to a file resource selection instruction issued by a user; the file resource selection instruction is displayed by the user on the first terminal device side The download instruction for a certain file resource selected in the file resource download list of the first terminal device, or the file resource selection instruction is a selection instruction for a certain file resource selected by the user from the file resources stored on the side of the first terminal device.

E30、如E25所述的终端设备,所述下载地址发送模块还适于:E30. The terminal device according to E25, wherein the download address sending module is further adapted to:

在第一终端设备侧获取所述目标文件资源的文件属性信息;Obtain the file attribute information of the target file resource on the side of the first terminal device;

在第一终端设备侧构建所述目标文件资源的下载地址以及所述文件属性信息的信息包;constructing the download address of the target file resource and the information package of the file attribute information on the side of the first terminal device;

在第一终端设备侧将所述信息包发送至第二服务器中。The information packet is sent to the second server on the side of the first terminal device.

E31、如E25所述的终端设备,还包括:E31. The terminal device according to E25, further comprising:

信息确认指令发送模块,适于在第一终端设备侧接收第三服务器发送的信息确认指令;an information confirmation instruction sending module, adapted to receive the information confirmation instruction sent by the third server on the side of the first terminal device;

展示模块,适于在第一终端设备侧将所述信息确认指令展示给用户;a presentation module, adapted to present the information confirmation instruction to the user on the side of the first terminal device;

确认信息接收模块,适于接收用户选择的确认信息,并将所述确认信息发送至第二服务器中。The confirmation information receiving module is adapted to receive confirmation information selected by the user, and send the confirmation information to the second server.

E32、如E31所述的终端设备,所述信息确认指令包括第二终端设备的标识,所述确认信息包括第一确认信息以及第二确认信息,所述第一确认信息为依据用户选定的确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;所述第二确认信息为依据用户选定的不确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息。E32. The terminal device according to E31, wherein the information confirmation instruction includes an identifier of the second terminal device, the confirmation information includes first confirmation information and second confirmation information, and the first confirmation information is selected according to the user Information generated by confirming that the second terminal device corresponding to the identifier of the second terminal device is the file recipient; Information generated by the terminal device for the recipient of the file.

E33、如E25所述的终端设备,还包括:E33. The terminal device according to E25, further comprising:

文件发送列表生成模块,适于在第一终端设备侧生成文件发送列表,所述文件发送列表为通过所述悬浮窗口进行离线发送的目标文件资源组织成的列表。The file sending list generating module is adapted to generate a file sending list on the side of the first terminal device, and the file sending list is a list organized by target file resources to be sent offline through the floating window.

E34、如E33所述的终端设备,所述文件发送列表中针对每个目标文件资源具有文件发送状态信息,所述文件发送状态信息包括成功发送状态、正在发送状态、等待发送状态以及发送失败状态。E34. The terminal device according to E33, the file sending list has file sending status information for each target file resource, and the file sending status information includes successful sending status, sending status, waiting for sending status, and sending failure status .

E35、如E25所述的终端设备,所述目标文件资源的文件属性信息还包括目标文件资源的大小、目标文件资源的类型、目标文件资源的版本号、目标文件资源的标识。E35. The terminal device according to E25, wherein the file attribute information of the target file resource further includes the size of the target file resource, the type of the target file resource, the version number of the target file resource, and the identifier of the target file resource.

E36、如E35所述的终端设备,所述目标文件资源的类型包括主题、壁纸、铃声、软件、音乐、游戏、视频、电子书。E36. The terminal device according to E35, wherein the types of the target file resources include themes, wallpapers, ringtones, software, music, games, videos, and e-books.

E37、如E28至36任一项所述的终端设备,所述第一服务器为文件服务器,所述第二服务器为应用服务器,所述第三服务器为推送服务器。E37. The terminal device according to any one of E28 to 36, wherein the first server is a file server, the second server is an application server, and the third server is a push server.

本发明的实施例还公开了F38、一种用于离线文件传输的服务器,包括:The embodiment of the present invention also discloses F38, a server for offline file transfer, comprising:

信息包接收模块,适于在第二服务器侧接收第一终端设备侧发送的信息包;an information packet receiving module, adapted to receive, on the second server side, an information packet sent by the first terminal device side;

设备标识获取模块,适于所述第二服务器获取所述第一终端设备的标识;a device identification acquiring module, adapted for the second server to acquire the identification of the first terminal device;

设备标识查找模块,适于在第二服务器侧的预设的关联关系列表中查找与所述第一终端设备的标识存在关联关系的第二终端设备的标识;a device identification search module, adapted to search for the identification of the second terminal device that has an association relationship with the identification of the first terminal device in a preset association relationship list on the second server side;

第一文件获取消息发送模块,适于在第二服务器侧依据所述第二终端设备的标识生成文件获取消息发送至第三服务器中。The first file acquisition message sending module is adapted to generate a file acquisition message on the second server side according to the identifier of the second terminal device and send it to the third server.

F39、如F38所述的服务器,还包括:F39. The server of F38, further comprising:

信息确认指令生成模块,适于在所述依据所述第二终端设备的标识生成文件获取消息发送至第三服务器中之前,在第二服务器侧生成信息确认指令;an information confirmation instruction generation module, adapted to generate an information confirmation instruction on the second server side before the file acquisition message is generated according to the identifier of the second terminal device and sent to the third server;

信息确认指令发送模块,适于在第二服务器侧将所述信息确认指令发送至第三服务器中,由第三服务器发送至第一终端设备侧;an information confirmation instruction sending module, adapted to send the information confirmation instruction on the second server side to the third server, and the third server sends it to the first terminal device side;

确认消息接收模块,适于在第二服务器侧接收第一终端设备返回的确认信息。The confirmation message receiving module is adapted to receive confirmation information returned by the first terminal device on the second server side.

F40、如F39所述的服务器,所述信息确认指令包括第二终端设备的标识,所述确认信息包括第一确认信息以及第二确认信息,所述第一确认信息为依据用户选定的确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;所述第二确认信息为依据用户选定的不确认所述第二终端设备的标识对应的第二终端设备为文件接收方而生成的信息;F40. The server according to F39, wherein the information confirmation instruction includes an identifier of the second terminal device, the confirmation information includes first confirmation information and second confirmation information, and the first confirmation information is a confirmation selected by a user The information generated by the second terminal device corresponding to the identifier of the second terminal device as the file recipient; the second confirmation information is the second terminal corresponding to the identifier of the second terminal device selected by the user not to confirm the second terminal device Information generated by the device as a recipient of the file;

所述服务器还包括:The server also includes:

调用模块,适于在所述确认信息为第一确认信息时,调用第一文件获取消息发送模块;a calling module, adapted to call the first file acquisition message sending module when the confirmation information is the first confirmation information;

标识获取模块,适于在所述确认信息为第二确认信息时,在第二服务器侧重新获取第二终端设备的标识。The identification acquisition module is adapted to re-acquire the identification of the second terminal device on the second server side when the confirmation information is the second confirmation information.

本发明的实施例还公开了G41、一种用于离线文件传输的服务器,包括:The embodiment of the present invention also discloses G41, a server for offline file transfer, comprising:

第一文件获取消息接收模块,适于在第三服务器侧接收第二服务器发送的文件获取消息,所述文件获取消息包括第二终端设备的标识;a first file acquisition message receiving module, adapted to receive, on the third server side, a file acquisition message sent by a second server, where the file acquisition message includes an identifier of the second terminal device;

第二文件获取消息发送模块,适于在第三服务器侧检测到所述第二终端设备的标识对应的第二终端设备在线时,将所述文件获取消息发送至所述第二终端设备侧。The second file obtaining message sending module is adapted to send the file obtaining message to the second terminal device side when the third server side detects that the second terminal device corresponding to the identifier of the second terminal device is online.

G42、如G41所述的服务器,所述第二文件获取消息发送模块还适于:G42. The server according to G41, wherein the second file acquisition message sending module is further adapted to:

在第三服务器侧获取所有已经接入的终端设备的标识;Obtain the identifiers of all connected terminal devices on the third server side;

在第三服务器侧判断所述所有接入的终端设备的标识中是否存在与所述第二终端设备的标识相同的终端设备;Judging on the third server side whether there is a terminal device identical to the identifier of the second terminal device in the identifiers of all the connected terminal devices;

若是,则判定所述第二终端设备的标识对应的第二终端设备在线。If so, it is determined that the second terminal device corresponding to the identifier of the second terminal device is online.

G43、如G41所述的服务器,还包括:G43. The server as described in G41, further comprising:

信息确认指令接收模块,适于在第三服务器侧接收第二服务器发送的信息确认指令;an information confirmation instruction receiving module, adapted to receive the information confirmation instruction sent by the second server on the third server side;

信息确认指令发送模块,适于在第三服务器侧将所述信息确认指令发送至第一终端设备中。The information confirmation instruction sending module is adapted to send the information confirmation instruction to the first terminal device on the third server side.

本发明的实施例还公开了H44、一种用于离线文件传输的终端设备,包括:The embodiment of the present invention also discloses H44, a terminal device for offline file transmission, including:

第二文件获取消息接收模块,适于在第二终端设备侧接收第三服务器发送的文件获取消息;The second file acquisition message receiving module is adapted to receive the file acquisition message sent by the third server on the second terminal device side;

信息包获取模块,适于在第二终端设备侧依据所述文件获取消息从第二服务器中获取对应的信息包,所述信息包包括目标文件资源的下载地址;an information package acquisition module, adapted to acquire a corresponding information package from the second server according to the file acquisition message on the second terminal device side, where the information package includes a download address of the target file resource;

目标文件资源下载模块,适于在第二终端设备侧依据所述目标文件资源的下载地址从第一服务器中下载对应的目标文件资源。The target file resource downloading module is adapted to download the corresponding target file resource from the first server on the second terminal device side according to the download address of the target file resource.

H45、如H44所述的终端设备,所述信息包包括文件属性信息,所述文件属性信息包括目标文件资源的类型,所述目标文件资源的类型包括主题、壁纸、铃声、软件、音乐、游戏、视频、电子书,所述的终端设备还包括:H45. The terminal device according to H44, wherein the information package includes file attribute information, the file attribute information includes the type of target file resource, and the type of the target file resource includes theme, wallpaper, ringtone, software, music, game , video, e-book, the terminal equipment also includes:

若所述目标文件资源的类型为主题、壁纸、铃声、音乐、视频、电子书,则将所述目标文件资源存储在第二终端设备侧;If the type of the target file resource is theme, wallpaper, ringtone, music, video, e-book, then the target file resource is stored on the second terminal device side;

若所述目标文件资源的类型为软件和/或游戏,则直接安装所述目标文件资源。If the type of the target file resource is software and/or a game, the target file resource is directly installed.

H46、如H44所述的终端设备,还包括:H46. The terminal device as described in H44, further comprising:

监听模块,适于在所述在第二终端设备侧接收第三服务器发送的文件获取消息之前,在第二终端设备侧监听网络状态,所述网络状态包括当前网络可用;a monitoring module, adapted to monitor a network state on the second terminal device side before receiving the file acquisition message sent by the third server on the second terminal device side, where the network state includes current network availability;

第一连接模块,适于若当前网络可用,则在第二终端设备侧连接当前网络;a first connection module, adapted to connect to the current network at the second terminal device side if the current network is available;

第二连接模块,适于在第二终端设备侧连接所述第三服务器。The second connection module is adapted to connect to the third server on the side of the second terminal device.

H47、如H46所述的终端设备,所述第二终端设备为移动设备,所述监听模块还适于:H47. The terminal device according to H46, wherein the second terminal device is a mobile device, and the monitoring module is further adapted to:

在所述第二终端设备侧注册网络状态变化接收服务 ConnctionChangeReceiver;Register the network state change receiving service ConnctionChangeReceiver on the second terminal device side;

在第二终端设备侧采用所述网络状态变化接收服务 ConnctionChangeReceiver接收系统服务SystemService发出的广播 CONNECTIVITY_CHANGE;On the second terminal device side, use the network state change receiving service ConnctionChangeReceiver to receive the broadcast CONNECTIVITY_CHANGE sent by the system service SystemService;

若所述广播CONNECTIVITY_CHANGE调用的方法 wifiNetInfo.isConnected()返回的布尔值为真,则判定当前网络可用;If the boolean value returned by the method wifiNetInfo.isConnected() called by the broadcast CONNECTIVITY_CHANGE is true, it is determined that the current network is available;

若所述广播CONNECTIVITY_CHANGE调用的方法 wifiNetInfo.isConnected()返回的布尔值为真,则判定当前网络不可用。If the boolean value returned by the method wifiNetInfo.isConnected() called by the broadcast CONNECTIVITY_CHANGE is true, it is determined that the current network is unavailable.

H48、如H46所述的方法,若所述第二终端设备为计算设备,所述在第二终端设备侧监听网络状态的步骤包括:H48. The method according to H46, if the second terminal device is a computing device, the step of monitoring the network status on the second terminal device side includes:

在第二终端设备侧调用网络接口API查询当前的网络状态。The network interface API is called on the second terminal device side to query the current network status.

本发明的实施例还公开了I49、一种离线文件传输的系统,包括:第一终端设备、文件服务器、应用服务器,推送服务器、第二终端设备,其中,The embodiment of the present invention also discloses I49, an offline file transmission system, comprising: a first terminal device, a file server, an application server, a push server, and a second terminal device, wherein,

所述第一终端设备,适于当第一终端设备没有检测到第二终端设备的接入时,通过悬浮窗口将待发送的目标文件资源发送至文件服务器中,并接收所述文件服务器返回的所述目标文件资源的下载地址,以及,将所述目标文件资源的下载地址构建信息包发送至应用服务器中;The first terminal device is adapted to, when the first terminal device does not detect the access of the second terminal device, send the target file resource to be sent to the file server through the floating window, and receive the data returned by the file server. The download address of the target file resource, and sending the download address of the target file resource to construct an information package to the application server;

所述文件服务器,适于接收所述目标文件资源,依据所述目标文件资源生成对应的目标文件资源的下载地址并发送至第一终端设备中;The file server is adapted to receive the target file resource, generate a download address of the corresponding target file resource according to the target file resource, and send it to the first terminal device;

所述应用服务器,适于接收所述信息包,依据所述信息包中携带的第一终端设备的标识在预设的关联关系列表中查找与所述第一终端设备的标识存在关联关系的第二终端设备的标识,以及,依据所述第二终端设备的标识生成文件获取消息发送至推送服务器中;The application server is adapted to receive the information packet, and according to the identification of the first terminal device carried in the information packet, search for the first terminal device that has an association relationship with the identification of the first terminal device in the preset association relationship list. The identifier of the second terminal device, and generating a file acquisition message according to the identifier of the second terminal device and sending it to the push server;

所述推送服务器,适于在检测到所述第二终端设备的标识对应的第二终端设备在线时,将所述文件获取消息发送至所述第二终端设备侧;The push server is adapted to send the file acquisition message to the second terminal device side when detecting that the second terminal device corresponding to the identifier of the second terminal device is online;

所述第二终端设备,适于依据所述文件获取消息从应用服务器中获取对应的信息包,以及,依据所述信息包携带的目标文件资源的下载地址从文件服务器中下载对应的目标文件资源。The second terminal device is adapted to obtain the corresponding information package from the application server according to the file obtaining message, and download the corresponding target file resource from the file server according to the download address of the target file resource carried in the information package. .

I50、如I49所述的系统,所述第一终端设备还适于:I50. The system according to I49, wherein the first terminal device is further adapted to:

依据用户针对悬浮窗口的指定操作生成文件发送请求;Generate a file sending request according to the user's specified operation on the floating window;

将所述文件发送请求发送至文件服务器中;sending the file sending request to the file server;

接收所述文件服务器返回的文件响应消息;receiving a file response message returned by the file server;

依据所述文件响应消息将所述目标文件资源发送至文件服务器中。The target file resource is sent to the file server according to the file response message.

I51、如I49所述的系统,所述目标文件资源的文件属性信息还包括目标文件资源的大小、目标文件资源的类型、目标文件资源的版本号、目标文件资源的标识。I51. The system according to I49, wherein the file attribute information of the target file resource further includes the size of the target file resource, the type of the target file resource, the version number of the target file resource, and the identifier of the target file resource.

I52、如I51所述的系统,所述目标文件资源的类型包括主题、壁纸、铃声、软件、音乐、游戏、视频、电子书。I52. The system according to I51, wherein the types of the target file resources include themes, wallpapers, ringtones, software, music, games, videos, and e-books.

I53、如I52所述的系统,所述第二终端设备还适于:I53. The system according to I52, wherein the second terminal device is further adapted to:

在所述目标文件资源的类型为主题、壁纸、铃声、音乐、视频、电子书时,将所述目标文件资源存储在第二终端设备侧;When the types of the target file resources are themes, wallpapers, ringtones, music, videos, and e-books, storing the target file resources on the side of the second terminal device;

在所述目标文件资源的类型为软件和/或游戏时,直接安装所述目标文件资源。When the type of the target file resource is software and/or a game, the target file resource is directly installed.

Claims (4)

1.一种离线文件传输的方法,包括:1. A method for offline file transfer, comprising: 在第三服务器侧接收第二服务器发送的文件获取消息,所述文件获取消息包括第二终端设备的标识;receiving, at the third server side, a file acquisition message sent by the second server, where the file acquisition message includes the identifier of the second terminal device; 在第三服务器侧检测到所述第二终端设备的标识对应的第二终端设备在线时,将所述文件获取消息发送至所述第二终端设备侧;When the third server side detects that the second terminal device corresponding to the identifier of the second terminal device is online, the file acquisition message is sent to the second terminal device side; 在第三服务器侧接收第二服务器发送的信息确认指令,所述信息确认指令包括第二终端设备的标识,其中,所述信息确认指令是在第三服务器侧接收第二服务器发送的文件获取消息之前获得的,所述信息确认指令是当第二服务器获取到作为目标文件资源接收方的第二终端设备的标识后生成的,用于告知第一终端设备确认是否将目标文件资源发送至选择的第二终端设备的标识中;Receive, at the third server side, an information confirmation instruction sent by the second server, where the information confirmation instruction includes the identifier of the second terminal device, wherein the information confirmation instruction is to receive, at the third server side, a file acquisition message sent by the second server Obtained before, the information confirmation instruction is generated when the second server obtains the identifier of the second terminal device that is the recipient of the target file resource, and is used to inform the first terminal device to confirm whether to send the target file resource to the selected device. in the identification of the second terminal device; 在第三服务器侧将所述信息确认指令发送至第一终端设备中,以使所述第一终端设备将所述信息确认指令展示给用户。On the third server side, the information confirmation instruction is sent to the first terminal device, so that the first terminal device displays the information confirmation instruction to the user. 2.如权利要求1所述的方法,其特征在于,所述检测所述第二终端设备的标识对应的第二终端设备在线的步骤包括:2. The method according to claim 1, wherein the step of detecting that the second terminal device corresponding to the identifier of the second terminal device is online comprises: 在第三服务器侧获取所有已经接入的终端设备的标识;Obtain the identifiers of all connected terminal devices on the third server side; 在第三服务器侧判断所述所有接入的终端设备的标识中是否存在与所述第二终端设备的标识相同的终端设备;Judging on the third server side whether there is a terminal device identical to the identifier of the second terminal device in the identifiers of all the connected terminal devices; 若是,则判定所述第二终端设备的标识对应的第二终端设备在线。If so, it is determined that the second terminal device corresponding to the identifier of the second terminal device is online. 3.一种用于离线文件传输的服务器,包括:3. A server for offline file transfer, comprising: 第一文件获取消息接收模块,适于在第三服务器侧接收第二服务器发送的文件获取消息,所述文件获取消息包括第二终端设备的标识;a first file acquisition message receiving module, adapted to receive, on the third server side, a file acquisition message sent by a second server, where the file acquisition message includes an identifier of the second terminal device; 第二文件获取消息发送模块,适于在第三服务器侧检测到所述第二终端设备的标识对应的第二终端设备在线时,将所述文件获取消息发送至所述第二终端设备侧;A second file acquisition message sending module, adapted to send the file acquisition message to the second terminal equipment side when the third server side detects that the second terminal equipment corresponding to the identifier of the second terminal equipment is online; 信息确认指令接收模块,适于在第三服务器侧接收第二服务器发送的信息确认指令,所述信息确认指令包括第二终端设备的标识,其中,所述信息确认指令是在第三服务器侧接收第二服务器发送的文件获取消息之前获得的,所述信息确认指令是当第二服务器获取到作为目标文件资源接收方的第二终端设备的标识后生成的,用于告知第一终端设备确认是否将目标文件资源发送至选择的第二终端设备的标识中;The information confirmation instruction receiving module is adapted to receive the information confirmation instruction sent by the second server at the third server side, the information confirmation instruction includes the identifier of the second terminal device, wherein the information confirmation instruction is received at the third server side Before the file acquisition message sent by the second server, the information confirmation instruction is generated after the second server acquires the identifier of the second terminal device that is the recipient of the target file resource, and is used to inform the first terminal device whether to confirm whether sending the target file resource to the identifier of the selected second terminal device; 信息确认指令发送模块,适于在第三服务器侧将所述信息确认指令发送至第一终端设备中,以使所述第一终端设备将所述信息确认指令展示给用户。The information confirmation instruction sending module is adapted to send the information confirmation instruction to the first terminal device on the third server side, so that the first terminal device displays the information confirmation instruction to the user. 4.如权利要求3所述的服务器,其特征在于,所述第二文件获取消息发送模块还适于:4. The server according to claim 3, wherein the second file acquisition message sending module is further adapted to: 在第三服务器侧获取所有已经接入的终端设备的标识;Obtain the identifiers of all connected terminal devices on the third server side; 在第三服务器侧判断所述所有接入的终端设备的标识中是否存在与所述第二终端设备的标识相同的终端设备;Judging on the third server side whether there is a terminal device identical to the identifier of the second terminal device in the identifiers of all the accessed terminal devices; 若是,则判定所述第二终端设备的标识对应的第二终端设备在线。If so, it is determined that the second terminal device corresponding to the identifier of the second terminal device is online.
CN201610274784.6A 2013-11-26 2013-11-26 A kind of method and server of offline file transmission Expired - Fee Related CN106027597B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610274784.6A CN106027597B (en) 2013-11-26 2013-11-26 A kind of method and server of offline file transmission

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201610274784.6A CN106027597B (en) 2013-11-26 2013-11-26 A kind of method and server of offline file transmission
CN201310612011.0A CN103634392B (en) 2013-11-26 2013-11-26 A method, system, terminal device and server for offline file transmission

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
CN201310612011.0A Division CN103634392B (en) 2013-11-26 2013-11-26 A method, system, terminal device and server for offline file transmission

Publications (2)

Publication Number Publication Date
CN106027597A CN106027597A (en) 2016-10-12
CN106027597B true CN106027597B (en) 2019-07-09

Family

ID=50215008

Family Applications (3)

Application Number Title Priority Date Filing Date
CN201610278618.3A Active CN105978956B (en) 2013-11-26 2013-11-26 A method, system, terminal device and server for offline file transfer
CN201310612011.0A Active CN103634392B (en) 2013-11-26 2013-11-26 A method, system, terminal device and server for offline file transmission
CN201610274784.6A Expired - Fee Related CN106027597B (en) 2013-11-26 2013-11-26 A kind of method and server of offline file transmission

Family Applications Before (2)

Application Number Title Priority Date Filing Date
CN201610278618.3A Active CN105978956B (en) 2013-11-26 2013-11-26 A method, system, terminal device and server for offline file transfer
CN201310612011.0A Active CN103634392B (en) 2013-11-26 2013-11-26 A method, system, terminal device and server for offline file transmission

Country Status (1)

Country Link
CN (3) CN105978956B (en)

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103916311B (en) 2014-04-21 2016-01-20 腾讯科技(深圳)有限公司 A kind of information transmission and control method, Apparatus and system
CN105407147B (en) * 2015-10-27 2018-11-20 北京金山安全软件有限公司 Method and device for downloading theme pack
CN107786425A (en) * 2016-09-12 2018-03-09 平安科技(深圳)有限公司 Information off-line treating method and apparatus
CN107995247B (en) * 2016-10-27 2020-07-14 腾讯科技(深圳)有限公司 File transmission method, server and system
CN107193981A (en) * 2017-05-26 2017-09-22 腾讯科技(深圳)有限公司 Collection file is shown, processing method and processing device, computer-readable storage medium and equipment
CN108322544A (en) * 2018-02-13 2018-07-24 合肥联宝信息技术有限公司 A kind of file management method and electronic equipment
CN108737505A (en) * 2018-04-27 2018-11-02 厦门理工学院 A kind of method of resource downloading, system and terminal device
US11010486B2 (en) * 2018-12-18 2021-05-18 Citrix Systems, Inc. Secure offline streaming of content
CN110460678A (en) * 2019-08-29 2019-11-15 湖南新云网科技有限公司 A kind of information transferring method, interactive device and server

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101075986A (en) * 2007-06-01 2007-11-21 腾讯科技(深圳)有限公司 Method and system for transmitting, receiving and transmitting off-line files
CN101170523A (en) * 2007-12-05 2008-04-30 腾讯科技(深圳)有限公司 File transmission system, method and file forward decision server
CN101184055A (en) * 2007-12-11 2008-05-21 腾讯科技(深圳)有限公司 Method and device of delivering, receiving, transmitting off-line files
CN102355426A (en) * 2011-06-30 2012-02-15 北京神州泰岳软件股份有限公司 Method for transmitting off-line file and system
CN102664823A (en) * 2012-04-17 2012-09-12 上海量明科技发展有限公司 Method, client and system for offline receiving of data in instant message
CN103248678A (en) * 2013-04-24 2013-08-14 天脉聚源(北京)传媒科技有限公司 Data resource sharing method, server-side and client-side

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6757705B1 (en) * 1998-08-14 2004-06-29 Microsoft Corporation Method and system for client-side caching
US7461378B2 (en) * 2002-06-11 2008-12-02 Siemens Communications, Inc. Methods and apparatus for processing an instant message
CN101977228B (en) * 2010-10-29 2013-04-24 优视科技有限公司 Off-line downloading method for mobile communication equipment terminal and system thereof
CN102821057A (en) * 2011-06-09 2012-12-12 腾讯科技(深圳)有限公司 File sending method, device and system
CN103051520B (en) * 2013-01-05 2015-11-25 小米科技有限责任公司 The method of synchronous offline session message and device in JICQ

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101075986A (en) * 2007-06-01 2007-11-21 腾讯科技(深圳)有限公司 Method and system for transmitting, receiving and transmitting off-line files
CN101170523A (en) * 2007-12-05 2008-04-30 腾讯科技(深圳)有限公司 File transmission system, method and file forward decision server
CN101184055A (en) * 2007-12-11 2008-05-21 腾讯科技(深圳)有限公司 Method and device of delivering, receiving, transmitting off-line files
CN102355426A (en) * 2011-06-30 2012-02-15 北京神州泰岳软件股份有限公司 Method for transmitting off-line file and system
CN102664823A (en) * 2012-04-17 2012-09-12 上海量明科技发展有限公司 Method, client and system for offline receiving of data in instant message
CN103248678A (en) * 2013-04-24 2013-08-14 天脉聚源(北京)传媒科技有限公司 Data resource sharing method, server-side and client-side

Also Published As

Publication number Publication date
CN105978956A (en) 2016-09-28
CN106027597A (en) 2016-10-12
CN105978956B (en) 2019-03-08
CN103634392B (en) 2017-04-19
CN103634392A (en) 2014-03-12

Similar Documents

Publication Publication Date Title
CN106027597B (en) A kind of method and server of offline file transmission
US11601385B2 (en) Conversion of text relating to media content and media extension apps
US10080111B2 (en) Techniques for communication using audio stickers
US20170359285A1 (en) Conversion of detected url in text message
JP6228676B2 (en) Connection state prompting method and apparatus
CN102981915B (en) A kind of inter-application communication method and device
CN103888505B (en) A kind of method, system, terminal device and the server of file transmission
WO2013135133A1 (en) Method, apparatus and computer storage medium for plug-in management and control
US9710661B2 (en) Presence-based content sharing
CN104410680A (en) Method, client terminal, server and system of sharing file/file folder
CN106789547A (en) One kind receives message approach and terminal device
CN103618824B (en) Method for sending information in address book program and mobile terminal
CN103023907A (en) Method, equipment and system for acquiring website information
CN104506616A (en) Method, device and system for sending information by browser client side
CN105763650B (en) A kind of method of offline file transmission, system, terminal device and server
CN104410679B (en) Share extracting method, client, server and the system of file/folder
CN104618445A (en) Method and device for arranging files based on cloud storage space
CN105138274A (en) Resource obtaining method of cloud disk and resource obtaining device of cloud disk
CN104301385A (en) Data acquisition method, computing device, mobile device and system
JP2011521335A (en) Method, apparatus, and computer program for distributing files from mobile devices by e-mail
CN104243572B (en) A kind of data transmission method and device based on carry-on WiFi network
CN106060111A (en) Resource downloading method and device and terminal device
CN104202310B (en) A kind of method and apparatus that connection is established between mobile device and computing device
CN105378654A (en) Service profile maintenance
CN104270825B (en) Information transferring method, computer and mobile terminal

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20220720

Address after: Room 801, 8th floor, No. 104, floors 1-19, building 2, yard 6, Jiuxianqiao Road, Chaoyang District, Beijing 100015

Patentee after: BEIJING QIHOO TECHNOLOGY Co.,Ltd.

Address before: 100088 room 112, block D, 28 new street, new street, Xicheng District, Beijing (Desheng Park)

Patentee before: BEIJING QIHOO TECHNOLOGY Co.,Ltd.

Patentee before: Qizhi software (Beijing) Co.,Ltd.

CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20190709