code: @Override
    public byte[] transformOut(JdbcPreparedStatementFactory jpsf, byte[] attributeObject) throws CpoException {
  
      byte[] retBytes = null;
  
      ByteArrayOutputStream baos = new ByteArrayOutputStream();
  
      try {
        if (attributeObject != null) {
          if (attributeObject.length > 0) {
            GZIPOutputStream os = new GZIPOutputStream(baos);
  
            os.write(attributeObject);
            os.flush();
            os.close();
  
            baos.flush();
            baos.close();
            retBytes = baos.toByteArray();
          } else {
            retBytes = new byte[0];
          }
        }
      } catch (Exception e) {
        String msg = "Error GZipping Byte Array";
        logger.error(msg, e);
        throw new CpoException(msg, e);
      }
      return retBytes;
    }
docs: Transforms the data from the class attribute to the object required by the datasource
  
  @param cpoAdapter The CpoAdapter for the datasource where the attribute is being persisted
  @param parentObject The object that contains the attribute being persisted.
  @param attributeObject The object that represents the attribute being persisted.
  @return The object to be stored in the datasource
  @throws CpoException