isLookupTableDataInterface

Determine whether object is a coder.descriptor.LookupTableDataInterface object

Syntax

lookupTableDataInterface = isLookupTableDataInterface(parameterObj)

Description

lookupTableDataInterface = isLookupTableDataInterface(parameterObj) returns a logical value indicating whether the object is a coder.descriptor.LookupTableDataInterface object.

Input Arguments

expand all

coder.descriptor.LookupTableDataInterface object that represents a Lookup Table block in the model.

Data Types: string

Output Arguments

expand all

Logical value indicating whether the object is a coder.descriptor.LookupTableDataInterface.

Data Types: logical

Examples

expand all

  1. Build the model.

    rtwbuild('rtwdemo_asap2')
  2. Create a coder.codedescriptor.CodeDescriptor object for the model.

    codeDescObj = coder.getCodeDescriptor('rtwdemo_asap2')
    
  3. Return properties of the Lookup Table parameters in the model.

    params = getDataInterfaces(codeDescObj, 'Parameters')

    The params variable is an array of coder.descriptor.DataInterface, coder.descriptor.LookupTableDataInterface, and coder.descriptor.BreakpointDataInterface objects.

  4. Obtain the details of the model Lookup Table block by accessing the sixth location in the array.

    parameterObj = params(6)

  5. Determine if the object stored in parameterObj variable is a coder.descriptor.LookupTableDataInterface object.

    lookupTableDataInterface = isLookupTableDataInterface(parameterObj)
    
    lookupTableDataInterface =
    
      logical
    
      1
    The code generator returns a logical value of 1 if parameterObj is a coder.descriptor.LookupTableDataInterface object. Otherwise, the code generator returns a logical value of 0.

Introduced in R2020a