Class BlockInstanceConfig
- java.lang.Object
-
- com.tibco.ep.tcs.runtime.config.BaseConfig
-
- com.tibco.ep.tcs.runtime.config.BlockInstanceConfig
-
public class BlockInstanceConfig extends BaseConfig
Configuration describing a block instance in a flow. Instances can contain inline meta-data or point to a block type via block type ID. Inline meta-data is exclusive with a referenced block type ID.
-
-
Constructor Summary
Constructors Constructor Description BlockInstanceConfig()
Create a new empty block instance object.BlockInstanceConfig(IBlockInstance source)
Create a new block instance from the specified interface source.BlockInstanceConfig(com.typesafe.config.Config config)
Create a new block instance from HOCON configuration.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected void
fillMap(Map<String,Object> props)
Add this object's properties to the specified map.String
getBlockID()
Return this block instance's referenced block identifier; that is, the block of which this object is an instance.BlockMetaDataConfig
getBlockMetaData()
For inline block definitions, return the block metadata that would otherwise appear in the referenced block project, null if none.String
getConfiguration()
Deprecated.Use #getConfigString
getDescription()
Return the block instance's human-readable description, null if none.com.typesafe.config.Config
getInstanceConfig()
Return this block instance's configuration, null if none.String
getLabel()
Return the block instance's human-readable label, null if none.BlockInstanceConfig
setBlockID(String blockID)
Set the identifier of the project of which this is block an instance, expressed as the project's Maven coordinate in standard Maven group ID:artifact ID:version format.BlockInstanceConfig
setBlockMetaData(BlockMetaDataConfig blockMetaData)
For inline block definitions, set the block metadata that would otherwise appear in the referenced block project, null if none.BlockInstanceConfig
setConfiguration(String configuration)
Deprecated.Use #setConfigBlockInstanceConfig
setDescription(String description)
Set the block instance's human-readable description, null if none.BlockInstanceConfig
setInstanceConfig(com.typesafe.config.Config instanceConfig)
Set this block instance's configuration, null if none.BlockInstanceConfig
setLabel(String label)
Set the block instance's human-readable label, null if none.-
Methods inherited from class com.tibco.ep.tcs.runtime.config.BaseConfig
toHOCON
-
-
-
-
Constructor Detail
-
BlockInstanceConfig
public BlockInstanceConfig()
Create a new empty block instance object.
-
BlockInstanceConfig
public BlockInstanceConfig(IBlockInstance source)
Create a new block instance from the specified interface source.
- Parameters:
source
- source block instance
-
BlockInstanceConfig
public BlockInstanceConfig(com.typesafe.config.Config config)
Create a new block instance from HOCON configuration.
- Parameters:
config
- HOCON representation of the block instance
-
-
Method Detail
-
getBlockID
public String getBlockID()
Return this block instance's referenced block identifier; that is, the block of which this object is an instance. This value is null if the block instance uses inline block metadata and non-null if it does not.
- Returns:
- block ID, null if an inline block
-
setBlockID
public BlockInstanceConfig setBlockID(String blockID)
Set the identifier of the project of which this is block an instance, expressed as the project's Maven coordinate in standard Maven group ID:artifact ID:version format. Use a value of null if the block instance uses inline block metadata and non-null if it does not.
- Parameters:
blockID
- block ID, null if an inline block- Returns:
- this object
-
getLabel
public String getLabel()
Return the block instance's human-readable label, null if none.
- Returns:
- label, null if none
-
setLabel
public BlockInstanceConfig setLabel(String label)
Set the block instance's human-readable label, null if none.
- Parameters:
label
- label, null if none- Returns:
- this object
-
getDescription
public String getDescription()
Return the block instance's human-readable description, null if none.
- Returns:
- description, null if none
-
setDescription
public BlockInstanceConfig setDescription(String description)
Set the block instance's human-readable description, null if none.
- Parameters:
description
- description, null if none- Returns:
- this object
-
getConfiguration
@Deprecated public String getConfiguration()
Deprecated.Use #getConfigReturn this block instance's HOCON configuration in string form, null if none.
- Returns:
- HOCON configuration, null if none
-
setConfiguration
@Deprecated public BlockInstanceConfig setConfiguration(String configuration) throws com.typesafe.config.ConfigException
Deprecated.Use #setConfigSet this block instance's configuration from a string, null if none.
- Parameters:
configuration
- configuration, null if none- Returns:
- this object
- Throws:
com.typesafe.config.ConfigException
- if the supplied text is not valid HOCON, JSON, or YAML
-
getInstanceConfig
public com.typesafe.config.Config getInstanceConfig()
Return this block instance's configuration, null if none.
- Returns:
- block instance configuration, null if none
-
setInstanceConfig
public BlockInstanceConfig setInstanceConfig(com.typesafe.config.Config instanceConfig)
Set this block instance's configuration, null if none.
- Parameters:
instanceConfig
- configuration, null if none- Returns:
- this object
-
getBlockMetaData
public BlockMetaDataConfig getBlockMetaData()
For inline block definitions, return the block metadata that would otherwise appear in the referenced block project, null if none. This value is null if the block instance has a block ID and non-null if it does not. The type of the returned value indicates the kind of block being inlined.
- Returns:
- inline block metadata, null if an identified block
-
setBlockMetaData
public BlockInstanceConfig setBlockMetaData(BlockMetaDataConfig blockMetaData)
For inline block definitions, set the block metadata that would otherwise appear in the referenced block project, null if none. Set to null if the block instance has a block ID and non-null if it does not.
- Parameters:
blockMetaData
- metadata, null if an identified block- Returns:
- this object
-
fillMap
protected void fillMap(Map<String,Object> props)
Add this object's properties to the specified map.
- Specified by:
fillMap
in classBaseConfig
- Parameters:
props
- map to fill
-
-