Class SkillJsonHelper
- Namespace
- nanoFramework.WebServer.Skills
- Assembly
- nanoFramework.WebServer.Skills.dll
Provides utility methods for generating JSON schemas that describe the input and output parameters of actions.
public static class SkillJsonHelper
- Inheritance
-
SkillJsonHelper
- Inherited Members
Methods
GenerateInputJson(Type)
Generates a JSON object schema describing the input parameters for an action.
public static string GenerateInputJson(Type inputType)
Parameters
Returns
- string
A JSON string representing the input parameters schema.
GenerateOutputJson(Type, string)
Generates a JSON object describing the output schema for an action.
public static string GenerateOutputJson(Type outputType, string description)
Parameters
Returns
- string
A JSON string representing the output schema.
IsPrimitiveType(Type)
Checks if the specified Type is a primitive type.
public static bool IsPrimitiveType(Type type)
Parameters
Returns
- bool
trueif the type is a primitive type; otherwise,false.