File transmission method and terminal

By establishing a direct file connection channel on the server side, allowing direct file transfer between terminals, the problem of file transfer between devices occupying server storage space, improving server efficiency and saving intranet bandwidth.

CN119030964APending Publication Date: 2024-11-26SHANGHAI QIYEYU NETWORK TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310584339.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-05-23
Publication Date
2024-11-26

AI Technical Summary

Technical Problem

When there are many devices, when files are transferred between devices, the transferred files will occupy a large storage space of the server, resulting in wasted server space and affecting the development of other server services.

Method used

The server obtains the direct connection attribute information of the second terminal, establishes a file direct connection channel, allowing the first terminal to directly transfer files to the second terminal, and avoids files being transferred and stored through the server.

Benefits of technology

It effectively avoids the waste of server storage space, improves the efficiency of other server services, and avoids the loss of intranet bandwidth resources caused by direct connection of terminals.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119030964A_ABST
    Figure CN119030964A_ABST
Patent Text Reader

Abstract

The embodiment of the invention discloses a file transmission method and a terminal.The method comprises the steps that a first terminal obtains direct connection attribute information of a second terminal through a server, and then the first terminal establishes a file direct connection channel with the second terminal based on the direct connection attribute information; and the first terminal can send the target file to the second terminal based on the file direct connection channel. The server is used for transmitting the direct connection attribute information for establishing the file direct connection channel, the situation that the target file is transmitted through the server is avoided, and therefore the technical problem that when the number of devices is large and file transmission is carried out between the devices, the transmitted file occupies a large storage space of the server, and development of other services of the server is affected is solved. In addition, the functional distinguishing between the terminal and the server is clear, and the problem that in the prior art, due to the fact that terminal direct connection is directly utilized, each terminal has the function of the terminal and the function of the server, and consequently a large amount of internal network bandwidth resources are consumed is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of data transmission, and in particular to a file transmission method and terminal. Background Art

[0002] With the rapid development of information technology, various communication tools have emerged rapidly. In work and daily life, communication tools are often used to transfer various files. When there are many devices, when transferring files between devices, the transferred files will occupy a large storage space of the server, causing a large waste of server space, thereby affecting the development of other services on the server. Summary of the invention

[0003] The embodiment of the present application provides a file transfer method and terminal, which can solve the technical problem that when there are many devices and files are transferred between devices, the transferred files will occupy a large storage space of the server, causing a large waste of server space, thereby affecting the development of other services of the server.

[0004] In a first aspect, an embodiment of the present application provides a file transmission method, which is applied to a first terminal, wherein the first terminal establishes a communication connection with a second terminal through a server, and the method includes:

[0005] In response to the first operation, sending a request for establishing a file direct connection channel to the second terminal through the server for the first operation;

[0006] receiving direct connection attribute information corresponding to the second terminal returned by the server, and establishing a file direct connection channel with the second terminal based on the direct connection attribute information, wherein the direct connection attribute information is obtained by the second terminal in response to the request and returned by the server;

[0007] In response to a second operation of sending the target file to the second terminal, the target file is sent to the second terminal through the file direct connection channel for the second operation.

[0008] Optionally, after sending the target file to the second terminal through the file direct connection channel for the second operation, the method further includes:

[0009] When the target file is sent completely or fails to be sent, the file direct connection channel is closed.

[0010] Optionally, the failure to send the target file includes that the second terminal refuses to receive the target file or the second terminal fails to receive the target file within a preset time.

[0011] Optionally, before responding to the first operation, the method further comprises:

[0012] After confirming that the user corresponding to the first terminal has direct connection authority, displaying an operation entry corresponding to the first operation;

[0013] The step of responding to the first operation includes:

[0014] In response to a first operation issued by the user based on the operation entry.

[0015] Optionally, the direct connection attribute information is obtained by the second terminal in response to the request and returned by the server, including:

[0016] The direct connection attribute information is determined by the address of the direct connection service opened by the second terminal in response to the request, and is returned by the server; wherein the direct connection service is used to enable the second terminal to establish a file direct connection channel with the first terminal.

[0017] Optionally, the sending the target file to the second terminal through the file direct connection channel for the second operation includes:

[0018] For the second operation, the target file is sent to the second terminal through the file direct connection channel, so that the second terminal displays at least one of file information and transmission information of the target file; the file information includes at least one of the file name, file occupied space and file type icon of the target file; the transmission information includes sending progress indication information corresponding to the target file.

[0019] In a second aspect, an embodiment of the present application provides a file transmission method, which is applied to a server, and a first terminal and a second terminal establish a communication connection through the server, and the method includes:

[0020] receiving a request for establishing a file direct connection channel sent by the first terminal in response to the first operation and for the first operation, and forwarding the request to the second terminal;

[0021] receiving direct connection attribute information returned by the second terminal in response to the request, and sending the direct connection attribute information to the first terminal, so that the first terminal establishes a file direct connection channel with the second terminal based on the direct connection attribute information;

[0022] And the first terminal is caused to respond to a second operation of sending a target file to the second terminal, and the first terminal is caused to send the target file to the second terminal through the file direct connection channel in response to the second operation.

[0023] Optionally, the file direct connection channel is also used to close when the target file is sent completely or when the target file fails to be sent.

[0024] Optionally, the failure to send the target file includes that the second terminal refuses to receive the target file or the second terminal fails to receive the target file within a preset time.

[0025] Optionally, the receiving a request for establishing a file direct connection channel sent by the first terminal in response to a first operation and in response to the first operation includes:

[0026] A request for establishing a direct file connection channel is received from the first terminal in response to a first operation initiated by a user based on an operation portal, wherein the operation portal is displayed before the first terminal responds to the first operation and after the first terminal confirms that the corresponding user has direct connection authority.

[0027] Optionally, the receiving the direct connection attribute information returned by the second terminal in response to the request, and sending the direct connection attribute information to the first terminal includes:

[0028] Receiving direct connection attribute information determined based on the address of the direct connection service opened by the second terminal in response to the request, and sending the direct connection attribute information to the first terminal; wherein the direct connection service is used to enable the second terminal to establish a file direct connection channel with the first terminal.

[0029] Optionally, the step of causing the first terminal to send the target file to the second terminal through the file direct connection channel in response to the second operation includes:

[0030] And the first terminal sends the target file to the second terminal through the file direct connection channel for the second operation, so that the second terminal displays at least one of the file information and transmission information of the target file; the file information includes at least one of the file name, file occupied space, and file type icon of the target file; the transmission information includes the sending progress indication information corresponding to the target file.

[0031] In a third aspect, an embodiment of the present application provides a first terminal, where the first terminal establishes a communication connection with a second terminal through a server, and the first terminal includes:

[0032] A first response module, adapted to respond to a first operation and send a request for establishing a file direct connection channel to the second terminal through the server in response to the first operation;

[0033] a receiving module, adapted to receive direct connection attribute information corresponding to the second terminal returned by the server, and establish a file direct connection channel with the second terminal based on the direct connection attribute information, wherein the direct connection attribute information is obtained by the second terminal in response to the request and returned by the server;

[0034] The second response module is adapted to respond to a second operation of sending the target file to the second terminal and send the target file to the second terminal through the file direct connection channel according to the second operation.

[0035] Optionally, the second response module is further adapted to close the file direct connection channel when the target file is sent completely or when the target file fails to be sent.

[0036] Optionally, the failure to send the target file includes that the second terminal refuses to receive the target file or the second terminal fails to receive the target file within a preset time.

[0037] Optionally, the first terminal further includes a direct connection authority confirmation module, and the direct connection authority confirmation module is adapted to display an operation entry corresponding to the first operation after confirming that the user corresponding to the first terminal has direct connection authority;

[0038] The first response module is further adapted to respond to a first operation issued by the user based on the operation entry.

[0039] Optionally, the direct connection attribute information in the receiving module is acquired by the second terminal in response to the request and returned by the server, including:

[0040] The direct connection attribute information is determined by the address of the direct connection service opened by the second terminal in response to the request, and is returned by the server; wherein the direct connection service is used to enable the second terminal to establish a file direct connection channel with the first terminal.

[0041] Optionally, the second response module is suitable for sending the target file to the second terminal through the file direct connection channel for the second operation, so that the second terminal displays at least one of the file information and transmission information of the target file; the file information includes at least one of the file name, file occupied space and file type icon of the target file; the transmission information includes the sending progress indication information corresponding to the target file.

[0042] In a fourth aspect, an embodiment of the present application provides a server, through which a first terminal and a second terminal establish a communication connection, and the server includes:

[0043] a forwarding module, adapted to receive a request for establishing a file direct connection channel sent by the first terminal in response to the first operation and in response to the first operation, and forward the request to the second terminal;

[0044] a direct connection attribute information acquisition module, adapted to receive the direct connection attribute information returned by the second terminal in response to the request, and send the direct connection attribute information to the first terminal, so that the first terminal establishes a file direct connection channel with the second terminal based on the direct connection attribute information;

[0045] The file direct connection channel module is adapted to enable the first terminal to respond to a second operation of sending a target file to the second terminal, and enable the first terminal to send the target file to the second terminal through the file direct connection channel in response to the second operation.

[0046] Optionally, the file direct connection channel in the file direct connection channel module is also used to close when the target file is sent completely or when the target file fails to be sent.

[0047] Optionally, the failure to send the target file includes that the second terminal refuses to receive the target file or the second terminal fails to receive the target file within a preset time.

[0048] Optionally, the forwarding module is suitable for receiving a request for establishing a direct file connection channel sent by the first terminal in response to a first operation issued by a user based on an operation portal; wherein the operation portal is displayed before the first terminal responds to the first operation and after the first terminal confirms that its corresponding user has direct connection authority.

[0049] Optionally, the direct connection attribute information acquisition module is also suitable for receiving direct connection attribute information determined based on the address of the direct connection service opened by the second terminal for the request, and sending the direct connection attribute information to the first terminal; wherein the direct connection service is used to enable the second terminal to establish a file direct connection channel with the first terminal.

[0050] Optionally, the step of causing the first terminal to send the target file to the second terminal through the file direct connection channel in response to the second operation includes:

[0051] And the first terminal sends the target file to the second terminal through the file direct connection channel for the second operation, so that the second terminal displays at least one of the file information and transmission information of the target file; the file information includes at least one of the file name, file occupied space, and file type icon of the target file; the transmission information includes the sending progress indication information corresponding to the target file.

[0052] In a fifth aspect, an embodiment of the present application provides a terminal, the terminal comprising:

[0053] Processor; and

[0054] A memory arranged to store computer executable instructions, which, when executed, cause the processor to perform a method according to any one of the above embodiments.

[0055] In a sixth aspect, an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores one or more programs, and when the one or more programs are executed by a processor, implement any of the methods described above.

[0056] The beneficial effects brought by the technical solutions provided in some embodiments of the present application include at least: the first terminal obtains the direct connection attribute information of the second terminal through the server, and then the first terminal establishes a file direct connection channel with the second terminal based on the direct connection attribute information. After the file direct connection channel is established, the first terminal can send the target file to the second terminal based on the file direct connection channel. In the present application, the server is used to transmit the direct connection attribute information for establishing the file direct connection channel, avoiding the use of the server to transmit the target file, thereby solving the technical problem that when there are many devices, when files are transferred between devices, the transferred files will occupy a large storage space of the server, which will cause a large waste of server space, thereby affecting the development of other services of the server. In addition, the functional distinction between the terminal and the server in the present application is clear, and it also avoids the problem in the prior art that each terminal has both the function of a terminal and the function of a server due to the direct use of the terminal direct connection, which leads to a large loss of intranet bandwidth resources. BRIEF DESCRIPTION OF THE DRAWINGS

[0057] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the embodiments of the present application. For those skilled in the art, other drawings can be obtained based on these drawings without paying any creative work.

[0058] Figure 1 An exemplary system architecture diagram of a file transmission method provided in an embodiment of the present application;

[0059] Figure 2 A flowchart of a file transmission method provided in an embodiment of the present application;

[0060] Figure 3 A schematic diagram of an interface in which a first terminal sends a target file to a second terminal through a file direct connection channel for a second operation provided in an embodiment of the present application;

[0061] Figure 4 A schematic diagram of an interface for sending a target file from a first terminal to a second terminal provided in another embodiment of the present application;

[0062] Figure 5 A schematic diagram of an interface for a second terminal receiving a target file provided in an embodiment of the present application;

[0063] Figure 6 A schematic diagram of an interface for receiving a target file by a second terminal provided in another embodiment of the present application;

[0064] Figure 7 A schematic diagram of an interface in which a first terminal successfully sends a target file provided in an embodiment of the present application;

[0065] Figure 8 A schematic diagram of an interface in which a second terminal successfully receives a target file provided in an embodiment of the present application;

[0066] Fig. 9 A schematic diagram of an interface in which a first terminal fails to send a target file provided in an embodiment of the present application;

[0067] Fig.10 A schematic diagram of an interface in which a second terminal fails to receive a target file provided in an embodiment of the present application;

[0068] Fig.11 A flowchart of a method for implementing file transmission by interaction between a first terminal, a second terminal and a server provided in an embodiment of the present application;

[0069] Fig.12 A schematic diagram of the structure of a first terminal provided in an embodiment of the present application;

[0070] Fig.13 A schematic diagram of the structure of a server provided in an embodiment of the present application;

[0071] Fig.14 A schematic diagram of the structure of a terminal for executing a file transmission method applied to a first terminal or a file transmission method applied to a server provided in an embodiment of the present application. DETAILED DESCRIPTION

[0072] In order to make the features and advantages of the embodiments of the present application more obvious and easy to understand, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of them. Based on the embodiments in the embodiments of the present application, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the embodiments of the present application.

[0073] With the rapid development of information technology, various communication tools have emerged rapidly. At present, the transmission of files with the help of communication tools is a common means. For example, in government and enterprises, there is often a frequent need to transmit large files between staff members. When a staff member uses a communication tool to transfer a file to another staff member's corresponding device, the file must first be uploaded to the server. After the server receives and stores the file, it forwards the file to the other staff member's corresponding device. Since the file needs to be transferred and stored through the server, when the number of staff members is large, the space occupied by the file on the server will also be very large, which will greatly waste the server's storage space and will also affect the development of other server services.

[0074] In order to solve this technical problem, the present application provides a file transmission method, firstly, the first terminal obtains the direct connection attribute information of the second terminal through the server, and then the first terminal establishes a file direct connection channel with the second terminal based on the direct connection attribute information. After the file direct connection channel is established, the first terminal can send the target file to the second terminal based on the file direct connection channel. In the present application, the server is used to transmit the direct connection attribute information for establishing the file direct connection channel, avoiding the use of the server to transmit the target file, thereby solving the technical problem that when there are many devices, when files are transferred between devices, the transferred files will occupy a large storage space of the server, which will cause a large waste of server space, thereby affecting the development of other services of the server. In addition, the functional distinction between the terminal and the server in the present application is clear, and it also avoids the problem in the prior art that each terminal has both the function of a terminal and the function of a server due to the direct use of the terminal direct connection, thereby causing a large loss of intranet bandwidth resources.

[0075] See also Figure 1 , Figure 1 An exemplary system architecture diagram of a file transfer method provided in an embodiment of the present application.

[0076] like Figure 1 As shown, the system architecture may include a first terminal 101, a first network 102, a server 103, a second terminal 104, and a second network 105. The first network 102 is used to provide a medium for a communication link between the first terminal 101 and the server 103, and to provide a communication link between the second terminal 101 and the server 103. The second network is used to provide a medium for a communication link between the first terminal 101 and the second terminal 104. The first network 102 or the second network 105 may include various types of wired communication links or wireless communication links, for example: the wired communication link includes an optical fiber, a twisted pair or a coaxial cable, etc., and the wireless communication link includes a Bluetooth communication link, a Wireless-Fidelity (Wi-Fi) communication link or a microwave communication link, etc.

[0077] The first terminal 101 can interact with the server 103 through the first network 102 to receive a message from the server 103 or send a message to the server 103, or the first terminal 101 can interact with the server 103 through the first network 102, and then receive a message or data sent by the second terminal 104 to the server 103, and the second terminal 104 can interact with the server 103 through the first network 102. The first terminal 101 or the second terminal 104 can be hardware or software. When the first terminal 101 or the second terminal 104 is hardware, it can be various terminals, including but not limited to smart watches, smart phones, tablet computers, laptop portable computers, and desktop computers. When the first terminal 101 or the second terminal 104 is software, it can be installed in the above-listed terminals, which can be implemented as multiple software or software modules (for example: used to provide distributed services), or can be implemented as a single software or software module, which is not specifically limited here.

[0078] In an embodiment of the present application, the first terminal 101 can respond to a first operation and send a request for establishing a file direct connection channel to the second terminal 104 through the server 103 for the first operation; thereafter, the first terminal 101 receives the direct connection attribute information corresponding to the second terminal 104 returned by the server 103, and establishes a file direct connection channel with the second terminal 104 based on the direct connection attribute information, and the direct connection attribute information is obtained by the second terminal 104 in response to the request and returned by the server 103; then, the first terminal 101 responds to a second operation of sending a target file to the second terminal 104, and sends the target file to the second terminal 104 through the file direct connection channel for the second operation.

[0079] The server 103 may be a business server that provides various services. It should be noted that the server 103 may be hardware or software. When the server 103 is hardware, it may be implemented as a distributed server cluster consisting of multiple servers, or it may be implemented as a single server. When the server 103 is software, it may be implemented as multiple software or software modules (for example, for providing distributed services), or it may be implemented as a single software or software module, which is not specifically limited here.

[0080] In an embodiment of the present application, the server 103 can receive a request for establishing a file direct connection channel sent by the first terminal 101 in response to a first operation and for the first operation, and forward the request to the second terminal 104; receive direct connection attribute information returned by the second terminal 104 in response to the request, and send the direct connection attribute information to the first terminal 101, so that the first terminal 101 establishes a file direct connection channel with the second terminal 104 based on the direct connection attribute information; and enable the first terminal 101 to respond to a second operation of sending a target file to the second terminal 104, and enable the first terminal 101 to send the target file to the second terminal 104 through the file direct connection channel in response to the second operation.

[0081] It should be understood that Figure 1 The number of the first terminal, the second terminal, the first network, the second network, and the server is only illustrative, and can be any number of the first terminal, the second terminal, the first network, the second network, and the server according to the implementation requirements. Here, the first terminal and the second terminal can be Web (World Wide Web) type terminals; or, the first terminal and the second terminal can run client programs packaged based on Web technology. Web-type clients can be clients created based on Web technology, including but not limited to Web browser clients, and native Web-type clients, Linux-type clients, and Mac OS-type clients created using packaging technologies such as Electron. Electron is a cross-platform desktop application built using JavaScript, HTML (Hypertext Mark-up Language) and CSS (Cascading Style Sheets).

[0082] See also Figure 2 , Figure 2 A flowchart of a file transfer method provided for an embodiment of the present application. The execution subject of the embodiment of the present application can be a first terminal that executes the file transfer method, or a processor in the first terminal that executes the file transfer method, or a file transfer service in the first terminal that executes the file transfer method. For the convenience of description, the specific execution process of the file transfer method is introduced below by taking the execution subject being the processor in the first terminal as an example.

[0083] The method is applied to a first terminal, and the first terminal and the second terminal establish a communication connection through a server, thereby realizing communication between the first terminal and the second terminal based on the server. Here, the communication connection may include a wired connection and a wireless connection. Among them, the wired connection method can be implemented based on a wired transmission medium such as a twisted pair, a coaxial cable, and an optical fiber, and the wireless connection method can be implemented based on a wireless transmission medium such as a microwave, an infrared ray, and a radio wave. It is easy to understand that the method provided in the embodiment of the present application is not limited to the first terminal being able to send a target file to the second terminal, and it can also be that the second terminal sends a target file to the first terminal. At this time, the scheme of the embodiment of the present application can be adaptively adjusted accordingly.

[0084] like Figure 2 As shown, the method includes:

[0085] S202: In response to the first operation, a request for establishing a file direct connection channel is sent to the second terminal through the server for the first operation.

[0086] Among them, the first operation may be an operation corresponding to a request initiated by a user to establish a direct file connection channel, and the first operation includes but is not limited to a mouse click, a finger touch, and an air selection based on camera recognition in the first device on a target area in the display area of ​​the first device. Here, the target area may be a functional area for sending a request to establish a direct file connection channel. A direct file connection channel may be a channel for directly connecting two terminals. The two connected terminals may directly transmit data such as files and information in a unidirectional or bidirectional manner based on the direct file connection channel, avoiding reliance on a server to store and transfer files.

[0087] After the processor in the first terminal responds to the first operation of the user, the processor sends a request for establishing a direct file connection with the second terminal to the server in response to the first operation, and after receiving the request, the server can forward the request to the second terminal. Here, the reception and forwarding of the request in the server can be implemented based on the long connection service module in the server, and the long connection service module is used for general long connection instant messaging services, so that the first terminal and the second terminal can maintain a session connection through the long connection service module.

[0088] S204: Receive direct connection attribute information corresponding to the second terminal returned by the server, and establish a file direct connection channel with the second terminal based on the direct connection attribute information, where the direct connection attribute information is obtained by the second terminal in response to the request and returned by the server.

[0089] After the second terminal receives the request forwarded by the server, the second terminal obtains the direct connection attribute information corresponding to the second terminal in response to the request. Then, the second terminal sends the direct connection attribute information to the server. After receiving the direct connection attribute information sent by the second terminal, the server sends the direct connection attribute information to the first terminal.

[0090] After the first terminal receives the direct connection attribute information returned by the server, it uses the direct connection attribute information of the second terminal to establish a file direct connection channel with the second terminal. At this time, the first terminal and the second terminal can directly transmit files, information and other data based on the file direct connection channel, avoiding the occupation of server memory space when transferring through the server.

[0091] In a feasible implementation, after the second terminal receives the request forwarded by the server, when the user corresponding to the second terminal agrees to establish a direct file connection channel with the first terminal, the second terminal obtains the direct connection attribute information corresponding to the second terminal in response to the request and sends the direct connection attribute information to the server; when the user corresponding to the second terminal refuses to establish a direct file connection channel with the first terminal, the second terminal sends a rejection request to the server and the server forwards it to the first terminal. After receiving the rejection request, the first terminal displays the rejection request. At this time, the first terminal and the second terminal fail to successfully establish a direct file connection channel.

[0092] Optionally, in step S204, the direct connection attribute information is obtained by the second terminal in response to the request and returned by the server, including:

[0093] The direct connection attribute information is determined by the second terminal for the address of the direct connection service requested to be opened, and is returned by the server; wherein the direct connection service is used to enable the second terminal to establish a file direct connection channel with the first terminal.

[0094] When the second terminal receives the request forwarded by the server, and the user corresponding to the second terminal agrees to establish a direct file connection channel with the first terminal in response to the request, the second terminal starts the direct connection service, which is used to enable the second terminal to establish a direct file connection channel with the first terminal. Specifically, the direct connection service can be a WebSocket service, which is a protocol for full-duplex communication on a single TCP (Transmission Control Protocol) connection, so that after the first terminal and the second terminal complete a handshake using WebSocket, a persistent connection can be directly created between the two terminals, and two-way data transmission can be performed.

[0095] Here, the direct connection attribute information may be determined by the address of the direct connection service enabled in the second terminal. The address of the direct connection service may include an IP (Internet Protocol) address and port information of the direct connection service, such as the IP address and port information corresponding to the WebSocket service.

[0096] like Figure 1As shown, the second terminal can send a request to the IP address resolution server 107 to obtain its own IP address. After receiving the request, the IP address resolution server 107 returns the resolved IP address of the second terminal to the second terminal. The IP address resolution server 107 is connected to the second terminal through the third network 106. The description of the third network 106 can refer to the first network 102. Of course, the second terminal can also obtain its own IP address based on the system API (Application Programming Interface).

[0097] After receiving the IP address and port information of the specified WebSocket service opened by the second terminal, the first terminal attempts to establish a WebSocket connection to the second terminal based on the IP address and port information. When the WebSocket connection is successful, the file direct connection channel is successfully created.

[0098] S206: In response to the second operation of sending the target file to the second terminal, sending the target file to the second terminal through the file direct connection channel for the second operation.

[0099] See also Figure 3 , Figure 3 A schematic diagram of an interface for a first terminal to send a target file to a second terminal through a file direct connection channel for a second operation provided in an embodiment of the present application. After the first terminal and the second terminal have established a file direct connection channel, the user can perform a second operation on the first terminal to send a selected target file to the second terminal, and the second operation includes but is not limited to adding the selected target file to a specified area in a specified display area of ​​the first terminal (see Figure 3 The designated area is used to implement the function of sending the selected target file to the second terminal. Adding the selected target file to the designated area may include opening the storage location of the target file in the designated area to add it or dragging the target file to the designated area. Of course, other feasible implementation methods may also be included, which will not be described in detail here.

[0100] After receiving the second operation, the first terminal sends the selected target file to the second terminal based on the file direct connection channel for the second operation. Optionally, sending the target file to the second terminal through the file direct connection channel for the second operation in step S206 includes:

[0101] For the second operation, the target file is sent to the second terminal through the file direct connection channel, so that the second terminal displays at least one of the file information and transmission information of the target file; the file information includes at least one of the file name, file occupied space and file type icon of the target file; the transmission information includes the sending progress indication information corresponding to the target file.

[0102] The first terminal sends the target file to the second terminal through the file direct transmission channel. At this time, the first terminal can display the sending information of the sent target file, such as Figure 3 As shown in the 302 area in the figure, the sending information may include the file type icon, the file name, the file occupied space, and the receiving status of the file. The receiving status of the file may include one of waiting to receive, refusing to receive, and sending.

[0103] See also Figure 4 , Figure 4 A schematic diagram of an interface for sending a target file from a first terminal to a second terminal provided in an embodiment of the present application. Figure 4 As shown in the 401 area in the figure, when the receiving status of the target file is sending, the first terminal can display the size of the target file that has been sent and the actual size of the target file. At the same time, the ratio of the size of the target file that has been sent to the actual size of the target file can be displayed in the form of a progress bar. It should be noted that the first terminal can cancel the sending process during the process of sending the target file to the second terminal, and the sending of the target file fails at this time.

[0104] See also Figure 5 , Figure 5 A schematic diagram of an interface for a second terminal receiving a target file provided in an embodiment of the present application. Figure 5 As shown in the 501 area in the figure, the first terminal sends the target file to the second terminal through the file direct transmission channel. At this time, the second terminal can display operations such as receiving, saving as and rejecting, which can realize the instant demand for sending and receiving the target file.

[0105] See also Figure 6 , Figure 6 A schematic diagram of an interface for receiving a target file by a second terminal provided in an embodiment of the present application. Figure 6 As shown in area 601 in the figure, when the second terminal agrees to receive the target file, the second terminal can display at least one of the file information and transmission information of the target file. The file information may include at least one of the file name of the target file, the space occupied by the file, and the file type icon. The file type icon may include a table icon, a document icon, a presentation icon, and a compressed package icon. The sending progress indication information corresponding to the target file in the transmission information may include the size of the received target file and the actual size of the target file. Similarly, the ratio of the received target file size to the actual size of the target file can be displayed in the form of a progress bar. It should be noted that, Figure 4 As shown, the second terminal can cancel the receiving process when receiving the target file sent by the first terminal, and the target file fails to be sent.

[0106] Optionally, after sending the target file to the second terminal through the file direct connection channel for the second operation in step S206, the method further includes:

[0107] When the target file is sent completely or fails to be sent, the file direct connection channel is closed.

[0108] Among them, after the target file is sent, the file direct connection channel is closed, which avoids the first device and the second device being directly connected all the time, resulting in invalid occupation of the processor resources corresponding to the first device and the processor resources corresponding to the second device.

[0109] See also Figure 7 , Figure 7 A schematic diagram of an interface in which a first terminal successfully sends a target file provided in an embodiment of the present application. Figure 8 , Figure 8 A schematic diagram of an interface in which a second terminal successfully receives a target file provided in an embodiment of the present application. Figure 7 and Figure 8 As shown, after the target file sent by the first device to the second device through the file direct connection channel is sent, the display area of ​​the first device can display "Sent successfully", and the display area of ​​the second device can display "Received successfully, open the folder". In the second device, you can click "Received successfully, open the folder" to open the folder and locate the location of the target file that has been successfully received.

[0110] See also Fig. 9 , Fig. 9 This is a schematic diagram of an interface in which a first terminal fails to send a target file provided in an embodiment of the present application. Fig.10 , Fig.10 A schematic diagram of an interface in which a second terminal fails to receive a target file provided in an embodiment of the present application. When the target file fails to be sent, the file direct connection channel is also closed. The target file sending failure includes the second terminal refusing to receive the target file or the second terminal not receiving the target file within a preset time. Fig. 9 and Fig.10 A schematic diagram of an interface in which the second terminal refuses to receive a target file is shown. The first terminal may display "sending failed, the other party has refused, please send again", and the second terminal may display "receiving failed, reception has been refused". In some feasible implementations, the failure to send the target file may also include the first terminal cancelling the sending process when sending the target file to the second terminal, and the second terminal cancelling the receiving process when receiving the target file sent by the first terminal.

[0111] Similarly, the file direct connection channel between the first device and the second device will not always be connected. When the second terminal refuses to receive the target file or the second terminal does not receive the target file within the preset time, the file direct connection channel is closed to avoid invalid occupation of the processor resources corresponding to the first device and the processor resources corresponding to the second device. The preset time for not receiving the target file can be 30 minutes, 1 hour or 1 day, etc., which can be set according to actual needs.

[0112] Optionally, before responding to the first operation in step S202, the method includes:

[0113] After confirming that the user corresponding to the first terminal has direct connection authority, displaying an operation entry corresponding to the first operation;

[0114] In response to the first operation, step S202 includes:

[0115] In response to a first operation issued by the user based on the operation entry.

[0116] The first terminal detects whether the corresponding user has direct connection permission, and displays the operation entry corresponding to the first operation after the first terminal detects that the corresponding user has direct connection permission. Among them, the server is used to distribute direct connection permission to specific users. Specifically, the server can grant the specified user in the specified first device direct connection permission through the RBAC module (Role-Based Access Control). Here, it can be determined whether the user has direct connection permission based on the account logged in by the user on the first device for identification. For example, after the server grants the specified user in the specified first device direct connection permission through the RBAC module, when the specified user logs in to the account of the corresponding communication software in the first device, the first device can display the operation entry corresponding to the first operation, so that the specified user can perform the first operation on the first device. Here, the communication software can be a client program packaged based on Web technology.

[0117] When the user performs the first operation on the first device, the object for establishing the direct file transfer channel is first determined, and the object for establishing the direct file transfer channel is determined based on the address book of the communication software. The user can click on the object determined in the address book to display the corresponding dialog window, and the dialog window displays an operation entry corresponding to the first operation. The user can issue a request to establish the direct file connection channel by clicking on the operation entry.

[0118] The embodiment of the present application provides a file transfer method, in which the server is used to transmit direct connection attribute information for establishing a file direct connection channel, avoiding the use of the server to transfer the target file, thereby solving the technical problem that when there are many devices, when files are transferred between devices, the transferred files will occupy a large storage space of the server, causing a large waste of server space, thereby affecting the development of other services of the server. In addition, the functional distinction between the terminal and the server is clear in the present application, and the problem that each terminal has both the function of a terminal and the function of a server due to the direct use of the terminal in the prior art is avoided, which leads to a large loss of intranet bandwidth resources.

[0119] See also Fig.11 , Fig.11 A flowchart of a method for implementing file transmission through interaction between a first terminal, a second terminal and a server provided in an embodiment of the present application.

[0120] like Fig.11 As shown, the method includes:

[0121] S1102: The first terminal responds to the first operation.

[0122] The specific content of step S1102 can refer to the relevant description of step S202, which will not be repeated here.

[0123] S1104: The first terminal sends a request to the server for establishing a direct file connection channel between the first terminal and the second terminal in response to the first operation.

[0124] The specific content of step S1104 can also refer to the relevant description of step S202, which will not be repeated here.

[0125] S1106: The server receives the request.

[0126] The server receives a request for establishing a file direct connection channel sent by the first terminal in response to a first operation issued by the user based on the operation portal; the operation portal is displayed before the first terminal responds to the first operation and after the first terminal confirms that the corresponding user has direct connection authority. For content not described in step S1106, refer to the relevant description of step S204.

[0127] S1108: The server forwards the request to the second terminal.

[0128] The specific content of step S1108 may refer to the relevant description of step S204.

[0129] S1110: The second terminal receives the request.

[0130] For the specific content of step S1110, reference may be made to the description of step S204.

[0131] S1112: The second terminal returns the direct connection attribute information corresponding to the second terminal to the server in response to the request.

[0132] The specific content of step S1112 may refer to the relevant description of step S204.

[0133] S1114: The server receives direct connection attribute information.

[0134] The receiving device receives direct connection attribute information determined based on the address of the direct connection service opened by the second terminal for the request; wherein the direct connection service is used to establish a file direct connection channel between the second terminal and the first terminal. For the contents not described in step S1114, please refer to the relevant description of step S204.

[0135] S1116: The server sends the direct connection attribute information to the first terminal.

[0136] The specific content of step S1116 may refer to the relevant description of step S204.

[0137] S1118: The first terminal establishes a file direct connection channel with the second terminal based on the direct connection attribute information.

[0138] The specific content of step S1118 may refer to the relevant description of step S204.

[0139] S1120: The first terminal responds to the second operation of sending the target file to the second terminal.

[0140] The specific content of step S1120 may refer to the related description of step S206.

[0141] S1122: The first terminal sends the target file to the second terminal through the file direct connection channel in response to the second operation.

[0142] The file direct connection channel is also used to close when the target file is sent or fails to send. The failure to send the target file includes the second terminal refusing to receive the target file or the second terminal not receiving the target file within a preset time. The first terminal sends the target file to the second terminal through the file direct connection channel for the second operation, and the second terminal displays at least one of the file information and transmission information of the target file; the file information includes at least one of the file name of the target file, the file occupied space, and the file type icon; the transmission information includes the sending progress indication information corresponding to the target file. For the content not described in step S1122, please refer to the relevant description of step S206.

[0143] An embodiment of the present application further provides a computer storage medium, which can store multiple instructions, and the instructions are suitable for being loaded by a processor and executing the steps of any method in the above embodiments.

[0144] Fig.12 This is a schematic diagram of the structure of a first terminal provided in an embodiment of the present application. Fig.12 shown.

[0145] The first terminal 1200 establishes a communication connection with the second terminal through a server, and the first terminal includes:

[0146] The first response module 1210 is adapted to respond to the first operation and send a request for establishing a file direct connection channel to the second terminal through the server for the first operation;

[0147] The receiving module 1220 is adapted to receive direct connection attribute information corresponding to the second terminal returned by the server, and establish a file direct connection channel with the second terminal based on the direct connection attribute information, wherein the direct connection attribute information is obtained by the second terminal in response to the request and returned by the server;

[0148] The second response module 1230 is adapted to respond to a second operation of sending the target file to the second terminal and send the target file to the second terminal through the file direct connection channel according to the second operation.

[0149] Optionally, the second response module 1230 is further adapted to close the file direct connection channel when the target file is sent completely or the target file fails to be sent.

[0150] Optionally, the failure to send the target file includes that the second terminal refuses to receive the target file or the second terminal fails to receive the target file within a preset time.

[0151] Optionally, the first terminal further includes a direct connection authority confirmation module, which is adapted to display an operation entry corresponding to the first operation after confirming that the user corresponding to the first terminal has the direct connection authority;

[0152] The first response module is further adapted to respond to a first operation issued by the user based on the operation portal.

[0153] Optionally, the direct connection attribute information in the receiving module 1220 is obtained by the second terminal in response to the request and returned by the server, including:

[0154] The direct connection attribute information is determined by the second terminal for the address of the direct connection service requested to be opened, and is returned by the server; wherein the direct connection service is used to enable the second terminal to establish a file direct connection channel with the first terminal.

[0155] Optionally, the second response module 1230 is suitable for sending the target file to the second terminal through the file direct connection channel for the second operation, so that the second terminal displays at least one of the file information and transmission information of the target file; the file information includes at least one of the file name, file occupied space and file type icon of the target file; the transmission information includes the sending progress indication information corresponding to the target file.

[0156] Fig.13 A schematic diagram of the structure of a server provided in an embodiment of the present application. Fig.13 shown.

[0157] The first terminal establishes a communication connection with the second terminal through a server, and the server 1300 includes:

[0158] The forwarding module 1310 is adapted to receive a request for establishing a file direct connection channel sent by the first terminal in response to the first operation and for the first operation, and forward the request to the second terminal;

[0159] The direct connection attribute information acquisition module 1320 is adapted to receive the direct connection attribute information returned by the second terminal in response to the request, and send the direct connection attribute information to the first terminal, so that the first terminal establishes a file direct connection channel with the second terminal based on the direct connection attribute information;

[0160] The file direct connection channel module 1330 is adapted to enable the first terminal to respond to a second operation of sending a target file to the second terminal, and enable the first terminal to send the target file to the second terminal through the file direct connection channel in response to the second operation.

[0161] Optionally, the file direct connection channel in the file direct connection channel module 1330 is also used to close when the target file is sent completely or when the target file fails to be sent.

[0162] Optionally, the failure to send the target file includes that the second terminal refuses to receive the target file or the second terminal fails to receive the target file within a preset time.

[0163] Optionally, the forwarding module 1310 is suitable for receiving a request for establishing a direct file connection channel sent by the first terminal in response to a first operation issued by the user based on an operation portal; wherein the operation portal is displayed before the first terminal responds to the first operation and after the first terminal confirms that its corresponding user has direct connection authority.

[0164] Optionally, the direct connection attribute information acquisition module 1320 is further adapted to receive direct connection attribute information determined based on the address of the direct connection service requested to be opened by the second terminal, and send the direct connection attribute information to the first terminal; wherein the direct connection service is used to establish a file direct connection channel between the second terminal and the first terminal.

[0165] Optionally, enabling the first terminal to send a target file to the second terminal through a file direct connection channel for the second operation includes:

[0166] And the first terminal sends the target file to the second terminal through the file direct connection channel for the second operation, so that the second terminal displays at least one of the file information and transmission information of the target file; the file information includes at least one of the file name of the target file, the file occupied space, and the file type icon; the transmission information includes the sending progress indication information corresponding to the target file.

[0167] See also Fig.14 , Fig.14 A schematic diagram of the structure of a terminal for executing a file transmission method applied to a first terminal or a file transmission method applied to a server provided in an embodiment of the present application. Fig.14 As shown, the terminal 1400 may include: at least one processor 1401 , at least one network interface 1404 , a user interface 1403 , a memory 1405 , and at least one communication bus 1402 .

[0168] The communication bus 1402 is used to realize the connection and communication between these components.

[0169] The user interface 1403 may include a display screen (Display) and a camera (Camera), and the optional user interface 1403 may also include a standard wired interface and a wireless interface.

[0170] The network interface 1404 may optionally include a standard wired interface or a wireless interface (such as a WI-FI interface).

[0171] Among them, the processor 1401 may include one or more processing cores. The processor 1401 uses various interfaces and lines to connect the various parts of the entire experimental operation terminal 1400, and executes various functions and processes data of the sample data management terminal 1400 by running or executing instructions, programs, code sets or instruction sets stored in the memory 1405, and calling data stored in the memory 1405. Optionally, the processor 1401 can be implemented in at least one hardware form of digital signal processing (Digital Signal Processing, DSP), field programmable gate array (Field-Programmable Gate Array, FPGA), and programmable logic array (Programmable Logic Array, PLA). The processor 1401 can integrate one or more combinations of a central processing unit (Central Processing Unit, CPU), a graphics processing unit (Graphics Processing Unit, GPU) and a modem. Among them, the CPU mainly processes the operating system, user interface and application programs; the GPU is responsible for rendering and drawing the content to be displayed on the display screen; and the modem is used to process wireless communication. It can be understood that the above-mentioned modem may not be integrated into the processor 1401, and it can be implemented by a single chip.

[0172] Among them, the memory 1405 may include a random access memory (Random Access Memory, RAM) and may also include a read-only memory (Read-Only Memory, ROM). Optionally, the memory 1405 includes a non-transitory computer-readable storage medium. The memory 1405 can be used to store instructions, programs, codes, code sets or instruction sets. The memory 1405 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the above-mentioned various method embodiments, etc.; the data storage area may store data involved in the above-mentioned various method embodiments, etc. The memory 1405 may also be optionally at least one storage device located away from the aforementioned processor 1401. As Fig.14 As shown, the memory 1405 as a computer storage medium may include an operating system, a network communication module, a user interface module, and a file transmission program applied to the first terminal or to the server.

[0173] exist Fig.14In the terminal 1400 shown, the user interface 1403 is mainly used to provide an input interface for the user and obtain data input by the user; and the processor 1401 can be used to call the file transmission program applied to the first terminal or the server stored in the memory 1405. When the file transmission program applied to the first terminal is stored in the memory 1405, the processor 1401 specifically performs the following operations:

[0174] In response to the first operation, sending a request for establishing a file direct connection channel to the second terminal through the server for the first operation;

[0175] Receiving direct connection attribute information corresponding to the second terminal returned by the server, and establishing a file direct connection channel with the second terminal based on the direct connection attribute information, wherein the direct connection attribute information is obtained by the second terminal in response to the request and returned by the server;

[0176] In response to a second operation of sending the target file to the second terminal, the target file is sent to the second terminal through the file direct connection channel for the second operation.

[0177] Optionally, after executing the second operation of sending the target file to the second terminal through the file direct connection channel, the processor 1401 further specifically performs the following steps:

[0178] When the target file is sent completely or fails to be sent, the file direct connection channel is closed.

[0179] Optionally, the failure to send the target file includes that the second terminal refuses to receive the target file or the second terminal fails to receive the target file within a preset time.

[0180] Optionally, before the processor 1401 executes the response to the first operation, the processor 1401 further specifically performs the following steps:

[0181] After confirming that the user corresponding to the first terminal has direct connection authority, displaying an operation entry corresponding to the first operation;

[0182] When the processor 1401 executes the first operation in response, the following steps are specifically performed:

[0183] In response to a first operation issued by the user based on the operation entry.

[0184] Optionally, the direct connection attribute information is obtained by the second terminal in response to the request and returned by the server, including:

[0185] The direct connection attribute information is determined by the second terminal for the address of the direct connection service requested to be opened, and is returned by the server; wherein the direct connection service is used to enable the second terminal to establish a file direct connection channel with the first terminal.

[0186] Optionally, when the processor 1401 executes the second operation to send the target file to the second terminal through the file direct connection channel, the following steps are specifically performed:

[0187] For the second operation, the target file is sent to the second terminal through the file direct connection channel, so that the second terminal displays at least one of the file information and transmission information of the target file; the file information includes at least one of the file name, file occupied space and file type icon of the target file; the transmission information includes the sending progress indication information corresponding to the target file.

[0188] When the file transfer program applied to the server is stored in the memory 1405, the processor 1401 specifically performs the following operations:

[0189] receiving a request for establishing a file direct connection channel sent by the first terminal in response to the first operation and in response to the first operation, and forwarding the request to the second terminal;

[0190] receiving direct connection attribute information returned by the second terminal in response to the request, and sending the direct connection attribute information to the first terminal, so that the first terminal establishes a file direct connection channel with the second terminal based on the direct connection attribute information;

[0191] And the first terminal is caused to respond to a second operation of sending the target file to the second terminal, and the first terminal is caused to send the target file to the second terminal through the file direct connection channel in response to the second operation.

[0192] Optionally, the file direct connection channel is also used to close when the target file is sent completely or when the target file fails to be sent.

[0193] Optionally, the failure to send the target file includes that the second terminal refuses to receive the target file or the second terminal fails to receive the target file within a preset time.

[0194] Optionally, when the processor 1401 receives a request for establishing a file direct connection channel sent by the first terminal in response to the first operation and for the first operation, the processor 1401 specifically performs the following steps:

[0195] A request for establishing a file direct connection channel is received from a first terminal in response to a first operation issued by a user based on an operation portal; wherein the operation portal is displayed before the first terminal responds to the first operation and after the first terminal confirms that the corresponding user has direct connection authority.

[0196] Optionally, when the processor 1401 receives the direct connection attribute information returned by the second terminal in response to the request and sends the direct connection attribute information to the first terminal, the processor 1401 specifically performs the following steps:

[0197] Direct connection attribute information determined based on the address of the direct connection service requested to be opened by the second terminal is received, and the direct connection attribute information is sent to the first terminal; wherein the direct connection service is used to enable the second terminal to establish a file direct connection channel with the first terminal.

[0198] Optionally, enabling the first terminal to send a target file to the second terminal through a file direct connection channel for the second operation includes:

[0199] And the first terminal sends the target file to the second terminal through the file direct connection channel for the second operation, so that the second terminal displays at least one of the file information and transmission information of the target file; the file information includes at least one of the file name of the target file, the file occupied space, and the file type icon; the transmission information includes the sending progress indication information corresponding to the target file.

[0200] In the several embodiments provided in the embodiments of the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the modules is only a logical function division. There may be other division methods in actual implementation, such as multiple modules or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or modules, which can be electrical, mechanical or other forms.

[0201] The modules described as separate components may or may not be physically separated, and the components shown as modules may or may not be physical modules, that is, they may be located in one place or distributed on multiple network modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0202] In addition, each functional module in each embodiment of the present application can be integrated into a processing module, or each module can exist physically separately, or two or more modules can be integrated into one module. The above integrated modules can be implemented in the form of hardware or in the form of software functional modules.

[0203] If the integrated module is implemented in the form of a software function module and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the embodiment of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program code.

[0204] It should be noted that, for the aforementioned method embodiments, for the sake of simplicity of description, they are all expressed as a series of action combinations, but those skilled in the art should be aware that the embodiments of the present application are not limited by the described order of actions, because according to the embodiments of the present application, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the embodiments of the present application.

[0205] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0206] The above is a description of a file transfer method and terminal provided in an embodiment of the present application. For technicians in this field, according to the ideas of the embodiments of the present application, there may be changes in the specific implementation methods and application scopes. In summary, the content of this specification should not be understood as a limitation on the embodiments of the present application.

Claims

1. A file transmission method, applied to a first terminal, wherein the first terminal establishes a communication connection with a second terminal through a server, wherein: The method comprises: In response to the first operation, sending a request for establishing a file direct connection channel to the second terminal through the server for the first operation; receiving direct connection attribute information corresponding to the second terminal returned by the server, and establishing a file direct connection channel with the second terminal based on the direct connection attribute information, wherein the direct connection attribute information is obtained by the second terminal in response to the request and returned by the server; In response to a second operation of sending the target file to the second terminal, the target file is sent to the second terminal through the file direct connection channel for the second operation.

2. The file transmission method according to claim 1, wherein: After sending the target file to the second terminal through the file direct connection channel for the second operation, the method further includes: When the target file is sent completely or fails to be sent, the file direct connection channel is closed.

3. The file transmission method according to claim 2, wherein: The failure to send the target file includes that the second terminal refuses to receive the target file or the second terminal fails to receive the target file within a preset time.

4. The file transmission method according to claim 1, wherein: Before responding to the first operation, the method includes: After confirming that the user corresponding to the first terminal has direct connection authority, displaying an operation entry corresponding to the first operation; The step of responding to the first operation includes: In response to a first operation issued by the user based on the operation entry.

5. The file transmission method according to claim 1, wherein: The direct connection attribute information is obtained by the second terminal in response to the request and returned by the server, including: The direct connection attribute information is determined by the address of the direct connection service opened by the second terminal in response to the request, and is returned by the server; wherein the direct connection service is used to enable the second terminal to establish a file direct connection channel with the first terminal.

6. The file transmission method according to claim 1, wherein: The sending the target file to the second terminal through the file direct connection channel for the second operation includes: For the second operation, the target file is sent to the second terminal through the file direct connection channel, so that the second terminal displays at least one of file information and transmission information of the target file; the file information includes at least one of the file name, file occupied space and file type icon of the target file; the transmission information includes sending progress indication information corresponding to the target file.

7. A file transmission method, applied to a server, wherein a first terminal and a second terminal establish a communication connection through the server, wherein: The method comprises: receiving a request for establishing a file direct connection channel sent by the first terminal in response to the first operation and for the first operation, and forwarding the request to the second terminal; receiving direct connection attribute information returned by the second terminal in response to the request, and sending the direct connection attribute information to the first terminal, so that the first terminal establishes a file direct connection channel with the second terminal based on the direct connection attribute information; And the first terminal is caused to respond to a second operation of sending a target file to the second terminal, and the first terminal is caused to send the target file to the second terminal through the file direct connection channel in response to the second operation.

8. A first terminal, wherein the first terminal establishes a communication connection with a second terminal through a server, wherein: The first terminal includes: A first response module, adapted to respond to a first operation and send a request for establishing a file direct connection channel to the second terminal through the server in response to the first operation; a receiving module, adapted to receive direct connection attribute information corresponding to the second terminal returned by the server, and establish a file direct connection channel with the second terminal based on the direct connection attribute information, wherein the direct connection attribute information is obtained by the second terminal in response to the request and returned by the server; The second response module is adapted to respond to a second operation of sending the target file to the second terminal and send the target file to the second terminal through the file direct connection channel according to the second operation.

9. A server, through which a first terminal and a second terminal establish a communication connection, wherein: The server comprises: a forwarding module, adapted to receive a request for establishing a file direct connection channel sent by the first terminal in response to the first operation and in response to the first operation, and forward the request to the second terminal; a direct connection attribute information acquisition module, adapted to receive the direct connection attribute information returned by the second terminal in response to the request, and send the direct connection attribute information to the first terminal, so that the first terminal establishes a file direct connection channel with the second terminal based on the direct connection attribute information; The file direct connection channel module is adapted to enable the first terminal to respond to a second operation of sending a target file to the second terminal, and enable the first terminal to send the target file to the second terminal through the file direct connection channel in response to the second operation.

10. A terminal, wherein: The terminal includes: Processor; and A memory arranged to store computer executable instructions which, when executed, cause the processor to perform a method according to any one of claims 1 to 6 or 7.