Examples of DigestContentHolder


Examples of com.google.enterprise.connector.db.diffing.DigestContentHolder

    ResultSetMetaData rsmd = createMock(ResultSetMetaData.class);
    expect(rsmd.getColumnType(anyInt())).andReturn(jdbcType).atLeastOnce();
    expect(rs.getMetaData()).andReturn(rsmd).atLeastOnce();
    replay(rsmd, rs);

    DigestContentHolder holder = new LobTypeHandler().getNullableResult(rs, 1);
    verify(rsmd, rs);

    // SQL NULLs are rendered as empty byte arrays for easier handling.
    Object content = holder.getContent();
    assertTrue(content.getClass().toString(),
        content instanceof InputStreamFactory);
    assertEquals(-1, ((InputStreamFactory) content).getInputStream().read());
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.