The present invention relates to the field of communications technologies, and in particular, to a content sharing method, terminal, server, and system.
At present, functions of a mobile phone become increasingly powerful, and a photo shooting function of a mobile phone also becomes increasingly powerful. However, storage space of a mobile phone is limited. Therefore, most of various mobile phone manufacturers provide a cloud server or a web disk for a user to store data such as a photo and an address book.
A Communication as a Service (CaaS) software development kit (SDK) is an application software development platform, and a telecommunication capability such as Voice over Internet Protocol VoIP, instant messaging, file sharing, picture sharing, or audio and video conferencing is open to the outside by using an application programming interface (API) interface. This solution is developed based on the Session Initiation Protocol (SIP). In a current picture sharing solution, after a user of a source terminal selects a local file, the source terminal invokes an API interface provided by an SDK to send the file. The file may be sent in two manners. In one manner, when a rich communication suite (RCS) server is configured in a store-and-forward mode, the local file is first sent to the RCS server, that is, an RCS server of an operator on a live network, and after the RCS server finishes receiving the local file, the RCS server sends the file to a receiver. In the other manner, when the RCS server is configured in a point-to-point mode, after a destination terminal receives a content sharing request and choose to accept the request, the file may be sent to the receiver by using the RCS server without waiting for the file to be completely sent to the RCS server.
In the foregoing technical solution, when the RCS server is configured in the store-and-forward mode, it is necessary to wait for shared content to be completely sent to the server, and then the server instructs a user to receive the shared content. In this way, time required from sending the shared content by a sender to receiving the shared content by a receiver is excessively long, thereby affecting user experience. When the RCS server is configured in the point-to-point mode, the server instructs the receiver to receive the file without waiting for the shared content to be completely sent by the sender, which reduces time when compared with time used in the store-and-forward mode. However, this process relies on network environments of two parties, and a relative slow network speed of either party affects total transfer time of a sharing process.
In view of the foregoing mentioned technical problems existing in the prior art, embodiments of the present invention provide a content sharing method, terminal, server, and system. In the embodiments of the present invention, after shared content is transferred between cloud servers, terminals respectively log in to their respective cloud servers, so that the shared content may be browsed and operated.
According to a first aspect, a content sharing method is provided. The method includes receiving, by a source terminal cloud server, a content sending command sent by a source terminal, where the content sending command carries an address of a destination terminal cloud server. The method also includes sending, by the source terminal cloud server, a connection request to the destination terminal cloud server according to the address of the destination terminal cloud server, where the connection request is used to request to establish a connection to the destination terminal cloud server. The method also includes sending, by the source terminal cloud server, shared content to the destination terminal cloud server after the connection is established.
With reference to the first aspect, in a first possible implementation manner, before the step of receiving, by a source terminal cloud server, a content sending command sent by a source terminal, the method further includes: obtaining, by the source terminal, the address of the destination terminal cloud server from a destination terminal.
With reference to the first possible implementation manner of the first aspect, before the step of receiving, by a source terminal cloud server, a content sending command sent by a source terminal, the method further includes: receiving, by the source terminal cloud server, an ID that is of the shared content and sent by the source terminal, obtaining a corresponding random verification code according to the ID of the shared content, returning the random verification code corresponding to the ID of the shared content to the source terminal, and determining, by the source terminal according to the ID of the shared content and the random verification code, whether the shared content is uploaded.
With reference to the first aspect or the first possible implementation manner of the first aspect, in a second possible implementation manner, the method further includes: operating, by the destination terminal, the shared content by using the destination terminal cloud server.
With reference to the first aspect, or the first possible implementation manner of the first aspect, or the second possible implementation manner of the first aspect, in a third possible implementation manner, the method further includes: receiving, by the source terminal cloud server, a login request sent by the source terminal, where the login request carries login verification information.
According to a second aspect, a content sharing method is provided. The method includes sending, by a source terminal, a request for obtaining an address of a destination terminal cloud server to a destination terminal, and receiving the address of the destination terminal cloud server returned by the destination terminal. The method also includes sending, by the source terminal, a content sending command to a source terminal cloud server, where the content sending command carries the address of the destination terminal cloud server. The method also includes sending, by the source terminal cloud server, a connection request to the destination terminal cloud server according to the address of the destination terminal cloud server. The method also includes sending, by the source terminal cloud server, shared content to the destination terminal cloud server after a connection is established.
With reference to the second aspect, in a first possible implementation manner of the second aspect, the method further includes: determining, by the source terminal, an ID of the shared content according to locally stored information, and sending the ID of the shared content to the source terminal cloud server; obtaining, by the source terminal cloud server according to the ID that is of the shared content and sent by the source terminal, a random verification code corresponding to the ID of the shared content, and returning the random verification code corresponding to the ID of the shared content to the source terminal; and verifying, by the source terminal according to the ID of the shared content and the received random verification code, whether the received random verification code matches a random verification code locally stored in the source terminal.
With reference to the second aspect or the first possible implementation manner of the second aspect, in a second possible implementation manner, the method further includes: if a connection result that includes an error code and is returned by the smartcard and received by the terminal is a connection failure, connecting to an official website of the smartcard by using a network, and querying information corresponding to the error code.
With reference to the second aspect, or the first possible implementation manner of the second aspect, or the second possible implementation manner of the second aspect, in a third possible implementation manner, the verifying, by the source terminal according to the ID of the shared content and the received random verification code, whether the received random verification code matches a locally stored random verification code specifically includes: if the received random verification code matches the random verification code locally stored in the source terminal, executing the step of sending, by the source terminal, a content sending command to a source terminal cloud server; or if the received random verification code does not match the random verification code locally stored in the source terminal, uploading, by the source terminal, the shared content to the source terminal cloud server.
With reference to the second aspect, or the first possible implementation manner of the second aspect, or the second possible implementation manner of the second aspect, or the third possible implementation manner of the second aspect, in a fourth possible implementation manner, the method further includes: sending, by the source terminal, a content sharing request to the destination terminal, and receiving a response of accepting content sharing returned by the destination terminal.
With reference to the second aspect, or the first possible implementation manner of the second aspect, or the second possible implementation manner of the second aspect, or the third possible implementation manner of the second aspect, or the fourth possible implementation manner of the second aspect, in a fifth possible implementation manner, the method further includes: operating, by the destination terminal, the shared content by using the destination terminal cloud server.
According to a third aspect, a content sharing terminal is provided. The terminal includes an interaction unit and a matching unit. The interaction unit sends a request for obtaining an address of a destination terminal cloud server to a destination terminal, and receives the address of the destination terminal cloud server sent by the destination terminal. The interaction unit sends an ID of shared content to a source terminal cloud server, and receives a random verification code that corresponds to the ID of the shared content and is returned by the source terminal cloud server. The matching unit determines, according to the ID of the shared content and the received random verification code, whether the shared content is uploaded to the source terminal cloud server. When determining that the shared content is uploaded to the source terminal cloud server, the matching unit instructs the interaction unit to send a content sending command to the source terminal cloud server. The interaction unit is further configured to send the content sending command to the source terminal cloud server. The content sending command carries the address of the destination terminal cloud server. The address of the destination terminal cloud server is used to make the source terminal cloud server send the shared content to the destination terminal cloud server.
With reference to the third aspect, in a first possible implementation manner, the terminal further includes a memory. The memory is configured to store related information about the shared content, and the related information about the shared content includes the ID of the shared content and a random verification code. The matching unit is further specifically configured to: search the memory for the locally stored random verification code according to the ID of the shared content, compare the locally stored random verification code with the received random verification code returned by the source terminal cloud server, and if the locally stored random verification code is consistent with the random verification code returned by the source terminal cloud server, determine that the shared content is uploaded to the source terminal cloud server, or if the locally stored random verification code is inconsistent with the random verification code returned by the source terminal cloud server, determine that the shared content is not uploaded to the source terminal cloud server.
With reference to the third aspect or the first possible implementation manner of the third aspect, in a second possible implementation manner, the memory stores login information of logging in to a cloud server by a user. The interaction unit logs in to the cloud server according to the login information.
According to a fourth aspect, a content sharing server is provided, where the server includes an interface unit and a processing unit. The interface unit receives a content sending command sent by a terminal, where the content sending command carries an address of a destination terminal cloud server. The processing unit parses the content sending command received by the interface unit, to obtain the address of the destination terminal cloud server, and instructs, according to the address of the destination terminal cloud server, the interaction unit to send a connection establishment request to the destination terminal cloud server. After the interaction unit establishes a connection to the destination terminal cloud server, the processing unit instructs the interaction unit to send shared content to the destination terminal cloud server. The interaction unit sends the connection establishment request to the destination terminal cloud server, establishes the connection to the destination terminal cloud server, and sends the shared content to the destination terminal cloud server.
With reference to the fourth aspect, in a first possible implementation manner, the server further includes a querying unit and a memory. The memory is configured to store related information about shared content. The related information about the shared content includes an ID of the shared content and a random verification code. The interaction unit receives the ID that is of the shared content and sent by the terminal. The querying unit queries the memory according to the received ID of the shared content to obtain the random verification code. The interaction unit sends the random verification code to the terminal.
With reference to the fourth aspect or the first possible implementation manner of the fourth aspect, in a second possible implementation manner, the processing unit records information about a progress and a status that are of transferring the shared content to the destination terminal cloud server by the interaction unit. The interaction unit feeds back, to the terminal, the information about the progress and the status that are of transferring the shared content to the destination terminal cloud server.
According to a fifth aspect, a content sharing system is provided, where the system includes a source terminal, a source terminal cloud server, a destination terminal, and a destination terminal cloud server. The source terminal sends a request for obtaining an address of the destination terminal cloud server to the destination terminal. The destination terminal returns the address of the destination terminal cloud server to the source terminal. The source terminal sends a content sending command to the source terminal cloud server, where the content sending command carries the address of the destination terminal cloud server. The source terminal cloud server sends a connection request to the destination terminal cloud server according to the address of the destination terminal cloud server. The destination terminal cloud server returns, to the source terminal cloud server, a response to the connection request. The source terminal cloud server sends shared content to the destination terminal cloud server after a connection is established.
With reference to the fifth aspect, in a first possible implementation manner, the source terminal determines an ID of the shared content according to locally stored information, and sends the ID of the shared content to the source terminal cloud server. The source terminal cloud server obtains, according to the ID that is of the shared content and sent by the source terminal, a random verification code corresponding to the ID of the shared content, and feeds back the random verification code to the source terminal. The source terminal determines, according to the ID of the shared content and the received random verification code, whether the shared content is uploaded to the source terminal cloud server.
With reference to the fifth aspect or the first possible implementation manner of the fifth aspect, in a second possible implementation manner, the source terminal obtains, according to the ID of the shared content, a random verification code locally stored in the source terminal, performs verification between the random verification code locally stored in the source terminal and the received verification code, and if the locally stored random verification code is consistent with the random verification code returned by the source terminal cloud server, determines that the shared content is uploaded to the source terminal cloud server, or if the locally stored random verification code is inconsistent with the random verification code returned by the source terminal cloud server, determines that the shared content is not uploaded to the source terminal cloud server.
With reference to the fifth aspect, or the first possible implementation manner of the fifth aspect, or the second possible implementation manner of the fifth aspect, in a third possible implementation manner, the destination terminal logs in to the destination terminal cloud server to operate the shared content.
With reference to the fifth aspect, or the first possible implementation manner of the fifth aspect, or the second possible implementation manner of the fifth aspect, or the third possible implementation manner of the fifth aspect, in a fourth possible implementation manner, the system further includes an RCS server, and the source terminal communicates with the destination terminal by using the RCS server.
According to a sixth aspect, a content sharing terminal is provided, where the terminal includes an interaction interface and a processor, and the interaction interface and the processor are connected through a bus. The interaction interface sends a request for obtaining an address of a destination terminal cloud server to a destination terminal, and receives the address of the destination terminal cloud server sent by the destination terminal. The interaction interface sends an ID of shared content to a source terminal cloud server, and receives a random verification code that corresponds to the ID of the shared content and is returned by the source terminal cloud server. When determining, according to the ID of the shared content and the received random verification code, that the shared content is uploaded to the source terminal cloud server, the processor instructs the interaction interface to send a content sending command to the source terminal cloud server. The interaction interface sends the content sending command to the source terminal cloud server, where the content sending command carries the address of the destination terminal cloud server, and the address of the destination terminal cloud server is used to make the source terminal cloud server send the shared content to the destination terminal cloud server.
With reference to the sixth aspect, in a first possible implementation manner, the terminal further includes a memory. The memory is configured to store related information about the shared content, and the related information about the shared content includes the ID of the shared content and a random verification code. The processor searches the memory for a locally stored random verification code according to the ID of the shared content, compares the locally stored random verification code with the received random verification code returned by the source terminal cloud server, and if the locally stored random verification code is consistent with the random verification code returned by the source terminal cloud server, determines that the shared content is uploaded to the source terminal cloud server, or if the locally stored random verification code is inconsistent with the random verification code returned by the source terminal cloud server, determines that the shared content is not uploaded to the source terminal cloud server.
According to a seventh aspect, a content sharing server is provided, where the server includes an interaction interface and a processor, and the interaction interface and the processor are connected through a bus. The interaction interface receives a content sending command sent by a terminal, where the content sending command carries an address of a destination terminal cloud server. The processor parses the content sending command received by the interaction interface, to obtain the address of the destination terminal cloud server, and instructs, according to the address of the destination terminal cloud server, the interaction interface to send a connection establishment request to the destination terminal cloud server. After the interaction interface establishes a connection to the destination terminal cloud server, the processor instructs the interaction interface to send shared content to the destination terminal cloud server. The interaction interface sends the connection establishment request to the destination terminal cloud server and establishes the connection to the destination terminal cloud server, and is further configured to send the shared content to the destination terminal cloud server.
With reference to the seventh aspect, in a first possible implementation manner, the server further includes a memory. The memory is configured to store related information about the shared content, and the related information about the shared content includes an ID of the shared content and a random verification code. The interaction interface receives the ID that is of the shared content and sent by the terminal. The processor queries the memory according to the received ID of the shared content to obtain the random verification code. The interaction interface sends the random verification code to the terminal.
With reference to the seventh aspect or the first possible implementation manner of the seventh aspect, in a second possible implementation manner, the processor records information about a progress and a status that are of transferring the shared content to the destination terminal cloud server by the interaction interface. The interaction interface feeds back, to the terminal, the information about the progress and the status that are of transferring the shared content to the destination terminal cloud server.
In the foregoing solutions provided in the embodiments of the present invention, after a source terminal and a destination terminal respectively log in to their respective cloud servers, verify their respective login information, and log in to their respective cloud servers, shared content may be browsed and operated. When the source terminal sends the shared content to the destination terminal, the source terminal needs only to instruct the source terminal cloud server to send the shared content to the destination terminal cloud server, and mutual verification between the source terminal cloud server and the destination terminal cloud server does not need to be performed. In the embodiments of the present invention, efficiency and a transfer speed of RCS content sharing are enhanced, and security of content sharing is improved.
To resolve a technical problem currently existing in a content sharing process, in the present invention, after shared content is transferred between cloud servers, terminals respectively log in to their respective cloud servers, so that the shared content may be browsed and operated.
To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the following clearly and completely describes the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Apparently, the described embodiments are some but not all of the embodiments of the present invention. All other embodiments obtained by persons of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention.
Referring to
In the embodiment of the present invention, the source terminal 10 may further send an address of the source terminal cloud server 20 to the destination terminal 40 by using the RCS server 30, so as to implement that the destination terminal 40 may conveniently and quickly share content to the source terminal 10.
In the embodiment of the present invention, before the source terminal 10 instructs the source terminal cloud server 20 to send the shared content to the destination terminal cloud server 50, the source terminal 10 may further determine an ID of the shared content according to locally stored information, and send the ID of the shared content to the source terminal cloud server 20; the source terminal cloud server 20 obtains a corresponding random verification code according to the ID that is of the shared content and sent by the source terminal 10, and feeds back the random verification code to the source terminal 10. The ID of the shared content may be a number of the shared content or the like. The shared content may be a file.
In the embodiment of the present invention, the source terminal 10 determines, according to the ID of the shared content and the random verification code, whether the shared content is uploaded to the source terminal cloud server. The source terminal 10 searches for a locally stored random verification code according to the ID of the shared content, and compares the locally stored random verification code with the received random verification code returned by the source terminal cloud server 20. If the locally stored random verification code is consistent with the random verification code returned by the source terminal cloud server, it indicates that the shared content is stored in the source terminal cloud server 20; or if the locally stored random verification code is inconsistent with the random verification code returned by the source terminal cloud server, it indicates that the shared content is not uploaded to the source terminal cloud server 20, and the source terminal 10 uploads the shared content to the source terminal cloud server 20. The source terminal server 20 feeds back, to the source terminal 10, information such as a progress and a status of transferring the shared content to the destination terminal cloud server 50 by the source terminal cloud server 20.
In the content sharing system provided in the embodiment of the present invention, content sharing is implemented by means of data interaction between cloud servers of users. Content sharing is performed by using the content sharing system provided in the embodiment of the present invention, so that a user may download, browse, or operate shared content by logging in to a cloud server of the user, thereby enhancing efficiency and a transfer speed of RCS content sharing, and improving security of content sharing.
In a content sharing system provided in another embodiment of the present invention, in an interaction process of terminals, the RCS server 30 may not be needed, that is, the source terminal 10 and the destination terminal 40 may directly exchange information. In a content sharing system shown in
As shown in
Step 201: The source terminal accesses the source terminal cloud server, and sends verification information of the source terminal to the source terminal cloud server, to request to access the source terminal cloud server.
In the embodiment of the present invention, the source terminal may perform, by using an SDK module in the source terminal, encryption on the verification information, such as an account password entered by a user, and send the encrypted verification information to the source terminal cloud server to perform login verification.
Step 202: After the source terminal cloud server performs verification on the verification information, if the verification is successful, login is successful, or if the verification fails, login fails. The source terminal cloud server feeds back a login result of the source terminal to the source terminal.
Step 203: The source terminal sends a request for obtaining an address of the destination terminal cloud server to the RCS server.
In the embodiment of the present invention, an address of the source terminal cloud server may be carried in the request for obtaining the address of the destination terminal cloud server sent by the source terminal, and the address of the source terminal cloud server is sent to the RCS server.
Step 204: The RCS server sends the request for obtaining the address of the destination terminal cloud server to the destination terminal.
In the embodiment of the present invention, when the request for obtaining the address of the destination terminal cloud server that is sent by the source terminal and received by the RCS server carries the address of the source terminal cloud server, the RCS server records the address, and adds the address of the source terminal cloud server into the request for obtaining the address of the destination terminal cloud server sent to the destination terminal.
Step 205 and step 206: The destination terminal sends the address of the destination terminal cloud server to the source terminal by using the RCS server.
Step 207: The source terminal sends a content sharing request to the RCS server.
In the embodiment of the present invention, a user may send the content sharing request to the RCS server by using the source terminal, where the content sharing request may include information about a file name, a type, a size, a thumbnail, and the like. The source terminal may send the content sharing request to the RCS server by using a SendFileRequest message, and the RCS server performs validity and security monitoring on to-be-shared content, and may further monitor whether a timeout occurs, or the like.
Step 208: The RCS server sends the content sharing request to the destination terminal.
Step 209: The destination terminal feeds back, to the RCS server, a response about whether to accept the content sharing request.
In the embodiment of the present invention, a user may choose to accept or reject the content sharing request by using the destination terminal, and the destination terminal feeds back, to the RCS server, the response of accepting or rejecting the content sharing request according to a selection result of the user.
Step 210: The RCS server returns, to the source terminal, the response that is about whether to accept the content sharing request and fed back by the destination terminal.
Step 211: The source terminal sends an ID of shared content to the source terminal cloud server.
In the embodiment of the present invention, the source terminal determines the ID of the shared content according to locally stored information, and sends the ID of the shared content to the source terminal cloud server. The ID of the shared content may be a number of the shared content or the like. The shared content may be a file.
Step 212: The source terminal cloud server obtains a corresponding random verification code according to the ID that is of the shared content and sent by the source terminal, and feeds back the ID of the shared content and the random verification code to the source terminal.
In the embodiment of the present invention, the source terminal determines, according to the ID of the shared content and the random verification code, whether the shared content is uploaded to the source terminal cloud server. The source terminal searches for a locally stored random verification code according to the ID of the shared content, and compares the locally stored random verification code with the received random verification code returned by the source terminal cloud server. If the locally stored random verification code is consistent with the random verification code returned by the source terminal cloud server, it indicates that the shared content is stored in the source terminal cloud server; or if the locally stored random verification code is inconsistent with the random verification code returned by the source terminal cloud server, it indicates that the shared content is not uploaded to the source terminal cloud server, and the source terminal uploads the shared content to the source terminal cloud server. When determining that the shared content is stored in the source terminal cloud server, the source terminal sends a content sending command to the source terminal cloud server.
In the embodiment of the present invention, the source terminal may add a setting of logging in to a cloud server into a submenu “account” in a local “setting” menu. When a user logs in to the cloud server, the user is prompted to select “Automatically upload content to the cloud server when WIFI is enabled”, so that content that needs to be shared may be uploaded to and stored in the cloud server in advance.
In the present invention, the source terminal may maintain locally stored information about shared content by using Table 1.
In Table 1, the number may indicate a number or an ID of shared content. The number may be automatically generated when the shared content is uploaded to the source terminal cloud server. The random verification code is a verification code that is used to verify whether there is a one-to-one correspondence between shared content in the source terminal cloud server and local shared content in the source terminal. The random verification code may be randomly generated by the source terminal when the shared content is uploaded to the source terminal cloud server. The random verification code may include a digit and/or Pinyin. The file path is used to indicate an absolute path for storing the shared content by the source terminal. The file path is unique in a same terminal. The sharing flag is used to indicate whether the shared content is uploaded to the source terminal cloud server. If the shared content is uploaded, the sharing flag may be marked as yes, or if the shared content is not uploaded, the sharing flag may be marked as no.
In the present invention, the source terminal cloud server may maintain locally stored information about shared content by using Table 2.
In Table 2, the number is carried when the source terminal uploads the shared content to the source terminal cloud server. The random verification code is carried when the source terminal uploads the shared content to the source terminal cloud server. The file path is used to indicate a path in which the shared content is stored in the source terminal cloud server.
In the embodiments of present invention, verification of a correspondence between the shared content in the source terminal and the content stored in the source terminal cloud server may be determined with reference to Table 1 and Table 2. For example, when content is being shared, the source terminal queries Table 1 according to a file path of the shared content, and obtains a number 001 of the shared content. The source terminal sends the found number 001 of the shared content to the source terminal cloud server. The source terminal cloud server searches Table 2 according to the received number 001 of the shared content, and obtains a corresponding random verification code Aaa123. The source terminal cloud server returns the number 001 and the random verification code Aaa123 that is found according to the number to the source terminal. The source terminal queries Table 1 according to the received number 001, and obtains a random verification code Aaa123. The source terminal compares the random verification code obtained by query with the received random verification code. The verification codes are consistent, and therefore it may be determined that the shared content is uploaded to the source terminal cloud server. It may be learned from Table 1 and Table 2 that, the random verification codes corresponding to the number 001 match each other, and therefore it is determined that the shared content with the number 001 is uploaded to the source terminal cloud server. The source terminal may mark a sharing flag corresponding to the shared content with the number 001 in Table 1 as “yes”. Random verification codes corresponding to a number 002 do not match, and therefore it is determined that shared content with the number 002 is not uploaded to the source terminal cloud server. The source terminal may mark a sharing flag corresponding to the shared content with the number 002 in Table 1 as “no”.
Step 213: When the source terminal determines that the shared content is stored in the source terminal cloud server, the source terminal sends a content sending command to the source terminal cloud server. The content sending command is used to instruct the source terminal cloud server to send the shared content to the destination terminal cloud server. The address of the destination terminal cloud server may be carried in the content sending command.
Step 214: The source terminal cloud server sends a connection request to the destination terminal cloud server, so as to implement that content transferring can be performed between the source terminal cloud server and the destination terminal cloud server.
In the embodiment of the present invention, a transmission mode of the shared content may be determined according to a status of a connection between the source terminal cloud server and the destination terminal cloud server. If the connection between the source terminal cloud server and the destination terminal cloud server is successful, the shared content may be directly sent from the source terminal cloud server to the destination terminal cloud server; or if the connection between the source terminal cloud server and the destination terminal cloud server fails, the shared content may be transferred by using the RCS server.
Step 215: The destination terminal cloud server returns, to the source terminal cloud server, a response to the connection request.
The response includes a feedback result of the connection request. The feedback result may be accepting the connection request and establishing a connection. Alternatively, the feedback result may be rejecting the connection request, and the process ends.
Step 216: The source terminal cloud server sends a feedback result to the source terminal.
Step 217: The source terminal sends a content transferring command to the source terminal cloud server.
Step 218: The source terminal cloud server sends the shared content to the destination terminal cloud server.
The source terminal cloud server sends the shared content to the destination terminal cloud server. Communication between the source terminal cloud server and the destination terminal cloud server may be implemented by using an agreed specific protocol. For example, the communication between the source terminal cloud server and the destination terminal cloud server may be implemented by using the SMTP (Simple Mail Transfer Protocol).
Step 219: The source terminal server feeds back, to the source terminal, information such as a progress and a status of transferring the shared content by the source terminal cloud server.
Step 220: The destination terminal logs in to the destination terminal cloud server to operate the shared content.
On the destination terminal, an operation on the shared content may be: downloading, browsing, or editing. After the destination terminal cloud server receives the shared content, the shared content may be simultaneously downloaded to the destination terminal.
During initialization, a related operation such as login verification or security verification is performed between the destination terminal and the destination terminal cloud server, and may not need to be operated again when the shared content is downloaded or browsed, thereby enhancing a speed and security of content sharing.
Step 221: The destination terminal cloud server sends operation information of the shared content to the destination terminal.
The operation information may include information such as a progress and a status of downloading the shared content. That is, the destination terminal cloud server may send, to the destination terminal, the information such as the progress and the status of downloading the shared content.
In the embodiment of the present invention, data interaction is performed between cloud servers of users, so that content sharing may be conveniently and quickly performed. For a photo, a video, or another file that is stored in a cloud server, the photo, the video, or the another file in the server may be sent to a cloud server of another user according to a sharing instruction of a user, and the another user may download the photo, the video, or the another file from the cloud server by using a terminal, so as to implement content sharing between users. In the embodiment of the present invention, time of content sharing may be greatly reduced, and user experience may be enhanced.
After a source terminal and a destination terminal respectively log in to their respective cloud servers, verify their respective login information, and log in to their respective cloud servers, shared content may be browsed and operated. When the source terminal sends the shared content to the destination terminal, the source terminal needs only to instruct the source terminal cloud server to send the shared content to the destination terminal cloud server, and mutual verification does not need to be performed between the source terminal cloud server and the destination terminal cloud server. In the embodiment of the present invention, efficiency and a transfer speed of RCS content sharing are enhanced, and security of content sharing is improved.
An embodiment of the present invention further provides a content sharing method. Referring to
Step 301: Receive a content sending command sent by the source terminal. The content sending command carries an address of a destination terminal cloud server. The content sending command is used to instruct to send shared content to the destination terminal cloud server.
Step 302: Send a connection request to the destination terminal cloud server according to the address of the destination terminal cloud server. The connection request is used to request to establish a connection to the destination terminal cloud server.
Step 303: Send the shared content to the destination terminal cloud server after the connection is established.
In the embodiment of the present invention, referring to
Step 304: The destination terminal operates the shared content by using the destination terminal cloud server.
In the embodiment of the present invention, on the destination terminal, an operation on the shared content may be: downloading, browsing, or editing. After step 304, the method may further include a step: The destination terminal cloud server sends operation information of the shared content to the destination terminal. The operation information includes information such as a downloading progress and a status.
In the embodiment of the present invention, referring to
Step 300: The source terminal determines, according to an ID of shared content and a random verification code, whether the shared content is uploaded to a source terminal cloud server.
The source terminal searches for a locally stored random verification code according to the ID of the shared content, and compares the locally stored random verification code with a received random verification code returned by the source terminal cloud server. If the locally stored random verification code is consistent with the random verification code returned by the source terminal cloud server, it indicates that the shared content is stored in the source terminal cloud server; or if the locally stored random verification code is inconsistent with the random verification code returned by the source terminal cloud server, it indicates that the shared content is not uploaded to the source terminal cloud server, and the source terminal uploads the shared content to the source terminal cloud server.
Before the step of determining, by the source terminal, according to an ID of shared content and a random verification code, whether the shared content is uploaded to a source terminal cloud server, the method may further include: determining, by the source terminal, the ID of the shared content according to locally stored information, and sending the ID of the shared content to the source terminal cloud server; and obtaining, by the source terminal cloud server, a corresponding random verification code according to the ID that is of the shared content and sent by the source terminal, and feeding back the ID of the shared content and the random verification code to the source terminal.
In the embodiment of the present invention, before step 301, the method may further include a step: The source terminal sends a request for obtaining the address of the destination terminal cloud server to an RCS server, and the destination terminal sends the address of the destination terminal cloud server to the source terminal by using the RCS server. In the embodiment of the present invention, the source terminal may directly interact with the destination terminal, or may interact with the destination terminal by using the RCS server.
In the embodiment of the present invention, the RCS server may be configured to implement information exchange between the source terminal and the destination terminal.
In the embodiment of the present invention, after step 303, the method may further include a step: The source terminal server feeds back, to the source terminal, information such as a progress and a status of transferring the shared content to the destination terminal cloud server by the source terminal cloud server.
In the foregoing embodiment of the present invention, after shared content is transferred between cloud servers, and after a source terminal and a destination terminal respectively log in to their respective cloud servers, verify their respective login information, and log in to their respective cloud servers, the shared content may be browsed and operated. In the embodiment of the present invention, efficiency and a transfer speed of RCS content sharing are enhanced, and security of content sharing is improved.
An embodiment of the present invention further provides a content sharing method. Referring to
Step 501: Obtain an address of a destination terminal cloud server.
In the embodiment of the present invention, a terminal may send a request for obtaining the address of the destination terminal cloud server to a destination terminal by using an RCS server, and the destination terminal sends the address of the destination terminal cloud server to the source terminal by using the RCS server.
Step 502: Determine, according to an ID of shared content, that the shared content is uploaded to a source terminal cloud server.
Step 503: Send a content sending command to the source terminal cloud server. The content sending command carries the address of the destination terminal cloud server. The content sending command is used to instruct to send the shared content to the destination terminal cloud server, so that an operation is performed on the shared content on the destination terminal by using the destination terminal cloud server. On the destination terminal, an operation on the shared content may be: downloading, browsing, or editing.
In the embodiment of the present invention, after step 503, the method may further include a step: The source terminal server feeds back, to the source terminal, information such as a progress and a status of transferring the shared content to the destination terminal cloud server by the source terminal cloud server.
In the embodiments of the present invention, step 502 specifically includes: determining, by the source terminal, the ID of the shared content according to locally stored information, and sending the ID of the shared content to the source terminal cloud server; obtaining, by the source terminal cloud server, a corresponding random verification code according to the ID that is of the shared content and sent by the source terminal, and feeding back the ID of the shared content and the random verification code to the source terminal; determining, by the source terminal according to the ID of the shared content and the random verification code, whether the shared content is uploaded to the source terminal cloud server; and searching, by the source terminal, for a locally stored random verification code according to the ID of the shared content, and comparing the locally stored random verification code with the received random verification code returned by the source terminal cloud server, where if the locally stored random verification code is consistent with the random verification code returned by the source terminal cloud server, it indicates that the shared content is stored in the source terminal cloud server; or if the locally stored random verification code is inconsistent with the random verification code returned by the source terminal cloud server, it indicates that the shared content is not uploaded to the source terminal cloud server, and the source terminal uploads the shared content to the source terminal cloud server.
In the embodiment of the present invention, for a specific process in which the terminal determines, according to the ID of the shared content, whether the shared content is uploaded to the source terminal cloud server, refer to a determining process with reference to Table 1 and Table 2 in the foregoing embodiment. The ID of the shared content may be a number or an identifier of the shared content, or the like.
In the foregoing embodiment of the present invention, whether shared content is uploaded to a cloud server is determined by using a terminal; in addition, after the shared content is transferred between cloud servers, and after a source terminal and a destination terminal respectively log in to their respective cloud servers, verify their respective login information, and log in to their respective cloud servers, the shared content may be browsed and operated. In the content sharing method provided in the embodiment of the present invention, efficiency and a transfer speed of RCS content sharing are enhanced, and convenience, quickness, and security of content sharing are improved.
An embodiment of the present invention further provides a terminal for content sharing. Referring to
The matching unit 602 is configured to determine, according to the ID of the shared content and the random verification code that are returned by the source terminal cloud server, whether the shared content is uploaded to the source terminal cloud server.
The terminal further includes a memory 603. The memory 603 is configured to store related information about the shared content. The related information about the shared content is information shown in Table 1.
In the embodiment of the present invention, referring to Table 1 and Table 2, the matching unit 602 searches the memory 603 for a locally stored random verification code according to the ID of the shared content, compares the locally stored random verification code with the received random verification code returned by the source terminal cloud server, and if the locally stored random verification code is consistent with the random verification code returned by the source terminal cloud server, determines that the shared content is uploaded to the source terminal cloud server, or if the locally stored random verification code is inconsistent with the random verification code returned by the source terminal cloud server, determines that the shared content is not uploaded to the source terminal cloud server.
When the matching unit 602 determines that the shared content is uploaded to the source terminal cloud server, the interaction unit 601 sends a content sending command to the source terminal cloud server. The content sending command is used to instruct the source terminal cloud server to send the shared content to the destination terminal cloud server. The address of the destination terminal cloud server may be carried in the content sending command. The interaction unit 601 is further configured to receive information such as a progress and a status of transferring the shared content that are fed back by the source terminal cloud server.
The memory 603 is further configured to store login information of logging in to a cloud server by a user, and the interaction unit 601 is configured to log in to the cloud server according to the login information.
In the embodiment of the present invention, the interaction unit 601 may be an SDK module. The SDK module may implement interaction between the terminal and another terminal or a server.
According to the terminal provided in the embodiment of the present invention, whether shared content is uploaded to a cloud server is determined; in addition, after the shared content is transferred between cloud servers, and after a source terminal and a destination terminal respectively log in to their respective cloud servers, verify their respective login information, and log in to their respective cloud servers, the shared content may be browsed and operated. In a content sharing method provided in an embodiment of the present invention, efficiency and a transfer speed of RCS content sharing are enhanced, and convenience, quickness, and security of content sharing are improved.
An embodiment of the present invention further provides a content sharing server. Referring to
In the embodiment of the present invention, the memory 704 is configured to store related information about the shared content. The related information about the shared content includes but is not limited to: a number of the shared content, a random verification code, and a file path. The number of the shared content and the random verification code may be received by the interaction unit 701 from the terminal. The file path is a specific path in which the shared content is stored.
The interaction unit 701 receives an ID that is of the shared content and sent by the terminal. The querying unit 703 queries the memory 704 according to the received ID of the shared content to obtain the random verification code. The interaction unit 701 sends the ID of the shared content and the random verification code to the terminal. The terminal may determine, according to the ID of the shared content and the random verification code, whether the shared content is uploaded to the server.
In the embodiment of the present invention, the processing unit 702 is further configured to record information such as a progress and a status of transferring the shared content to the destination terminal cloud server by the interaction unit 701. The interaction unit 701 is further configured to feed back, to the terminal, the information such as the progress and the status of transferring the shared content to the destination terminal cloud server.
In the foregoing embodiment of the present invention, a server interacts with a terminal and another cloud server by using an interaction unit; after shared content is transferred between cloud servers, and after a source terminal and a destination terminal respectively log in to their respective cloud servers, verify their respective login information, and log in to their respective cloud servers, the shared content may be browsed and operated. In the embodiment of the present invention, efficiency and a transfer speed of RCS content sharing are enhanced, and security of content sharing is improved.
An embodiment of the present invention further provides a content sharing terminal. Referring to
The interaction interface 801 may further send the request for obtaining the address of the destination terminal cloud server to the RCS server, and receive the address of the destination terminal cloud server sent by the destination terminal by using the RCS server.
The processor 802 is configured to determine, according to the ID of the shared content and the random verification code that are returned by the source terminal cloud server, whether the shared content is uploaded to the source terminal cloud server.
The memory 803 is configured to store related information about the shared content. The related information about the shared content is information shown in Table 1.
In the embodiment of the present invention, referring to Table 1 and Table 2, the processor 802 searches the memory 803 for a locally stored random verification code according to the ID of the shared content, compares the locally stored random verification code with the received random verification code returned by the source terminal cloud server, and if the locally stored random verification code is consistent with the random verification code returned by the source terminal cloud server, determines that the shared content is uploaded to the source terminal cloud server, or if the locally stored random verification code is inconsistent with the random verification code returned by the source terminal cloud server, determines that the shared content is not uploaded to the source terminal cloud server.
When determining that the shared content is uploaded to the source terminal cloud server, the processor 802 instructs the interaction interface 801 to send a content sending command to the source terminal cloud server. The content sending command is used to instruct the source terminal cloud server to send the shared content to the destination terminal cloud server. The address of the destination terminal cloud server may be carried in the content sending command. The interaction interface 801 is further configured to receive information such as a progress and a status of transferring the shared content that are fed back by the source terminal cloud server.
In the embodiment of the present invention, the interaction interface 801 may be an SDK module. The SDK module may implement interaction between the terminal and another terminal or a server.
According to the terminal provided in the embodiment of the present invention, whether shared content is uploaded to a cloud server is determined; in addition, after the shared content is transferred between cloud servers, and after a source terminal and a destination terminal respectively log in to their respective cloud servers, verify their respective login information, and log in to their respective cloud servers, the shared content may be browsed and operated. In a content sharing method provided in an embodiment of the present invention, efficiency and a transfer speed of RCS content sharing are enhanced, and convenience, quickness, and security of content sharing are improved.
An embodiment of the present invention further provides a content sharing server. Referring to
In the embodiment of the present invention, the memory 903 is configured to store related information about the shared content. The related information about the shared content includes but is not limited to: a number of the shared content, a random verification code, and a file path. The number of the shared content and the random verification code may be received by the interaction interface 901 and sent by the terminal. The file path is a specific path in which the shared content is stored.
The interaction interface 901 receives an ID that is of the shared content and sent by the terminal. The processor 902 queries the memory 903 according to the received ID of the shared content to obtain the random verification code. The interaction interface 901 sends the ID of the shared content and the random verification code to the terminal. The terminal may determine, according to the ID of the shared content and the random verification code, whether the shared content is uploaded to the server.
In the embodiment of the present invention, the processor 902 is further configured to record information such as a progress and a status of transferring the shared content to the destination terminal cloud server by the interaction interface 901. The interaction interface 901 is further configured to feed back, to the terminal, the information such as the progress and the status of transferring the shared content to the destination terminal cloud server.
In the foregoing embodiment of the present invention, a server interacts with a terminal and another cloud server by using an interaction interface; after shared content is transferred between cloud servers, and after a source terminal and a destination terminal respectively log in to their respective cloud servers, verify their respective login information, and log in to their respective cloud servers, the shared content may be browsed and operated. In the embodiment of the present invention, efficiency and a transfer speed of RCS content sharing are enhanced, and security of content sharing is improved.
An embodiment of the present invention further provides a content sharing method. Referring to
Step 1001: The source terminal sends a request for obtaining an address of the destination terminal cloud server to the destination terminal, and receives the address of the destination terminal cloud server returned by the destination terminal.
Step 1002: The source terminal sends a content sending command to the source terminal cloud server, where the content sending command carries the address of the destination terminal cloud server.
Step 1003: The source terminal cloud server sends a connection request to the destination terminal cloud server according to the address of the destination terminal cloud server.
Step 1004: The source terminal cloud server sends shared content to the destination terminal cloud server after a connection is established.
In the embodiment of the present invention, before step 1002, the method further includes steps: The source terminal determines an ID of the shared content according to locally stored information, and sends the ID of the shared content to the source terminal cloud server; the source terminal cloud server obtains a corresponding random verification code according to the ID that is of the shared content and sent by the source terminal, and feeds back the ID of the shared content and the random verification code to the source terminal; and the source terminal verifies, according to the ID of the shared content and the random verification code, whether corresponding shared content locally exists in the source terminal.
In the embodiment of the present invention, that the source terminal determines, according to the ID of the shared content and the random verification code, whether the shared content is uploaded to the source terminal cloud server specifically includes: If the corresponding shared content locally exists in the source terminal, it indicates that the shared content is uploaded to the source terminal cloud server, and the step that the source terminal sends a content sending command to the source terminal cloud server is executed; or if the corresponding shared content does not locally exist in the source terminal, it indicates that the shared content is not uploaded to the source terminal cloud server, and the source terminal uploads the shared content to the source terminal cloud server. For a specific verification process, refer to an implementation manner with reference to Table 1 and Table 2 in the foregoing embodiment.
In the embodiment of the present invention, before step 1002, the method further includes a step: The source terminal sends a content sharing request to the destination terminal, and receives a response of accepting content sharing returned by the destination terminal.
In the embodiment of the present invention, after step 1004, the method further includes: operating, by the destination terminal, the shared content by using the destination terminal cloud server.
In the embodiment of the present invention, information exchange may be performed between the source terminal and the destination terminal by using an RCS server.
In the embodiment of the present invention, after shared content is transferred between cloud servers, and after a source terminal and a destination terminal respectively log in to their respective cloud servers, verify their respective login information, and log in to their respective cloud servers, the shared content may be browsed and operated. In the embodiment of the present invention, efficiency and a transfer speed of RCS content sharing are enhanced, and security of content sharing is improved.
Persons skilled in the art should understand that the embodiments of the present invention may be provided as a method, a system, or a computer program product. Therefore, the present invention may use a form of hardware only embodiments, software only embodiments, or embodiments with a combination of software and hardware. Moreover, the present invention may use a form of a computer program product that is implemented on one or more computer-usable storage media (including but is not limited to a disk memory, a CD-ROM, an optical memory, and the like) that include computer-usable program code.
The present invention is described with reference to the flowcharts and/or block diagrams of the method, the device (system), and the computer program product according to the embodiments of the present invention. It should be understood that computer program instructions may be used to implement each process and/or each block in the flowcharts and/or the block diagrams and a combination of a process and/or a block in the flowcharts and/or the block diagrams. These computer program instructions may be provided for a general-purpose computer, a dedicated computer, an embedded processor, or a processor of any other programmable data processing device to generate a machine, so that the instructions executed by a computer or a processor of any other programmable data processing device generate an apparatus for implementing a specific function in one or more processes in the flowcharts and/or in one or more blocks in the block diagrams.
These computer program instructions may be stored in a computer readable memory that can instruct the computer or any other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory generate an artifact that includes an instruction apparatus. The instruction apparatus implements a specific function in one or more processes in the flowcharts and/or in one or more blocks in the block diagrams.
These computer program instructions may be loaded onto a computer or another programmable data processing device, so that a series of operations and steps are performed on the computer or the another programmable device, thereby generating computer-implemented processing. Therefore, the instructions executed on the computer or the another programmable device provide steps for implementing a specific function in one or more processes in the flowcharts and/or in one or more blocks in the block diagrams.
Although some preferred embodiments of the present invention have been described, persons skilled in the art can make changes and modifications to these embodiments once they learn the basic inventive concept. Therefore, the following claims are intended to be construed as to cover the preferred embodiments and all changes and modifications falling within the scope of the present invention.
Obviously, persons skilled in the art can make various modifications and variations to the embodiments of the present invention without departing from the spirit and scope of the embodiments of the present invention. The present invention is intended to cover these modifications and variations provided that they fall within the scope of protection defined by the following claims and their equivalent technologies.
This application is a continuation of International Application No. PCT/CN2014/095956, filed on Dec. 31, 2014, the disclosure of which is hereby incorporated by reference in its entirety.
Number | Name | Date | Kind |
---|---|---|---|
9137131 | Sarukkai | Sep 2015 | B1 |
9450784 | Schmidt | Sep 2016 | B2 |
20030033428 | Yadav | Feb 2003 | A1 |
20050050211 | Kaul | Mar 2005 | A1 |
20090307302 | Tennant | Dec 2009 | A1 |
20110022812 | van der Linden | Jan 2011 | A1 |
20120058721 | Fok | Mar 2012 | A1 |
20120278622 | Lesavich | Nov 2012 | A1 |
20130054634 | Chakraborty | Feb 2013 | A1 |
20130124617 | Lee | May 2013 | A1 |
20130235044 | Kaleta | Sep 2013 | A1 |
20130282920 | Zhang | Oct 2013 | A1 |
20140136893 | Xie | May 2014 | A1 |
20140181916 | Koo | Jun 2014 | A1 |
20140229457 | Sydell | Aug 2014 | A1 |
20140359047 | Lee | Dec 2014 | A1 |
20150067109 | Tang | Mar 2015 | A1 |
20150089028 | Zheng | Mar 2015 | A1 |
20150120843 | Cornwall | Apr 2015 | A1 |
20150195264 | Finlayson | Jul 2015 | A1 |
20150207847 | Kim | Jul 2015 | A1 |
20160191618 | Shi | Jun 2016 | A1 |
Number | Date | Country |
---|---|---|
102308290 | Jan 2012 | CN |
102651751 | Aug 2012 | CN |
103095553 | May 2013 | CN |
104243567 | Dec 2014 | CN |
Number | Date | Country | |
---|---|---|---|
20170302499 A1 | Oct 2017 | US |
Number | Date | Country | |
---|---|---|---|
Parent | PCT/CN2014/095956 | Dec 2014 | US |
Child | 15638054 | US |