CMS-3082 Introduce TextComponent in Java
Moved some Json-generating classes to api module