Interface PortDefinition


@Immutable public interface PortDefinition
Definition of an input or output port on a node. Used to describe the node's interface for client rendering. Port IDs are simple names (e.g., "interval", "message", "bot"). The port type is stored separately in the type() field.
  • Method Details

    • execIn

      static PortDefinition execIn()
      Creates an execution input port.
    • execOut

      static PortDefinition execOut()
      Creates an execution output port.
    • input

      static PortDefinition input(String id, String displayName, PortType type, String description)
      Creates a required input port.
      Parameters:
      id - simple port name (e.g., "interval", "target")
    • inputWithDefault

      static PortDefinition inputWithDefault(String id, String displayName, PortType type, String defaultValue, String description)
      Creates an optional input port with a default value.
      Parameters:
      id - simple port name (e.g., "interval", "message")
    • output

      static PortDefinition output(String id, String displayName, PortType type, String description)
      Creates an output port.
      Parameters:
      id - simple port name (e.g., "success", "count")
    • listInput

      static PortDefinition listInput(String id, String displayName, PortType elementType, String description)
      Creates a list input port with element type.
      Parameters:
      id - simple port name (e.g., "items", "targets")
    • listOutput

      static PortDefinition listOutput(String id, String displayName, PortType elementType, String description)
      Creates a list output port with element type.
      Parameters:
      id - simple port name (e.g., "results", "bots")
    • id

      String id()
    • displayName

      String displayName()
    • type

      PortType type()
    • required

      @Default default boolean required()
    • defaultValue

      @Nullable String defaultValue()
    • description

      @Default default String description()
    • elementType

      @Nullable PortType elementType()
    • multiInput

      @Default default boolean multiInput()
      Whether this input accepts multiple connections (Blender-style multi-input). When true, all connected values are collected into a list. NOTE: The reactive engine does not yet implement multi-input collection.
    • multiInput

      static PortDefinition multiInput(String id, String displayName, PortType type, String description)
      Creates a multi-input port that accepts multiple connections. All connected values are collected into a list.
      Parameters:
      id - simple port name