I need to create a report with headers (Male, Female ...) inside (between) data rows.
I know how to group headers of columns from vaadin docs. But how to create headers between rows?
The Grid in Vaadin8 does not have this feature as is. However you could consider TreeGrid component as alternative. The outcome will not be exactly same, but quite near though. I would have "Female" and "Male" as parent nodes and then all the females and males as childs to them.
If the data source is small it is possible to implemente design above. with GridLayout, since you probably do not need lazy loading for data, and thus can keep boiler plate for custom component based on GridLayout relatively simple. With GridLayout design in the picture is possible, by using e.g. addComponent(Component component, int column1, int row1, int column2, int row2) method for the headers Male and Female.