Times like this it might feel more concise to do:

```
case id
  when 0; return "host"
  when 2; return "plugin"
  ...
end
```

At your preference.