Searched refs:mimeType (Results 1 - 25 of 108) sorted by relevance

12345

/packages/apps/Contacts/src/com/android/contacts/quickcontact/
H A DActionMultiMap.java27 public void put(String mimeType, Action info) { argument
28 put(mimeType, info, false);
32 * Puts the (mimeType,Action) tuple into the multimap at the front if
35 public void put(String mimeType, Action info, boolean front) { argument
37 ArrayList<Action> collectList = get(mimeType);
42 put(mimeType, collectList);
H A DQuickContactActivity.java323 private boolean isMimeExcluded(String mimeType) { argument
326 if (TextUtils.equals(excludedMime, mimeType)) {
354 final String mimeType = dataItem.getMimeType();
357 .getKindOrFallback(accountType, mimeType);
360 if (isMimeExcluded(mimeType)) continue;
374 if (isSuperPrimary || (isPrimary && (mDefaultsMap.get(mimeType) == null))) {
375 mDefaultsMap.put(mimeType, action);
409 for (String mimeType : LEADING_MIMETYPES) {
410 if (containedTypes.contains(mimeType)) {
411 mSortedActionMimeTypes.add(mimeType);
472 inflateAction(String mimeType, ResolveCache resolveCache, ViewGroup root, String name) argument
[all...]
/packages/apps/Contacts/src/com/android/contacts/model/dataitem/
H A DDataItem.java56 final String mimeType = values.getAsString(Data.MIMETYPE);
57 if (GroupMembership.CONTENT_ITEM_TYPE.equals(mimeType)) {
59 } else if (StructuredName.CONTENT_ITEM_TYPE.equals(mimeType)) {
61 } else if (Phone.CONTENT_ITEM_TYPE.equals(mimeType)) {
63 } else if (Email.CONTENT_ITEM_TYPE.equals(mimeType)) {
65 } else if (StructuredPostal.CONTENT_ITEM_TYPE.equals(mimeType)) {
67 } else if (Im.CONTENT_ITEM_TYPE.equals(mimeType)) {
69 } else if (Organization.CONTENT_ITEM_TYPE.equals(mimeType)) {
71 } else if (Nickname.CONTENT_ITEM_TYPE.equals(mimeType)) {
73 } else if (Note.CONTENT_ITEM_TYPE.equals(mimeType)) {
118 setMimeType(String mimeType) argument
[all...]
/packages/apps/Browser/src/com/android/browser/
H A DFetchUrlMimeType.java88 String mimeType = null;
98 mimeType = header.getValue();
99 final int semicolonIndex = mimeType.indexOf(';');
101 mimeType = mimeType.substring(0, semicolonIndex);
117 if (mimeType != null) {
118 if (mimeType.equalsIgnoreCase("text/plain") ||
119 mimeType.equalsIgnoreCase("application/octet-stream")) {
124 mimeType = newMimeType;
129 mimeType);
[all...]
/packages/apps/Email/src/org/apache/james/mime4j/field/
H A DContentTypeField.java71 private String mimeType = ""; field in class:ContentTypeField
75 protected ContentTypeField(String name, String body, String raw, String mimeType, Map<String, String> parameters, ParseException parseException) { argument
77 this.mimeType = mimeType;
96 return mimeType;
190 * @param mimeType the MIME type to match against.
194 public boolean isMimeType(String mimeType) { argument
195 return this.mimeType.equalsIgnoreCase(mimeType);
205 return mimeType
[all...]
/packages/apps/Email/tests/src/com/android/emailcommon/mail/
H A DMessageTestUtils.java72 * @param mimeType MIME type of body part
77 public static BodyPart bodyPart(String mimeType, String contentId) throws MessagingException { argument
78 final MimeBodyPart bp = new MimeBodyPart(null, mimeType);
88 * @param mimeType MIME type of text
93 public static BodyPart textPart(String mimeType, String text) throws MessagingException { argument
96 textPart.setHeader(MimeHeader.HEADER_CONTENT_TYPE, mimeType);
114 * @param mimeType MIME type of this Multipart
116 public MultipartBuilder(String mimeType) { argument
117 this(mimeType, "this_is_boundary");
123 * @param mimeType MIM
126 MultipartBuilder(String mimeType, String boundary) argument
[all...]
/packages/apps/Gallery/src/com/android/camera/gallery/
H A DDrmImageList.java62 long miniThumbMagic, String mimeType, long dateTaken,
65 mimeType, dateTaken, title, rotation);
100 String mimeType = cursor.getString(INDEX_MIME_TYPE);
102 contentUri(id), dataPath, 0, mimeType, 0, "DrmImage-" + id,
60 DrmImage(BaseImageList container, ContentResolver cr, long id, int index, Uri uri, String dataPath, long miniThumbMagic, String mimeType, long dateTaken, String title, int rotation) argument
H A DImage.java47 String mimeType, long dateTaken, String title,
50 mimeType, dateTaken, title);
71 String mimeType = getMimeType();
72 return !"image/jpeg".equals(mimeType) && !"image/png".equals(mimeType);
45 Image(BaseImageList container, ContentResolver cr, long id, int index, Uri uri, String dataPath, String mimeType, long dateTaken, String title, int rotation) argument
/packages/apps/Launcher2/src/com/android/launcher2/
H A DPendingAddItemInfo.java63 String mimeType; field in class:PendingAddWidgetInfo
77 mimeType = dataMimeType;
92 mimeType = copy.mimeType;
/packages/apps/Gallery2/gallerycommon/src/com/android/gallery3d/common/
H A DBitmapUtils.java248 public static boolean isSupportedByRegionDecoder(String mimeType) { argument
249 if (mimeType == null) return false;
250 mimeType = mimeType.toLowerCase();
251 return mimeType.startsWith("image/") &&
252 (!mimeType.equals("image/gif") && !mimeType.endsWith("bmp"));
255 public static boolean isRotationSupported(String mimeType) { argument
256 if (mimeType == null) return false;
257 mimeType
[all...]
/packages/apps/ContactsCommon/src/com/android/contacts/common/model/dataitem/
H A DDataKind.java44 public String mimeType; field in class:DataKind
91 public DataKind(String mimeType, int titleRes, int weight, boolean editable) { argument
92 this.mimeType = mimeType;
109 sb.append(" mimeType=").append(mimeType);
/packages/apps/Email/src/org/apache/james/mime4j/
H A DBodyDescriptor.java35 private String mimeType = "text/plain"; field in class:BodyDescriptor
58 mimeType = "message/rfc822";
60 mimeType = "text/plain";
126 mimeType = main;
321 public boolean isMimeType(String mimeType) { argument
322 return this.mimeType.equals(mimeType.toLowerCase());
329 return mimeType.equals("message/rfc822");
336 return mimeType.startsWith("multipart/");
343 return mimeType;
[all...]
/packages/providers/DownloadProvider/src/com/android/providers/downloads/
H A DOpenHelper.java53 String mimeType = getCursorString(cursor, COLUMN_MEDIA_TYPE);
54 mimeType = DownloadDrmHelper.getOriginalMimeType(context, file, mimeType);
59 if ("application/vnd.android.package-archive".equals(mimeType)) {
61 intent.setDataAndType(localUri, mimeType);
70 ContentUris.withAppendedId(ALL_DOWNLOADS_CONTENT_URI, id), mimeType);
72 intent.setDataAndType(localUri, mimeType);
H A DDownloadScanner.java51 public final String mimeType; field in class:DownloadScanner.ScanRequest
54 public ScanRequest(long id, String path, String mimeType) { argument
57 this.mimeType = mimeType;
62 conn.scanFile(path, mimeType);
H A DHelpers.java76 String mimeType,
88 base = storageManager.locateDestinationDirectory(mimeType, destination,
94 if (DownloadDrmHelper.isDrmConvertNeeded(mimeType)) {
97 path = getFullPath(path, mimeType, destination, base);
101 static String getFullPath(String filename, String mimeType, int destination, File base) argument
118 extension = chooseExtensionFromMimeType(mimeType, true);
120 extension = chooseExtensionFromFilename(mimeType, destination, filename, dotIndex);
230 private static String chooseExtensionFromMimeType(String mimeType, boolean useDefaults) { argument
232 if (mimeType != null) {
233 extension = MimeTypeMap.getSingleton().getExtensionFromMimeType(mimeType);
70 generateSaveFile( Context context, String url, String hint, String contentDisposition, String contentLocation, String mimeType, int destination, long contentLength, StorageManager storageManager) argument
268 chooseExtensionFromFilename(String mimeType, int destination, String filename, int lastDotIndex) argument
[all...]
/packages/apps/Contacts/src/com/android/contacts/model/
H A DRawContactDelta.java155 public ValuesDelta getPrimaryEntry(String mimeType) { argument
156 final ArrayList<ValuesDelta> mimeEntries = getMimeEntries(mimeType, false);
173 public ValuesDelta getSuperPrimaryEntry(String mimeType) { argument
174 return getSuperPrimaryEntry(mimeType, true);
184 public ValuesDelta getSuperPrimaryEntry(String mimeType, boolean forceSelection) { argument
185 final ArrayList<ValuesDelta> mimeEntries = getMimeEntries(mimeType, false);
246 private ArrayList<ValuesDelta> getMimeEntries(String mimeType, boolean lazyCreate) { argument
247 ArrayList<ValuesDelta> mimeEntries = mEntries.get(mimeType);
250 mEntries.put(mimeType, mimeEntries);
255 public ArrayList<ValuesDelta> getMimeEntries(String mimeType) { argument
259 getMimeEntriesCount(String mimeType, boolean onlyVisible) argument
272 hasMimeEntries(String mimeType) argument
[all...]
/packages/apps/Gallery2/tests/src/com/android/photos/data/
H A DPhotoDatabaseTest.java119 String mimeType = "test/test";
127 assertFalse(PhotoDatabaseUtils.insertPhoto(db, null, height, dateTaken, null, mimeType,
131 assertFalse(PhotoDatabaseUtils.insertPhoto(db, width, null, dateTaken, null, mimeType,
135 assertFalse(PhotoDatabaseUtils.insertPhoto(db, width, height, null, null, mimeType,
140 mimeType, null));
143 assertTrue(PhotoDatabaseUtils.insertPhoto(db, width, height, dateTaken, null, mimeType,
154 final String mimeType = "test/test";
155 PhotoDatabaseUtils.insertPhoto(db, 100, 100, 100L, PARENT_ID1, mimeType, 100L);
190 final String mimeType = "test/test";
191 assertTrue(PhotoDatabaseUtils.insertPhoto(db, 100, 100, 100L, PARENT_ID1, mimeType,
[all...]
/packages/apps/Gallery2/src/com/android/gallery3d/data/
H A DUriSource.java75 String mimeType = getMimeType(uri);
79 && mimeType.startsWith(IMAGE_TYPE_PREFIX))) {
80 type = mimeType;
/packages/apps/Tag/src/com/android/apps/tag/record/
H A DImageRecord.java54 String mimeType = record.toMimeType();
55 if (mimeType == null) {
58 Preconditions.checkArgument(mimeType.startsWith("image/"));
/packages/apps/Mms/src/com/android/mms/drm/
H A DDrmUtils.java40 public static boolean isDrmType(String mimeType) { argument
45 if (drmManagerClient.canHandle("", mimeType)) {
/packages/apps/Exchange/exchange2/tests/src/com/android/exchange/adapter/
H A DEmailSyncAdapterTests.java62 String mimeType = p.getMimeTypeFromFileName("foo.jpg");
63 assertEquals("image/jpeg", mimeType);
65 mimeType = p.getMimeTypeFromFileName("foo.JPG");
66 assertEquals("image/jpeg", mimeType);
67 mimeType = p.getMimeTypeFromFileName("this_is_a_weird_filename.gif");
68 assertEquals("image/gif", mimeType);
70 mimeType = p.getMimeTypeFromFileName("foo.");
71 assertEquals("application/octet-stream", mimeType);
73 mimeType = p.getMimeTypeFromFileName(".....");
74 assertEquals("application/octet-stream", mimeType);
[all...]
/packages/apps/Exchange/tests/src/com/android/exchange/adapter/
H A DEmailSyncAdapterTests.java62 String mimeType = p.getMimeTypeFromFileName("foo.jpg");
63 assertEquals("image/jpeg", mimeType);
65 mimeType = p.getMimeTypeFromFileName("foo.JPG");
66 assertEquals("image/jpeg", mimeType);
67 mimeType = p.getMimeTypeFromFileName("this_is_a_weird_filename.gif");
68 assertEquals("image/gif", mimeType);
70 mimeType = p.getMimeTypeFromFileName("foo.");
71 assertEquals("application/octet-stream", mimeType);
73 mimeType = p.getMimeTypeFromFileName(".....");
74 assertEquals("application/octet-stream", mimeType);
[all...]
/packages/apps/Email/emailcommon/src/com/android/emailcommon/internet/
H A DMimeBodyPart.java52 public MimeBodyPart(Body body, String mimeType) throws MessagingException { argument
53 if (mimeType != null) {
54 setHeader(MimeHeader.HEADER_CONTENT_TYPE, mimeType);
134 public boolean isMimeType(String mimeType) throws MessagingException { argument
135 return getMimeType().equals(mimeType);
H A DMimeUtility.java217 public static Part findFirstPartByMimeType(Part part, String mimeType) argument
223 Part ret = findFirstPartByMimeType(bodyPart, mimeType);
229 else if (part.getMimeType().equalsIgnoreCase(mimeType)) {
264 String mimeType = part.getMimeType();
265 if (mimeType != null && MimeUtility.mimeTypeMatches(mimeType, "text/*")) {
319 * Returns true if the given mimeType matches the matchAgainst specification. The comparison
322 * @param mimeType A MIME type to check.
324 * @return true if the mimeType matches
326 public static boolean mimeTypeMatches(String mimeType, Strin argument
341 mimeTypeMatches(String mimeType, String[] matchAgainst) argument
[all...]
/packages/experimental/LoaderApp/src/com/android/loaderapp/model/
H A DEntityDelta.java150 public ValuesDelta getPrimaryEntry(String mimeType) { argument
151 final ArrayList<ValuesDelta> mimeEntries = getMimeEntries(mimeType, false);
168 public ValuesDelta getSuperPrimaryEntry(String mimeType) { argument
169 return getSuperPrimaryEntry(mimeType, true);
178 public ValuesDelta getSuperPrimaryEntry(String mimeType, boolean forceSelection) { argument
179 final ArrayList<ValuesDelta> mimeEntries = getMimeEntries(mimeType, false);
206 private ArrayList<ValuesDelta> getMimeEntries(String mimeType, boolean lazyCreate) { argument
207 ArrayList<ValuesDelta> mimeEntries = mEntries.get(mimeType);
210 mEntries.put(mimeType, mimeEntries);
215 public ArrayList<ValuesDelta> getMimeEntries(String mimeType) { argument
219 getMimeEntriesCount(String mimeType, boolean onlyVisible) argument
232 hasMimeEntries(String mimeType) argument
[all...]

Completed in 3658 milliseconds

12345