Classes can have parameters. Parameters behave like class members initialised from arguments to the class constructor. For example:
My_pasta pasta_name cooked = class { is_ready t = "your " ++ pasta_name ++ " is " ++ state { state = "underdone!", t < cooked = "perfect", t == cooked = "yuk!"; } }
This defines a class called My_pasta which takes a pasta name and a cooking time as parameters. Once you have made an instance of My_pasta, you can test if it's been cooked at a certain time with the is_ready member. For example:
tele = My_pasta "telephoni" 10; tele.is_ready 5 == "your telephoni " ++ "is underdone!"