blockly > Procedures > IProcedureModel > getReturnTypes
Procedures.IProcedureModel.getReturnTypes() method
Returns the return type(s) of the procedure.
Null represents a procedure that does not return a value.
Signature:
getReturnTypes(): string[] | null;
Returns:
string[] | null
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-09-18 UTC.
[null,null,["Last updated 2024-09-18 UTC."],[[["The `getReturnTypes()` method provides the return type(s) of a procedure, indicating the data type(s) it produces as output."],["If a procedure doesn't return any value, the method returns `null`, signifying a void return type."],["Return types are represented as an array of strings, where each string denotes a specific data type like 'number', 'string', 'boolean', etc."]]],["The `getReturnTypes()` method, part of the Procedures.IProcedureModel interface, retrieves the return type(s) of a procedure. It outputs an array of strings (`string[]`) representing the return types. If the procedure does not return a value, the method returns `null`. This method essentially defines what kind of value a given procedure will give back after it is called.\n"]]