Document positioning method and device
By receiving and processing the target user identification, obtaining and sending location information, automatic document positioning between terminals is realized, which solves the inefficiency problem caused by manual communication in the existing technology, and improves the efficiency of document positioning and the real-time nature of user collaboration.
Patent Information
- Application Number
- CN201910660989.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2019-07-22
- Publication Date
- 2024-09-06
- Estimated Expiration
- 2039-07-22
AI Technical Summary
In the existing technology, manual communication between terminals is required to locate the document location, which is inefficient and requires communication between the target terminal and other terminals, resulting in a cumbersome positioning process.
By receiving the positioning request sent by the first terminal, the location information of the target user is obtained according to the target user identification, and is sent to the first terminal so that it can automatically locate the target document. The method includes determining the terminal corresponding to the target user, querying cursor information or identifying the current display content to obtain location information.
It realizes automatic positioning of documents, improves positioning efficiency, reduces communication steps between users, protects user privacy, and improves the real-time nature of multi-user collaboration and supervision.
Smart Images

Figure CN112256820B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of network application technology, and in particular to a document positioning method and device. Background Art
[0002] In some scenarios, multiple terminals need to process the same document at the same time. For example, when editing a document of a large project, in order to increase the processing speed, the document will be distributed to various terminals, and each terminal will edit the part it is responsible for.
[0003] In the above process, sometimes it is necessary to communicate between terminals or monitor the working process of the terminal. At this time, it is necessary to determine the location of the document currently edited by the terminal.
[0004] Currently, other communication methods are usually required, whereby the target terminal notifies other terminals of the location of the document being edited, and then other terminals can locate the document at the location of the document being edited by the target terminal.
[0005] However, the above method requires communication between the target terminal and other terminals, and also requires other terminals to manually locate the document to the location of the document being edited by the target terminal, which is inefficient. Summary of the invention
[0006] The purpose of the embodiment of the present invention is to provide a document positioning method and device to realize automatic positioning of documents and improve document positioning efficiency. The specific technical solution is as follows:
[0007] An embodiment of the present invention provides a document positioning method, which is applied to a server. The method includes:
[0008] Receiving a location request for a target document sent by a first terminal, wherein the location request carries a target user identifier of a target user;
[0009] Acquire location information of the target user according to the target user identifier, where the location information is used to indicate the location of the target user in the target document;
[0010] The location information is sent to the first terminal, so that the first terminal locates the target document according to the location information.
[0011] Optionally, acquiring the location information of the target user according to the target user identifier includes:
[0012] Determining a target terminal corresponding to the target user according to the target user identifier;
[0013] Send a location information acquisition request to the target terminal to acquire the location information of the target user.
[0014] Optionally, acquiring the location information of the target user according to the target user identifier includes:
[0015] According to the target user identifier, querying the cursor information of the target user in a database, wherein the user identifier and cursor information of each user are correspondingly stored in the database;
[0016] Based on the cursor information, the location information of the target user is determined, wherein the location information includes one or more of the following: the page number where the target user is located, the position of the target user's cursor in the target document, the position of the target user's cursor on the target terminal screen, and the cell where the target user is located.
[0017] Optionally, when the cursor information of the target user is not obtained, the method further includes:
[0018] The currently displayed content of the target terminal corresponding to the target user is identified to obtain a content identifier of the currently displayed content as the location information.
[0019] The embodiment of the present invention further provides a document positioning device, which is applied to a server, and the device includes:
[0020] A receiving module, configured to receive a location request for a target document sent by a first terminal, wherein the location request carries a target user identifier of a target user;
[0021] An acquisition module, used for acquiring the location information of the target user according to the target user identifier, wherein the location information is used for indicating the location of the target user in the target document;
[0022] The sending module is used to send the location information to the first terminal, so that the first terminal locates the target document according to the location information.
[0023] Optionally, the acquisition module is specifically used to:
[0024] Determining a target terminal corresponding to the target user according to the target user identifier;
[0025] Send a location information acquisition request to the target terminal to acquire the location information of the target user.
[0026] Optionally, the acquisition module is specifically used to:
[0027] According to the target user identifier, querying the cursor information of the target user in a database, wherein the user identifier and cursor information of each user are correspondingly stored in the database;
[0028] Based on the cursor information, the location information of the target user is determined, wherein the location information includes one or more of the following: the page number where the target user is located, the position of the target user's cursor in the target document, the position of the target user's cursor on the target terminal screen, and the cell where the target user is located.
[0029] Optionally, when the cursor information of the target user is not obtained, the device further includes:
[0030] The identification module is used to identify the current display content of the target terminal corresponding to the target user, and obtain the content identifier of the current display content as the location information.
[0031] An embodiment of the present invention further provides an electronic device, comprising a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus;
[0032] Memory, used to store computer programs;
[0033] The processor is used to implement any of the above-mentioned document positioning methods when executing the program stored in the memory.
[0034] An embodiment of the present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, any of the above-mentioned document positioning methods is implemented.
[0035] The document positioning method and device provided by the embodiment of the present invention firstly receives a positioning request for a target document sent by a first terminal, the positioning request carries a target user identifier of a target user, and then obtains the location information of the target user according to the target user identifier, the location information is used to indicate the location of the target user in the target document, and then sends the location information to the first terminal so that the first terminal can locate the target document according to the location information. In this way, the document can be automatically positioned and the efficiency of document positioning can be improved. Of course, any product or method implementing the present invention does not necessarily need to achieve all the advantages described above at the same time. BRIEF DESCRIPTION OF THE DRAWINGS
[0036] In order to more clearly illustrate the embodiments of the present invention 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 present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0037] Figure 1 A schematic diagram of a flow chart of a document positioning method provided by an embodiment of the present invention;
[0038] Figure 2 A schematic diagram of the structure of a document positioning device provided by an embodiment of the present invention;
[0039] Figure 3 A schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0040] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0041] Currently, other communication methods are usually required, whereby the target terminal notifies other terminals of the location of the document being edited, and then other terminals can locate the document at the location of the document being edited by the target terminal.
[0042] However, the above method requires communication between the target terminal and other terminals, and also requires other terminals to manually locate the document to the location of the document being edited by the target terminal, which is inefficient.
[0043] In order to solve the above technical problem, the present invention provides a document positioning method, which can be applied to a server.
[0044] The document positioning method provided by the embodiment of the present invention is generally described below. The document positioning method includes:
[0045] receiving a location request for a target document sent by the first terminal, wherein the location request carries a target user identifier of a target user;
[0046] According to the target user identifier, obtain the location information of the target user, where the location information is used to indicate the location of the target user in the target document;
[0047] The location information is sent to the first terminal so that the first terminal locates the target document according to the location information.
[0048] From the above, it can be seen that the document positioning method provided by the embodiment of the present invention obtains the location information of the target user according to the target user identifier in the positioning request, and can determine the current position of the target user in the target document, thereby locating the document of the first user, realizing automatic positioning of the document, and improving the efficiency of document positioning.
[0049] The document positioning method provided by the embodiment of the present invention is described in detail below through specific embodiments.
[0050] like Figure 1 FIG. 1 is a flow chart of a first document location method provided by an embodiment of the present invention, which is applied to a server and includes the following steps:
[0051] S101: receiving a location request for a target document sent by a first terminal, where the location request carries a target user identifier of a target user.
[0052] When the first user needs to locate the target document according to the position of the target user in the target document, a location request for the target document may be sent to the server. The location request includes the target user identifier, such as the target user's name, IP address, user number, etc.
[0053] For example, the first user can click a button on a preset page to open a list of all users who are currently browsing or editing the target document, then determine the target user in the list, obtain the target user identifier of the target user, and then generate and send a positioning request.
[0054] Alternatively, the first user may directly input relevant information of the target user, such as the user name, IP address and other information of the target user, so that the first terminal generates and sends a positioning request according to the information input by the first user.
[0055] S102: Acquire the location information of the target user according to the target user identifier, where the location information is used to indicate the location of the target user in the target document.
[0056] Specifically, the server may determine the target terminal corresponding to the target user according to the target user identifier, and then send a location information acquisition request to the target terminal to acquire the location information of the target user.
[0057] In one case, the location information acquisition request may carry the user ID of the first user, so that the target user can determine whether to allow the first user to locate the location of the target user in the target document based on the user ID of the first user. If allowed, the target terminal can feedback the location information of the target user in the target document to the server; if not allowed, the target terminal will not feedback the location information of the target user in the target document to the server.
[0058] In this way, the risk of information leakage between users can be reduced, and user privacy and information can be protected more securely.
[0059] Alternatively, each user's terminal may upload the user's position in the target document to the server in advance, and the server may store each user's user ID and location information in a database. After the server obtains the target user ID, the target user's location information may be queried in the database. There is no specific limitation.
[0060] In one case, different permissions can be set for different users in advance. In this way, after the server obtains the target user ID, it can first determine the permissions allowed to the first user based on the user ID of the first user, and then, based on the permissions of the first user, determine whether the location information of the target user is within the permission range of the first user. If the location information of the target user is within the permission range of the first user, the location information of the target user is queried in the database. If the location information of the target user is not within the permission range of the first user, an access denial prompt message is sent to the first terminal.
[0061] In one implementation, the server may obtain the cursor information of the target user according to the target user identifier, and then determine the location information of the target user according to the cursor information. The location information of the target user may include one or more of the following: the page number of the target user, the location of the cursor of the target user in the target document, the location of the cursor of the target user on the target terminal screen, the cell of the target user, etc.
[0062] It can be understood that in some cases, the target user does not select the target document, that is, there is no cursor information of the target user in the target document.
[0063] Then, in one implementation, when the cursor information of the target user is not obtained, the server can identify the current display content of the target terminal corresponding to the target user and obtain the content identifier of the current display content as the position information. For example, the content identifier can be a picture number, paragraph number, etc. in the target document.
[0064] Alternatively, in another implementation, when the cursor information of the target user is not obtained, the server can directly obtain the current display content of the target terminal corresponding to the target user, and perform feature recognition on the current display content to obtain feature information of the current display content as the location information of the target user. In addition, the current display content can be directly matched with each page in the target document, and the similarity between the current display content and each page in the target document can be calculated respectively, and then the page number of the page with the highest similarity can be used as the location information of the target user.
[0065] S103: Send the location information to the first terminal, so that the first terminal locates the target document according to the location information.
[0066] After receiving the location information, the first terminal may locate the target document according to the location information, that is, jump the page of the target document currently displayed on the first terminal to the page that is consistent with the page of the target document currently displayed on the target terminal.
[0067] For example, if the target user's page number, the target user's cursor position in the target document, the target user's cursor position on the target terminal screen, the target user's cell and other location information are obtained, then the target document can be located directly based on this location information.
[0068] If information such as picture numbers and paragraph numbers is obtained, then a query can be performed in the target document to determine the positions corresponding to the information such as picture numbers and paragraph numbers, and the target document can be located.
[0069] If only the current display content of the target terminal corresponding to the target user is obtained, then the current display content can be matched with each page in the target document, and the similarity between the current display content and each page in the target document can be calculated respectively, and then the target document can be located to the page with the highest similarity.
[0070] In one case, when the first terminal sends a location request for the target document, it can also send a document acquisition request for the target document. The server can forward the request to the target terminal, and then the target terminal returns the target document and the location information of the target user in the target document to the first terminal at the same time. In this way, the synchronization of the target documents opened by the first terminal and the target terminal is improved, and the supervision of the target user by the first user is more real-time.
[0071] As can be seen from the above, the document positioning method provided by the embodiment of the present invention can obtain the location information of the target user according to the target user identifier in the positioning request, and can determine the current position of the target user in the target document, thereby locating the document of the first user, realizing automatic positioning of the document, and improving the efficiency of document positioning. For example, when multiple users are editing the target document at the same time, the first user can quickly know the location of the document being edited by other users, which can achieve more effective division of labor and more convenient supervision. When multiple users communicate remotely, they can actively locate the content being narrated by the target user who is currently speaking, making communication more efficient.
[0072] like Figure 2 As shown, an embodiment of the present invention further provides a document positioning device, which is applied to a server, and the device includes:
[0073] The receiving module 201 is used to receive a location request for a target document sent by a first terminal, where the location request carries a target user identifier of a target user;
[0074] An acquisition module 202 is used to acquire the location information of the target user according to the target user identifier, where the location information is used to indicate the location of the target user in the target document;
[0075] The sending module 203 is used to send the location information to the first terminal, so that the first terminal can locate the target document according to the location information.
[0076] In one implementation, the acquisition module 202 is specifically configured to:
[0077] Determine the target terminal corresponding to the target user according to the target user identifier;
[0078] Send a location information acquisition request to the target terminal to obtain the location information of the target user.
[0079] In one implementation, the acquisition module 202 is specifically configured to:
[0080] According to the target user ID, the cursor information of the target user is searched in the database, and the user ID and cursor information of each user are correspondingly stored in the database;
[0081] The location information of the target user is determined based on the cursor information, wherein the location information includes one or more of the following: the page number where the target user is located, the location of the target user's cursor in the target document, the location of the target user's cursor on the target terminal screen, and the cell where the target user is located.
[0082] In one implementation, when the cursor information of the target user is not obtained, the device further includes:
[0083] The identification module (not shown in the figure) is used to identify the current display content of the target terminal corresponding to the target user, and obtain the content identifier of the current display content as the location information.
[0084] As can be seen from the above, the document positioning device provided by the embodiment of the present invention can obtain the location information of the target user according to the target user identifier in the positioning request, and can determine the current location of the target user in the target document, thereby locating the document of the first user, realizing automatic positioning of the document, and improving the efficiency of document positioning. For example, when multiple users are editing the target document at the same time, the first user can quickly know the location of the document being edited by other users, which can achieve more effective division of labor and more convenient supervision. When multiple users communicate remotely, they can actively locate the content being narrated by the target user who is currently speaking, making communication more efficient.
[0085] The embodiment of the present invention further provides an electronic device, such as Figure 3 As shown, it includes a processor 301, a communication interface 302, a memory 303 and a communication bus 304, wherein the processor 301, the communication interface 302, and the memory 303 communicate with each other through the communication bus 304.
[0086] Memory 303, used for storing computer programs;
[0087] The processor 301 is used to execute the program stored in the memory 303 to implement the following steps:
[0088] receiving a location request for a target document sent by the first terminal, wherein the location request carries a target user identifier of a target user;
[0089] According to the target user identifier, obtain the location information of the target user, where the location information is used to indicate the location of the target user in the target document;
[0090] The location information is sent to the first terminal so that the first terminal locates the target document according to the location information.
[0091] The communication bus mentioned in the above electronic device can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The communication bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus.
[0092] The communication interface is used for communication between the above electronic device and other devices.
[0093] The memory may include a random access memory (RAM) or a non-volatile memory (NVM), such as at least one disk memory. Optionally, the memory may also be at least one storage device located away from the aforementioned processor.
[0094] The above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
[0095] From the above, it can be seen that the electronic device provided by the embodiment of the present invention can obtain the location information of the target user according to the target user identifier in the positioning request, and can determine the current position of the target user in the target document, thereby locating the document of the first user, realizing automatic positioning of the document, and improving the efficiency of document positioning.
[0096] In another embodiment of the present invention, a computer-readable storage medium is provided. The computer-readable storage medium stores instructions. When the instructions are executed on a computer, the computer executes the document positioning method described in any one of the above embodiments.
[0097] In another embodiment of the present invention, a computer program product including instructions is provided. When the computer program product is run on a computer, the computer executes the document positioning method described in any one of the above embodiments.
[0098] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions may be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions may be transmitted from a website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital terminal line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center. The computer-readable storage medium may be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrated. The available medium may be a magnetic medium, (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid-state hard disk Solid State Disk (SSD)), etc.
[0099] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.
[0100] Each embodiment in this specification is described in a related manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the device embodiment, electronic device embodiment and storage medium embodiment, since they are basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0101] The above description is only a preferred embodiment of the present invention and is not intended to limit the protection scope of the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention are included in the protection scope of the present invention.
Claims
1. A document positioning method, characterized in that: Applied to a server, the method comprises: receiving a location request for a target document sent by a first terminal, wherein the location request carries a target user identifier of a target user, and the target user and a first user corresponding to the first terminal are different users; Acquire location information of the target user according to the target user identifier, where the location information is used to indicate the location of the target user in the target document; Sending the location information to the first terminal so that the first terminal locates the target document according to the location information; Wherein, acquiring the location information of the target user according to the target user identifier includes: Determining cursor information of the target user according to the target user identifier; Based on the cursor information, determine the location information of the target user, wherein the location information includes one or more of the following: the page number where the target user is located, the position of the target user's cursor in the target document, the position of the target user's cursor on the target terminal screen corresponding to the target user, and the cell where the target user is located.
2. The method according to claim 1, characterized in that The acquiring the location information of the target user according to the target user identifier includes: Determining a target terminal corresponding to the target user according to the target user identifier; Send a location information acquisition request to the target terminal to acquire the location information of the target user.
3. The method according to claim 1, characterized in that The acquiring the location information of the target user according to the target user identifier includes: According to the target user identifier, querying the cursor information of the target user in a database, wherein the user identifier and cursor information of each user are correspondingly stored in the database; Based on the cursor information, the location information of the target user is determined, wherein the location information includes one or more of the following: the page number where the target user is located, the position of the target user's cursor in the target document, the position of the target user's cursor on the target terminal screen, and the cell where the target user is located.
4. The method according to claim 3, characterized in that In the case where the cursor information of the target user is not obtained, the method further includes: Identify the currently displayed content of the target terminal corresponding to the target user, and obtain the content identifier of the currently displayed content as the location information; Alternatively, the currently displayed content is directly matched with each page in the target document, the similarity between the currently displayed content and each page in the target document is calculated respectively, and the page number of the page with the highest similarity is used as the location information of the target user.
5. The method according to claim 1, characterized in that The positioning request is generated and sent to the server after the first terminal opens a list of all users who are currently browsing or editing the target document, determines the target user in the list, obtains the target user identifier of the target user, and sends the request to the server; Alternatively, the positioning request is generated by the first terminal according to input information of the target user and sent to the server.
6. A document positioning device, characterized in that: Applied to a server, the device comprises: A receiving module, configured to receive a location request for a target document sent by a first terminal, wherein the location request carries a target user identifier of a target user, and the target user and a first user corresponding to the first terminal are different users; An acquisition module, used for acquiring the location information of the target user according to the target user identifier, wherein the location information is used for indicating the location of the target user in the target document; A sending module, used for sending the location information to the first terminal, so that the first terminal locates the target document according to the location information; Among them, the acquisition module is specifically used to: determine the cursor information of the target user according to the target user identifier; determine the location information of the target user according to the cursor information, wherein the location information includes one or more of the following: the page number of the target user, the position of the cursor of the target user in the target document, the position of the cursor of the target user on the target terminal screen corresponding to the target user, and the cell where the target user is located.
7. The device according to claim 6, characterized in that The acquisition module is specifically used for: Determining a target terminal corresponding to the target user according to the target user identifier; Send a location information acquisition request to the target terminal to acquire the location information of the target user.
8. The device according to claim 6, characterized in that The acquisition module is specifically used for: According to the target user identifier, querying the cursor information of the target user in a database, wherein the user identifier and cursor information of each user are correspondingly stored in the database; Based on the cursor information, the location information of the target user is determined, wherein the location information includes one or more of the following: the page number where the target user is located, the position of the target user's cursor in the target document, the position of the target user's cursor on the target terminal screen, and the cell where the target user is located.
9. The device according to claim 8, characterized in that In the case where the cursor information of the target user is not obtained, the device further includes: An identification module is used to identify the currently displayed content of the target terminal corresponding to the target user, and obtain the content identifier of the currently displayed content as the location information; or to directly match the currently displayed content with each page in the target document, calculate the similarity between the currently displayed content and each page in the target document respectively, and use the page number of the page with the highest similarity as the location information of the target user.
10. The device according to claim 6, characterized in that The positioning request is generated and sent to the server after the first terminal opens a list of all users who are currently browsing or editing the target document, determines the target user in the list, obtains the target user identifier of the target user, and sends the request to the server; Alternatively, the positioning request is generated by the first terminal according to input information of the target user and sent to the server.
11. An electronic device, characterized in that: It includes a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus; Memory, used to store computer programs; A processor, for implementing the method steps described in any one of claims 1 to 5 when executing a program stored in a memory.
12. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method steps described in any one of claims 1 to 5 are implemented.
