Home | History | Annotate | Download | only in provider

Lines Matching defs:BODY

86 import com.android.emailcommon.provider.EmailContent.Body;
281 private static final int BODY = BODY_BASE;
305 array.put(BODY_BASE >> BASE_SHIFT, Body.TABLE_NAME);
335 "select " + BodyColumns.MESSAGE_KEY + " from " + Body.TABLE_NAME +
338 private static final String DELETE_ORPHAN_BODIES = "delete from " + Body.TABLE_NAME +
341 private static final String DELETE_BODY = "delete from " + Body.TABLE_NAME +
636 // body database is already attached to the email database and any attempt to use the
637 // body database directly will result in a SQLiteException (the database is locked)
685 // Handle lost Body records here, since this cannot be done in a trigger
744 case BODY:
766 // Delete the Body record associated with the deleted message
775 // Delete any orphaned Body records
816 return "vnd.android.cursor.item/email-body";
817 case BODY:
818 return "vnd.android.cursor.dir/email-body";
912 case BODY:
918 longId = db.insert(Body.TABLE_NAME, "foo", dbValues);
921 // This will look less ugly once the body table is folded into the message table
925 "Cannot insert body without MESSAGE_KEY");
928 // Ensure that no pre-existing body files contaminate the message
1149 sURIMatcher.addURI(EmailContent.AUTHORITY, "body", BODY);
1150 // A specific mail body
1151 sURIMatcher.addURI(EmailContent.AUTHORITY, "body/#", BODY_ID);
1152 // A specific HTML body part, for openFile
1154 // A specific text body part, for openFile
1386 case BODY:
1394 "Body content cannot be returned in the cursor");
1404 sb.append(" FROM ").append(Body.TABLE_NAME);
2134 " from " + Body.TABLE_NAME +
2144 case BODY: {
2151 if (result == 0 && selection.equals(Body.SELECTION_BY_MESSAGE_KEY)) {
2154 LogUtils.i(TAG, "Body Update to non-existent row, morphing to insert");
2157 insert(Body.CONTENT_URI, insertValues);
2159 // possibly need to write new body values
2169 " from " + Body.TABLE_NAME +
2176 final Cursor c = db.query(Body.TABLE_NAME, proj,
2182 throw new IllegalStateException("Can't find body record");
2325 * @param messageId id of message to write body for
2328 * associated text or html body file
2338 throw new IllegalStateException("IOException while writing html body " +
2347 throw new IllegalStateException("IOException while writing text body " +
2354 * Writes a message body file to disk
2357 * @param messageId id of message to write body for
2359 * @param content Body content to write to file, or null/empty to delete file
2367 LogUtils.v(LogUtils.TAG, "did not delete text body for %d", messageId);
2380 * Returns a {@link java.io.File} object pointing to the body content file for the message
2395 "body/" + Long.toString(l1) + "/" + Long.toString(l2) + "/");
2397 throw new FileNotFoundException("Could not create directory for body file");
3074 Body body = Body.restoreBodyWithMessageId(context, messageId);
3075 if (body != null) {
3076 if (body.mHtmlContent != null) {
3077 if (IMG_TAG_START_REGEX.matcher(body.mHtmlContent).find()) {
3149 sb.append(" FROM " + Message.TABLE_NAME + " LEFT JOIN " + Body.TABLE_NAME +
4989 // Delete the body
4990 ops.add(ContentProviderOperation.newDelete(Body.CONTENT_URI)
4994 // Add the ops for the message, atts, and body