Class TextPartParser

java.lang.Object
io.agentscope.core.a2a.agent.message.TextPartParser
All Implemented Interfaces:
PartParser<io.a2a.spec.TextPart>

public class TextPartParser extends Object implements PartParser<io.a2a.spec.TextPart>
Parser for TextPart to TextBlock or ThinkingBlock.
  • Constructor Details

    • TextPartParser

      public TextPartParser()
  • Method Details

    • parse

      public io.agentscope.core.message.ContentBlock parse(io.a2a.spec.TextPart part)
      Description copied from interface: PartParser
      Parse the given part and convert it to a ContentBlock.
      Specified by:
      parse in interface PartParser<io.a2a.spec.TextPart>
      Parameters:
      part - the part to parse, not null
      Returns:
      the parsed content block