qcloud.storage.ranger.thirdparty.org.apache.zookeeper.server.quorum.QuorumPacket Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of hadoop-ranger-client-for-impala Show documentation
Show all versions of hadoop-ranger-client-for-impala Show documentation
Tencent Qcloud chdfs hadoop ranger client.
// File generated by hadoop record compiler. Do not edit.
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package qcloud.storage.ranger.thirdparty.org.apache.zookeeper.server.quorum;
import org.apache.jute.*;
public class QuorumPacket implements Record {
private int type;
private long zxid;
private byte[] data;
private java.util.List authinfo;
public QuorumPacket() {
}
public QuorumPacket(
int type,
long zxid,
byte[] data,
java.util.List authinfo) {
this.type=type;
this.zxid=zxid;
this.data=data;
this.authinfo=authinfo;
}
public int getType() {
return type;
}
public void setType(int m_) {
type=m_;
}
public long getZxid() {
return zxid;
}
public void setZxid(long m_) {
zxid=m_;
}
public byte[] getData() {
return data;
}
public void setData(byte[] m_) {
data=m_;
}
public java.util.List getAuthinfo() {
return authinfo;
}
public void setAuthinfo(java.util.List m_) {
authinfo=m_;
}
public void serialize(OutputArchive a_, String tag) throws java.io.IOException {
a_.startRecord(this,tag);
a_.writeInt(type,"type");
a_.writeLong(zxid,"zxid");
a_.writeBuffer(data,"data");
{
a_.startVector(authinfo,"authinfo");
if (authinfo!= null) { int len1 = authinfo.size();
for(int vidx1 = 0; vidx1();
for (; !vidx1.done(); vidx1.incr()) {
qcloud.storage.ranger.thirdparty.org.apache.zookeeper.data.Id e1;
e1= new qcloud.storage.ranger.thirdparty.org.apache.zookeeper.data.Id();
a_.readRecord(e1,"e1");
authinfo.add(e1);
}
}
a_.endVector("authinfo");
}
a_.endRecord(tag);
}
public String toString() {
try {
java.io.ByteArrayOutputStream s =
new java.io.ByteArrayOutputStream();
CsvOutputArchive a_ =
new CsvOutputArchive(s);
a_.startRecord(this,"");
a_.writeInt(type,"type");
a_.writeLong(zxid,"zxid");
a_.writeBuffer(data,"data");
{
a_.startVector(authinfo,"authinfo");
if (authinfo!= null) { int len1 = authinfo.size();
for(int vidx1 = 0; vidx1>>32));
result = 37*result + ret;
ret = java.util.Arrays.toString(data).hashCode();
result = 37*result + ret;
ret = authinfo.hashCode();
result = 37*result + ret;
return result;
}
public static String signature() {
return "LQuorumPacket(ilB[LId(ss)])";
}
}