io.seventytwo.vaadinjooq.RecordGrid Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of vaadin-jooq Show documentation
Show all versions of vaadin-jooq Show documentation
Integrates Vaadin with jOOQ
The newest version!
package io.seventytwo.vaadinjooq;
import com.vaadin.flow.component.grid.Grid;
import org.jooq.Record;
import org.jooq.TableField;
import java.util.Arrays;
import java.util.List;
import java.util.stream.Collectors;
public class RecordGrid extends Grid {
public RecordGrid(Class clazz) {
super(clazz);
}
public void setColumns(TableField, ?>... fields) {
List propertyNames = Arrays.stream(fields).map(field -> JooqUtil.getPropertyName(field)).collect(Collectors.toList());
super.setColumns(propertyNames.toArray(new String[propertyNames.size()]));
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy