CN113132216B - Instant messaging method and device, readable storage medium and electronic equipment - Google Patents
Instant messaging method and device, readable storage medium and electronic equipment Download PDFInfo
- Publication number
- CN113132216B CN113132216B CN202110424801.0A CN202110424801A CN113132216B CN 113132216 B CN113132216 B CN 113132216B CN 202110424801 A CN202110424801 A CN 202110424801A CN 113132216 B CN113132216 B CN 113132216B
- Authority
- CN
- China
- Prior art keywords
- message
- client
- content
- user
- server
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L51/00—User-to-user messaging in packet-switching networks, transmitted according to store-and-forward or real-time protocols, e.g. e-mail
- H04L51/04—Real-time or near real-time messaging, e.g. instant messaging [IM]
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/08—Network architectures or network communication protocols for network security for authentication of entities
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
- H04L67/1097—Protocols in which an application is distributed across nodes in the network for distributed storage of data in networks, e.g. transport arrangements for network file system [NFS], storage area networks [SAN] or network attached storage [NAS]
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Computer Hardware Design (AREA)
- Computer Security & Cryptography (AREA)
- Computing Systems (AREA)
- General Engineering & Computer Science (AREA)
- Information Transfer Between Computers (AREA)
Abstract
The embodiment of the invention provides an instant messaging method, an instant messaging device, a readable storage medium and electronic equipment. The method comprises the following steps: the instant message IM server responds to the editing content reporting message sent by the first IM client; editing the content report message includes: the method comprises the steps of logging in an identification ID of a first user of a first IM client, an ID of a first message window edited by the first user and first content which is not sent in the first message window; the IM server acquires the addresses of all IM clients logged in by the first user according to the ID of the first user; the IM server sends editing content synchronization messages to other IM clients except the first IM client which the first user logs in; editing the content synchronization message comprises: the ID and first content of the first message window such that: each IM client receiving the edit content synchronization message initializes a first message window and displays first content in the first message window. The embodiment of the invention improves the instant messaging efficiency.
Description
Technical Field
The present invention relates to the field of mobile communications technologies, and in particular, to an instant messaging method and apparatus, a readable storage medium, and an electronic device.
Background
With the development of mobile devices and communications, people use instant messaging tools to communicate more and more, and the time is longer and longer. At present, the instant messaging tool can be installed and used on different terminal devices so as to facilitate people to communicate at any time, and thus, one user can switch between different terminal devices and use the same instant messaging tool.
The existing instant messaging tool can synchronize the historical communication contents on different terminal devices. However, when the user is editing content on a certain terminal device and exits while still in an edited and unsent state, then the user needs to re-edit the content when logging in the instant messaging tool on another terminal device thereafter.
Disclosure of Invention
The embodiment of the invention provides an instant messaging method and device, a readable storage medium and electronic equipment, so as to improve instant messaging efficiency.
The technical scheme of the embodiment of the invention is realized as follows:
an instant messaging method, the method comprising:
the instant message IM server responds to the editing content reporting message sent by the first IM client;
the editing content report message comprises: the method comprises the steps of logging in an identification ID of a first user of a first IM client, an ID of a first message window edited by the first user and first content which is not sent in the first message window;
the IM server acquires the addresses of all IM clients logged in by the first user according to the ID of the first user;
the IM server sends editing content synchronization messages to other IM clients except the first IM client which the first user logs in;
the edit content synchronization message includes: the ID and first content of the first message window such that: each IM client receiving the edit content synchronization message initializes a first message window and displays first content in the first message window.
The IM server obtains the addresses of the IM clients logged in by the first user according to the ID of the first user, and the method comprises the following steps:
the IM server inquires an IM client list which is maintained by the IM server and is logged in by a first user;
the IM server reads the address of each IM client logged in by the first user from the list.
After the IM server responds to the edit content report message sent from the first IM client, the method further comprises:
the IM server searches the edit content corresponding to the ID of the first user and the ID of the first message window in a corresponding relation list of the user ID, the message window ID and the edit content maintained by the IM server, and if so, the searched edit content is covered by the first content; otherwise, establishing a corresponding relation among the ID of the first user, the ID of the first message window and the first content.
After the IM server sends the edit content synchronization message to each IM client except the first IM client logged in by the first user, the method further includes:
the IM server periodically polls a self-maintained list of IM clients logged in by a first user, and when a new IM client is added in the list, the IM server determines that the new IM client is added in the list:
searching a message window ID and editing content corresponding to the ID of a first user in a corresponding relation list of the user ID, the message window ID and the editing content maintained by the user ID and the editing content;
the IM server sends an edit content synchronization message to the new IM client, the message comprising: the searched message form ID and the editing content are such that: and initializing a message window corresponding to the message window ID in the message according to the received editing content synchronous message by the new IM client, and displaying the editing content in the message in the corresponding message window.
After the IM server sends the edit content synchronization message to each IM client except the first IM client logged in by the first user, the method further includes:
the IM server receives an online message sent by a second IM client, wherein the online message carries an ID of a first user logged in the second IM client;
the IM server adds the address of the second IM client into an IM client list which is maintained by the IM server and in which a first user logs in, and searches the message window ID and the editing content corresponding to the ID of the first user in a corresponding relation list of the user ID, the message window ID and the editing content which are maintained by the IM server;
the IM server sends an edit content synchronization message to the second IM client, the message comprising: the searched message form ID and the editing content are such that: and initializing a message window corresponding to the message window ID in the message according to the received editing content synchronous message by the second IM client, and displaying the editing content in the message in the corresponding message window.
After the IM server sends the edit content synchronization message to each IM client except the first IM client logged in by the first user, the method further includes:
the IM server receives a content sent message sent by a third IM client, wherein the message comprises: logging in the ID of the first user of the third IM client and the ID of the first message window where the sent content is located; the third IM client is any IM client logged in by the first user;
the IM server acquires the addresses of all IM clients logged in by a first user;
the IM server sends a content emptying message to each IM client except the third IM client which is logged in by the first user;
the content clear message includes: the ID of the first message window such that: each IM client receiving the content clear message clears the content in the first message window.
The editing content reporting message is as follows:
the first IM client sends out when detecting that the first content in the first message window is not executed with any operation in a preset time length.
The first content is as follows: text, or pictures, or audio, or files.
An instant messaging device, the device being located on an instant messaging IM server, the device comprising:
the message receiving module is configured to receive an edit content report message sent by the first IM client, where the edit content report message includes: the method comprises the steps of logging in an identification ID of a first user of a first IM client, an ID of a first message window edited by the first user and first content which is not sent in the first message window;
the content synchronization module is used for acquiring the address of each IM client logged in by the first user according to the ID of the first user in the editing content reporting message received by the message receiving module, and sending editing content synchronization messages to other IM clients except the first IM client logged in by the first user, wherein the editing content synchronization messages comprise: the ID and first content of the first message window such that: each IM client receiving the edit content synchronization message initializes a first message window and displays first content in the first message window.
A non-transitory computer readable storage medium storing instructions that, when executed by a processor, cause the processor to perform the steps of the instant messaging method of any of the above.
An electronic device comprising a non-transitory computer readable storage medium as described above, and the processor having access to the non-transitory computer readable storage medium.
In the embodiment of the invention, the IM client reports the content which is edited and not sent in the message window to the IM server, and the IM server synchronizes the content to other IM clients logged in by the same user, so that when the user switches between different IM clients, the user does not need to input the content which is not edited any more, and the instant messaging efficiency is improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings that are needed in the description of the embodiments will be briefly described below, it being obvious that the drawings in the following description are only some embodiments of the present invention, and that other drawings may be obtained according to these drawings without inventive effort to a person skilled in the art.
FIG. 1 is a flow chart of an instant messaging method according to an embodiment of the present invention;
fig. 2 is a flowchart of an instant messaging method according to another embodiment of the present invention;
fig. 3 is a schematic structural diagram of an instant messaging device according to an embodiment of the present invention;
fig. 4 is an exemplary structural schematic diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present invention, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
The terms "first," "second," "third," "fourth" and the like in the description and in the claims and in the above drawings, if any, are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments of the invention described herein may be implemented, for example, in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprise" and "have," as well as any variations thereof, are intended to cover a non-exclusive inclusion. For example, a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those elements but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
The technical scheme of the invention is described in detail below by specific examples. The following embodiments may be combined with each other, and some embodiments may not be repeated for the same or similar concepts or processes.
The embodiment of the invention provides an Instant messaging method, in which an IM (Instant Message) server responds to an edit content reporting Message sent by a first IM client, and the Message comprises: an ID (identification) of a first user logging in the first IM client, an ID of a first message window that the first user is editing, and first content that is not sent within the first message window; the IM server acquires the addresses of all IM clients logged in by the first user according to the ID of the first user; the IM server sends editing content synchronization information to other IM clients except the first IM client which the first user logs in, wherein the information comprises: the ID and first content of the first message window such that: each IM client receiving the edit content synchronization message initializes a first message window and displays first content in the first message window. Therefore, when the user switches between different IM clients, the user does not need to input the unedited content again, and the instant messaging efficiency is improved.
Fig. 1 is a flowchart of an instant messaging method according to an embodiment of the present invention, which specifically includes the following steps:
step 101: an IM (Instant Message) server responds to an edit content report Message sent from a first IM client, the Message comprising: an ID (identification) of a first user logging into the first IM client, an ID of a first message frame that the first user is editing, and first content that is not sent within the first message frame.
The first IM client is any IM client logged in by the first user.
The first content is all content that is not transmitted within the first message window.
The first content is: text, or pictures, or audio, or files, etc.
The editing content report message may be: the first IM client sends out when detecting that the first content in the first message window is not executed with any operation in a preset time length.
IM clients, i.e., clients of instant messaging tools. Each IM client is installed on a different terminal device, respectively. The first IM client is an IM client installed on a certain terminal device.
Step 102: and the IM server acquires the addresses of the IM clients logged in by the first user according to the ID of the first user.
Step 103: the IM server sends editing content synchronization information to other IM clients except the first IM client which the first user logs in, wherein the information comprises: the ID and first content of the first message window such that: each IM client receiving the edit content synchronization message initializes a first message window and displays first content in the first message window.
In the above embodiment, the IM client reports the content which is being edited and not sent in the message window to the IM server, and the IM server synchronizes the content to other IM clients logged in by the same user, so that when the user switches between different IM clients, the user does not need to re-input the content which is not edited, thereby improving the instant messaging efficiency.
In an optional embodiment, in step 102, the IM server obtains, according to the ID of the first user, the address of each IM client logged in by the first user, including: the IM server inquires a self-maintained list of the IM clients logged in by the first user, and reads the addresses of all the IM clients logged in by the first user from the list.
After detecting that a user logs in, the IM client side carries an ID of the user and an address of the IM client side in an online message and sends the online message to the IM server, and after receiving the online message, the IM server inquires whether an IM client side list logged in by the user is maintained according to the ID of the user in the message, if so, the address of the IM client side in the notification is directly added into the list; otherwise, establishing an IM client list logged in by the user, wherein the list is identified by the ID of the user, and adding the address of the IM client into the list.
In an optional embodiment, in step 101, after the IM server responds to the edit content report message sent from the first IM client, the method further includes: the IM server searches the edit content corresponding to the ID of the first user and the ID of the first message window in a corresponding relation list of the user ID, the message window ID and the edit content maintained by the IM server, and if so, the searched edit content is covered by the first content; otherwise, establishing a corresponding relation among the ID of the first user, the ID of the first message window and the first content.
In an optional embodiment, in step 103, after the IM server sends the edit content synchronization message to each IM client other than the first IM client logged in by the first user, the method further includes:
the IM server periodically polls a self-maintained list of IM clients logged in by a first user, and when a new IM client is added in the list, the IM server determines that the new IM client is added in the list: searching a message window ID and editing content corresponding to the ID of a first user in a corresponding relation list of the user ID, the message window ID and the editing content maintained by the user ID and the editing content; the IM server sends an edit content synchronization message to the new IM client, the message comprising: the searched message form ID and the editing content are such that: and initializing a message window corresponding to the message window ID in the message according to the received editing content synchronous message by the new IM client, and displaying the editing content in the message in the corresponding message window.
In the above embodiment, the IM server detects whether the first user logs in to the new IM client by periodically polling the IM client list that the first user maintains and synchronizes the content edited and not transmitted by the first user on other IM clients to the new IM client in time when the first user logs in to the new IM client, so that the first user does not need to repeatedly input the content on the new IM client, thereby improving the instant messaging efficiency.
In an optional embodiment, in step 103, after the IM server sends the edit content synchronization message to each IM client other than the first IM client logged in by the first user, the method further includes:
the IM server receives an online message sent by a second IM client, wherein the online message carries an ID of a first user logged in the second IM client; the IM server adds the address of the second IM client into an IM client list which is maintained by the IM server and in which a first user logs in, and searches the message window ID and the editing content corresponding to the ID of the first user in a corresponding relation list of the user ID, the message window ID and the editing content which are maintained by the IM server; the IM server sends an edit content synchronization message to the second IM client, the message comprising: the searched message form ID and the editing content are such that: and initializing a message window corresponding to the message window ID in the message according to the received editing content synchronous message by the second IM client, and displaying the editing content in the message in the corresponding message window.
In the above embodiment, the IM server knows that the first user logs in the second IM client newly through the online message sent by the IM client, and when the first user synchronizes the content edited and not sent by the first user on other IM clients to the second IM client, the first user does not need to repeatedly input the content on the second IM client, thereby improving the instant messaging efficiency.
In an optional embodiment, in step 103, after the IM server sends the edit content synchronization message to each IM client other than the first IM client logged in by the first user, the method further includes:
the IM server receives a content sent message sent by a third IM client, wherein the message comprises: logging in the ID of the first user of the third IM client and the ID of the first message window where the sent content is located; the IM server obtains the addresses of all IM clients logged in by the first user, and sends a content clearing message to all IM clients except the third IM client logged in by the first user, wherein the content clearing message comprises: the ID of the first message window such that: each IM client receiving the content clear message clears the content in the first message window. The third IM client is any IM client logged in by the first user, for example: either the first IM client or the second IM client, or any other IM client other than the first IM client and the second IM client.
In the above embodiment, when the content has been sent by an IM client, the IM server timely notifies the other IM clients logged in by the user to delete the content, thereby avoiding the same message from being repeatedly sent.
Fig. 2 is a flowchart of an instant messaging method according to another embodiment of the present invention, which specifically includes the following steps:
step 201: the first IM client detects that the first user is online, and then the ID of the first user and the address of the first IM client are carried in an online message and sent to the IM server; and the IM server receives the online message and adds the address of the first IM client into a self-maintained IM client list logged in by the first user.
Wherein the list of IM clients to which the first user is logged is identified by the ID of the first user.
Step 202: the first IM client detects that the first content in the first message window is not executed with any operation within a preset time length, and sends an edit content report message to the IM server, wherein the message comprises: the ID of the first user logging into the first IM client, the ID of the first message window the first user is editing, and the first content not sent within the first message window.
Step 203: the IM server inquires an IM client list which is maintained by the IM server and is logged in by the first user according to the ID of the first user, and reads the address of each IM client logged in by the first user from the list; meanwhile, the IM server searches the edit content corresponding to the ID of the first user and the ID of the first message window in a corresponding relation list of the user ID, the message window ID and the edit content maintained by the IM server, if so, the searched edit content is covered by the first content, otherwise, the corresponding relation among the ID of the first user, the ID of the first message window and the first content is established.
Step 204: the IM server sends editing content synchronization information to other IM clients except the first IM client according to the addresses of the IM clients logged in by the first user, wherein the information comprises: the ID of the first message frame and the first content.
Step 205: and each IM client except the first IM client which is logged in by the first user receives the editing content synchronization message, initializes the first message window according to the ID and the first content of the first message window in the message, and displays the first content in the first message window.
It should be noted that, if in step 203, the IM server finds that only the address of the first IM client is in the list of IM clients logged in by the first user, it does not need to execute step 204, and then it goes directly to step 206.
Step 206: the IM server receives an online message sent by a second IM client, wherein the online message carries an ID of a first user logged in the second IM client; the IM server adds the address of the second IM client into an IM client list which is maintained by the IM server and is logged in by the first user, and searches the message window ID and the editing content corresponding to the ID of the first user in a corresponding relation list of the user ID, the message window ID and the editing content which are maintained by the IM server, and sends an editing content synchronization message to the second IM client, wherein the message comprises: the searched message form ID and the editing content.
Step 207: the second IM client receives the editing content synchronous message, initializes the corresponding message window according to the message window ID and the editing content in the message, and displays the editing content in the corresponding message window.
Step 208: the IM server receives a content sent message sent by a third IM client, wherein the message comprises: logging in the ID of the first user of the third IM client and the ID of the first message window where the sent content is located; the IM server obtains the addresses of all IM clients logged in by the first user, and sends a content clearing message to all IM clients except the third IM client logged in by the first user, wherein the content clearing message comprises: the ID of the first message frame.
Step 209: and each IM client except the third IM client which is logged in by the first user receives the content clearing message, and the content in the first message window is cleared according to the ID of the first message window in the message.
Fig. 3 is a schematic structural diagram of an instant messaging device according to an embodiment of the present invention, where the instant messaging device is located on an IM server, and the instant messaging device mainly includes:
the message receiving module 31 is configured to receive an edit content report message sent from the first IM client, where the edit content report message includes: the ID of the first user logging into the first IM client, the ID of the first message window the first user is editing, and the first content not sent within the first message window.
The content synchronization module 32 is configured to obtain, according to the ID of the first user in the edit content report message received by the message receiving module 31, an address of each IM client logged in by the first user, and send an edit content synchronization message to each other IM client logged in by the first user except the first IM client, where the edit content synchronization message includes: the ID and first content of the first message window such that: each IM client receiving the edit content synchronization message initializes a first message window and displays first content in the first message window.
In an alternative embodiment, the content synchronization module 32 obtains the address of each IM client logged in by the first user, including: and inquiring a self-maintained IM client list of the first user login, and reading the address of each IM client of the first user login from the list.
In an alternative embodiment, the content synchronization module 32 is further configured to search, in a corresponding relationship list of the user ID, the message form ID, and the edit content maintained by the content synchronization module, for the edit content corresponding to the ID of the first user and the ID of the first message form, and if so, cover the searched edit content with the first content; otherwise, establishing a corresponding relation among the ID of the first user, the ID of the first message window and the first content.
In an alternative embodiment, after the content synchronization module 32 sends the edit content synchronization message to the other IM clients except the first IM client that the first user logs in, it is further configured to:
the method comprises the steps of periodically polling a self-maintained list of IM clients logged in by a first user, and when a new IM client is found to be added in the list, then: searching for a message form ID and edit content corresponding to the ID of a first user in a corresponding relation list of the user ID, the message form ID and the edit content maintained by the user ID, and sending an edit content synchronization message to the new IM client, wherein the message comprises: the searched message form ID and the editing content are such that: and initializing a message window corresponding to the message window ID in the message according to the received editing content synchronous message by the new IM client, and displaying the editing content in the message in the corresponding message window.
In an alternative embodiment, after the content synchronization module 32 sends the edit content synchronization message to the other IM clients except the first IM client that the first user logs in, it is further configured to:
receiving an online message sent by a second IM client, wherein the online message carries an ID of a first user logging in the second IM client, adding an address of the second IM client into an IM client list logged in by the first user maintained by the second IM client, searching a message window ID and editing content corresponding to the ID of the first user in a corresponding relation list of the user ID, the message window ID and the editing content maintained by the second IM client, and sending an editing content synchronization message to the second IM client, wherein the message comprises: the searched message form ID and the editing content are such that: and initializing a message window corresponding to the message window ID in the message according to the received editing content synchronous message by the second IM client, and displaying the editing content in the message in the corresponding message window.
In an alternative embodiment, after the content synchronization module 32 sends the edit content synchronization message to the other IM clients except the first IM client that the first user logs in, it is further configured to:
receiving a content sent message from a third IM client, the message comprising: logging in the ID of the first user of the third IM client and the ID of the first message window where the sent content is located; the third IM client is any IM client logged in by the first user; the method comprises the steps of obtaining addresses of all IM clients logged in by a first user, and sending a content clearing message to all IM clients logged in by the first user except a third IM client, wherein the content clearing message comprises: the ID of the first message window such that: each IM client receiving the content clear message clears the content in the first message window.
In an alternative embodiment, the edit content report message received by the message receiving module 31 is: the first IM client sends out when detecting that the first content in the first message window is not executed with any operation in a preset time length.
Embodiments also provide a computer readable storage medium storing instructions that when executed by a processor can perform the steps in the instant messaging method as described above. In practice, the computer readable medium may be comprised by or separate from the apparatus/device/system of the above embodiments, and may not be incorporated into the apparatus/device/system. Wherein the instructions stored in the computer readable storage medium, which when executed by the processor, perform the steps of the instant messaging method as described above.
According to embodiments disclosed herein, the computer-readable storage medium may be a non-volatile computer-readable storage medium, which may include, for example, but is not limited to: portable computer diskette, hard disk, random Access Memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), portable compact disc read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination of the foregoing, but are not intended to limit the scope of the protection herein. In the embodiments disclosed herein, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
As shown in fig. 4, the embodiment of the invention further provides an electronic device. As shown in fig. 4, a schematic structural diagram of an electronic device according to an embodiment of the present invention is shown, specifically:
the electronic device may include a processor 41 of one or more processing cores, a memory 42 of one or more computer-readable storage media, and a computer program stored on the memory and executable on the processor. The above-described instant communication method can be implemented when the program of the memory 42 is executed.
Specifically, in practical applications, the electronic device may further include a power supply 43, an input/output unit 44, and other components. Those skilled in the art will appreciate that the configuration of the electronic device shown in fig. 4 is not limiting of the electronic device and may include more or fewer components than shown, or may combine certain components, or may be arranged in different components. Wherein:
the processor 41 is a control center of the electronic device, connects various parts of the entire electronic device using various interfaces and lines, and performs various functions of a server and processes data by running or executing software programs and/or modules stored in the memory 42, and calling data stored in the memory 42, thereby performing overall monitoring of the electronic device.
The memory 42 may be used to store software programs and modules, i.e., the computer-readable storage media described above. The processor 41 executes various functional applications and data processing by running software programs and modules stored in the memory 42. The memory 42 may mainly include a storage program area that may store an operating system, application programs required for at least one function, and the like, and a storage data area; the storage data area may store data created according to the use of the server, etc. In addition, memory 42 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid-state storage device. Accordingly, the memory 42 may also include a memory controller to provide access to the memory 42 by the processor 41.
The electronic device further comprises a power supply 43 for supplying power to the various components, which may be logically connected to the processor 41 via a power management system, whereby the functions of managing charging, discharging, and power consumption are performed via the power management system. The power supply 43 may also include one or more of any of a direct current or alternating current power supply, a recharging system, a power failure detection circuit, a power converter or inverter, a power status indicator, and the like.
The electronic device may further comprise an input output unit 44, which input unit output 44 may be used to receive input numeric or character information and to generate keyboard, mouse, joystick, optical or trackball signal inputs in connection with user settings and function control. The input unit output 44 may also be used to display information entered by a user or provided to a user as well as various graphical user interfaces that may be composed of graphics, text, icons, video, and any combination thereof.
The flowcharts and block diagrams in the figures of the present application illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
Those skilled in the art will appreciate that the features recited in the various embodiments of the disclosure and/or the claims may be combined in various combinations and/or combinations, even if such combinations or combinations are not explicitly recited in the present application. In particular, the features recited in the various embodiments and/or claims of the present application may be combined in various combinations and/or combinations without departing from the spirit and teachings of the application, all of which are within the scope of the disclosure.
The principles and embodiments of the present invention have been described herein with reference to specific examples, which are intended to be included herein for purposes of illustration only and not to be limiting of the invention. It will be apparent to those skilled in the art that variations can be made in the present embodiments and in the scope of the application in accordance with the spirit and principles of the present invention, and any modifications, equivalent substitutions, improvements, etc. are intended to be included within the scope of the present application.
Claims (10)
1. An instant messaging method, comprising:
the instant message IM server responds to the editing content reporting message sent by the first IM client;
the editing content report message comprises: the method comprises the steps of logging in an identification ID of a first user of a first IM client, an ID of a first message window edited by the first user and first content which is not sent in the first message window;
the IM server acquires the addresses of all IM clients logged in by the first user according to the ID of the first user;
the IM server sends editing content synchronization messages to other IM clients except the first IM client which the first user logs in;
the edit content synchronization message includes: the ID and first content of the first message window such that: each IM client receiving the editing content synchronization message initializes a first message window and displays first content in the first message window;
after the IM server sends the edit content synchronization message to each IM client except the first IM client logged in by the first user, the method further includes:
the IM server receives an online message sent by a second IM client, wherein the online message carries an ID of a first user logged in the second IM client;
the IM server adds the address of the second IM client into an IM client list which is maintained by the IM server and in which a first user logs in, and searches the message window ID and the editing content corresponding to the ID of the first user in a corresponding relation list of the user ID, the message window ID and the editing content which are maintained by the IM server;
the IM server sends an edit content synchronization message to the second IM client, the message comprising: the searched message form ID and the editing content are such that: and initializing a message window corresponding to the message window ID in the message according to the received editing content synchronous message by the second IM client, and displaying the editing content in the message in the corresponding message window.
2. The method of claim 1 wherein the IM server obtaining the address of each IM client logged in by the first user based on the ID of the first user comprises:
the IM server inquires an IM client list which is maintained by the IM server and is logged in by a first user;
the IM server reads the address of each IM client logged in by the first user from the list.
3. The method of claim 1, wherein the IM server, after responding to the edit content report message from the first IM client, further comprises:
the IM server searches the edit content corresponding to the ID of the first user and the ID of the first message window in a corresponding relation list of the user ID, the message window ID and the edit content maintained by the IM server, and if so, the searched edit content is covered by the first content; otherwise, establishing a corresponding relation among the ID of the first user, the ID of the first message window and the first content.
4. The method of claim 3, wherein after the IM server sends the edit content synchronization message to each of the IM clients other than the first IM client to which the first user is logged in, further comprising:
the IM server periodically polls a self-maintained list of IM clients logged in by a first user, and when a new IM client is added in the list, the IM server determines that the new IM client is added in the list:
searching a message window ID and editing content corresponding to the ID of a first user in a corresponding relation list of the user ID, the message window ID and the editing content maintained by the user ID and the editing content;
the IM server sends an edit content synchronization message to the new IM client, the message comprising: the searched message form ID and the editing content are such that: and initializing a message window corresponding to the message window ID in the message according to the received editing content synchronous message by the new IM client, and displaying the editing content in the message in the corresponding message window.
5. The method of claim 1, wherein after the IM server sends the edit content synchronization message to each of the IM clients other than the first IM client to which the first user is logged in, further comprising:
the IM server receives a content sent message sent by a third IM client, wherein the message comprises: logging in the ID of the first user of the third IM client and the ID of the first message window where the sent content is located; the third IM client is any IM client logged in by the first user;
the IM server acquires the addresses of all IM clients logged in by a first user;
the IM server sends a content emptying message to each IM client except the third IM client which is logged in by the first user;
the content clear message includes: the ID of the first message window such that: each IM client receiving the content clear message clears the content in the first message window.
6. The method of claim 1, wherein the edit content report message is:
the first IM client sends out when detecting that the first content in the first message window is not executed with any operation in a preset time length.
7. The method of claim 1, wherein the first content is: text, or pictures, or audio, or files.
8. An instant messaging device, the device residing on an instant messaging IM server, the device comprising:
the message receiving module is configured to receive an edit content report message sent by the first IM client, where the edit content report message includes: the method comprises the steps of logging in an identification ID of a first user of a first IM client, an ID of a first message window edited by the first user and first content which is not sent in the first message window;
the content synchronization module is used for acquiring the address of each IM client logged in by the first user according to the ID of the first user in the editing content reporting message received by the message receiving module, and sending editing content synchronization messages to other IM clients except the first IM client logged in by the first user, wherein the editing content synchronization messages comprise: the ID and first content of the first message window such that: each IM client receiving the editing content synchronization message initializes a first message window and displays first content in the first message window;
after the content synchronization module sends the edit content synchronization message to the other IM clients except the first IM client logged in by the first user, the content synchronization module is further configured to:
receiving an online message sent by a second IM client, wherein the online message carries an ID of a first user logging in the second IM client; adding the address of the second IM client into an IM client list which is maintained by the second IM client and in which a first user logs in, and searching a message window ID and editing content corresponding to the ID of the first user in a corresponding relation list of the user ID, the message window ID and the editing content which are maintained by the second IM client; transmitting an edit content synchronization message to the second IM client, the message comprising: the searched message form ID and the editing content are such that: and initializing a message window corresponding to the message window ID in the message according to the received editing content synchronous message by the second IM client, and displaying the editing content in the message in the corresponding message window.
9. A non-transitory computer readable storage medium storing instructions which, when executed by a processor, cause the processor to perform the steps of the instant messaging method of any of claims 1 to 7.
10. An electronic device comprising the non-transitory computer-readable storage medium of claim 9, and the processor having access to the non-transitory computer-readable storage medium.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110424801.0A CN113132216B (en) | 2021-04-20 | 2021-04-20 | Instant messaging method and device, readable storage medium and electronic equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110424801.0A CN113132216B (en) | 2021-04-20 | 2021-04-20 | Instant messaging method and device, readable storage medium and electronic equipment |
Publications (2)
Publication Number | Publication Date |
---|---|
CN113132216A CN113132216A (en) | 2021-07-16 |
CN113132216B true CN113132216B (en) | 2023-06-27 |
Family
ID=76778014
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202110424801.0A Active CN113132216B (en) | 2021-04-20 | 2021-04-20 | Instant messaging method and device, readable storage medium and electronic equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN113132216B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN114124865A (en) * | 2021-10-27 | 2022-03-01 | 钉钉(中国)信息技术有限公司 | Message synchronization method and device |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104734936A (en) * | 2013-12-19 | 2015-06-24 | 中兴通讯股份有限公司 | Instant message processing method, device and system |
US10425477B2 (en) * | 2015-09-15 | 2019-09-24 | Microsoft Technology Licensing, Llc | Synchronizing file data between computer systems |
US10866963B2 (en) * | 2017-12-28 | 2020-12-15 | Dropbox, Inc. | File system authentication |
CN112667585B (en) * | 2019-11-19 | 2022-06-07 | 腾讯科技(深圳)有限公司 | Synchronous management method, device and equipment for online documents |
-
2021
- 2021-04-20 CN CN202110424801.0A patent/CN113132216B/en active Active
Also Published As
Publication number | Publication date |
---|---|
CN113132216A (en) | 2021-07-16 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109714230B (en) | Flow monitoring method and device and computing equipment | |
CN111800443B (en) | Data processing system and method, device and electronic equipment | |
CN103441861A (en) | Method and device for generating data records | |
CN111669717B (en) | Cloud mobile phone data sending method, computer device and storage medium | |
CN105718529A (en) | Message pushing method and device for application program on communication terminal | |
CN104967537A (en) | Alarm information pushing method and device | |
US9332406B2 (en) | Method, apparatus, and system for updating contact information | |
CN113132216B (en) | Instant messaging method and device, readable storage medium and electronic equipment | |
CN109446204B (en) | Data storage method and device for instant messaging, electronic equipment and medium | |
CN108280020A (en) | Monitoring method and device of computer equipment, terminal and computer storage medium | |
CN104168559A (en) | Method, device and system for updating address book | |
CN113468023A (en) | Monitoring method, monitoring device, monitoring medium and electronic equipment | |
CN110912805B (en) | Message reading state synchronization method, terminal, server and system | |
CN113434312A (en) | Data blood relationship processing method and device | |
CN113067769A (en) | Router restarting method, device, equipment and storage medium | |
CN112965799A (en) | Task state prompting method and device, electronic equipment and medium | |
CN101971562B (en) | Method, device and system for controlling automatic running process performance | |
CN114448775B (en) | Equipment fault information processing method and device, electronic equipment and storage medium | |
CN111162938A (en) | Data processing system and method | |
CN106357481B (en) | Power utilization safety management method and system | |
CN113886497A (en) | Bidirectional real-time data monitoring method and device | |
CN115801548A (en) | Communication control method, device, equipment and storage medium for daisy chain | |
CN113873018A (en) | Vehicle communication method, device, server and vehicle | |
CN103475574A (en) | Method and device used for sending messages | |
CN113810457A (en) | Method and device for reporting service access exception, readable storage medium and electronic equipment |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |