@sap/cds-compiler 4.7.6 → 4.9.0

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 (129) hide show
  1. package/CHANGELOG.md +63 -3
  2. package/bin/cds_remove_invalid_whitespace.js +135 -0
  3. package/bin/cds_update_annotations.js +180 -0
  4. package/bin/cds_update_identifiers.js +3 -4
  5. package/bin/cdsc.js +28 -1
  6. package/bin/cdshi.js +13 -3
  7. package/doc/CHANGELOG_BETA.md +24 -1
  8. package/lib/api/main.js +119 -46
  9. package/lib/api/options.js +51 -0
  10. package/lib/api/validate.js +1 -5
  11. package/lib/base/builtins.js +116 -0
  12. package/lib/base/keywords.js +5 -1
  13. package/lib/base/location.js +91 -14
  14. package/lib/base/message-registry.js +76 -46
  15. package/lib/base/messages.js +121 -35
  16. package/lib/base/model.js +4 -7
  17. package/lib/checks/actionsFunctions.js +3 -3
  18. package/lib/checks/annotationsOData.js +3 -0
  19. package/lib/checks/defaultValues.js +5 -2
  20. package/lib/checks/elements.js +2 -1
  21. package/lib/checks/enricher.js +2 -2
  22. package/lib/checks/queryNoDbArtifacts.js +5 -3
  23. package/lib/checks/utils.js +1 -1
  24. package/lib/checks/validator.js +8 -56
  25. package/lib/compiler/assert-consistency.js +11 -7
  26. package/lib/compiler/builtins.js +0 -74
  27. package/lib/compiler/checks.js +105 -29
  28. package/lib/compiler/define.js +37 -25
  29. package/lib/compiler/extend.js +35 -12
  30. package/lib/compiler/index.js +9 -10
  31. package/lib/compiler/lsp-api.js +5 -0
  32. package/lib/compiler/populate.js +13 -5
  33. package/lib/compiler/propagator.js +24 -18
  34. package/lib/compiler/resolve.js +47 -45
  35. package/lib/compiler/shared.js +61 -21
  36. package/lib/compiler/tweak-assocs.js +15 -90
  37. package/lib/compiler/utils.js +3 -3
  38. package/lib/compiler/xpr-rewrite.js +689 -0
  39. package/lib/compiler/{classes.js → xsn-model.js} +0 -16
  40. package/lib/edm/annotations/edmJson.js +7 -5
  41. package/lib/edm/annotations/genericTranslation.js +149 -71
  42. package/lib/edm/csn2edm.js +25 -9
  43. package/lib/edm/edm.js +7 -7
  44. package/lib/edm/edmInboundChecks.js +57 -5
  45. package/lib/edm/edmPreprocessor.js +54 -25
  46. package/lib/edm/edmUtils.js +3 -16
  47. package/lib/gen/Dictionary.json +138 -14
  48. package/lib/gen/language.checksum +1 -1
  49. package/lib/gen/language.interp +1 -1
  50. package/lib/gen/languageParser.js +2085 -1989
  51. package/lib/json/csnVersion.js +7 -4
  52. package/lib/json/from-csn.js +21 -11
  53. package/lib/json/to-csn.js +8 -4
  54. package/lib/language/antlrParser.js +1 -1
  55. package/lib/language/genericAntlrParser.js +23 -16
  56. package/lib/language/multiLineStringParser.js +2 -2
  57. package/lib/language/textUtils.js +1 -1
  58. package/lib/main.d.ts +90 -14
  59. package/lib/main.js +9 -1
  60. package/lib/model/cloneCsn.js +21 -9
  61. package/lib/model/csnRefs.js +153 -42
  62. package/lib/model/csnUtils.js +14 -11
  63. package/lib/model/enrichCsn.js +4 -2
  64. package/lib/model/revealInternalProperties.js +2 -1
  65. package/lib/model/sortViews.js +14 -6
  66. package/lib/modelCompare/compare.js +135 -122
  67. package/lib/optionProcessor.js +49 -2
  68. package/lib/render/DuplicateChecker.js +6 -6
  69. package/lib/render/manageConstraints.js +1 -0
  70. package/lib/render/toCdl.js +6 -3
  71. package/lib/render/toHdbcds.js +4 -48
  72. package/lib/render/toSql.js +6 -3
  73. package/lib/transform/addTenantFields.js +58 -35
  74. package/lib/transform/db/applyTransformations.js +34 -1
  75. package/lib/transform/db/constraints.js +1 -1
  76. package/lib/transform/db/expansion.js +11 -3
  77. package/lib/transform/db/flattening.js +71 -46
  78. package/lib/transform/db/groupByOrderBy.js +2 -2
  79. package/lib/transform/db/temporal.js +6 -3
  80. package/lib/transform/db/transformExists.js +2 -2
  81. package/lib/transform/db/views.js +1 -4
  82. package/lib/transform/effective/annotations.js +194 -0
  83. package/lib/transform/effective/main.js +11 -10
  84. package/lib/transform/effective/misc.js +45 -14
  85. package/lib/transform/effective/types.js +4 -3
  86. package/lib/transform/forOdata.js +29 -12
  87. package/lib/transform/forRelationalDB.js +104 -113
  88. package/lib/transform/localized.js +7 -6
  89. package/lib/transform/odata/flattening.js +228 -107
  90. package/lib/transform/odata/toFinalBaseType.js +10 -26
  91. package/lib/transform/odata/typesExposure.js +41 -25
  92. package/lib/transform/parseExpr.js +4 -7
  93. package/lib/transform/transformUtils.js +50 -43
  94. package/lib/transform/translateAssocsToJoins.js +48 -48
  95. package/lib/transform/universalCsn/coreComputed.js +2 -1
  96. package/lib/transform/universalCsn/universalCsnEnricher.js +12 -16
  97. package/package.json +2 -2
  98. package/share/messages/README.md +4 -0
  99. package/share/messages/anno-duplicate-unrelated-layer.md +1 -1
  100. package/share/messages/anno-missing-rewrite.md +45 -0
  101. package/share/messages/check-proper-type-of.md +1 -1
  102. package/share/messages/def-duplicate-autoexposed.md +1 -1
  103. package/share/messages/extend-repeated-intralayer.md +3 -16
  104. package/share/messages/extend-unrelated-layer.md +1 -1
  105. package/share/messages/message-explanations.json +2 -0
  106. package/share/messages/redirected-to-ambiguous.md +1 -1
  107. package/share/messages/redirected-to-complex.md +1 -1
  108. package/share/messages/redirected-to-unrelated.md +1 -1
  109. package/share/messages/rewrite-not-supported.md +1 -1
  110. package/share/messages/syntax-expecting-unsigned-int.md +2 -2
  111. package/share/messages/type-missing-enum-value.md +59 -0
  112. package/share/messages/wildcard-excluding-one.md +1 -1
  113. package/bin/.eslintrc.json +0 -17
  114. package/lib/api/.eslintrc.json +0 -37
  115. package/lib/checks/.eslintrc.json +0 -31
  116. package/lib/compiler/.eslintrc.json +0 -8
  117. package/lib/edm/.eslintrc.json +0 -46
  118. package/lib/inspect/.eslintrc.json +0 -4
  119. package/lib/json/.eslintrc.json +0 -4
  120. package/lib/language/.eslintrc.json +0 -4
  121. package/lib/model/.eslintrc.json +0 -13
  122. package/lib/modelCompare/utils/.eslintrc.json +0 -22
  123. package/lib/render/.eslintrc.json +0 -22
  124. package/lib/transform/.eslintrc.json +0 -13
  125. package/lib/transform/db/.eslintrc.json +0 -41
  126. package/lib/transform/draft/.eslintrc.json +0 -4
  127. package/lib/transform/effective/.eslintrc.json +0 -4
  128. package/lib/transform/universalCsn/.eslintrc.json +0 -37
  129. package/lib/utils/.eslintrc.json +0 -7
@@ -5,9 +5,10 @@ const { setProp, isDeprecatedEnabled, isBetaEnabled } = require('../base/model')
5
5
  const {
6
6
  forEachDefinition, forEachGeneric, forEachMemberRecursively,
7
7
  isEdmPropertyRendered, getUtils,
8
- isBuiltinType, applyTransformations, transformExpression, findAnnotationExpression,
9
- cardinality2str, isMagicVariable,
8
+ applyTransformations, transformExpression, findAnnotationExpression,
9
+ cardinality2str,
10
10
  } = require('../model/csnUtils');
11
+ const { isBuiltinType, isMagicVariable } = require('../base/builtins');
11
12
  const edmUtils = require('./edmUtils.js');
12
13
  const edmAnnoPreproc = require('./edmAnnoPreprocessor.js');
13
14
  const { inboundQualificationChecks } = require('./edmInboundChecks.js');
@@ -126,7 +127,7 @@ function initializeModel( csn, _options, messageFunctions, requestedServiceNames
126
127
  const mySchemaName = whatsMySchemaName(defName);
127
128
  if (mySchemaName)
128
129
  setProp(def, '$mySchemaName', mySchemaName);
129
- if (isMyServiceRequested(defName) && def.kind !== 'aspect')
130
+ if (isMyServiceRequested(defName) && def.kind !== 'aspect' && def.kind !== 'event')
130
131
  reqDefs.definitions[defName] = def;
131
132
  },
132
133
  linkAssociationTarget,
@@ -540,7 +541,6 @@ function initializeModel( csn, _options, messageFunctions, requestedServiceNames
540
541
  // preserve the original target for constraint calculation
541
542
  setProp(entityCsn.$sources[n], '_originalTarget', entityCsn.$sources[n]._target);
542
543
  entityCsn.$sources[n]._target = parameterCsn;
543
- entityCsn.$sources[n].target = parameterCsn.name;
544
544
  });
545
545
  }
546
546
 
@@ -1641,7 +1641,10 @@ function initializeModel( csn, _options, messageFunctions, requestedServiceNames
1641
1641
  if (art.type && !isBuiltinType(art.type))
1642
1642
  art = art._type || csnUtils.getCsnDef(art.type);
1643
1643
  }
1644
- keyPaths.push(...produceKeyRefPaths(art, prefix + options.pathDelimiter + k.ref.join(options.pathDelimiter), path));
1644
+ if (art === eltCsn)
1645
+ error('odata-key-recursive', path, { name: prefix });
1646
+ else
1647
+ keyPaths.push(...produceKeyRefPaths(art, prefix + options.pathDelimiter + k.ref.join(options.pathDelimiter), path));
1645
1648
  });
1646
1649
  }
1647
1650
  else {
@@ -1905,6 +1908,7 @@ function initializeModel( csn, _options, messageFunctions, requestedServiceNames
1905
1908
  markCollection(member.returns);
1906
1909
  mapCdsToEdmProp(member.returns);
1907
1910
  annotateAllowedValues(member.returns, [ ...location, 'returns' ]);
1911
+ rewriteAnnotationExpressions(member.returns);
1908
1912
  }
1909
1913
  }, defLocation);
1910
1914
  // mark members that need to be rendered as collections
@@ -2038,11 +2042,12 @@ function initializeModel( csn, _options, messageFunctions, requestedServiceNames
2038
2042
 
2039
2043
  if (edmUtils.isNavigable(assoc) && isMyServiceRequested(containee.name) || containee.$proxy) {
2040
2044
  const localAssocPath = path.join('.');
2041
- let navPropEntry = localRestrictions.find(p => p.NavigationProperty && p.NavigationProperty['='] === prefix.concat(localAssocPath).join('.'));
2045
+ const laprefix = prefix.concat(localAssocPath).join('.');
2046
+ let navPropEntry = localRestrictions.find(p => p.NavigationProperty && p.NavigationProperty['='] === laprefix);
2042
2047
  const hasEntry = !!navPropEntry;
2043
2048
 
2044
2049
  if (!hasEntry)
2045
- navPropEntry = { NavigationProperty: { '=': prefix.concat(localAssocPath).join('.') } };
2050
+ navPropEntry = { NavigationProperty: { '=': laprefix } };
2046
2051
 
2047
2052
 
2048
2053
  const props = Object.entries(containee);
@@ -2172,17 +2177,18 @@ function initializeModel( csn, _options, messageFunctions, requestedServiceNames
2172
2177
  // rewrite annotation expression paths such that they are defined against the definition
2173
2178
  const absPath = $path2path(carrier.$path);
2174
2179
  let isSubTreeSpan = true;
2175
- const rootPrefix = absPath.slice(1, absPath.length - 1);
2176
2180
 
2177
- const isExprAnno = (obj, pn) => isBetaEnabled(options, 'odataPathsInAnnotationExpressions') && findAnnotationExpression(obj, pn);
2181
+ let rootPrefix = absPath.slice(1, absPath.length - 1);
2178
2182
 
2179
2183
  const subTreeSpan = {
2180
2184
  ref: (parent, _prop, xpr) => {
2181
2185
  const head = xpr[0].id || xpr[0];
2182
2186
  if (head === '$self' || parent.param) {
2183
2187
  let j = parent.param ? 0 : 1;
2188
+ const k = parent.param ? 1 : 0;
2189
+ isSubTreeSpan = isSubTreeSpan && (absPath.length - k <= xpr.length);
2184
2190
  for (let i = 1; i < absPath.length - 1 && isSubTreeSpan; i++, j++)
2185
- isSubTreeSpan = (xpr[j].id || xpr[j]) === absPath[i];
2191
+ isSubTreeSpan = isSubTreeSpan && (xpr[j].id || xpr[j]) === absPath[i];
2186
2192
  }
2187
2193
  },
2188
2194
  };
@@ -2197,10 +2203,13 @@ function initializeModel( csn, _options, messageFunctions, requestedServiceNames
2197
2203
  for (let i = 1; i < absPath.length - 1 && absPathPrefixEqual; i++, j++)
2198
2204
  absPathPrefixEqual = (xpr[j].id || xpr[j]) === absPath[i];
2199
2205
 
2200
- if (absPathPrefixEqual)
2206
+ if (absPathPrefixEqual) {
2201
2207
  // remove prefix between $self and leaf element name
2202
2208
  // or starting with the parameter name
2203
2209
  xpr.splice(parent.param ? 0 : 1, absPath.length - 2);
2210
+ if (parent.param)
2211
+ parent.param = null;
2212
+ }
2204
2213
  }
2205
2214
  },
2206
2215
  };
@@ -2221,9 +2230,34 @@ function initializeModel( csn, _options, messageFunctions, requestedServiceNames
2221
2230
  if (absPath.length > 2) {
2222
2231
  const [ xprANames, nxprANames ] = Object.keys(carrier).reduce((acc, pn) => {
2223
2232
  if (pn[0] === '@')
2224
- acc[isExprAnno(carrier, pn) ? 0 : 1].push(pn);
2233
+ acc[findAnnotationExpression(carrier, pn) ? 0 : 1].push(pn);
2225
2234
  return acc;
2226
2235
  }, [ [], [] ]);
2236
+
2237
+ let scope = carrier.$path[2];
2238
+ let def = csn.definitions[carrier.$path[1]];
2239
+ // unbound
2240
+ if (scope === 'returns') {
2241
+ absPath[1] = '$ReturnType';
2242
+ rootPrefix = absPath.slice(3, absPath.length - 1);
2243
+ }
2244
+ let eltPath = absPath.slice(1).join('/');
2245
+ // bound action
2246
+ if (scope === 'actions' && def[scope][carrier.$path[3]]) {
2247
+ def = def[scope][carrier.$path[3]];
2248
+ scope = carrier.$path[4];
2249
+ if (scope === 'params') {
2250
+ rootPrefix = absPath.slice(2, absPath.length - 1);
2251
+ eltPath = absPath.slice(2).join('/');
2252
+ }
2253
+ if (scope === 'returns') {
2254
+ absPath[2] = '$ReturnType';
2255
+ rootPrefix = absPath.slice(3, absPath.length - 1);
2256
+ eltPath = absPath.slice(2).join('/');
2257
+ }
2258
+ }
2259
+ const proxyDict = `$${scope}AnnoProxies`;
2260
+
2227
2261
  xprANames.forEach((xprAName) => {
2228
2262
  isSubTreeSpan = true;
2229
2263
  transformExpression(carrier, xprAName, subTreeSpan);
@@ -2231,18 +2265,13 @@ function initializeModel( csn, _options, messageFunctions, requestedServiceNames
2231
2265
  transformExpression(carrier, xprAName, relativize);
2232
2266
  }
2233
2267
  else {
2234
- const scope = carrier.$path[2];
2235
2268
  absolutize.scope = scope;
2236
2269
  transformExpression(carrier, xprAName, absolutize);
2237
- const def = csn.definitions[absPath[0]];
2238
- const eltPath = absPath.slice(1).join('/');
2239
- const proxyDict = scope === 'elements' ? '$eltAnnoProxies' : '$paramAnnoProxies';
2240
-
2241
2270
  if (!def[proxyDict])
2242
2271
  setProp(def, proxyDict, Object.create(null));
2243
- let eltProxy = def[proxyDict][eltPath];
2244
- if (!eltProxy) {
2245
- eltProxy = Object.create(null);
2272
+ let proxyCarrier = def[proxyDict][eltPath];
2273
+ if (!proxyCarrier) {
2274
+ proxyCarrier = Object.create(null);
2246
2275
  // these attributes are needed to test for
2247
2276
  // Property, Parameter, NavigationProperty, Collection
2248
2277
  // Applicability
@@ -2255,18 +2284,18 @@ function initializeModel( csn, _options, messageFunctions, requestedServiceNames
2255
2284
  '@cds.api.ignore',
2256
2285
  '@odata.navigable' ].forEach((prop) => {
2257
2286
  if (carrier[prop] != null)
2258
- setProp(eltProxy, prop, carrier[prop]);
2287
+ setProp(proxyCarrier, prop, carrier[prop]);
2259
2288
  });
2260
2289
 
2261
2290
  Object.keys(carrier).filter(pn => pn[0] !== '@').forEach((pn) => {
2262
- eltProxy[pn] = carrier[pn];
2291
+ proxyCarrier[pn] = carrier[pn];
2263
2292
  });
2264
- def[proxyDict][eltPath] = eltProxy;
2293
+ def[proxyDict][eltPath] = proxyCarrier;
2265
2294
  }
2266
- eltProxy[xprAName] = carrier[xprAName];
2295
+ proxyCarrier[xprAName] = carrier[xprAName];
2267
2296
  carrier[xprAName] = null;
2268
2297
  nxprANames.filter(an => an.startsWith(`${xprAName}.`)).forEach((nxprAName) => {
2269
- eltProxy[nxprAName] = carrier[nxprAName];
2298
+ proxyCarrier[nxprAName] = carrier[nxprAName];
2270
2299
  carrier[nxprAName] = null;
2271
2300
  });
2272
2301
  }
@@ -1,9 +1,10 @@
1
1
  'use strict';
2
2
 
3
- const { setProp, isBetaEnabled } = require('../base/model');
3
+ const { setProp } = require('../base/model');
4
4
  const {
5
- isBuiltinType, isEdmPropertyRendered, applyTransformations,
5
+ isEdmPropertyRendered, applyTransformations,
6
6
  } = require('../model/csnUtils');
7
+ const { isBuiltinType } = require('../base/builtins');
7
8
  const { escapeString, hasControlCharacters, hasUnpairedUnicodeSurrogate } = require('../render/utils/stringEscapes');
8
9
  const { CompilerAssertion } = require('../base/error');
9
10
  const { cloneAnnotationValue } = require('../model/cloneCsn');
@@ -31,20 +32,6 @@ function validateOptions( _options ) {
31
32
  options.isV4 = () => v4;
32
33
 
33
34
  options.pathDelimiter = options.isStructFormat ? '/' : '_';
34
-
35
- if (isBetaEnabled(options, 'v5preview')) {
36
- if (!options.severities)
37
- options.severities = {};
38
- options.severities['odata-spec-violation-array'] ??= 'Error';
39
- options.severities['odata-spec-violation-assoc'] ??= 'Error';
40
- options.severities['odata-spec-violation-namespace'] ??= 'Error';
41
- options.severities['odata-spec-violation-param'] ??= 'Error';
42
- options.severities['odata-spec-violation-returns'] ??= 'Error';
43
- options.severities['odata-spec-violation-type-unknown'] ??= 'Error';
44
- options.severities['odata-spec-violation-no-key'] ??= 'Error';
45
- options.severities['odata-spec-violation-key-type'] ??= 'Error';
46
- options.severities['odata-spec-violation-property-name'] ??= 'Error';
47
- }
48
35
  return options;
49
36
  }
50
37
  return _options;
@@ -213,7 +213,6 @@
213
213
  "Type": "Capabilities.CountRestrictionsType",
214
214
  "AppliesTo": [
215
215
  "EntitySet",
216
- "Singleton",
217
216
  "Collection"
218
217
  ]
219
218
  },
@@ -417,6 +416,12 @@
417
416
  "Property"
418
417
  ]
419
418
  },
419
+ "Capabilities.DefaultCapabilities": {
420
+ "Type": "Capabilities.DefaultCapabilitiesType",
421
+ "AppliesTo": [
422
+ "EntityContainer"
423
+ ]
424
+ },
420
425
  "CodeList.CurrencyCodes": {
421
426
  "Type": "CodeList.CodeListSource",
422
427
  "AppliesTo": [
@@ -2553,20 +2558,34 @@
2553
2558
  "DocumentationUrl": "Edm.String"
2554
2559
  }
2555
2560
  },
2561
+ "Capabilities.ChangeTrackingBase": {
2562
+ "$kind": "ComplexType",
2563
+ "Properties": {
2564
+ "Supported": "Edm.Boolean"
2565
+ }
2566
+ },
2556
2567
  "Capabilities.ChangeTrackingType": {
2557
2568
  "$kind": "ComplexType",
2569
+ "BaseType": "Capabilities.ChangeTrackingBase",
2558
2570
  "Properties": {
2559
- "Supported": "Edm.Boolean",
2560
2571
  "FilterableProperties": "Collection(Edm.PropertyPath)",
2561
- "ExpandableProperties": "Collection(Edm.NavigationPropertyPath)"
2572
+ "ExpandableProperties": "Collection(Edm.NavigationPropertyPath)",
2573
+ "Supported": "Edm.Boolean"
2574
+ }
2575
+ },
2576
+ "Capabilities.CountRestrictionsBase": {
2577
+ "$kind": "ComplexType",
2578
+ "Properties": {
2579
+ "Countable": "Edm.Boolean"
2562
2580
  }
2563
2581
  },
2564
2582
  "Capabilities.CountRestrictionsType": {
2565
2583
  "$kind": "ComplexType",
2584
+ "BaseType": "Capabilities.CountRestrictionsBase",
2566
2585
  "Properties": {
2567
- "Countable": "Edm.Boolean",
2568
2586
  "NonCountableProperties": "Collection(Edm.PropertyPath)",
2569
- "NonCountableNavigationProperties": "Collection(Edm.NavigationPropertyPath)"
2587
+ "NonCountableNavigationProperties": "Collection(Edm.NavigationPropertyPath)",
2588
+ "Countable": "Edm.Boolean"
2570
2589
  }
2571
2590
  },
2572
2591
  "Capabilities.NavigationRestrictionsType": {
@@ -2625,14 +2644,23 @@
2625
2644
  "SupportedFormats": "Collection(Edm.String)"
2626
2645
  }
2627
2646
  },
2628
- "Capabilities.FilterRestrictionsType": {
2647
+ "Capabilities.FilterRestrictionsBase": {
2629
2648
  "$kind": "ComplexType",
2630
2649
  "Properties": {
2631
2650
  "Filterable": "Edm.Boolean",
2632
2651
  "RequiresFilter": "Edm.Boolean",
2652
+ "MaxLevels": "Edm.Int32"
2653
+ }
2654
+ },
2655
+ "Capabilities.FilterRestrictionsType": {
2656
+ "$kind": "ComplexType",
2657
+ "BaseType": "Capabilities.FilterRestrictionsBase",
2658
+ "Properties": {
2633
2659
  "RequiredProperties": "Collection(Edm.PropertyPath)",
2634
2660
  "NonFilterableProperties": "Collection(Edm.PropertyPath)",
2635
2661
  "FilterExpressionRestrictions": "Collection(Capabilities.FilterExpressionRestrictionType)",
2662
+ "Filterable": "Edm.Boolean",
2663
+ "RequiresFilter": "Edm.Boolean",
2636
2664
  "MaxLevels": "Edm.Int32"
2637
2665
  }
2638
2666
  },
@@ -2643,22 +2671,38 @@
2643
2671
  "AllowedExpressions": "Capabilities.FilterExpressionType"
2644
2672
  }
2645
2673
  },
2674
+ "Capabilities.SortRestrictionsBase": {
2675
+ "$kind": "ComplexType",
2676
+ "Properties": {
2677
+ "Sortable": "Edm.Boolean"
2678
+ }
2679
+ },
2646
2680
  "Capabilities.SortRestrictionsType": {
2647
2681
  "$kind": "ComplexType",
2682
+ "BaseType": "Capabilities.SortRestrictionsBase",
2648
2683
  "Properties": {
2649
- "Sortable": "Edm.Boolean",
2650
2684
  "AscendingOnlyProperties": "Collection(Edm.PropertyPath)",
2651
2685
  "DescendingOnlyProperties": "Collection(Edm.PropertyPath)",
2652
- "NonSortableProperties": "Collection(Edm.PropertyPath)"
2686
+ "NonSortableProperties": "Collection(Edm.PropertyPath)",
2687
+ "Sortable": "Edm.Boolean"
2653
2688
  }
2654
2689
  },
2655
- "Capabilities.ExpandRestrictionsType": {
2690
+ "Capabilities.ExpandRestrictionsBase": {
2656
2691
  "$kind": "ComplexType",
2657
2692
  "Properties": {
2658
2693
  "Expandable": "Edm.Boolean",
2659
2694
  "StreamsExpandable": "Edm.Boolean",
2695
+ "MaxLevels": "Edm.Int32"
2696
+ }
2697
+ },
2698
+ "Capabilities.ExpandRestrictionsType": {
2699
+ "$kind": "ComplexType",
2700
+ "BaseType": "Capabilities.ExpandRestrictionsBase",
2701
+ "Properties": {
2660
2702
  "NonExpandableProperties": "Collection(Edm.NavigationPropertyPath)",
2661
2703
  "NonExpandableStreamProperties": "Collection(Edm.PropertyPath)",
2704
+ "Expandable": "Edm.Boolean",
2705
+ "StreamsExpandable": "Edm.Boolean",
2662
2706
  "MaxLevels": "Edm.Int32"
2663
2707
  }
2664
2708
  },
@@ -2669,16 +2713,31 @@
2669
2713
  "UnsupportedExpressions": "Capabilities.SearchExpressions"
2670
2714
  }
2671
2715
  },
2672
- "Capabilities.InsertRestrictionsType": {
2716
+ "Capabilities.InsertRestrictionsBase": {
2673
2717
  "$kind": "ComplexType",
2674
2718
  "Properties": {
2675
2719
  "Insertable": "Edm.Boolean",
2720
+ "MaxLevels": "Edm.Int32",
2721
+ "TypecastSegmentSupported": "Edm.Boolean",
2722
+ "QueryOptions": "Capabilities.ModificationQueryOptionsType",
2723
+ "CustomHeaders": "Collection(Capabilities.CustomParameter)",
2724
+ "CustomQueryOptions": "Collection(Capabilities.CustomParameter)",
2725
+ "Description": "Edm.String",
2726
+ "LongDescription": "Edm.String",
2727
+ "ErrorResponses": "Collection(Capabilities.HttpResponse)"
2728
+ }
2729
+ },
2730
+ "Capabilities.InsertRestrictionsType": {
2731
+ "$kind": "ComplexType",
2732
+ "BaseType": "Capabilities.InsertRestrictionsBase",
2733
+ "Properties": {
2676
2734
  "NonInsertableProperties": "Collection(Edm.PropertyPath)",
2677
2735
  "NonInsertableNavigationProperties": "Collection(Edm.NavigationPropertyPath)",
2678
2736
  "RequiredProperties": "Collection(Edm.PropertyPath)",
2737
+ "Permissions": "Collection(Capabilities.PermissionType)",
2738
+ "Insertable": "Edm.Boolean",
2679
2739
  "MaxLevels": "Edm.Int32",
2680
2740
  "TypecastSegmentSupported": "Edm.Boolean",
2681
- "Permissions": "Collection(Capabilities.PermissionType)",
2682
2741
  "QueryOptions": "Capabilities.ModificationQueryOptionsType",
2683
2742
  "CustomHeaders": "Collection(Capabilities.CustomParameter)",
2684
2743
  "CustomQueryOptions": "Collection(Capabilities.CustomParameter)",
@@ -2708,7 +2767,7 @@
2708
2767
  "ContentIDSupported": "Edm.Boolean"
2709
2768
  }
2710
2769
  },
2711
- "Capabilities.UpdateRestrictionsType": {
2770
+ "Capabilities.UpdateRestrictionsBase": {
2712
2771
  "$kind": "ComplexType",
2713
2772
  "Properties": {
2714
2773
  "Updatable": "Edm.Boolean",
@@ -2717,9 +2776,29 @@
2717
2776
  "UpdateMethod": "Capabilities.HttpMethod",
2718
2777
  "FilterSegmentSupported": "Edm.Boolean",
2719
2778
  "TypecastSegmentSupported": "Edm.Boolean",
2779
+ "MaxLevels": "Edm.Int32",
2780
+ "Permissions": "Collection(Capabilities.PermissionType)",
2781
+ "QueryOptions": "Capabilities.ModificationQueryOptionsType",
2782
+ "CustomHeaders": "Collection(Capabilities.CustomParameter)",
2783
+ "CustomQueryOptions": "Collection(Capabilities.CustomParameter)",
2784
+ "Description": "Edm.String",
2785
+ "LongDescription": "Edm.String",
2786
+ "ErrorResponses": "Collection(Capabilities.HttpResponse)"
2787
+ }
2788
+ },
2789
+ "Capabilities.UpdateRestrictionsType": {
2790
+ "$kind": "ComplexType",
2791
+ "BaseType": "Capabilities.UpdateRestrictionsBase",
2792
+ "Properties": {
2720
2793
  "NonUpdatableProperties": "Collection(Edm.PropertyPath)",
2721
2794
  "NonUpdatableNavigationProperties": "Collection(Edm.NavigationPropertyPath)",
2722
2795
  "RequiredProperties": "Collection(Edm.PropertyPath)",
2796
+ "Updatable": "Edm.Boolean",
2797
+ "Upsertable": "Edm.Boolean",
2798
+ "DeltaUpdateSupported": "Edm.Boolean",
2799
+ "UpdateMethod": "Capabilities.HttpMethod",
2800
+ "FilterSegmentSupported": "Edm.Boolean",
2801
+ "TypecastSegmentSupported": "Edm.Boolean",
2723
2802
  "MaxLevels": "Edm.Int32",
2724
2803
  "Permissions": "Collection(Capabilities.PermissionType)",
2725
2804
  "QueryOptions": "Capabilities.ModificationQueryOptionsType",
@@ -2737,11 +2816,27 @@
2737
2816
  "ContentIDSupported": "Edm.Boolean"
2738
2817
  }
2739
2818
  },
2740
- "Capabilities.DeleteRestrictionsType": {
2819
+ "Capabilities.DeleteRestrictionsBase": {
2741
2820
  "$kind": "ComplexType",
2742
2821
  "Properties": {
2743
2822
  "Deletable": "Edm.Boolean",
2823
+ "MaxLevels": "Edm.Int32",
2824
+ "FilterSegmentSupported": "Edm.Boolean",
2825
+ "TypecastSegmentSupported": "Edm.Boolean",
2826
+ "Permissions": "Collection(Capabilities.PermissionType)",
2827
+ "CustomHeaders": "Collection(Capabilities.CustomParameter)",
2828
+ "CustomQueryOptions": "Collection(Capabilities.CustomParameter)",
2829
+ "Description": "Edm.String",
2830
+ "LongDescription": "Edm.String",
2831
+ "ErrorResponses": "Collection(Capabilities.HttpResponse)"
2832
+ }
2833
+ },
2834
+ "Capabilities.DeleteRestrictionsType": {
2835
+ "$kind": "ComplexType",
2836
+ "BaseType": "Capabilities.DeleteRestrictionsBase",
2837
+ "Properties": {
2744
2838
  "NonDeletableNavigationProperties": "Collection(Edm.NavigationPropertyPath)",
2839
+ "Deletable": "Edm.Boolean",
2745
2840
  "MaxLevels": "Edm.Int32",
2746
2841
  "FilterSegmentSupported": "Edm.Boolean",
2747
2842
  "TypecastSegmentSupported": "Edm.Boolean",
@@ -2841,6 +2936,27 @@
2841
2936
  "ExampleValues": "Collection(Core.PrimitiveExampleValue)"
2842
2937
  }
2843
2938
  },
2939
+ "Capabilities.DefaultCapabilitiesType": {
2940
+ "$kind": "ComplexType",
2941
+ "Properties": {
2942
+ "ChangeTracking": "Capabilities.ChangeTrackingBase",
2943
+ "CountRestrictions": "Capabilities.CountRestrictionsBase",
2944
+ "IndexableByKey": "Core.Tag",
2945
+ "TopSupported": "Core.Tag",
2946
+ "SkipSupported": "Core.Tag",
2947
+ "ComputeSupported": "Core.Tag",
2948
+ "SelectSupport": "Capabilities.SelectSupportType",
2949
+ "FilterRestrictions": "Capabilities.FilterRestrictionsBase",
2950
+ "SortRestrictions": "Capabilities.SortRestrictionsBase",
2951
+ "ExpandRestrictions": "Capabilities.ExpandRestrictionsBase",
2952
+ "SearchRestrictions": "Capabilities.SearchRestrictionsType",
2953
+ "InsertRestrictions": "Capabilities.InsertRestrictionsBase",
2954
+ "UpdateRestrictions": "Capabilities.UpdateRestrictionsBase",
2955
+ "DeleteRestrictions": "Capabilities.DeleteRestrictionsBase",
2956
+ "OperationRestrictions": "Capabilities.OperationRestrictionsType",
2957
+ "ReadRestrictions": "Capabilities.ReadRestrictionsType"
2958
+ }
2959
+ },
2844
2960
  "Capabilities.HttpResponse": {
2845
2961
  "$kind": "ComplexType",
2846
2962
  "Properties": {
@@ -3030,6 +3146,15 @@
3030
3146
  "ValueListProperty": "Edm.String"
3031
3147
  }
3032
3148
  },
3149
+ "Common.ValueListParameterConstants": {
3150
+ "$kind": "ComplexType",
3151
+ "BaseType": "Common.ValueListParameter",
3152
+ "Properties": {
3153
+ "Constants": "Collection(Edm.PrimitiveType)",
3154
+ "ValueListProperty": "Edm.String"
3155
+ },
3156
+ "$experimental": true
3157
+ },
3033
3158
  "Common.ValueListParameterInOut": {
3034
3159
  "$kind": "ComplexType",
3035
3160
  "BaseType": "Common.ValueListParameter",
@@ -3093,7 +3218,6 @@
3093
3218
  "TargetEntities": "Collection(Edm.NavigationPropertyPath)",
3094
3219
  "EffectTypes": "Common.EffectType",
3095
3220
  "TriggerAction": "Common.QualifiedName",
3096
- "TriggeredIndicator": "Edm.Boolean",
3097
3221
  "Discretionary": "Edm.Boolean"
3098
3222
  }
3099
3223
  },
@@ -1 +1 @@
1
- 37b3697769a5035b6409cd959ebdf610
1
+ 0c76b255e5fe55c0f8527a4d9f1b563f