CN106899734A - Mobile terminal and mobile terminal contact person method of data synchronization - Google Patents
Mobile terminal and mobile terminal contact person method of data synchronization Download PDFInfo
- Publication number
- CN106899734A CN106899734A CN201710204375.3A CN201710204375A CN106899734A CN 106899734 A CN106899734 A CN 106899734A CN 201710204375 A CN201710204375 A CN 201710204375A CN 106899734 A CN106899734 A CN 106899734A
- Authority
- CN
- China
- Prior art keywords
- local
- storehouse
- distal end
- contact
- contact person
- 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.)
- Pending
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04M—TELEPHONIC COMMUNICATION
- H04M1/00—Substation equipment, e.g. for use by subscribers
- H04M1/26—Devices for calling a subscriber
- H04M1/27—Devices whereby a plurality of signals may be stored simultaneously
- H04M1/274—Devices whereby a plurality of signals may be stored simultaneously with provision for storing more than one subscriber number at a time, e.g. using toothed disc
- H04M1/2745—Devices whereby a plurality of signals may be stored simultaneously with provision for storing more than one subscriber number at a time, e.g. using toothed disc using static electronic memories, e.g. chips
- H04M1/2753—Devices whereby a plurality of signals may be stored simultaneously with provision for storing more than one subscriber number at a time, e.g. using toothed disc using static electronic memories, e.g. chips providing data content
- H04M1/2757—Devices whereby a plurality of signals may be stored simultaneously with provision for storing more than one subscriber number at a time, e.g. using toothed disc using static electronic memories, e.g. chips providing data content by data transmission, e.g. downloading
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04M—TELEPHONIC COMMUNICATION
- H04M1/00—Substation equipment, e.g. for use by subscribers
- H04M1/26—Devices for calling a subscriber
- H04M1/27—Devices whereby a plurality of signals may be stored simultaneously
- H04M1/274—Devices whereby a plurality of signals may be stored simultaneously with provision for storing more than one subscriber number at a time, e.g. using toothed disc
- H04M1/2745—Devices whereby a plurality of signals may be stored simultaneously with provision for storing more than one subscriber number at a time, e.g. using toothed disc using static electronic memories, e.g. chips
- H04M1/27453—Directories allowing storage of additional subscriber data, e.g. metadata
- H04M1/27457—Management thereof, e.g. manual editing of data
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04M—TELEPHONIC COMMUNICATION
- H04M2242/00—Special services or facilities
- H04M2242/40—Data synchronization between user terminals and central server
- H04M2242/405—Incremental backup
Landscapes
- Engineering & Computer Science (AREA)
- Signal Processing (AREA)
- Computer Networks & Wireless Communication (AREA)
- Business, Economics & Management (AREA)
- General Business, Economics & Management (AREA)
- Library & Information Science (AREA)
- Mobile Radio Communication Systems (AREA)
Abstract
The invention discloses a kind of mobile terminal and mobile terminal contact person method of data synchronization, the mobile terminal includes the first acquisition module, for when data syn-chronization instruction is detected, obtaining the local version number of mobile terminal and the distal end version number of Cloud Server;Second acquisition module, for when local version number and distal end version number are inconsistent, local contact database being write into caching according to the local identification information of each local linkages people in storehouse, and obtain the distal marker information of each distal end contact person in the contact database of distal end;Comparing module, for comparing local identification information and distal marker information, to obtain the different information of local linkages people and distal end contact person;Synchronization module, for obtaining correspondence difference contact data from distal end contact database according to different information, and realizes local contact database according to storehouse and the data syn-chronization of distal end contact database according to difference contact data.The present invention realizes the data syn-chronization of Cloud Server and mobile terminal contact person personal data.
Description
Technical field
The present invention relates to data synchronization technology field, more particularly to a kind of mobile terminal and mobile terminal contact person data it is same
One step process.
Background technology
Contact database (the data storage carrier of contact application in mobile terminal) is used as functions such as call, short messages
Entrance, is one of most basic function of mobile terminal (such as mobile phone), although mobile instant chat software (such as wechat application) exists
The frequency more and more higher used in people's daily life, instead of the part work(of conventional communication mode to a certain extent
Can, but contact database is used as the preserving type of user basic information, is still critically important.
But, the local contact database that important contact data is only stored in mobile terminal be according to storehouse it is unsafe,
Once mobile terminal is lost, the All Contacts' data having on mobile terminal will be lost, and the terminal that is often moved is lost
After mistake everywhere ask for lose number situation, and change mobile phone when contact data migration it is also inconvenient.
The content of the invention
It is a primary object of the present invention to provide a kind of mobile terminal and mobile terminal contact person method of data synchronization, it is intended to
Solve existing mobile terminal to lose or change, cause contact data to be lost or the difficult technical problem of migration.
To achieve the above object, the embodiment of the present invention provides a kind of mobile terminal, and the mobile terminal includes
First acquisition module, for when detect data syn-chronization instruct when, obtain mobile terminal local contact database according to
The distal end version number of the local version number in storehouse and the distal end contact database of Cloud Server;
Second acquisition module, for when local version number and distal end version number are inconsistent, by local contact database according to storehouse
In each local linkages people local identification information write-in caching, and obtain the remote of each distal end contact person in the contact database of distal end
End identification information;
Comparing module, for comparing local identification information and distal marker information, is joined with obtaining local linkages people with distal end
It is the different information of people;
Synchronization module, for obtaining correspondence difference contact data from distal end contact database according to different information, and
Realize local contact database according to storehouse and the data syn-chronization of distal end contact database according to difference contact data.
Alternatively, the mobile terminal also includes distal end synchronization module, and the distal end synchronization module is used for:
Acquisition local contact database is carried out in data synchronization process according to storehouse and distal end contact database, local contact database
According to the locally modified data changed in storehouse;
By locally modified data is activation to Cloud Server, so that Cloud Server realizes that distal end contacts according to locally modified data
Personal data storehouse and amended local contact database according to storehouse data syn-chronization.
Alternatively, the distal end synchronization module is additionally operable to:
The local version number of mobile terminal is updated to the current distal end version number of Cloud Server, wherein Cloud Server is remote
After end contact database carries out data syn-chronization with amended local contact database according to storehouse, the distal end version number of itself is updated.
Alternatively, the synchronization module is used for:
The different information is analyzed;
When local contact database has the same key contact person of like-identified according to storehouse and distal end contact database, judge same
Whether key contact person correspondence personal data have modification in local contact database according to storehouse;
When same key contact person correspondence personal data have modification in local contact database according to storehouse, if local contact database is according to storehouse
This is not deleted with key contact person with distal end contact database, then merge same key contact person in local contact database according to storehouse and remote
Hold contact database personal data, by merging after same key contact person personal data be updated to local contact database according to storehouse;
When same key contact person correspondence personal data have modification in local contact database according to storehouse, if local contact database is according to storehouse
Deletion does not delete this with key contact person with key contact person, distal end contact database, and with key contact person in local contact database
Differed according to the corresponding personal data in storehouse and distal end contact database, then by the contact database of distal end with key contact person
Correspondence personal data replace local contact database according in storehouse this with key contact person correspondence personal data;
When same key contact person correspondence personal data have modification in local contact database according to storehouse, if local contact database is according to storehouse
Do not delete same key contact person, distal end contact database and delete this with key contact person, by local contact database according in storehouse with bonded
It is that people corresponds to personal data as newly-increased locally modified data.
Alternatively, the synchronization module is used for:
When same key contact person correspondence personal data are not changed in local contact database according to storehouse, following steps are performed,
If distal end contact database does not delete same key contact person, and with key contact person in local contact database according to storehouse and remote
Corresponding personal data in the contact database of end are differed, then will be personal with key contact person correspondence in the contact database of distal end
Data replace local contact database according in storehouse this with key contact person correspondence personal data;
If distal end contact database is deleted with key contact person, local contact database is deleted according in storehouse with key contact person
Remove.
Alternatively, the synchronization module is used for:
There is local contact database in the contact database of distal end according to the different key contact person outside storehouse, and distal end contact person
When database does not delete the different key contact person, following steps are performed,
If local contact database is according to the contact person not existed in storehouse with different key contact person same name, by the different bonded system
People's correspondence personal data are added to local contact database according to storehouse;
If local contact database is according to the contact person existed in storehouse with different key contact person same name, by different key contact person couple
Personal data personal data corresponding with the contact person of same name are answered to be incorporated into local contact database according to storehouse.
To achieve the above object, the present invention also provides a kind of mobile terminal contact person method of data synchronization, described mobile whole
End contact data synchronous method includes:
When data syn-chronization instruction is detected, the local contact database of mobile terminal is obtained according to the local version number and cloud in storehouse
The distal end version number of the distal end contact database of server;
When local version number and distal end version number it is inconsistent when, by local contact database according to each local linkages people in storehouse sheet
Ground identification information write-in caching, and obtain the distal marker information of each distal end contact person in the contact database of distal end;
Local identification information and distal marker information are compared, is believed with the difference of distal end contact person with obtaining local linkages people
Breath;
Correspondence difference contact data is obtained from distal end contact database according to different information, and according to difference contact person
Data realize local contact database according to storehouse and the data syn-chronization of distal end contact database.
Alternatively, it is described that correspondence difference contact data, and root are obtained from distal end contact database according to different information
According to difference contact data realize local contact database according to storehouse and distal end contact database data syn-chronization the step of after also
Including:
Acquisition local contact database is carried out in data synchronization process according to storehouse and distal end contact database, local contact database
According to the locally modified data changed in storehouse;
By locally modified data is activation to Cloud Server, so that Cloud Server realizes that distal end contacts according to locally modified data
Personal data storehouse and amended local contact database according to storehouse data syn-chronization.
Alternatively, it is described by locally modified data is activation to Cloud Server, so that Cloud Server is according to locally modified data
Realize distal end contact database and amended local contact database according to storehouse data syn-chronization the step of after also include:
The local version number of mobile terminal is updated to the current distal end version number of Cloud Server, wherein Cloud Server is remote
After end contact database carries out data syn-chronization with amended local contact database according to storehouse, the distal end version number of itself is updated.
Alternatively, it is described that correspondence difference contact data, and root are obtained from distal end contact database according to different information
According to difference contact data realize local contact database according to storehouse and distal end contact database data syn-chronization the step of include:
The different information is analyzed;
When local contact database has the same key contact person of like-identified according to storehouse and distal end contact database, judge same
Whether key contact person correspondence personal data have modification in local contact database according to storehouse;
When same key contact person correspondence personal data have modification in local contact database according to storehouse, following steps are performed,
If local contact database does not delete this with key contact person according to storehouse and distal end contact database, merge with bonded
Be people in local contact database according to storehouse and the personal data of distal end contact database, by merging after same key contact person number
According to being updated to local contact database according to storehouse;
If local contact database deletes according to storehouse and does not delete this with key contact person with key contact person, distal end contact database,
And differed according to the corresponding personal data in storehouse and distal end contact database in local contact database with key contact person, then will be remote
End contact database in key contact person correspondence personal data replace local contact database according in storehouse this with key contact person correspondence
Personal data;
If local contact database does not delete same key contact person, distal end contact database and deletes this with key contact person according to storehouse,
Local contact database is corresponded into personal data as newly-increased locally modified data according in storehouse with key contact person.
Alternatively, judge whether there is modification according to storehouse in local contact database with key contact person correspondence personal data described
Also include after step:
When same key contact person correspondence personal data are not changed in local contact database according to storehouse, following steps are performed,
If distal end contact database does not delete same key contact person, and with key contact person in local contact database according to storehouse and remote
Corresponding personal data in the contact database of end are differed, then will be personal with key contact person correspondence in the contact database of distal end
Data replace local contact database according in storehouse this with key contact person correspondence personal data;
If distal end contact database is deleted with key contact person, local contact database is deleted according in storehouse with key contact person
Remove.
Alternatively, it is described the step of be analyzed to the different information after also include:
There is local contact database in the contact database of distal end according to the different key contact person outside storehouse, and distal end contact person
When database does not delete the different key contact person, following steps are performed,
If local contact database is according to the contact person not existed in storehouse with different key contact person same name, by the different bonded system
People's correspondence personal data are added to local contact database according to storehouse;
If local contact database is according to the contact person existed in storehouse with different key contact person same name, by different key contact person couple
Personal data personal data corresponding with the contact person of same name are answered to be incorporated into local contact database according to storehouse.
The present invention is by when data syn-chronization instruction is detected, obtaining the local contact database of mobile terminal according to the local of storehouse
The distal end version number of the distal end contact database of version number and Cloud Server, then when local version number and distal end version number not
When consistent, local contact database is write into caching according to the local identification information of each local linkages people in storehouse, and obtain distal end contact
The distal marker information of personal data storehouse Zhong Ge distal ends contact person, then local identification information and distal marker information are compared, to obtain
Local linkages people and the different information of distal end contact person, obtain corresponding poor finally according to different information from distal end contact database
Different contact data, and realize local contact database according to storehouse and the individual of distal end contact database according to difference contact data
Data syn-chronization, realizes the data syn-chronization of Cloud Server and mobile terminal contact person personal data, though mobile terminal lose or
Change, it is also possible to quickly from contact person's personal data that Cloud Server is synchronously newest, considerably increase user in contact number
According to the experience in migration.
Brief description of the drawings
Fig. 1 is the hardware architecture diagram for realizing the optional mobile terminal of each embodiment one of the invention;
Fig. 2 is the schematic diagram of a scenario of mobile terminal of the present invention and method application;
Fig. 3 is the logic flow schematic diagram of personal data synchronization flow in mobile terminal of the present invention and method;
Fig. 4 is the module diagram of the embodiment of mobile terminal of the present invention;
Fig. 5 is the module diagram of another embodiment of mobile terminal of the present invention;
Fig. 6 is the schematic flow sheet of the embodiment of mobile terminal contact person method of data synchronization one of the present invention;
Fig. 7 is the schematic flow sheet of the another embodiment of mobile terminal contact person method of data synchronization of the present invention.
The realization of the object of the invention, functional characteristics and advantage will be described further referring to the drawings in conjunction with the embodiments.
Specific embodiment
It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, it is not intended to limit the present invention.
The mobile terminal of each embodiment of the invention is realized referring now to Description of Drawings.In follow-up description, using for representing
Only for being conducive to explanation of the invention, itself does not have spy to the suffix of such as " module ", " part " or " unit " of element
Fixed meaning.Therefore, " module " can be used mixedly with " part ".
Mobile terminal can be implemented in a variety of manners.For example, the terminal described in the present invention can include such as moving
Phone, smart phone, notebook computer, digit broadcasting receiver, PDA (personal digital assistant), PAD (panel computer), PMP
The mobile terminal of (portable media player), guider etc. and such as numeral TV, desktop computer etc. are consolidated
Determine terminal.
Fig. 1 is the hardware architecture diagram for realizing the optional mobile terminal of each embodiment one of the invention.
Mobile terminal 1 00 can include wireless communication unit 110, A/V (audio/video) input block 120, user input
Unit 130, sensing unit 140, output unit 150, memory 160, interface unit 170, controller 180 and power subsystem 190,
And first acquisition module 10, the second acquisition module 20, comparing module 30 and synchronization module 40 etc..Fig. 1 is shown with each
The mobile terminal of component is planted, it should be understood that being not required for implementing all components for showing.Can alternatively implement more
Or less component.The element of mobile terminal will be discussed in more detail below.
Wireless communication unit 110 generally includes one or more assemblies, and it allows mobile terminal 1 00 and radio communication device
Or the radio communication between network.For example, wireless communication unit can include mobile communication module 112, wireless Internet mould
At least one of block 113.
Mobile communication module 112 sends radio signals to base station (for example, access point, node B etc.), exterior terminal
And at least one of server and/or receive from it radio signal.Such radio signal can be logical including voice
Words signal, video calling signal or the various types of data for sending and/or receiving according to text and/or Multimedia Message.
Wireless Internet module 113 supports the Wi-Fi (Wireless Internet Access) of mobile terminal.The module can be internally or externally
It is couple to terminal.Wi-Fi (Wireless Internet Access) technology involved by the module can include WLAN (WLAN) (Wi-Fi), Wibro
(WiMAX), Wimax (worldwide interoperability for microwave accesses), HSDPA (high-speed downlink packet access) etc..
A/V input blocks 120 are used to receive audio or video signal.
User input unit 130 can generate key input data to control each of mobile terminal according to the order of user input
Plant operation.User input unit 130 allows the various types of information of user input, and can include keyboard, metal dome, touch
Plate (for example, detection due to being touched caused by resistance, pressure value, electric capacity etc. change sensitive component), roller, rocking bar
Etc..Especially, when touch pad is superimposed upon on display unit 151 in the form of layer, touch-screen can be formed.
Sensing unit 140 detects the current state of mobile terminal 1 00, (for example, mobile terminal 1 00 opens or closes shape
State), the presence or absence of the contact (that is, touch input) of the position of mobile terminal 1 00, user for mobile terminal 1 00, mobile terminal
100 orientation, the acceleration of mobile terminal 1 00 or by speed is mobile and direction etc., and generate for controlling mobile terminal 1 00
The order of operation or signal.
Interface unit 170 is connected the interface that can pass through with mobile terminal 1 00 as at least one external device (ED).For example,
External device (ED) can include wired or wireless head-band earphone port, external power source (or battery charger) port, wired or nothing
Line FPDP, memory card port, the port for connecting the device with identification module, audio input/output (I/O) end
Mouth, video i/o port, ear port etc..
Output unit 150 is configured to provide output signal (for example, audio is believed with vision, audio and/or tactile manner
Number, vision signal, alarm signal, vibration signal etc.).Output unit 150 can include display unit 151, audio output mould
Block 152 etc..
Display unit 151 may be displayed on the information processed in mobile terminal 1 00.For example, when mobile terminal 1 00 is in electricity
During words call mode, display unit 151 can show and converse or other communicate (for example, text messaging, multimedia file
Download etc.) related user interface (UI) or graphic user interface (GUI).
Dio Output Modules 152 can mobile terminal be in call signal reception pattern, call mode, logging mode,
It is that wireless communication unit 110 is received or in memory 160 when under the isotypes such as speech recognition mode, broadcast reception mode
The voice data transducing audio signal of middle storage and it is output as sound.
Memory 160 can store software program for the treatment and control operation performed by controller 180 etc., Huo Zheke
Temporarily to store oneself data (for example, telephone directory, message, still image, video etc.) through exporting or will export.
Memory 160 can include the storage medium of at least one type, and the storage medium includes flash memory, hard disk, many
Media card, card-type memory (for example, SD or DX memories etc.), random access storage device (RAM), static random-access storage
Device (SRAM), read-only storage (ROM), Electrically Erasable Read Only Memory (EEPROM), programmable read only memory
(PROM), magnetic storage, disk, CD etc..And, mobile terminal 1 00 can perform memory with by network connection
The network storage device cooperation of 160 store function.
The overall operation of the generally control mobile terminal of controller 180.For example, controller 180 is performed and voice call, data
Communication, video calling etc. related control and treatment.In addition, controller 180 can be included for reproducing (or playback) many matchmakers
The multi-media module 181 of volume data, multi-media module 181 can be constructed in controller 180, or can be structured as and control
Device 180 is separated.
Power subsystem 190 receives external power or internal power under the control of controller 180 and provides operation each unit
Appropriate electric power needed for part and component.
Various implementation methods described herein can be with use such as computer software, hardware or its any combination of calculating
Machine computer-readable recording medium is implemented.Implement for hardware, implementation method described herein can be by using application-specific IC
(ASIC), digital signal processor (DSP), digital signal processing device (DSPD), programmable logic device (PLD), scene can
Programming gate array (FPGA), processor, controller, microcontroller, microprocessor, it is designed to perform function described herein
At least one in electronic unit is implemented, and in some cases, such implementation method can be implemented in controller 180.
For software implementation, the implementation method of such as process or function can with allow to perform the single of at least one function or operation
Software module is implemented.Software code can be come by the software application (or program) write with any appropriate programming language
Implement, software code can be stored in memory 160 and performed by controller 180.
Based on above-mentioned mobile terminal hardware configuration, communication apparatus structure, each embodiment of mobile terminal of the present invention is proposed, it is mobile
Terminal is a part for mobile terminal.
Reference picture 4, the present invention provides a kind of mobile terminal, and in the embodiment of mobile terminal one, the device includes:
First acquisition module 10, for when data syn-chronization instruction is detected, obtaining the local contact database of mobile terminal
According to the distal end version number of the distal end contact database of the local version number and Cloud Server in storehouse;
The control instruction of contact data synchronization flow, data syn-chronization instruction are triggered when data syn-chronization is instructed in mobile terminal
Can by mobile terminal medium cloud service framework (cloud service framework can be a process or thread, or a software and hardware combining module) draw
Hair, such as cloud service framework can enable timed task, when timed task reaches setting time, the cloud service framework life of mobile terminal
Into data syn-chronization instruction;Specifically, as timed task is set as at 18 points on every Sundays, so that mobile terminal is in 6 pm on every Sundays
When automatically generated data synchronic command carrying out contact data synchronization.Additionally, data syn-chronization instruction can also be mobile terminal
User actively triggers, such as on user's triggering mobile terminal display screen when specific region, specific virtual key or specific material resources button,
Mobile terminal generation data syn-chronization instruction, so as to realize being operated according to user and being intended to come real-time implementation contact data synchronization.
Reference picture 2, the storage user that local contact database is provided in inside mobile terminal according to storehouse is local mobile whole 100
Addition and contact person's personal data of modification, a mobile terminal 1 00 comprise at least a local contact database according to storehouse.One cloud
Server 200 can be corresponded to and associate multiple mobile terminal 1s 00, and specifically, user can register an account, Shen in Cloud Server 200
Distal end contact database that please be in Cloud Server 200, a distal end contact database can be with the sheet of multiple mobile terminal 1s 00
Ground contact database carries out contact data synchronization.
Local contact database has the version number that data update, local contact database according to storehouse and distal end contact database
Updated once according to the contact data in storehouse and distal end contact database, then correspond to version number and update once.Specifically, locally
The distal end contact database that contact database has local version number, Cloud Server has distal end version number, local linkages
When there is to update (such as deletion of personal data, newly-increased, modification) in the contact person's correspondence personal data in personal data storehouse, city edition
This number is updated to current distal end version number, when the contact person's correspondence personal data in the contact database of distal end update, far
End version number one unit of increase, such as distal end version number are 1.1 before updating again, and distal end version number is 1.2 after personal data update.
Due to being usually that a distal end contact database associates multiple local contact databases according to storehouse, so distal end version number
Generally larger than contact person's personal data of local version number, i.e. distal end contact database than local contact database according to storehouse more
Newly, if going to obtain and compare local version number and distal end version number in real time, local contact database can be caused to be contacted with distal end according to storehouse
Frequently data syn-chronization flow is carried out between personal data storehouse, causes mobile terminal flow to waste and power consumption increase, the present embodiment is
When detecting data syn-chronization and instructing, just carry out the acquisition of local version number and distal end version number, compare, greatly reduce data
The triggering of synchronous flow, it is to avoid distal end contact database personal data change also frequently carries out data syn-chronization when smaller, reduces
The waste of data traffic, the power consumption for reducing mobile terminal.
Second acquisition module 20, for when local version number and distal end version number it is inconsistent when, by local contact database according to
The local identification information write-in caching of each local linkages people in storehouse, and obtain each distal end contact person in the contact database of distal end
Distal marker information;
Because Cloud Server is at least associated with a mobile terminal, in local linkages every time with a certain mobile terminal
After personal data storehouse carries out personal data synchronization, the distal end version number of the distal end contact database of Cloud Server can update one
It is secondary, so distal end version number typically will be higher than local version number of each local contact database according to storehouse.Thus in local version number
When inconsistent with distal end version number, show that local version number will be less than distal end version number, the local version number correspondence mobile terminal
Cloud service framework notification local contact database according to storehouse by the local identification information of each local linkages people be written to caching in, it is ensured that
Local identification information in caching is consistent according to corresponding informance in storehouse with local contact database, meanwhile, it is also remote in acquisition Cloud Server
The distal marker information of each distal end contact person in the contact database of end, its identification information can in database unique mark it is each
The major key of contact person, such as student number, job number, identification card number.Due to mobile terminal local cache is only to simplify the sheet after treatment
Ground identification information, what is obtained from Cloud Server is also only the distal marker information after treatment that simplifies, therefore local identification information and remote
Hold the data volume of identification information smaller, it is to avoid to obtain the larger complete local linkages people correspondence personal data of data volume, improve
The extraction rate of local data, while avoid downloading complete distal end contact person correspondence personal data from Cloud Server, significantly
Reduce the spent flow in terms of distal end contact person correspondence personal data are downloaded of mobile terminal.
For example, local contact database includes contact person A and B according to storehouse, the personal data of contact person A include job number 001, sex
Man, telephone number 123, the personal data of contact person B include job number 002, sex female, telephone number 321, then will be including job number
001 writes with the mapping table of contact person's B mapping relations with contact person's A mapping relations, and job number 002 as local identification information
In mobile terminal caching.Meanwhile, acquisition includes job number 001 with contact person A mapping relations, job number 002 and contact person's B mapping relations
And job number 003 and the distal marker information of contact person's C mapping relations etc., believed with comparing local identification information and distal marker
Breath.Local contact data storehouse personal data corresponding with the contact person in the contact database of distal end may include major key, and head portrait,
One or more in the pet name, Real Name, work unit, email address, telephone number, social account information.
Comparing module 30, for comparing local identification information and distal marker information, to obtain local linkages people and distal end
The different information of contact person;
Synchronization module 40, for obtaining correspondence difference contact data from distal end contact database according to different information,
And realize local contact database according to storehouse and the data syn-chronization of distal end contact database according to difference contact data.
After local identification information and distal marker information is obtained, local identification information and distal marker information are compared,
Obtain different information of the local contact database according to distal end contact person in local linkages people in storehouse and distal end contact database, difference
Information includes existing between local linkages people and distal end contact person being deposited between same correspondents, local linkages people and distal end contact person
In different contact person, local contact database according to storehouse and distal end contact database to same correspondents, the deletion of different contact person
Situation etc..So as to can targetedly obtain corresponding difference contact number from the contact database of distal end according to different information
According to, difference contact data is then updated to local contact database according to storehouse, complete personal data of the local contact database according to storehouse
It is synchronous.Additionally, after personal data synchronizing process of the local contact database according to storehouse is completed, the exportable prompt message of mobile terminal with
Users personal data is reminded to synchronously complete, the prompt message can be the one kind in the modes such as picture, video, audio, vibrations, flash of light
Or it is various.
For example, local contact database has 3 local linkages people (contact person A, B and C) according to storehouse, 3 local linkages people
Personal data amounts to 3M, and the local identification information of 3 local linkages people amounts to 3KB, and distal end contact database has 5 distal ends to contact
People (contact person A, B, C, D and E), the personal data of distal end contact person amount to 5M, and 5 distal marker information of distal end contact person are total to
Meter 5KB.
If according to the conventional contact data method of synchronization, mobile terminal obtains from distal end contact database download 5M first
The personal data of distal end contact person, then spend more time to extract 3 personal data of local linkages people of 3M, then basis
The personal data of distal end contact person and the personal data of local linkages people carry out personal data synchronization, and flow 5M streams are expended altogether
Amount, expends the electricity for extracting 3M personal data.
According to the scheme of the application, mobile terminal downloads the distal marker letter of 5KB from distal end contact database first
Breath, then the very fast local identification information for extracting 3KB, then determines from distal end according to local identification information and distal marker information
Contact database downloads the corresponding personal data of contact person D and E of 2M, and flow 2M+5KB is expended altogether, expends and extracts 3KB sheets
The electricity of ground identification information.
In the present embodiment, mobile terminal is obtained when data syn-chronization instruction is detected by the first acquisition module 10
Local contact database according to the distal end contact database of the local version number and Cloud Server in storehouse distal end version number, then second
Acquisition module 20 when local version number and distal end version number it is inconsistent when, by local contact database according to each local linkages people in storehouse
Local identification information write-in caching, and the distal marker information of each distal end contact person in the contact database of distal end is obtained, compare
Module 30 compares local identification information and distal marker information again, is believed with the difference of distal end contact person with obtaining local linkages people
Breath, last synchronization module 40 is obtained from distal end contact database according to different information and corresponds to difference contact data, and according to
Difference contact data realizes that local contact database is synchronous with the personal data of distal end contact database according to storehouse, realizes cloud clothes
Business device and mobile terminal contact person personal data data syn-chronization, even if mobile terminal lose or change, it is also possible to quickly from
The synchronously newest contact person's personal data of Cloud Server, considerably increase experience of the user in contact data migration.Meanwhile,
The less different information of data volume is themselves based on, targetedly downloads correspondence distal end contact person's from distal end contact database
Personal data, it is to avoid the contact person's personal data in the contact database of distal end are all downloaded, mobile terminal is greatlyd save
Flow, and mobile terminal only just carries out contact data synchronization flow when data syn-chronization instruction is detected, and this need to be extracted
Ground identification information expends time, occupying system resources much smaller than local linkages people's personal data, mobile whole so as to greatly reduce
The power consumption at end.
Further, in another embodiment of mobile terminal of the present invention, synchronization module 40 is used for:
The different information is analyzed;
When local contact database has the same key contact person of like-identified according to storehouse and distal end contact database, judge same
Whether key contact person correspondence personal data have modification in local contact database according to storehouse;
When same key contact person correspondence personal data have modification in local contact database according to storehouse, if local contact database is according to storehouse
This is not deleted with key contact person with distal end contact database, then merge same key contact person in local contact database according to storehouse and remote
Hold contact database personal data, by merging after same key contact person personal data be updated to local contact database according to storehouse;
When same key contact person correspondence personal data have modification in local contact database according to storehouse, if local contact database is according to storehouse
Deletion does not delete this with key contact person with key contact person, distal end contact database, and with key contact person in local contact database
Differed according to the corresponding personal data in storehouse and distal end contact database, then by the contact database of distal end with key contact person
Correspondence personal data replace local contact database according in storehouse this with key contact person correspondence personal data;
When same key contact person correspondence personal data have modification in local contact database according to storehouse, if local contact database is according to storehouse
Do not delete same key contact person, distal end contact database and delete this with key contact person, by local contact database according in storehouse with bonded
It is that people corresponds to personal data as newly-increased locally modified data.
Reference picture 3, after different information of the local linkages people with distal end contact person is obtained, is divided the different information
Analysis, when there is the same key contact person of like-identified according to storehouse DB1 and distal end contact database DB2 in local contact database, and then
Whether on DB1 have modification, wherein like-identified can refer to identical major key, also if judging same key contact person correspondence personal data
It is to say that with key contact person refer to the contact person with identical major key, the contact person A with identical job number such as in DB1 and DB2, that
Contact person A is the same key contact person of DB1 and DB2.
When same key contact person A correspondence personal data have modification in DB1, if DB1 and DB2 does not delete this with key contact person
A, shows there is renewal with the personal data of key contact person A in DB1, continues to retain with the personal data of key contact person A in DB2, table
The former personal data of bright same key contact person A have meaning, so merge the personal data with key contact person A in DB1 and DB2, will
Same key contact person personal data after merging are updated to local contact database according to storehouse.For example, personal in DB2 with key contact person A
Phone number is number 1 in data, and phone number is revised as number 2 in personal data in DB1, then merge number 1 and number
2, so as to the phone number using number 1 and number 2 as same key contact person A in DB1 personal data.Additionally, DB1 and DB2 are deleted
Except contact person A, refer to the contact person A DB1 and DB2 record field addition " deletion " mark, the source data of contact person A according to
So retain in DB1 and DB2.
When same key contact person A correspondence personal data have modification in DB1, if DB1 is deleted not deleted with key contact person A, DB2
This is with key contact person A, and corresponding personal data with key contact person A in DB1 and DB2 are differed, and show that same key contact person A exists
There is modification in DB2, so corresponding to individual with key contact person A by being corresponded to during personal data replace DB1 with key contact person A in DB2
Data, with the synchronization of each contact person's personal data in keeping DB1 and DB2.
When same key contact person A correspondence personal data have modification in DB1, if DB1 does not delete same key contact person A, DB2 and deletes
This shows that same key contact person A is newly-increased in DB1 with key contact person A, so personal data will be corresponded to key contact person A in DB1
As newly-increased locally modified data, added with the same key contact person A personal data that will be increased newly in DB1 based on locally modified data
Into DB2.
When same key contact person A correspondence personal data have modification in DB1, if DB1 and DB2 delete this with key contact person A,
Show that same key contact person A personal data are useless for mobile terminal user, so same key contact person A is not done locating
Reason.
In the present embodiment, there is the same bonded of like-identified according to storehouse and distal end contact database in local contact database
When being people, same key contact person personal data are modified situation according to storehouse in local contact database, based on above-mentioned treatment rule, protected
Card local contact database is timely with contact person's personal data of distal end contact database, accurately synchronous according to storehouse.
Alternatively, the synchronization module 40 is additionally operable to:
When same key contact person correspondence personal data are not changed in local contact database according to storehouse, if distal end contact data
Do not delete same key contact person in storehouse, and individual according to the correspondence in storehouse and distal end contact database in local contact database with key contact person
Personal data is differed, then will replace local contact database according to storehouse with key contact person correspondence personal data in the contact database of distal end
In this with key contact person correspondence personal data;
When same key contact person correspondence personal data are not changed in local contact database according to storehouse, if distal end contact data
Storehouse is deleted with key contact person, then deleted local contact database with key contact person according in storehouse.
Reference picture 3, when during in same key contact person A, correspondingly personal data are in local contact database according to storehouse DB1 without modification, if
Distal end contact database DB2 does not delete same key contact person A, and the corresponding personal data with key contact person A in DB1 and DB2
Differ, show there is renewal relative to DB1 with the personal data of key contact person A in DB2, then will be corresponding with key contact person A in DB2
This realizes the synchronization of contact person's personal data with key contact person A correspondence personal data in personal data replacement DB1.
When same key contact person A correspondence personal data are not changed in DB1, if DB2 is deleted with key contact person A, show cloud
Server actively deletes same key contact person A because of user in the operation of other mobile terminals, is used for mobile terminal with bonded system A
Family is useless, then will be deleted with key contact person A personal data in DB1.
In the present embodiment, there is the same bonded of like-identified according to storehouse and distal end contact database in local contact database
When being people, same key contact person personal data are modified situation according to storehouse in local contact database, based on above-mentioned treatment rule, protected
Card local contact database is timely with contact person's personal data of distal end contact database, accurately synchronous according to storehouse.
Further, in the another embodiment of mobile terminal of the present invention, the synchronization module 40 is used for:
There is local contact database in the contact database of distal end according to the different key contact person outside storehouse, and distal end contact person
When database does not delete the different key contact person, if local contact database is according to the connection not existed in storehouse with different key contact person same name
It is people, then the different key contact person correspondence personal data is added to local contact database according to storehouse;If local contact database is according in storehouse
In the presence of the contact person with different key contact person same name, then by different key contact person correspondence personal data and the contact person of same name
Correspondence personal data are incorporated into local contact database according to storehouse.
Reference picture 3, based on different information, if it is determined that there is local contact database according to storehouse in distal end contact database DB2
Different key contact person B outside DB1, shows there is the contact person of different mark in DB1 in DB2, and then judge different key contact person B
Whether there is deletion in DB2;
If without the different key contact person B of deletion in DB2, and the different key contact person B does not exist the contact of same name in DB1
People, shows to identify different name identical contact persons without different major keys, and different key contact person B is non-existent new contact in DB1
People, so different key contact person B correspondence personal data are updated in DB1.
If without the different key contact person B of deletion in DB2, and there is the contact of same name in the different key contact person B in DB1
People, further analyze different key contact person B personal data whether the complete phase of personal data corresponding with same name contact person in DB1
Together;(1) it is different if the personal data of different key contact person B personal data corresponding with same name contact person C in DB1 are incomplete same
The personal data of key contact person B personal data corresponding with same name contact person C in DB1 merge, and same name in DB1 is joined
It is that people C is deleted with different key contact person B identical personal data part;(2) if the personal data and phase in DB1 of different key contact person B
It is identical with name contact person C correspondence personal data, although showing different key contact person B and same name contact person's C primary keys
Know it is inconsistent, but substantially same contact person, by the local identification information of same name contact person C in DB1 (i.e. this landlord
Key is identified) be updated to the distal marker information (i.e. distal end major key mark) of different key contact person B in DB2, such as different key contact person B's
Major key is designated 002, and the major key of same name contact person C is designated 003, then by the primary key of the same name contact person C of DB1
Knowledge is changed to 002.
In the present embodiment, it is further implemented in the contact database of distal end outside there is local contact database according to storehouse
Different key contact person, and distal end contact database do not deleted under the different key contact person scene, local data base and remote data storehouse
Between personal data synchronization, it is ensured that the Cloud Server accuracy synchronous with personal data under multi-mobile-terminal scene, in time
Property and convenience.
Further, on the basis of each embodiment of above-mentioned mobile terminal, mobile terminal also includes distal end synchronization module 50,
Reference picture 5, the distal end synchronization module 50 is used for:
Acquisition local contact database is carried out in data synchronization process according to storehouse and distal end contact database, local contact database
According to the locally modified data changed in storehouse;
By locally modified data is activation to Cloud Server, so that Cloud Server realizes that distal end contacts according to locally modified data
Personal data storehouse and amended local contact database according to storehouse data syn-chronization.
In local contact database carries out personal data synchronizing process according to storehouse DB1 and distal end contact database DB2, DB1
In each contact person correspondence personal data may exist and the modification operation such as delete, replace, merging, cause right after DB2 and DB1 modifications
The inconsistent situation of contact person's personal data that major key is identified is answered, so obtain that personal data in DB1 change locally repaiies
Change data, in locally modified data at least include personal data change modification type, change contact person's major key identify,
Amended personal data.Then mobile terminal is by locally modified data is activation to Cloud Server, so that Cloud Server is according to this
Ground modification data validation DB1 have modification local linkages people correspondence personal data, and by DB1 in personal data synchronizing process
The local linkages people correspondence personal data for having modification are updated in the DB2 of Cloud Server, so as to keep Cloud Server DB2 and movement
Personal data uniformity between terminal D B1.
Alternatively, the distal end synchronization module 50 is additionally operable to:
The local version number of mobile terminal is updated to the current distal end version number of Cloud Server, wherein Cloud Server is remote
After end contact database carries out data syn-chronization with amended local contact database according to storehouse, the distal end version number of itself is updated.
For example, before personal data synchronization, the distal end contact database DB2 version numbers of Cloud Server are 1.5, mobile whole
The local contact database at end is 1.3 according to storehouse DB1 version numbers, and after DB2 and DB2 realize that personal data are synchronous, the version number of DB2 is
1.6, and the version number of DB1 is consistent with DB2, i.e. and the DB1 version numbers of mobile terminal are also updated to 1.6.By the present embodiment
Scheme, it is ensured that after personal data renewal is carried out, version number is consistent mobile terminal DB1 with Cloud Server.
The present invention also provides a kind of mobile terminal contact person method of data synchronization, in mobile terminal contact person data syn-chronization side
In the embodiment of method one, reference picture 6, mobile terminal contact person method of data synchronization includes:
Step S10, when data syn-chronization instruction is detected, obtains the local contact database of mobile terminal according to the city edition in storehouse
The distal end version number of the distal end contact database of this number and Cloud Server;
The control instruction of contact data synchronization flow, data syn-chronization instruction are triggered when data syn-chronization is instructed in mobile terminal
Can by mobile terminal medium cloud service framework (cloud service framework can be a process or thread, or a software and hardware combining module) draw
Hair, such as cloud service framework can enable timed task, when timed task reaches setting time, the cloud service framework life of mobile terminal
Into data syn-chronization instruction;Specifically, as timed task is set as at 18 points on every Sundays, so that mobile terminal is in 6 pm on every Sundays
When automatically generated data synchronic command carrying out contact data synchronization.Additionally, data syn-chronization instruction can also be mobile terminal
User actively triggers, such as on user's triggering mobile terminal display screen when specific region, specific virtual key or specific material resources button,
Mobile terminal generation data syn-chronization instruction, so as to realize being operated according to user and being intended to come real-time implementation contact data synchronization.
The storage user that local contact database is provided in inside mobile terminal according to storehouse locally adds and repaiies in mobile terminal
The contact person's personal data for changing a, mobile terminal comprises at least a local contact database according to storehouse.One Cloud Server can be right
Multiple mobile terminals should be associated, specifically, user can register an account in Cloud Server, the distal end connection in application Cloud Server
It is personal data storehouse, a distal end contact database can carry out contacting number with the local contact database of multiple mobile terminals according to storehouse
According to synchronization.
Local contact database has the version number that data update, local contact database according to storehouse and distal end contact database
Updated once according to the contact data in storehouse and distal end contact database, then correspond to version number and update once.Specifically, locally
The distal end contact database that contact database has local version number, Cloud Server has distal end version number, local linkages
When there is to update (such as deletion of personal data, newly-increased, modification) in the contact person's correspondence personal data in personal data storehouse, city edition
This number is updated to current distal end version number, when the contact person's correspondence personal data in the contact database of distal end update, far
End version number one unit of increase, such as distal end version number are 1.1 before updating again, and distal end version number is 1.2 after personal data update.
Due to being usually that a distal end contact database associates multiple local contact databases according to storehouse, so distal end version number
Generally larger than contact person's personal data of local version number, i.e. distal end contact database than local contact database according to storehouse more
Newly, if going to obtain and compare local version number and distal end version number in real time, local contact database can be caused to be contacted with distal end according to storehouse
Frequently data syn-chronization flow is carried out between personal data storehouse, causes mobile terminal flow to waste and power consumption increase, the present embodiment is
When detecting data syn-chronization and instructing, just carry out the acquisition of local version number and distal end version number, compare, greatly reduce data
The triggering of synchronous flow, it is to avoid distal end contact database personal data change also frequently carries out data syn-chronization when smaller, reduces
The waste of data traffic, the power consumption for reducing mobile terminal.
Step S20, when local version number and distal end version number are inconsistent, by local contact database according to each local in storehouse
It is the local identification information write-in caching of people, and obtains the distal marker letter of each distal end contact person in the contact database of distal end
Breath;
Because Cloud Server is at least associated with a mobile terminal, in local linkages every time with a certain mobile terminal
After personal data storehouse carries out personal data synchronization, the distal end version number of the distal end contact database of Cloud Server can update one
It is secondary, so distal end version number typically will be higher than local version number of each local contact database according to storehouse.Thus in local version number
When inconsistent with distal end version number, show that local version number will be less than distal end version number, the local version number correspondence mobile terminal
Cloud service framework notification local contact database according to storehouse by the local identification information of each local linkages people be written to caching in, it is ensured that
Local identification information in caching is consistent according to corresponding informance in storehouse with local contact database, meanwhile, it is also remote in acquisition Cloud Server
The distal marker information of each distal end contact person in the contact database of end, its identification information can in database unique mark it is each
The major key of contact person, such as student number, job number, identification card number.Due to mobile terminal local cache is only to simplify the sheet after treatment
Ground identification information, what is obtained from Cloud Server is also only the distal marker information after treatment that simplifies, therefore local identification information and remote
Hold the data volume of identification information smaller, it is to avoid to obtain the larger complete local linkages people correspondence personal data of data volume, improve
The extraction rate of local data, while avoid downloading complete distal end contact person correspondence personal data from Cloud Server, significantly
Reduce the spent flow in terms of distal end contact person correspondence personal data are downloaded of mobile terminal.
For example, local contact database includes contact person A and B according to storehouse, the personal data of contact person A include job number 001, sex
Man, telephone number 123, the personal data of contact person B include job number 002, sex female, telephone number 321, then will be including job number
001 writes with the mapping table of contact person's B mapping relations with contact person's A mapping relations, and job number 002 as local identification information
In mobile terminal caching.Meanwhile, acquisition includes job number 001 with contact person A mapping relations, job number 002 and contact person's B mapping relations
And job number 003 and the distal marker information of contact person's C mapping relations etc., believed with comparing local identification information and distal marker
Breath.Local contact data storehouse personal data corresponding with the contact person in the contact database of distal end may include major key, and head portrait,
One or more in the pet name, Real Name, work unit, email address, telephone number, social account information.
Step S30, compares local identification information and distal marker information, to obtain local linkages people and distal end contact person's
Different information;
Step S40, correspondence difference contact data is obtained according to different information from distal end contact database, and according to difference
Different contact data realizes that local contact database is synchronous with the personal data of distal end contact database according to storehouse.
After local identification information and distal marker information is obtained, local identification information and distal marker information are compared,
Obtain different information of the local contact database according to distal end contact person in local linkages people in storehouse and distal end contact database, difference
Information includes existing between local linkages people and distal end contact person being deposited between same correspondents, local linkages people and distal end contact person
In different contact person, local contact database according to storehouse and distal end contact database to same correspondents, the deletion of different contact person
Situation etc..So as to can targetedly obtain corresponding difference contact number from the contact database of distal end according to different information
According to, difference contact data is then updated to local contact database according to storehouse, complete personal data of the local contact database according to storehouse
It is synchronous.Additionally, after personal data synchronizing process of the local contact database according to storehouse is completed, the exportable prompt message of mobile terminal with
Users personal data is reminded to synchronously complete, the prompt message can be the one kind in the modes such as picture, video, audio, vibrations, flash of light
Or it is various.
For example, local contact database has 3 local linkages people (contact person A, B and C) according to storehouse, 3 local linkages people
Personal data amounts to 3M, and the local identification information of 3 local linkages people amounts to 3KB, and distal end contact database has 5 distal ends to contact
People (contact person A, B, C, D and E), the personal data of distal end contact person amount to 5M, and 5 distal marker information of distal end contact person are total to
Meter 5KB.
If according to the conventional contact data method of synchronization, mobile terminal obtains from distal end contact database download 5M first
The personal data of distal end contact person, then spend more time to extract 3 personal data of local linkages people of 3M, then basis
The personal data of distal end contact person and the personal data of local linkages people carry out personal data synchronization, and flow 5M streams are expended altogether
Amount, expends the electricity for extracting 3M personal data.
According to the scheme of the application, mobile terminal downloads the distal marker letter of 5KB from distal end contact database first
Breath, then the very fast local identification information for extracting 3KB, then determines from distal end according to local identification information and distal marker information
Contact database downloads the corresponding personal data of contact person D and E of 2M, and flow 2M+5KB is expended altogether, expends and extracts 3KB sheets
The electricity of ground identification information.
In the present embodiment, by when detect data syn-chronization instruct when, obtain mobile terminal local contact database according to
The distal end version number of the local version number in storehouse and the distal end contact database of Cloud Server, then when local version number and distal end
When version number is inconsistent, local contact database is write into caching according to the local identification information of each local linkages people in storehouse, and obtain
The distal marker information of each distal end contact person in the contact database of distal end, then compare local identification information and distal marker letter
Breath, to obtain the different information of local linkages people and distal end contact person, finally according to different information from distal end contact database
Correspondence difference contact data is obtained, and realizes that local contact database contacts number according to storehouse and distal end according to difference contact data
According to the personal data synchronization in storehouse, the data syn-chronization of Cloud Server and mobile terminal contact person personal data is realized, even if mobile
Terminal loss or replacing, it is also possible to quickly from contact person's personal data that Cloud Server is synchronously newest, considerably increase user
Experience in contact data migration.Meanwhile, the less different information of data volume is themselves based on, targetedly join from distal end
It is the personal data of personal data storehouse download correspondence distal end contact person, it is to avoid by the contact person number in the contact database of distal end
According to whole downloads, mobile terminal flow is greatlyd save, and mobile terminal is only just carried out when data syn-chronization instruction is detected
Contact data synchronization flow, and local identification information consuming time, occupying system resources need to be extracted much smaller than local linkages people
Personal data, so as to greatly reduce the power consumption of mobile terminal.
Further, in another embodiment of mobile terminal contact person method of data synchronization of the present invention, step S40 includes:
Step S41, is analyzed to different information;
, there is the same key contact person of like-identified according to storehouse and distal end contact database in local contact database in step S42
When, judge whether same key contact person correspondence personal data have modification in local contact database according to storehouse;
Step S43, when same key contact person correspondence personal data have modification in local contact database according to storehouse, if local linkages
Personal data storehouse does not delete this with key contact person with distal end contact database, then merge same key contact person in local contact database
According to storehouse and the personal data of distal end contact database, by merging after same key contact person personal data be updated to local linkages people
Database;
Step S44, when same key contact person correspondence personal data have modification in local contact database according to storehouse, if local linkages
Personal data storehouse is deleted and is not deleted this with key contact person with key contact person, distal end contact database, and with key contact person local
Corresponding personal data in contact database and distal end contact database are differed, then will be same in the contact database of distal end
Key contact person correspondence personal data replace local contact database according in storehouse this with key contact person correspondence personal data;
Step S45, when same key contact person correspondence personal data have modification in local contact database according to storehouse, if local linkages
Personal data storehouse is not deleted same key contact person, distal end contact database and deletes this with key contact person, by local contact database according to storehouse
In with key contact person correspondence personal data as newly-increased locally modified data.
Reference picture 3, after different information of the local linkages people with distal end contact person is obtained, is divided the different information
Analysis, when there is the same key contact person of like-identified according to storehouse DB1 and distal end contact database DB2 in local contact database, and then
Whether on DB1 have modification, wherein like-identified can refer to identical major key, also if judging same key contact person correspondence personal data
It is to say that with key contact person refer to the contact person with identical major key, the contact person A with identical job number such as in DB1 and DB2, that
Contact person A is the same key contact person of DB1 and DB2.
When same key contact person A correspondence personal data have modification in DB1, if DB1 and DB2 does not delete this with key contact person
A, shows there is renewal with the personal data of key contact person A in DB1, continues to retain with the personal data of key contact person A in DB2, table
The former personal data of bright same key contact person A have meaning, so merge the personal data with key contact person A in DB1 and DB2, will
Same key contact person personal data after merging are updated to local contact database according to storehouse.For example, personal in DB2 with key contact person A
Phone number is number 1 in data, and phone number is revised as number 2 in personal data in DB1, then merge number 1 and number
2, so as to the phone number using number 1 and number 2 as same key contact person A in DB1 personal data.Additionally, DB1 and DB2 are deleted
Except contact person A, refer to the contact person A DB1 and DB2 record field addition " deletion " mark, the source data of contact person A according to
So retain in DB1 and DB2.
When same key contact person A correspondence personal data have modification in DB1, if DB1 is deleted not deleted with key contact person A, DB2
This is with key contact person A, and corresponding personal data with key contact person A in DB1 and DB2 are differed, and show that same key contact person A exists
There is modification in DB2, so corresponding to individual with key contact person A by being corresponded to during personal data replace DB1 with key contact person A in DB2
Data, with the synchronization of each contact person's personal data in keeping DB1 and DB2.
When same key contact person A correspondence personal data have modification in DB1, if DB1 does not delete same key contact person A, DB2 and deletes
This shows that same key contact person A is newly-increased in DB1 with key contact person A, so personal data will be corresponded to key contact person A in DB1
As newly-increased locally modified data, added with the same key contact person A personal data that will be increased newly in DB1 based on locally modified data
Into DB2.
When same key contact person A correspondence personal data have modification in DB1, if DB1 and DB2 delete this with key contact person A,
Show that same key contact person A personal data are useless for mobile terminal user, so same key contact person A is not done locating
Reason.
In the present embodiment, there is the same bonded of like-identified according to storehouse and distal end contact database in local contact database
When being people, same key contact person personal data are modified situation according to storehouse in local contact database, based on above-mentioned treatment rule, protected
Card local contact database is timely with contact person's personal data of distal end contact database, accurately synchronous according to storehouse.
Alternatively, judge whether same key contact person correspondence personal data have in local contact database according to storehouse in step S42
Also include after the step of modification:
Step S46, when same key contact person correspondence personal data are not changed in local contact database according to storehouse, if distal end joins
Be that same key contact person is not deleted in personal data storehouse, and with key contact person in local contact database according in storehouse and distal end contact database
Corresponding personal data differ, then will in the contact database of distal end with key contact person correspondence personal data replace local linkages
This is with key contact person correspondence personal data in personal data storehouse;
Step S47, when same key contact person correspondence personal data are not changed in local contact database according to storehouse, if distal end joins
It is that personal data storehouse is deleted with key contact person, then deletes local contact database with key contact person according in storehouse.
Reference picture 3, when during in same key contact person A, correspondingly personal data are in local contact database according to storehouse DB1 without modification, if
Distal end contact database DB2 does not delete same key contact person A, and the corresponding personal data with key contact person A in DB1 and DB2
Differ, show there is renewal relative to DB1 with the personal data of key contact person A in DB2, then will be corresponding with key contact person A in DB2
This realizes the synchronization of contact person's personal data with key contact person A correspondence personal data in personal data replacement DB1.
When same key contact person A correspondence personal data are not changed in DB1, if DB2 is deleted with key contact person A, show cloud
Server actively deletes same key contact person A because of user in the operation of other mobile terminals, is used for mobile terminal with bonded system A
Family is useless, then will be deleted with key contact person A personal data in DB1.
In the present embodiment, there is the same bonded of like-identified according to storehouse and distal end contact database in local contact database
When being people, same key contact person personal data are modified situation according to storehouse in local contact database, based on above-mentioned treatment rule, protected
Card local contact database is timely with contact person's personal data of distal end contact database, accurately synchronous according to storehouse.
Further, in the another embodiment of mobile terminal contact person method of data synchronization of the present invention, after step S41 also
Including:
, there is local contact database in the contact database of distal end according to the different key contact person outside storehouse in step S48, and far
When end contact database does not delete the different key contact person, if local contact database is identical with different key contact person according to not existing in storehouse
The contact person of name, then be added to local contact database according to storehouse by the different key contact person correspondence personal data;If local linkages people
There is the contact person with different key contact person same name in database, then by different key contact person correspondence personal data and same name
Contact person correspondence personal data be incorporated into local contact database according to storehouse.
Reference picture 3, based on different information, if it is determined that there is local contact database according to storehouse in distal end contact database DB2
Different key contact person B outside DB1, shows there is the contact person of different mark in DB1 in DB2, and then judge different key contact person B
Whether there is deletion in DB2;
If without the different key contact person B of deletion in DB2, and the different key contact person B does not exist the contact of same name in DB1
People, shows to identify different name identical contact persons without different major keys, and different key contact person B is non-existent new contact in DB1
People, so different key contact person B correspondence personal data are updated in DB1.
If without the different key contact person B of deletion in DB2, and there is the contact of same name in the different key contact person B in DB1
People, further analyze different key contact person B personal data whether the complete phase of personal data corresponding with same name contact person in DB1
Together;(1) it is different if the personal data of different key contact person B personal data corresponding with same name contact person C in DB1 are incomplete same
The personal data of key contact person B personal data corresponding with same name contact person C in DB1 merge, and same name in DB1 is joined
It is that people C is deleted with different key contact person B identical personal data part;(2) if the personal data and phase in DB1 of different key contact person B
It is identical with name contact person C correspondence personal data, although showing different key contact person B and same name contact person's C primary keys
Know it is inconsistent, but substantially same contact person, by the local identification information of same name contact person C in DB1 (i.e. this landlord
Key is identified) be updated to the distal marker information (i.e. distal end major key mark) of different key contact person B in DB2, such as different key contact person B's
Major key is designated 002, and the major key of same name contact person C is designated 003, then by the primary key of the same name contact person C of DB1
Knowledge is changed to 002.
In the present embodiment, it is further implemented in the contact database of distal end outside there is local contact database according to storehouse
Different key contact person, and distal end contact database do not deleted under the different key contact person scene, local data base and remote data storehouse
Between personal data synchronization, it is ensured that the Cloud Server accuracy synchronous with personal data under multi-mobile-terminal scene, in time
Property and convenience.
Further, on the basis of above-mentioned each embodiment of mobile terminal contact person method of data synchronization, reference picture 7,
Also include after step S40:
Step S50, acquisition local contact database is carried out in data synchronization process according to storehouse and distal end contact database, locally
The locally modified data changed in contact database;
Step S60, by locally modified data is activation to Cloud Server, so that Cloud Server is realized according to locally modified data
Distal end contact database and amended local contact database according to storehouse data syn-chronization.
In local contact database carries out personal data synchronizing process according to storehouse DB1 and distal end contact database DB2, DB1
In each contact person correspondence personal data may exist and the modification operation such as delete, replace, merging, cause right after DB2 and DB1 modifications
The inconsistent situation of contact person's personal data that major key is identified is answered, so obtain that personal data in DB1 change locally repaiies
Change data, in locally modified data at least include personal data change modification type, change contact person's major key identify,
Amended personal data.Then mobile terminal is by locally modified data is activation to Cloud Server, so that Cloud Server is according to this
Ground modification data validation DB1 have modification local linkages people correspondence personal data, and by DB1 in personal data synchronizing process
The local linkages people correspondence personal data for having modification are updated in the DB2 of Cloud Server, so as to keep Cloud Server DB2 and movement
Personal data uniformity between terminal D B1.
Alternatively, also include after step S60:
Step S70, the current distal end version number of Cloud Server, its medium cloud clothes are updated to by the local version number of mobile terminal
Business device updates the distal end of itself after distal end contact database carries out data syn-chronization with amended local contact database according to storehouse
Version number.
For example, before personal data synchronization, the distal end contact database DB2 version numbers of Cloud Server are 1.5, mobile whole
The local contact database at end is 1.3 according to storehouse DB1 version numbers, and after DB2 and DB2 realize that personal data are synchronous, the version number of DB2 is
1.6, and the version number of DB1 is consistent with DB2, i.e. and the DB1 version numbers of mobile terminal are also updated to 1.6.By the present embodiment
Scheme, it is ensured that after personal data renewal is carried out, version number is consistent mobile terminal DB1 with Cloud Server.
It should be noted that herein, term " including ", "comprising" or its any other variant be intended to non-row
His property is included, so that process, method, article or device including a series of key elements not only include those key elements, and
And also include other key elements being not expressly set out, or also include for this process, method, article or device institute are intrinsic
Key element.In the absence of more restrictions, the key element limited by sentence "including a ...", it is not excluded that including this
Also there is other identical element in the process of key element, method, article or device.
The embodiments of the present invention are for illustration only, and the quality of embodiment is not represented.
Through the above description of the embodiments, those skilled in the art can be understood that above-described embodiment side
Method can add the mode of required general hardware platform to realize by software, naturally it is also possible to by hardware, but in many cases
The former is more preferably implementation method.Based on such understanding, technical scheme is substantially done to prior art in other words
The part for going out contribution can be embodied in the form of software product, and the computer software product is stored in a storage medium
In (such as ROM/RAM, magnetic disc, CD), including some instructions are used to so that a station terminal equipment (can be mobile phone, computer, clothes
Business device, air-conditioner, or network equipment etc.) perform method described in each embodiment of the invention.
The preferred embodiments of the present invention are these are only, the scope of the claims of the invention is not thereby limited, it is every to utilize this hair
Equivalent structure or equivalent flow conversion that bright specification and accompanying drawing content are made, or directly or indirectly it is used in other related skills
Art field, is included within the scope of the present invention.
Claims (10)
1. a kind of mobile terminal, it is characterised in that the mobile terminal includes:
First acquisition module, for when data syn-chronization instruction is detected, obtaining the local contact database of mobile terminal according to storehouse
The distal end version number of the distal end contact database of local version number and Cloud Server;
Second acquisition module, for when local version number and distal end version number are inconsistent, by local contact database according to each in storehouse
The local identification information write-in caching of local linkages people, and obtain the distal end mark of each distal end contact person in the contact database of distal end
Knowledge information;
Comparing module, for comparing local identification information and distal marker information, to obtain local linkages people and distal end contact person
Different information;
Synchronization module, difference contact data is corresponded to for being obtained from distal end contact database according to different information, and according to
Difference contact data realizes local contact database according to storehouse and the data syn-chronization of distal end contact database.
2. mobile terminal as claimed in claim 1, it is characterised in that the mobile terminal also includes distal end synchronization module, institute
Stating distal end synchronization module is used for:
Acquisition local contact database is carried out in data synchronization process according to storehouse and distal end contact database, and local contact database is according to storehouse
The middle locally modified data changed;
By locally modified data is activation to Cloud Server, so that Cloud Server realizes that distal end contacts number according to locally modified data
According to storehouse and amended local contact database according to storehouse data syn-chronization.
3. mobile terminal as claimed in claim 1 or 2, it is characterised in that the synchronization module is used for:
The different information is analyzed;
When local contact database has the same key contact person of like-identified according to storehouse and distal end contact database, judge with bonded
It is whether people's correspondence personal data have modification in local contact database according to storehouse;
Same key contact person correspondence personal data have modification according to storehouse in local contact database when, if local contact database according to storehouse with it is remote
End contact database does not delete this with key contact person, then merge same key contact person and join according to storehouse and distal end in local contact database
Be the personal data in personal data storehouse, by merging after same key contact person personal data be updated to local contact database according to storehouse;
When same key contact person correspondence personal data have modification in local contact database according to storehouse, if local contact database deletes according to storehouse
Do not delete this with key contact person with key contact person, distal end contact database, and with key contact person in local contact database according to storehouse
Differed with the corresponding personal data in the contact database of distal end, then will be corresponding with key contact person in the contact database of distal end
Personal data replace local contact database according in storehouse this with key contact person correspondence personal data;
When same key contact person correspondence personal data have modification in local contact database according to storehouse, if local contact database does not delete according to storehouse
Except same key contact person, distal end contact database delete this with key contact person, by local contact database according in storehouse with key contact person
Correspondence personal data are used as newly-increased locally modified data.
4. mobile terminal as claimed in claim 3, it is characterised in that the synchronization module is used for:
When same key contact person correspondence personal data are not changed in local contact database according to storehouse, following steps are performed,
If distal end contact database does not delete same key contact person, and joins according to storehouse and distal end in local contact database with key contact person
Be that corresponding personal data in personal data storehouse are differed, then will be in the contact database of distal end with key contact person correspondence personal data
Replace local contact database according in storehouse this with key contact person correspondence personal data;
If distal end contact database is deleted with key contact person, local contact database is deleted according in storehouse with key contact person.
5. mobile terminal as claimed in claim 3, it is characterised in that the synchronization module is used for:
There is local contact database in the contact database of distal end according to the different key contact person outside storehouse, and distal end contact data
When the different key contact person is not deleted in storehouse, following steps are performed,
If local contact database is according to the contact person not existed in storehouse with different key contact person same name, by the different key contact person couple
Answer personal data added to local contact database according to storehouse;
If local contact database is according to the contact person existed in storehouse with different key contact person same name, by different key contact person correspondence
Personal data personal data corresponding with the contact person of same name are incorporated into local contact database according to storehouse.
6. a kind of mobile terminal contact person method of data synchronization, it is characterised in that the mobile terminal contact person data syn-chronization side
Method includes:
When data syn-chronization instruction is detected, local version number and cloud service of the local contact database of mobile terminal according to storehouse are obtained
The distal end version number of the distal end contact database of device;
When local version number and distal end version number it is inconsistent when, by local contact database according to each local linkages people in storehouse this terrestrial reference
Knowledge information write-in caching, and obtain the distal marker information of each distal end contact person in the contact database of distal end;
Local identification information and distal marker information are compared, to obtain the different information of local linkages people and distal end contact person;
Correspondence difference contact data is obtained from distal end contact database according to different information, and according to difference contact data
Realize local contact database according to storehouse and the data syn-chronization of distal end contact database.
7. mobile terminal contact person method of data synchronization as claimed in claim 6, it is characterised in that described according to different information
Correspondence difference contact data is obtained from distal end contact database, and local contact database is realized according to difference contact data
According to storehouse and distal end contact database data syn-chronization the step of after also include:
Acquisition local contact database is carried out in data synchronization process according to storehouse and distal end contact database, and local contact database is according to storehouse
The middle locally modified data changed;
By locally modified data is activation to Cloud Server, so that Cloud Server realizes that distal end contacts number according to locally modified data
According to storehouse and amended local contact database according to storehouse data syn-chronization.
8. mobile terminal contact person method of data synchronization as claimed in claims 6 or 7, it is characterised in that described according to difference
Information obtains correspondence difference contact data from distal end contact database, and realizes local linkages according to difference contact data
The step of data syn-chronization of personal data storehouse and distal end contact database, includes:
The different information is analyzed;
When local contact database has the same key contact person of like-identified according to storehouse and distal end contact database, judge with bonded
It is whether people's correspondence personal data have modification in local contact database according to storehouse;
When same key contact person correspondence personal data have modification in local contact database according to storehouse, following steps are performed,
If local contact database does not delete this with key contact person according to storehouse and distal end contact database, merge same key contact person
In local contact database according to storehouse and the personal data of distal end contact database, by merging after same key contact person personal data more
Newly to local contact database according to storehouse;
If local contact database deletes according to storehouse and does not delete this with key contact person with key contact person, distal end contact database, and together
Key contact person differs in local contact database according to the corresponding personal data in storehouse and distal end contact database, then join distal end
It is with key contact person correspondence personal data to replace local contact database in personal data storehouse this is personal with key contact person correspondence according in storehouse
Data;
If local contact database does not delete same key contact person, distal end contact database and deletes this with key contact person according to storehouse, incite somebody to action this
With key contact person correspondence personal data as newly-increased locally modified data in ground contact database.
9. mobile terminal contact person method of data synchronization as claimed in claim 8, it is characterised in that in the judgement with bonded
It is that people's correspondence personal data also include after the step of whether local contact database has modification according to storehouse:
When same key contact person correspondence personal data are not changed in local contact database according to storehouse, following steps are performed,
If distal end contact database does not delete same key contact person, and joins according to storehouse and distal end in local contact database with key contact person
Be that corresponding personal data in personal data storehouse are differed, then will be in the contact database of distal end with key contact person correspondence personal data
Replace local contact database according in storehouse this with key contact person correspondence personal data;
If distal end contact database is deleted with key contact person, local contact database is deleted according in storehouse with key contact person.
10. mobile terminal contact person method of data synchronization as claimed in claim 8, it is characterised in that described to the difference
Also include after the step of information is analyzed:
There is local contact database in the contact database of distal end according to the different key contact person outside storehouse, and distal end contact data
When the different key contact person is not deleted in storehouse, following steps are performed,
If local contact database is according to the contact person not existed in storehouse with different key contact person same name, by the different key contact person couple
Answer personal data added to local contact database according to storehouse;
If local contact database is according to the contact person existed in storehouse with different key contact person same name, by different key contact person correspondence
Personal data personal data corresponding with the contact person of same name are incorporated into local contact database according to storehouse.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710204375.3A CN106899734A (en) | 2017-03-30 | 2017-03-30 | Mobile terminal and mobile terminal contact person method of data synchronization |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710204375.3A CN106899734A (en) | 2017-03-30 | 2017-03-30 | Mobile terminal and mobile terminal contact person method of data synchronization |
Publications (1)
Publication Number | Publication Date |
---|---|
CN106899734A true CN106899734A (en) | 2017-06-27 |
Family
ID=59194201
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201710204375.3A Pending CN106899734A (en) | 2017-03-30 | 2017-03-30 | Mobile terminal and mobile terminal contact person method of data synchronization |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106899734A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110401709A (en) * | 2019-07-23 | 2019-11-01 | 北京云中融信网络科技有限公司 | Processing method, device and the storage medium of session in a kind of instant messaging application |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2010048324A1 (en) * | 2008-10-21 | 2010-04-29 | Google Inc. | Always ready client/server data synchronization |
CN105635215A (en) * | 2014-11-04 | 2016-06-01 | 阿里巴巴集团控股有限公司 | Contact information synchronization method and device and cloud server |
CN105847336A (en) * | 2016-03-18 | 2016-08-10 | 周奇 | Address book synchronization method and device |
CN105872168A (en) * | 2015-11-09 | 2016-08-17 | 乐视致新电子科技(天津)有限公司 | Address list update method and device |
CN105915636A (en) * | 2016-06-03 | 2016-08-31 | 青岛海信移动通信技术股份有限公司 | Contact person information synchronization method and apparatus thereof |
-
2017
- 2017-03-30 CN CN201710204375.3A patent/CN106899734A/en active Pending
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2010048324A1 (en) * | 2008-10-21 | 2010-04-29 | Google Inc. | Always ready client/server data synchronization |
CN105635215A (en) * | 2014-11-04 | 2016-06-01 | 阿里巴巴集团控股有限公司 | Contact information synchronization method and device and cloud server |
CN105872168A (en) * | 2015-11-09 | 2016-08-17 | 乐视致新电子科技(天津)有限公司 | Address list update method and device |
CN105847336A (en) * | 2016-03-18 | 2016-08-10 | 周奇 | Address book synchronization method and device |
CN105915636A (en) * | 2016-06-03 | 2016-08-31 | 青岛海信移动通信技术股份有限公司 | Contact person information synchronization method and apparatus thereof |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110401709A (en) * | 2019-07-23 | 2019-11-01 | 北京云中融信网络科技有限公司 | Processing method, device and the storage medium of session in a kind of instant messaging application |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN104423703B (en) | For showing the electronic equipment and method of application message | |
US8893054B2 (en) | Devices, systems, and methods for conveying gesture commands | |
CN104536848B (en) | Firmware restoration method, apparatus and terminal | |
WO2019080929A1 (en) | Message prompting method and mobile terminal | |
CN109690479B (en) | Method and device for associating notification message and mobile terminal | |
CN107330035A (en) | Operation Log synchronous method, mobile terminal and computer-readable recording medium in a kind of database | |
CN104104768A (en) | Apparatus and method for providing additional information by using caller phone number | |
CN114827914B (en) | Short message processing method and device and electronic equipment | |
CN110286980A (en) | A kind of schedule creation method and mobile terminal | |
CN107977248B (en) | Display method of desktop pendant and mobile terminal | |
US11861158B2 (en) | Message processing method and electronic device | |
CN105739820A (en) | Message prompt display method and device | |
WO2019174441A1 (en) | Application update method and mobile terminal | |
CN108200287B (en) | Information processing method, terminal and computer readable storage medium | |
CN109697262A (en) | A kind of information display method and device | |
CN109840125A (en) | A kind of terminal control method, terminal and computer readable storage medium | |
CN109254972A (en) | A kind of offline order Word library updating method, terminal and computer readable storage medium | |
CN103634461A (en) | Mobile terminal and control method thereof | |
CN107766517A (en) | A kind of acquisition methods of view data, device and mobile terminal | |
CN107766505A (en) | A kind of file management method and terminal | |
CN106572230A (en) | Device and method for recording calls | |
WO2019052436A1 (en) | Image processing method, computer-readable storage medium and mobile terminal | |
CN103618834A (en) | Displaying method for short message reminding and mobile terminal | |
CN107819937A (en) | A kind of memo information based reminding method and device, terminal and readable storage medium storing program for executing | |
CN106899734A (en) | Mobile terminal and mobile terminal contact person method of data synchronization |
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 | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20170627 |
|
RJ01 | Rejection of invention patent application after publication |