I grabbed this code form some book I've bumped on the InternetS... 

```
sm: new Ext.grid.RowSelectionModel({
   singleSelect: true,
   listeners: {
       rowselect: {
           fn: function(sm,index,record) {
               Ext.Msg.alert('You Selected',record.data.title);
           }
       }
   }
});

```

now, `sm` is shorthand for selection model, we're discussing a ExtJS GridPanel here... Everything is clear until the `fn:` part. AFAIK, an anonymous function is passed with 3 parameters: sm, index, and record.

Right now I'm about to get down votes for asking something extremely trivial: how do you know which parameters you should pass? If I omit index parameter, I'll get an error... Why do I *must* pass 3 parameters? What's the catch?