Home
last modified time | relevance | path

Searched refs:mimeType (Results 1 – 25 of 136) sorted by relevance

123456

/packages/apps/TV/usbtuner/src/com/google/android/exoplayer/
DMediaSoftwareCodecUtil.java56 public static DecoderInfo getSoftwareDecoderInfo(String mimeType, boolean secure) in getSoftwareDecoderInfo() argument
60 getMediaSoftwareCodecInfo(mimeType, secure); in getSoftwareDecoderInfo()
72 getMediaSoftwareCodecInfo(String mimeType, boolean secure) throws DecoderQueryException { in getMediaSoftwareCodecInfo() argument
73 CodecKey key = new CodecKey(mimeType, secure); in getMediaSoftwareCodecInfo()
85 Log.w(TAG, "MediaCodecList API didn't list secure decoder for: " + mimeType in getMediaSoftwareCodecInfo()
105 String mimeType = key.mimeType; in getMediaSoftwareCodecInfoInternal() local
117 if (supportedType.equalsIgnoreCase(mimeType)) { in getMediaSoftwareCodecInfoInternal()
121 key.mimeType, capabilities); in getMediaSoftwareCodecInfoInternal()
125 sSwCodecs.put(key.secure ? new CodecKey(mimeType, false) : key, in getMediaSoftwareCodecInfoInternal()
128 sSwCodecs.put(key.secure ? key : new CodecKey(mimeType, true), in getMediaSoftwareCodecInfoInternal()
[all …]
/packages/apps/Contacts/src/com/android/contacts/editor/
DKindSectionDataList.java45 return get(0).getDataKind().mimeType; in getMimeType()
60 final String mimeType = getMimeType(); in getEntryToWrite() local
61 if (mimeType == null) return null; in getEntryToWrite()
70 vlog(mimeType + ": matched kind section data to write by ID"); in getEntryToWrite()
82 vlog(mimeType + ": matched kind section data to write by super primary"); in getEntryToWrite()
94 vlog(mimeType + ": matched kind section data to write by primary " + in getEntryToWrite()
109 kindSectionData.getAccountType(), mimeType); in getEntryToWrite() local
112 vlog(mimeType + ": falling back to first kind section data to write"); in getEntryToWrite()
118 wlog(mimeType+ ": no writable kind section data found"); in getEntryToWrite()
134 final String mimeType = getMimeType(); in getEntryToDisplay() local
[all …]
DCompactRawContactsEditorView.java696 vlog("parse: " + i + " " + dataKind.mimeType + " dropped read-only"); in parseRawContactDeltas()
699 final String mimeType = dataKind.mimeType; in parseRawContactDeltas() local
702 if (DataKind.PSEUDO_MIME_TYPE_DISPLAY_NAME.equals(mimeType) in parseRawContactDeltas()
703 || DataKind.PSEUDO_MIME_TYPE_PHONETIC_NAME.equals(mimeType)) { in parseRawContactDeltas()
704 vlog("parse: " + i + " " + dataKind.mimeType + " dropped pseudo type"); in parseRawContactDeltas()
709 getOrCreateKindSectionDataList(mimeType); in parseRawContactDeltas()
714 vlog("parse: " + i + " " + dataKind.mimeType + " " + in parseRawContactDeltas()
723 private KindSectionDataList getOrCreateKindSectionDataList(String mimeType) { in getOrCreateKindSectionDataList() argument
724 KindSectionDataList kindSectionDataList = mKindSectionDataMap.get(mimeType); in getOrCreateKindSectionDataList()
727 mKindSectionDataMap.put(mimeType, kindSectionDataList); in getOrCreateKindSectionDataList()
[all …]
DRawContactEditorView.java258 final String mimeType = kind.mimeType; in setState() local
259 if (StructuredName.CONTENT_ITEM_TYPE.equals(mimeType)) { in setState()
261 final ValuesDelta primary = state.getPrimaryEntry(mimeType); in setState()
273 ValuesDelta primaryNickNameEntry = state.getPrimaryEntry(nickNameKind.mimeType); in setState()
284 } else if (Photo.CONTENT_ITEM_TYPE.equals(mimeType)) { in setState()
286 final ValuesDelta primary = state.getPrimaryEntry(mimeType); in setState()
288 } else if (GroupMembership.CONTENT_ITEM_TYPE.equals(mimeType)) { in setState()
293 } else if (DataKind.PSEUDO_MIME_TYPE_DISPLAY_NAME.equals(mimeType) in setState()
294 || DataKind.PSEUDO_MIME_TYPE_PHONETIC_NAME.equals(mimeType) in setState()
295 || Nickname.CONTENT_ITEM_TYPE.equals(mimeType)) { in setState()
/packages/apps/ContactsCommon/src/com/android/contacts/common/model/dataitem/
DDataItem.java60 final String mimeType = values.getAsString(Data.MIMETYPE); in createFrom() local
61 if (GroupMembership.CONTENT_ITEM_TYPE.equals(mimeType)) { in createFrom()
63 } else if (StructuredName.CONTENT_ITEM_TYPE.equals(mimeType)) { in createFrom()
65 } else if (Phone.CONTENT_ITEM_TYPE.equals(mimeType)) { in createFrom()
67 } else if (Email.CONTENT_ITEM_TYPE.equals(mimeType)) { in createFrom()
69 } else if (StructuredPostal.CONTENT_ITEM_TYPE.equals(mimeType)) { in createFrom()
71 } else if (Im.CONTENT_ITEM_TYPE.equals(mimeType)) { in createFrom()
73 } else if (Organization.CONTENT_ITEM_TYPE.equals(mimeType)) { in createFrom()
75 } else if (Nickname.CONTENT_ITEM_TYPE.equals(mimeType)) { in createFrom()
77 } else if (Note.CONTENT_ITEM_TYPE.equals(mimeType)) { in createFrom()
[all …]
/packages/apps/UnifiedEmail/src/com/android/mail/print/
DPrintUtils.java303 private static String getIconFilename(String mimeType) { in getIconFilename() argument
304 if (mimeType.startsWith("application/msword") || in getIconFilename()
305 mimeType.startsWith("application/vnd.oasis.opendocument.text") || in getIconFilename()
306 mimeType.equals("application/rtf") || in getIconFilename()
307 mimeType.equals("application/" in getIconFilename()
310 } else if (mimeType.startsWith("image/")) { in getIconFilename()
312 } else if (mimeType.startsWith("text/html")) { in getIconFilename()
314 } else if (mimeType.startsWith("application/pdf")) { in getIconFilename()
316 } else if (mimeType.endsWith("powerpoint") || in getIconFilename()
317 mimeType.equals("application/vnd.oasis.opendocument.presentation") || in getIconFilename()
[all …]
/packages/services/Telephony/src/org/apache/james/mime4j/field/
DContentTypeField.java71 private String mimeType = ""; field in ContentTypeField
75 …protected ContentTypeField(String name, String body, String raw, String mimeType, Map<String, Stri… in ContentTypeField() argument
77 this.mimeType = mimeType; in ContentTypeField()
96 return mimeType; in getMimeType()
194 public boolean isMimeType(String mimeType) { in isMimeType() argument
195 return this.mimeType.equalsIgnoreCase(mimeType); in isMimeType()
205 return mimeType.startsWith(TYPE_MULTIPART_PREFIX); in isMultipart()
213 String mimeType = ""; in parse() local
238 mimeType = (type + "/" + parser.getSubType()).toLowerCase(); in parse()
256 return new ContentTypeField(name, body, raw, mimeType, parameters, parseException); in parse()
/packages/apps/UnifiedEmail/src/org/apache/james/mime4j/field/
DContentTypeField.java71 private String mimeType = ""; field in ContentTypeField
75 …protected ContentTypeField(String name, String body, String raw, String mimeType, Map<String, Stri… in ContentTypeField() argument
77 this.mimeType = mimeType; in ContentTypeField()
96 return mimeType; in getMimeType()
194 public boolean isMimeType(String mimeType) { in isMimeType() argument
195 return this.mimeType.equalsIgnoreCase(mimeType); in isMimeType()
205 return mimeType.startsWith(TYPE_MULTIPART_PREFIX); in isMultipart()
213 String mimeType = ""; in parse() local
238 mimeType = (type + "/" + parser.getSubType()).toLowerCase(); in parse()
256 return new ContentTypeField(name, body, raw, mimeType, parameters, parseException); in parse()
/packages/apps/Camera2/src/com/android/camera/
DStorage.java122 int height, String mimeType) throws IOException { in addImage() argument
124 String path = generateFilepath(title, mimeType); in addImage()
128 path, width, height, mimeType); in addImage()
151 String mimeType) { in addImageToMediaStore() argument
155 height, mimeType); in addImageToMediaStore()
174 String path, int width, int height, String mimeType) { in getContentValuesForData() argument
183 values.put(ImageColumns.MIME_TYPE, mimeType); in getContentValuesForData()
271 byte[] jpeg, int width, int height, String mimeType) throws IOException { in updateImage() argument
272 String path = generateFilepath(title, mimeType); in updateImage()
275 width, height, mimeType); in updateImage()
[all …]
/packages/apps/ContactsCommon/src/com/android/contacts/common/model/
DRawContactModifier.java92 final int visibleCount = state.getMimeEntriesCount(kind.mimeType, true); in canInsert()
114 RawContactDelta state, AccountType accountType, String mimeType) { in ensureKindExists() argument
115 final DataKind kind = accountType.getKindForMimetype(mimeType); in ensureKindExists()
116 final boolean hasChild = state.getMimeEntriesCount(mimeType, true) > 0; in ensureKindExists()
121 return state.getMimeEntries(mimeType).get(0); in ensureKindExists()
125 if (kind.mimeType.equals(Photo.CONTENT_ITEM_TYPE)) { in ensureKindExists()
196 final List<ValuesDelta> mimeEntries = state.getMimeEntries(kind.mimeType); in getTypeFrequencies()
354 after.put(Data.MIMETYPE, kind.mimeType); in insertChild()
420 final String mimeType = kind.mimeType; in trimEmpty() local
421 final ArrayList<ValuesDelta> entries = state.getMimeEntries(mimeType); in trimEmpty()
[all …]
DRawContactDelta.java158 public ValuesDelta getPrimaryEntry(String mimeType) { in getPrimaryEntry() argument
159 final ArrayList<ValuesDelta> mimeEntries = getMimeEntries(mimeType, false); in getPrimaryEntry()
176 public ValuesDelta getSuperPrimaryEntry(String mimeType) { in getSuperPrimaryEntry() argument
177 return getSuperPrimaryEntry(mimeType, true); in getSuperPrimaryEntry()
187 public ValuesDelta getSuperPrimaryEntry(String mimeType, boolean forceSelection) { in getSuperPrimaryEntry() argument
188 final ArrayList<ValuesDelta> mimeEntries = getMimeEntries(mimeType, false); in getSuperPrimaryEntry()
249 private ArrayList<ValuesDelta> getMimeEntries(String mimeType, boolean lazyCreate) { in getMimeEntries() argument
250 ArrayList<ValuesDelta> mimeEntries = mEntries.get(mimeType); in getMimeEntries()
253 mEntries.put(mimeType, mimeEntries); in getMimeEntries()
258 public ArrayList<ValuesDelta> getMimeEntries(String mimeType) { in getMimeEntries() argument
[all …]
/packages/apps/UnifiedEmail/src/com/android/mail/utils/
DMimeType.java128 public static String inferMimeType(String name, String mimeType) { in inferMimeType() argument
133 return mimeType; in inferMimeType()
135 final boolean isTextPlain = TEXT_PLAIN.equalsIgnoreCase(mimeType); in inferMimeType()
137 isTextPlain || GENERIC_MIMETYPE.equalsIgnoreCase(mimeType); in inferMimeType()
140 if (isGenericType || TextUtils.isEmpty(mimeType)) { in inferMimeType()
150 return !TextUtils.isEmpty(mimeType) ? mimeType : GENERIC_MIMETYPE; in inferMimeType()
161 public static boolean isEmlMimeType(String mimeType) { in isEmlMimeType() argument
162 return EML_ATTACHMENT_CONTENT_TYPES.contains(mimeType); in isEmlMimeType()
/packages/services/Telephony/src/org/apache/james/mime4j/
DBodyDescriptor.java35 private String mimeType = "text/plain"; field in BodyDescriptor
58 mimeType = "message/rfc822"; in BodyDescriptor()
60 mimeType = "text/plain"; in BodyDescriptor()
126 mimeType = main; in addField()
321 public boolean isMimeType(String mimeType) { in isMimeType() argument
322 return this.mimeType.equals(mimeType.toLowerCase()); in isMimeType()
329 return mimeType.equals("message/rfc822"); in isMessage()
336 return mimeType.startsWith("multipart/"); in isMultipart()
343 return mimeType; in getMimeType()
390 return mimeType; in toString()
/packages/apps/UnifiedEmail/src/org/apache/james/mime4j/
DBodyDescriptor.java35 private String mimeType = "text/plain"; field in BodyDescriptor
58 mimeType = "message/rfc822"; in BodyDescriptor()
60 mimeType = "text/plain"; in BodyDescriptor()
126 mimeType = main; in addField()
321 public boolean isMimeType(String mimeType) { in isMimeType() argument
322 return this.mimeType.equals(mimeType.toLowerCase()); in isMimeType()
329 return mimeType.equals("message/rfc822"); in isMessage()
336 return mimeType.startsWith("multipart/"); in isMultipart()
343 return mimeType; in getMimeType()
390 return mimeType; in toString()
/packages/apps/Gallery2/gallerycommon/src/com/android/gallery3d/common/
DBitmapUtils.java247 public static boolean isSupportedByRegionDecoder(String mimeType) { in isSupportedByRegionDecoder() argument
248 if (mimeType == null) return false; in isSupportedByRegionDecoder()
249 mimeType = mimeType.toLowerCase(); in isSupportedByRegionDecoder()
250 return mimeType.startsWith("image/") && in isSupportedByRegionDecoder()
251 (!mimeType.equals("image/gif") && !mimeType.endsWith("bmp")); in isSupportedByRegionDecoder()
254 public static boolean isRotationSupported(String mimeType) { in isRotationSupported() argument
255 if (mimeType == null) return false; in isRotationSupported()
256 mimeType = mimeType.toLowerCase(); in isRotationSupported()
257 return mimeType.equals("image/jpeg"); in isRotationSupported()
/packages/providers/DownloadProvider/src/com/android/providers/downloads/
DDownloadStorageProvider.java111 public String createDocument(String docId, String mimeType, String displayName) in createDocument() argument
115 if (Document.MIME_TYPE_DIR.equals(mimeType)) { in createDocument()
126 final File file = FileUtils.buildUniqueFile(parent, mimeType, displayName); in createDocument()
137 file.getName(), file.getName(), true, mimeType, file.getAbsolutePath(), 0L, in createDocument()
273 final String mimeType = cursor.getString( in queryRecentDocuments() local
280 if (mimeType == null in queryRecentDocuments()
281 || (mimeType.startsWith("image/") && !TextUtils.isEmpty(uri))) { in queryRecentDocuments()
336 String mimeType = cursor.getString( in includeDownloadFromCursor() local
338 if (mimeType == null) { in includeDownloadFromCursor()
340 mimeType = "vnd.android.document/file"; in includeDownloadFromCursor()
[all …]
DDownloadScanner.java53 public final String mimeType; field in DownloadScanner.ScanRequest
56 public ScanRequest(long id, String path, String mimeType) { in ScanRequest() argument
59 this.mimeType = mimeType; in ScanRequest()
64 conn.scanFile(path, mimeType); in exec()
82 public static void requestScanBlocking(Context context, long id, String path, String mimeType) { in requestScanBlocking() argument
85 scanner.requestScan(new ScanRequest(id, path, mimeType)); in requestScanBlocking()
DHelpers.java201 String contentDisposition, String contentLocation, String mimeType, int destination) in generateSaveFile() argument
229 if (DownloadDrmHelper.isDrmConvertNeeded(mimeType)) { in generateSaveFile()
251 suffix = chooseExtensionFromMimeType(mimeType, true); in generateSaveFile()
254 suffix = chooseExtensionFromFilename(mimeType, destination, name, dotIndex); in generateSaveFile()
348 private static String chooseExtensionFromMimeType(String mimeType, boolean useDefaults) { in chooseExtensionFromMimeType() argument
350 if (mimeType != null) { in chooseExtensionFromMimeType()
351 extension = MimeTypeMap.getSingleton().getExtensionFromMimeType(mimeType); in chooseExtensionFromMimeType()
359 Log.v(Constants.TAG, "couldn't find extension for " + mimeType); in chooseExtensionFromMimeType()
364 if (mimeType != null && mimeType.toLowerCase().startsWith("text/")) { in chooseExtensionFromMimeType()
365 if (mimeType.equalsIgnoreCase("text/html")) { in chooseExtensionFromMimeType()
[all …]
/packages/apps/Email/tests/src/com/android/emailcommon/mail/
DMessageTestUtils.java77 public static BodyPart bodyPart(String mimeType, String contentId) throws MessagingException { in bodyPart() argument
78 final MimeBodyPart bp = new MimeBodyPart(null, mimeType); in bodyPart()
93 public static BodyPart textPart(String mimeType, String text) throws MessagingException { in textPart() argument
96 textPart.setHeader(MimeHeader.HEADER_CONTENT_TYPE, mimeType); in textPart()
116 public MultipartBuilder(String mimeType) { in MultipartBuilder() argument
117 this(mimeType, "this_is_boundary"); in MultipartBuilder()
126 public MultipartBuilder(String mimeType, String boundary) { in MultipartBuilder() argument
127 mContentType = mimeType + "; boundary=" + boundary; in MultipartBuilder()
/packages/experimental/LoaderApp/src/com/android/loaderapp/model/
DEntityDelta.java150 public ValuesDelta getPrimaryEntry(String mimeType) { in getPrimaryEntry() argument
151 final ArrayList<ValuesDelta> mimeEntries = getMimeEntries(mimeType, false); in getPrimaryEntry()
168 public ValuesDelta getSuperPrimaryEntry(String mimeType) { in getSuperPrimaryEntry() argument
169 return getSuperPrimaryEntry(mimeType, true); in getSuperPrimaryEntry()
178 public ValuesDelta getSuperPrimaryEntry(String mimeType, boolean forceSelection) { in getSuperPrimaryEntry() argument
179 final ArrayList<ValuesDelta> mimeEntries = getMimeEntries(mimeType, false); in getSuperPrimaryEntry()
206 private ArrayList<ValuesDelta> getMimeEntries(String mimeType, boolean lazyCreate) { in getMimeEntries() argument
207 ArrayList<ValuesDelta> mimeEntries = mEntries.get(mimeType); in getMimeEntries()
210 mEntries.put(mimeType, mimeEntries); in getMimeEntries()
215 public ArrayList<ValuesDelta> getMimeEntries(String mimeType) { in getMimeEntries() argument
[all …]
/packages/apps/Contacts/src/com/android/contacts/quickcontact/
DResolveCache.java124 protected Entry getEntry(String mimeType, Intent intent) { in getEntry() argument
125 Entry entry = mCache.get(mimeType); in getEntry()
129 if (SipAddress.CONTENT_ITEM_TYPE.equals(mimeType) in getEntry()
155 mCache.put(mimeType, entry); in getEntry()
200 public boolean hasResolve(String mimeType, Intent intent) { in hasResolve() argument
201 return getEntry(mimeType, intent).bestResolve != null; in hasResolve()
209 public Drawable getIcon(String mimeType, Intent intent) { in getIcon() argument
210 return getEntry(mimeType, intent).icon; in getIcon()
DActionMultiMap.java27 public void put(String mimeType, Action info) { in put() argument
28 put(mimeType, info, false); in put()
35 public void put(String mimeType, Action info, boolean front) { in put() argument
37 ArrayList<Action> collectList = get(mimeType); in put()
42 put(mimeType, collectList); in put()
/packages/apps/CertInstaller/src/com/android/certinstaller/
DCertInstallerMain.java123 private void startInstallActivity(String mimeType, Uri uri) { in startInstallActivity() argument
124 if (mimeType == null) { in startInstallActivity()
125 mimeType = getContentResolver().getType(uri); in startInstallActivity()
128 String target = MIME_MAPPINGS.get(mimeType); in startInstallActivity()
130 throw new IllegalArgumentException("Unknown MIME type: " + mimeType); in startInstallActivity()
134 startWifiInstallActivity(mimeType, uri); in startInstallActivity()
160 private void startWifiInstallActivity(String mimeType, Uri uri) { in startWifiInstallActivity() argument
167 intent.putExtra(WIFI_CONFIG, mimeType); in startWifiInstallActivity()
/packages/apps/UnifiedEmail/src/com/android/emailcommon/internet/
DMimeUtility.java229 String mimeType = part.getMimeType(); in getTextFromPart() local
230 if (mimeType != null && MimeUtility.mimeTypeMatches(mimeType, "text/*")) { in getTextFromPart()
291 public static boolean mimeTypeMatches(String mimeType, String matchAgainst) { in mimeTypeMatches() argument
294 return p.matcher(mimeType).matches(); in mimeTypeMatches()
306 public static boolean mimeTypeMatches(String mimeType, String[] matchAgainst) { in mimeTypeMatches() argument
308 if (mimeTypeMatches(mimeType, matchType)) { in mimeTypeMatches()
379 String mimeType = part.getMimeType().toLowerCase(); in collectParts() local
409 } else if (inline && (mimeType.startsWith("text") || (mimeType.startsWith("image")))) { in collectParts()
/packages/services/Telephony/src/com/android/phone/common/mail/internet/
DMimeUtility.java228 String mimeType = part.getMimeType(); in getTextFromPart() local
229 if (mimeType != null && MimeUtility.mimeTypeMatches(mimeType, "text/*")) { in getTextFromPart()
290 public static boolean mimeTypeMatches(String mimeType, String matchAgainst) { in mimeTypeMatches() argument
293 return p.matcher(mimeType).matches(); in mimeTypeMatches()
305 public static boolean mimeTypeMatches(String mimeType, String[] matchAgainst) { in mimeTypeMatches() argument
307 if (mimeTypeMatches(mimeType, matchType)) { in mimeTypeMatches()
378 String mimeType = part.getMimeType().toLowerCase(); in collectParts() local
408 } else if (inline && (mimeType.startsWith("text") || (mimeType.startsWith("image")))) { in collectParts()

123456