Packagecom.adobe.photoshop.utils
Classpublic class Util
InheritanceUtil Inheritance Object

Language Version : ActionScript 3.0
Runtime Versions : AIR 1.0, Flash Player 10

A class that tends to contain static helper functions, which are mostly useful for the internal API. However, if you're extending the functionality of this API in your own code, you maay find its methods useful.



Public Methods
 MethodDefined By
  
Constructor
Util
  
replaceParams(textToModify:String, ... rest):String
[static] Takes a string of text that contains parameters in the format of $1, $2, $3, ...
Util
Constructor Detail
Util()Constructor
public function Util()

Language Version : ActionScript 3.0
Runtime Versions : AIR 1.0, Flash Player 10

Constructor

Method Detail
replaceParams()method
public static function replaceParams(textToModify:String, ... rest):String

Runtime Versions : AIR 1.0, Flash Player 10

Takes a string of text that contains parameters in the format of $1, $2, $3, ... , $n , and expects an array of n length. The function will cycle through the available parameters and replace the tokens in the input string, in order. If the number of parameters is less than the number of tokens in the string, the output will still contain the tokens.

Parameters

textToModify:String — The input string that contains tokens of the form $1, $2, $3, ... , $n
 
... rest — rest . A number of Strings, containing the text that should be placed into the tokens

Returns
String — Returns the modified version of the input string