title: JPA - analog of LobCreator from hibernate?
body: <p>in pure Hibernate i can do:</p>
  
  <pre><code>Blob blob= Hibernate.getLobCreator(sessionFactory.getCurrentSession()).createBlob(inputStream, len);
  </code></pre>
  
  <p>How to do this in jpa (with hibernate as  provider)?</p>
  
  <p>In pure hibernate i made user type for blobs, which used <code>setBinaryStream</code> prepared statement. This solution worked for me perfectly and i'm looking for a way to port it to JPA.</p>