summaryrefslogtreecommitdiffstats
path: root/core/java/android/pim/vcard
Commit message (Collapse)AuthorAgeFilesLines
* Make VCardComposer create the instance for mHandlerList.Daisuke Miyakawa2009-10-061-4/+2
| | | | | | | | | | | Previously the creation was delayed until addHandler(), which had been required to be called. However, after VCardComoser's support toward PBAP stuffs, the guarantee was not true any more. So by creating the instance in constructor, we refrain NPE during finalize() when PBAP uses VCardComposer.
* show events in the UIFred Quintana2009-09-302-7/+12
|
* Make ContactStruct handle Collection properly.Daisuke Miyakawa2009-09-301-1/+2
| | | | Internal Issue number: 2157922
* Fix vCard composer in three points.Daisuke Miyakawa2009-09-302-75/+249
| | | | | | | - Make it allow composer users to emit Quoted-Printabled primary ("N", "FN", etc.) properties. - Make it strictly check whether it is necessary for the composer to emit CHARSET infomation. -- Added the logic "not vCard 3.0, or, CHARSET is not UTF-8". - Clean up the code (again...)
* Remove GAIA stringCostin Manolache2009-09-291-1/+1
|
* Clean up vCard code.Daisuke Miyakawa2009-09-293-234/+376
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With this change, the vCard composer does not emit any information about CHARSET until it is really needed for parsing it (e.g. when non-ascii chacacters are included in some value). This "may" be effective toward external vCard importers which are not able to understand non-ascii characters and CHARSET info itself. Also now vCard composer does not use Quoted Printable until it is really needed (e.g. until when the composer find non-"7bit" characters are included in some value. "7bit" is defined in vCard 2.1, which is "<7bit us-ascii printable chars, excluding CR LF>". The vCard composer detects duplicate phone numbers, email addresses, and remove them in default. The duplication would come from aggregation done by the new ContactsProvider introduced in Eclair. Even when two Accounts have two exactly same addresses, we cannot ask ContactsProvider to exclude them since current implementation of ContactsProvider2#queryEntities() does not acceps Contacts.CONTENT_URI but only RawContacts.CONTENT_URI, which inevitably returns same email addresses with different Accounts (ACCOUNT_NAME and ACCOUNT_TYPE should be different. If not, the original contact itself should have the duplication). The vCard composer now detects null returned from queryEntities(). The null value is potentially harmful for vCard file, since it forces the (old) vCard composer to emit meaningless line like "BDAY:". Internal Issue number: 2150768, 2151954, 2154235
* Three changes.Daisuke Miyakawa2009-09-281-20/+36
| | | | | | | | | | | - Add FOR_EXPORT_ONLY to Data column. - Make VCardComposer use Contacts instead of RawContacts. - Make VCardComposer honor FOR_CONTACT_ONLY regardless of the intention of any caller, which makes composer unable to compose any contact with "is_restricted" flag, which is unseen from outside the contacts provider. Internal Issue number: 2147248, 2143207
* Two changes toward vCard composer.Daisuke Miyakawa2009-09-251-29/+40
| | | | | | | | - Separate the two cases: mCursor == null and mCursor.getCount() == 0. - Make error messages viewable from user applications, which enables them to translate those messages. Internal issue number: 2138187, 27103
* fix typoFred Quintana2009-09-241-1/+1
|
* rename misc to birthdayFred Quintana2009-09-242-9/+11
|
* Add "TYPE=" to type attribute when appropriate.Daisuke Miyakawa2009-09-241-140/+184
| | | | Internal issue number: 2142140
* Add appendType() utility method.Daisuke Miyakawa2009-09-241-43/+48
| | | | Some fix toward coll history related code is included.
* Add final to appropriate variables.Daisuke Miyakawa2009-09-241-13/+13
|
* Fix vCard code.Daisuke Miyakawa2009-09-242-19/+118
|
* Add call log support to pim.vcard.VCardComposerLixin Yue2009-09-241-38/+202
| | | | Change-Id: I6573b22aa42d60720b93d0f4c3b03fb8213208f2
* Make ContactStruct explicitly set RawContacts.ACCOUNT_NAME and ↵Daisuke Miyakawa2009-09-231-4/+5
| | | | | | | | | | | | RawContacts.ACCOUNT_TYPE to null. Contacts app's EditContactActivity now explicitly set those to null, so I thought vCard importer also shold do so. Internal issue number: 2141766 TODO: Contacts app's side should be also modified to completely fix the issue above.
* Suppress Performance log emitted by vCard importer.Daisuke Miyakawa2009-09-221-1/+1
|
* Add Website.TYPE information.Daisuke Miyakawa2009-09-221-1/+4
| | | | Related internal issue number: 2131626
* Add each contact in vCard into "My Groups" if account is for Google's and it ↵Daisuke Miyakawa2009-09-171-0/+34
| | | | | | | | has such a group. This fix should be temporal. Should be fixed in the near future. Internal issue id: 2126265
* Make vCard importer code use Account information if possible.Daisuke Miyakawa2009-09-152-11/+28
| | | | Internal isssue: 2116216, 2102720
* Handle cases where TYPE can be undefined, such as EAS.Jeff Sharkey2009-09-092-30/+35
| | | | | When TYPE not provided, assume a default value and check that label isn't empty when CUSTOM is used.
* Fix small bugs in VCardComposer.java.Daisuke Miyakawa2009-09-072-6/+17
| | | | | | - The logic for emitting "FN" is wrong. - FileWriter's "double close" problem should occur in the current implementation. - Let VCardParser_V31.java ignore AGENT field instead of throwing an unkind VCardNotSupportedException.
* Make vCard composer handle null of Photo entry correctly.Daisuke Miyakawa2009-09-011-0/+3
| | | | Internal bug id: 2088922
* Use Email.TYPE_MOBILEDaisuke Miyakawa2009-09-011-5/+1
|
* Refactor VCard handling code, phase 2, 3, 4, 5Daisuke Miyakawa2009-08-2510-905/+3344
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Phase 2 Make VCard Importer use Data structures in ContactsContract instead of using old Conatacts structure. Phase 3 Developed VCardComposer, which was originally in Contacts package, but now in base/core/java. Also made it use queryEntries() as per jsharkey's suggestion. Phase 4 Added VCardUtils and moved some common methods to it, some of which should be in public API, but hidden for now. Phase 5 Made VCardComposer emits (almost) valid vCard 3.0 data. Confirmed with vCard data emitted by Mac. Related issue: 1784580, 1728351, 1967349 Note: Probable next step: - Add "fast parse" mode in VCradBuilder, in which, VCardBuilder skip parsing the value of each property. It will make the parsing faster. -- Note that parsing the parameters of each entry cannot be skipped, since it may contains the information about Encoding of the property. In other words, if the line is in Quoted-Printable format, the next line may be the part of the property, not a separated property, which should be parsed accordingly. - Needs test
* Refactor VCard-related code.Daisuke Miyakawa2009-07-1718-0/+3583
Move VCard code from android/syncml/pim to android/pim since the code is not related to SyncML at all; Previous code was misplaced, I suppose. Reorganize "Builder" structure: Create VCardBuilderBase.java as a base class for "Builder" classes. Separate VCardDataBuilder to several components. Now, VCardBuilder is able to accept EntryHandlers (interface) which handle each VCard entry. Add EntriCommitter and ProgressShower as ones of EntryHandler implementations. Stop using VNode/PropertyNode in the actual importing path. Instead, VCard importer directly creates ContactStruct object. PropertyNode is still used in test codes, since it does not drop any kind of information while ContactStruct does. All codes are made hidden (with package.html) like the files in syncml directory; These files are only for Contacts app. Issue - due to internal issue 1975498, any performance test cannot be conducted. Next todos - Add tests for ContactStruct. - remove android/syncml directory. - Rename several methods; old names are based on V??? structure, which does not make sense in the current code. - Use ContentProviderOperation instead of relying on beginTransaction()/endTransaction(). - Use ContactsContact in Eclair Related internal issues - 1784580, 1728351