Method, system and device for file transmission among multiple devices

The X11 clipboard mechanism facilitates efficient file transfer between cloud desktops by synchronizing file lists and automating the download process, addressing the inconvenience of existing cloud desktop transfer methods.

CN119254770AInactive Publication Date: 2025-01-03BEIJING TINGYU TECH CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202411754999.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-03
Publication Date
2025-01-03
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

The existing method of file transfer in cloud desktops is cumbersome and inconvenient for users, differing from the straightforward copy-paste operation on local desktops.

Method used

A method utilizing the X11 clipboard mechanism to synchronize a file list across devices, enabling efficient file transfer by copying the list on one device and automatically downloading and pasting it to another device through standard copy-paste operations.

Benefits of technology

Enables seamless and efficient file synchronization and paste operations between multiple devices, aligning with user habits by integrating file transfer into intuitive copy-paste actions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119254770A_ABST
    Figure CN119254770A_ABST
Patent Text Reader

Abstract

The invention relates to a file transmission method, system and device among multiple devices, which can obtain a copied file list when a copy operation instruction sent by a user on a first device is received, and synchronously store the file list to a second device through an X11 clipboard mechanism; when a pasting operation instruction sent by a user on the second device is received, all files and folders corresponding to the file list are downloaded from the first device in a recursive mode and stored in a temporary directory of the second device; setting a file list in the temporary directory as an X11 clipboard file list of the second equipment; and sending all files and folders corresponding to the X11 clipboard file list to a specified directory according to the pasting operation instruction. It can be understood that according to the technical scheme provided by the invention, efficient synchronization and pasting operation of the file lists among multiple devices can be achieved, a user can complete file transmission only through copying and pasting operation, and the operation habit of the user is met.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of file transmission, and in particular to a method, system and device for transmitting files between multiple devices. Background Art

[0002] Cloud desktop is a desktop virtualization service based on cloud computing technology. It migrates the traditional desktop environment from local computing devices (such as personal computers and laptops) to the cloud. Users can access the virtual desktop provided by the cloud through the network. The devices used include computers, tablets, smartphones, etc., and they can access their complete desktop environment as long as there is an Internet connection.

[0003] When a user uses a cloud desktop to access another smart device through a smart device, the user has a need to transfer files between the desktops of the two smart devices. The existing technical solution is that the user manually opens a file transfer interface, uploads the file to be sent on a new interface, and then downloads the file on the file transfer interface on the cloud desktop.

[0004] However, this method is different from the file transfer operation on the local desktop. The file transfer operation on the local desktop is usually a user copying a file and pasting it in the target directory, and the file will be copied to the target directory. Therefore, compared with the file transfer operation on the local desktop, the existing cloud desktop file transfer method is more cumbersome and inconvenient for users to use. Summary of the invention

[0005] In view of this, the purpose of the present invention is to provide a method, system and device for file transmission between multiple devices to solve the problem that the file transmission method of cloud desktop in the prior art is relatively cumbersome and inconvenient for users to use.

[0006] According to a first aspect of an embodiment of the present invention, a method for transmitting files between multiple devices is provided, comprising: When receiving a copy operation instruction issued by the user on the first device, obtaining a list of files to be copied according to the copy operation instruction, and synchronously storing the list of files to the second device through the X11 clipboard mechanism; When receiving a paste operation instruction issued by the user on the second device, recursively downloading all files and folders corresponding to the file list from the first device, and saving the downloaded content to a temporary directory of the second device; Set the file list in the temporary directory as the X11 clipboard file list of the second device; According to the paste operation instructions, all files and folders corresponding to the X11 clipboard file list are sent to the specified directory.

[0007] Preferably, synchronizing the file list to the second device via an X11 clipboard mechanism further includes: If the previously stored file list exists in the second device, the previously stored file list is deleted, and then the file list is synchronously stored in the second device through the X11 clipboard mechanism.

[0008] Preferably, obtaining a list of files to be copied according to the copy operation instruction includes: Obtaining the path of the file or folder to be copied according to the copy operation instruction; The path of the file or folder to be copied is converted into a file list in a preset format.

[0009] Preferably, the method for transmitting files between multiple devices further includes: The file list is transmitted from the first device to the second device via a network protocol.

[0010] Preferably, recursively downloading all files and folders corresponding to the file list from the first device includes: According to the file list, the file system of the first device is recursively traversed, and each file and folder corresponding to the file list is downloaded level by level.

[0011] Preferably, the method for transmitting files between multiple devices further includes: If the life cycle of the file or folder in the temporary directory reaches a preset time, the file or folder is deleted; or, A deletion instruction sent by a user is obtained, and files or folders in the temporary directory are deleted according to the deletion instruction.

[0012] According to a second aspect of an embodiment of the present invention, a system for transmitting files between multiple devices is provided, including: A file list synchronization module, configured to, when receiving a copy operation instruction issued by a user on a first device, obtain a copied file list according to the copy operation instruction, and synchronously store the file list to a second device through an X11 clipboard mechanism; A file download module, configured to recursively download all files and folders corresponding to the file list from the first device upon receiving a paste operation instruction issued by the user on the second device, and save the downloaded content to a temporary directory of the second device; The file pasting module is used to set the file list in the temporary directory as the X11 clipboard file list of the second device; according to the paste operation instruction, all files and folders corresponding to the X11 clipboard file list are sent to the designated directory.

[0013] According to a third aspect of an embodiment of the present invention, a multi-device file transmission device is provided, including: A main controller, and a memory connected to the main controller; a memory in which program instructions are stored; The main controller is used to execute program instructions stored in the memory to perform any of the above methods.

[0014] The technical solution provided by the embodiments of the present invention may have the following beneficial effects: It can be understood that the technical solution shown in the present invention can obtain the copied file list when receiving the copy operation instruction issued by the user on the first device, and store the file list synchronously to the second device through the X11 clipboard mechanism; when receiving the paste operation instruction issued by the user on the second device, recursively download all the files and folders corresponding to the file list from the first device and save them to the temporary directory of the second device; set the file list in the temporary directory as the X11 clipboard file list of the second device; according to the paste operation instruction, send all the files and folders corresponding to the X11 clipboard file list to the specified directory. It can be understood that the technical solution provided by the present invention can realize the efficient synchronization and paste operation of the file list between multiple devices. The user only needs to copy and paste operations to complete the file transfer, which is in line with the user's operating habits.

[0015] It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.

[0017] Figure 1 The figure is a schematic diagram of the steps of a method for transmitting files between multiple devices according to an exemplary embodiment. DETAILED DESCRIPTION

[0018] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present invention. Instead, they are merely examples of devices and methods consistent with some aspects of the present invention as detailed in the appended claims.

[0019] In one embodiment, Figure 1 is a schematic diagram of a method for transmitting files between multiple devices according to an exemplary embodiment. Figure 1 , a method for transmitting files between multiple devices is provided, comprising: Step S11: when receiving a copy operation instruction issued by the user on the first device, obtaining a copied file list according to the copy operation instruction, and synchronously storing the file list to the second device through the X11 clipboard mechanism; Step S12: when receiving a paste operation instruction issued by the user on the second device, recursively downloading all files and folders corresponding to the file list from the first device, and saving the downloaded content to a temporary directory of the second device; Step S13, setting the file list in the temporary directory as the X11 clipboard file list of the second device; Step S14: According to the paste operation instruction, all files and folders corresponding to the X11 clipboard file list are sent to the designated directory.

[0020] X11, also known as X Window System or X, is a network protocol and window system for graphical user interfaces, widely used in Unix, Linux and other Unix-like operating systems. It provides users with basic functions for displaying graphical interfaces on the screen and interacting with them. X11 is a low-level graphics system that manages windows on the screen and interacts with user input devices (such as the mouse and keyboard).

[0021] It can be understood that the technical solution shown in this embodiment can obtain the copied file list when receiving the copy operation instruction issued by the user on the first device, and store the file list synchronously to the second device through the X11 clipboard mechanism; when receiving the paste operation instruction issued by the user on the second device, recursively download all files and folders corresponding to the file list from the first device and save them to the temporary directory of the second device; set the file list in the temporary directory as the X11 clipboard file list of the second device; according to the paste operation instruction, send all files and folders corresponding to the X11 clipboard file list to the specified directory. It can be understood that the technical solution provided by this embodiment can realize the efficient synchronization and paste operation of file lists between multiple devices. Users only need to copy and paste operations to complete file transfer, which is in line with user operation habits.

[0022] The technical solution proposed in this embodiment is based on the file synchronization function implemented by the clipboard of the X11 desktop environment, aiming to realize efficient synchronization and paste operations of file lists between multiple devices. Its basic principles include real-time synchronization of file lists, recursive download of files, and seamless integration of clipboard paste functions, which is suitable for file management and multi-device file transfer in Linux environment.

[0023] In specific practice, in step S11, when the user performs a "copy" operation on one device (eg, the first device), the technical solution of this embodiment synchronizes the copied file list to another device (the second device) through the clipboard mechanism (Selection) of X11.

[0024] It should be noted that obtaining a list of files to be copied according to the copy operation instruction includes: obtaining a path of a file or folder to be copied according to the copy operation instruction; and converting the path of the file or folder to be copied into a file list in a preset format.

[0025] Through the above operation, the file list can include the paths of all files or folders to be copied and be saved in a preset format, which may be a text format or other format suitable for transmission.

[0026] It should be noted that synchronizing the file list to the second device through the X11 clipboard mechanism also includes: if there is a previously stored file list in the second device, deleting the previously stored file list, and then synchronizing and storing the file list to the second device through the X11 clipboard mechanism.

[0027] It is understandable that during the synchronization of the file list, the new file list will automatically overwrite the old list to ensure that the latest file information is always delivered. In order to ensure the real-time and accuracy of the file list, the new file list will overwrite the old list after each copy operation to avoid pasting outdated or incorrect file information. The overwrite mechanism ensures the uniqueness of the list and avoids data conflicts.

[0028] It should be noted that the method for transmitting files between multiple devices further includes: transmitting the file list from the first device to the second device via a network protocol.

[0029] In actual practice, when a file list is transmitted between two devices, data can be transmitted through a network protocol (such as SSH, WebSocket, etc.).

[0030] When executing step S12, when the user performs a "paste" operation on another device, the technical solution of this embodiment will automatically trigger the synchronous download of the file. The specific process is: according to the file list, all files and folders are recursively downloaded from the first device to the local (second device) temporary directory. Recursive download means that not only the files in the main folder will be downloaded, but also the subfolders and their contents in the folder will be downloaded to ensure that the entire file structure can be completely copied to the local.

[0031] It should be noted that recursively downloading all files and folders corresponding to the file list from the first device includes: recursively traversing the file system of the first device according to the file list, and downloading each file and folder corresponding to the file list level by level.

[0032] In practice, recursive downloading is to recursively traverse the file system of the remote device through the network protocol, and download each file and folder corresponding to the file list level by level.

[0033] After the files and folders are downloaded to a temporary directory, that directory becomes the current source of files to use when you paste them. The system ensures that the file structure is consistent, preventing files from being lost or paths from being mixed up.

[0034] When executing step S13, that is, after the recursive download of the file is completed, the file list in the temporary directory will be set as the X11 Selection file list of the current device. This means that when the user performs a "paste" operation locally, the X11 system will use the file in the local temporary directory as the paste content to complete the local storage of the file. The entire process is transparent to the user, and there is no need to manually operate the download step.

[0035] In another embodiment, it should be noted that the method for transferring files between multiple devices further includes: if the life cycle of the file or folder in the temporary directory reaches a preset time, deleting the file or folder; or, obtaining a deletion instruction sent by a user, and deleting the file or folder in the temporary directory according to the deletion instruction.

[0036] By automatically managing the life cycle of files or folders in the temporary directory according to preset time, or after the paste operation is completed, the temporary directory can be deleted or cleaned up according to user configuration to ensure that the content stored in the temporary directory does not occupy too much local storage resources.

[0037] This embodiment makes full use of the Selection mechanism in the X11 system, which is the core part of the X11 clipboard function. By setting the file list as the content of the X11 Selection, the user can complete the synchronization of the file list and file transfer through standard copy / paste operations. When the paste operation is triggered, the system automatically reads the file list from the Selection and performs subsequent download and paste operations based on the list.

[0038] It can be understood that this embodiment can synchronize file lists across devices, and is particularly suitable for scenarios where files are copied and transferred between multiple Linux devices. Users only need to copy the file list on any device, and can easily paste it on another device and download it locally. The entire file transfer process is transparent to the user, and the user does not need to know the details of the file download behind it. All operations are integrated into the copy / paste process of the X11 clipboard, which conforms to the user's intuitive operating habits. Files are transferred and downloaded only when they need to be pasted, and the temporary directory downloaded to the local is automatically managed and cleaned up, reducing the waste of local storage space.

[0039] Through the above technical solution, the present invention realizes efficient file synchronization and pasting operations based on the X11 desktop environment, and provides a convenient cross-device file transfer solution for Linux users.

[0040] According to a second aspect of an embodiment of the present invention, a system for transmitting files between multiple devices is provided, including: A file list synchronization module, configured to, when receiving a copy operation instruction issued by a user on a first device, obtain a copied file list according to the copy operation instruction, and synchronously store the file list to a second device through an X11 clipboard mechanism; A file download module, configured to recursively download all files and folders corresponding to the file list from the first device upon receiving a paste operation instruction issued by the user on the second device, and save the downloaded content to a temporary directory of the second device; The file pasting module is used to set the file list in the temporary directory as the X11 clipboard file list of the second device; according to the paste operation instruction, all files and folders corresponding to the X11 clipboard file list are sent to the designated directory.

[0041] It can be understood that the technical solution shown in this embodiment can obtain the copied file list through the file list synchronization module when receiving the copy operation instruction issued by the user on the first device, and synchronize and store the file list to the second device through the X11 clipboard mechanism; when receiving the paste operation instruction issued by the user on the second device through the file download module, recursively download all files and folders corresponding to the file list from the first device and save them to the temporary directory of the second device; set the file list in the temporary directory as the X11 clipboard file list of the second device through the file paste module; according to the paste operation instruction, send all files and folders corresponding to the X11 clipboard file list to the specified directory. It can be understood that the technical solution provided by this embodiment can realize efficient synchronization and paste operations of file lists between multiple devices. Users only need to copy and paste operations to complete file transfer, which is in line with user operation habits.

[0042] According to a third aspect of an embodiment of the present invention, a multi-device file transmission device is provided, including: A main controller, and a memory connected to the main controller; a memory in which program instructions are stored; The main controller is used to execute program instructions stored in the memory to perform any of the above methods.

[0043] It can be understood that the same or similar parts of the above embodiments can be referenced to each other, and the contents not described in detail in some embodiments can refer to the same or similar contents in other embodiments.

[0044] It should be noted that, in the description of the present invention, the terms "first", "second", etc. are only used for descriptive purposes and cannot be understood as indicating or implying relative importance. In addition, in the description of the present invention, unless otherwise specified, the meaning of "plurality" refers to at least two.

[0045] Any process or method description in a flowchart or otherwise described herein may be understood to represent a module, segment or portion of code that includes one or more executable instructions for implementing the steps of a specific logical function or process, and the scope of the preferred embodiments of the present invention includes alternative implementations in which functions may not be performed in the order shown or discussed, including performing functions in a substantially simultaneous manner or in the reverse order depending on the functions involved, which should be understood by those skilled in the art to which the embodiments of the present invention belong.

[0046] It should be understood that the various parts of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, multiple steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.

[0047] A person skilled in the art may understand that all or part of the steps in the method for implementing the above-mentioned embodiment may be completed by instructing related hardware through a program, and the program may be stored in a computer-readable storage medium, which, when executed, includes one or a combination of the steps of the method embodiment.

[0048] In addition, each functional unit in each embodiment of the present invention may be integrated into a processing module, or each unit may exist physically separately, or two or more units may be integrated into one module. The above-mentioned integrated module may be implemented in the form of hardware or in the form of a software functional module. If the integrated module is implemented in the form of a software functional module and sold or used as an independent product, it may also be stored in a computer-readable storage medium.

[0049] The storage medium mentioned above can be a read-only memory, a magnetic disk or an optical disk, etc.

[0050] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "examples", "specific examples", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner.

[0051] Although the embodiments of the present invention have been shown and described above, it is to be understood that the above embodiments are exemplary and are not to be construed as limitations of the present invention. A person skilled in the art may change, modify, replace and vary the above embodiments within the scope of the present invention.

Claims

1. A method for transferring files between multiple devices, characterized in that: include: When receiving a copy operation instruction issued by the user on the first device, obtaining a list of files to be copied according to the copy operation instruction, and synchronously storing the list of files to the second device through the X11 clipboard mechanism; When receiving a paste operation instruction issued by the user on the second device, recursively downloading all files and folders corresponding to the file list from the first device, and saving the downloaded content to a temporary directory of the second device; Set the file list in the temporary directory as the X11 clipboard file list of the second device; According to the paste operation instructions, all files and folders corresponding to the X11 clipboard file list are sent to the specified directory.

2. The method for transferring files between multiple devices according to claim 1, characterized in that: Synchronizing the file list to the second device via the X11 clipboard mechanism, further comprising: If the previously stored file list exists in the second device, the previously stored file list is deleted, and then the file list is synchronously stored in the second device through the X11 clipboard mechanism.

3. The method for transferring files between multiple devices according to claim 1, characterized in that: Obtaining a list of files to be copied according to the copy operation instruction includes: Obtaining the path of the file or folder to be copied according to the copy operation instruction; The path of the file or folder to be copied is converted into a file list in a preset format.

4. The method for transferring files between multiple devices according to claim 1, characterized in that: Also includes: The file list is transmitted from the first device to the second device via a network protocol.

5. The method for transferring files between multiple devices according to claim 1, characterized in that: Recursively downloading all files and folders corresponding to the file list from the first device, including: According to the file list, the file system of the first device is recursively traversed, and each file and folder corresponding to the file list is downloaded level by level.

6. The method for transferring files between multiple devices according to claim 1, characterized in that: Also includes: If the life cycle of the file or folder in the temporary directory reaches a preset time, the file or folder is deleted; or, A deletion instruction sent by a user is obtained, and files or folders in the temporary directory are deleted according to the deletion instruction.

7. A file transfer system between multiple devices, characterized in that: include: A file list synchronization module, configured to, when receiving a copy operation instruction issued by a user on a first device, obtain a copied file list according to the copy operation instruction, and synchronously store the file list to a second device through an X11 clipboard mechanism; A file download module, configured to recursively download all files and folders corresponding to the file list from the first device upon receiving a paste operation instruction issued by the user on the second device, and save the downloaded content to a temporary directory of the second device; The file pasting module is used to set the file list in the temporary directory as the X11 clipboard file list of the second device; according to the paste operation instruction, all files and folders corresponding to the X11 clipboard file list are sent to the designated directory.

8. A file transfer device between multiple devices, characterized in that: include: A main controller, and a memory connected to the main controller; a memory in which program instructions are stored; The main controller is used to execute program instructions stored in the memory and execute the method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Cross-device file processing method, client sides and server

    CN103618795A

  • Cloud desktop file copying method, device and equipment

    CN114546676A

  • Clipboard data security isolation method based on linux or credential terminal environment

    CN117009957A

  • Remote file rapid positioning access method and equipment based on path pasting function

    CN118312256A

  • File copy and paste between local and remote system in virtual desktops via clipboard redirection

    US20230251884A1