Home
last modified time | relevance | path

Searched refs:builder (Results 1 – 25 of 73) sorted by relevance

123

/development/samples/browseable/Notifications/Application/src/com.example.android.support.wearable.notifications/
DNotificationPresets.java71 NotificationCompat.Builder builder, NotificationCompat.WearableExtender wearableOptions, in applyBasicOptions() argument
73 builder.setContentTitle(options.titlePreset) in applyBasicOptions()
78 options.actionsPreset.apply(context, builder, wearableOptions); in applyBasicOptions()
79 options.priorityPreset.apply(builder, wearableOptions); in applyBasicOptions()
81 builder.setLargeIcon(BitmapFactory.decodeResource( in applyBasicOptions()
85 builder.setLocalOnly(true); in applyBasicOptions()
88 builder.setContentIntent(NotificationUtil.getExamplePendingIntent(context, in applyBasicOptions()
92 builder.setVibrate(new long[] {0, 100, 50, 100} ); in applyBasicOptions()
94 return builder; in applyBasicOptions()
105 NotificationCompat.Builder builder = new NotificationCompat.Builder(context); in buildNotifications() local
[all …]
DActionsPresets.java45 public void apply(Context context, NotificationCompat.Builder builder, in apply() argument
56 public void apply(Context context, NotificationCompat.Builder builder, in apply() argument
58 builder.addAction(R.drawable.ic_full_action, in apply()
72 public void apply(Context context, NotificationCompat.Builder builder, in apply() argument
74 builder.addAction(R.drawable.ic_full_action, in apply()
88 public void apply(Context context, NotificationCompat.Builder builder, in apply() argument
100 builder.addAction(action); in apply()
110 public void apply(Context context, NotificationCompat.Builder builder, in apply() argument
134 public void apply(Context context, NotificationCompat.Builder builder, in apply() argument
142 builder.addAction(phoneAction); in apply()
/development/samples/browseable/BasicNotifications/src/com.example.android.basicnotifications/
DMainActivity.java49 NotificationCompat.Builder builder = new NotificationCompat.Builder(this); in sendNotification() local
59 builder.setSmallIcon(R.drawable.ic_stat_notification); in sendNotification()
62 builder.setContentIntent(pendingIntent); in sendNotification()
66 builder.setAutoCancel(true); in sendNotification()
74 builder.setLargeIcon(BitmapFactory.decodeResource(getResources(), R.drawable.ic_launcher)); in sendNotification()
85 builder.setContentTitle("BasicNotifications Sample"); in sendNotification()
86 builder.setContentText("Time to learn about notifications!"); in sendNotification()
87 builder.setSubText("Tap to view documentation about notifications."); in sendNotification()
98 notificationManager.notify(NOTIFICATION_ID, builder.build()); in sendNotification()
/development/samples/browseable/RecipeAssistant/Application/src/com.example.android.wearable.recipeassistant/
DRecipeService.java73 NotificationCompat.Builder builder = new NotificationCompat.Builder(this); in createNotification() local
74 builder.setStyle(style); in createNotification()
75 notificationPages.add(builder.build()); in createNotification()
78 NotificationCompat.Builder builder = new NotificationCompat.Builder(this); in createNotification() local
84 builder.setLargeIcon(recipeImage); in createNotification()
86 builder.setContentTitle(mRecipe.titleText); in createNotification()
87 builder.setContentText(mRecipe.summaryText); in createNotification()
88 builder.setSmallIcon(R.mipmap.ic_notification_recipe); in createNotification()
90 Notification notification = builder in createNotification()
/development/samples/VoicemailProviderDemo/src/com/example/android/voicemail/common/utils/
DDbQueryUtils.java63 StringBuilder builder = new StringBuilder(); in concatenateClausesWithOperation() local
67 if (builder.length() > 0) { in concatenateClausesWithOperation()
68 builder.append(" ").append(operation).append(" "); in concatenateClausesWithOperation()
70 builder.append("("); in concatenateClausesWithOperation()
71 builder.append(clause); in concatenateClausesWithOperation()
72 builder.append(")"); in concatenateClausesWithOperation()
75 return builder.toString(); in concatenateClausesWithOperation()
/development/apps/Development/src/com/android/development/
DLogViewer.java69 StringBuilder builder = new StringBuilder(); in appendThrowable() local
70 builder.append("Error reading log: "); in appendThrowable()
71 builder.append(Log.getStackTraceString(t)); in appendThrowable()
72 text.getText().append(builder); in appendThrowable()
79 StringBuilder builder = new StringBuilder(); field in LogViewer.LogReader
111 builder.append(tag) in run()
118 handler.post(new AppendCharacters(builder)); in run()
119 builder = new StringBuilder(); in run()
/development/samples/ToyVpn/src/com/example/android/toyvpn/
DToyVpnConnection.java308 VpnService.Builder builder = mService.new Builder(); in configure() local
314 builder.setMtu(Short.parseShort(fields[1])); in configure()
317 builder.addAddress(fields[1], Integer.parseInt(fields[2])); in configure()
320 builder.addRoute(fields[1], Integer.parseInt(fields[2])); in configure()
323 builder.addDnsServer(fields[1]); in configure()
326 builder.addSearchDomain(fields[1]); in configure()
339 builder.addAllowedApplication(packageName); in configure()
341 builder.addDisallowedApplication(packageName); in configure()
347 builder.setSession(mServerName).setConfigureIntent(mConfigureIntent); in configure()
349 builder.setHttpProxy(ProxyInfo.buildDirectProxy(mProxyHostName, mProxyHostPort)); in configure()
[all …]
/development/samples/ApiDemos/src/com/example/android/apis/graphics/kube/
DM4.java68 StringBuilder builder = new StringBuilder("[ "); in toString() local
71 builder.append(m[i][j]); in toString()
72 builder.append(" "); in toString()
75 builder.append("\n "); in toString()
77 builder.append(" ]"); in toString()
78 return builder.toString(); in toString()
/development/samples/browseable/BasicSyncAdapter/src/com.example.android.basicsyncadapter/provider/
DFeedProvider.java95 SelectionBuilder builder = new SelectionBuilder(); in query() local
101 builder.where(FeedContract.Entry._ID + "=?", id); in query()
104 builder.table(FeedContract.Entry.TABLE_NAME) in query()
106 Cursor c = builder.query(db, projection, sortOrder); in query()
149 SelectionBuilder builder = new SelectionBuilder(); in delete() local
155 count = builder.table(FeedContract.Entry.TABLE_NAME) in delete()
161 count = builder.table(FeedContract.Entry.TABLE_NAME) in delete()
181 SelectionBuilder builder = new SelectionBuilder(); in update() local
187 count = builder.table(FeedContract.Entry.TABLE_NAME) in update()
193 count = builder.table(FeedContract.Entry.TABLE_NAME) in update()
/development/tools/idegen/src/com/android/idegen/
DDirectorySearch.java143 ImmutableList.Builder<File> builder = ImmutableList.builder(); in findSourceDirs() local
168 builder.add(child); in findSourceDirs()
171 builder.addAll(filteredDirs); in findSourceDirs()
176 return builder.build(); in findSourceDirs()
187 ImmutableList.Builder<File> builder = ImmutableList.builder(); in findExcludeDirs() local
201 builder.add(child); in findExcludeDirs()
207 return builder.build(); in findExcludeDirs()
/development/tools/apkcheck/src/com/android/apkcheck/
DTypeUtils.java73 StringBuilder builder = new StringBuilder(); in typeToDescriptor() local
75 builder.append("["); in typeToDescriptor()
80 builder.append(quick); in typeToDescriptor()
82 builder.append("L"); in typeToDescriptor()
83 builder.append(type.replace('.', '/')); in typeToDescriptor()
84 builder.append(";"); in typeToDescriptor()
87 return builder.toString(); in typeToDescriptor()
/development/samples/browseable/CustomNotifications/src/com.example.android.customnotifications/
DMainActivity.java46 NotificationCompat.Builder builder = new NotificationCompat.Builder(this); in createNotification() local
55 builder.setContentIntent(intent); in createNotification()
60 builder.setTicker(getResources().getString(R.string.custom_notification)); in createNotification()
63 builder.setSmallIcon(R.drawable.ic_stat_custom); in createNotification()
68 builder.setAutoCancel(true); in createNotification()
71 Notification notification = builder.build(); in createNotification()
/development/samples/browseable/HdrViewfinder/src/com.example.android.hdrviewfinder/
DMessageDialogFragment.java47 AlertDialog.Builder builder = new AlertDialog.Builder(getActivity()); in onCreateDialog() local
48 builder.setPositiveButton(android.R.string.ok, null); in onCreateDialog()
51 builder.setMessage(args.getInt(ARG_MESSAGE_INT)); in onCreateDialog()
53 builder.setMessage(args.getString(ARG_MESSAGE_STRING)); in onCreateDialog()
55 return builder.create(); in onCreateDialog()
/development/samples/browseable/Quiz/Wearable/src/com.example.android.wearable.quiz/
DQuizListenerService.java116 Notification.Builder builder = new Notification.Builder(this) in onDataChanged() local
147 builder.extend(wearableOptions); in onDataChanged()
148 Notification notification = builder.build(); in onDataChanged()
180 Notification.Builder builder = new Notification.Builder(this) in onMessageReceived() local
192 builder.setContentText(quizReportText); in onMessageReceived()
195 builder.addAction(R.drawable.ic_launcher, in onMessageReceived()
199 .notify(QUIZ_REPORT_NOTIF_ID, builder.build()); in onMessageReceived()
203 private void appendColored(SpannableStringBuilder builder, String text, int colorResId) { in appendColored() argument
204 builder.append(text).setSpan(new ForegroundColorSpan(getResources().getColor(colorResId)), in appendColored()
205 builder.length() - text.length(), builder.length(), 0); in appendColored()
/development/samples/browseable/JobScheduler/src/com.example.android.jobscheduler/
DMainActivity.java124 JobInfo.Builder builder = new JobInfo.Builder(mJobId++, mServiceComponent); in scheduleJob() local
128 builder.setMinimumLatency(Long.valueOf(delay) * 1000); in scheduleJob()
132 builder.setOverrideDeadline(Long.valueOf(deadline) * 1000); in scheduleJob()
137 builder.setRequiredNetworkType(JobInfo.NETWORK_TYPE_UNMETERED); in scheduleJob()
139 builder.setRequiredNetworkType(JobInfo.NETWORK_TYPE_ANY); in scheduleJob()
141 builder.setRequiresDeviceIdle(mRequiresIdleCheckbox.isChecked()); in scheduleJob()
142 builder.setRequiresCharging(mRequiresChargingCheckBox.isChecked()); in scheduleJob()
152 builder.setExtras(extras); in scheduleJob()
157 tm.schedule(builder.build()); in scheduleJob()
/development/samples/training/notify-user/src/com/example/android/pingme/
DPingService.java34 NotificationCompat.Builder builder; field in PingService
84 builder = in issueNotification()
123 builder.setContentIntent(resultPendingIntent); in issueNotification()
127 private void issueNotification(NotificationCompat.Builder builder) { in issueNotification() argument
131 mNotificationManager.notify(CommonConstants.NOTIFICATION_ID, builder.build()); in issueNotification()
144 issueNotification(builder); in startTimer()
/development/samples/browseable/AppRestrictionSchema/src/com.example.android.apprestrictionschema/
DAppRestrictionSchemaFragment.java185 StringBuilder builder = new StringBuilder(); in updateItems() local
201 builder.append(", "); in updateItems()
203 builder.append(item.getString(KEY_ITEM_KEY)); in updateItems()
204 builder.append(":"); in updateItems()
205 builder.append(item.getString(KEY_ITEM_VALUE)); in updateItems()
208 builder.append(getString(R.string.none)); in updateItems()
211 builder.append(getString(R.string.none)); in updateItems()
213 mTextItems.setText(getString(R.string.your_items, builder)); in updateItems()
/development/samples/AppNavigation/src/com/example/android/appnavigation/app/
DNotificationsActivity.java38 Notification.Builder builder = new Notification.Builder(this) in onPostDirect() local
50 nm.notify("direct_tag", R.id.direct_notification, builder.getNotification()); in onPostDirect()
54 Notification.Builder builder = new Notification.Builder(this) in onPostInterstitial() local
65 nm.notify("interstitial_tag", R.id.interstitial_notification, builder.getNotification()); in onPostInterstitial()
/development/samples/browseable/BluetoothAdvertisements/src/com.example.android.bluetoothadvertisements/
DScannerFragment.java182 ScanFilter.Builder builder = new ScanFilter.Builder(); in buildScanFilters() local
184 builder.setServiceUuid(Constants.Service_UUID); in buildScanFilters()
185 scanFilters.add(builder.build()); in buildScanFilters()
194 ScanSettings.Builder builder = new ScanSettings.Builder(); in buildScanSettings() local
195 builder.setScanMode(ScanSettings.SCAN_MODE_LOW_POWER); in buildScanSettings()
196 return builder.build(); in buildScanSettings()
/development/samples/browseable/MediaBrowserService/src/com.example.android.mediabrowserservice/
DMediaNotificationManager.java295 private void addPlayPauseAction(Notification.Builder builder) { in addPlayPauseAction() argument
309 builder.addAction(new Notification.Action(icon, label, intent)); in addPlayPauseAction()
312 private void setNotificationPlaybackState(Notification.Builder builder) { in setNotificationPlaybackState() argument
323 builder in setNotificationPlaybackState()
329 builder in setNotificationPlaybackState()
336 builder.setOngoing(mPlaybackState.getState() == PlaybackState.STATE_PLAYING); in setNotificationPlaybackState()
340 final Notification.Builder builder) { in fetchBitmapFromURLAsync() argument
348 builder.setLargeIcon(bitmap); in fetchBitmapFromURLAsync()
349 mNotificationManager.notify(NOTIFICATION_ID, builder.build()); in fetchBitmapFromURLAsync()
/development/samples/ApiDemos/src/com/example/android/apis/content/
DTextUndoActivity.java105 StringBuilder builder = new StringBuilder(); in addSpaces() local
109 builder.append(str.subSequence(i, i + 4)); in addSpaces()
110 builder.append(' '); in addSpaces()
113 builder.append(str.subSequence(i, len)); in addSpaces()
116 return builder.toString(); in addSpaces()
/development/tools/idegen/src/
DFiles.java32 StringBuilder builder = new StringBuilder(); in toString() local
34 builder.append(buffer, 0, read); in toString()
37 return builder.toString(); in toString()
/development/samples/ApiDemos/src/com/example/android/apis/app/
DDeviceAdminSample.java257 AlertDialog.Builder builder = new AlertDialog.Builder(mActivity); in doResetPassword() local
259 builder.setMessage(message); in doResetPassword()
260 builder.setPositiveButton(R.string.reset_password_ok, null); in doResetPassword()
261 builder.show(); in doResetPassword()
916 AlertDialog.Builder builder = new AlertDialog.Builder(activity); in promptForRealDeviceWipe() local
917 builder.setMessage(R.string.wipe_warning_first); in promptForRealDeviceWipe()
918 builder.setPositiveButton(R.string.wipe_warning_first_ok, in promptForRealDeviceWipe()
922 AlertDialog.Builder builder = new AlertDialog.Builder(activity); in promptForRealDeviceWipe()
924 builder.setMessage(R.string.wipe_warning_second_full); in promptForRealDeviceWipe()
926 builder.setMessage(R.string.wipe_warning_second); in promptForRealDeviceWipe()
[all …]
/development/apps/GestureBuilder/src/com/android/gesture/builder/
DGestureBuilderActivity.java17 package com.android.gesture.builder;
245 AlertDialog.Builder builder = new AlertDialog.Builder(this); in createRenameDialog() local
246 builder.setIcon(0); in createRenameDialog()
247 builder.setTitle(getString(R.string.gestures_rename_title)); in createRenameDialog()
248 builder.setCancelable(true); in createRenameDialog()
249 builder.setOnCancelListener(new Dialog.OnCancelListener() { in createRenameDialog()
254 builder.setNegativeButton(getString(R.string.cancel_action), in createRenameDialog()
261 builder.setPositiveButton(getString(R.string.rename_action), in createRenameDialog()
268 builder.setView(layout); in createRenameDialog()
269 return builder.create(); in createRenameDialog()
/development/samples/SampleSyncAdapter/src/com/example/android/samplesync/platform/
DContactOperations.java108 ContentProviderOperation.Builder builder = in ContactOperations() local
110 mBatchOperation.add(builder.build()); in ContactOperations()
366 ContentProviderOperation.Builder builder = in addInsertOp() local
368 builder.withValues(mValues); in addInsertOp()
370 builder.withValueBackReference(Data.RAW_CONTACT_ID, mBackReference); in addInsertOp()
373 mBatchOperation.add(builder.build()); in addInsertOp()
380 ContentProviderOperation.Builder builder = in addUpdateOp() local
383 mBatchOperation.add(builder.build()); in addUpdateOp()

123