ord-schema 0.3.47 → 0.3.49

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ord-schema",
3
- "version": "0.3.47",
3
+ "version": "0.3.49",
4
4
  "description": "Schema for the Open Reaction Database",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -29,7 +29,7 @@ test('round-trip', () => {
29
29
  const reaction2 = new ord.Reaction();
30
30
  const identifier2 = reaction2.addIdentifiers();
31
31
  identifier2.setValue('amide coupling');
32
- identifier2.setType(ord.ReactionIdentifier.ReactionIdentifierType.NAME);
32
+ identifier2.setType(ord.ReactionIdentifier.ReactionIdentifierType.REACTION_TYPE);
33
33
  dataset.addReactions(reaction2);
34
34
  const serialized = dataset.serializeBinary();
35
35
  const other = ord.Dataset.deserializeBinary(serialized);
@@ -37,5 +37,5 @@ test('round-trip', () => {
37
37
  expect(other.getDescription()).toBe('test dataset');
38
38
  expect(other.getReactionsList()).toHaveLength(2);
39
39
  expect(other.getReactionsList()[0].getIdentifiersList()[0].getType()).toBe(ord.ReactionIdentifier.ReactionIdentifierType.REACTION_SMILES);
40
- expect(other.getReactionsList()[1].getIdentifiersList()[0].getType()).toBe(ord.ReactionIdentifier.ReactionIdentifierType.NAME);
40
+ expect(other.getReactionsList()[1].getIdentifiersList()[0].getType()).toBe(ord.ReactionIdentifier.ReactionIdentifierType.REACTION_TYPE);
41
41
  });
@@ -59,7 +59,6 @@ goog.exportSymbol('proto.ord.ElectrochemistryConditions', null, global);
59
59
  goog.exportSymbol('proto.ord.ElectrochemistryConditions.ElectrochemistryCell', null, global);
60
60
  goog.exportSymbol('proto.ord.ElectrochemistryConditions.ElectrochemistryCell.ElectrochemistryCellType', null, global);
61
61
  goog.exportSymbol('proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement', null, global);
62
- goog.exportSymbol('proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement.KindCase', null, global);
63
62
  goog.exportSymbol('proto.ord.ElectrochemistryConditions.ElectrochemistryType', null, global);
64
63
  goog.exportSymbol('proto.ord.FloatValue', null, global);
65
64
  goog.exportSymbol('proto.ord.FlowConditions', null, global);
@@ -809,7 +808,7 @@ if (goog.DEBUG && !COMPILED) {
809
808
  * @constructor
810
809
  */
811
810
  proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement = function(opt_data) {
812
- jspb.Message.initialize(this, opt_data, 0, -1, null, proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement.oneofGroups_);
811
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
813
812
  };
814
813
  goog.inherits(proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement, jspb.Message);
815
814
  if (goog.DEBUG && !COMPILED) {
@@ -2235,7 +2234,7 @@ proto.ord.ReactionIdentifier.ReactionIdentifierType = {
2235
2234
  REACTION_CXSMILES: 6,
2236
2235
  RDFILE: 3,
2237
2236
  RINCHI: 4,
2238
- NAME: 5
2237
+ REACTION_TYPE: 5
2239
2238
  };
2240
2239
 
2241
2240
  /**
@@ -5278,8 +5277,10 @@ proto.ord.Vessel.toObject = function(includeInstance, msg) {
5278
5277
  attachmentsList: jspb.Message.toObjectList(msg.getAttachmentsList(),
5279
5278
  proto.ord.VesselAttachment.toObject, includeInstance),
5280
5279
  volume: (f = msg.getVolume()) && proto.ord.Volume.toObject(includeInstance, f),
5281
- plateId: jspb.Message.getFieldWithDefault(msg, 7, ""),
5282
- platePosition: jspb.Message.getFieldWithDefault(msg, 8, "")
5280
+ vesselId: jspb.Message.getFieldWithDefault(msg, 7, ""),
5281
+ position: jspb.Message.getFieldWithDefault(msg, 8, ""),
5282
+ row: jspb.Message.getFieldWithDefault(msg, 9, ""),
5283
+ col: jspb.Message.getFieldWithDefault(msg, 10, "")
5283
5284
  };
5284
5285
 
5285
5286
  if (includeInstance) {
@@ -5346,11 +5347,19 @@ proto.ord.Vessel.deserializeBinaryFromReader = function(msg, reader) {
5346
5347
  break;
5347
5348
  case 7:
5348
5349
  var value = /** @type {string} */ (reader.readString());
5349
- msg.setPlateId(value);
5350
+ msg.setVesselId(value);
5350
5351
  break;
5351
5352
  case 8:
5352
5353
  var value = /** @type {string} */ (reader.readString());
5353
- msg.setPlatePosition(value);
5354
+ msg.setPosition(value);
5355
+ break;
5356
+ case 9:
5357
+ var value = /** @type {string} */ (reader.readString());
5358
+ msg.setRow(value);
5359
+ break;
5360
+ case 10:
5361
+ var value = /** @type {string} */ (reader.readString());
5362
+ msg.setCol(value);
5354
5363
  break;
5355
5364
  default:
5356
5365
  reader.skipField();
@@ -5427,20 +5436,34 @@ proto.ord.Vessel.serializeBinaryToWriter = function(message, writer) {
5427
5436
  proto.ord.Volume.serializeBinaryToWriter
5428
5437
  );
5429
5438
  }
5430
- f = message.getPlateId();
5439
+ f = message.getVesselId();
5431
5440
  if (f.length > 0) {
5432
5441
  writer.writeString(
5433
5442
  7,
5434
5443
  f
5435
5444
  );
5436
5445
  }
5437
- f = message.getPlatePosition();
5446
+ f = message.getPosition();
5438
5447
  if (f.length > 0) {
5439
5448
  writer.writeString(
5440
5449
  8,
5441
5450
  f
5442
5451
  );
5443
5452
  }
5453
+ f = message.getRow();
5454
+ if (f.length > 0) {
5455
+ writer.writeString(
5456
+ 9,
5457
+ f
5458
+ );
5459
+ }
5460
+ f = message.getCol();
5461
+ if (f.length > 0) {
5462
+ writer.writeString(
5463
+ 10,
5464
+ f
5465
+ );
5466
+ }
5444
5467
  };
5445
5468
 
5446
5469
 
@@ -5650,10 +5673,10 @@ proto.ord.Vessel.prototype.hasVolume = function() {
5650
5673
 
5651
5674
 
5652
5675
  /**
5653
- * optional string plate_id = 7;
5676
+ * optional string vessel_id = 7;
5654
5677
  * @return {string}
5655
5678
  */
5656
- proto.ord.Vessel.prototype.getPlateId = function() {
5679
+ proto.ord.Vessel.prototype.getVesselId = function() {
5657
5680
  return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 7, ""));
5658
5681
  };
5659
5682
 
@@ -5662,16 +5685,16 @@ proto.ord.Vessel.prototype.getPlateId = function() {
5662
5685
  * @param {string} value
5663
5686
  * @return {!proto.ord.Vessel} returns this
5664
5687
  */
5665
- proto.ord.Vessel.prototype.setPlateId = function(value) {
5688
+ proto.ord.Vessel.prototype.setVesselId = function(value) {
5666
5689
  return jspb.Message.setProto3StringField(this, 7, value);
5667
5690
  };
5668
5691
 
5669
5692
 
5670
5693
  /**
5671
- * optional string plate_position = 8;
5694
+ * optional string position = 8;
5672
5695
  * @return {string}
5673
5696
  */
5674
- proto.ord.Vessel.prototype.getPlatePosition = function() {
5697
+ proto.ord.Vessel.prototype.getPosition = function() {
5675
5698
  return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 8, ""));
5676
5699
  };
5677
5700
 
@@ -5680,11 +5703,47 @@ proto.ord.Vessel.prototype.getPlatePosition = function() {
5680
5703
  * @param {string} value
5681
5704
  * @return {!proto.ord.Vessel} returns this
5682
5705
  */
5683
- proto.ord.Vessel.prototype.setPlatePosition = function(value) {
5706
+ proto.ord.Vessel.prototype.setPosition = function(value) {
5684
5707
  return jspb.Message.setProto3StringField(this, 8, value);
5685
5708
  };
5686
5709
 
5687
5710
 
5711
+ /**
5712
+ * optional string row = 9;
5713
+ * @return {string}
5714
+ */
5715
+ proto.ord.Vessel.prototype.getRow = function() {
5716
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 9, ""));
5717
+ };
5718
+
5719
+
5720
+ /**
5721
+ * @param {string} value
5722
+ * @return {!proto.ord.Vessel} returns this
5723
+ */
5724
+ proto.ord.Vessel.prototype.setRow = function(value) {
5725
+ return jspb.Message.setProto3StringField(this, 9, value);
5726
+ };
5727
+
5728
+
5729
+ /**
5730
+ * optional string col = 10;
5731
+ * @return {string}
5732
+ */
5733
+ proto.ord.Vessel.prototype.getCol = function() {
5734
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 10, ""));
5735
+ };
5736
+
5737
+
5738
+ /**
5739
+ * @param {string} value
5740
+ * @return {!proto.ord.Vessel} returns this
5741
+ */
5742
+ proto.ord.Vessel.prototype.setCol = function(value) {
5743
+ return jspb.Message.setProto3StringField(this, 10, value);
5744
+ };
5745
+
5746
+
5688
5747
 
5689
5748
 
5690
5749
 
@@ -9898,32 +9957,6 @@ proto.ord.ElectrochemistryConditions.ElectrochemistryType = {
9898
9957
  };
9899
9958
 
9900
9959
 
9901
- /**
9902
- * Oneof group definitions for this message. Each group defines the field
9903
- * numbers belonging to that group. When of these fields' value is set, all
9904
- * other fields in the group are cleared. During deserialization, if multiple
9905
- * fields are encountered for a group, only the last value seen will be kept.
9906
- * @private {!Array<!Array<number>>}
9907
- * @const
9908
- */
9909
- proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement.oneofGroups_ = [[2,3]];
9910
-
9911
- /**
9912
- * @enum {number}
9913
- */
9914
- proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement.KindCase = {
9915
- KIND_NOT_SET: 0,
9916
- CURRENT: 2,
9917
- VOLTAGE: 3
9918
- };
9919
-
9920
- /**
9921
- * @return {proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement.KindCase}
9922
- */
9923
- proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement.prototype.getKindCase = function() {
9924
- return /** @type {proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement.KindCase} */(jspb.Message.computeOneofCase(this, proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement.oneofGroups_[0]));
9925
- };
9926
-
9927
9960
 
9928
9961
 
9929
9962
  if (jspb.Message.GENERATE_TO_OBJECT) {
@@ -10117,7 +10150,7 @@ proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement.prototype.getCu
10117
10150
  * @return {!proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement} returns this
10118
10151
  */
10119
10152
  proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement.prototype.setCurrent = function(value) {
10120
- return jspb.Message.setOneofWrapperField(this, 2, proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement.oneofGroups_[0], value);
10153
+ return jspb.Message.setWrapperField(this, 2, value);
10121
10154
  };
10122
10155
 
10123
10156
 
@@ -10154,7 +10187,7 @@ proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement.prototype.getVo
10154
10187
  * @return {!proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement} returns this
10155
10188
  */
10156
10189
  proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement.prototype.setVoltage = function(value) {
10157
- return jspb.Message.setOneofWrapperField(this, 3, proto.ord.ElectrochemistryConditions.ElectrochemistryMeasurement.oneofGroups_[0], value);
10190
+ return jspb.Message.setWrapperField(this, 3, value);
10158
10191
  };
10159
10192
 
10160
10193
 
@@ -15148,7 +15181,8 @@ proto.ord.ReactionProvenance.toObject = function(includeInstance, msg) {
15148
15181
  publicationUrl: jspb.Message.getFieldWithDefault(msg, 6, ""),
15149
15182
  recordCreated: (f = msg.getRecordCreated()) && proto.ord.RecordEvent.toObject(includeInstance, f),
15150
15183
  recordModifiedList: jspb.Message.toObjectList(msg.getRecordModifiedList(),
15151
- proto.ord.RecordEvent.toObject, includeInstance)
15184
+ proto.ord.RecordEvent.toObject, includeInstance),
15185
+ reactionMetadataMap: (f = msg.getReactionMetadataMap()) ? f.toObject(includeInstance, proto.ord.Data.toObject) : []
15152
15186
  };
15153
15187
 
15154
15188
  if (includeInstance) {
@@ -15221,6 +15255,12 @@ proto.ord.ReactionProvenance.deserializeBinaryFromReader = function(msg, reader)
15221
15255
  reader.readMessage(value,proto.ord.RecordEvent.deserializeBinaryFromReader);
15222
15256
  msg.addRecordModified(value);
15223
15257
  break;
15258
+ case 9:
15259
+ var value = msg.getReactionMetadataMap();
15260
+ reader.readMessage(value, function(message, reader) {
15261
+ jspb.Map.deserializeBinary(message, reader, jspb.BinaryReader.prototype.readString, jspb.BinaryReader.prototype.readMessage, proto.ord.Data.deserializeBinaryFromReader, "", new proto.ord.Data());
15262
+ });
15263
+ break;
15224
15264
  default:
15225
15265
  reader.skipField();
15226
15266
  break;
@@ -15310,6 +15350,10 @@ proto.ord.ReactionProvenance.serializeBinaryToWriter = function(message, writer)
15310
15350
  proto.ord.RecordEvent.serializeBinaryToWriter
15311
15351
  );
15312
15352
  }
15353
+ f = message.getReactionMetadataMap(true);
15354
+ if (f && f.getLength() > 0) {
15355
+ f.serializeBinary(9, writer, jspb.BinaryWriter.prototype.writeString, jspb.BinaryWriter.prototype.writeMessage, proto.ord.Data.serializeBinaryToWriter);
15356
+ }
15313
15357
  };
15314
15358
 
15315
15359
 
@@ -15534,6 +15578,28 @@ proto.ord.ReactionProvenance.prototype.clearRecordModifiedList = function() {
15534
15578
  };
15535
15579
 
15536
15580
 
15581
+ /**
15582
+ * map<string, Data> reaction_metadata = 9;
15583
+ * @param {boolean=} opt_noLazyCreate Do not create the map if
15584
+ * empty, instead returning `undefined`
15585
+ * @return {!jspb.Map<string,!proto.ord.Data>}
15586
+ */
15587
+ proto.ord.ReactionProvenance.prototype.getReactionMetadataMap = function(opt_noLazyCreate) {
15588
+ return /** @type {!jspb.Map<string,!proto.ord.Data>} */ (
15589
+ jspb.Message.getMapField(this, 9, opt_noLazyCreate,
15590
+ proto.ord.Data));
15591
+ };
15592
+
15593
+
15594
+ /**
15595
+ * Clears values from the map. The map will be non-null.
15596
+ * @return {!proto.ord.ReactionProvenance} returns this
15597
+ */
15598
+ proto.ord.ReactionProvenance.prototype.clearReactionMetadataMap = function() {
15599
+ this.getReactionMetadataMap().clear();
15600
+ return this;};
15601
+
15602
+
15537
15603
 
15538
15604
 
15539
15605