File tree Expand file tree Collapse file tree 2 files changed +28
-0
lines changed
src/Microsoft.OpenApi/Expressions Expand file tree Collapse file tree 2 files changed +28
-0
lines changed Original file line number Diff line number Diff line change
1
+ using System ;
2
+ using System . Collections . Generic ;
3
+ using System . Linq ;
4
+ using System . Text ;
5
+ using System . Threading . Tasks ;
6
+
7
+ namespace Microsoft . OpenApi . Expressions
8
+ {
9
+ public class CompositeExpression : RuntimeExpression
10
+ {
11
+ private string template ;
12
+
13
+ public CompositeExpression ( string expression )
14
+ {
15
+ template = expression ;
16
+
17
+ // Extract subexpressions and convert to RuntimeExpressions
18
+
19
+ }
20
+
21
+ public override string Expression => template ;
22
+ }
23
+ }
Original file line number Diff line number Diff line change @@ -34,6 +34,11 @@ public static RuntimeExpression Build(string expression)
34
34
throw Error . ArgumentNullOrWhiteSpace ( nameof ( expression ) ) ;
35
35
}
36
36
37
+ if ( expression . Contains ( "{$" ) )
38
+ {
39
+ return new CompositeExpression ( expression ) ;
40
+ }
41
+
37
42
if ( ! expression . StartsWith ( Prefix ) )
38
43
{
39
44
throw new OpenApiException ( string . Format ( SRResource . RuntimeExpressionMustBeginWithDollar , expression ) ) ;
You can’t perform that action at this time.
0 commit comments