Re: Is it possible to use standard JavaScript methods with Installer classes/objects?
site_archiver@lists.apple.com Delivered-To: installer-dev@lists.apple.com Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=NmDbCqo9z4i4pNg9iNncUJoapwJKir8RgOVAHQw/g5k=; b=l7swdFx0Fqj3z3YF4ZkRPVv4mSXhtDYVu5m2E66zuZY0CYXUV5qrUVk+lc/buQDdCY Qeu0JhKyg5ZBTBnzf7KdDtlXlUYFvdJJmEvLnAGHV5+sz1J9RElYaQwhll/Fx5Vk7+Vv dB1FpzTm0NhfnZQeDm7ax81ZCsyNXsuEmCnCE= Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=I2RNizSQ8Qfjk5clErLuTJ+uzdl2+jE8Wu/E2ZOlIdV+KIf7K/vPMJcb2mrCmIa6wK xREdKI9AN76HwGN3ebkMkdX/SemtY/NeUQ+9Qc+YaRiWuGrK3daUvJGcxKFeXqUfcxd/ z3gRgstRC5Fkw4DNz6+yNYztKhRZ2ObvPiSF4= You could pass it a piece of JSON and eval it, that way your array or object "sneaks past" the function prototype. 2009/3/18 Iceberg-Dev <dev.iceberg@gmail.com>:
I would like to execute the system.run function by passing it an array of arguments instead of a variable list of arguments.
From what I gather in the JavaScript reference book from O'Reilly, it would look something like this:
system.run.apply(null,tArrayOfArguments)
Unfortunately, the JavaScript runtime is not happy with this and trigger an exception (on Tiger and Leopard):
Mar 19 00:02:44 Selene : JavaScript error "Value undefined (result of expression system.run.apply) is not object." while running "__choice_function1"
Mar 19 00:02:44 Selene : __choice_function1 returned error: Value undefined (result of expression system.run.apply) is not object.
allow-external-scripts is set to "yes"
I tried multiple variations such as:
system.run.apply(system,tArrayOfArguments)
run.apply(system,tArrayOfArguments)
with no success.
I looked at the release notes for Installer (on Tiger), the Installer JavaScript Reference documentation but I'm still clueless.
Is it possible to do this?
_______________________________________________ Do not post admin requests to the list. They will be ignored. Installer-dev mailing list (Installer-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/installer-dev/el.dodgero%40gmail.com
This email sent to el.dodgero@gmail.com
-- Dodger _______________________________________________ Do not post admin requests to the list. They will be ignored. Installer-dev mailing list (Installer-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/installer-dev/site_archiver%40lists.a... This email sent to site_archiver@lists.apple.com
participants (1)
-
Dodger