列车数据mode属性调整

This commit is contained in:
tiger_zhou 2023-06-26 15:32:25 +08:00
parent 0dae9b7021
commit c8c44a126b
8 changed files with 3923 additions and 1339 deletions

View File

@ -4,6 +4,7 @@ import club.joylink.xiannccda.ats.message.MessageResponse;
import club.joylink.xiannccda.ats.message.convertor.DeviceStatusConvertor;
import club.joylink.xiannccda.ats.message.line3.DateTimeUtil;
import club.joylink.xiannccda.ats.message.line3.MessageCons;
import club.joylink.xiannccda.ats.message.line3.device.DeviceStatus;
import club.joylink.xiannccda.ats.message.line3.device.DeviceType;
import club.joylink.xiannccda.ats.message.line3.rep.DeviceStatusBitmapResponse.DeviceTypeEntity;
import club.joylink.xiannccda.dto.protos.DeviceStatusProto;
@ -86,7 +87,8 @@ public class TrainIndicationInitResponse extends MessageResponse {
builder.setOtpTime(trainCell.getOtpTime());
}
if (trainCell.getMode() != null) {
builder.setMode(trainCell.getMode());
DeviceStatusProto.TrainMode.Builder trainMode = DeviceStatusConvertor.convert(DeviceStatus.TRAIN_MODE.class, trainCell.getMode());
builder.setMode(trainMode.build());
}
if (trainCell.getArriveTime() != null) {
builder.setArriveTime(trainCell.getArriveTime().getNano());

View File

@ -3,7 +3,12 @@ package club.joylink.xiannccda.ats.message.line3.rep;
import club.joylink.xiannccda.ats.message.MessageResponse;
import club.joylink.xiannccda.ats.message.line3.MessageCons;
import club.joylink.xiannccda.ats.message.line3.device.DeviceType;
import club.joylink.xiannccda.dto.protos.DeviceStatusProto;
import club.joylink.xiannccda.dto.protos.TrainProto.NccWindow;
import club.joylink.xiannccda.dto.protos.TrainProto.TrainRemove;
import com.google.protobuf.GeneratedMessageV3.Builder;
import io.netty.buffer.ByteBuf;
import java.util.List;
import lombok.Getter;
import lombok.Setter;
@ -68,4 +73,21 @@ public class TrainIndicationRemoveResponse extends MessageResponse {
this.trainIndex = new String(trainIndex, MessageCons.STRING_CHARSET).trim();
this.groupId = new String(groupId, MessageCons.STRING_CHARSET).trim();
}
@Override
public List<Builder> generateProto() throws Exception {
TrainRemove.Builder trainRemove = TrainRemove.newBuilder();
trainRemove.setLineId(this.lineId);
trainRemove.setRtuId(this.rtuId);
NccWindow.Builder window = NccWindow.newBuilder();
window.setNccWindow(this.nccWindow);
window.setNccWinOffset(this.nccWindowOffset);
trainRemove.setWindow(window);
trainRemove.setDeviceType(DeviceStatusProto.DeviceType.forNumber(this.devType.getVal()));
trainRemove.setDevName(this.devName);
trainRemove.setTrainIndex(this.trainIndex);
trainRemove.setGroupId(this.groupId);
return List.of(trainRemove);
}
}

View File

@ -1,6 +1,7 @@
package club.joylink.xiannccda.ats.message.line3.rep;
import club.joylink.xiannccda.ats.message.MessageResponse;
import club.joylink.xiannccda.ats.message.convertor.DeviceStatusConvertor;
import club.joylink.xiannccda.ats.message.line3.DateTimeUtil;
import club.joylink.xiannccda.ats.message.line3.MessageCons;
import club.joylink.xiannccda.ats.message.line3.device.DeviceStatus;
@ -143,7 +144,8 @@ public class TrainIndicationUpdateResponse extends MessageResponse {
train.setOtpTime(this.optTime);
train.setArriveTime(this.arriveTime.toEpochSecond(ZoneOffset.ofHours(8)) * 1000);
train.setDepartTime(this.departTime.toEpochSecond(ZoneOffset.ofHours(8)) * 1000);
train.setMode(this.mode);
DeviceStatusProto.TrainMode.Builder trainMode = DeviceStatusConvertor.convert(DeviceStatus.TRAIN_MODE.class, this.mode);
train.setMode(trainMode.build());
train.setSpeed(this.speed);
train.setRate(this.rate);
train.setRouteId(this.routeId);

View File

@ -11,6 +11,7 @@ import com.google.common.collect.Lists;
import com.google.protobuf.GeneratedMessageV3;
import com.google.protobuf.GeneratedMessageV3.Builder;
import io.netty.buffer.ByteBuf;
import java.time.ZoneOffset;
import java.util.List;
import lombok.Getter;
@ -151,7 +152,7 @@ public class TrainRecordResponse extends MessageResponse {
builder.setRecordType(this.getRecordType());
}
if (this.getRecordTime() != null) {
builder.setRecordTime(this.getRecordTime().getNano());
builder.setRecordTime(this.getRecordTime().toEpochSecond(ZoneOffset.ofHours(8)) * 1000);
}
msgBuildList.add(builder);
return msgBuildList;

File diff suppressed because it is too large Load Diff

View File

@ -225,12 +225,32 @@ public final class TrainProto {
/**
* <pre>
* 列车状态
* int32 mode = 14;
* </pre>
*
* <code>int32 mode = 14;</code>
* <code>.state.TrainMode mode = 14;</code>
* @return Whether the mode field is set.
*/
boolean hasMode();
/**
* <pre>
* 列车状态
* int32 mode = 14;
* </pre>
*
* <code>.state.TrainMode mode = 14;</code>
* @return The mode.
*/
int getMode();
club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode getMode();
/**
* <pre>
* 列车状态
* int32 mode = 14;
* </pre>
*
* <code>.state.TrainMode mode = 14;</code>
*/
club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainModeOrBuilder getModeOrBuilder();
/**
* <pre>
@ -758,18 +778,44 @@ public final class TrainProto {
}
public static final int MODE_FIELD_NUMBER = 14;
private int mode_ = 0;
private club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode mode_;
/**
* <pre>
* 列车状态
* int32 mode = 14;
* </pre>
*
* <code>int32 mode = 14;</code>
* <code>.state.TrainMode mode = 14;</code>
* @return Whether the mode field is set.
*/
@java.lang.Override
public boolean hasMode() {
return mode_ != null;
}
/**
* <pre>
* 列车状态
* int32 mode = 14;
* </pre>
*
* <code>.state.TrainMode mode = 14;</code>
* @return The mode.
*/
@java.lang.Override
public int getMode() {
return mode_;
public club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode getMode() {
return mode_ == null ? club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode.getDefaultInstance() : mode_;
}
/**
* <pre>
* 列车状态
* int32 mode = 14;
* </pre>
*
* <code>.state.TrainMode mode = 14;</code>
*/
@java.lang.Override
public club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainModeOrBuilder getModeOrBuilder() {
return mode_ == null ? club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode.getDefaultInstance() : mode_;
}
public static final int ARRIVETIME_FIELD_NUMBER = 15;
@ -930,8 +976,8 @@ public final class TrainProto {
if (otpTime_ != 0) {
output.writeInt32(13, otpTime_);
}
if (mode_ != 0) {
output.writeInt32(14, mode_);
if (mode_ != null) {
output.writeMessage(14, getMode());
}
if (arriveTime_ != 0L) {
output.writeInt64(15, arriveTime_);
@ -1009,9 +1055,9 @@ public final class TrainProto {
size += com.google.protobuf.CodedOutputStream
.computeInt32Size(13, otpTime_);
}
if (mode_ != 0) {
if (mode_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeInt32Size(14, mode_);
.computeMessageSize(14, getMode());
}
if (arriveTime_ != 0L) {
size += com.google.protobuf.CodedOutputStream
@ -1084,8 +1130,11 @@ public final class TrainProto {
.equals(other.getDriverId())) return false;
if (getOtpTime()
!= other.getOtpTime()) return false;
if (getMode()
!= other.getMode()) return false;
if (hasMode() != other.hasMode()) return false;
if (hasMode()) {
if (!getMode()
.equals(other.getMode())) return false;
}
if (getArriveTime()
!= other.getArriveTime()) return false;
if (getDepartTime()
@ -1140,8 +1189,10 @@ public final class TrainProto {
hash = (53 * hash) + getDriverId().hashCode();
hash = (37 * hash) + OTPTIME_FIELD_NUMBER;
hash = (53 * hash) + getOtpTime();
if (hasMode()) {
hash = (37 * hash) + MODE_FIELD_NUMBER;
hash = (53 * hash) + getMode();
hash = (53 * hash) + getMode().hashCode();
}
hash = (37 * hash) + ARRIVETIME_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getArriveTime());
@ -1313,7 +1364,11 @@ public final class TrainProto {
rollingStock_ = 0;
driverId_ = "";
otpTime_ = 0;
mode_ = 0;
mode_ = null;
if (modeBuilder_ != null) {
modeBuilder_.dispose();
modeBuilder_ = null;
}
arriveTime_ = 0L;
departTime_ = 0L;
speed_ = 0F;
@ -1396,7 +1451,9 @@ public final class TrainProto {
result.otpTime_ = otpTime_;
}
if (((from_bitField0_ & 0x00002000) != 0)) {
result.mode_ = mode_;
result.mode_ = modeBuilder_ == null
? mode_
: modeBuilder_.build();
}
if (((from_bitField0_ & 0x00004000) != 0)) {
result.arriveTime_ = arriveTime_;
@ -1484,8 +1541,8 @@ public final class TrainProto {
if (other.getOtpTime() != 0) {
setOtpTime(other.getOtpTime());
}
if (other.getMode() != 0) {
setMode(other.getMode());
if (other.hasMode()) {
mergeMode(other.getMode());
}
if (other.getArriveTime() != 0L) {
setArriveTime(other.getArriveTime());
@ -1601,11 +1658,13 @@ public final class TrainProto {
bitField0_ |= 0x00001000;
break;
} // case 104
case 112: {
mode_ = input.readInt32();
case 114: {
input.readMessage(
getModeFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00002000;
break;
} // case 112
} // case 114
case 120: {
arriveTime_ = input.readInt64();
bitField0_ |= 0x00004000;
@ -2622,31 +2681,54 @@ public final class TrainProto {
return this;
}
private int mode_ ;
private club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode mode_;
private com.google.protobuf.SingleFieldBuilderV3<
club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode, club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode.Builder, club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainModeOrBuilder> modeBuilder_;
/**
* <pre>
* 列车状态
* int32 mode = 14;
* </pre>
*
* <code>int32 mode = 14;</code>
* @return The mode.
* <code>.state.TrainMode mode = 14;</code>
* @return Whether the mode field is set.
*/
@java.lang.Override
public int getMode() {
return mode_;
public boolean hasMode() {
return ((bitField0_ & 0x00002000) != 0);
}
/**
* <pre>
* 列车状态
* int32 mode = 14;
* </pre>
*
* <code>int32 mode = 14;</code>
* @param value The mode to set.
* @return This builder for chaining.
* <code>.state.TrainMode mode = 14;</code>
* @return The mode.
*/
public Builder setMode(int value) {
public club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode getMode() {
if (modeBuilder_ == null) {
return mode_ == null ? club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode.getDefaultInstance() : mode_;
} else {
return modeBuilder_.getMessage();
}
}
/**
* <pre>
* 列车状态
* int32 mode = 14;
* </pre>
*
* <code>.state.TrainMode mode = 14;</code>
*/
public Builder setMode(club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode value) {
if (modeBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
mode_ = value;
} else {
modeBuilder_.setMessage(value);
}
bitField0_ |= 0x00002000;
onChanged();
return this;
@ -2654,17 +2736,114 @@ public final class TrainProto {
/**
* <pre>
* 列车状态
* int32 mode = 14;
* </pre>
*
* <code>int32 mode = 14;</code>
* @return This builder for chaining.
* <code>.state.TrainMode mode = 14;</code>
*/
public Builder setMode(
club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode.Builder builderForValue) {
if (modeBuilder_ == null) {
mode_ = builderForValue.build();
} else {
modeBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00002000;
onChanged();
return this;
}
/**
* <pre>
* 列车状态
* int32 mode = 14;
* </pre>
*
* <code>.state.TrainMode mode = 14;</code>
*/
public Builder mergeMode(club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode value) {
if (modeBuilder_ == null) {
if (((bitField0_ & 0x00002000) != 0) &&
mode_ != null &&
mode_ != club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode.getDefaultInstance()) {
getModeBuilder().mergeFrom(value);
} else {
mode_ = value;
}
} else {
modeBuilder_.mergeFrom(value);
}
bitField0_ |= 0x00002000;
onChanged();
return this;
}
/**
* <pre>
* 列车状态
* int32 mode = 14;
* </pre>
*
* <code>.state.TrainMode mode = 14;</code>
*/
public Builder clearMode() {
bitField0_ = (bitField0_ & ~0x00002000);
mode_ = 0;
mode_ = null;
if (modeBuilder_ != null) {
modeBuilder_.dispose();
modeBuilder_ = null;
}
onChanged();
return this;
}
/**
* <pre>
* 列车状态
* int32 mode = 14;
* </pre>
*
* <code>.state.TrainMode mode = 14;</code>
*/
public club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode.Builder getModeBuilder() {
bitField0_ |= 0x00002000;
onChanged();
return getModeFieldBuilder().getBuilder();
}
/**
* <pre>
* 列车状态
* int32 mode = 14;
* </pre>
*
* <code>.state.TrainMode mode = 14;</code>
*/
public club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainModeOrBuilder getModeOrBuilder() {
if (modeBuilder_ != null) {
return modeBuilder_.getMessageOrBuilder();
} else {
return mode_ == null ?
club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode.getDefaultInstance() : mode_;
}
}
/**
* <pre>
* 列车状态
* int32 mode = 14;
* </pre>
*
* <code>.state.TrainMode mode = 14;</code>
*/
private com.google.protobuf.SingleFieldBuilderV3<
club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode, club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode.Builder, club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainModeOrBuilder>
getModeFieldBuilder() {
if (modeBuilder_ == null) {
modeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode, club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainMode.Builder, club.joylink.xiannccda.dto.protos.DeviceStatusProto.TrainModeOrBuilder>(
getMode(),
getParentForChildren(),
isClean());
mode_ = null;
}
return modeBuilder_;
}
private long arriveTime_ ;
/**
@ -3639,10 +3818,20 @@ public final class TrainProto {
* 列车标示号全线唯一若无法提供缺省值为0
* </pre>
*
* <code>int32 trainIndex = 6;</code>
* <code>string trainIndex = 6;</code>
* @return The trainIndex.
*/
int getTrainIndex();
java.lang.String getTrainIndex();
/**
* <pre>
* 列车标示号全线唯一若无法提供缺省值为0
* </pre>
*
* <code>string trainIndex = 6;</code>
* @return The bytes for trainIndex.
*/
com.google.protobuf.ByteString
getTrainIndexBytes();
/**
* <pre>
@ -3683,6 +3872,7 @@ public final class TrainProto {
private TrainRemove() {
deviceType_ = 0;
devName_ = "";
trainIndex_ = "";
groupId_ = "";
}
@ -3839,18 +4029,50 @@ public final class TrainProto {
}
public static final int TRAININDEX_FIELD_NUMBER = 6;
private int trainIndex_ = 0;
@SuppressWarnings("serial")
private volatile java.lang.Object trainIndex_ = "";
/**
* <pre>
* 列车标示号全线唯一若无法提供缺省值为0
* </pre>
*
* <code>int32 trainIndex = 6;</code>
* <code>string trainIndex = 6;</code>
* @return The trainIndex.
*/
@java.lang.Override
public int getTrainIndex() {
return trainIndex_;
public java.lang.String getTrainIndex() {
java.lang.Object ref = trainIndex_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
trainIndex_ = s;
return s;
}
}
/**
* <pre>
* 列车标示号全线唯一若无法提供缺省值为0
* </pre>
*
* <code>string trainIndex = 6;</code>
* @return The bytes for trainIndex.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getTrainIndexBytes() {
java.lang.Object ref = trainIndex_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
trainIndex_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int GROUPID_FIELD_NUMBER = 7;
@ -3929,8 +4151,8 @@ public final class TrainProto {
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(devName_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 5, devName_);
}
if (trainIndex_ != 0) {
output.writeInt32(6, trainIndex_);
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(trainIndex_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 6, trainIndex_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(groupId_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 7, groupId_);
@ -3963,9 +4185,8 @@ public final class TrainProto {
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(devName_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, devName_);
}
if (trainIndex_ != 0) {
size += com.google.protobuf.CodedOutputStream
.computeInt32Size(6, trainIndex_);
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(trainIndex_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, trainIndex_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(groupId_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, groupId_);
@ -3997,8 +4218,8 @@ public final class TrainProto {
if (deviceType_ != other.deviceType_) return false;
if (!getDevName()
.equals(other.getDevName())) return false;
if (getTrainIndex()
!= other.getTrainIndex()) return false;
if (!getTrainIndex()
.equals(other.getTrainIndex())) return false;
if (!getGroupId()
.equals(other.getGroupId())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
@ -4025,7 +4246,7 @@ public final class TrainProto {
hash = (37 * hash) + DEVNAME_FIELD_NUMBER;
hash = (53 * hash) + getDevName().hashCode();
hash = (37 * hash) + TRAININDEX_FIELD_NUMBER;
hash = (53 * hash) + getTrainIndex();
hash = (53 * hash) + getTrainIndex().hashCode();
hash = (37 * hash) + GROUPID_FIELD_NUMBER;
hash = (53 * hash) + getGroupId().hashCode();
hash = (29 * hash) + getUnknownFields().hashCode();
@ -4172,7 +4393,7 @@ public final class TrainProto {
}
deviceType_ = 0;
devName_ = "";
trainIndex_ = 0;
trainIndex_ = "";
groupId_ = "";
return this;
}
@ -4261,8 +4482,10 @@ public final class TrainProto {
bitField0_ |= 0x00000010;
onChanged();
}
if (other.getTrainIndex() != 0) {
setTrainIndex(other.getTrainIndex());
if (!other.getTrainIndex().isEmpty()) {
trainIndex_ = other.trainIndex_;
bitField0_ |= 0x00000020;
onChanged();
}
if (!other.getGroupId().isEmpty()) {
groupId_ = other.groupId_;
@ -4322,11 +4545,11 @@ public final class TrainProto {
bitField0_ |= 0x00000010;
break;
} // case 42
case 48: {
trainIndex_ = input.readInt32();
case 50: {
trainIndex_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000020;
break;
} // case 48
} // case 50
case 58: {
groupId_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000040;
@ -4734,30 +4957,60 @@ public final class TrainProto {
return this;
}
private int trainIndex_ ;
private java.lang.Object trainIndex_ = "";
/**
* <pre>
* 列车标示号全线唯一若无法提供缺省值为0
* </pre>
*
* <code>int32 trainIndex = 6;</code>
* <code>string trainIndex = 6;</code>
* @return The trainIndex.
*/
@java.lang.Override
public int getTrainIndex() {
return trainIndex_;
public java.lang.String getTrainIndex() {
java.lang.Object ref = trainIndex_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
trainIndex_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* <pre>
* 列车标示号全线唯一若无法提供缺省值为0
* </pre>
*
* <code>int32 trainIndex = 6;</code>
* <code>string trainIndex = 6;</code>
* @return The bytes for trainIndex.
*/
public com.google.protobuf.ByteString
getTrainIndexBytes() {
java.lang.Object ref = trainIndex_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
trainIndex_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* <pre>
* 列车标示号全线唯一若无法提供缺省值为0
* </pre>
*
* <code>string trainIndex = 6;</code>
* @param value The trainIndex to set.
* @return This builder for chaining.
*/
public Builder setTrainIndex(int value) {
public Builder setTrainIndex(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
trainIndex_ = value;
bitField0_ |= 0x00000020;
onChanged();
@ -4768,12 +5021,30 @@ public final class TrainProto {
* 列车标示号全线唯一若无法提供缺省值为0
* </pre>
*
* <code>int32 trainIndex = 6;</code>
* <code>string trainIndex = 6;</code>
* @return This builder for chaining.
*/
public Builder clearTrainIndex() {
trainIndex_ = getDefaultInstance().getTrainIndex();
bitField0_ = (bitField0_ & ~0x00000020);
trainIndex_ = 0;
onChanged();
return this;
}
/**
* <pre>
* 列车标示号全线唯一若无法提供缺省值为0
* </pre>
*
* <code>string trainIndex = 6;</code>
* @param value The bytes for trainIndex to set.
* @return This builder for chaining.
*/
public Builder setTrainIndexBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
trainIndex_ = value;
bitField0_ |= 0x00000020;
onChanged();
return this;
}
@ -8607,36 +8878,36 @@ public final class TrainProto {
static {
java.lang.String[] descriptorData = {
"\n\013train.proto\022\005train\032\023device_status.prot" +
"o\"\231\003\n\tTrainInfo\022\016\n\006lineId\030\001 \001(\005\022\r\n\005rtuId" +
"o\"\253\003\n\tTrainInfo\022\016\n\006lineId\030\001 \001(\005\022\r\n\005rtuId" +
"\030\002 \001(\005\022 \n\006window\030\003 \001(\0132\020.train.NccWindow" +
"\022\"\n\007devType\030\004 \001(\0162\021.state.DeviceType\022\017\n\007" +
"devName\030\005 \001(\t\022\022\n\ntrainIndex\030\006 \001(\t\022\017\n\007gro" +
"upId\030\007 \001(\t\022\017\n\007trainId\030\010 \001(\t\022\020\n\010globalId\030" +
"\t \001(\t\022\025\n\rdestinationId\030\n \001(\005\022\024\n\014rollingS" +
"tock\030\013 \001(\005\022\020\n\010driverId\030\014 \001(\t\022\017\n\007otpTime\030" +
"\r \001(\005\022\014\n\004mode\030\016 \001(\005\022\022\n\narriveTime\030\017 \001(\003\022" +
"\022\n\ndepartTime\030\020 \001(\003\022\r\n\005speed\030\021 \001(\002\022\014\n\004sh" +
"ow\030\022 \001(\010\022\014\n\004type\030\023 \001(\010\022\017\n\007routeId\030\024 \001(\005\022" +
"\014\n\004rate\030\025 \001(\005\"4\n\tNccWindow\022\021\n\tnccWindow\030" +
"\001 \001(\005\022\024\n\014nccWinOffset\030\002 \001(\005\"\253\001\n\013TrainRem" +
"ove\022\016\n\006lineId\030\001 \001(\005\022\r\n\005rtuId\030\002 \001(\005\022 \n\006wi" +
"ndow\030\003 \001(\0132\020.train.NccWindow\022%\n\ndeviceTy" +
"pe\030\004 \001(\0162\021.state.DeviceType\022\017\n\007devName\030\005" +
" \001(\t\022\022\n\ntrainIndex\030\006 \001(\005\022\017\n\007groupId\030\007 \001(" +
"\t\"\343\001\n\nTrainBlock\022\016\n\006lineId\030\001 \001(\005\022\017\n\007grou" +
"pId\030\002 \001(\t\022\017\n\007trainId\030\003 \001(\t\022\021\n\tdirection\030" +
"\004 \001(\005\022\031\n\021stationIDInUpSide\030\005 \001(\005\022\033\n\023stat" +
"ionIDInDownSide\030\006 \001(\005\022\r\n\005rtuId\030\007 \001(\005\022%\n\n" +
"deviceType\030\010 \001(\0162\021.state.DeviceType\022\017\n\007D" +
"evName\030\t \001(\t\022\021\n\tblockFlag\030\n \001(\005\"\372\001\n\013Trai" +
"nRecord\022\016\n\006lineId\030\001 \001(\005\022\017\n\007trainId\030\002 \001(\t" +
"\022\020\n\010globalId\030\003 \001(\t\022\022\n\nlocalSubId\030\004 \001(\005\022\017" +
"\n\007groupId\030\005 \001(\t\022\025\n\rdestinationId\030\006 \001(\005\022\021" +
"\n\ttrainType\030\007 \001(\005\022\013\n\003dir\030\010 \001(\005\022\021\n\tstatio" +
"nId\030\t \001(\005\022\016\n\006sideId\030\n \001(\005\022\021\n\ttrackName\030\013" +
" \001(\t\022\022\n\nrecordType\030\014 \001(\010\022\022\n\nrecordTime\030\r" +
" \001(\003B/\n!club.joylink.xiannccda.dto.proto" +
"sB\nTrainProtob\006proto3"
"\r \001(\005\022\036\n\004mode\030\016 \001(\0132\020.state.TrainMode\022\022\n" +
"\narriveTime\030\017 \001(\003\022\022\n\ndepartTime\030\020 \001(\003\022\r\n" +
"\005speed\030\021 \001(\002\022\014\n\004show\030\022 \001(\010\022\014\n\004type\030\023 \001(\010" +
"\022\017\n\007routeId\030\024 \001(\005\022\014\n\004rate\030\025 \001(\005\"4\n\tNccWi" +
"ndow\022\021\n\tnccWindow\030\001 \001(\005\022\024\n\014nccWinOffset\030" +
"\002 \001(\005\"\253\001\n\013TrainRemove\022\016\n\006lineId\030\001 \001(\005\022\r\n" +
"\005rtuId\030\002 \001(\005\022 \n\006window\030\003 \001(\0132\020.train.Ncc" +
"Window\022%\n\ndeviceType\030\004 \001(\0162\021.state.Devic" +
"eType\022\017\n\007devName\030\005 \001(\t\022\022\n\ntrainIndex\030\006 \001" +
"(\t\022\017\n\007groupId\030\007 \001(\t\"\343\001\n\nTrainBlock\022\016\n\006li" +
"neId\030\001 \001(\005\022\017\n\007groupId\030\002 \001(\t\022\017\n\007trainId\030\003" +
" \001(\t\022\021\n\tdirection\030\004 \001(\005\022\031\n\021stationIDInUp" +
"Side\030\005 \001(\005\022\033\n\023stationIDInDownSide\030\006 \001(\005\022" +
"\r\n\005rtuId\030\007 \001(\005\022%\n\ndeviceType\030\010 \001(\0162\021.sta" +
"te.DeviceType\022\017\n\007DevName\030\t \001(\t\022\021\n\tblockF" +
"lag\030\n \001(\005\"\372\001\n\013TrainRecord\022\016\n\006lineId\030\001 \001(" +
"\005\022\017\n\007trainId\030\002 \001(\t\022\020\n\010globalId\030\003 \001(\t\022\022\n\n" +
"localSubId\030\004 \001(\005\022\017\n\007groupId\030\005 \001(\t\022\025\n\rdes" +
"tinationId\030\006 \001(\005\022\021\n\ttrainType\030\007 \001(\005\022\013\n\003d" +
"ir\030\010 \001(\005\022\021\n\tstationId\030\t \001(\005\022\016\n\006sideId\030\n " +
"\001(\005\022\021\n\ttrackName\030\013 \001(\t\022\022\n\nrecordType\030\014 \001" +
"(\010\022\022\n\nrecordTime\030\r \001(\003B/\n!club.joylink.x" +
"iannccda.dto.protosB\nTrainProtob\006proto3"
};
descriptor = com.google.protobuf.Descriptors.FileDescriptor
.internalBuildGeneratedFileFrom(descriptorData,

@ -1 +1 @@
Subproject commit 911d1999d0df58db7fefb59471487bd5c524269f
Subproject commit b5d0bb7fedf61cfe5cdfdfc75637bd02c875b19c