gremlin 3.4.12 → 3.5.2

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.
Files changed (77) hide show
  1. package/NOTICE +1 -1
  2. package/doc/AnonymousTraversalSource.html +11 -3
  3. package/doc/Authenticator.html +6 -2
  4. package/doc/Bytecode.html +258 -6
  5. package/doc/Client.html +84 -6
  6. package/doc/Connection.html +12 -2
  7. package/doc/DriverRemoteConnection.html +392 -8
  8. package/doc/EdgeLabelVerificationStrategy.html +5 -3
  9. package/doc/Graph.html +6 -2
  10. package/doc/GraphSON2Reader.html +6 -2
  11. package/doc/GraphSON2Writer.html +8 -2
  12. package/doc/GraphSON3Reader.html +4 -2
  13. package/doc/GraphSON3Writer.html +4 -2
  14. package/doc/GraphTraversal.html +317 -107
  15. package/doc/GraphTraversalSource.html +164 -19
  16. package/doc/HaltedTraverserStrategy.html +5 -3
  17. package/doc/MatchAlgorithmStrategy.html +5 -3
  18. package/doc/P.html +28 -2
  19. package/doc/PartitionStrategy.html +5 -3
  20. package/doc/Path.html +4 -2
  21. package/doc/PlainTextSaslAuthenticator.html +6 -2
  22. package/doc/ProductiveByStrategy.html +288 -0
  23. package/doc/RemoteConnection.html +561 -13
  24. package/doc/RemoteStrategy.html +8 -4
  25. package/doc/RemoteTraversal.html +5 -3
  26. package/doc/ReservedKeysVerificationStrategy.html +5 -3
  27. package/doc/ResponseError.html +4 -2
  28. package/doc/ResultSet.html +10 -2
  29. package/doc/SaslAuthenticator.html +6 -2
  30. package/doc/SaslMechanismBase.html +8 -2
  31. package/doc/SaslMechanismPlain.html +10 -2
  32. package/doc/SeedStrategy.html +288 -0
  33. package/doc/SubgraphStrategy.html +5 -3
  34. package/doc/TextP.html +18 -2
  35. package/doc/Transaction.html +2 -2
  36. package/doc/Translator.html +202 -4
  37. package/doc/TraversalStrategies.html +142 -3
  38. package/doc/TraversalStrategy.html +8 -4
  39. package/doc/TypeSerializer.html +4 -2
  40. package/doc/driver_auth_authenticator.js.html +2 -2
  41. package/doc/driver_auth_mechanisms_sasl-mechanism-base.js.html +2 -2
  42. package/doc/driver_auth_mechanisms_sasl-mechanism-plain.js.html +2 -2
  43. package/doc/driver_auth_plain-text-sasl-authenticator.js.html +2 -2
  44. package/doc/driver_auth_sasl-authenticator.js.html +2 -2
  45. package/doc/driver_client.js.html +20 -8
  46. package/doc/driver_connection.js.html +2 -2
  47. package/doc/driver_driver-remote-connection.js.html +38 -4
  48. package/doc/driver_remote-connection.js.html +55 -5
  49. package/doc/driver_response-error.js.html +2 -2
  50. package/doc/driver_result-set.js.html +2 -2
  51. package/doc/global.html +3 -3
  52. package/doc/index.html +35 -18
  53. package/doc/process_anonymous-traversal.js.html +3 -3
  54. package/doc/process_bytecode.js.html +32 -3
  55. package/doc/process_graph-traversal.js.html +25 -6
  56. package/doc/process_transaction.js.html +2 -2
  57. package/doc/process_translator.js.html +45 -32
  58. package/doc/process_traversal-strategy.js.html +23 -2
  59. package/doc/process_traversal.js.html +3 -3
  60. package/doc/scripts/linenumber.js +9 -9
  61. package/doc/structure_graph.js.html +2 -2
  62. package/doc/structure_io_graph-serializer.js.html +2 -2
  63. package/doc/structure_io_type-serializers.js.html +2 -2
  64. package/doc/styles/jsdoc-default.css +2 -2
  65. package/lib/driver/client.js +18 -6
  66. package/lib/driver/driver-remote-connection.js +36 -2
  67. package/lib/driver/remote-connection.js +53 -3
  68. package/lib/process/anonymous-traversal.js +1 -1
  69. package/lib/process/bytecode.js +30 -1
  70. package/lib/process/graph-traversal.js +23 -4
  71. package/lib/process/transaction.js +86 -0
  72. package/lib/process/translator.js +43 -30
  73. package/lib/process/traversal-strategy.js +21 -0
  74. package/lib/process/traversal.js +1 -1
  75. package/package.json +6 -5
  76. package/.npmignore +0 -26
  77. package/package-lock.json +0 -5828
@@ -45,6 +45,16 @@ class TraversalStrategies {
45
45
  this.strategies.push(strategy);
46
46
  }
47
47
 
48
+ /** @param {TraversalStrategy} strategy */
49
+ removeStrategy(strategy) {
50
+ const idx = this.strategies.findIndex(s => s.fqcn === strategy.fqcn);
51
+ if (idx !== -1) {
52
+ return this.strategies.splice(idx, 1)[0];
53
+ }
54
+
55
+ return undefined;
56
+ }
57
+
48
58
  /**
49
59
  * @param {Traversal} traversal
50
60
  * @returns {Promise}
@@ -141,6 +151,16 @@ class SubgraphStrategy extends TraversalStrategy {
141
151
  }
142
152
  }
143
153
 
154
+ class ProductiveByStrategy extends TraversalStrategy {
155
+ /**
156
+ * @param {Object} [options]
157
+ * @param {Array<String>} [options.productiveKeys] set of keys that will always be productive
158
+ */
159
+ constructor(options) {
160
+ super("org.apache.tinkerpop.gremlin.process.traversal.strategy.optimization.ProductiveByStrategy", options);
161
+ }
162
+ }
163
+
144
164
  class VertexProgramStrategy extends TraversalStrategy {
145
165
 
146
166
  constructor(options) {
@@ -302,6 +322,7 @@ module.exports = {
302
322
  OrderLimitStrategy: OrderLimitStrategy,
303
323
  PathProcessorStrategy: PathProcessorStrategy,
304
324
  PathRetractionStrategy: PathRetractionStrategy,
325
+ ProductiveByStrategy: ProductiveByStrategy,
305
326
  CountStrategy: CountStrategy,
306
327
  RepeatUnrollStrategy: RepeatUnrollStrategy,
307
328
  GraphFilterStrategy: GraphFilterStrategy,
@@ -497,7 +497,7 @@ module.exports = {
497
497
  graphSONVersion: toEnum('GraphSONVersion', 'V1_0 V2_0 V3_0'),
498
498
  gryoVersion: toEnum('GryoVersion', 'V1_0 V3_0'),
499
499
  operator: toEnum('Operator', 'addAll and assign div max min minus mult or sum sumLong'),
500
- order: toEnum('Order', 'asc decr desc incr shuffle'),
500
+ order: toEnum('Order', 'asc desc shuffle'),
501
501
  pick: toEnum('Pick', 'any none'),
502
502
  pop: toEnum('Pop', 'all first last mixed'),
503
503
  scope: toEnum('Scope', 'global local'),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gremlin",
3
- "version": "3.4.12",
3
+ "version": "3.5.2",
4
4
  "description": "JavaScript Gremlin Language Variant",
5
5
  "author": "Apache TinkerPop team",
6
6
  "keywords": [
@@ -19,10 +19,11 @@
19
19
  "devDependencies": {
20
20
  "chai": "~4.1.2",
21
21
  "cucumber": "~4.2.1",
22
- "grunt": "~1.0.4",
22
+ "grunt": "~1.2.0",
23
23
  "grunt-cli": "~1.3.2",
24
- "grunt-jsdoc": "~2.3.1",
25
- "mocha": "~5.2.0"
24
+ "grunt-jsdoc": "~2.4.1",
25
+ "mocha": "~5.2.0",
26
+ "colors": "1.4.0"
26
27
  },
27
28
  "repository": {
28
29
  "type": "git",
@@ -38,6 +39,6 @@
38
39
  "unit-test": "./node_modules/mocha/bin/mocha test/unit"
39
40
  },
40
41
  "engines": {
41
- "node": ">=6"
42
+ "node": ">=10"
42
43
  }
43
44
  }
package/.npmignore DELETED
@@ -1,26 +0,0 @@
1
- # Licensed to the Apache Software Foundation (ASF) under one
2
- # or more contributor license agreements. See the NOTICE file
3
- # distributed with this work for additional information
4
- # regarding copyright ownership. The ASF licenses this file
5
- # to you under the Apache License, Version 2.0 (the
6
- # "License"); you may not use this file except in compliance
7
- # with the License. You may obtain a copy of the License at
8
- #
9
- # http://www.apache.org/licenses/LICENSE-2.0
10
- #
11
- # Unless required by applicable law or agreed to in writing,
12
- # software distributed under the License is distributed on an
13
- # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14
- # KIND, either express or implied. See the License for the
15
- # specific language governing permissions and limitations
16
- # under the License.
17
-
18
- *.gz
19
- *.tgz
20
- test/
21
- .DS_Store
22
- .idea
23
- node_modules/
24
- npm-debug.log
25
- # maven plugin com.github.eirslett frontend-maven-plugin installs node.js runtime in "node" folder
26
- node/