Class: AWSCDK::AmplifyUIBuilder::CfnComponent::PredicateProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
amplify_ui_builder/cfn_component.rb

Overview

The Predicate property specifies information for generating Amplify DataStore queries.

Use Predicate to retrieve a subset of the data in a collection.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(_and: nil, field: nil, operand: nil, operand_type: nil, operator: nil, _or: nil) ⇒ PredicateProperty

Returns a new instance of PredicateProperty.

Parameters:

  • _and (AWSCDK::IResolvable, Array<AWSCDK::IResolvable, AWSCDK::AmplifyUIBuilder::CfnComponent::PredicateProperty>, nil) (defaults to: nil)

    A list of predicates to combine logically.

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

    The field to query.

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

    The value to use when performing the evaluation.

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

    The type of value to use when performing the evaluation.

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

    The operator to use to perform the evaluation.

  • _or (AWSCDK::IResolvable, Array<AWSCDK::IResolvable, AWSCDK::AmplifyUIBuilder::CfnComponent::PredicateProperty>, nil) (defaults to: nil)

    A list of predicates to combine logically.



1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
# File 'amplify_ui_builder/cfn_component.rb', line 1663

def initialize(_and: nil, field: nil, operand: nil, operand_type: nil, operator: nil, _or: nil)
  @_and = _and
  Jsii::Type.check_type(@_and, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYW1wbGlmeXVpYnVpbGRlci5DZm5Db21wb25lbnQuUHJlZGljYXRlUHJvcGVydHkifV19fSwia2luZCI6ImFycmF5In19XX19")), "and") unless @_and.nil?
  @field = field
  Jsii::Type.check_type(@field, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "field") unless @field.nil?
  @operand = operand
  Jsii::Type.check_type(@operand, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "operand") unless @operand.nil?
  @operand_type = operand_type
  Jsii::Type.check_type(@operand_type, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "operandType") unless @operand_type.nil?
  @operator = operator
  Jsii::Type.check_type(@operator, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "operator") unless @operator.nil?
  @_or = _or
  Jsii::Type.check_type(@_or, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYW1wbGlmeXVpYnVpbGRlci5DZm5Db21wb25lbnQuUHJlZGljYXRlUHJvcGVydHkifV19fSwia2luZCI6ImFycmF5In19XX19")), "or") unless @_or.nil?
end

Instance Attribute Details

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

A list of predicates to combine logically.



1682
1683
1684
# File 'amplify_ui_builder/cfn_component.rb', line 1682

def _and
  @_and
end

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

A list of predicates to combine logically.



1707
1708
1709
# File 'amplify_ui_builder/cfn_component.rb', line 1707

def _or
  @_or
end

#fieldString? (readonly)

The field to query.



1687
1688
1689
# File 'amplify_ui_builder/cfn_component.rb', line 1687

def field
  @field
end

#operandString? (readonly)

The value to use when performing the evaluation.



1692
1693
1694
# File 'amplify_ui_builder/cfn_component.rb', line 1692

def operand
  @operand
end

#operand_typeString? (readonly)

The type of value to use when performing the evaluation.



1697
1698
1699
# File 'amplify_ui_builder/cfn_component.rb', line 1697

def operand_type
  @operand_type
end

#operatorString? (readonly)

The operator to use to perform the evaluation.



1702
1703
1704
# File 'amplify_ui_builder/cfn_component.rb', line 1702

def operator
  @operator
end

Class Method Details

.jsii_propertiesObject



1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
# File 'amplify_ui_builder/cfn_component.rb', line 1709

def self.jsii_properties
  {
    :_and => "and",
    :field => "field",
    :operand => "operand",
    :operand_type => "operandType",
    :operator => "operator",
    :_or => "or",
  }
end

Instance Method Details

#to_jsiiObject



1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
# File 'amplify_ui_builder/cfn_component.rb', line 1720

def to_jsii
  result = {}
  result.merge!({
    "and" => @_and,
    "field" => @field,
    "operand" => @operand,
    "operandType" => @operand_type,
    "operator" => @operator,
    "or" => @_or,
  })
  result.compact
end