defined with an annotation:
@DocumentationProvider(MyDocumentationProvider.class)
public interface MyDomElement extends DomElement {
.....
}
where the class given in the annotation implements an interface similar to com.intellij.lang.documentation.DocumentationProvider with a method "String getDocumentation(DomElement element)"