Class: AWSCDK::DataBrew::CfnDataset::DatetimeOptionsProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
data_brew/cfn_dataset.rb

Overview

Represents additional options for correct interpretation of datetime parameters used in the Amazon S3 path of a dataset.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(format:, locale_code: nil, timezone_offset: nil) ⇒ DatetimeOptionsProperty

Returns a new instance of DatetimeOptionsProperty.

Parameters:

  • format (String)

    Required option, that defines the datetime format used for a date parameter in the Amazon S3 path.

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

    Optional value for a non-US locale code, needed for correct interpretation of some date formats.

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

    Optional value for a timezone offset of the datetime parameter value in the Amazon S3 path.



835
836
837
838
839
840
841
842
# File 'data_brew/cfn_dataset.rb', line 835

def initialize(format:, locale_code: nil, timezone_offset: nil)
  @format = format
  Jsii::Type.check_type(@format, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "format")
  @locale_code = locale_code
  Jsii::Type.check_type(@locale_code, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "localeCode") unless @locale_code.nil?
  @timezone_offset = timezone_offset
  Jsii::Type.check_type(@timezone_offset, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "timezoneOffset") unless @timezone_offset.nil?
end

Instance Attribute Details

#formatString (readonly)

Required option, that defines the datetime format used for a date parameter in the Amazon S3 path.

Should use only supported datetime specifiers and separation characters, all litera a-z or A-Z character should be escaped with single quotes. E.g. "MM.dd.yyyy-'at'-HH:mm".



850
851
852
# File 'data_brew/cfn_dataset.rb', line 850

def format
  @format
end

#locale_codeString? (readonly)

Optional value for a non-US locale code, needed for correct interpretation of some date formats.



855
856
857
# File 'data_brew/cfn_dataset.rb', line 855

def locale_code
  @locale_code
end

#timezone_offsetString? (readonly)

Optional value for a timezone offset of the datetime parameter value in the Amazon S3 path.

Shouldn't be used if Format for this parameter includes timezone fields. If no offset specified, UTC is assumed.



862
863
864
# File 'data_brew/cfn_dataset.rb', line 862

def timezone_offset
  @timezone_offset
end

Class Method Details

.jsii_propertiesObject



864
865
866
867
868
869
870
# File 'data_brew/cfn_dataset.rb', line 864

def self.jsii_properties
  {
    :format => "format",
    :locale_code => "localeCode",
    :timezone_offset => "timezoneOffset",
  }
end

Instance Method Details

#to_jsiiObject



872
873
874
875
876
877
878
879
880
# File 'data_brew/cfn_dataset.rb', line 872

def to_jsii
  result = {}
  result.merge!({
    "format" => @format,
    "localeCode" => @locale_code,
    "timezoneOffset" => @timezone_offset,
  })
  result.compact
end