Class: AWSCDK::IoTSiteWise::CfnAssetModel::AssetModelCompositeModelProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
io_t_site_wise/cfn_asset_model.rb

Overview

Contains information about a composite model in an asset model.

This object contains the asset property definitions that you define in the composite model.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name:, type:, composed_asset_model_id: nil, composite_model_properties: nil, description: nil, external_id: nil, id: nil, parent_asset_model_composite_model_external_id: nil, path: nil) ⇒ AssetModelCompositeModelProperty

Returns a new instance of AssetModelCompositeModelProperty.

Parameters:

  • name (String)

    The name of the composite model.

  • type (String)

    The type of the composite model.

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

    The ID of a component model which is reused to create this composite model.

  • composite_model_properties (AWSCDK::IResolvable, Array<AWSCDK::IResolvable, AWSCDK::IoTSiteWise::CfnAssetModel::AssetModelPropertyProperty>, nil) (defaults to: nil)

    The asset property definitions for this composite model.

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

    The description of the composite model.

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

    The external ID of a composite model on this asset model.

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

    The ID of the asset model composite model.

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

    The external ID of the parent composite model.

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

    The structured path to the property from the root of the asset using property names.



673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
# File 'io_t_site_wise/cfn_asset_model.rb', line 673

def initialize(name:, type:, composed_asset_model_id: nil, composite_model_properties: nil, description: nil, external_id: nil, id: nil, parent_asset_model_composite_model_external_id: nil, path: nil)
  @name = name
  Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name")
  @type = type
  Jsii::Type.check_type(@type, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "type")
  @composed_asset_model_id = composed_asset_model_id
  Jsii::Type.check_type(@composed_asset_model_id, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "composedAssetModelId") unless @composed_asset_model_id.nil?
  @composite_model_properties = composite_model_properties
  Jsii::Type.check_type(@composite_model_properties, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfaW90c2l0ZXdpc2UuQ2ZuQXNzZXRNb2RlbC5Bc3NldE1vZGVsUHJvcGVydHlQcm9wZXJ0eSJ9XX19LCJraW5kIjoiYXJyYXkifX1dfX0=")), "compositeModelProperties") unless @composite_model_properties.nil?
  @description = description
  Jsii::Type.check_type(@description, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "description") unless @description.nil?
  @external_id = external_id
  Jsii::Type.check_type(@external_id, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "externalId") unless @external_id.nil?
  @id = id
  Jsii::Type.check_type(@id, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "id") unless @id.nil?
  @parent_asset_model_composite_model_external_id = parent_asset_model_composite_model_external_id
  Jsii::Type.check_type(@parent_asset_model_composite_model_external_id, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "parentAssetModelCompositeModelExternalId") unless @parent_asset_model_composite_model_external_id.nil?
  @path = path
  Jsii::Type.check_type(@path, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "path") unless @path.nil?
end

Instance Attribute Details

#composed_asset_model_idString? (readonly)

The ID of a component model which is reused to create this composite model.



710
711
712
# File 'io_t_site_wise/cfn_asset_model.rb', line 710

def composed_asset_model_id
  @composed_asset_model_id
end

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

The asset property definitions for this composite model.



715
716
717
# File 'io_t_site_wise/cfn_asset_model.rb', line 715

def composite_model_properties
  @composite_model_properties
end

#descriptionString? (readonly)

The description of the composite model.

If the composite model is a component-model-based composite model, the description is inherited from the COMPONENT_MODEL asset model and cannot be changed.



722
723
724
# File 'io_t_site_wise/cfn_asset_model.rb', line 722

def description
  @description
end

#external_idString? (readonly)

The external ID of a composite model on this asset model.

For more information, see Using external IDs in the AWS IoT SiteWise User Guide .

One of ExternalId or Path must be specified.



731
732
733
# File 'io_t_site_wise/cfn_asset_model.rb', line 731

def external_id
  @external_id
end

#idString? (readonly)

The ID of the asset model composite model.

This is a return value and can't be set.



738
739
740
# File 'io_t_site_wise/cfn_asset_model.rb', line 738

def id
  @id
end

#nameString (readonly)

The name of the composite model.



698
699
700
# File 'io_t_site_wise/cfn_asset_model.rb', line 698

def name
  @name
end

#parent_asset_model_composite_model_external_idString? (readonly)

The external ID of the parent composite model.

For more information, see Using external IDs in the AWS IoT SiteWise User Guide .



745
746
747
# File 'io_t_site_wise/cfn_asset_model.rb', line 745

def parent_asset_model_composite_model_external_id
  @parent_asset_model_composite_model_external_id
end

#pathArray<String>? (readonly)

The structured path to the property from the root of the asset using property names.

Path is used as the ID if the asset model is a derived composite model.

One of ExternalId or Path must be specified.



754
755
756
# File 'io_t_site_wise/cfn_asset_model.rb', line 754

def path
  @path
end

#typeString (readonly)

The type of the composite model.

For alarm composite models, this type is AWS/ALARM .



705
706
707
# File 'io_t_site_wise/cfn_asset_model.rb', line 705

def type
  @type
end

Class Method Details

.jsii_propertiesObject



756
757
758
759
760
761
762
763
764
765
766
767
768
# File 'io_t_site_wise/cfn_asset_model.rb', line 756

def self.jsii_properties
  {
    :name => "name",
    :type => "type",
    :composed_asset_model_id => "composedAssetModelId",
    :composite_model_properties => "compositeModelProperties",
    :description => "description",
    :external_id => "externalId",
    :id => "id",
    :parent_asset_model_composite_model_external_id => "parentAssetModelCompositeModelExternalId",
    :path => "path",
  }
end

Instance Method Details

#to_jsiiObject



770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
# File 'io_t_site_wise/cfn_asset_model.rb', line 770

def to_jsii
  result = {}
  result.merge!({
    "name" => @name,
    "type" => @type,
    "composedAssetModelId" => @composed_asset_model_id,
    "compositeModelProperties" => @composite_model_properties,
    "description" => @description,
    "externalId" => @external_id,
    "id" => @id,
    "parentAssetModelCompositeModelExternalId" => @parent_asset_model_composite_model_external_id,
    "path" => @path,
  })
  result.compact
end