блочно > Блокировать > setOutput
Метод Block.setOutput()
Установите, возвращает ли этот блок значение.
Подпись:
setOutput(newBoolean: boolean, opt_check?: string | string[] | null): void;
Параметры
Параметр | Тип | Описание |
---|
новое логическое значение | логическое значение | Правда, если есть выход. |
opt_check | строка | строка[] | нулевой | (Необязательно) Возвращаемый тип или список возвращаемых типов. Нулевое или неопределенное значение, если может быть возвращен любой тип (например, переменная get). |
Возврат:
пустота
Если не указано иное, контент на этой странице предоставляется по лицензии Creative Commons "С указанием авторства 4.0", а примеры кода – по лицензии Apache 2.0. Подробнее об этом написано в правилах сайта. Java – это зарегистрированный товарный знак корпорации Oracle и ее аффилированных лиц.
Последнее обновление: 2024-11-14 UTC.
[null,null,["Последнее обновление: 2024-11-14 UTC."],[[["The `setOutput` method determines if a block produces a value or not."],["It takes a boolean argument (`newBoolean`) indicating the output status and an optional `opt_check` for specifying the output type(s)."],["Calling `setOutput` does not return any value (void)."]]],["The `Block.setOutput()` method determines if a block returns a value. It accepts a boolean `newBoolean`: `true` indicates an output exists, `false` otherwise. An optional `opt_check` parameter specifies the type or types returned, using a string or string array. If `null` or `undefined`, any type is acceptable. The method's return type is `void`. The key actions are setting and defining the parameters of a block's output status and its type.\n"]]