diff --git a/packages/google-cloud-filestore/protos/protos.d.ts b/packages/google-cloud-filestore/protos/protos.d.ts index 75c4327e3a7..c03487cf1dc 100644 --- a/packages/google-cloud-filestore/protos/protos.d.ts +++ b/packages/google-cloud-filestore/protos/protos.d.ts @@ -12,8 +12,8 @@ // See the License for the specific language governing permissions and // limitations under the License. -import Long = require("long"); import type {protobuf as $protobuf} from "google-gax"; +import Long = require("long"); /** Namespace google. */ export namespace google { diff --git a/packages/google-cloud-filestore/protos/protos.js b/packages/google-cloud-filestore/protos/protos.js index cbafc3d8aca..2e5c6bff608 100644 --- a/packages/google-cloud-filestore/protos/protos.js +++ b/packages/google-cloud-filestore/protos/protos.js @@ -1069,6 +1069,10 @@ for (var i = 0; i < object.modes.length; ++i) switch (object.modes[i]) { default: + if (typeof object.modes[i] === "number") { + message.modes[i] = object.modes[i]; + break; + } case "ADDRESS_MODE_UNSPECIFIED": case 0: message.modes[i] = 0; @@ -1117,7 +1121,7 @@ if (message.modes && message.modes.length) { object.modes = []; for (var j = 0; j < message.modes.length; ++j) - object.modes[j] = options.enums === String ? $root.google.cloud.filestore.v1.NetworkConfig.AddressMode[message.modes[j]] : message.modes[j]; + object.modes[j] = options.enums === String ? $root.google.cloud.filestore.v1.NetworkConfig.AddressMode[message.modes[j]] === undefined ? message.modes[j] : $root.google.cloud.filestore.v1.NetworkConfig.AddressMode[message.modes[j]] : message.modes[j]; } if (message.reservedIpRange != null && message.hasOwnProperty("reservedIpRange")) object.reservedIpRange = message.reservedIpRange; @@ -1749,6 +1753,12 @@ message.ipRanges[i] = String(object.ipRanges[i]); } switch (object.accessMode) { + default: + if (typeof object.accessMode === "number") { + message.accessMode = object.accessMode; + break; + } + break; case "ACCESS_MODE_UNSPECIFIED": case 0: message.accessMode = 0; @@ -1763,6 +1773,12 @@ break; } switch (object.squashMode) { + default: + if (typeof object.squashMode === "number") { + message.squashMode = object.squashMode; + break; + } + break; case "SQUASH_MODE_UNSPECIFIED": case 0: message.squashMode = 0; @@ -1832,9 +1848,9 @@ object.ipRanges[j] = message.ipRanges[j]; } if (message.accessMode != null && message.hasOwnProperty("accessMode")) - object.accessMode = options.enums === String ? $root.google.cloud.filestore.v1.NfsExportOptions.AccessMode[message.accessMode] : message.accessMode; + object.accessMode = options.enums === String ? $root.google.cloud.filestore.v1.NfsExportOptions.AccessMode[message.accessMode] === undefined ? message.accessMode : $root.google.cloud.filestore.v1.NfsExportOptions.AccessMode[message.accessMode] : message.accessMode; if (message.squashMode != null && message.hasOwnProperty("squashMode")) - object.squashMode = options.enums === String ? $root.google.cloud.filestore.v1.NfsExportOptions.SquashMode[message.squashMode] : message.squashMode; + object.squashMode = options.enums === String ? $root.google.cloud.filestore.v1.NfsExportOptions.SquashMode[message.squashMode] === undefined ? message.squashMode : $root.google.cloud.filestore.v1.NfsExportOptions.SquashMode[message.squashMode] : message.squashMode; if (message.anonUid != null && message.hasOwnProperty("anonUid")) if (typeof message.anonUid === "number") object.anonUid = options.longs === String ? String(message.anonUid) : message.anonUid; @@ -2312,6 +2328,12 @@ if (object.description != null) message.description = String(object.description); switch (object.state) { + default: + if (typeof object.state === "number") { + message.state = object.state; + break; + } + break; case "STATE_UNSPECIFIED": case 0: message.state = 0; @@ -2349,6 +2371,12 @@ message.createTime = $root.google.protobuf.Timestamp.fromObject(object.createTime); } switch (object.tier) { + default: + if (typeof object.tier === "number") { + message.tier = object.tier; + break; + } + break; case "TIER_UNSPECIFIED": case 0: message.tier = 0; @@ -2445,13 +2473,13 @@ if (message.description != null && message.hasOwnProperty("description")) object.description = message.description; if (message.state != null && message.hasOwnProperty("state")) - object.state = options.enums === String ? $root.google.cloud.filestore.v1.Instance.State[message.state] : message.state; + object.state = options.enums === String ? $root.google.cloud.filestore.v1.Instance.State[message.state] === undefined ? message.state : $root.google.cloud.filestore.v1.Instance.State[message.state] : message.state; if (message.statusMessage != null && message.hasOwnProperty("statusMessage")) object.statusMessage = message.statusMessage; if (message.createTime != null && message.hasOwnProperty("createTime")) object.createTime = $root.google.protobuf.Timestamp.toObject(message.createTime, options); if (message.tier != null && message.hasOwnProperty("tier")) - object.tier = options.enums === String ? $root.google.cloud.filestore.v1.Instance.Tier[message.tier] : message.tier; + object.tier = options.enums === String ? $root.google.cloud.filestore.v1.Instance.Tier[message.tier] === undefined ? message.tier : $root.google.cloud.filestore.v1.Instance.Tier[message.tier] : message.tier; var keys2; if (message.labels && (keys2 = Object.keys(message.labels)).length) { object.labels = {}; @@ -4700,6 +4728,12 @@ if (object.description != null) message.description = String(object.description); switch (object.state) { + default: + if (typeof object.state === "number") { + message.state = object.state; + break; + } + break; case "STATE_UNSPECIFIED": case 0: message.state = 0; @@ -4756,6 +4790,12 @@ if (object.sourceFileShare != null) message.sourceFileShare = String(object.sourceFileShare); switch (object.sourceInstanceTier) { + default: + if (typeof object.sourceInstanceTier === "number") { + message.sourceInstanceTier = object.sourceInstanceTier; + break; + } + break; case "TIER_UNSPECIFIED": case 0: message.sourceInstanceTier = 0; @@ -4843,7 +4883,7 @@ if (message.description != null && message.hasOwnProperty("description")) object.description = message.description; if (message.state != null && message.hasOwnProperty("state")) - object.state = options.enums === String ? $root.google.cloud.filestore.v1.Backup.State[message.state] : message.state; + object.state = options.enums === String ? $root.google.cloud.filestore.v1.Backup.State[message.state] === undefined ? message.state : $root.google.cloud.filestore.v1.Backup.State[message.state] : message.state; if (message.createTime != null && message.hasOwnProperty("createTime")) object.createTime = $root.google.protobuf.Timestamp.toObject(message.createTime, options); var keys2; @@ -4867,7 +4907,7 @@ if (message.sourceFileShare != null && message.hasOwnProperty("sourceFileShare")) object.sourceFileShare = message.sourceFileShare; if (message.sourceInstanceTier != null && message.hasOwnProperty("sourceInstanceTier")) - object.sourceInstanceTier = options.enums === String ? $root.google.cloud.filestore.v1.Instance.Tier[message.sourceInstanceTier] : message.sourceInstanceTier; + object.sourceInstanceTier = options.enums === String ? $root.google.cloud.filestore.v1.Instance.Tier[message.sourceInstanceTier] === undefined ? message.sourceInstanceTier : $root.google.cloud.filestore.v1.Instance.Tier[message.sourceInstanceTier] : message.sourceInstanceTier; if (message.downloadBytes != null && message.hasOwnProperty("downloadBytes")) if (typeof message.downloadBytes === "number") object.downloadBytes = options.longs === String ? String(message.downloadBytes) : message.downloadBytes; @@ -7060,6 +7100,10 @@ for (var i = 0; i < object.modes.length; ++i) switch (object.modes[i]) { default: + if (typeof object.modes[i] === "number") { + message.modes[i] = object.modes[i]; + break; + } case "ADDRESS_MODE_UNSPECIFIED": case 0: message.modes[i] = 0; @@ -7108,7 +7152,7 @@ if (message.modes && message.modes.length) { object.modes = []; for (var j = 0; j < message.modes.length; ++j) - object.modes[j] = options.enums === String ? $root.google.cloud.filestore.v1beta1.NetworkConfig.AddressMode[message.modes[j]] : message.modes[j]; + object.modes[j] = options.enums === String ? $root.google.cloud.filestore.v1beta1.NetworkConfig.AddressMode[message.modes[j]] === undefined ? message.modes[j] : $root.google.cloud.filestore.v1beta1.NetworkConfig.AddressMode[message.modes[j]] : message.modes[j]; } if (message.reservedIpRange != null && message.hasOwnProperty("reservedIpRange")) object.reservedIpRange = message.reservedIpRange; @@ -7740,6 +7784,12 @@ message.ipRanges[i] = String(object.ipRanges[i]); } switch (object.accessMode) { + default: + if (typeof object.accessMode === "number") { + message.accessMode = object.accessMode; + break; + } + break; case "ACCESS_MODE_UNSPECIFIED": case 0: message.accessMode = 0; @@ -7754,6 +7804,12 @@ break; } switch (object.squashMode) { + default: + if (typeof object.squashMode === "number") { + message.squashMode = object.squashMode; + break; + } + break; case "SQUASH_MODE_UNSPECIFIED": case 0: message.squashMode = 0; @@ -7823,9 +7879,9 @@ object.ipRanges[j] = message.ipRanges[j]; } if (message.accessMode != null && message.hasOwnProperty("accessMode")) - object.accessMode = options.enums === String ? $root.google.cloud.filestore.v1beta1.NfsExportOptions.AccessMode[message.accessMode] : message.accessMode; + object.accessMode = options.enums === String ? $root.google.cloud.filestore.v1beta1.NfsExportOptions.AccessMode[message.accessMode] === undefined ? message.accessMode : $root.google.cloud.filestore.v1beta1.NfsExportOptions.AccessMode[message.accessMode] : message.accessMode; if (message.squashMode != null && message.hasOwnProperty("squashMode")) - object.squashMode = options.enums === String ? $root.google.cloud.filestore.v1beta1.NfsExportOptions.SquashMode[message.squashMode] : message.squashMode; + object.squashMode = options.enums === String ? $root.google.cloud.filestore.v1beta1.NfsExportOptions.SquashMode[message.squashMode] === undefined ? message.squashMode : $root.google.cloud.filestore.v1beta1.NfsExportOptions.SquashMode[message.squashMode] : message.squashMode; if (message.anonUid != null && message.hasOwnProperty("anonUid")) if (typeof message.anonUid === "number") object.anonUid = options.longs === String ? String(message.anonUid) : message.anonUid; @@ -8303,6 +8359,12 @@ if (object.description != null) message.description = String(object.description); switch (object.state) { + default: + if (typeof object.state === "number") { + message.state = object.state; + break; + } + break; case "STATE_UNSPECIFIED": case 0: message.state = 0; @@ -8340,6 +8402,12 @@ message.createTime = $root.google.protobuf.Timestamp.fromObject(object.createTime); } switch (object.tier) { + default: + if (typeof object.tier === "number") { + message.tier = object.tier; + break; + } + break; case "TIER_UNSPECIFIED": case 0: message.tier = 0; @@ -8436,13 +8504,13 @@ if (message.description != null && message.hasOwnProperty("description")) object.description = message.description; if (message.state != null && message.hasOwnProperty("state")) - object.state = options.enums === String ? $root.google.cloud.filestore.v1beta1.Instance.State[message.state] : message.state; + object.state = options.enums === String ? $root.google.cloud.filestore.v1beta1.Instance.State[message.state] === undefined ? message.state : $root.google.cloud.filestore.v1beta1.Instance.State[message.state] : message.state; if (message.statusMessage != null && message.hasOwnProperty("statusMessage")) object.statusMessage = message.statusMessage; if (message.createTime != null && message.hasOwnProperty("createTime")) object.createTime = $root.google.protobuf.Timestamp.toObject(message.createTime, options); if (message.tier != null && message.hasOwnProperty("tier")) - object.tier = options.enums === String ? $root.google.cloud.filestore.v1beta1.Instance.Tier[message.tier] : message.tier; + object.tier = options.enums === String ? $root.google.cloud.filestore.v1beta1.Instance.Tier[message.tier] === undefined ? message.tier : $root.google.cloud.filestore.v1beta1.Instance.Tier[message.tier] : message.tier; var keys2; if (message.labels && (keys2 = Object.keys(message.labels)).length) { object.labels = {}; @@ -10600,6 +10668,12 @@ if (object.description != null) message.description = String(object.description); switch (object.state) { + default: + if (typeof object.state === "number") { + message.state = object.state; + break; + } + break; case "STATE_UNSPECIFIED": case 0: message.state = 0; @@ -10672,7 +10746,7 @@ if (message.description != null && message.hasOwnProperty("description")) object.description = message.description; if (message.state != null && message.hasOwnProperty("state")) - object.state = options.enums === String ? $root.google.cloud.filestore.v1beta1.Snapshot.State[message.state] : message.state; + object.state = options.enums === String ? $root.google.cloud.filestore.v1beta1.Snapshot.State[message.state] === undefined ? message.state : $root.google.cloud.filestore.v1beta1.Snapshot.State[message.state] : message.state; if (message.createTime != null && message.hasOwnProperty("createTime")) object.createTime = $root.google.protobuf.Timestamp.toObject(message.createTime, options); var keys2; @@ -11135,6 +11209,12 @@ if (object.description != null) message.description = String(object.description); switch (object.state) { + default: + if (typeof object.state === "number") { + message.state = object.state; + break; + } + break; case "STATE_UNSPECIFIED": case 0: message.state = 0; @@ -11191,6 +11271,12 @@ if (object.sourceFileShare != null) message.sourceFileShare = String(object.sourceFileShare); switch (object.sourceInstanceTier) { + default: + if (typeof object.sourceInstanceTier === "number") { + message.sourceInstanceTier = object.sourceInstanceTier; + break; + } + break; case "TIER_UNSPECIFIED": case 0: message.sourceInstanceTier = 0; @@ -11278,7 +11364,7 @@ if (message.description != null && message.hasOwnProperty("description")) object.description = message.description; if (message.state != null && message.hasOwnProperty("state")) - object.state = options.enums === String ? $root.google.cloud.filestore.v1beta1.Backup.State[message.state] : message.state; + object.state = options.enums === String ? $root.google.cloud.filestore.v1beta1.Backup.State[message.state] === undefined ? message.state : $root.google.cloud.filestore.v1beta1.Backup.State[message.state] : message.state; if (message.createTime != null && message.hasOwnProperty("createTime")) object.createTime = $root.google.protobuf.Timestamp.toObject(message.createTime, options); var keys2; @@ -11302,7 +11388,7 @@ if (message.sourceFileShare != null && message.hasOwnProperty("sourceFileShare")) object.sourceFileShare = message.sourceFileShare; if (message.sourceInstanceTier != null && message.hasOwnProperty("sourceInstanceTier")) - object.sourceInstanceTier = options.enums === String ? $root.google.cloud.filestore.v1beta1.Instance.Tier[message.sourceInstanceTier] : message.sourceInstanceTier; + object.sourceInstanceTier = options.enums === String ? $root.google.cloud.filestore.v1beta1.Instance.Tier[message.sourceInstanceTier] === undefined ? message.sourceInstanceTier : $root.google.cloud.filestore.v1beta1.Instance.Tier[message.sourceInstanceTier] : message.sourceInstanceTier; if (message.downloadBytes != null && message.hasOwnProperty("downloadBytes")) if (typeof message.downloadBytes === "number") object.downloadBytes = options.longs === String ? String(message.downloadBytes) : message.downloadBytes; @@ -14155,6 +14241,12 @@ if (object.nameField != null) message.nameField = String(object.nameField); switch (object.history) { + default: + if (typeof object.history === "number") { + message.history = object.history; + break; + } + break; case "HISTORY_UNSPECIFIED": case 0: message.history = 0; @@ -14179,6 +14271,10 @@ for (var i = 0; i < object.style.length; ++i) switch (object.style[i]) { default: + if (typeof object.style[i] === "number") { + message.style[i] = object.style[i]; + break; + } case "STYLE_UNSPECIFIED": case 0: message.style[i] = 0; @@ -14226,7 +14322,7 @@ if (message.nameField != null && message.hasOwnProperty("nameField")) object.nameField = message.nameField; if (message.history != null && message.hasOwnProperty("history")) - object.history = options.enums === String ? $root.google.api.ResourceDescriptor.History[message.history] : message.history; + object.history = options.enums === String ? $root.google.api.ResourceDescriptor.History[message.history] === undefined ? message.history : $root.google.api.ResourceDescriptor.History[message.history] : message.history; if (message.plural != null && message.hasOwnProperty("plural")) object.plural = message.plural; if (message.singular != null && message.hasOwnProperty("singular")) @@ -14234,7 +14330,7 @@ if (message.style && message.style.length) { object.style = []; for (var j = 0; j < message.style.length; ++j) - object.style[j] = options.enums === String ? $root.google.api.ResourceDescriptor.Style[message.style[j]] : message.style[j]; + object.style[j] = options.enums === String ? $root.google.api.ResourceDescriptor.Style[message.style[j]] === undefined ? message.style[j] : $root.google.api.ResourceDescriptor.Style[message.style[j]] : message.style[j]; } return object; }; @@ -17045,6 +17141,12 @@ if (object.number != null) message.number = object.number | 0; switch (object.label) { + default: + if (typeof object.label === "number") { + message.label = object.label; + break; + } + break; case "LABEL_OPTIONAL": case 1: message.label = 1; @@ -17059,6 +17161,12 @@ break; } switch (object.type) { + default: + if (typeof object.type === "number") { + message.type = object.type; + break; + } + break; case "TYPE_DOUBLE": case 1: message.type = 1; @@ -17185,9 +17293,9 @@ if (message.number != null && message.hasOwnProperty("number")) object.number = message.number; if (message.label != null && message.hasOwnProperty("label")) - object.label = options.enums === String ? $root.google.protobuf.FieldDescriptorProto.Label[message.label] : message.label; + object.label = options.enums === String ? $root.google.protobuf.FieldDescriptorProto.Label[message.label] === undefined ? message.label : $root.google.protobuf.FieldDescriptorProto.Label[message.label] : message.label; if (message.type != null && message.hasOwnProperty("type")) - object.type = options.enums === String ? $root.google.protobuf.FieldDescriptorProto.Type[message.type] : message.type; + object.type = options.enums === String ? $root.google.protobuf.FieldDescriptorProto.Type[message.type] === undefined ? message.type : $root.google.protobuf.FieldDescriptorProto.Type[message.type] : message.type; if (message.typeName != null && message.hasOwnProperty("typeName")) object.typeName = message.typeName; if (message.defaultValue != null && message.hasOwnProperty("defaultValue")) @@ -19534,6 +19642,12 @@ if (object.javaStringCheckUtf8 != null) message.javaStringCheckUtf8 = Boolean(object.javaStringCheckUtf8); switch (object.optimizeFor) { + default: + if (typeof object.optimizeFor === "number") { + message.optimizeFor = object.optimizeFor; + break; + } + break; case "SPEED": case 1: message.optimizeFor = 1; @@ -19642,7 +19756,7 @@ if (message.javaOuterClassname != null && message.hasOwnProperty("javaOuterClassname")) object.javaOuterClassname = message.javaOuterClassname; if (message.optimizeFor != null && message.hasOwnProperty("optimizeFor")) - object.optimizeFor = options.enums === String ? $root.google.protobuf.FileOptions.OptimizeMode[message.optimizeFor] : message.optimizeFor; + object.optimizeFor = options.enums === String ? $root.google.protobuf.FileOptions.OptimizeMode[message.optimizeFor] === undefined ? message.optimizeFor : $root.google.protobuf.FileOptions.OptimizeMode[message.optimizeFor] : message.optimizeFor; if (message.javaMultipleFiles != null && message.hasOwnProperty("javaMultipleFiles")) object.javaMultipleFiles = message.javaMultipleFiles; if (message.goPackage != null && message.hasOwnProperty("goPackage")) @@ -20444,6 +20558,12 @@ return object; var message = new $root.google.protobuf.FieldOptions(); switch (object.ctype) { + default: + if (typeof object.ctype === "number") { + message.ctype = object.ctype; + break; + } + break; case "STRING": case 0: message.ctype = 0; @@ -20460,6 +20580,12 @@ if (object.packed != null) message.packed = Boolean(object.packed); switch (object.jstype) { + default: + if (typeof object.jstype === "number") { + message.jstype = object.jstype; + break; + } + break; case "JS_NORMAL": case 0: message.jstype = 0; @@ -20498,6 +20624,10 @@ for (var i = 0; i < object[".google.api.fieldBehavior"].length; ++i) switch (object[".google.api.fieldBehavior"][i]) { default: + if (typeof object[".google.api.fieldBehavior"][i] === "number") { + message[".google.api.fieldBehavior"][i] = object[".google.api.fieldBehavior"][i]; + break; + } case "FIELD_BEHAVIOR_UNSPECIFIED": case 0: message[".google.api.fieldBehavior"][i] = 0; @@ -20568,7 +20698,7 @@ object[".google.api.resourceReference"] = null; } if (message.ctype != null && message.hasOwnProperty("ctype")) - object.ctype = options.enums === String ? $root.google.protobuf.FieldOptions.CType[message.ctype] : message.ctype; + object.ctype = options.enums === String ? $root.google.protobuf.FieldOptions.CType[message.ctype] === undefined ? message.ctype : $root.google.protobuf.FieldOptions.CType[message.ctype] : message.ctype; if (message.packed != null && message.hasOwnProperty("packed")) object.packed = message.packed; if (message.deprecated != null && message.hasOwnProperty("deprecated")) @@ -20576,7 +20706,7 @@ if (message.lazy != null && message.hasOwnProperty("lazy")) object.lazy = message.lazy; if (message.jstype != null && message.hasOwnProperty("jstype")) - object.jstype = options.enums === String ? $root.google.protobuf.FieldOptions.JSType[message.jstype] : message.jstype; + object.jstype = options.enums === String ? $root.google.protobuf.FieldOptions.JSType[message.jstype] === undefined ? message.jstype : $root.google.protobuf.FieldOptions.JSType[message.jstype] : message.jstype; if (message.weak != null && message.hasOwnProperty("weak")) object.weak = message.weak; if (message.unverifiedLazy != null && message.hasOwnProperty("unverifiedLazy")) @@ -20589,7 +20719,7 @@ if (message[".google.api.fieldBehavior"] && message[".google.api.fieldBehavior"].length) { object[".google.api.fieldBehavior"] = []; for (var j = 0; j < message[".google.api.fieldBehavior"].length; ++j) - object[".google.api.fieldBehavior"][j] = options.enums === String ? $root.google.api.FieldBehavior[message[".google.api.fieldBehavior"][j]] : message[".google.api.fieldBehavior"][j]; + object[".google.api.fieldBehavior"][j] = options.enums === String ? $root.google.api.FieldBehavior[message[".google.api.fieldBehavior"][j]] === undefined ? message[".google.api.fieldBehavior"][j] : $root.google.api.FieldBehavior[message[".google.api.fieldBehavior"][j]] : message[".google.api.fieldBehavior"][j]; } if (message[".google.api.resourceReference"] != null && message.hasOwnProperty(".google.api.resourceReference")) object[".google.api.resourceReference"] = $root.google.api.ResourceReference.toObject(message[".google.api.resourceReference"], options); @@ -21966,6 +22096,12 @@ if (object.deprecated != null) message.deprecated = Boolean(object.deprecated); switch (object.idempotencyLevel) { + default: + if (typeof object.idempotencyLevel === "number") { + message.idempotencyLevel = object.idempotencyLevel; + break; + } + break; case "IDEMPOTENCY_UNKNOWN": case 0: message.idempotencyLevel = 0; @@ -22035,7 +22171,7 @@ if (message.deprecated != null && message.hasOwnProperty("deprecated")) object.deprecated = message.deprecated; if (message.idempotencyLevel != null && message.hasOwnProperty("idempotencyLevel")) - object.idempotencyLevel = options.enums === String ? $root.google.protobuf.MethodOptions.IdempotencyLevel[message.idempotencyLevel] : message.idempotencyLevel; + object.idempotencyLevel = options.enums === String ? $root.google.protobuf.MethodOptions.IdempotencyLevel[message.idempotencyLevel] === undefined ? message.idempotencyLevel : $root.google.protobuf.MethodOptions.IdempotencyLevel[message.idempotencyLevel] : message.idempotencyLevel; if (message.uninterpretedOption && message.uninterpretedOption.length) { object.uninterpretedOption = []; for (var j = 0; j < message.uninterpretedOption.length; ++j) @@ -23790,6 +23926,12 @@ if (object.end != null) message.end = object.end | 0; switch (object.semantic) { + default: + if (typeof object.semantic === "number") { + message.semantic = object.semantic; + break; + } + break; case "NONE": case 0: message.semantic = 0; @@ -23839,7 +23981,7 @@ if (message.end != null && message.hasOwnProperty("end")) object.end = message.end; if (message.semantic != null && message.hasOwnProperty("semantic")) - object.semantic = options.enums === String ? $root.google.protobuf.GeneratedCodeInfo.Annotation.Semantic[message.semantic] : message.semantic; + object.semantic = options.enums === String ? $root.google.protobuf.GeneratedCodeInfo.Annotation.Semantic[message.semantic] === undefined ? message.semantic : $root.google.protobuf.GeneratedCodeInfo.Annotation.Semantic[message.semantic] : message.semantic; return object; };