Tabnine Logo
PGStream.Receive
Code IndexAdd Tabnine to your IDE (free)

How to use
Receive
method
in
org.postgresql.core.PGStream

Best Java code snippets using org.postgresql.core.PGStream.Receive (Showing top 20 results out of 315)

origin: postgresql/postgresql

/**
 * Reads in a given number of bytes from the backend
 *
 * @param siz number of bytes to read
 * @return array of bytes received
 * @exception IOException if a data I/O error occurs
 */
public byte[] Receive(int siz) throws IOException
{
  byte[] answer = new byte[siz];
  Receive(answer, 0, siz);
  return answer;
}
origin: postgresql/postgresql

private String receiveCommandStatus() throws IOException {
  //TODO: better handle the msg len
  int l_len = pgStream.ReceiveInteger4();
  //read l_len -5 bytes (-4 for l_len and -1 for trailing \0)
  String status = pgStream.ReceiveString(l_len - 5);
  //now read and discard the trailing \0
  pgStream.Receive(1);
  if (logger.logDebug())
    logger.debug(" <=BE CommandStatus(" + status + ")");
  return status;
}
origin: postgresql/postgresql

try {
  answer[i] = new byte[l_size];
  Receive(answer[i], 0, l_size);
} catch(OutOfMemoryError oome) {
  oom = oome;
origin: postgresql/postgresql

  int type = pgStream.ReceiveInteger4();
  inToken = pgStream.Receive(len - 8);
} else {
origin: postgresql/postgresql

pgStream.Receive(buf, 0, valueLen);
returnValue = buf;
origin: postgresql/postgresql

byte[] bitmask = Receive(bim);
byte[][] answer = new byte[nf][];
    try {
      answer[i] = new byte[len];
      Receive(answer[i], 0, len);
    } catch(OutOfMemoryError oome) {
      oom = oome;
origin: postgresql/postgresql

byte[] salt = pgStream.Receive(2);
byte[] md5Salt = pgStream.Receive(4);
if (logger.logDebug())
origin: postgresql/postgresql

result = pgStream.Receive(len);
c = pgStream.ReceiveChar();
origin: org.ancoron.postgresql/org.postgresql.osgi

private String receiveCommandStatus() throws IOException {
  //TODO: better handle the msg len
  int l_len = pgStream.ReceiveInteger4();
  //read l_len -5 bytes (-4 for l_len and -1 for trailing \0)
  String status = pgStream.ReceiveString(l_len - 5);
  //now read and discard the trailing \0
  pgStream.Receive(1);
  if (logger.logDebug())
    logger.debug(" <=BE CommandStatus(" + status + ")");
  return status;
}
origin: org.ancoron.postgresql/org.postgresql.osgi

try {
  answer[i] = new byte[l_size];
  Receive(answer[i], 0, l_size);
} catch(OutOfMemoryError oome) {
  oom = oome;
origin: org.ancoron.postgresql/org.postgresql.osgi

byte[] bitmask = Receive(bim);
byte[][] answer = new byte[nf][];
    try {
      answer[i] = new byte[len];
      Receive(answer[i], 0, len);
    } catch(OutOfMemoryError oome) {
      oom = oome;
origin: org.ancoron.postgresql/org.postgresql.osgi

/**
 * Reads in a given number of bytes from the backend
 *
 * @param siz number of bytes to read
 * @return array of bytes received
 * @exception IOException if a data I/O error occurs
 */
public byte[] Receive(int siz) throws IOException
{
  byte[] answer = new byte[siz];
  Receive(answer, 0, siz);
  return answer;
}
origin: postgresql/postgresql

byte salt[] = pgStream.Receive(2);
byte[] md5Salt = pgStream.Receive(4);
if (logger.logDebug())
  logger.debug(" <=BE AuthenticationReqMD5(salt=" + Utils.toHexString(md5Salt) + ")");
origin: postgresql/postgresql

byte[] buf = pgStream.Receive(len);
if(op == null) {
  error = new PSQLException(GT.tr("Got CopyData without an active copy operation"), PSQLState.OBJECT_NOT_IN_STATE);
  pgStream.Receive(len); // not in specification; should never appear
origin: org.ancoron.postgresql/org.postgresql

private String receiveCommandStatus() throws IOException {
  //TODO: better handle the msg len
  int l_len = pgStream.ReceiveInteger4();
  //read l_len -5 bytes (-4 for l_len and -1 for trailing \0)
  String status = pgStream.ReceiveString(l_len - 5);
  //now read and discard the trailing \0
  pgStream.Receive(1);
  if (logger.logDebug())
    logger.debug(" <=BE CommandStatus(" + status + ")");
  return status;
}
origin: org.ancoron.postgresql/org.postgresql

try {
  answer[i] = new byte[l_size];
  Receive(answer[i], 0, l_size);
} catch(OutOfMemoryError oome) {
  oom = oome;
origin: org.ancoron.postgresql/org.postgresql

/**
 * Reads in a given number of bytes from the backend
 *
 * @param siz number of bytes to read
 * @return array of bytes received
 * @exception IOException if a data I/O error occurs
 */
public byte[] Receive(int siz) throws IOException
{
  byte[] answer = new byte[siz];
  Receive(answer, 0, siz);
  return answer;
}
origin: org.ancoron.postgresql/org.postgresql

  int type = pgStream.ReceiveInteger4();
  inToken = pgStream.Receive(len - 8);
} else {
origin: org.ancoron.postgresql/org.postgresql.osgi

pgStream.Receive(buf, 0, valueLen);
returnValue = buf;
origin: org.ancoron.postgresql/org.postgresql.osgi

result = pgStream.Receive(len);
c = pgStream.ReceiveChar();
org.postgresql.corePGStreamReceive

Javadoc

Reads in a given number of bytes from the backend

Popular methods of PGStream

  • <init>
    Constructor: Connect to the PostgreSQL back end and return a stream connection.
  • changeSocket
    Switch this stream to using a new socket. Any existing socket is not closed; it's assumed that we ar
  • close
    Closes the connection.
  • flush
    Flush any pending output to the backend.
  • getEncoding
  • getSocket
  • hasMessagePending
    Check for pending backend messages without blocking. Might return false when there actually are mess
  • setEncoding
    Change the encoding used by this connection.
  • ReceiveChar
    Receives a single character from the backend
  • ReceiveEOF
    Consume an expected EOF from the backend
  • ReceiveInteger2
    Receives a two byte integer from the backend
  • ReceiveInteger4
    Receives a four byte integer from the backend
  • ReceiveInteger2,
  • ReceiveInteger4,
  • ReceiveString,
  • ReceiveTupleV2,
  • ReceiveTupleV3,
  • Send,
  • SendChar,
  • SendInteger2,
  • SendInteger4

Popular in Java

  • Running tasks concurrently on multiple threads
  • setScale (BigDecimal)
  • setContentView (Activity)
  • notifyDataSetChanged (ArrayAdapter)
  • Rectangle (java.awt)
    A Rectangle specifies an area in a coordinate space that is enclosed by the Rectangle object's top-
  • File (java.io)
    An "abstract" representation of a file system entity identified by a pathname. The pathname may be a
  • ServerSocket (java.net)
    This class represents a server-side socket that waits for incoming client connections. A ServerSocke
  • ResourceBundle (java.util)
    ResourceBundle is an abstract class which is the superclass of classes which provide Locale-specifi
  • HttpServletRequest (javax.servlet.http)
    Extends the javax.servlet.ServletRequest interface to provide request information for HTTP servlets.
  • Base64 (org.apache.commons.codec.binary)
    Provides Base64 encoding and decoding as defined by RFC 2045.This class implements section 6.8. Base
  • Top 12 Jupyter Notebook extensions
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now