Package ghidra.app.util.bin.format.golang.rtti.types

# Class GoChanType

java.lang.Object
ghidra.app.util.bin.format.golang.rtti.types.GoType
ghidra.app.util.bin.format.golang.rtti.types.GoChanType

All Implemented Interfaces:
  `StructureMarkup<GoType>`, `StructureVerifier`

public class GoChanType extends GoType
A `GoType` structure that defines a Go channel

- ## Field Summary

  ### Fields inherited from class ghidra.app.util.bin.format.golang.rtti.types.GoType

  `context, programContext, typ, uncommonType`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `GoChanType()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `boolean`
  `discoverGoTypes(Set<Long> discoveredTypes)`
  Iterates this type, and any types this type refers to, while registering the types with the `GoRttiMapper` context.
  `GoType`
  `getElement()`
  Returns a reference to the `GoType` that defines the elements this channel uses.
  `boolean`
  `isValid()`
  `DataType`
  `recoverDataType()`
  Converts a Go RTTI type structure into a Ghidra data type.

  ### Methods inherited from class ghidra.app.util.bin.format.golang.rtti.types.GoType

  `additionalMarkup, getBaseType, getDebugId, getEndOfTypeInfo, getFullyQualifiedName, getImplementsInterfaceString, getMethodInfoList, getMethodListString, getMethodPrototypeString, getMethodPrototypeString, getName, getOffsetEndOfFullType, getPackagePathString, getSpecializedTypeClass, getStructureContext, getStructureLabel, getStructureName, getStructureNamespace, getSymbolName, getTypeDeclString, getTypeOffset, getUncommonType, toString`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

  ### Methods inherited from interface ghidra.app.util.bin.format.golang.structmapping.StructureMarkup

  `getExternalInstancesToMarkup`

- ## Constructor Details

  - ### GoChanType

    public GoChanType()

- ## Method Details

  - ### getElement

    public GoType getElement() throws IOException
    Returns a reference to the `GoType` that defines the elements this channel uses.
    Returns:
      a reference to the `GoType` that defines the elements this channel uses
    Throws:
      `IOException` - if error reading type

  - ### recoverDataType

    public DataType recoverDataType() throws IOException
    Description copied from class: `GoType`
    Converts a Go RTTI type structure into a Ghidra data type.

    This default implementation just creates an opaque blob of the appropriate size

    Overrides:
      `recoverDataType` in class `GoType`
    Returns:
      `DataType` that represents the Go type
    Throws:
      `IOException` - if error getting name of the type

  - ### discoverGoTypes

    public boolean discoverGoTypes(Set<Long> discoveredTypes) throws IOException
    Description copied from class: `GoType`
    Iterates this type, and any types this type refers to, while registering the types with the `GoRttiMapper` context.

    This method should be overloaded by derived type classes to add any additional types referenced by the derived type.

    Overrides:
      `discoverGoTypes` in class `GoType`
    Parameters:
      `discoveredTypes` - set of already iterated types
    Returns:
      boolean boolean flag, if false the type has already been discovered, if true the type was encountered for the first time
    Throws:
      `IOException` - if error reading type info

  - ### isValid

    public boolean isValid()
    Specified by:
      `isValid` in interface `StructureVerifier`
    Overrides:
      `isValid` in class `GoType`