Class Tools.Utils
java.lang.Object
com.inductiveautomation.ignition.common.ai.Tools.Utils
- Enclosing class:
Tools
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic Tools.Utils.SchemaResultapplyJsonSchema(Class<?> raw, Type type, String name, @Nullable ToolParam annotation) Builds the JSON schema fragment forparameter's type.static @Nullable Objectstatic @Nullable TypelistElementType(Type generic) Resolves the element type of a genericList<T>parameter, ornullwhen the parameter is a rawListwith no compile-time element type.
-
Constructor Details
-
Utils
public Utils()
-
-
Method Details
-
applyJsonSchema
public static Tools.Utils.SchemaResult applyJsonSchema(Class<?> raw, Type type, String name, @Nullable ToolParam annotation) Builds the JSON schema fragment forparameter's type. Supports scalars (String, the boxed and unboxed forms ofint/long/double/float/boolean),enumtypes (emitted as astringwith anenumconstraint of the constant names), andList<String>. Anything else throws. -
listElementType
-
coerce
-