@args
and array values containing the string names of the arguments:
@args [ CARD ] # or @args.0 CARD
@args
and the argument name. The type and the default value are specified in the compound block:
@args.CARD { type string default "abcd" }
card $CARD
hw:0,1 hw:CARD=0,DEV=1 hw:{CARD 0 DEV 1} plug:"hw:0,1" plug:{SLAVE="hw:{CARD 0 DEV 1}"}
As you see, arguments can be specified in their proper order or by name. Note that arguments enclosed in braces are parsed in the same way as in configuration files, but using the override method by default.
pcm.demo { @args [ CARD DEVICE ] @args.CARD { type string default "supersonic" } @args.DEVICE { type integer default 0 } type hw card $CARD device $DEVICE }