public static <T> FactoryExpression<T> createProjection(RelationalPath<T> path) {
        if (path.getType().equals(path.getClass())) {
            throw new IllegalArgumentException("RelationalPath based projection can only be used with generated Bean types");
        }
        try {
            // ensure that empty constructor is available
            path.getType().getConstructor();
            return createBeanProjection(path);
        } catch (NoSuchMethodException e) {
            // fallback to constructor projection
            return createConstructorProjection(path);
        }
    }
{@code RelationalPathUtils} provides static utility methods for {@link RelationalPath} instances

@author tiwe
querydsl-sql/src/main/java/com/querydsl/sql/RelationalPathUtils.java