io.protostuff.Input.readBool()方法的使用及代码示例

x33g5p2x  于2022-01-21 转载在 其他  
字(6.0k)|赞(0)|评价(0)|浏览(220)

本文整理了Java中io.protostuff.Input.readBool()方法的一些代码示例,展示了Input.readBool()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Input.readBool()方法的具体详情如下:
包路径:io.protostuff.Input
类名称:Input
方法名:readBool

Input.readBool介绍

[英]Reads a boolean field value.
[中]读取布尔字段值。

代码示例

代码示例来源:origin: protostuff/protostuff

@Override
public boolean readBool() throws IOException
{
  return input.readBool();
}

代码示例来源:origin: protostuff/protostuff

@Override
public Boolean readFrom(Input input) throws IOException
{
  return input.readBool() ? Boolean.TRUE : Boolean.FALSE;
}

代码示例来源:origin: protostuff/protostuff

@Override
public Boolean readFrom(Input input) throws IOException
{
  return input.readBool() ? Boolean.TRUE : Boolean.FALSE;
}

代码示例来源:origin: protostuff/protostuff

@Override
public Boolean readFrom(Input input) throws IOException
{
  return input.readBool() ? Boolean.TRUE : Boolean.FALSE;
}

代码示例来源:origin: protostuff/protostuff

@Override
public void transfer(Pipe pipe, Input input, Output output, int number,
    boolean repeated) throws IOException
{
  output.writeBool(number, input.readBool(), repeated);
}

代码示例来源:origin: protostuff/protostuff

@Override
public void transfer(Pipe pipe, Input input, Output output, int number,
    boolean repeated) throws IOException
{
  output.writeBool(number, input.readBool(), repeated);
}

代码示例来源:origin: protostuff/protostuff

@Override
public void transfer(Pipe pipe, Input input, Output output, int number,
    boolean repeated) throws IOException
{
  output.writeBool(number, input.readBool(), repeated);
}

代码示例来源:origin: protostuff/protostuff

protected Object readPrimitiveFrom(Input input, Object owner, int len)
    throws IOException
{
  boolean[] array = new boolean[len];
  if (input instanceof GraphInput)
  {
    // update the actual reference.
    ((GraphInput) input).updateLast(array, owner);
  }
  for (int i = 0; i < len; i++)
  {
    if (ID_ARRAY_DATA != input.readFieldNumber(this))
      throw new ProtostuffException("Corrupt input.");
    array[i] = input.readBool();
  }
  if (0 != input.readFieldNumber(this))
    throw new ProtostuffException("Corrupt input.");
  return array;
}

代码示例来源:origin: protostuff/protostuff

protected Object readPrimitiveFrom(Input input, Object owner, int len)
    throws IOException
{
  boolean[] array = new boolean[len];
  if (input instanceof GraphInput)
  {
    // update the actual reference.
    ((GraphInput) input).updateLast(array, owner);
  }
  for (int i = 0; i < len; i++)
  {
    if (ID_ARRAY_DATA != input.readFieldNumber(this))
      throw new ProtostuffException("Corrupt input.");
    array[i] = input.readBool();
  }
  if (0 != input.readFieldNumber(this))
    throw new ProtostuffException("Corrupt input.");
  return array;
}

代码示例来源:origin: protostuff/protostuff

protected Object readBoxedFrom(Input input, Object owner, int len)
    throws IOException
{
  final Boolean[] array = new Boolean[len];
  if (input instanceof GraphInput)
  {
    // update the actual reference.
    ((GraphInput) input).updateLast(array, owner);
  }
  for (int i = 0; i < len;)
  {
    switch (input.readFieldNumber(this))
    {
      case ID_ARRAY_DATA:
        array[i++] = input.readBool();
        break;
      case ID_ARRAY_NULLCOUNT:
        i += input.readUInt32();
        break;
      default:
        throw new ProtostuffException("Corrupt input.");
    }
  }
  if (0 != input.readFieldNumber(this))
    throw new ProtostuffException("Corrupt input.");
  return array;
}

代码示例来源:origin: protostuff/protostuff

protected Object readBoxedFrom(Input input, Object owner, int len)
    throws IOException
{
  final Boolean[] array = new Boolean[len];
  if (input instanceof GraphInput)
  {
    // update the actual reference.
    ((GraphInput) input).updateLast(array, owner);
  }
  for (int i = 0; i < len;)
  {
    switch (input.readFieldNumber(this))
    {
      case ID_ARRAY_DATA:
        array[i++] = input.readBool();
        break;
      case ID_ARRAY_NULLCOUNT:
        i += input.readUInt32();
        break;
      default:
        throw new ProtostuffException("Corrupt input.");
    }
  }
  if (0 != input.readFieldNumber(this))
    throw new ProtostuffException("Corrupt input.");
  return array;
}

代码示例来源:origin: protostuff/protostuff

if (message.someBoolean == null)
    message.someBoolean = new ArrayList<Boolean>();
  message.someBoolean.add(input.readBool());
  break;
case 7:

代码示例来源:origin: protostuff/protostuff

break;
case 6:
  message.someBoolean = input.readBool();
  break;
case 7:

代码示例来源:origin: org.apache.servicecomb/foundation-protobuf

@Override
public Object readFrom(Input input) throws IOException {
 return input.readBool();
}

代码示例来源:origin: org.apache.servicecomb/foundation-protobuf

@Override
public void mergeFrom(Input input, Object message) throws IOException {
 setter.set(message, input.readBool());
}

代码示例来源:origin: dremio/dremio-oss

public void mergeFrom(Input input, Ack message) throws IOException
{
  for(int number = input.readFieldNumber(this);; number = input.readFieldNumber(this))
  {
    switch(number)
    {
      case 0:
        return;
      case 1:
        message.ok = input.readBool();
        break;
      default:
        input.handleUnknownField(number, this);
    }   
  }
}

代码示例来源:origin: dremio/dremio-oss

public void mergeFrom(Input input, ParquetFileConfig message) throws IOException
{
  for(int number = input.readFieldNumber(this);; number = input.readFieldNumber(this))
  {
    switch(number)
    {
      case 0:
        return;
      case 1:
        message.autoCorrectCorruptDates = input.readBool();
        break;
      default:
        input.handleUnknownField(number, this);
    }   
  }
}

代码示例来源:origin: NationalSecurityAgency/datawave

@Override
public void mergeFrom(Input input, EdgeSummaryQueryMessage message) throws IOException {
  int number;
  while ((number = input.readFieldNumber(this)) != 0) {
    switch (number) {
      case 1:
        message.scanLimitHit = input.readBool();
        break;
      case 2:
        message.queryLogicWarning = input.readString();
        break;
      default:
        input.handleUnknownField(number, this);
        break;
    }
  }
}

代码示例来源:origin: dremio/dremio-oss

public void mergeFrom(Input input, AccelerationData message) throws IOException
{
  for(int number = input.readFieldNumber(this);; number = input.readFieldNumber(this))
  {
    switch(number)
    {
      case 0:
        return;
      case 1:
        message.enabled = input.readBool();
        break;
      case 2:
        if(message.info == null)
          message.info = new ArrayList<Info>();
        message.info.add(input.mergeObject(null, Info.getSchema()));
        break;
      default:
        input.handleUnknownField(number, this);
    }   
  }
}

代码示例来源:origin: dremio/dremio-oss

public void mergeFrom(io.protostuff.Input input, com.dremio.exec.proto.GeneralRPCProtos.Ack.Builder builder) throws java.io.IOException
{
  for(int number = input.readFieldNumber(this);; number = input.readFieldNumber(this))
  {
    switch(number)
    {
      case 0:
        return;
      case 1:
        builder.setOk(input.readBool());
        break;
      default:
        input.handleUnknownField(number, this);
    }
  }
}
public boolean isInitialized(com.dremio.exec.proto.GeneralRPCProtos.Ack.Builder builder)

相关文章