if becomes the name of the xblock class:

```python
class MyXBlock:
   ...
```

I took the code from the XBlock repo. I could not find an easy way to reuse it without copying it.