Home
last modified time | relevance | path

Searched refs:format (Results 1 – 25 of 170) sorted by relevance

1234567

/development/samples/browseable/Timer/src/com.example.android.wearable.timer/util/
DTimerFormat.java49 String format; in setTime() local
85 format = showNeg ? NEG_TWO_DIGITS : TWO_DIGITS; in setTime()
86 mHours = String.format(format, hours); in setTime()
88 format = showNeg ? NEG_ONE_DIGIT : ONE_DIGIT; in setTime()
89 mHours = String.format(format, hours); in setTime()
96 format = (showNeg && hours == 0) ? NEG_TWO_DIGITS : TWO_DIGITS; in setTime()
97 mMinutes = String.format(format, minutes); in setTime()
99 format = (showNeg && hours == 0) ? NEG_ONE_DIGIT : ONE_DIGIT; in setTime()
100 mMinutes = String.format(format, minutes); in setTime()
104 mSeconds = String.format(TWO_DIGITS, seconds); in setTime()
[all …]
/development/vndk/snapshot/
Dcheck_gpl_license.py63 '{manifest} not found at {manifest_file}'.format(
117 logging.info('Checking if revision {rev} exists in {proj}'.format(
121 'git', '-C', path, 'rev-list', 'HEAD..{}'.format(revision)
125 logging.error('Error: {}'.format(error))
131 format(proj=git_project_path, rev=output))
135 'Found revision {rev} in project {proj}'.format(
148 format(rev=revision, proj=git_project_path))
152 '{}^2'.format(revision)]
157 '{err}'.format(
160 'in the current branch'.format(revision))
[all …]
Dupdate.py41 logging.info('Creating branch {branch} in {dir}'.format(
47 logging.info('Removing any old files in {}'.format(install_dir))
48 for file in glob.glob('{}/*'.format(install_dir)):
55 logging.error('Error: {}'.format(error))
78 logging.info('Fetching {pattern} from {branch} (bid: {build})'.format(
82 manifest_pattern = 'manifest_{}.xml'.format(build)
83 logging.info('Fetching {file} from {branch} (bid: {build})'.format(
90 logging.info('Fetching local VNDK snapshot from {}'.format(local_dir))
95 logging.info('Unzipping VNDK snapshot: {}'.format(artifact))
103 logging.info('Creating {} directory to gather all NOTICE files...'.format(
[all …]
Dgen_buildfiles.py96 etc_pattern = '{}*'.format(os.path.splitext(etc_module)[0])
132 logging.info('Generating Android.bp for snapshot v{}'.format(
144 logging.info('Successfully generated {}'.format(self._root_bpfile))
149 logging.info('Generating common/Android.bp for snapshot v{}'.format(
172 binder32_suffix = '_{}'.format(
174 logging.info('Generating Android.bp for vndk_v{}_{}{}'.format(
227 logging.info('Successfully generated {}'.format(bpfile_path))
248 '{0}{0} DO NOT EDIT\n'.format(comment_char))
275 versioned_name = '{}.{}{}'.format(name, self._vndk_version, ext)
282 binder_suffix = '.{}'.format(utils.BINDER32) if is_binder32 else ''
[all …]
Dutils.py44 format='%(levelname)-8s [%(filename)s:%(lineno)d] %(message)s',
49 logging.debug('Running `{}`'.format(' '.join(cmd)))
54 logging.debug('Running `{}`'.format(' '.join(cmd)))
56 logging.debug('Output: `{}`'.format(output))
93 for file in glob.glob('{}/*'.format(install_dir)):
/development/scripts/
Dgdbclient.py60 return path.format(root, arch, "64")
62 return path.format(root, arch, "")
88 line, _ = device.shell(["grep", "-e", "^TracerPid:", "/proc/{}/status".format(pid)])
136 sys.exit(msg.format(target_device, name))
142 msg = "failed to find running process {}".format(process_name)
146 msg = "multiple processes match '{}': {}".format(process_name, pids)
246 "please provide an absolute path.".format(args.run_cmd[0]))
256 sys.exit("failed to pull binary for PID {}".format(pid))
260 " symbols may not be available.".format(sysroot))
269 "name": "(gdbclient.py) Attach {} (port: {})".format(binary_name.split("/")[-1], port),
[all …]
Dget_rust_pkg.py78 print("INFO: {}".format(msg), flush=True)
83 print("INFO: now {} in {}:{}".format(len(deps), kind, set2list(deps)))
103 echo(args, "checking version={} id={}".format(check_version, check_id))
121 url = "https://crates.io/api/v1/crates/{}/{}".format(base_name, version)
122 echo(args, "try to get dl_path from {}".format(url))
126 print("ERROR: cannot find version {} of package {}".format(
129 echo(args, "found download path for version {}".format(version))
136 print("ERROR: cannot find download path for '{}'".format(pkg))
140 echo(args, "fetch tar file from {}".format(url))
143 echo(args, "extract tar file {} into {}".format(tar_file, tmp_dir))
[all …]
/development/tools/winscope/adb_proxy/
Dwinscope_proxy.py61 format='%(asctime)s - %(name)s - %(levelname)s - %(message)s')
142 log.debug("Loaded token {} from {}".format(token, WINSCOPE_TOKEN_LOCATION))
149 log.debug("Created and saved token {} to {}".format(token, WINSCOPE_TOKEN_LOCATION))
153 … log.error("Unable to save persistent token {} to {}".format(token, WINSCOPE_TOKEN_LOCATION))
228 return self.__bad_request("Unknown endpoint /{}/".format(endpoint_name))
244 log.debug('Error executing adb command: {}\n{}'.format(' '.join(command), repr(ex)))
245 raise AdbError('Error executing adb command: {}\n{}'.format(' '.join(command), repr(ex)))
247 …log.debug('Error executing adb command: {}\n{}'.format(' '.join(command), ex.output.decode("utf-8"…
248 …raise AdbError('Error executing adb command: adb {}\n{}'.format(params, ex.output.decode("utf-8")))
258 log.debug('Error executing adb command: adb {}\n'.format(params) + err.decode(
[all …]
/development/python-packages/gdbrunner/
D__init__.py65 sys.exit(msg.format(adb_path))
180 gdbserver_cmd.extend(["--once", "+{}".format(debug_socket)])
187 forward_gdbserver_port(device, local=port, remote="localfilesystem:{}".format(debug_socket))
194 print("Redirecting gdbserver output to {}".format(gdbserver_output_path))
202 device.forward("tcp:{}".format(local), remote)
203 atexit.register(lambda: device.forward_remove("tcp:{}".format(local)))
227 raise ValueError("'{}' is not an absolute path".format(executable_path))
243 file_name = "gdbclient-binary-{}".format(os.getppid())
244 remote_temp_path = "/data/local/tmp/{}".format(file_name)
255 "device".format(executable_path))
[all …]
/development/gsi/gsi_util/gsi_util/commands/
Dcheck_compat.py70 print(self._OUTPUT_FORMAT.format(title, result_str))
72 print(self._ERR_MSE_FORMAT.format(stderr))
84 summary_result_str = '{}/{}'.format(num_pass_items, num_all_items)
85 print(self._OUTPUT_FORMAT.format(self._SUMMARY_NAME, summary_result_str))
102 return ', '.join('{!r}'.format(x.check_item) for x in check_list)
172 'select one from: {}\n'.format(_format_check_list(
/development/gsi/gsi_util/gsi_util/checkers/
Dsepolicy_checker.py86 raise RuntimeError('Failed to open: {}'.format(_VENDOR_VERSION_FILE))
125 mapping_sepolicy_cil = '/system/etc/selinux/mapping/{}.cil'.format(
138 raise RuntimeError('Failed to open: {}'.format(_PLAT_SEPOLICY_CIL))
140 raise RuntimeError('Failed to open: {}'.format(mapping_sepolicy_cil))
155 'Either {!r} or {!r}/{!r} should present'.format(
Dvintf_checker.py69 raise RuntimeError('Failed to open: {}'.format(manifest_filename))
71 raise RuntimeError('Failed to open: {}'.format(matrix_filename))
Dchecker.py87 raise RuntimeError('Unknown check item: {}'.format(check_item))
91 'Duplicated check items: {} in the check list'.format(check_item))
/development/tools/repo_pull/
Dgerrit.py143 .format(domain, args.gitcookies), file=sys.stderr)
228 url = '{}/a/changes/{}/revisions/current/review'.format(
243 url = '{}/a/changes/{}/submit'.format(gerrit_url, change_id)
251 url = '{}/a/changes/{}/abandon'.format(gerrit_url, change_id)
263 url = '{}/a/changes/{}/topic'.format(gerrit_url, change_id)
271 url = '{}/a/changes/{}/topic'.format(gerrit_url, change_id)
280 url = '{}/a/changes/{}/hashtags'.format(gerrit_url, change_id)
294 url = '{}/a/changes/{}/revisions/current/review'.format(
307 url = '{}/a/changes/{}/reviewers/{}/delete'.format(
316 url = '{}/a/changes/{}/revisions/{}/patch'.format(
/development/gsi/gsi_util/
Dbuild.py88 print 'Copy {}...'.format(item.dest)
94 print 'Archive to {}...'.format(filename)
97 print 'Add {}'.format(f)
100 print 'Add {}'.format(f[0])
114 print ' {:20} <== {}'.format(item.dest, item.src)
117 print ' {}'.format(item)
Dgsi_util.py44 logging.basicConfig(format=self._LOGGING_FORMAT, level=self._LOGGING_LEVEL)
49 version='%(prog)s {}'.format(self._GSI_UTIL_VERSION))
/development/tools/mkstubs/src/com/android/mkstubs/sourcer/
DOutput.java51 public void write(String format, Object... args) { in write() argument
53 mWriter.write(String.format(format, args)); in write()
/development/gsi/gsi_util/gsi_util/mounters/
Dcomposite_mounter.py60 raise ValueError('Wrong partition name "{}"'.format(partition))
66 path_prefix = '/{}/'.format(partition)
76 raise ValueError('Unknown target "{}"'.format(mount_target))
126 mount_point = '/{}/'.format(partition)
/development/gsi/gsi_util/gsi_util/utils/
Ddebugfs.py37 debugfs_command = 'dump {} {}'.format(file_spec, out_file)
57 debugfs_command = 'stat {}'.format(file_spec)
70 assert m is not None, '{} outputs with an unknown format.'.format(_DEBUGFS)
/development/samples/browseable/BluetoothLeGatt/src/com.example.android.bluetoothlegatt/
DBluetoothLeService.java131 int format = -1; in broadcastUpdate() local
133 format = BluetoothGattCharacteristic.FORMAT_UINT16; in broadcastUpdate()
136 format = BluetoothGattCharacteristic.FORMAT_UINT8; in broadcastUpdate()
139 final int heartRate = characteristic.getIntValue(format, 1); in broadcastUpdate()
140 Log.d(TAG, String.format("Received heart rate: %d", heartRate)); in broadcastUpdate()
148 stringBuilder.append(String.format("%02X ", byteChar)); in broadcastUpdate()
/development/vndk/tools/definition-tool/tests/
Dtest_elf_linker.py344 self.assertIn('/system/{}/libsp_both_vs.so'.format(lib_dir),
348 self.assertIn('/system/{}/libcutils.so'.format(lib_dir),
350 self.assertIn('/system/{}/libcutils_dep.so'.format(lib_dir),
352 self.assertIn('/system/{}/libutils.so'.format(lib_dir),
356 self.assertIn('/system/{}/libhidlbase.so'.format(lib_dir),
358 self.assertIn('/system/{}/libhidlmemory.so'.format(lib_dir),
362 self.assertIn('/vendor/{}/libllvm_vendor.so'.format(lib_dir),
364 self.assertIn('/vendor/{}/libllvm_vendor_dep.so'.format(lib_dir),
368 self.assertIn('/vendor/{}/egl/libEGL_chipset.so'.format(lib_dir),
372 self.assertIn('/system/{}/libEGL.so'.format(lib_dir), ll_ndk)
[all …]
/development/samples/browseable/DirectorySelection/src/com.example.android.directoryselection/
DDirectorySelectionFragment.java136 Log.d(TAG, String.format("Open Directory result Uri : %s", data.getData())); in onActivityResult()
204 Log.i(TAG, String.format( in createDirectory()
207 Toast.makeText(getActivity(), String.format("Created a directory [%s]", in createDirectory()
210 Log.w(TAG, String.format("Failed to create a directory : %s, Uri %s", directoryName, in createDirectory()
212 Toast.makeText(getActivity(), String.format("Failed to created a directory [%s] : ", in createDirectory()
/development/samples/browseable/ClippingBasic/src/com.example.android.clippingbasic/
DClippingBasicFragment.java86 Log.d(TAG, String.format("Clipping to outline is disabled")); in onViewCreated()
92 Log.d(TAG, String.format("Clipping to outline is enabled")); in onViewCreated()
120 Log.d(TAG, String.format("Text was changed.")); in changeText()
/development/tools/mkstubs/src/com/android/mkstubs/
DFilterClassAdapter.java76 String filterName = String.format("%s#%s", mClassName, name); in visitField()
108 String filterName = String.format("%s#%s%s", mClassName, name, desc); in visitMethod()
117 filterName = String.format("%s#%s%s", mClassName, name, signature); in visitMethod()
/development/tools/core_connectivity/
Dcheck_style.sh26 $ANDROID_BUILD_TOP/prebuilts/clang/host/linux-x86/clang-stable/bin/git-clang-format \
30 local MSG=`git rev-list --format=%B --max-count=1 HEAD`

1234567