Class: AWSCDK::QuickSight::CfnAnalysis::PeriodToDateComputationProperty

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

Overview

The period to date computation configuration.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(computation_id:, name: nil, period_time_granularity: nil, time: nil, value: nil) ⇒ PeriodToDateComputationProperty

Returns a new instance of PeriodToDateComputationProperty.

Parameters:



21074
21075
21076
21077
21078
21079
21080
21081
21082
21083
21084
21085
# File 'quick_sight/cfn_analysis.rb', line 21074

def initialize(computation_id:, name: nil, period_time_granularity: nil, time: nil, value: nil)
  @computation_id = computation_id
  Jsii::Type.check_type(@computation_id, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "computationId")
  @name = name
  Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name") unless @name.nil?
  @period_time_granularity = period_time_granularity
  Jsii::Type.check_type(@period_time_granularity, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "periodTimeGranularity") unless @period_time_granularity.nil?
  @time = time.is_a?(Hash) ? ::AWSCDK::QuickSight::CfnAnalysis::DimensionFieldProperty.new(**time.transform_keys(&:to_sym)) : time
  Jsii::Type.check_type(@time, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19xdWlja3NpZ2h0LkNmbkFuYWx5c2lzLkRpbWVuc2lvbkZpZWxkUHJvcGVydHkifV19fQ==")), "time") unless @time.nil?
  @value = value.is_a?(Hash) ? ::AWSCDK::QuickSight::CfnAnalysis::MeasureFieldProperty.new(**value.transform_keys(&:to_sym)) : value
  Jsii::Type.check_type(@value, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19xdWlja3NpZ2h0LkNmbkFuYWx5c2lzLk1lYXN1cmVGaWVsZFByb3BlcnR5In1dfX0=")), "value") unless @value.nil?
end

Instance Attribute Details

#computation_idString (readonly)

The ID for a computation.



21091
21092
21093
# File 'quick_sight/cfn_analysis.rb', line 21091

def computation_id
  @computation_id
end

#nameString? (readonly)

The name of a computation.



21096
21097
21098
# File 'quick_sight/cfn_analysis.rb', line 21096

def name
  @name
end

#period_time_granularityString? (readonly)

The time granularity setup of period to date computation. Choose from the following options:.

  • YEAR: Year to date.
  • MONTH: Month to date.


21104
21105
21106
# File 'quick_sight/cfn_analysis.rb', line 21104

def period_time_granularity
  @period_time_granularity
end

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

The time field that is used in a computation.



21109
21110
21111
# File 'quick_sight/cfn_analysis.rb', line 21109

def time
  @time
end

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

The value field that is used in a computation.



21114
21115
21116
# File 'quick_sight/cfn_analysis.rb', line 21114

def value
  @value
end

Class Method Details

.jsii_propertiesObject



21116
21117
21118
21119
21120
21121
21122
21123
21124
# File 'quick_sight/cfn_analysis.rb', line 21116

def self.jsii_properties
  {
    :computation_id => "computationId",
    :name => "name",
    :period_time_granularity => "periodTimeGranularity",
    :time => "time",
    :value => "value",
  }
end

Instance Method Details

#to_jsiiObject



21126
21127
21128
21129
21130
21131
21132
21133
21134
21135
21136
# File 'quick_sight/cfn_analysis.rb', line 21126

def to_jsii
  result = {}
  result.merge!({
    "computationId" => @computation_id,
    "name" => @name,
    "periodTimeGranularity" => @period_time_granularity,
    "time" => @time,
    "value" => @value,
  })
  result.compact
end