Please enable JavaScript to view this site.

ESL Documentation

Object parameters are very useful when you wish to specify a response definition for a class of objects, and then perform distinct action statements for each of the members of the class. In such a case, you can specify, as the parameter attribute, an identifying string. In the following example, the parameter of each object is used to have different cities become visible.

 

key Northeast ...

    parameter is "Boston"

 

key Midwest ...

    parameter is "Chicago"

 

key Southeast ...

    parameter is "Atlanta"

 

class Districts in Northeast Midwest Southeast

 

response to Districts                # When Districts is

    copy parameter to Headquarters   # selected, the city

    make Headquarters visible        # name is displayed.

 

Be careful not to confuse the parameter function with the parameter of function. The parameter of function is an object inquiry built-in function, returning the parameter string associated with the object whose name is specified as the argument to the function. See Using Functions to Inquire about Attributes for details on the use of the parameter of function.