Lines Matching refs:args

44     for (const auto& arg : args) { \
53 Result<void> check_chown(const BuiltinArguments& args) { in check_chown() argument
54 if (!args[1].empty()) { in check_chown()
55 auto uid = DecodeUid(args[1]); in check_chown()
57 return Error() << "Unable to decode UID for '" << args[1] << "': " << uid.error(); in check_chown()
62 if (args.size() == 4 && !args[2].empty()) { in check_chown()
63 auto gid = DecodeUid(args[2]); in check_chown()
65 return Error() << "Unable to decode GID for '" << args[2] << "': " << gid.error(); in check_chown()
72 Result<void> check_exec(const BuiltinArguments& args) { in check_exec() argument
75 auto result = Service::MakeTemporaryOneshotService(args.args); in check_exec()
83 Result<void> check_exec_background(const BuiltinArguments& args) { in check_exec_background() argument
84 return check_exec(std::move(args)); in check_exec_background()
87 Result<void> check_exec_reboot_on_failure(const BuiltinArguments& args) { in check_exec_reboot_on_failure() argument
88 BuiltinArguments remaining_args{.context = args.context}; in check_exec_reboot_on_failure()
90 remaining_args.args = std::vector<std::string>(args.begin() + 1, args.end()); in check_exec_reboot_on_failure()
91 remaining_args.args[0] = args[0]; in check_exec_reboot_on_failure()
96 Result<void> check_interface_restart(const BuiltinArguments& args) { in check_interface_restart() argument
97 if (auto result = IsKnownInterface(args[1]); !result.ok()) { in check_interface_restart()
103 Result<void> check_interface_start(const BuiltinArguments& args) { in check_interface_start() argument
104 return check_interface_restart(std::move(args)); in check_interface_start()
107 Result<void> check_interface_stop(const BuiltinArguments& args) { in check_interface_stop() argument
108 return check_interface_restart(std::move(args)); in check_interface_stop()
111 Result<void> check_load_system_props(const BuiltinArguments& args) { in check_load_system_props() argument
115 Result<void> check_loglevel(const BuiltinArguments& args) { in check_loglevel() argument
119 ParseInt(args[1], &log_level); in check_loglevel()
126 Result<void> check_mount_all(const BuiltinArguments& args) { in check_mount_all() argument
127 auto options = ParseMountAll(args.args); in check_mount_all()
134 Result<void> check_mkdir(const BuiltinArguments& args) { in check_mkdir() argument
135 auto options = ParseMkdir(args.args); in check_mkdir()
142 Result<void> check_restorecon(const BuiltinArguments& args) { in check_restorecon() argument
145 auto restorecon_info = ParseRestorecon(args.args); in check_restorecon()
153 Result<void> check_restorecon_recursive(const BuiltinArguments& args) { in check_restorecon_recursive() argument
154 return check_restorecon(std::move(args)); in check_restorecon_recursive()
157 Result<void> check_setprop(const BuiltinArguments& args) { in check_setprop() argument
158 const std::string& name = args[1]; in check_setprop()
162 const std::string& value = args[2]; in check_setprop()
197 Result<void> check_setrlimit(const BuiltinArguments& args) { in check_setrlimit() argument
200 auto rlimit = ParseRlimit(args.args); in check_setrlimit()
205 Result<void> check_swapon_all(const BuiltinArguments& args) { in check_swapon_all() argument
206 auto options = ParseSwaponAll(args.args); in check_swapon_all()
213 Result<void> check_sysclktz(const BuiltinArguments& args) { in check_sysclktz() argument
217 if (!android::base::ParseInt(args[1], &tz.tz_minuteswest)) { in check_sysclktz()
223 Result<void> check_umount_all(const BuiltinArguments& args) { in check_umount_all() argument
224 auto options = ParseUmountAll(args.args); in check_umount_all()
231 Result<void> check_wait(const BuiltinArguments& args) { in check_wait() argument
232 if (args.size() == 3 && !args[2].empty()) { in check_wait()
234 if (!android::base::ParseDouble(args[2], &timeout_double, 0)) { in check_wait()
241 Result<void> check_wait_for_prop(const BuiltinArguments& args) { in check_wait_for_prop() argument
242 return check_setprop(std::move(args)); in check_wait_for_prop()