getopt
(New page: {{DavinciWiki_Function| A nice way to deal with command line options for specific davinci scripts| Input: A structure (generally called opt) with all of the desired elements. Output: ...) |
|||
Line 30: | Line 30: | ||
*[[opt_usage]] | *[[opt_usage]] | ||
| | | | ||
+ | *misc.dvrc | ||
+ | | | ||
+ | 1.69 | ||
}} | }} | ||
[[category:Functions]] | [[category:Functions]] | ||
[[category:User Defined Functions]] | [[category:User Defined Functions]] | ||
[[category:Miscellaneous]] | [[category:Miscellaneous]] |
Revision as of 01:14, 12 January 2008
Contents: Description, Arguments, Usage, Examples, Sub-Functions, Related Functions, Source Supported Under Version: > 1.69
Description A nice way to deal with command line options for specific davinci scripts
Arguments and Return Values Input: A structure (generally called opt) with all of the desired elements. Output: A structure with the same elements but with some changes reflecting the command line
Usage Syntax: getopt( $ARGV, opt = VAL)
Examples Options given on the command line before davinci is started 1% davinci filename="TEST" size=100 loading history dv> Now we will set up the structure getopt() needs with default values dv> opt={ filename="default", size=300, input="myfile.png"} struct, 3 elements filename: "default" size: 300 input: "myfile.png" Next we will run getopt() and the specified values will be filled in dv> opt2=getopt($ARGV,opt) struct, 3 elements input: "myfile.png" size: "100" filename: "TEST" |
DavinciWiki Mini-Nav Bar Contents
Contact Developers
All other topics
Major Sub-Functions
Related Functions
Recent Library Changes Created On: 06-18-2007 |