Source:
<code>private ContactDataBuilder extractContactData(ContactDataBuilder builder, long contactId, Cursor cursor) { final ColumnProcessors processors = new ColumnProcessors(); final ColumnProcessor<LabelType> labelTypeProcessor = processors.forMappedEnum(LabelType.class, LabelType.values()); builder.setContactId(contactId); builder.setPhotoId(processors.forInteger().extract(cursor, Column.PHOTO_ID)); String mimeType = processors.forString().extract(cursor, Column.MIMETYPE); String data = processors.forString().extract(cursor, Column.DATA1); int isPrimary = processors.forInteger().extract(cursor, Column.IS_PRIMARY); if (mimeType.equals(Email.CONTENT_ITEM_TYPE)) { builder.addEmailId(data); } else if (mimeType.equals(Phone.CONTENT_ITEM_TYPE)) { LabelType labelType = labelTypeProcessor.extract(cursor, Column.DATA2); <START> if (labelType == null) { <END> labelType = LabelType.Other; } builder.addPhoneNumber(new ContactNumber(data, isPrimary > 0 ? true : false, labelType)); } else if (mimeType.equals(StructuredName.CONTENT_ITEM_TYPE)) { PersonNameDataBuilder nameBuilder = new PersonNameDataBuilder(); nameBuilder.setDisplayName(data); nameBuilder.setGivenName(processors.forString().extract(cursor, Column.DATA2)); nameBuilder.setFamilyName(processors.forString().extract(cursor, Column.DATA3)); nameBuilder.setPrefix(processors.forString().extract(cursor, Column.DATA4)); nameBuilder.setMiddleName(processors.forString().extract(cursor, Column.DATA5)); nameBuilder.setSuffix(processors.forString().extract(cursor, Column.DATA6)); builder.setName(nameBuilder); } return builder; }</code><technical_language>If label Type is null need set null. I EnumColumnProcessor that. need do is change MappedEnumColumnProcessor in a default is set parsed - throw a ParseException stand today</technical_language>

Target:
private ContactDataBuilder extractContactData(ContactDataBuilder builder, long contactId, Cursor cursor) { final ColumnProcessors processors = new ColumnProcessors(); final ColumnProcessor<ContactLabel> labelTypeProcessor = processors.forMappedEnum(ContactLabel.class, ContactLabel.values()); builder.setContactId(contactId); builder.setPhotoId(processors.forInteger().extract(cursor, Column.PHOTO_ID)); String mimeType = processors.forString().extract(cursor, Column.MIMETYPE); String data = processors.forString().extract(cursor, Column.DATA1); int isPrimary = processors.forInteger().extract(cursor, Column.IS_PRIMARY); if (mimeType.equals(Email.CONTENT_ITEM_TYPE)) { builder.addEmailId(data); } else if (mimeType.equals(Phone.CONTENT_ITEM_TYPE)) { ContactLabel labelType = labelTypeProcessor.extract(cursor, Column.DATA2); builder.addPhoneNumber(new ContactNumber(data, isPrimary > 0 ? true : false, labelType)); } else if (mimeType.equals(StructuredName.CONTENT_ITEM_TYPE)) { PersonNameDataBuilder nameBuilder = new PersonNameDataBuilder(); nameBuilder.setDisplayName(data); nameBuilder.setGivenName(processors.forString().extract(cursor, Column.DATA2)); nameBuilder.setFamilyName(processors.forString().extract(cursor, Column.DATA3)); nameBuilder.setPrefix(processors.forString().extract(cursor, Column.DATA4)); nameBuilder.setMiddleName(processors.forString().extract(cursor, Column.DATA5)); nameBuilder.setSuffix(processors.forString().extract(cursor, Column.DATA6)); builder.setName(nameBuilder); } return builder; }