模板:Function

出自Minecraft基岩版开发Wiki
[檢視 | 編輯 | 歷史 | 清除緩存]文件頁面
Function
參數型別

{{Function}}應當被放在條目頂端,給予讀者關於條目的基本資訊。


模板參數[編輯]

該模板是函式或變數的Infobox

模板參數[編輯模板資料]

此模板以參數區塊格式為優先。

參數描述類型狀態
標題title

Infobox的標題,不填寫時預設繼承頁面標題

預設
{{PAGENAMEBASE}}
範例
query.all tags
頁面名稱選填
實驗性experimental

在副標題註明「實驗性」

布林值選填
型別type

本變數的型別,可以填寫fn, function, cfn, construct, constructor, constructfunction, q, query, queryfunction, num, number, str, string, arr, array, dat, date, bl, bool, boolean, obj, object, ?, unknown或自訂值

字串選填
整數int

只有{{{type}}}填寫num或number時可選

布林值選填
單精度浮點數double

只有{{{type}}}填寫num或number時可選

布林值選填
雙精確度浮點數float

只有{{{type}}}填寫num或number時可選

布林值選填
Java物件java

只有{{{type}}}填寫obj或object時可選,Java型別

字串選填
自訂物件custom

只有{{{type}}}填寫obj或object時可選

字串選填
參數型別par

參數型別,可以填寫fn, function, num, number, numi, numberint, numd, numberdouble, numf, numberint, str, string, arr, array, dat, date, bl, bool, boolean, obj, object, objj, objectjava, objc, objectcustome, cfn, construct, constructor, constructfunction, q, query, queryfunction, ?, unknown或自訂值

字串選填
可選參數型別params

函式末尾的可選參數型別,可以填寫fn, function, num, number, numi, numberint, numd, numberdouble, numf, numberint, str, string, arr, array, dat, date, bl, bool, boolean, obj, object, objj, objectjava, objc, objectcustome, cfn, construct, constructor, constructfunction, q, query, queryfunction, ?, unknown或自訂值

字串選填
傳回值型別return_type

傳回值型別,可以填寫fn, function, num, number, numi, numberint, numd, numberdouble, numf, numberint, str, string, arr, array, dat, date, bl, bool, boolean, obj, object, objj, objectjava, objc, objectcustome, cfn, construct, constructor, constructfunction, q, query, queryfunction, ?, unknown或自訂值

預設
void
字串選填
APIapi

API種類

字串選填
適用語言lang

語言

字串選填
加入版本added

加入版本

字串選填
移除版本removed

移除版本

字串選填
最低引擎版本verengine

只有{{{lang}}}填寫ml或molang時可選

字串選填

參見[編輯]