提供意見
Operation
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
此資源表示作為網絡 API 調用結果的長時間運行的操作。
JSON 表示 {
"name": string ,
"metadata": {
"@type": string ,
field1: ... ,
...
} ,
"done": boolean ,
// Union field result
can be only one of the following:
"error": {
object(Status
)
} ,
"response": {
"@type": string ,
field1: ... ,
...
}
// End of list of possible types for union field result
.
}
字段 name
string
服務器分配的名稱,僅在最初返回它的服務中是唯一的。如果使用默認的HTTP映射, name
應具有格式operations/some/unique/name
。
metadata
object
與操作關聯的特定於服務的元數據。它通常包含進度信息和通用元數據,例如創建時間。某些服務可能不提供此類元數據。任何返回長時間運行操作的方法都應記錄元數據類型(如果有)。
包含任意類型字段的對象。一個附加的字段"@type"
包含URI識別的類型。例如: { "id": 1234, "@type": "types.example.com/standard/id" }
。
done
boolean
如果該值是false
,這意味著操作仍在進行中。如果true
,則操作完成,並且或者error
或response
是可用的。
聯盟場result
。的操作結果,其可以是一個error
或有效的response
。如果done
== false
,既不error
也不response
設置。如果done
== true
,正好一個error
或response
設置。 result
只能是以下情況之一: error
object( Status
)
操作失敗或取消時的錯誤結果。
response
object
操作成功時的正常反應。如果原始方法返回成功沒有數據,諸如Delete
,響應是google.protobuf.Empty
。如果原來的方法是標準Get
/ Create
/ Update
,響應應該是資源。對於其他方法,響應應具有類型XxxResponse
,其中Xxx
是原來的方法的名稱。例如,如果原來的方法名是TakeSnapshot()
所推斷的響應類型是TakeSnapshotResponse
。
包含任意類型字段的對象。一個附加的字段"@type"
包含URI識別的類型。例如: { "id": 1234, "@type": "types.example.com/standard/id" }
。
提供意見
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權 ,程式碼範例則為阿帕契 2.0 授權 。詳情請參閱《Google Developers 網站政策 》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2019-12-03 (世界標準時間)。
[{
"type": "thumb-down",
"id": "missingTheInformationINeed",
"label":"缺少我需要的資訊"
},{
"type": "thumb-down",
"id": "tooComplicatedTooManySteps",
"label":"過於複雜/步驟過多"
},{
"type": "thumb-down",
"id": "outOfDate",
"label":"過時"
},{
"type": "thumb-down",
"id": "translationIssue",
"label":"翻譯問題"
},{
"type": "thumb-down",
"id": "samplesCodeIssue",
"label":"示例/程式碼問題"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"其他"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"容易理解"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"確實解決了我的問題"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"其他"
}]
想進一步說明嗎?