Class: AWSCDK::QuickSight::CfnTopic::TopicCalculatedFieldProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
quick_sight/cfn_topic.rb

Overview

A structure that represents a calculated field.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(calculated_field_name:, expression:, aggregation: nil, allowed_aggregations: nil, calculated_field_description: nil, calculated_field_synonyms: nil, cell_value_synonyms: nil, column_data_role: nil, comparative_order: nil, default_formatting: nil, disable_indexing: nil, is_included_in_topic: nil, never_aggregate_in_filter: nil, non_additive: nil, not_allowed_aggregations: nil, semantic_type: nil, time_granularity: nil) ⇒ TopicCalculatedFieldProperty

Returns a new instance of TopicCalculatedFieldProperty.

Parameters:

  • calculated_field_name (String)

    The calculated field name.

  • expression (String)

    The calculated field expression.

  • aggregation (String, nil) (defaults to: nil)

    The default aggregation.

  • allowed_aggregations (Array<String>, nil) (defaults to: nil)

    The list of aggregation types that are allowed for the calculated field.

  • calculated_field_description (String, nil) (defaults to: nil)

    The calculated field description.

  • calculated_field_synonyms (Array<String>, nil) (defaults to: nil)

    The other names or aliases for the calculated field.

  • cell_value_synonyms (AWSCDK::IResolvable, Array<AWSCDK::IResolvable, AWSCDK::QuickSight::CfnTopic::CellValueSynonymProperty>, nil) (defaults to: nil)

    The other names or aliases for the calculated field cell value.

  • column_data_role (String, nil) (defaults to: nil)

    The column data role for a calculated field.

  • comparative_order (AWSCDK::IResolvable, AWSCDK::QuickSight::CfnTopic::ComparativeOrderProperty, nil) (defaults to: nil)

    The order in which data is displayed for the calculated field when it's used in a comparative context.

  • default_formatting (AWSCDK::IResolvable, AWSCDK::QuickSight::CfnTopic::DefaultFormattingProperty, nil) (defaults to: nil)

    The default formatting definition.

  • disable_indexing (Boolean, AWSCDK::IResolvable, nil) (defaults to: nil)

    A Boolean value that indicates if a calculated field is visible in the autocomplete.

  • is_included_in_topic (Boolean, AWSCDK::IResolvable, nil) (defaults to: nil)

    A boolean value that indicates if a calculated field is included in the topic.

  • never_aggregate_in_filter (Boolean, AWSCDK::IResolvable, nil) (defaults to: nil)

    A Boolean value that indicates whether to never aggregate calculated field in filters.

  • non_additive (Boolean, AWSCDK::IResolvable, nil) (defaults to: nil)

    The non additive for the table style target.

  • not_allowed_aggregations (Array<String>, nil) (defaults to: nil)

    The list of aggregation types that are not allowed for the calculated field.

  • semantic_type (AWSCDK::IResolvable, AWSCDK::QuickSight::CfnTopic::SemanticTypeProperty, nil) (defaults to: nil)

    The semantic type.

  • time_granularity (String, nil) (defaults to: nil)

    The level of time precision that is used to aggregate DateTime values.



1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
# File 'quick_sight/cfn_topic.rb', line 1501

def initialize(calculated_field_name:, expression:, aggregation: nil, allowed_aggregations: nil, calculated_field_description: nil, calculated_field_synonyms: nil, cell_value_synonyms: nil, column_data_role: nil, comparative_order: nil, default_formatting: nil, disable_indexing: nil, is_included_in_topic: nil, never_aggregate_in_filter: nil, non_additive: nil, not_allowed_aggregations: nil, semantic_type: nil, time_granularity: nil)
  @calculated_field_name = calculated_field_name
  Jsii::Type.check_type(@calculated_field_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "calculatedFieldName")
  @expression = expression
  Jsii::Type.check_type(@expression, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "expression")
  @aggregation = aggregation
  Jsii::Type.check_type(@aggregation, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "aggregation") unless @aggregation.nil?
  @allowed_aggregations = allowed_aggregations
  Jsii::Type.check_type(@allowed_aggregations, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "allowedAggregations") unless @allowed_aggregations.nil?
  @calculated_field_description = calculated_field_description
  Jsii::Type.check_type(@calculated_field_description, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "calculatedFieldDescription") unless @calculated_field_description.nil?
  @calculated_field_synonyms = calculated_field_synonyms
  Jsii::Type.check_type(@calculated_field_synonyms, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "calculatedFieldSynonyms") unless @calculated_field_synonyms.nil?
  @cell_value_synonyms = cell_value_synonyms
  Jsii::Type.check_type(@cell_value_synonyms, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfcXVpY2tzaWdodC5DZm5Ub3BpYy5DZWxsVmFsdWVTeW5vbnltUHJvcGVydHkifV19fSwia2luZCI6ImFycmF5In19XX19")), "cellValueSynonyms") unless @cell_value_synonyms.nil?
  @column_data_role = column_data_role
  Jsii::Type.check_type(@column_data_role, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "columnDataRole") unless @column_data_role.nil?
  @comparative_order = comparative_order.is_a?(Hash) ? ::AWSCDK::QuickSight::CfnTopic::ComparativeOrderProperty.new(**comparative_order.transform_keys(&:to_sym)) : comparative_order
  Jsii::Type.check_type(@comparative_order, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19xdWlja3NpZ2h0LkNmblRvcGljLkNvbXBhcmF0aXZlT3JkZXJQcm9wZXJ0eSJ9XX19")), "comparativeOrder") unless @comparative_order.nil?
  @default_formatting = default_formatting.is_a?(Hash) ? ::AWSCDK::QuickSight::CfnTopic::DefaultFormattingProperty.new(**default_formatting.transform_keys(&:to_sym)) : default_formatting
  Jsii::Type.check_type(@default_formatting, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19xdWlja3NpZ2h0LkNmblRvcGljLkRlZmF1bHRGb3JtYXR0aW5nUHJvcGVydHkifV19fQ==")), "defaultFormatting") unless @default_formatting.nil?
  @disable_indexing = disable_indexing
  Jsii::Type.check_type(@disable_indexing, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "disableIndexing") unless @disable_indexing.nil?
  @is_included_in_topic = is_included_in_topic
  Jsii::Type.check_type(@is_included_in_topic, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "isIncludedInTopic") unless @is_included_in_topic.nil?
  @never_aggregate_in_filter = never_aggregate_in_filter
  Jsii::Type.check_type(@never_aggregate_in_filter, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "neverAggregateInFilter") unless @never_aggregate_in_filter.nil?
  @non_additive = non_additive
  Jsii::Type.check_type(@non_additive, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "nonAdditive") unless @non_additive.nil?
  @not_allowed_aggregations = not_allowed_aggregations
  Jsii::Type.check_type(@not_allowed_aggregations, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "notAllowedAggregations") unless @not_allowed_aggregations.nil?
  @semantic_type = semantic_type.is_a?(Hash) ? ::AWSCDK::QuickSight::CfnTopic::SemanticTypeProperty.new(**semantic_type.transform_keys(&:to_sym)) : semantic_type
  Jsii::Type.check_type(@semantic_type, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19xdWlja3NpZ2h0LkNmblRvcGljLlNlbWFudGljVHlwZVByb3BlcnR5In1dfX0=")), "semanticType") unless @semantic_type.nil?
  @time_granularity = time_granularity
  Jsii::Type.check_type(@time_granularity, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "timeGranularity") unless @time_granularity.nil?
end

Instance Attribute Details

#aggregationString? (readonly)

The default aggregation.

Valid values for this structure are SUM , MAX , MIN , COUNT , DISTINCT_COUNT , and AVERAGE .



1554
1555
1556
# File 'quick_sight/cfn_topic.rb', line 1554

def aggregation
  @aggregation
end

#allowed_aggregationsArray<String>? (readonly)

The list of aggregation types that are allowed for the calculated field.

Valid values for this structure are COUNT , DISTINCT_COUNT , MIN , MAX , MEDIAN , SUM , AVERAGE , STDEV , STDEVP , VAR , VARP , and PERCENTILE .



1561
1562
1563
# File 'quick_sight/cfn_topic.rb', line 1561

def allowed_aggregations
  @allowed_aggregations
end

#calculated_field_descriptionString? (readonly)

The calculated field description.



1566
1567
1568
# File 'quick_sight/cfn_topic.rb', line 1566

def calculated_field_description
  @calculated_field_description
end

#calculated_field_nameString (readonly)

The calculated field name.



1542
1543
1544
# File 'quick_sight/cfn_topic.rb', line 1542

def calculated_field_name
  @calculated_field_name
end

#calculated_field_synonymsArray<String>? (readonly)

The other names or aliases for the calculated field.



1571
1572
1573
# File 'quick_sight/cfn_topic.rb', line 1571

def calculated_field_synonyms
  @calculated_field_synonyms
end

#cell_value_synonymsAWSCDK::IResolvable, ... (readonly)

The other names or aliases for the calculated field cell value.



1576
1577
1578
# File 'quick_sight/cfn_topic.rb', line 1576

def cell_value_synonyms
  @cell_value_synonyms
end

#column_data_roleString? (readonly)

The column data role for a calculated field.

Valid values for this structure are DIMENSION and MEASURE .



1583
1584
1585
# File 'quick_sight/cfn_topic.rb', line 1583

def column_data_role
  @column_data_role
end

#comparative_orderAWSCDK::IResolvable, ... (readonly)

The order in which data is displayed for the calculated field when it's used in a comparative context.



1588
1589
1590
# File 'quick_sight/cfn_topic.rb', line 1588

def comparative_order
  @comparative_order
end

#default_formattingAWSCDK::IResolvable, ... (readonly)

The default formatting definition.



1593
1594
1595
# File 'quick_sight/cfn_topic.rb', line 1593

def default_formatting
  @default_formatting
end

#disable_indexingBoolean, ... (readonly)

A Boolean value that indicates if a calculated field is visible in the autocomplete.



1598
1599
1600
# File 'quick_sight/cfn_topic.rb', line 1598

def disable_indexing
  @disable_indexing
end

#expressionString (readonly)

The calculated field expression.



1547
1548
1549
# File 'quick_sight/cfn_topic.rb', line 1547

def expression
  @expression
end

#is_included_in_topicBoolean, ... (readonly)

Note:

Default: - false

A boolean value that indicates if a calculated field is included in the topic.



1604
1605
1606
# File 'quick_sight/cfn_topic.rb', line 1604

def is_included_in_topic
  @is_included_in_topic
end

#never_aggregate_in_filterBoolean, ... (readonly)

Note:

Default: - false

A Boolean value that indicates whether to never aggregate calculated field in filters.



1610
1611
1612
# File 'quick_sight/cfn_topic.rb', line 1610

def never_aggregate_in_filter
  @never_aggregate_in_filter
end

#non_additiveBoolean, ... (readonly)

Note:

Default: - false

The non additive for the table style target.



1616
1617
1618
# File 'quick_sight/cfn_topic.rb', line 1616

def non_additive
  @non_additive
end

#not_allowed_aggregationsArray<String>? (readonly)

The list of aggregation types that are not allowed for the calculated field.

Valid values for this structure are COUNT , DISTINCT_COUNT , MIN , MAX , MEDIAN , SUM , AVERAGE , STDEV , STDEVP , VAR , VARP , and PERCENTILE .



1623
1624
1625
# File 'quick_sight/cfn_topic.rb', line 1623

def not_allowed_aggregations
  @not_allowed_aggregations
end

#semantic_typeAWSCDK::IResolvable, ... (readonly)

The semantic type.



1628
1629
1630
# File 'quick_sight/cfn_topic.rb', line 1628

def semantic_type
  @semantic_type
end

#time_granularityString? (readonly)

The level of time precision that is used to aggregate DateTime values.



1633
1634
1635
# File 'quick_sight/cfn_topic.rb', line 1633

def time_granularity
  @time_granularity
end

Class Method Details

.jsii_propertiesObject



1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
# File 'quick_sight/cfn_topic.rb', line 1635

def self.jsii_properties
  {
    :calculated_field_name => "calculatedFieldName",
    :expression => "expression",
    :aggregation => "aggregation",
    :allowed_aggregations => "allowedAggregations",
    :calculated_field_description => "calculatedFieldDescription",
    :calculated_field_synonyms => "calculatedFieldSynonyms",
    :cell_value_synonyms => "cellValueSynonyms",
    :column_data_role => "columnDataRole",
    :comparative_order => "comparativeOrder",
    :default_formatting => "defaultFormatting",
    :disable_indexing => "disableIndexing",
    :is_included_in_topic => "isIncludedInTopic",
    :never_aggregate_in_filter => "neverAggregateInFilter",
    :non_additive => "nonAdditive",
    :not_allowed_aggregations => "notAllowedAggregations",
    :semantic_type => "semanticType",
    :time_granularity => "timeGranularity",
  }
end

Instance Method Details

#to_jsiiObject



1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
# File 'quick_sight/cfn_topic.rb', line 1657

def to_jsii
  result = {}
  result.merge!({
    "calculatedFieldName" => @calculated_field_name,
    "expression" => @expression,
    "aggregation" => @aggregation,
    "allowedAggregations" => @allowed_aggregations,
    "calculatedFieldDescription" => @calculated_field_description,
    "calculatedFieldSynonyms" => @calculated_field_synonyms,
    "cellValueSynonyms" => @cell_value_synonyms,
    "columnDataRole" => @column_data_role,
    "comparativeOrder" => @comparative_order,
    "defaultFormatting" => @default_formatting,
    "disableIndexing" => @disable_indexing,
    "isIncludedInTopic" => @is_included_in_topic,
    "neverAggregateInFilter" => @never_aggregate_in_filter,
    "nonAdditive" => @non_additive,
    "notAllowedAggregations" => @not_allowed_aggregations,
    "semanticType" => @semantic_type,
    "timeGranularity" => @time_granularity,
  })
  result.compact
end