File tree 2 files changed +14
-0
lines changed
gooddata-sdk/gooddata_sdk
2 files changed +14
-0
lines changed Original file line number Diff line number Diff line change 240
240
)
241
241
from gooddata_sdk .compute .model .metric import (
242
242
ArithmeticMetric ,
243
+ InlineMetric ,
243
244
Metric ,
244
245
PopDate ,
245
246
PopDateDataset ,
Original file line number Diff line number Diff line change @@ -267,3 +267,16 @@ def _body_as_api_model(self) -> afm_models.ArithmeticMeasureDefinition:
267
267
operator = self .operator , measure_identifiers = measure_identifiers
268
268
)
269
269
)
270
+
271
+
272
+ class InlineMetric (Metric ):
273
+ def __init__ (self , maql : str , local_id : str ) -> None :
274
+ super ().__init__ (local_id )
275
+ self ._maql = maql
276
+
277
+ @property
278
+ def maql (self ) -> str :
279
+ return self ._maql
280
+
281
+ def _body_as_api_model (self ) -> afm_models .InlineMeasureDefinition :
282
+ return afm_models .InlineMeasureDefinition (inline = afm_models .InlineMeasureDefinitionInline (maql = self .maql ))
You can’t perform that action at this time.
0 commit comments