Summary of the invention
It is an object of the invention to provide a kind of method sharing file based on geographical position, share simple to operate
And there is general applicability, promote Consumer's Experience.
Another object of the present invention is to provide a kind of system sharing file based on geographical position, share operation
Simple and there is general applicability, promote Consumer's Experience.
For achieving the above object, the technical scheme is that offer one shares file based on geographical position
Method, it comprises the steps:
(1), after transmitting terminal and receiving terminal obtain the instruction sharing file, geographical location information is obtained respectively concurrent
Send;
(2) received server-side relatively described transmitting terminal and the geographical location information of described receiving terminal, and compare
The transmission sending time and the geographical location information of described receiving terminal of the geographical location information of more described transmitting terminal
Time, if the most identical, then return the information of successful matching, otherwise, then return the information that pairing is failed;
(3) described transmitting terminal, described receiving terminal receive the information of successful matching respectively, and set up bluetooth and connect;
(4) file that the needs that user selects are shared by described transmitting terminal is sent to described reception by bluetooth
End.
It is preferred that also comprise the steps: before described step (1) to identify transmitting terminal, the user of receiving terminal
Identity;Wherein, described transmitting terminal, described receiving terminal identify user by login account or identification machine ID number
Identity.
It is preferred that described step (1) specifically includes following steps:
Transmitting terminal enters and sends interface and receiving terminal entrance reception interface;
Described transmitting terminal obtains the file that the needs of user's selection are shared;
Described transmitting terminal and described receiving terminal obtain the instruction sharing file respectively;
Described transmitting terminal and described receiving terminal obtain geographical location information respectively and send.
The generation it is preferred that described " sharing the instruction of file " can pass through to rock, touch or blow.
Compared with prior art, the method that the present invention shares file based on geographical position, when transmitting terminal and reception
After end obtains the instruction sharing file, obtain geographical location information respectively and send;Received server-side also compares
More described transmitting terminal and the geographical location information of described receiving terminal, and compare the geographical position letter of described transmitting terminal
The transmission time sending time and the geographical location information of described receiving terminal of breath, if the most identical, then return and join
To successful information, otherwise, then return the information that pairing is failed;Described transmitting terminal, described receiving terminal are respectively
Receive the information of successful matching, and set up bluetooth connection;Finally, the needs that user is selected by described transmitting terminal
The file shared is sent to described receiving terminal by bluetooth;Therefore, the operation sharing file is relatively simple, and
Without arranging special hardware, the method for sharing files has general applicability, thus is greatly promoted user's body
Test.
Accordingly, invention additionally discloses a kind of system sharing file based on geographical position, comprising:
Transmitting terminal, for obtaining its geographical location information according to the instruction sharing file and send, and according to returning
The file that the needs that user selects are shared by the information returned sends;
Receiving terminal, for obtaining its geographical location information according to the instruction sharing file and send, and according to returning
The information returned receives the file that the needs of described user selection are shared;
Server end, for receiving and compare the geographical location information of described transmitting terminal and described receiving terminal, and
Sending out of the time that the sends geographical location information with described receiving terminal of the geographical location information of the described transmitting terminal of comparison
Send the time, and return successful matching or failed information of matching according to comparative result.
Specifically, described transmitting terminal, described receiving terminal all include:
Acquisition device, for obtaining the instruction sharing file;
GPS locating module, is used for obtaining geographical location information;
First transmission/reception module, for sending described geographical location information, receiving joining of server end return
The information failed to success or pairing;
Bluetooth module, the file that the needs selected for sending or receive user are shared.
It is preferred that described " sharing the instruction of file " includes rocking, touch or blowing.
It is preferred that described acquisition device is gravity sensor or mike.
Specifically, described server end includes:
Second transmission/reception module, for receiving end/sending end, the geographical location information of receiving terminal transmission, transmission
Successful matching or failed information of matching;
Comparison module, for the geographical location information of relatively described transmitting terminal with described receiving terminal, and compares institute
When stating the transmission of the transmission time of the geographical location information of transmitting terminal and the geographical location information of described receiving terminal
Between.
Compared with prior art, owing to the present invention shares the system of file based on geographical position, it includes sending
End, receiving terminal and server end, wherein, transmitting terminal for obtaining its geographical position according to the instruction sharing file
Confidence ceases and sends, and receiving terminal is for obtaining its geographical location information according to the instruction sharing file and send;
Server end is for receiving and compare the geographical location information of described transmitting terminal and described receiving terminal, and compares institute
When stating the transmission of the transmission time of the geographical location information of transmitting terminal and the geographical location information of described receiving terminal
Between, and return successful matching or failed information of matching according to comparative result;Transmitting terminal is according to the pairing returned
The file that successfully needs that user selects are shared by information sends;Receiving terminal is according to the successful matching returned
Information receives the file that the needs of described user selection are shared;Therefore, the operation sharing file is relatively simple,
And without arranging special hardware, the method for sharing files has general applicability, thus is greatly promoted user
Experience.
Detailed description of the invention
With reference now to accompanying drawing, describing embodiments of the invention, element numbers similar in accompanying drawing represents similar unit
Part.The method and system sharing file based on geographical position that the present invention provides, share the simple to operate of file
And there is general applicability, thus there is preferable Consumer's Experience.
As it is shown in figure 1, Fig. 1 illustrates the main flow of a kind of method sharing file based on geographical position of the present invention
Cheng Tu.Specifically, the method comprises the steps:
Step S1: after transmitting terminal and receiving terminal obtain the instruction sharing file, obtain geographical location information respectively
And send;
Step S2: received server-side relatively described transmitting terminal and the geographical location information of described receiving terminal,
And compare the time that the sends geographical location information with described receiving terminal of the geographical location information of described transmitting terminal
The transmission time, if the most identical, then return the information of successful matching, otherwise, then return the information that pairing is failed;
Step S3: described transmitting terminal, described receiving terminal receive the information of successful matching respectively, and set up bluetooth
Connect;
Step S4: the file that the needs that user selects are shared by described transmitting terminal connects described in bluetooth transmission extremely
Receiving end.
As in figure 2 it is shown, Fig. 2 illustrates the present invention, a kind of to share the method one of file based on geographical position concrete
The flow chart of embodiment.Specifically, the method comprises the steps:
Step S01: transmitting terminal enters and sends interface and receiving terminal entrance reception interface;
Step S02: described transmitting terminal obtains the file that the needs of user's selection are shared;
Step S03: described transmitting terminal and described receiving terminal obtain the instruction sharing file respectively;Wherein, described
" sharing the instruction of file " can be by rocking, touch or blows generation;Such as, transmitting terminal, receiving terminal are together
Time rock, or mutually touch, or be respectively toward to transmitting terminal by user, receiving terminal is blown, thus produce and share
The instruction of file;
Step S04: described transmitting terminal and described receiving terminal obtain geographical location information respectively and send;Specifically,
Transmitting terminal obtains its geographical location information and is sent by this geographical location information to server end, and receiving terminal obtains
This geographical location information is also sent to server end by its geographical location information;
Step S05: transmitting terminal described in received server-side and the geographical location information of described receiving terminal;
Step S06: the geographical location information of the more described transmitting terminal of server end and described receiving terminal whether phase
With, if identical, then carry out step S07, otherwise, then return the information that pairing is failed;Specifically, if sending
The geographical location information of end is identical with the geographical location information of receiving terminal, then carry out next step, otherwise, then
Return the failed information of pairing to transmitting terminal and receiving terminal;
Step S07: the transmission time of the geographical location information of the more described transmitting terminal of server end and described reception
The transmission time of the geographical location information of end is the most identical, if identical, then carries out step S08, otherwise, then return
Return the information that pairing is failed;Specifically, if the geographical location information of transmitting terminal send time and receiving terminal
The transmission time of geographical location information is identical, then carry out step, otherwise, then return the letter that pairing is failed
Breath is to transmitting terminal and receiving terminal;
Step S08: server end returns the information of successful matching;
Step S09: described transmitting terminal, described receiving terminal receive the information of successful matching respectively, and set up bluetooth
Connect;
Step S10: the file that the needs that user selects are shared is sent by described transmitting terminal by bluetooth;
Step S11: the file that the needs that described receiving terminal is selected by user described in Bluetooth receptions are shared.
Specifically, also comprise the steps: before described step S01
Transmitting terminal, receiving terminal are separately turned on positioning function and Bluetooth function;
More specifically, " transmitting terminal, receiving terminal are separately turned on positioning function and Bluetooth function " before also include as
Lower step:
Identify transmitting terminal, the user identity of receiving terminal;Wherein, described transmitting terminal, receiving terminal are respectively by stepping on
Record account or identification machine ID number identify user identity, such as, be exclusively used in the account supporting cloud service by login
Number, or the IMEI number or serial number by machine identify user identity.
The method sharing file based on geographical position due to the present invention, shares literary composition when transmitting terminal and receiving terminal obtain
After the instruction of part, obtain geographical location information respectively and send;Received server-side relatively described transmitting terminal
With the geographical location information of described receiving terminal, and transmission time of the relatively geographical location information of described transmitting terminal
With the transmission time of the geographical location information of described receiving terminal, if the most identical, then return the information of successful matching,
Otherwise, then the information that pairing is failed is returned;Described transmitting terminal, described receiving terminal receive successful matching respectively
After information, set up bluetooth and connect;Finally, the file that the needs that user selects are shared is passed through by described transmitting terminal
Bluetooth sends to described receiving terminal;Therefore, the operation sharing file is relatively simple, and special without arranging
Hardware, the method for sharing files has general applicability, thus is greatly promoted Consumer's Experience.
As shown in Figure 3, Figure 4, the present invention is a kind of shares the system of file based on geographical position and includes:
Transmitting terminal 20, for obtaining its geographical location information according to the instruction sharing file and send, and according to
The information returned is set up bluetooth with receiving terminal 30 and is connected, then the file shared by the needs that user selects sends;
Receiving terminal 30, for obtaining its geographical location information according to the instruction sharing file and send, and according to
The information returned is set up bluetooth with transmitting terminal 20 and is connected, and the file that the needs receiving described user selection are shared;
Server end 10, for receiving and compare the geographical position of the most described transmitting terminal 20 and described receiving terminal 30
Information, and compare the ground sending time and described receiving terminal 30 of the geographical location information of described transmitting terminal 20
The transmission time of reason positional information, and return successful matching or failed information of matching according to comparative result.
With continued reference to shown in Fig. 4, Fig. 5, described transmitting terminal 20 includes that acquisition device 201, GPS position mould
Block the 202, first transmission/reception module 203 and bluetooth module 204.
Described acquisition device 201 is for obtaining the instruction sharing file;Wherein, described acquisition device 201 is
Gravity sensor or mike etc., described " sharing the instruction of file " can include rocking, touch or air blowing etc.;
Such as, after user rocks described transmitting terminal 20, touches transmitting terminal 20 or blow facing to transmitting terminal 20,
Gravity sensor senses and rocks, touches or after mike senses air blowing, i.e. obtains the instruction sharing file;
Described GPS locating module 202 is for obtaining the geographical location information of transmitting terminal 20;First sends/receives mould
Block 203 is for sending described geographical location information, receiving successful matching or pairing mistake that server end 10 returns
The information lost;The file that the needs that described bluetooth module 204 selects for sending or receive user are shared.
With continued reference to shown in Fig. 4, Fig. 5, described receiving terminal 30 includes that acquisition device 301, GPS position mould
Block the 302, first transmission/reception module 303 and bluetooth module 304.
Described acquisition device 301 is for obtaining the instruction sharing file;Wherein, described acquisition device 301 is
Gravity sensor or mike etc., described " sharing the instruction of file " can include rocking, touch or air blowing etc.;
Such as, after user rocks described receiving terminal 30, touches receiving terminal 30 or blow facing to receiving terminal 30,
Gravity sensor senses and rocks, touches or after mike senses air blowing, i.e. obtains the instruction sharing file;
Described GPS locating module 302 is for obtaining the geographical location information of receiving terminal 30;Described first sends/connects
Receive module 303 for sending described geographical location information, receiving the successful matching of server end 10 return or join
To failed information;The file that the needs that described bluetooth module 304 selects for sending or receive user are shared.
It is to be appreciated that described transmitting terminal 20, receiving terminal 30 are relative two ends, and both structure phases
With, therefore, receiving terminal 30 also has and sends the function of file that the needs that user selects are shared, accordingly,
Transmitting terminal 20 also has and receives the function of file that the needs that user selects are shared, and this is those skilled in the art
Known technology.
Preferably, described transmitting terminal 20, receiving terminal 30 are mobile phone, panel computer, PAD etc., but not with
This is limited.
Referring again to shown in Fig. 4, Fig. 5, described server end 10 include the second transmission/reception module 101 and
Comparison module 102.
The geographical position that described second transmission/reception module 101 sends for receiving end/sending end 30, receiving terminal 30
Confidence ceases, and for sending successful matching or failed information of matching;Described comparison module 102 is used for comparing
Described transmitting terminal 30 and the geographical location information of described receiving terminal 30, and compare the geography of described transmitting terminal 30
The transmission time sending time and the geographical location information of described receiving terminal 30 of positional information.
Owing to the present invention shares the system of file based on geographical position, it include transmitting terminal 20, receiving terminal 30 and
Server end 10, wherein, transmitting terminal 20, receiving terminal 30 obtain its geographical position according to the instruction sharing file
After confidence ceases and sends;Server end 10 receives and compares the ground of described transmitting terminal 20 and described receiving terminal 30
Reason positional information, and compare the transmission time of the geographical location information of described transmitting terminal 30 and described receiving terminal 30
Transmission time of geographical location information, and return successful matching or the failed information of pairing according to comparative result;
The file that the needs that user selects are shared by transmitting terminal 20 according to the information of the successful matching returned sends;Receive
End 30 receives, according to the information of the successful matching returned, the file that the needs of described user selection are shared;Therefore,
The operation sharing file is relatively simple, and without arranging special hardware, the method for sharing files has generally
The suitability, thus it is greatly promoted Consumer's Experience.
Above disclosed only the preferred embodiments of the present invention, can not limit the present invention with this certainly
Interest field, the equivalent variations therefore made according to scope of the present invention patent, still belong to the present invention and contained
Scope.