mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2024-11-21 14:44:00 +00:00
vendor: make vendor-update
This commit is contained in:
parent
79d967d35a
commit
2a78975447
51 changed files with 1444 additions and 3194 deletions
15
go.mod
15
go.mod
|
@ -3,7 +3,7 @@ module github.com/VictoriaMetrics/VictoriaMetrics
|
|||
go 1.17
|
||||
|
||||
require (
|
||||
cloud.google.com/go/storage v1.23.0
|
||||
cloud.google.com/go/storage v1.24.0
|
||||
github.com/VictoriaMetrics/fastcache v1.10.0
|
||||
|
||||
// Do not use the original github.com/valyala/fasthttp because of issues
|
||||
|
@ -11,7 +11,7 @@ require (
|
|||
github.com/VictoriaMetrics/fasthttp v1.1.0
|
||||
github.com/VictoriaMetrics/metrics v1.19.3
|
||||
github.com/VictoriaMetrics/metricsql v0.44.1
|
||||
github.com/aws/aws-sdk-go v1.44.56
|
||||
github.com/aws/aws-sdk-go v1.44.59
|
||||
github.com/cespare/xxhash/v2 v2.1.2
|
||||
|
||||
// TODO: switch back to https://github.com/cheggaaa/pb/v3 when v3-pooling branch
|
||||
|
@ -20,18 +20,18 @@ require (
|
|||
github.com/dmitryk-dk/pb/v3 v3.0.9
|
||||
github.com/golang/snappy v0.0.4
|
||||
github.com/influxdata/influxdb v1.9.8
|
||||
github.com/klauspost/compress v1.15.8
|
||||
github.com/klauspost/compress v1.15.9
|
||||
github.com/prometheus/prometheus v1.8.2-0.20201119142752-3ad25a6dc3d9
|
||||
github.com/urfave/cli/v2 v2.11.0
|
||||
github.com/urfave/cli/v2 v2.11.1
|
||||
github.com/valyala/fastjson v1.6.3
|
||||
github.com/valyala/fastrand v1.1.0
|
||||
github.com/valyala/fasttemplate v1.2.1
|
||||
github.com/valyala/gozstd v1.17.0
|
||||
github.com/valyala/quicktemplate v1.7.0
|
||||
golang.org/x/net v0.0.0-20220708220712-1185a9018129
|
||||
golang.org/x/oauth2 v0.0.0-20220630143837-2104d58473e0
|
||||
golang.org/x/oauth2 v0.0.0-20220718184931-c8730f7fcb92
|
||||
golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8
|
||||
google.golang.org/api v0.87.0
|
||||
google.golang.org/api v0.88.0
|
||||
gopkg.in/yaml.v2 v2.4.0
|
||||
)
|
||||
|
||||
|
@ -52,7 +52,6 @@ require (
|
|||
github.com/google/uuid v1.3.0 // indirect
|
||||
github.com/googleapis/enterprise-certificate-proxy v0.1.0 // indirect
|
||||
github.com/googleapis/gax-go/v2 v2.4.0 // indirect
|
||||
github.com/googleapis/go-type-adapters v1.0.0 // indirect
|
||||
github.com/jmespath/go-jmespath v0.4.0 // indirect
|
||||
github.com/mattn/go-colorable v0.1.12 // indirect
|
||||
github.com/mattn/go-isatty v0.0.14 // indirect
|
||||
|
@ -76,7 +75,7 @@ require (
|
|||
golang.org/x/text v0.3.7 // indirect
|
||||
golang.org/x/xerrors v0.0.0-20220609144429-65e65417b02f // indirect
|
||||
google.golang.org/appengine v1.6.7 // indirect
|
||||
google.golang.org/genproto v0.0.0-20220715211116-798f69b842b9 // indirect
|
||||
google.golang.org/genproto v0.0.0-20220720214146-176da50484ac // indirect
|
||||
google.golang.org/grpc v1.48.0 // indirect
|
||||
google.golang.org/protobuf v1.28.0 // indirect
|
||||
)
|
||||
|
|
28
go.sum
28
go.sum
|
@ -61,8 +61,9 @@ cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohl
|
|||
cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs=
|
||||
cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0=
|
||||
cloud.google.com/go/storage v1.22.1/go.mod h1:S8N1cAStu7BOeFfE8KAQzmyyLkK8p/vmRq6kuBTW58Y=
|
||||
cloud.google.com/go/storage v1.23.0 h1:wWRIaDURQA8xxHguFCshYepGlrWIrbBnAmc7wfg07qY=
|
||||
cloud.google.com/go/storage v1.23.0/go.mod h1:vOEEDNFnciUMhBeT6hsJIn3ieU5cFRmzeLgDvXzfIXc=
|
||||
cloud.google.com/go/storage v1.24.0 h1:a4N0gIkx83uoVFGz8B2eAV3OhN90QoWF5OZWLKl39ig=
|
||||
cloud.google.com/go/storage v1.24.0/go.mod h1:3xrJEFMXBsQLgxwThyjuD3aYlroL0TMRec1ypGUQ0KE=
|
||||
collectd.org v0.3.0/go.mod h1:A/8DzQBkF6abtvrT2j/AU/4tiBgJWYyh0y/oB/4MlWE=
|
||||
dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU=
|
||||
github.com/Azure/azure-sdk-for-go v48.2.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
|
||||
|
@ -147,8 +148,8 @@ github.com/aws/aws-lambda-go v1.13.3/go.mod h1:4UKl9IzQMoD+QF79YdCuzCwp8VbmG4VAQ
|
|||
github.com/aws/aws-sdk-go v1.27.0/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo=
|
||||
github.com/aws/aws-sdk-go v1.34.28/go.mod h1:H7NKnBqNVzoTJpGfLrQkkD+ytBA93eiDYi/+8rV9s48=
|
||||
github.com/aws/aws-sdk-go v1.35.31/go.mod h1:hcU610XS61/+aQV88ixoOzUoG7v3b31pl2zKMmprdro=
|
||||
github.com/aws/aws-sdk-go v1.44.56 h1:bT+lExwagH7djxb6InKUVkEKGPAj5aAPnV85/m1fKro=
|
||||
github.com/aws/aws-sdk-go v1.44.56/go.mod h1:y4AeaBuwd2Lk+GepC1E9v0qOiTws0MIWAX4oIKwKHZo=
|
||||
github.com/aws/aws-sdk-go v1.44.59 h1:bkdnNsMvMhFmNLqKDAJ6rKR+S0hjOt/3AIJp2mxOK9o=
|
||||
github.com/aws/aws-sdk-go v1.44.59/go.mod h1:y4AeaBuwd2Lk+GepC1E9v0qOiTws0MIWAX4oIKwKHZo=
|
||||
github.com/aws/aws-sdk-go-v2 v0.18.0/go.mod h1:JWVYvqSMppoMJC0x5wdwiImzgXTI9FuZwxzkQq9wy+g=
|
||||
github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q=
|
||||
github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8=
|
||||
|
@ -475,7 +476,6 @@ github.com/googleapis/gax-go/v2 v2.3.0/go.mod h1:b8LNqSzNabLiUpXKkY7HAR5jr6bIT99
|
|||
github.com/googleapis/gax-go/v2 v2.4.0 h1:dS9eYAjhrE2RjmzYw2XAPvcXfmcQLtFEQWn0CR82awk=
|
||||
github.com/googleapis/gax-go/v2 v2.4.0/go.mod h1:XOTVJ59hdnfJLIP/dh8n5CGryZR2LxK9wbMD5+iXC6c=
|
||||
github.com/googleapis/gnostic v0.4.1/go.mod h1:LRhVm6pbyptWbWbuZ38d1eyptfvIytN3ir6b65WBswg=
|
||||
github.com/googleapis/go-type-adapters v1.0.0 h1:9XdMn+d/G57qq1s8dNc5IesGCXHf6V2HZ2JwRxfA2tA=
|
||||
github.com/googleapis/go-type-adapters v1.0.0/go.mod h1:zHW75FOG2aur7gAO2B+MLby+cLsWGBF62rFAi7WjWO4=
|
||||
github.com/gophercloud/gophercloud v0.14.0/go.mod h1:VX0Ibx85B60B5XOrZr6kaNwrmPUzcmMpwxvQ1WQIIWM=
|
||||
github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY=
|
||||
|
@ -574,8 +574,8 @@ github.com/klauspost/compress v1.4.0/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0
|
|||
github.com/klauspost/compress v1.9.5/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A=
|
||||
github.com/klauspost/compress v1.13.4/go.mod h1:8dP1Hq4DHOhN9w426knH3Rhby4rFm6D8eO+e+Dq5Gzg=
|
||||
github.com/klauspost/compress v1.13.5/go.mod h1:/3/Vjq9QcHkK5uEr5lBEmyoZ1iFhe47etQ6QUkpK6sk=
|
||||
github.com/klauspost/compress v1.15.8 h1:JahtItbkWjf2jzm/T+qgMxkP9EMHsqEUA6vCMGmXvhA=
|
||||
github.com/klauspost/compress v1.15.8/go.mod h1:PhcZ0MbTNciWF3rruxRgKxI5NkcHHrHUDtV4Yw2GlzU=
|
||||
github.com/klauspost/compress v1.15.9 h1:wKRjX6JRtDdrE9qwa4b/Cip7ACOshUI4smpCQanqjSY=
|
||||
github.com/klauspost/compress v1.15.9/go.mod h1:PhcZ0MbTNciWF3rruxRgKxI5NkcHHrHUDtV4Yw2GlzU=
|
||||
github.com/klauspost/cpuid v0.0.0-20170728055534-ae7887de9fa5/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek=
|
||||
github.com/klauspost/crc32 v0.0.0-20161016154125-cb6bfca970f6/go.mod h1:+ZoRqAPRLkC4NPOvfYeR5KNOrY6TD+/sAC3HXPZgDYg=
|
||||
github.com/klauspost/pgzip v1.0.2-0.20170402124221-0bf5dcad4ada/go.mod h1:Ch1tH69qFZu15pkjo5kYi6mth2Zzwzt50oCQKQE9RUs=
|
||||
|
@ -823,8 +823,8 @@ github.com/uber/jaeger-client-go v2.25.0+incompatible/go.mod h1:WVhlPFC8FDjOFMMW
|
|||
github.com/uber/jaeger-lib v2.4.0+incompatible/go.mod h1:ComeNDZlWwrWnDv8aPp0Ba6+uUTzImX/AauajbLI56U=
|
||||
github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
|
||||
github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0=
|
||||
github.com/urfave/cli/v2 v2.11.0 h1:c6bD90aLd2iEsokxhxkY5Er0zA2V9fId2aJfwmrF+do=
|
||||
github.com/urfave/cli/v2 v2.11.0/go.mod h1:f8iq5LtQ/bLxafbdBSLPPNsgaW0l/2fYYEHhAyPlwvo=
|
||||
github.com/urfave/cli/v2 v2.11.1 h1:UKK6SP7fV3eKOefbS87iT9YHefv7iB/53ih6e+GNAsE=
|
||||
github.com/urfave/cli/v2 v2.11.1/go.mod h1:f8iq5LtQ/bLxafbdBSLPPNsgaW0l/2fYYEHhAyPlwvo=
|
||||
github.com/valyala/bytebufferpool v1.0.0 h1:GqA5TC/0021Y/b9FG4Oi9Mr3q7XYx6KllzawFIhcdPw=
|
||||
github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc=
|
||||
github.com/valyala/fasthttp v1.30.0/go.mod h1:2rsYD01CKFrjjsvFxx75KlEUNpWNBY9JWD3K/7o2Cus=
|
||||
|
@ -1026,8 +1026,8 @@ golang.org/x/oauth2 v0.0.0-20220309155454-6242fa91716a/go.mod h1:DAh4E804XQdzx2j
|
|||
golang.org/x/oauth2 v0.0.0-20220411215720-9780585627b5/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc=
|
||||
golang.org/x/oauth2 v0.0.0-20220608161450-d0670ef3b1eb/go.mod h1:jaDAt6Dkxork7LmZnYtzbRWj0W47D86a3TGe0YHBvmE=
|
||||
golang.org/x/oauth2 v0.0.0-20220622183110-fd043fe589d2/go.mod h1:jaDAt6Dkxork7LmZnYtzbRWj0W47D86a3TGe0YHBvmE=
|
||||
golang.org/x/oauth2 v0.0.0-20220630143837-2104d58473e0 h1:VnGaRqoLmqZH/3TMLJwYCEWkR4j1nuIU1U9TvbqsDUw=
|
||||
golang.org/x/oauth2 v0.0.0-20220630143837-2104d58473e0/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg=
|
||||
golang.org/x/oauth2 v0.0.0-20220718184931-c8730f7fcb92 h1:oVlhw3Oe+1reYsE2Nqu19PDJfLzwdU3QUUrG86rLK68=
|
||||
golang.org/x/oauth2 v0.0.0-20220718184931-c8730f7fcb92/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg=
|
||||
golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
|
@ -1287,8 +1287,8 @@ google.golang.org/api v0.80.0/go.mod h1:xY3nI94gbvBrE0J6NHXhxOmW97HG7Khjkku6AFB3
|
|||
google.golang.org/api v0.84.0/go.mod h1:NTsGnUFJMYROtiquksZHBWtHfeMC7iYthki7Eq3pa8o=
|
||||
google.golang.org/api v0.85.0/go.mod h1:AqZf8Ep9uZ2pyTvgL+x0D3Zt0eoT9b5E8fmzfu6FO2g=
|
||||
google.golang.org/api v0.86.0/go.mod h1:+Sem1dnrKlrXMR/X0bPnMWyluQe4RsNoYfmNLhOIkzw=
|
||||
google.golang.org/api v0.87.0 h1:pUQVF/F+X7Tl1lo4LJoJf5BOpjtmINU80p9XpYTU2p4=
|
||||
google.golang.org/api v0.87.0/go.mod h1:+Sem1dnrKlrXMR/X0bPnMWyluQe4RsNoYfmNLhOIkzw=
|
||||
google.golang.org/api v0.88.0 h1:MPwxQRqpyskYhr2iNyfsQ8R06eeyhe7UEuR30p136ZQ=
|
||||
google.golang.org/api v0.88.0/go.mod h1:+Sem1dnrKlrXMR/X0bPnMWyluQe4RsNoYfmNLhOIkzw=
|
||||
google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=
|
||||
google.golang.org/appengine v1.2.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
|
||||
google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
|
||||
|
@ -1382,8 +1382,8 @@ google.golang.org/genproto v0.0.0-20220616135557-88e70c0c3a90/go.mod h1:KEWEmljW
|
|||
google.golang.org/genproto v0.0.0-20220617124728-180714bec0ad/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA=
|
||||
google.golang.org/genproto v0.0.0-20220624142145-8cd45d7dbd1f/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA=
|
||||
google.golang.org/genproto v0.0.0-20220628213854-d9e0b6570c03/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA=
|
||||
google.golang.org/genproto v0.0.0-20220715211116-798f69b842b9 h1:1aEQRgZ4Gks2SRAkLzIPpIszRazwVfjSFe1cKc+e0Jg=
|
||||
google.golang.org/genproto v0.0.0-20220715211116-798f69b842b9/go.mod h1:GkXuJDJ6aQ7lnJcRF+SJVgFdQhypqgl3LB1C9vabdRE=
|
||||
google.golang.org/genproto v0.0.0-20220720214146-176da50484ac h1:EOa+Yrhx1C0O+4pHeXeWrCwdI0tWI6IfUU56Vebs9wQ=
|
||||
google.golang.org/genproto v0.0.0-20220720214146-176da50484ac/go.mod h1:GkXuJDJ6aQ7lnJcRF+SJVgFdQhypqgl3LB1C9vabdRE=
|
||||
google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs=
|
||||
google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c=
|
||||
google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM=
|
||||
|
|
2
vendor/cloud.google.com/go/storage/.release-please-manifest.json
generated
vendored
2
vendor/cloud.google.com/go/storage/.release-please-manifest.json
generated
vendored
|
@ -1,3 +1,3 @@
|
|||
{
|
||||
"storage": "1.23.0"
|
||||
"storage": "1.24.0"
|
||||
}
|
7
vendor/cloud.google.com/go/storage/CHANGES.md
generated
vendored
7
vendor/cloud.google.com/go/storage/CHANGES.md
generated
vendored
|
@ -1,6 +1,13 @@
|
|||
# Changes
|
||||
|
||||
|
||||
## [1.24.0](https://github.com/googleapis/google-cloud-go/compare/storage/v1.23.0...storage/v1.24.0) (2022-07-20)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* **storage:** add Custom Placement Config Dual Region Support ([#6294](https://github.com/googleapis/google-cloud-go/issues/6294)) ([5a8c607](https://github.com/googleapis/google-cloud-go/commit/5a8c607e3a9a3265887e27cb13f8943f3e3fa23d))
|
||||
|
||||
## [1.23.0](https://github.com/googleapis/google-cloud-go/compare/storage/v1.22.1...storage/v1.23.0) (2022-06-23)
|
||||
|
||||
|
||||
|
|
2
vendor/cloud.google.com/go/storage/acl.go
generated
vendored
2
vendor/cloud.google.com/go/storage/acl.go
generated
vendored
|
@ -20,9 +20,9 @@ import (
|
|||
"reflect"
|
||||
|
||||
"cloud.google.com/go/internal/trace"
|
||||
storagepb "cloud.google.com/go/storage/internal/apiv2/stubs"
|
||||
"google.golang.org/api/googleapi"
|
||||
raw "google.golang.org/api/storage/v1"
|
||||
storagepb "google.golang.org/genproto/googleapis/storage/v2"
|
||||
)
|
||||
|
||||
// ACLRole is the level of access to grant.
|
||||
|
|
160
vendor/cloud.google.com/go/storage/bucket.go
generated
vendored
160
vendor/cloud.google.com/go/storage/bucket.go
generated
vendored
|
@ -27,14 +27,13 @@ import (
|
|||
"cloud.google.com/go/compute/metadata"
|
||||
"cloud.google.com/go/internal/optional"
|
||||
"cloud.google.com/go/internal/trace"
|
||||
"github.com/googleapis/go-type-adapters/adapters"
|
||||
storagepb "cloud.google.com/go/storage/internal/apiv2/stubs"
|
||||
"google.golang.org/api/googleapi"
|
||||
"google.golang.org/api/iamcredentials/v1"
|
||||
"google.golang.org/api/iterator"
|
||||
"google.golang.org/api/option"
|
||||
raw "google.golang.org/api/storage/v1"
|
||||
"google.golang.org/genproto/googleapis/storage/v2"
|
||||
storagepb "google.golang.org/genproto/googleapis/storage/v2"
|
||||
dpb "google.golang.org/genproto/googleapis/type/date"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
|
@ -461,8 +460,13 @@ type BucketAttrs struct {
|
|||
PredefinedDefaultObjectACL string
|
||||
|
||||
// Location is the location of the bucket. It defaults to "US".
|
||||
// If specifying a dual-region, CustomPlacementConfig should be set in conjunction.
|
||||
Location string
|
||||
|
||||
// The bucket's custom placement configuration that holds a list of
|
||||
// regional locations for custom dual regions.
|
||||
CustomPlacementConfig *CustomPlacementConfig
|
||||
|
||||
// MetaGeneration is the metadata generation of the bucket.
|
||||
// This field is read-only.
|
||||
MetaGeneration int64
|
||||
|
@ -782,6 +786,15 @@ type BucketWebsite struct {
|
|||
NotFoundPage string
|
||||
}
|
||||
|
||||
// CustomPlacementConfig holds the bucket's custom placement
|
||||
// configuration for Custom Dual Regions. See
|
||||
// https://cloud.google.com/storage/docs/locations#location-dr for more information.
|
||||
type CustomPlacementConfig struct {
|
||||
// The list of regional locations in which data is placed.
|
||||
// Custom Dual Regions require exactly 2 regional locations.
|
||||
DataLocations []string
|
||||
}
|
||||
|
||||
func newBucket(b *raw.Bucket) (*BucketAttrs, error) {
|
||||
if b == nil {
|
||||
return nil, nil
|
||||
|
@ -815,6 +828,7 @@ func newBucket(b *raw.Bucket) (*BucketAttrs, error) {
|
|||
LocationType: b.LocationType,
|
||||
ProjectNumber: b.ProjectNumber,
|
||||
RPO: toRPO(b),
|
||||
CustomPlacementConfig: customPlacementFromRaw(b.CustomPlacementConfig),
|
||||
}, nil
|
||||
}
|
||||
|
||||
|
@ -845,6 +859,7 @@ func newBucketFromProto(b *storagepb.Bucket) *BucketAttrs {
|
|||
PublicAccessPrevention: toPublicAccessPreventionFromProto(b.GetIamConfig()),
|
||||
LocationType: b.GetLocationType(),
|
||||
RPO: toRPOFromProto(b),
|
||||
CustomPlacementConfig: customPlacementFromProto(b.GetCustomPlacementConfig()),
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -882,22 +897,23 @@ func (b *BucketAttrs) toRawBucket() *raw.Bucket {
|
|||
}
|
||||
}
|
||||
return &raw.Bucket{
|
||||
Name: b.Name,
|
||||
Location: b.Location,
|
||||
StorageClass: b.StorageClass,
|
||||
Acl: toRawBucketACL(b.ACL),
|
||||
DefaultObjectAcl: toRawObjectACL(b.DefaultObjectACL),
|
||||
Versioning: v,
|
||||
Labels: labels,
|
||||
Billing: bb,
|
||||
Lifecycle: toRawLifecycle(b.Lifecycle),
|
||||
RetentionPolicy: b.RetentionPolicy.toRawRetentionPolicy(),
|
||||
Cors: toRawCORS(b.CORS),
|
||||
Encryption: b.Encryption.toRawBucketEncryption(),
|
||||
Logging: b.Logging.toRawBucketLogging(),
|
||||
Website: b.Website.toRawBucketWebsite(),
|
||||
IamConfiguration: bktIAM,
|
||||
Rpo: b.RPO.String(),
|
||||
Name: b.Name,
|
||||
Location: b.Location,
|
||||
StorageClass: b.StorageClass,
|
||||
Acl: toRawBucketACL(b.ACL),
|
||||
DefaultObjectAcl: toRawObjectACL(b.DefaultObjectACL),
|
||||
Versioning: v,
|
||||
Labels: labels,
|
||||
Billing: bb,
|
||||
Lifecycle: toRawLifecycle(b.Lifecycle),
|
||||
RetentionPolicy: b.RetentionPolicy.toRawRetentionPolicy(),
|
||||
Cors: toRawCORS(b.CORS),
|
||||
Encryption: b.Encryption.toRawBucketEncryption(),
|
||||
Logging: b.Logging.toRawBucketLogging(),
|
||||
Website: b.Website.toRawBucketWebsite(),
|
||||
IamConfiguration: bktIAM,
|
||||
Rpo: b.RPO.String(),
|
||||
CustomPlacementConfig: b.CustomPlacementConfig.toRawCustomPlacement(),
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -924,7 +940,7 @@ func (b *BucketAttrs) toProtoBucket() *storagepb.Bucket {
|
|||
}
|
||||
var bb *storagepb.Bucket_Billing
|
||||
if b.RequesterPays {
|
||||
bb = &storage.Bucket_Billing{RequesterPays: true}
|
||||
bb = &storagepb.Bucket_Billing{RequesterPays: true}
|
||||
}
|
||||
var bktIAM *storagepb.Bucket_IamConfig
|
||||
if b.UniformBucketLevelAccess.Enabled || b.BucketPolicyOnly.Enabled || b.PublicAccessPrevention != PublicAccessPreventionUnknown {
|
||||
|
@ -940,22 +956,23 @@ func (b *BucketAttrs) toProtoBucket() *storagepb.Bucket {
|
|||
}
|
||||
|
||||
return &storagepb.Bucket{
|
||||
Name: b.Name,
|
||||
Location: b.Location,
|
||||
StorageClass: b.StorageClass,
|
||||
Acl: toProtoBucketACL(b.ACL),
|
||||
DefaultObjectAcl: toProtoObjectACL(b.DefaultObjectACL),
|
||||
Versioning: v,
|
||||
Labels: labels,
|
||||
Billing: bb,
|
||||
Lifecycle: toProtoLifecycle(b.Lifecycle),
|
||||
RetentionPolicy: b.RetentionPolicy.toProtoRetentionPolicy(),
|
||||
Cors: toProtoCORS(b.CORS),
|
||||
Encryption: b.Encryption.toProtoBucketEncryption(),
|
||||
Logging: b.Logging.toProtoBucketLogging(),
|
||||
Website: b.Website.toProtoBucketWebsite(),
|
||||
IamConfig: bktIAM,
|
||||
Rpo: b.RPO.String(),
|
||||
Name: b.Name,
|
||||
Location: b.Location,
|
||||
StorageClass: b.StorageClass,
|
||||
Acl: toProtoBucketACL(b.ACL),
|
||||
DefaultObjectAcl: toProtoObjectACL(b.DefaultObjectACL),
|
||||
Versioning: v,
|
||||
Labels: labels,
|
||||
Billing: bb,
|
||||
Lifecycle: toProtoLifecycle(b.Lifecycle),
|
||||
RetentionPolicy: b.RetentionPolicy.toProtoRetentionPolicy(),
|
||||
Cors: toProtoCORS(b.CORS),
|
||||
Encryption: b.Encryption.toProtoBucketEncryption(),
|
||||
Logging: b.Logging.toProtoBucketLogging(),
|
||||
Website: b.Website.toProtoBucketWebsite(),
|
||||
IamConfig: bktIAM,
|
||||
Rpo: b.RPO.String(),
|
||||
CustomPlacementConfig: b.CustomPlacementConfig.toProtoCustomPlacement(),
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -972,7 +989,7 @@ func (ua *BucketAttrsToUpdate) toProtoBucket() *storagepb.Bucket {
|
|||
}
|
||||
var bb *storagepb.Bucket_Billing
|
||||
if ua.RequesterPays != nil {
|
||||
bb = &storage.Bucket_Billing{RequesterPays: optional.ToBool(ua.RequesterPays)}
|
||||
bb = &storagepb.Bucket_Billing{RequesterPays: optional.ToBool(ua.RequesterPays)}
|
||||
}
|
||||
var bktIAM *storagepb.Bucket_IamConfig
|
||||
var ublaEnabled bool
|
||||
|
@ -1596,13 +1613,13 @@ func toProtoLifecycle(l Lifecycle) *storagepb.Bucket_Lifecycle {
|
|||
}
|
||||
|
||||
if !r.Condition.CreatedBefore.IsZero() {
|
||||
rr.Condition.CreatedBefore = adapters.TimeToProtoDate(r.Condition.CreatedBefore)
|
||||
rr.Condition.CreatedBefore = timeToProtoDate(r.Condition.CreatedBefore)
|
||||
}
|
||||
if !r.Condition.CustomTimeBefore.IsZero() {
|
||||
rr.Condition.CustomTimeBefore = adapters.TimeToProtoDate(r.Condition.CustomTimeBefore)
|
||||
rr.Condition.CustomTimeBefore = timeToProtoDate(r.Condition.CustomTimeBefore)
|
||||
}
|
||||
if !r.Condition.NoncurrentTimeBefore.IsZero() {
|
||||
rr.Condition.NoncurrentTimeBefore = adapters.TimeToProtoDate(r.Condition.NoncurrentTimeBefore)
|
||||
rr.Condition.NoncurrentTimeBefore = timeToProtoDate(r.Condition.NoncurrentTimeBefore)
|
||||
}
|
||||
rl.Rule = append(rl.Rule, rr)
|
||||
}
|
||||
|
@ -1699,13 +1716,13 @@ func toLifecycleFromProto(rl *storagepb.Bucket_Lifecycle) Lifecycle {
|
|||
}
|
||||
|
||||
if rr.GetCondition().GetCreatedBefore() != nil {
|
||||
r.Condition.CreatedBefore = adapters.ProtoDateToUTCTime(rr.GetCondition().GetCreatedBefore())
|
||||
r.Condition.CreatedBefore = protoDateToUTCTime(rr.GetCondition().GetCreatedBefore())
|
||||
}
|
||||
if rr.GetCondition().GetCustomTimeBefore() != nil {
|
||||
r.Condition.CustomTimeBefore = adapters.ProtoDateToUTCTime(rr.GetCondition().GetCustomTimeBefore())
|
||||
r.Condition.CustomTimeBefore = protoDateToUTCTime(rr.GetCondition().GetCustomTimeBefore())
|
||||
}
|
||||
if rr.GetCondition().GetNoncurrentTimeBefore() != nil {
|
||||
r.Condition.NoncurrentTimeBefore = adapters.ProtoDateToUTCTime(rr.GetCondition().GetNoncurrentTimeBefore())
|
||||
r.Condition.NoncurrentTimeBefore = protoDateToUTCTime(rr.GetCondition().GetNoncurrentTimeBefore())
|
||||
}
|
||||
l.Rules = append(l.Rules, r)
|
||||
}
|
||||
|
@ -1933,6 +1950,38 @@ func toRPOFromProto(b *storagepb.Bucket) RPO {
|
|||
}
|
||||
}
|
||||
|
||||
func customPlacementFromRaw(c *raw.BucketCustomPlacementConfig) *CustomPlacementConfig {
|
||||
if c == nil {
|
||||
return nil
|
||||
}
|
||||
return &CustomPlacementConfig{DataLocations: c.DataLocations}
|
||||
}
|
||||
|
||||
func (c *CustomPlacementConfig) toRawCustomPlacement() *raw.BucketCustomPlacementConfig {
|
||||
if c == nil {
|
||||
return nil
|
||||
}
|
||||
return &raw.BucketCustomPlacementConfig{
|
||||
DataLocations: c.DataLocations,
|
||||
}
|
||||
}
|
||||
|
||||
func (c *CustomPlacementConfig) toProtoCustomPlacement() *storagepb.Bucket_CustomPlacementConfig {
|
||||
if c == nil {
|
||||
return nil
|
||||
}
|
||||
return &storagepb.Bucket_CustomPlacementConfig{
|
||||
DataLocations: c.DataLocations,
|
||||
}
|
||||
}
|
||||
|
||||
func customPlacementFromProto(c *storagepb.Bucket_CustomPlacementConfig) *CustomPlacementConfig {
|
||||
if c == nil {
|
||||
return nil
|
||||
}
|
||||
return &CustomPlacementConfig{DataLocations: c.GetDataLocations()}
|
||||
}
|
||||
|
||||
// Objects returns an iterator over the objects in the bucket that match the
|
||||
// Query q. If q is nil, no filtering is done. Objects will be iterated over
|
||||
// lexicographically by name.
|
||||
|
@ -2187,3 +2236,28 @@ func (rpo RPO) String() string {
|
|||
return rpoUnknown
|
||||
}
|
||||
}
|
||||
|
||||
// protoDateToUTCTime returns a new Time based on the google.type.Date, in UTC.
|
||||
//
|
||||
// Hours, minutes, seconds, and nanoseconds are set to 0.
|
||||
func protoDateToUTCTime(d *dpb.Date) time.Time {
|
||||
return protoDateToTime(d, time.UTC)
|
||||
}
|
||||
|
||||
// protoDateToTime returns a new Time based on the google.type.Date and provided
|
||||
// *time.Location.
|
||||
//
|
||||
// Hours, minutes, seconds, and nanoseconds are set to 0.
|
||||
func protoDateToTime(d *dpb.Date, l *time.Location) time.Time {
|
||||
return time.Date(int(d.GetYear()), time.Month(d.GetMonth()), int(d.GetDay()), 0, 0, 0, 0, l)
|
||||
}
|
||||
|
||||
// timeToProtoDate returns a new google.type.Date based on the provided time.Time.
|
||||
// The location is ignored, as is anything more precise than the day.
|
||||
func timeToProtoDate(t time.Time) *dpb.Date {
|
||||
return &dpb.Date{
|
||||
Year: int32(t.Year()),
|
||||
Month: int32(t.Month()),
|
||||
Day: int32(t.Day()),
|
||||
}
|
||||
}
|
||||
|
|
49
vendor/cloud.google.com/go/storage/client.go
generated
vendored
49
vendor/cloud.google.com/go/storage/client.go
generated
vendored
|
@ -66,19 +66,19 @@ type storageClient interface {
|
|||
|
||||
DeleteDefaultObjectACL(ctx context.Context, bucket string, entity ACLEntity, opts ...storageOption) error
|
||||
ListDefaultObjectACLs(ctx context.Context, bucket string, opts ...storageOption) ([]ACLRule, error)
|
||||
UpdateDefaultObjectACL(ctx context.Context, opts ...storageOption) (*ACLRule, error)
|
||||
UpdateDefaultObjectACL(ctx context.Context, bucket string, entity ACLEntity, role ACLRole, opts ...storageOption) error
|
||||
|
||||
// Bucket ACL methods.
|
||||
|
||||
DeleteBucketACL(ctx context.Context, bucket string, entity ACLEntity, opts ...storageOption) error
|
||||
ListBucketACLs(ctx context.Context, bucket string, opts ...storageOption) ([]ACLRule, error)
|
||||
UpdateBucketACL(ctx context.Context, bucket string, entity ACLEntity, role ACLRole, opts ...storageOption) (*ACLRule, error)
|
||||
UpdateBucketACL(ctx context.Context, bucket string, entity ACLEntity, role ACLRole, opts ...storageOption) error
|
||||
|
||||
// Object ACL methods.
|
||||
|
||||
DeleteObjectACL(ctx context.Context, bucket, object string, entity ACLEntity, opts ...storageOption) error
|
||||
ListObjectACLs(ctx context.Context, bucket, object string, opts ...storageOption) ([]ACLRule, error)
|
||||
UpdateObjectACL(ctx context.Context, bucket, object string, entity ACLEntity, role ACLRole, opts ...storageOption) (*ACLRule, error)
|
||||
UpdateObjectACL(ctx context.Context, bucket, object string, entity ACLEntity, role ACLRole, opts ...storageOption) error
|
||||
|
||||
// Media operations.
|
||||
|
||||
|
@ -96,11 +96,11 @@ type storageClient interface {
|
|||
|
||||
// HMAC Key methods.
|
||||
|
||||
GetHMACKey(ctx context.Context, desc *hmacKeyDesc, opts ...storageOption) (*HMACKey, error)
|
||||
ListHMACKey(ctx context.Context, desc *hmacKeyDesc, opts ...storageOption) *HMACKeysIterator
|
||||
UpdateHMACKey(ctx context.Context, desc *hmacKeyDesc, attrs *HMACKeyAttrsToUpdate, opts ...storageOption) (*HMACKey, error)
|
||||
CreateHMACKey(ctx context.Context, desc *hmacKeyDesc, opts ...storageOption) (*HMACKey, error)
|
||||
DeleteHMACKey(ctx context.Context, desc *hmacKeyDesc, opts ...storageOption) error
|
||||
GetHMACKey(ctx context.Context, project, accessID string, opts ...storageOption) (*HMACKey, error)
|
||||
ListHMACKeys(ctx context.Context, project, serviceAccountEmail string, showDeletedKeys bool, opts ...storageOption) *HMACKeysIterator
|
||||
UpdateHMACKey(ctx context.Context, project, serviceAccountEmail, accessID string, attrs *HMACKeyAttrsToUpdate, opts ...storageOption) (*HMACKey, error)
|
||||
CreateHMACKey(ctx context.Context, project, serviceAccountEmail string, opts ...storageOption) (*HMACKey, error)
|
||||
DeleteHMACKey(ctx context.Context, project, accessID string, opts ...storageOption) error
|
||||
|
||||
// Notification methods.
|
||||
ListNotifications(ctx context.Context, bucket string, opts ...storageOption) (map[string]*Notification, error)
|
||||
|
@ -278,22 +278,33 @@ type newRangeReaderParams struct {
|
|||
|
||||
type composeObjectRequest struct {
|
||||
dstBucket string
|
||||
dstObject string
|
||||
srcs []string
|
||||
dstObject destinationObject
|
||||
srcs []sourceObject
|
||||
predefinedACL string
|
||||
encryptionKey []byte
|
||||
sendCRC32C bool
|
||||
}
|
||||
|
||||
type sourceObject struct {
|
||||
name string
|
||||
bucket string
|
||||
gen int64
|
||||
conds *Conditions
|
||||
predefinedACL string
|
||||
encryptionKey []byte
|
||||
}
|
||||
|
||||
type destinationObject struct {
|
||||
name string
|
||||
bucket string
|
||||
conds *Conditions
|
||||
attrs *ObjectAttrs // attrs to set on the destination object.
|
||||
encryptionKey []byte
|
||||
keyName string
|
||||
}
|
||||
|
||||
type rewriteObjectRequest struct {
|
||||
srcBucket string
|
||||
srcObject string
|
||||
dstBucket string
|
||||
dstObject string
|
||||
dstKeyName string
|
||||
attrs *ObjectAttrs
|
||||
gen int64
|
||||
conds *Conditions
|
||||
srcObject sourceObject
|
||||
dstObject destinationObject
|
||||
predefinedACL string
|
||||
token string
|
||||
}
|
||||
|
|
18
vendor/cloud.google.com/go/storage/copy.go
generated
vendored
18
vendor/cloud.google.com/go/storage/copy.go
generated
vendored
|
@ -192,13 +192,6 @@ func (c *Composer) Run(ctx context.Context) (attrs *ObjectAttrs, err error) {
|
|||
return nil, errors.New("storage: at least one source object must be specified")
|
||||
}
|
||||
|
||||
req := &raw.ComposeRequest{}
|
||||
// Compose requires a non-empty Destination, so we always set it,
|
||||
// even if the caller-provided ObjectAttrs is the zero value.
|
||||
req.Destination = c.ObjectAttrs.toRawObject(c.dst.bucket)
|
||||
if c.SendCRC32C {
|
||||
req.Destination.Crc32c = encodeUint32(c.ObjectAttrs.CRC32C)
|
||||
}
|
||||
for _, src := range c.srcs {
|
||||
if err := src.validate(); err != nil {
|
||||
return nil, err
|
||||
|
@ -209,6 +202,17 @@ func (c *Composer) Run(ctx context.Context) (attrs *ObjectAttrs, err error) {
|
|||
if src.encryptionKey != nil {
|
||||
return nil, fmt.Errorf("storage: compose source %s.%s must not have encryption key", src.bucket, src.object)
|
||||
}
|
||||
}
|
||||
|
||||
// TODO: transport agnostic interface starts here.
|
||||
req := &raw.ComposeRequest{}
|
||||
// Compose requires a non-empty Destination, so we always set it,
|
||||
// even if the caller-provided ObjectAttrs is the zero value.
|
||||
req.Destination = c.ObjectAttrs.toRawObject(c.dst.bucket)
|
||||
if c.SendCRC32C {
|
||||
req.Destination.Crc32c = encodeUint32(c.ObjectAttrs.CRC32C)
|
||||
}
|
||||
for _, src := range c.srcs {
|
||||
srcObj := &raw.ComposeRequestSourceObjects{
|
||||
Name: src.object,
|
||||
}
|
||||
|
|
364
vendor/cloud.google.com/go/storage/grpc_client.go
generated
vendored
364
vendor/cloud.google.com/go/storage/grpc_client.go
generated
vendored
|
@ -16,16 +16,17 @@ package storage
|
|||
|
||||
import (
|
||||
"context"
|
||||
"encoding/base64"
|
||||
"fmt"
|
||||
"io"
|
||||
"os"
|
||||
|
||||
"cloud.google.com/go/internal/trace"
|
||||
gapic "cloud.google.com/go/storage/internal/apiv2"
|
||||
storagepb "cloud.google.com/go/storage/internal/apiv2/stubs"
|
||||
"google.golang.org/api/iterator"
|
||||
"google.golang.org/api/option"
|
||||
iampb "google.golang.org/genproto/googleapis/iam/v1"
|
||||
storagepb "google.golang.org/genproto/googleapis/storage/v2"
|
||||
"google.golang.org/grpc"
|
||||
"google.golang.org/grpc/codes"
|
||||
"google.golang.org/grpc/metadata"
|
||||
|
@ -47,6 +48,11 @@ const (
|
|||
//
|
||||
// This is only used for the gRPC API.
|
||||
globalProjectAlias = "_"
|
||||
|
||||
// msgEntityNotSupported indicates ACL entites using project ID are not currently supported.
|
||||
//
|
||||
// This is only used for the gRPC API.
|
||||
msgEntityNotSupported = "The gRPC API currently does not support ACL entities using project ID, use project numbers instead"
|
||||
)
|
||||
|
||||
// defaultGRPCOptions returns a set of the default client options
|
||||
|
@ -309,6 +315,8 @@ func (c *grpcStorageClient) UpdateBucket(ctx context.Context, bucket string, uat
|
|||
// In cases where PredefinedDefaultObjectACL is set, DefaultObjectAcl is cleared.
|
||||
fieldMask.Paths = append(fieldMask.Paths, "default_object_acl")
|
||||
}
|
||||
// Note: This API currently does not support entites using project ID.
|
||||
// Use project numbers in ACL entities. Pending b/233617896.
|
||||
if uattrs.acl != nil {
|
||||
// In cases where acl is set by UpdateBucketACL method.
|
||||
fieldMask.Paths = append(fieldMask.Paths, "acl")
|
||||
|
@ -458,7 +466,8 @@ func (c *grpcStorageClient) UpdateObject(ctx context.Context, bucket, object str
|
|||
s := callSettings(c.settings, opts...)
|
||||
o := uattrs.toProtoObject(bucketResourceName(globalProjectAlias, bucket), object)
|
||||
req := &storagepb.UpdateObjectRequest{
|
||||
Object: o,
|
||||
Object: o,
|
||||
PredefinedAcl: uattrs.PredefinedACL,
|
||||
}
|
||||
if err := applyCondsProto("grpcStorageClient.UpdateObject", gen, conds, req); err != nil {
|
||||
return nil, err
|
||||
|
@ -498,8 +507,11 @@ func (c *grpcStorageClient) UpdateObject(ctx context.Context, bucket, object str
|
|||
if !uattrs.CustomTime.IsZero() {
|
||||
fieldMask.Paths = append(fieldMask.Paths, "custom_time")
|
||||
}
|
||||
|
||||
// TODO(cathyo): Handle ACL and PredefinedACL. Pending b/233617896.
|
||||
// Note: This API currently does not support entites using project ID.
|
||||
// Use project numbers in ACL entities. Pending b/233617896.
|
||||
if uattrs.ACL != nil {
|
||||
fieldMask.Paths = append(fieldMask.Paths, "acl")
|
||||
}
|
||||
// TODO(cathyo): Handle metadata. Pending b/230510191.
|
||||
|
||||
req.UpdateMask = fieldMask
|
||||
|
@ -527,11 +539,21 @@ func (c *grpcStorageClient) DeleteDefaultObjectACL(ctx context.Context, bucket s
|
|||
return err
|
||||
}
|
||||
// Delete the entity and copy other remaining ACL entities.
|
||||
// Note: This API currently does not support entites using project ID.
|
||||
// Use project numbers in ACL entities. Pending b/233617896.
|
||||
// Return error if entity is not found or a project ID is used.
|
||||
invalidEntity := true
|
||||
var acl []ACLRule
|
||||
for _, a := range attrs.DefaultObjectACL {
|
||||
if a.Entity != entity {
|
||||
acl = append(acl, a)
|
||||
}
|
||||
if a.Entity == entity {
|
||||
invalidEntity = false
|
||||
}
|
||||
}
|
||||
if invalidEntity {
|
||||
return fmt.Errorf("storage: entity %v was not found on bucket %v, got %v. %v", entity, bucket, attrs.DefaultObjectACL, msgEntityNotSupported)
|
||||
}
|
||||
uattrs := &BucketAttrsToUpdate{defaultObjectACL: acl}
|
||||
// Call UpdateBucket with a MetagenerationMatch precondition set.
|
||||
|
@ -540,6 +562,7 @@ func (c *grpcStorageClient) DeleteDefaultObjectACL(ctx context.Context, bucket s
|
|||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (c *grpcStorageClient) ListDefaultObjectACLs(ctx context.Context, bucket string, opts ...storageOption) ([]ACLRule, error) {
|
||||
attrs, err := c.GetBucket(ctx, bucket, nil, opts...)
|
||||
if err != nil {
|
||||
|
@ -547,8 +570,25 @@ func (c *grpcStorageClient) ListDefaultObjectACLs(ctx context.Context, bucket st
|
|||
}
|
||||
return attrs.DefaultObjectACL, nil
|
||||
}
|
||||
func (c *grpcStorageClient) UpdateDefaultObjectACL(ctx context.Context, opts ...storageOption) (*ACLRule, error) {
|
||||
return nil, errMethodNotSupported
|
||||
|
||||
func (c *grpcStorageClient) UpdateDefaultObjectACL(ctx context.Context, bucket string, entity ACLEntity, role ACLRole, opts ...storageOption) error {
|
||||
// There is no separate API for PATCH in gRPC.
|
||||
// Make a GET call first to retrieve BucketAttrs.
|
||||
attrs, err := c.GetBucket(ctx, bucket, nil, opts...)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
// Note: This API currently does not support entites using project ID.
|
||||
// Use project numbers in ACL entities. Pending b/233617896.
|
||||
var acl []ACLRule
|
||||
aclRule := ACLRule{Entity: entity, Role: role}
|
||||
acl = append(attrs.DefaultObjectACL, aclRule)
|
||||
uattrs := &BucketAttrsToUpdate{defaultObjectACL: acl}
|
||||
// Call UpdateBucket with a MetagenerationMatch precondition set.
|
||||
if _, err = c.UpdateBucket(ctx, bucket, uattrs, &BucketConditions{MetagenerationMatch: attrs.MetaGeneration}, opts...); err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// Bucket ACL methods.
|
||||
|
@ -561,11 +601,21 @@ func (c *grpcStorageClient) DeleteBucketACL(ctx context.Context, bucket string,
|
|||
return err
|
||||
}
|
||||
// Delete the entity and copy other remaining ACL entities.
|
||||
// Note: This API currently does not support entites using project ID.
|
||||
// Use project numbers in ACL entities. Pending b/233617896.
|
||||
// Return error if entity is not found or a project ID is used.
|
||||
invalidEntity := true
|
||||
var acl []ACLRule
|
||||
for _, a := range attrs.ACL {
|
||||
if a.Entity != entity {
|
||||
acl = append(acl, a)
|
||||
}
|
||||
if a.Entity == entity {
|
||||
invalidEntity = false
|
||||
}
|
||||
}
|
||||
if invalidEntity {
|
||||
return fmt.Errorf("storage: entity %v was not found on bucket %v, got %v. %v", entity, bucket, attrs.ACL, msgEntityNotSupported)
|
||||
}
|
||||
uattrs := &BucketAttrsToUpdate{acl: acl}
|
||||
// Call UpdateBucket with a MetagenerationMatch precondition set.
|
||||
|
@ -574,6 +624,7 @@ func (c *grpcStorageClient) DeleteBucketACL(ctx context.Context, bucket string,
|
|||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (c *grpcStorageClient) ListBucketACLs(ctx context.Context, bucket string, opts ...storageOption) ([]ACLRule, error) {
|
||||
attrs, err := c.GetBucket(ctx, bucket, nil, opts...)
|
||||
if err != nil {
|
||||
|
@ -582,29 +633,58 @@ func (c *grpcStorageClient) ListBucketACLs(ctx context.Context, bucket string, o
|
|||
return attrs.ACL, nil
|
||||
}
|
||||
|
||||
func (c *grpcStorageClient) UpdateBucketACL(ctx context.Context, bucket string, entity ACLEntity, role ACLRole, opts ...storageOption) (*ACLRule, error) {
|
||||
func (c *grpcStorageClient) UpdateBucketACL(ctx context.Context, bucket string, entity ACLEntity, role ACLRole, opts ...storageOption) error {
|
||||
// There is no separate API for PATCH in gRPC.
|
||||
// Make a GET call first to retrieve BucketAttrs.
|
||||
attrs, err := c.GetBucket(ctx, bucket, nil, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
return err
|
||||
}
|
||||
// Note: This API currently does not support entites using project ID.
|
||||
// Use project numbers in ACL entities. Pending b/233617896.
|
||||
var acl []ACLRule
|
||||
aclRule := ACLRule{Entity: entity, Role: role}
|
||||
acl = append(attrs.ACL, aclRule)
|
||||
uattrs := &BucketAttrsToUpdate{acl: acl}
|
||||
// Call UpdateBucket with a MetagenerationMatch precondition set.
|
||||
_, err = c.UpdateBucket(ctx, bucket, uattrs, &BucketConditions{MetagenerationMatch: attrs.MetaGeneration}, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
if _, err = c.UpdateBucket(ctx, bucket, uattrs, &BucketConditions{MetagenerationMatch: attrs.MetaGeneration}, opts...); err != nil {
|
||||
return err
|
||||
}
|
||||
return &aclRule, err
|
||||
return nil
|
||||
}
|
||||
|
||||
// Object ACL methods.
|
||||
|
||||
func (c *grpcStorageClient) DeleteObjectACL(ctx context.Context, bucket, object string, entity ACLEntity, opts ...storageOption) error {
|
||||
return errMethodNotSupported
|
||||
// There is no separate API for PATCH in gRPC.
|
||||
// Make a GET call first to retrieve ObjectAttrs.
|
||||
attrs, err := c.GetObject(ctx, bucket, object, defaultGen, nil, nil, opts...)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
// Delete the entity and copy other remaining ACL entities.
|
||||
// Note: This API currently does not support entites using project ID.
|
||||
// Use project numbers in ACL entities. Pending b/233617896.
|
||||
// Return error if entity is not found or a project ID is used.
|
||||
invalidEntity := true
|
||||
var acl []ACLRule
|
||||
for _, a := range attrs.ACL {
|
||||
if a.Entity != entity {
|
||||
acl = append(acl, a)
|
||||
}
|
||||
if a.Entity == entity {
|
||||
invalidEntity = false
|
||||
}
|
||||
}
|
||||
if invalidEntity {
|
||||
return fmt.Errorf("storage: entity %v was not found on bucket %v, got %v. %v", entity, bucket, attrs.ACL, msgEntityNotSupported)
|
||||
}
|
||||
uattrs := &ObjectAttrsToUpdate{ACL: acl}
|
||||
// Call UpdateObject with the specified metageneration.
|
||||
if _, err = c.UpdateObject(ctx, bucket, object, uattrs, defaultGen, nil, &Conditions{MetagenerationMatch: attrs.Metageneration}, opts...); err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// ListObjectACLs retrieves object ACL entries. By default, it operates on the latest generation of this object.
|
||||
|
@ -617,17 +697,125 @@ func (c *grpcStorageClient) ListObjectACLs(ctx context.Context, bucket, object s
|
|||
return o.ACL, nil
|
||||
}
|
||||
|
||||
func (c *grpcStorageClient) UpdateObjectACL(ctx context.Context, bucket, object string, entity ACLEntity, role ACLRole, opts ...storageOption) (*ACLRule, error) {
|
||||
return nil, errMethodNotSupported
|
||||
func (c *grpcStorageClient) UpdateObjectACL(ctx context.Context, bucket, object string, entity ACLEntity, role ACLRole, opts ...storageOption) error {
|
||||
// There is no separate API for PATCH in gRPC.
|
||||
// Make a GET call first to retrieve ObjectAttrs.
|
||||
attrs, err := c.GetObject(ctx, bucket, object, defaultGen, nil, nil, opts...)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
// Note: This API currently does not support entites using project ID.
|
||||
// Use project numbers in ACL entities. Pending b/233617896.
|
||||
var acl []ACLRule
|
||||
aclRule := ACLRule{Entity: entity, Role: role}
|
||||
acl = append(attrs.ACL, aclRule)
|
||||
uattrs := &ObjectAttrsToUpdate{ACL: acl}
|
||||
// Call UpdateObject with the specified metageneration.
|
||||
if _, err = c.UpdateObject(ctx, bucket, object, uattrs, defaultGen, nil, &Conditions{MetagenerationMatch: attrs.Metageneration}, opts...); err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// Media operations.
|
||||
|
||||
func (c *grpcStorageClient) ComposeObject(ctx context.Context, req *composeObjectRequest, opts ...storageOption) (*ObjectAttrs, error) {
|
||||
return nil, errMethodNotSupported
|
||||
s := callSettings(c.settings, opts...)
|
||||
if s.userProject != "" {
|
||||
ctx = setUserProjectMetadata(ctx, s.userProject)
|
||||
}
|
||||
|
||||
dstObjPb := req.dstObject.attrs.toProtoObject(req.dstBucket)
|
||||
dstObjPb.Name = req.dstObject.name
|
||||
if err := applyCondsProto("ComposeObject destination", -1, req.dstObject.conds, dstObjPb); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if req.sendCRC32C {
|
||||
dstObjPb.Checksums.Crc32C = &req.dstObject.attrs.CRC32C
|
||||
}
|
||||
|
||||
srcs := []*storagepb.ComposeObjectRequest_SourceObject{}
|
||||
for _, src := range req.srcs {
|
||||
srcObjPb := &storagepb.ComposeObjectRequest_SourceObject{Name: src.name}
|
||||
if err := applyCondsProto("ComposeObject source", src.gen, src.conds, srcObjPb); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
srcs = append(srcs, srcObjPb)
|
||||
}
|
||||
|
||||
rawReq := &storagepb.ComposeObjectRequest{
|
||||
Destination: dstObjPb,
|
||||
SourceObjects: srcs,
|
||||
}
|
||||
if req.predefinedACL != "" {
|
||||
rawReq.DestinationPredefinedAcl = req.predefinedACL
|
||||
}
|
||||
if req.encryptionKey != nil {
|
||||
rawReq.CommonObjectRequestParams = toProtoCommonObjectRequestParams(req.encryptionKey)
|
||||
}
|
||||
|
||||
var obj *storagepb.Object
|
||||
var err error
|
||||
if err := run(ctx, func() error {
|
||||
obj, err = c.raw.ComposeObject(ctx, rawReq, s.gax...)
|
||||
return err
|
||||
}, s.retry, s.idempotent, setRetryHeaderGRPC(ctx)); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
return newObjectFromProto(obj), nil
|
||||
}
|
||||
func (c *grpcStorageClient) RewriteObject(ctx context.Context, req *rewriteObjectRequest, opts ...storageOption) (*rewriteObjectResponse, error) {
|
||||
return nil, errMethodNotSupported
|
||||
s := callSettings(c.settings, opts...)
|
||||
obj := req.dstObject.attrs.toProtoObject("")
|
||||
call := &storagepb.RewriteObjectRequest{
|
||||
SourceBucket: bucketResourceName(globalProjectAlias, req.srcObject.bucket),
|
||||
SourceObject: req.srcObject.name,
|
||||
RewriteToken: req.token,
|
||||
DestinationBucket: bucketResourceName(globalProjectAlias, req.dstObject.bucket),
|
||||
DestinationName: req.dstObject.name,
|
||||
Destination: obj,
|
||||
DestinationKmsKey: req.dstObject.keyName,
|
||||
DestinationPredefinedAcl: req.predefinedACL,
|
||||
}
|
||||
|
||||
// The userProject, whether source or destination project, is decided by the code calling the interface.
|
||||
if s.userProject != "" {
|
||||
ctx = setUserProjectMetadata(ctx, s.userProject)
|
||||
}
|
||||
if err := applyCondsProto("Copy destination", defaultGen, req.dstObject.conds, call); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if err := applySourceCondsProto(req.srcObject.gen, req.srcObject.conds, call); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
if len(req.dstObject.encryptionKey) > 0 {
|
||||
call.CommonObjectRequestParams = toProtoCommonObjectRequestParams(req.dstObject.encryptionKey)
|
||||
}
|
||||
if len(req.srcObject.encryptionKey) > 0 {
|
||||
srcParams := toProtoCommonObjectRequestParams(req.srcObject.encryptionKey)
|
||||
call.CopySourceEncryptionAlgorithm = srcParams.GetEncryptionAlgorithm()
|
||||
call.CopySourceEncryptionKeyBytes = srcParams.GetEncryptionKeyBytes()
|
||||
call.CopySourceEncryptionKeySha256Bytes = srcParams.GetEncryptionKeySha256Bytes()
|
||||
}
|
||||
var res *storagepb.RewriteResponse
|
||||
var err error
|
||||
|
||||
retryCall := func() error { res, err = c.raw.RewriteObject(ctx, call, s.gax...); return err }
|
||||
|
||||
if err := run(ctx, retryCall, s.retry, s.idempotent, setRetryHeaderGRPC(ctx)); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
r := &rewriteObjectResponse{
|
||||
done: res.GetDone(),
|
||||
written: res.GetTotalBytesRewritten(),
|
||||
token: res.GetRewriteToken(),
|
||||
resource: newObjectFromProto(res.GetResource()),
|
||||
}
|
||||
|
||||
return r, nil
|
||||
}
|
||||
|
||||
func (c *grpcStorageClient) NewRangeReader(ctx context.Context, params *newRangeReaderParams, opts ...storageOption) (r *Reader, err error) {
|
||||
|
@ -883,20 +1071,142 @@ func (c *grpcStorageClient) TestIamPermissions(ctx context.Context, resource str
|
|||
|
||||
// HMAC Key methods.
|
||||
|
||||
func (c *grpcStorageClient) GetHMACKey(ctx context.Context, desc *hmacKeyDesc, opts ...storageOption) (*HMACKey, error) {
|
||||
return nil, errMethodNotSupported
|
||||
func (c *grpcStorageClient) GetHMACKey(ctx context.Context, project, accessID string, opts ...storageOption) (*HMACKey, error) {
|
||||
s := callSettings(c.settings, opts...)
|
||||
req := &storagepb.GetHmacKeyRequest{
|
||||
AccessId: accessID,
|
||||
Project: toProjectResource(project),
|
||||
}
|
||||
if s.userProject != "" {
|
||||
ctx = setUserProjectMetadata(ctx, s.userProject)
|
||||
}
|
||||
var metadata *storagepb.HmacKeyMetadata
|
||||
err := run(ctx, func() error {
|
||||
var err error
|
||||
metadata, err = c.raw.GetHmacKey(ctx, req, s.gax...)
|
||||
return err
|
||||
}, s.retry, s.idempotent, setRetryHeaderGRPC(ctx))
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return toHMACKeyFromProto(metadata), nil
|
||||
}
|
||||
func (c *grpcStorageClient) ListHMACKey(ctx context.Context, desc *hmacKeyDesc, opts ...storageOption) *HMACKeysIterator {
|
||||
return &HMACKeysIterator{}
|
||||
|
||||
func (c *grpcStorageClient) ListHMACKeys(ctx context.Context, project, serviceAccountEmail string, showDeletedKeys bool, opts ...storageOption) *HMACKeysIterator {
|
||||
s := callSettings(c.settings, opts...)
|
||||
req := &storagepb.ListHmacKeysRequest{
|
||||
Project: toProjectResource(project),
|
||||
ServiceAccountEmail: serviceAccountEmail,
|
||||
ShowDeletedKeys: showDeletedKeys,
|
||||
}
|
||||
if s.userProject != "" {
|
||||
ctx = setUserProjectMetadata(ctx, s.userProject)
|
||||
}
|
||||
it := &HMACKeysIterator{
|
||||
ctx: ctx,
|
||||
projectID: project,
|
||||
retry: s.retry,
|
||||
}
|
||||
gitr := c.raw.ListHmacKeys(it.ctx, req, s.gax...)
|
||||
fetch := func(pageSize int, pageToken string) (token string, err error) {
|
||||
var hmacKeys []*storagepb.HmacKeyMetadata
|
||||
err = run(it.ctx, func() error {
|
||||
hmacKeys, token, err = gitr.InternalFetch(pageSize, pageToken)
|
||||
return err
|
||||
}, s.retry, s.idempotent, setRetryHeaderGRPC(ctx))
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
for _, hkmd := range hmacKeys {
|
||||
hk := toHMACKeyFromProto(hkmd)
|
||||
it.hmacKeys = append(it.hmacKeys, hk)
|
||||
}
|
||||
|
||||
return token, nil
|
||||
}
|
||||
it.pageInfo, it.nextFunc = iterator.NewPageInfo(
|
||||
fetch,
|
||||
func() int { return len(it.hmacKeys) - it.index },
|
||||
func() interface{} {
|
||||
prev := it.hmacKeys
|
||||
it.hmacKeys = it.hmacKeys[:0]
|
||||
it.index = 0
|
||||
return prev
|
||||
})
|
||||
return it
|
||||
}
|
||||
func (c *grpcStorageClient) UpdateHMACKey(ctx context.Context, desc *hmacKeyDesc, attrs *HMACKeyAttrsToUpdate, opts ...storageOption) (*HMACKey, error) {
|
||||
return nil, errMethodNotSupported
|
||||
|
||||
func (c *grpcStorageClient) UpdateHMACKey(ctx context.Context, project, serviceAccountEmail, accessID string, attrs *HMACKeyAttrsToUpdate, opts ...storageOption) (*HMACKey, error) {
|
||||
s := callSettings(c.settings, opts...)
|
||||
hk := &storagepb.HmacKeyMetadata{
|
||||
AccessId: accessID,
|
||||
Project: toProjectResource(project),
|
||||
ServiceAccountEmail: serviceAccountEmail,
|
||||
State: string(attrs.State),
|
||||
Etag: attrs.Etag,
|
||||
}
|
||||
var paths []string
|
||||
fieldMask := &fieldmaskpb.FieldMask{
|
||||
Paths: paths,
|
||||
}
|
||||
if attrs.State != "" {
|
||||
fieldMask.Paths = append(fieldMask.Paths, "state")
|
||||
}
|
||||
req := &storagepb.UpdateHmacKeyRequest{
|
||||
HmacKey: hk,
|
||||
UpdateMask: fieldMask,
|
||||
}
|
||||
if s.userProject != "" {
|
||||
ctx = setUserProjectMetadata(ctx, s.userProject)
|
||||
}
|
||||
var metadata *storagepb.HmacKeyMetadata
|
||||
err := run(ctx, func() error {
|
||||
var err error
|
||||
metadata, err = c.raw.UpdateHmacKey(ctx, req, s.gax...)
|
||||
return err
|
||||
}, s.retry, s.idempotent, setRetryHeaderGRPC(ctx))
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return toHMACKeyFromProto(metadata), nil
|
||||
}
|
||||
func (c *grpcStorageClient) CreateHMACKey(ctx context.Context, desc *hmacKeyDesc, opts ...storageOption) (*HMACKey, error) {
|
||||
return nil, errMethodNotSupported
|
||||
|
||||
func (c *grpcStorageClient) CreateHMACKey(ctx context.Context, project, serviceAccountEmail string, opts ...storageOption) (*HMACKey, error) {
|
||||
s := callSettings(c.settings, opts...)
|
||||
req := &storagepb.CreateHmacKeyRequest{
|
||||
Project: toProjectResource(project),
|
||||
ServiceAccountEmail: serviceAccountEmail,
|
||||
}
|
||||
if s.userProject != "" {
|
||||
ctx = setUserProjectMetadata(ctx, s.userProject)
|
||||
}
|
||||
var res *storagepb.CreateHmacKeyResponse
|
||||
err := run(ctx, func() error {
|
||||
var err error
|
||||
res, err = c.raw.CreateHmacKey(ctx, req, s.gax...)
|
||||
return err
|
||||
}, s.retry, s.idempotent, setRetryHeaderGRPC(ctx))
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
key := toHMACKeyFromProto(res.Metadata)
|
||||
key.Secret = base64.StdEncoding.EncodeToString(res.SecretKeyBytes)
|
||||
|
||||
return key, nil
|
||||
}
|
||||
func (c *grpcStorageClient) DeleteHMACKey(ctx context.Context, desc *hmacKeyDesc, opts ...storageOption) error {
|
||||
return errMethodNotSupported
|
||||
|
||||
func (c *grpcStorageClient) DeleteHMACKey(ctx context.Context, project string, accessID string, opts ...storageOption) error {
|
||||
s := callSettings(c.settings, opts...)
|
||||
req := &storagepb.DeleteHmacKeyRequest{
|
||||
AccessId: accessID,
|
||||
Project: toProjectResource(project),
|
||||
}
|
||||
if s.userProject != "" {
|
||||
ctx = setUserProjectMetadata(ctx, s.userProject)
|
||||
}
|
||||
return run(ctx, func() error {
|
||||
return c.raw.DeleteHmacKey(ctx, req, s.gax...)
|
||||
}, s.retry, s.idempotent, setRetryHeaderGRPC(ctx))
|
||||
}
|
||||
|
||||
// Notification methods.
|
||||
|
|
65
vendor/cloud.google.com/go/storage/hmac.go
generated
vendored
65
vendor/cloud.google.com/go/storage/hmac.go
generated
vendored
|
@ -20,6 +20,7 @@ import (
|
|||
"fmt"
|
||||
"time"
|
||||
|
||||
storagepb "cloud.google.com/go/storage/internal/apiv2/stubs"
|
||||
"google.golang.org/api/iterator"
|
||||
raw "google.golang.org/api/storage/v1"
|
||||
)
|
||||
|
@ -135,10 +136,10 @@ func (hkh *HMACKeyHandle) Get(ctx context.Context, opts ...HMACKeyOption) (*HMAC
|
|||
return nil, err
|
||||
}
|
||||
|
||||
hkPb := &raw.HmacKey{
|
||||
hk := &raw.HmacKey{
|
||||
Metadata: metadata,
|
||||
}
|
||||
return pbHmacKeyToHMACKey(hkPb, false)
|
||||
return toHMACKeyFromRaw(hk, false)
|
||||
}
|
||||
|
||||
// Delete invokes an RPC to delete the key referenced by accessID, on Google Cloud Storage.
|
||||
|
@ -162,34 +163,50 @@ func (hkh *HMACKeyHandle) Delete(ctx context.Context, opts ...HMACKeyOption) err
|
|||
}, hkh.retry, true, setRetryHeaderHTTP(delCall))
|
||||
}
|
||||
|
||||
func pbHmacKeyToHMACKey(pb *raw.HmacKey, updatedTimeCanBeNil bool) (*HMACKey, error) {
|
||||
pbmd := pb.Metadata
|
||||
if pbmd == nil {
|
||||
func toHMACKeyFromRaw(hk *raw.HmacKey, updatedTimeCanBeNil bool) (*HMACKey, error) {
|
||||
hkmd := hk.Metadata
|
||||
if hkmd == nil {
|
||||
return nil, errors.New("field Metadata cannot be nil")
|
||||
}
|
||||
createdTime, err := time.Parse(time.RFC3339, pbmd.TimeCreated)
|
||||
createdTime, err := time.Parse(time.RFC3339, hkmd.TimeCreated)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("field CreatedTime: %v", err)
|
||||
}
|
||||
updatedTime, err := time.Parse(time.RFC3339, pbmd.Updated)
|
||||
updatedTime, err := time.Parse(time.RFC3339, hkmd.Updated)
|
||||
if err != nil && !updatedTimeCanBeNil {
|
||||
return nil, fmt.Errorf("field UpdatedTime: %v", err)
|
||||
}
|
||||
|
||||
hmk := &HMACKey{
|
||||
AccessID: pbmd.AccessId,
|
||||
Secret: pb.Secret,
|
||||
Etag: pbmd.Etag,
|
||||
ID: pbmd.Id,
|
||||
State: HMACState(pbmd.State),
|
||||
ProjectID: pbmd.ProjectId,
|
||||
hmKey := &HMACKey{
|
||||
AccessID: hkmd.AccessId,
|
||||
Secret: hk.Secret,
|
||||
Etag: hkmd.Etag,
|
||||
ID: hkmd.Id,
|
||||
State: HMACState(hkmd.State),
|
||||
ProjectID: hkmd.ProjectId,
|
||||
CreatedTime: createdTime,
|
||||
UpdatedTime: updatedTime,
|
||||
|
||||
ServiceAccountEmail: pbmd.ServiceAccountEmail,
|
||||
ServiceAccountEmail: hkmd.ServiceAccountEmail,
|
||||
}
|
||||
|
||||
return hmk, nil
|
||||
return hmKey, nil
|
||||
}
|
||||
|
||||
func toHMACKeyFromProto(pbmd *storagepb.HmacKeyMetadata) *HMACKey {
|
||||
if pbmd == nil {
|
||||
return nil
|
||||
}
|
||||
|
||||
return &HMACKey{
|
||||
AccessID: pbmd.GetAccessId(),
|
||||
ID: pbmd.GetId(),
|
||||
State: HMACState(pbmd.GetState()),
|
||||
ProjectID: pbmd.GetProject(),
|
||||
CreatedTime: convertProtoTime(pbmd.GetCreateTime()),
|
||||
UpdatedTime: convertProtoTime(pbmd.GetUpdateTime()),
|
||||
ServiceAccountEmail: pbmd.GetServiceAccountEmail(),
|
||||
}
|
||||
}
|
||||
|
||||
// CreateHMACKey invokes an RPC for Google Cloud Storage to create a new HMACKey.
|
||||
|
@ -215,17 +232,17 @@ func (c *Client) CreateHMACKey(ctx context.Context, projectID, serviceAccountEma
|
|||
|
||||
setClientHeader(call.Header())
|
||||
|
||||
var hkPb *raw.HmacKey
|
||||
var hk *raw.HmacKey
|
||||
|
||||
if err := run(ctx, func() error {
|
||||
h, err := call.Context(ctx).Do()
|
||||
hkPb = h
|
||||
hk = h
|
||||
return err
|
||||
}, c.retry, false, setRetryHeaderHTTP(call)); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
return pbHmacKeyToHMACKey(hkPb, true)
|
||||
return toHMACKeyFromRaw(hk, true)
|
||||
}
|
||||
|
||||
// HMACKeyAttrsToUpdate defines the attributes of an HMACKey that will be updated.
|
||||
|
@ -272,10 +289,10 @@ func (h *HMACKeyHandle) Update(ctx context.Context, au HMACKeyAttrsToUpdate, opt
|
|||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
hkPb := &raw.HmacKey{
|
||||
hk := &raw.HmacKey{
|
||||
Metadata: metadata,
|
||||
}
|
||||
return pbHmacKeyToHMACKey(hkPb, false)
|
||||
return toHMACKeyFromRaw(hk, false)
|
||||
}
|
||||
|
||||
// An HMACKeysIterator is an iterator over HMACKeys.
|
||||
|
@ -350,6 +367,8 @@ func (it *HMACKeysIterator) Next() (*HMACKey, error) {
|
|||
func (it *HMACKeysIterator) PageInfo() *iterator.PageInfo { return it.pageInfo }
|
||||
|
||||
func (it *HMACKeysIterator) fetch(pageSize int, pageToken string) (token string, err error) {
|
||||
// TODO: Remove fetch method upon integration. This method is internalized into
|
||||
// httpStorageClient.ListHMACKeys() as it is the only caller.
|
||||
call := it.raw.List(it.projectID)
|
||||
setClientHeader(call.Header())
|
||||
if pageToken != "" {
|
||||
|
@ -379,10 +398,10 @@ func (it *HMACKeysIterator) fetch(pageSize int, pageToken string) (token string,
|
|||
}
|
||||
|
||||
for _, metadata := range resp.Items {
|
||||
hkPb := &raw.HmacKey{
|
||||
hk := &raw.HmacKey{
|
||||
Metadata: metadata,
|
||||
}
|
||||
hkey, err := pbHmacKeyToHMACKey(hkPb, true)
|
||||
hkey, err := toHMACKeyFromRaw(hk, true)
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
|
|
291
vendor/cloud.google.com/go/storage/http_client.go
generated
vendored
291
vendor/cloud.google.com/go/storage/http_client.go
generated
vendored
|
@ -548,8 +548,25 @@ func (c *httpStorageClient) ListDefaultObjectACLs(ctx context.Context, bucket st
|
|||
}
|
||||
return toObjectACLRules(acls.Items), nil
|
||||
}
|
||||
func (c *httpStorageClient) UpdateDefaultObjectACL(ctx context.Context, opts ...storageOption) (*ACLRule, error) {
|
||||
return nil, errMethodNotSupported
|
||||
func (c *httpStorageClient) UpdateDefaultObjectACL(ctx context.Context, bucket string, entity ACLEntity, role ACLRole, opts ...storageOption) error {
|
||||
s := callSettings(c.settings, opts...)
|
||||
type setRequest interface {
|
||||
Do(opts ...googleapi.CallOption) (*raw.ObjectAccessControl, error)
|
||||
Header() http.Header
|
||||
}
|
||||
acl := &raw.ObjectAccessControl{
|
||||
Bucket: bucket,
|
||||
Entity: string(entity),
|
||||
Role: string(role),
|
||||
}
|
||||
var req setRequest
|
||||
var err error
|
||||
req = c.raw.DefaultObjectAccessControls.Update(bucket, string(entity), acl)
|
||||
configureACLCall(ctx, s.userProject, req)
|
||||
return run(ctx, func() error {
|
||||
_, err = req.Do()
|
||||
return err
|
||||
}, s.retry, s.idempotent, setRetryHeaderHTTP(req))
|
||||
}
|
||||
|
||||
// Bucket ACL methods.
|
||||
|
@ -577,7 +594,7 @@ func (c *httpStorageClient) ListBucketACLs(ctx context.Context, bucket string, o
|
|||
return toBucketACLRules(acls.Items), nil
|
||||
}
|
||||
|
||||
func (c *httpStorageClient) UpdateBucketACL(ctx context.Context, bucket string, entity ACLEntity, role ACLRole, opts ...storageOption) (*ACLRule, error) {
|
||||
func (c *httpStorageClient) UpdateBucketACL(ctx context.Context, bucket string, entity ACLEntity, role ACLRole, opts ...storageOption) error {
|
||||
s := callSettings(c.settings, opts...)
|
||||
acl := &raw.BucketAccessControl{
|
||||
Bucket: bucket,
|
||||
|
@ -586,17 +603,11 @@ func (c *httpStorageClient) UpdateBucketACL(ctx context.Context, bucket string,
|
|||
}
|
||||
req := c.raw.BucketAccessControls.Update(bucket, string(entity), acl)
|
||||
configureACLCall(ctx, s.userProject, req)
|
||||
var aclRule ACLRule
|
||||
var err error
|
||||
err = run(ctx, func() error {
|
||||
acl, err = req.Do()
|
||||
aclRule = toBucketACLRule(acl)
|
||||
return run(ctx, func() error {
|
||||
_, err = req.Do()
|
||||
return err
|
||||
}, s.retry, s.idempotent, setRetryHeaderHTTP(req))
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return &aclRule, nil
|
||||
}
|
||||
|
||||
// configureACLCall sets the context, user project and headers on the apiary library call.
|
||||
|
@ -613,7 +624,10 @@ func configureACLCall(ctx context.Context, userProject string, call interface{ H
|
|||
// Object ACL methods.
|
||||
|
||||
func (c *httpStorageClient) DeleteObjectACL(ctx context.Context, bucket, object string, entity ACLEntity, opts ...storageOption) error {
|
||||
return errMethodNotSupported
|
||||
s := callSettings(c.settings, opts...)
|
||||
req := c.raw.ObjectAccessControls.Delete(bucket, object, string(entity))
|
||||
configureACLCall(ctx, s.userProject, req)
|
||||
return run(ctx, func() error { return req.Context(ctx).Do() }, s.retry, s.idempotent, setRetryHeaderHTTP(req))
|
||||
}
|
||||
|
||||
// ListObjectACLs retrieves object ACL entries. By default, it operates on the latest generation of this object.
|
||||
|
@ -634,17 +648,123 @@ func (c *httpStorageClient) ListObjectACLs(ctx context.Context, bucket, object s
|
|||
return toObjectACLRules(acls.Items), nil
|
||||
}
|
||||
|
||||
func (c *httpStorageClient) UpdateObjectACL(ctx context.Context, bucket, object string, entity ACLEntity, role ACLRole, opts ...storageOption) (*ACLRule, error) {
|
||||
return nil, errMethodNotSupported
|
||||
func (c *httpStorageClient) UpdateObjectACL(ctx context.Context, bucket, object string, entity ACLEntity, role ACLRole, opts ...storageOption) error {
|
||||
s := callSettings(c.settings, opts...)
|
||||
type setRequest interface {
|
||||
Do(opts ...googleapi.CallOption) (*raw.ObjectAccessControl, error)
|
||||
Header() http.Header
|
||||
}
|
||||
|
||||
acl := &raw.ObjectAccessControl{
|
||||
Bucket: bucket,
|
||||
Entity: string(entity),
|
||||
Role: string(role),
|
||||
}
|
||||
var req setRequest
|
||||
var err error
|
||||
req = c.raw.ObjectAccessControls.Update(bucket, object, string(entity), acl)
|
||||
configureACLCall(ctx, s.userProject, req)
|
||||
return run(ctx, func() error {
|
||||
_, err = req.Do()
|
||||
return err
|
||||
}, s.retry, s.idempotent, setRetryHeaderHTTP(req))
|
||||
}
|
||||
|
||||
// Media operations.
|
||||
|
||||
func (c *httpStorageClient) ComposeObject(ctx context.Context, req *composeObjectRequest, opts ...storageOption) (*ObjectAttrs, error) {
|
||||
return nil, errMethodNotSupported
|
||||
s := callSettings(c.settings, opts...)
|
||||
rawReq := &raw.ComposeRequest{}
|
||||
// Compose requires a non-empty Destination, so we always set it,
|
||||
// even if the caller-provided ObjectAttrs is the zero value.
|
||||
rawReq.Destination = req.dstObject.attrs.toRawObject(req.dstBucket)
|
||||
if req.sendCRC32C {
|
||||
rawReq.Destination.Crc32c = encodeUint32(req.dstObject.attrs.CRC32C)
|
||||
}
|
||||
for _, src := range req.srcs {
|
||||
srcObj := &raw.ComposeRequestSourceObjects{
|
||||
Name: src.name,
|
||||
}
|
||||
if err := applyConds("ComposeFrom source", src.gen, src.conds, composeSourceObj{srcObj}); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
rawReq.SourceObjects = append(rawReq.SourceObjects, srcObj)
|
||||
}
|
||||
|
||||
call := c.raw.Objects.Compose(req.dstBucket, req.dstObject.name, rawReq).Context(ctx)
|
||||
if err := applyConds("ComposeFrom destination", -1, req.dstObject.conds, call); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if s.userProject != "" {
|
||||
call.UserProject(s.userProject)
|
||||
}
|
||||
if req.predefinedACL != "" {
|
||||
call.DestinationPredefinedAcl(req.predefinedACL)
|
||||
}
|
||||
if err := setEncryptionHeaders(call.Header(), req.encryptionKey, false); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
var obj *raw.Object
|
||||
setClientHeader(call.Header())
|
||||
|
||||
var err error
|
||||
retryCall := func() error { obj, err = call.Do(); return err }
|
||||
|
||||
if err := run(ctx, retryCall, s.retry, s.idempotent, setRetryHeaderHTTP(call)); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return newObject(obj), nil
|
||||
}
|
||||
func (c *httpStorageClient) RewriteObject(ctx context.Context, req *rewriteObjectRequest, opts ...storageOption) (*rewriteObjectResponse, error) {
|
||||
return nil, errMethodNotSupported
|
||||
s := callSettings(c.settings, opts...)
|
||||
rawObject := req.dstObject.attrs.toRawObject("")
|
||||
call := c.raw.Objects.Rewrite(req.srcObject.bucket, req.srcObject.name, req.dstObject.bucket, req.dstObject.name, rawObject)
|
||||
|
||||
call.Context(ctx).Projection("full")
|
||||
if req.token != "" {
|
||||
call.RewriteToken(req.token)
|
||||
}
|
||||
if req.dstObject.keyName != "" {
|
||||
call.DestinationKmsKeyName(req.dstObject.keyName)
|
||||
}
|
||||
if req.predefinedACL != "" {
|
||||
call.DestinationPredefinedAcl(req.predefinedACL)
|
||||
}
|
||||
if err := applyConds("Copy destination", defaultGen, req.dstObject.conds, call); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if err := applySourceConds(req.srcObject.gen, req.srcObject.conds, call); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if s.userProject != "" {
|
||||
call.UserProject(s.userProject)
|
||||
}
|
||||
// Set destination encryption headers.
|
||||
if err := setEncryptionHeaders(call.Header(), req.dstObject.encryptionKey, false); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
// Set source encryption headers.
|
||||
if err := setEncryptionHeaders(call.Header(), req.srcObject.encryptionKey, true); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
var res *raw.RewriteResponse
|
||||
var err error
|
||||
setClientHeader(call.Header())
|
||||
|
||||
retryCall := func() error { res, err = call.Do(); return err }
|
||||
|
||||
if err := run(ctx, retryCall, s.retry, s.idempotent, setRetryHeaderHTTP(call)); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
r := &rewriteObjectResponse{
|
||||
done: res.Done,
|
||||
written: res.TotalBytesRewritten,
|
||||
token: res.RewriteToken,
|
||||
resource: newObject(res.Resource),
|
||||
}
|
||||
|
||||
return r, nil
|
||||
}
|
||||
|
||||
func (c *httpStorageClient) NewRangeReader(ctx context.Context, params *newRangeReaderParams, opts ...storageOption) (r *Reader, err error) {
|
||||
|
@ -1006,20 +1126,139 @@ func (c *httpStorageClient) TestIamPermissions(ctx context.Context, resource str
|
|||
|
||||
// HMAC Key methods.
|
||||
|
||||
func (c *httpStorageClient) GetHMACKey(ctx context.Context, desc *hmacKeyDesc, opts ...storageOption) (*HMACKey, error) {
|
||||
return nil, errMethodNotSupported
|
||||
func (c *httpStorageClient) GetHMACKey(ctx context.Context, project, accessID string, opts ...storageOption) (*HMACKey, error) {
|
||||
s := callSettings(c.settings, opts...)
|
||||
call := c.raw.Projects.HmacKeys.Get(project, accessID)
|
||||
if s.userProject != "" {
|
||||
call = call.UserProject(s.userProject)
|
||||
}
|
||||
|
||||
var metadata *raw.HmacKeyMetadata
|
||||
var err error
|
||||
if err := run(ctx, func() error {
|
||||
metadata, err = call.Context(ctx).Do()
|
||||
return err
|
||||
}, s.retry, s.idempotent, setRetryHeaderHTTP(call)); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
hk := &raw.HmacKey{
|
||||
Metadata: metadata,
|
||||
}
|
||||
return toHMACKeyFromRaw(hk, false)
|
||||
}
|
||||
func (c *httpStorageClient) ListHMACKey(ctx context.Context, desc *hmacKeyDesc, opts ...storageOption) *HMACKeysIterator {
|
||||
return &HMACKeysIterator{}
|
||||
|
||||
func (c *httpStorageClient) ListHMACKeys(ctx context.Context, project, serviceAccountEmail string, showDeletedKeys bool, opts ...storageOption) *HMACKeysIterator {
|
||||
s := callSettings(c.settings, opts...)
|
||||
it := &HMACKeysIterator{
|
||||
ctx: ctx,
|
||||
raw: c.raw.Projects.HmacKeys,
|
||||
projectID: project,
|
||||
retry: s.retry,
|
||||
}
|
||||
fetch := func(pageSize int, pageToken string) (token string, err error) {
|
||||
call := c.raw.Projects.HmacKeys.List(project)
|
||||
setClientHeader(call.Header())
|
||||
if pageToken != "" {
|
||||
call = call.PageToken(pageToken)
|
||||
}
|
||||
if pageSize > 0 {
|
||||
call = call.MaxResults(int64(pageSize))
|
||||
}
|
||||
if showDeletedKeys {
|
||||
call = call.ShowDeletedKeys(true)
|
||||
}
|
||||
if s.userProject != "" {
|
||||
call = call.UserProject(s.userProject)
|
||||
}
|
||||
if serviceAccountEmail != "" {
|
||||
call = call.ServiceAccountEmail(serviceAccountEmail)
|
||||
}
|
||||
|
||||
var resp *raw.HmacKeysMetadata
|
||||
err = run(it.ctx, func() error {
|
||||
resp, err = call.Context(it.ctx).Do()
|
||||
return err
|
||||
}, s.retry, s.idempotent, setRetryHeaderHTTP(call))
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
|
||||
for _, metadata := range resp.Items {
|
||||
hk := &raw.HmacKey{
|
||||
Metadata: metadata,
|
||||
}
|
||||
hkey, err := toHMACKeyFromRaw(hk, true)
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
it.hmacKeys = append(it.hmacKeys, hkey)
|
||||
}
|
||||
return resp.NextPageToken, nil
|
||||
}
|
||||
|
||||
it.pageInfo, it.nextFunc = iterator.NewPageInfo(
|
||||
fetch,
|
||||
func() int { return len(it.hmacKeys) - it.index },
|
||||
func() interface{} {
|
||||
prev := it.hmacKeys
|
||||
it.hmacKeys = it.hmacKeys[:0]
|
||||
it.index = 0
|
||||
return prev
|
||||
})
|
||||
return it
|
||||
}
|
||||
func (c *httpStorageClient) UpdateHMACKey(ctx context.Context, desc *hmacKeyDesc, attrs *HMACKeyAttrsToUpdate, opts ...storageOption) (*HMACKey, error) {
|
||||
return nil, errMethodNotSupported
|
||||
|
||||
func (c *httpStorageClient) UpdateHMACKey(ctx context.Context, project, serviceAccountEmail, accessID string, attrs *HMACKeyAttrsToUpdate, opts ...storageOption) (*HMACKey, error) {
|
||||
s := callSettings(c.settings, opts...)
|
||||
call := c.raw.Projects.HmacKeys.Update(project, accessID, &raw.HmacKeyMetadata{
|
||||
Etag: attrs.Etag,
|
||||
State: string(attrs.State),
|
||||
})
|
||||
if s.userProject != "" {
|
||||
call = call.UserProject(s.userProject)
|
||||
}
|
||||
|
||||
var metadata *raw.HmacKeyMetadata
|
||||
var err error
|
||||
if err := run(ctx, func() error {
|
||||
metadata, err = call.Context(ctx).Do()
|
||||
return err
|
||||
}, s.retry, s.idempotent, setRetryHeaderHTTP(call)); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
hk := &raw.HmacKey{
|
||||
Metadata: metadata,
|
||||
}
|
||||
return toHMACKeyFromRaw(hk, false)
|
||||
}
|
||||
func (c *httpStorageClient) CreateHMACKey(ctx context.Context, desc *hmacKeyDesc, opts ...storageOption) (*HMACKey, error) {
|
||||
return nil, errMethodNotSupported
|
||||
|
||||
func (c *httpStorageClient) CreateHMACKey(ctx context.Context, project, serviceAccountEmail string, opts ...storageOption) (*HMACKey, error) {
|
||||
s := callSettings(c.settings, opts...)
|
||||
call := c.raw.Projects.HmacKeys.Create(project, serviceAccountEmail)
|
||||
if s.userProject != "" {
|
||||
call = call.UserProject(s.userProject)
|
||||
}
|
||||
|
||||
var hk *raw.HmacKey
|
||||
if err := run(ctx, func() error {
|
||||
h, err := call.Context(ctx).Do()
|
||||
hk = h
|
||||
return err
|
||||
}, s.retry, s.idempotent, setRetryHeaderHTTP(call)); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return toHMACKeyFromRaw(hk, true)
|
||||
}
|
||||
func (c *httpStorageClient) DeleteHMACKey(ctx context.Context, desc *hmacKeyDesc, opts ...storageOption) error {
|
||||
return errMethodNotSupported
|
||||
|
||||
func (c *httpStorageClient) DeleteHMACKey(ctx context.Context, project string, accessID string, opts ...storageOption) error {
|
||||
s := callSettings(c.settings, opts...)
|
||||
call := c.raw.Projects.HmacKeys.Delete(project, accessID)
|
||||
if s.userProject != "" {
|
||||
call = call.UserProject(s.userProject)
|
||||
}
|
||||
return run(ctx, func() error {
|
||||
return call.Context(ctx).Do()
|
||||
}, s.retry, s.idempotent, setRetryHeaderHTTP(call))
|
||||
}
|
||||
|
||||
// Notification methods.
|
||||
|
|
2
vendor/cloud.google.com/go/storage/internal/apiv2/doc.go
generated
vendored
2
vendor/cloud.google.com/go/storage/internal/apiv2/doc.go
generated
vendored
|
@ -48,7 +48,7 @@
|
|||
//
|
||||
// req := &storagepb.DeleteBucketRequest{
|
||||
// // TODO: Fill request struct fields.
|
||||
// // See https://pkg.go.dev/google.golang.org/genproto/googleapis/storage/v2#DeleteBucketRequest.
|
||||
// // See https://pkg.go.dev/cloud.google.com/go/storage/internal/apiv2/stubs#DeleteBucketRequest.
|
||||
// }
|
||||
// err = c.DeleteBucket(ctx, req)
|
||||
// if err != nil {
|
||||
|
|
2
vendor/cloud.google.com/go/storage/internal/apiv2/storage_client.go
generated
vendored
2
vendor/cloud.google.com/go/storage/internal/apiv2/storage_client.go
generated
vendored
|
@ -20,13 +20,13 @@ import (
|
|||
"context"
|
||||
"math"
|
||||
|
||||
storagepb "cloud.google.com/go/storage/internal/apiv2/stubs"
|
||||
gax "github.com/googleapis/gax-go/v2"
|
||||
"google.golang.org/api/iterator"
|
||||
"google.golang.org/api/option"
|
||||
"google.golang.org/api/option/internaloption"
|
||||
gtransport "google.golang.org/api/transport/grpc"
|
||||
iampb "google.golang.org/genproto/googleapis/iam/v1"
|
||||
storagepb "google.golang.org/genproto/googleapis/storage/v2"
|
||||
"google.golang.org/grpc"
|
||||
"google.golang.org/grpc/metadata"
|
||||
"google.golang.org/protobuf/proto"
|
||||
|
|
|
@ -25,17 +25,17 @@ import (
|
|||
reflect "reflect"
|
||||
sync "sync"
|
||||
|
||||
empty "github.com/golang/protobuf/ptypes/empty"
|
||||
timestamp "github.com/golang/protobuf/ptypes/timestamp"
|
||||
_ "google.golang.org/genproto/googleapis/api/annotations"
|
||||
v1 "google.golang.org/genproto/googleapis/iam/v1"
|
||||
date "google.golang.org/genproto/googleapis/type/date"
|
||||
field_mask "google.golang.org/genproto/protobuf/field_mask"
|
||||
grpc "google.golang.org/grpc"
|
||||
codes "google.golang.org/grpc/codes"
|
||||
status "google.golang.org/grpc/status"
|
||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||
emptypb "google.golang.org/protobuf/types/known/emptypb"
|
||||
fieldmaskpb "google.golang.org/protobuf/types/known/fieldmaskpb"
|
||||
timestamppb "google.golang.org/protobuf/types/known/timestamppb"
|
||||
)
|
||||
|
||||
const (
|
||||
|
@ -264,7 +264,7 @@ type GetBucketRequest struct {
|
|||
// Mask specifying which fields to read.
|
||||
// A "*" field may be used to indicate all fields.
|
||||
// If no mask is specified, will default to all fields.
|
||||
ReadMask *fieldmaskpb.FieldMask `protobuf:"bytes,5,opt,name=read_mask,json=readMask,proto3,oneof" json:"read_mask,omitempty"`
|
||||
ReadMask *field_mask.FieldMask `protobuf:"bytes,5,opt,name=read_mask,json=readMask,proto3,oneof" json:"read_mask,omitempty"`
|
||||
}
|
||||
|
||||
func (x *GetBucketRequest) Reset() {
|
||||
|
@ -320,7 +320,7 @@ func (x *GetBucketRequest) GetIfMetagenerationNotMatch() int64 {
|
|||
return 0
|
||||
}
|
||||
|
||||
func (x *GetBucketRequest) GetReadMask() *fieldmaskpb.FieldMask {
|
||||
func (x *GetBucketRequest) GetReadMask() *field_mask.FieldMask {
|
||||
if x != nil {
|
||||
return x.ReadMask
|
||||
}
|
||||
|
@ -443,7 +443,7 @@ type ListBucketsRequest struct {
|
|||
// If no mask is specified, will default to all fields except items.owner,
|
||||
// items.acl, and items.default_object_acl.
|
||||
// * may be used to mean "all fields".
|
||||
ReadMask *fieldmaskpb.FieldMask `protobuf:"bytes,5,opt,name=read_mask,json=readMask,proto3,oneof" json:"read_mask,omitempty"`
|
||||
ReadMask *field_mask.FieldMask `protobuf:"bytes,5,opt,name=read_mask,json=readMask,proto3,oneof" json:"read_mask,omitempty"`
|
||||
}
|
||||
|
||||
func (x *ListBucketsRequest) Reset() {
|
||||
|
@ -506,7 +506,7 @@ func (x *ListBucketsRequest) GetPrefix() string {
|
|||
return ""
|
||||
}
|
||||
|
||||
func (x *ListBucketsRequest) GetReadMask() *fieldmaskpb.FieldMask {
|
||||
func (x *ListBucketsRequest) GetReadMask() *field_mask.FieldMask {
|
||||
if x != nil {
|
||||
return x.ReadMask
|
||||
}
|
||||
|
@ -664,7 +664,7 @@ type UpdateBucketRequest struct {
|
|||
// Not specifying any fields is an error.
|
||||
// Not specifying a field while setting that field to a non-default value is
|
||||
// an error.
|
||||
UpdateMask *fieldmaskpb.FieldMask `protobuf:"bytes,6,opt,name=update_mask,json=updateMask,proto3" json:"update_mask,omitempty"`
|
||||
UpdateMask *field_mask.FieldMask `protobuf:"bytes,6,opt,name=update_mask,json=updateMask,proto3" json:"update_mask,omitempty"`
|
||||
}
|
||||
|
||||
func (x *UpdateBucketRequest) Reset() {
|
||||
|
@ -734,7 +734,7 @@ func (x *UpdateBucketRequest) GetPredefinedDefaultObjectAcl() string {
|
|||
return ""
|
||||
}
|
||||
|
||||
func (x *UpdateBucketRequest) GetUpdateMask() *fieldmaskpb.FieldMask {
|
||||
func (x *UpdateBucketRequest) GetUpdateMask() *field_mask.FieldMask {
|
||||
if x != nil {
|
||||
return x.UpdateMask
|
||||
}
|
||||
|
@ -1328,7 +1328,7 @@ type ReadObjectRequest struct {
|
|||
// If no mask is specified, will default to all fields except metadata.owner
|
||||
// and metadata.acl.
|
||||
// * may be used to mean "all fields".
|
||||
ReadMask *fieldmaskpb.FieldMask `protobuf:"bytes,12,opt,name=read_mask,json=readMask,proto3,oneof" json:"read_mask,omitempty"`
|
||||
ReadMask *field_mask.FieldMask `protobuf:"bytes,12,opt,name=read_mask,json=readMask,proto3,oneof" json:"read_mask,omitempty"`
|
||||
}
|
||||
|
||||
func (x *ReadObjectRequest) Reset() {
|
||||
|
@ -1433,7 +1433,7 @@ func (x *ReadObjectRequest) GetCommonObjectRequestParams() *CommonObjectRequestP
|
|||
return nil
|
||||
}
|
||||
|
||||
func (x *ReadObjectRequest) GetReadMask() *fieldmaskpb.FieldMask {
|
||||
func (x *ReadObjectRequest) GetReadMask() *field_mask.FieldMask {
|
||||
if x != nil {
|
||||
return x.ReadMask
|
||||
}
|
||||
|
@ -1474,7 +1474,7 @@ type GetObjectRequest struct {
|
|||
// If no mask is specified, will default to all fields except metadata.acl and
|
||||
// metadata.owner.
|
||||
// * may be used to mean "all fields".
|
||||
ReadMask *fieldmaskpb.FieldMask `protobuf:"bytes,10,opt,name=read_mask,json=readMask,proto3,oneof" json:"read_mask,omitempty"`
|
||||
ReadMask *field_mask.FieldMask `protobuf:"bytes,10,opt,name=read_mask,json=readMask,proto3,oneof" json:"read_mask,omitempty"`
|
||||
}
|
||||
|
||||
func (x *GetObjectRequest) Reset() {
|
||||
|
@ -1565,7 +1565,7 @@ func (x *GetObjectRequest) GetCommonObjectRequestParams() *CommonObjectRequestPa
|
|||
return nil
|
||||
}
|
||||
|
||||
func (x *GetObjectRequest) GetReadMask() *fieldmaskpb.FieldMask {
|
||||
func (x *GetObjectRequest) GetReadMask() *field_mask.FieldMask {
|
||||
if x != nil {
|
||||
return x.ReadMask
|
||||
}
|
||||
|
@ -2058,7 +2058,7 @@ type ListObjectsRequest struct {
|
|||
// If no mask is specified, will default to all fields except items.acl and
|
||||
// items.owner.
|
||||
// * may be used to mean "all fields".
|
||||
ReadMask *fieldmaskpb.FieldMask `protobuf:"bytes,8,opt,name=read_mask,json=readMask,proto3,oneof" json:"read_mask,omitempty"`
|
||||
ReadMask *field_mask.FieldMask `protobuf:"bytes,8,opt,name=read_mask,json=readMask,proto3,oneof" json:"read_mask,omitempty"`
|
||||
// Filter results to objects whose names are lexicographically equal to or
|
||||
// after lexicographic_start. If lexicographic_end is also set, the objects
|
||||
// listed have names between lexicographic_start (inclusive) and
|
||||
|
@ -2152,7 +2152,7 @@ func (x *ListObjectsRequest) GetVersions() bool {
|
|||
return false
|
||||
}
|
||||
|
||||
func (x *ListObjectsRequest) GetReadMask() *fieldmaskpb.FieldMask {
|
||||
func (x *ListObjectsRequest) GetReadMask() *field_mask.FieldMask {
|
||||
if x != nil {
|
||||
return x.ReadMask
|
||||
}
|
||||
|
@ -2851,7 +2851,7 @@ type UpdateObjectRequest struct {
|
|||
// Not specifying any fields is an error.
|
||||
// Not specifying a field while setting that field to a non-default value is
|
||||
// an error.
|
||||
UpdateMask *fieldmaskpb.FieldMask `protobuf:"bytes,7,opt,name=update_mask,json=updateMask,proto3" json:"update_mask,omitempty"`
|
||||
UpdateMask *field_mask.FieldMask `protobuf:"bytes,7,opt,name=update_mask,json=updateMask,proto3" json:"update_mask,omitempty"`
|
||||
// A set of parameters common to Storage API requests concerning an object.
|
||||
CommonObjectRequestParams *CommonObjectRequestParams `protobuf:"bytes,8,opt,name=common_object_request_params,json=commonObjectRequestParams,proto3" json:"common_object_request_params,omitempty"`
|
||||
}
|
||||
|
@ -2930,7 +2930,7 @@ func (x *UpdateObjectRequest) GetPredefinedAcl() string {
|
|||
return ""
|
||||
}
|
||||
|
||||
func (x *UpdateObjectRequest) GetUpdateMask() *fieldmaskpb.FieldMask {
|
||||
func (x *UpdateObjectRequest) GetUpdateMask() *field_mask.FieldMask {
|
||||
if x != nil {
|
||||
return x.UpdateMask
|
||||
}
|
||||
|
@ -3382,7 +3382,7 @@ type UpdateHmacKeyRequest struct {
|
|||
// identify the key.
|
||||
HmacKey *HmacKeyMetadata `protobuf:"bytes,1,opt,name=hmac_key,json=hmacKey,proto3" json:"hmac_key,omitempty"`
|
||||
// Update mask for hmac_key.
|
||||
UpdateMask *fieldmaskpb.FieldMask `protobuf:"bytes,3,opt,name=update_mask,json=updateMask,proto3" json:"update_mask,omitempty"`
|
||||
UpdateMask *field_mask.FieldMask `protobuf:"bytes,3,opt,name=update_mask,json=updateMask,proto3" json:"update_mask,omitempty"`
|
||||
}
|
||||
|
||||
func (x *UpdateHmacKeyRequest) Reset() {
|
||||
|
@ -3424,7 +3424,7 @@ func (x *UpdateHmacKeyRequest) GetHmacKey() *HmacKeyMetadata {
|
|||
return nil
|
||||
}
|
||||
|
||||
func (x *UpdateHmacKeyRequest) GetUpdateMask() *fieldmaskpb.FieldMask {
|
||||
func (x *UpdateHmacKeyRequest) GetUpdateMask() *field_mask.FieldMask {
|
||||
if x != nil {
|
||||
return x.UpdateMask
|
||||
}
|
||||
|
@ -3599,14 +3599,14 @@ type Bucket struct {
|
|||
// Output only. The creation time of the bucket.
|
||||
// Attempting to set or update this field will result in a
|
||||
// [FieldViolation][google.rpc.BadRequest.FieldViolation].
|
||||
CreateTime *timestamppb.Timestamp `protobuf:"bytes,11,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"`
|
||||
CreateTime *timestamp.Timestamp `protobuf:"bytes,11,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"`
|
||||
// The bucket's [https://www.w3.org/TR/cors/][Cross-Origin Resource Sharing]
|
||||
// (CORS) config.
|
||||
Cors []*Bucket_Cors `protobuf:"bytes,12,rep,name=cors,proto3" json:"cors,omitempty"`
|
||||
// Output only. The modification time of the bucket.
|
||||
// Attempting to set or update this field will result in a
|
||||
// [FieldViolation][google.rpc.BadRequest.FieldViolation].
|
||||
UpdateTime *timestamppb.Timestamp `protobuf:"bytes,13,opt,name=update_time,json=updateTime,proto3" json:"update_time,omitempty"`
|
||||
UpdateTime *timestamp.Timestamp `protobuf:"bytes,13,opt,name=update_time,json=updateTime,proto3" json:"update_time,omitempty"`
|
||||
// The default value for event-based hold on newly created objects in this
|
||||
// bucket. Event-based hold is a way to retain objects indefinitely until an
|
||||
// event occurs, signified by the
|
||||
|
@ -3777,7 +3777,7 @@ func (x *Bucket) GetLifecycle() *Bucket_Lifecycle {
|
|||
return nil
|
||||
}
|
||||
|
||||
func (x *Bucket) GetCreateTime() *timestamppb.Timestamp {
|
||||
func (x *Bucket) GetCreateTime() *timestamp.Timestamp {
|
||||
if x != nil {
|
||||
return x.CreateTime
|
||||
}
|
||||
|
@ -3791,7 +3791,7 @@ func (x *Bucket) GetCors() []*Bucket_Cors {
|
|||
return nil
|
||||
}
|
||||
|
||||
func (x *Bucket) GetUpdateTime() *timestamppb.Timestamp {
|
||||
func (x *Bucket) GetUpdateTime() *timestamp.Timestamp {
|
||||
if x != nil {
|
||||
return x.UpdateTime
|
||||
}
|
||||
|
@ -4161,9 +4161,9 @@ type HmacKeyMetadata struct {
|
|||
// State of the key. One of ACTIVE, INACTIVE, or DELETED.
|
||||
State string `protobuf:"bytes,5,opt,name=state,proto3" json:"state,omitempty"`
|
||||
// The creation time of the HMAC key.
|
||||
CreateTime *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"`
|
||||
CreateTime *timestamp.Timestamp `protobuf:"bytes,6,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"`
|
||||
// The last modification time of the HMAC key metadata.
|
||||
UpdateTime *timestamppb.Timestamp `protobuf:"bytes,7,opt,name=update_time,json=updateTime,proto3" json:"update_time,omitempty"`
|
||||
UpdateTime *timestamp.Timestamp `protobuf:"bytes,7,opt,name=update_time,json=updateTime,proto3" json:"update_time,omitempty"`
|
||||
// The etag of the HMAC key.
|
||||
Etag string `protobuf:"bytes,8,opt,name=etag,proto3" json:"etag,omitempty"`
|
||||
}
|
||||
|
@ -4235,14 +4235,14 @@ func (x *HmacKeyMetadata) GetState() string {
|
|||
return ""
|
||||
}
|
||||
|
||||
func (x *HmacKeyMetadata) GetCreateTime() *timestamppb.Timestamp {
|
||||
func (x *HmacKeyMetadata) GetCreateTime() *timestamp.Timestamp {
|
||||
if x != nil {
|
||||
return x.CreateTime
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *HmacKeyMetadata) GetUpdateTime() *timestamppb.Timestamp {
|
||||
func (x *HmacKeyMetadata) GetUpdateTime() *timestamp.Timestamp {
|
||||
if x != nil {
|
||||
return x.UpdateTime
|
||||
}
|
||||
|
@ -4489,7 +4489,7 @@ type Object struct {
|
|||
// version of the object has been deleted.
|
||||
// Attempting to set or update this field will result in a
|
||||
// [FieldViolation][google.rpc.BadRequest.FieldViolation].
|
||||
DeleteTime *timestamppb.Timestamp `protobuf:"bytes,12,opt,name=delete_time,json=deleteTime,proto3" json:"delete_time,omitempty"`
|
||||
DeleteTime *timestamp.Timestamp `protobuf:"bytes,12,opt,name=delete_time,json=deleteTime,proto3" json:"delete_time,omitempty"`
|
||||
// Content-Type of the object data, matching
|
||||
// [https://tools.ietf.org/html/rfc7231#section-3.1.1.5][RFC 7231 §3.1.1.5].
|
||||
// If an object is stored without a Content-Type, it is served as
|
||||
|
@ -4498,7 +4498,7 @@ type Object struct {
|
|||
// Output only. The creation time of the object.
|
||||
// Attempting to set or update this field will result in a
|
||||
// [FieldViolation][google.rpc.BadRequest.FieldViolation].
|
||||
CreateTime *timestamppb.Timestamp `protobuf:"bytes,14,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"`
|
||||
CreateTime *timestamp.Timestamp `protobuf:"bytes,14,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"`
|
||||
// Output only. Number of underlying components that make up this object. Components are
|
||||
// accumulated by compose operations.
|
||||
// Attempting to set or update this field will result in a
|
||||
|
@ -4509,7 +4509,7 @@ type Object struct {
|
|||
// Output only. The modification time of the object metadata.
|
||||
// Attempting to set or update this field will result in a
|
||||
// [FieldViolation][google.rpc.BadRequest.FieldViolation].
|
||||
UpdateTime *timestamppb.Timestamp `protobuf:"bytes,17,opt,name=update_time,json=updateTime,proto3" json:"update_time,omitempty"`
|
||||
UpdateTime *timestamp.Timestamp `protobuf:"bytes,17,opt,name=update_time,json=updateTime,proto3" json:"update_time,omitempty"`
|
||||
// Cloud KMS Key used to encrypt this object, if the object is encrypted by
|
||||
// such a key.
|
||||
KmsKey string `protobuf:"bytes,18,opt,name=kms_key,json=kmsKey,proto3" json:"kms_key,omitempty"`
|
||||
|
@ -4517,7 +4517,7 @@ type Object struct {
|
|||
// object is initially created, it will be set to time_created.
|
||||
// Attempting to set or update this field will result in a
|
||||
// [FieldViolation][google.rpc.BadRequest.FieldViolation].
|
||||
UpdateStorageClassTime *timestamppb.Timestamp `protobuf:"bytes,19,opt,name=update_storage_class_time,json=updateStorageClassTime,proto3" json:"update_storage_class_time,omitempty"`
|
||||
UpdateStorageClassTime *timestamp.Timestamp `protobuf:"bytes,19,opt,name=update_storage_class_time,json=updateStorageClassTime,proto3" json:"update_storage_class_time,omitempty"`
|
||||
// Whether an object is under temporary hold. While this flag is set to true,
|
||||
// the object is protected against deletion and overwrites. A common use case
|
||||
// of this flag is regulatory investigations where objects need to be retained
|
||||
|
@ -4531,7 +4531,7 @@ type Object struct {
|
|||
// Note 2: This value can be provided even when temporary hold is set (so that
|
||||
// the user can reason about policy without having to first unset the
|
||||
// temporary hold).
|
||||
RetentionExpireTime *timestamppb.Timestamp `protobuf:"bytes,21,opt,name=retention_expire_time,json=retentionExpireTime,proto3" json:"retention_expire_time,omitempty"`
|
||||
RetentionExpireTime *timestamp.Timestamp `protobuf:"bytes,21,opt,name=retention_expire_time,json=retentionExpireTime,proto3" json:"retention_expire_time,omitempty"`
|
||||
// User-provided metadata, in key/value pairs.
|
||||
Metadata map[string]string `protobuf:"bytes,22,rep,name=metadata,proto3" json:"metadata,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
|
||||
// Whether an object is under event-based hold.
|
||||
|
@ -4554,7 +4554,7 @@ type Object struct {
|
|||
// such a key.
|
||||
CustomerEncryption *CustomerEncryption `protobuf:"bytes,25,opt,name=customer_encryption,json=customerEncryption,proto3" json:"customer_encryption,omitempty"`
|
||||
// A user-specified timestamp set on an object.
|
||||
CustomTime *timestamppb.Timestamp `protobuf:"bytes,26,opt,name=custom_time,json=customTime,proto3" json:"custom_time,omitempty"`
|
||||
CustomTime *timestamp.Timestamp `protobuf:"bytes,26,opt,name=custom_time,json=customTime,proto3" json:"custom_time,omitempty"`
|
||||
}
|
||||
|
||||
func (x *Object) Reset() {
|
||||
|
@ -4673,7 +4673,7 @@ func (x *Object) GetContentLanguage() string {
|
|||
return ""
|
||||
}
|
||||
|
||||
func (x *Object) GetDeleteTime() *timestamppb.Timestamp {
|
||||
func (x *Object) GetDeleteTime() *timestamp.Timestamp {
|
||||
if x != nil {
|
||||
return x.DeleteTime
|
||||
}
|
||||
|
@ -4687,7 +4687,7 @@ func (x *Object) GetContentType() string {
|
|||
return ""
|
||||
}
|
||||
|
||||
func (x *Object) GetCreateTime() *timestamppb.Timestamp {
|
||||
func (x *Object) GetCreateTime() *timestamp.Timestamp {
|
||||
if x != nil {
|
||||
return x.CreateTime
|
||||
}
|
||||
|
@ -4708,7 +4708,7 @@ func (x *Object) GetChecksums() *ObjectChecksums {
|
|||
return nil
|
||||
}
|
||||
|
||||
func (x *Object) GetUpdateTime() *timestamppb.Timestamp {
|
||||
func (x *Object) GetUpdateTime() *timestamp.Timestamp {
|
||||
if x != nil {
|
||||
return x.UpdateTime
|
||||
}
|
||||
|
@ -4722,7 +4722,7 @@ func (x *Object) GetKmsKey() string {
|
|||
return ""
|
||||
}
|
||||
|
||||
func (x *Object) GetUpdateStorageClassTime() *timestamppb.Timestamp {
|
||||
func (x *Object) GetUpdateStorageClassTime() *timestamp.Timestamp {
|
||||
if x != nil {
|
||||
return x.UpdateStorageClassTime
|
||||
}
|
||||
|
@ -4736,7 +4736,7 @@ func (x *Object) GetTemporaryHold() bool {
|
|||
return false
|
||||
}
|
||||
|
||||
func (x *Object) GetRetentionExpireTime() *timestamppb.Timestamp {
|
||||
func (x *Object) GetRetentionExpireTime() *timestamp.Timestamp {
|
||||
if x != nil {
|
||||
return x.RetentionExpireTime
|
||||
}
|
||||
|
@ -4771,7 +4771,7 @@ func (x *Object) GetCustomerEncryption() *CustomerEncryption {
|
|||
return nil
|
||||
}
|
||||
|
||||
func (x *Object) GetCustomTime() *timestamppb.Timestamp {
|
||||
func (x *Object) GetCustomTime() *timestamp.Timestamp {
|
||||
if x != nil {
|
||||
return x.CustomTime
|
||||
}
|
||||
|
@ -5692,7 +5692,7 @@ type Bucket_RetentionPolicy struct {
|
|||
|
||||
// Server-determined value that indicates the time from which policy was
|
||||
// enforced and effective.
|
||||
EffectiveTime *timestamppb.Timestamp `protobuf:"bytes,1,opt,name=effective_time,json=effectiveTime,proto3" json:"effective_time,omitempty"`
|
||||
EffectiveTime *timestamp.Timestamp `protobuf:"bytes,1,opt,name=effective_time,json=effectiveTime,proto3" json:"effective_time,omitempty"`
|
||||
// Once locked, an object retention policy cannot be modified.
|
||||
IsLocked bool `protobuf:"varint,2,opt,name=is_locked,json=isLocked,proto3" json:"is_locked,omitempty"`
|
||||
// The duration in seconds that objects need to be retained. Retention
|
||||
|
@ -5734,7 +5734,7 @@ func (*Bucket_RetentionPolicy) Descriptor() ([]byte, []int) {
|
|||
return file_google_storage_v2_storage_proto_rawDescGZIP(), []int{38, 6}
|
||||
}
|
||||
|
||||
func (x *Bucket_RetentionPolicy) GetEffectiveTime() *timestamppb.Timestamp {
|
||||
func (x *Bucket_RetentionPolicy) GetEffectiveTime() *timestamp.Timestamp {
|
||||
if x != nil {
|
||||
return x.EffectiveTime
|
||||
}
|
||||
|
@ -5936,7 +5936,7 @@ type Bucket_Autoclass struct {
|
|||
// disabled/unconfigured or set to false after being enabled. If Autoclass
|
||||
// is enabled when the bucket is created, the toggle_time is set to the
|
||||
// bucket creation time.
|
||||
ToggleTime *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=toggle_time,json=toggleTime,proto3" json:"toggle_time,omitempty"`
|
||||
ToggleTime *timestamp.Timestamp `protobuf:"bytes,2,opt,name=toggle_time,json=toggleTime,proto3" json:"toggle_time,omitempty"`
|
||||
}
|
||||
|
||||
func (x *Bucket_Autoclass) Reset() {
|
||||
|
@ -5978,7 +5978,7 @@ func (x *Bucket_Autoclass) GetEnabled() bool {
|
|||
return false
|
||||
}
|
||||
|
||||
func (x *Bucket_Autoclass) GetToggleTime() *timestamppb.Timestamp {
|
||||
func (x *Bucket_Autoclass) GetToggleTime() *timestamp.Timestamp {
|
||||
if x != nil {
|
||||
return x.ToggleTime
|
||||
}
|
||||
|
@ -5997,7 +5997,7 @@ type Bucket_IamConfig_UniformBucketLevelAccess struct {
|
|||
// The deadline time for changing
|
||||
// `iamConfig.uniformBucketLevelAccess.enabled` from `true` to `false`.
|
||||
// Mutable until the specified deadline is reached, but not afterward.
|
||||
LockTime *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=lock_time,json=lockTime,proto3" json:"lock_time,omitempty"`
|
||||
LockTime *timestamp.Timestamp `protobuf:"bytes,2,opt,name=lock_time,json=lockTime,proto3" json:"lock_time,omitempty"`
|
||||
}
|
||||
|
||||
func (x *Bucket_IamConfig_UniformBucketLevelAccess) Reset() {
|
||||
|
@ -6039,7 +6039,7 @@ func (x *Bucket_IamConfig_UniformBucketLevelAccess) GetEnabled() bool {
|
|||
return false
|
||||
}
|
||||
|
||||
func (x *Bucket_IamConfig_UniformBucketLevelAccess) GetLockTime() *timestamppb.Timestamp {
|
||||
func (x *Bucket_IamConfig_UniformBucketLevelAccess) GetLockTime() *timestamp.Timestamp {
|
||||
if x != nil {
|
||||
return x.LockTime
|
||||
}
|
||||
|
@ -7925,13 +7925,13 @@ var file_google_storage_v2_storage_proto_goTypes = []interface{}{
|
|||
(*Bucket_Lifecycle_Rule_Condition)(nil), // 70: google.storage.v2.Bucket.Lifecycle.Rule.Condition
|
||||
nil, // 71: google.storage.v2.Notification.CustomAttributesEntry
|
||||
nil, // 72: google.storage.v2.Object.MetadataEntry
|
||||
(*fieldmaskpb.FieldMask)(nil), // 73: google.protobuf.FieldMask
|
||||
(*timestamppb.Timestamp)(nil), // 74: google.protobuf.Timestamp
|
||||
(*field_mask.FieldMask)(nil), // 73: google.protobuf.FieldMask
|
||||
(*timestamp.Timestamp)(nil), // 74: google.protobuf.Timestamp
|
||||
(*date.Date)(nil), // 75: google.type.Date
|
||||
(*v1.GetIamPolicyRequest)(nil), // 76: google.iam.v1.GetIamPolicyRequest
|
||||
(*v1.SetIamPolicyRequest)(nil), // 77: google.iam.v1.SetIamPolicyRequest
|
||||
(*v1.TestIamPermissionsRequest)(nil), // 78: google.iam.v1.TestIamPermissionsRequest
|
||||
(*emptypb.Empty)(nil), // 79: google.protobuf.Empty
|
||||
(*empty.Empty)(nil), // 79: google.protobuf.Empty
|
||||
(*v1.Policy)(nil), // 80: google.iam.v1.Policy
|
||||
(*v1.TestIamPermissionsResponse)(nil), // 81: google.iam.v1.TestIamPermissionsResponse
|
||||
}
|
||||
|
@ -8986,7 +8986,7 @@ const _ = grpc.SupportPackageIsVersion6
|
|||
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
|
||||
type StorageClient interface {
|
||||
// Permanently deletes an empty bucket.
|
||||
DeleteBucket(ctx context.Context, in *DeleteBucketRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
|
||||
DeleteBucket(ctx context.Context, in *DeleteBucketRequest, opts ...grpc.CallOption) (*empty.Empty, error)
|
||||
// Returns metadata for the specified bucket.
|
||||
GetBucket(ctx context.Context, in *GetBucketRequest, opts ...grpc.CallOption) (*Bucket, error)
|
||||
// Creates a new bucket.
|
||||
|
@ -9005,7 +9005,7 @@ type StorageClient interface {
|
|||
// Updates a bucket. Equivalent to JSON API's storage.buckets.patch method.
|
||||
UpdateBucket(ctx context.Context, in *UpdateBucketRequest, opts ...grpc.CallOption) (*Bucket, error)
|
||||
// Permanently deletes a notification subscription.
|
||||
DeleteNotification(ctx context.Context, in *DeleteNotificationRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
|
||||
DeleteNotification(ctx context.Context, in *DeleteNotificationRequest, opts ...grpc.CallOption) (*empty.Empty, error)
|
||||
// View a notification config.
|
||||
GetNotification(ctx context.Context, in *GetNotificationRequest, opts ...grpc.CallOption) (*Notification, error)
|
||||
// Creates a notification subscription for a given bucket.
|
||||
|
@ -9021,7 +9021,7 @@ type StorageClient interface {
|
|||
// Deletes an object and its metadata. Deletions are permanent if versioning
|
||||
// is not enabled for the bucket, or if the `generation` parameter
|
||||
// is used.
|
||||
DeleteObject(ctx context.Context, in *DeleteObjectRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
|
||||
DeleteObject(ctx context.Context, in *DeleteObjectRequest, opts ...grpc.CallOption) (*empty.Empty, error)
|
||||
// Retrieves an object's metadata.
|
||||
GetObject(ctx context.Context, in *GetObjectRequest, opts ...grpc.CallOption) (*Object, error)
|
||||
// Reads an object's data.
|
||||
|
@ -9110,7 +9110,7 @@ type StorageClient interface {
|
|||
// Creates a new HMAC key for the given service account.
|
||||
CreateHmacKey(ctx context.Context, in *CreateHmacKeyRequest, opts ...grpc.CallOption) (*CreateHmacKeyResponse, error)
|
||||
// Deletes a given HMAC key. Key must be in an INACTIVE state.
|
||||
DeleteHmacKey(ctx context.Context, in *DeleteHmacKeyRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
|
||||
DeleteHmacKey(ctx context.Context, in *DeleteHmacKeyRequest, opts ...grpc.CallOption) (*empty.Empty, error)
|
||||
// Gets an existing HMAC key metadata for the given id.
|
||||
GetHmacKey(ctx context.Context, in *GetHmacKeyRequest, opts ...grpc.CallOption) (*HmacKeyMetadata, error)
|
||||
// Lists HMAC keys under a given project with the additional filters provided.
|
||||
|
@ -9127,8 +9127,8 @@ func NewStorageClient(cc grpc.ClientConnInterface) StorageClient {
|
|||
return &storageClient{cc}
|
||||
}
|
||||
|
||||
func (c *storageClient) DeleteBucket(ctx context.Context, in *DeleteBucketRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) {
|
||||
out := new(emptypb.Empty)
|
||||
func (c *storageClient) DeleteBucket(ctx context.Context, in *DeleteBucketRequest, opts ...grpc.CallOption) (*empty.Empty, error) {
|
||||
out := new(empty.Empty)
|
||||
err := c.cc.Invoke(ctx, "/google.storage.v2.Storage/DeleteBucket", in, out, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
@ -9208,8 +9208,8 @@ func (c *storageClient) UpdateBucket(ctx context.Context, in *UpdateBucketReques
|
|||
return out, nil
|
||||
}
|
||||
|
||||
func (c *storageClient) DeleteNotification(ctx context.Context, in *DeleteNotificationRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) {
|
||||
out := new(emptypb.Empty)
|
||||
func (c *storageClient) DeleteNotification(ctx context.Context, in *DeleteNotificationRequest, opts ...grpc.CallOption) (*empty.Empty, error) {
|
||||
out := new(empty.Empty)
|
||||
err := c.cc.Invoke(ctx, "/google.storage.v2.Storage/DeleteNotification", in, out, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
@ -9253,8 +9253,8 @@ func (c *storageClient) ComposeObject(ctx context.Context, in *ComposeObjectRequ
|
|||
return out, nil
|
||||
}
|
||||
|
||||
func (c *storageClient) DeleteObject(ctx context.Context, in *DeleteObjectRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) {
|
||||
out := new(emptypb.Empty)
|
||||
func (c *storageClient) DeleteObject(ctx context.Context, in *DeleteObjectRequest, opts ...grpc.CallOption) (*empty.Empty, error) {
|
||||
out := new(empty.Empty)
|
||||
err := c.cc.Invoke(ctx, "/google.storage.v2.Storage/DeleteObject", in, out, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
@ -9400,8 +9400,8 @@ func (c *storageClient) CreateHmacKey(ctx context.Context, in *CreateHmacKeyRequ
|
|||
return out, nil
|
||||
}
|
||||
|
||||
func (c *storageClient) DeleteHmacKey(ctx context.Context, in *DeleteHmacKeyRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) {
|
||||
out := new(emptypb.Empty)
|
||||
func (c *storageClient) DeleteHmacKey(ctx context.Context, in *DeleteHmacKeyRequest, opts ...grpc.CallOption) (*empty.Empty, error) {
|
||||
out := new(empty.Empty)
|
||||
err := c.cc.Invoke(ctx, "/google.storage.v2.Storage/DeleteHmacKey", in, out, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
@ -9439,7 +9439,7 @@ func (c *storageClient) UpdateHmacKey(ctx context.Context, in *UpdateHmacKeyRequ
|
|||
// StorageServer is the server API for Storage service.
|
||||
type StorageServer interface {
|
||||
// Permanently deletes an empty bucket.
|
||||
DeleteBucket(context.Context, *DeleteBucketRequest) (*emptypb.Empty, error)
|
||||
DeleteBucket(context.Context, *DeleteBucketRequest) (*empty.Empty, error)
|
||||
// Returns metadata for the specified bucket.
|
||||
GetBucket(context.Context, *GetBucketRequest) (*Bucket, error)
|
||||
// Creates a new bucket.
|
||||
|
@ -9458,7 +9458,7 @@ type StorageServer interface {
|
|||
// Updates a bucket. Equivalent to JSON API's storage.buckets.patch method.
|
||||
UpdateBucket(context.Context, *UpdateBucketRequest) (*Bucket, error)
|
||||
// Permanently deletes a notification subscription.
|
||||
DeleteNotification(context.Context, *DeleteNotificationRequest) (*emptypb.Empty, error)
|
||||
DeleteNotification(context.Context, *DeleteNotificationRequest) (*empty.Empty, error)
|
||||
// View a notification config.
|
||||
GetNotification(context.Context, *GetNotificationRequest) (*Notification, error)
|
||||
// Creates a notification subscription for a given bucket.
|
||||
|
@ -9474,7 +9474,7 @@ type StorageServer interface {
|
|||
// Deletes an object and its metadata. Deletions are permanent if versioning
|
||||
// is not enabled for the bucket, or if the `generation` parameter
|
||||
// is used.
|
||||
DeleteObject(context.Context, *DeleteObjectRequest) (*emptypb.Empty, error)
|
||||
DeleteObject(context.Context, *DeleteObjectRequest) (*empty.Empty, error)
|
||||
// Retrieves an object's metadata.
|
||||
GetObject(context.Context, *GetObjectRequest) (*Object, error)
|
||||
// Reads an object's data.
|
||||
|
@ -9563,7 +9563,7 @@ type StorageServer interface {
|
|||
// Creates a new HMAC key for the given service account.
|
||||
CreateHmacKey(context.Context, *CreateHmacKeyRequest) (*CreateHmacKeyResponse, error)
|
||||
// Deletes a given HMAC key. Key must be in an INACTIVE state.
|
||||
DeleteHmacKey(context.Context, *DeleteHmacKeyRequest) (*emptypb.Empty, error)
|
||||
DeleteHmacKey(context.Context, *DeleteHmacKeyRequest) (*empty.Empty, error)
|
||||
// Gets an existing HMAC key metadata for the given id.
|
||||
GetHmacKey(context.Context, *GetHmacKeyRequest) (*HmacKeyMetadata, error)
|
||||
// Lists HMAC keys under a given project with the additional filters provided.
|
||||
|
@ -9576,7 +9576,7 @@ type StorageServer interface {
|
|||
type UnimplementedStorageServer struct {
|
||||
}
|
||||
|
||||
func (*UnimplementedStorageServer) DeleteBucket(context.Context, *DeleteBucketRequest) (*emptypb.Empty, error) {
|
||||
func (*UnimplementedStorageServer) DeleteBucket(context.Context, *DeleteBucketRequest) (*empty.Empty, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method DeleteBucket not implemented")
|
||||
}
|
||||
func (*UnimplementedStorageServer) GetBucket(context.Context, *GetBucketRequest) (*Bucket, error) {
|
||||
|
@ -9603,7 +9603,7 @@ func (*UnimplementedStorageServer) TestIamPermissions(context.Context, *v1.TestI
|
|||
func (*UnimplementedStorageServer) UpdateBucket(context.Context, *UpdateBucketRequest) (*Bucket, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method UpdateBucket not implemented")
|
||||
}
|
||||
func (*UnimplementedStorageServer) DeleteNotification(context.Context, *DeleteNotificationRequest) (*emptypb.Empty, error) {
|
||||
func (*UnimplementedStorageServer) DeleteNotification(context.Context, *DeleteNotificationRequest) (*empty.Empty, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method DeleteNotification not implemented")
|
||||
}
|
||||
func (*UnimplementedStorageServer) GetNotification(context.Context, *GetNotificationRequest) (*Notification, error) {
|
||||
|
@ -9618,7 +9618,7 @@ func (*UnimplementedStorageServer) ListNotifications(context.Context, *ListNotif
|
|||
func (*UnimplementedStorageServer) ComposeObject(context.Context, *ComposeObjectRequest) (*Object, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method ComposeObject not implemented")
|
||||
}
|
||||
func (*UnimplementedStorageServer) DeleteObject(context.Context, *DeleteObjectRequest) (*emptypb.Empty, error) {
|
||||
func (*UnimplementedStorageServer) DeleteObject(context.Context, *DeleteObjectRequest) (*empty.Empty, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method DeleteObject not implemented")
|
||||
}
|
||||
func (*UnimplementedStorageServer) GetObject(context.Context, *GetObjectRequest) (*Object, error) {
|
||||
|
@ -9651,7 +9651,7 @@ func (*UnimplementedStorageServer) GetServiceAccount(context.Context, *GetServic
|
|||
func (*UnimplementedStorageServer) CreateHmacKey(context.Context, *CreateHmacKeyRequest) (*CreateHmacKeyResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method CreateHmacKey not implemented")
|
||||
}
|
||||
func (*UnimplementedStorageServer) DeleteHmacKey(context.Context, *DeleteHmacKeyRequest) (*emptypb.Empty, error) {
|
||||
func (*UnimplementedStorageServer) DeleteHmacKey(context.Context, *DeleteHmacKeyRequest) (*empty.Empty, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method DeleteHmacKey not implemented")
|
||||
}
|
||||
func (*UnimplementedStorageServer) GetHmacKey(context.Context, *GetHmacKeyRequest) (*HmacKeyMetadata, error) {
|
2
vendor/cloud.google.com/go/storage/internal/version.go
generated
vendored
2
vendor/cloud.google.com/go/storage/internal/version.go
generated
vendored
|
@ -15,4 +15,4 @@
|
|||
package internal
|
||||
|
||||
// Version is the current tagged release of the library.
|
||||
const Version = "1.23.0"
|
||||
const Version = "1.24.0"
|
||||
|
|
2
vendor/cloud.google.com/go/storage/notifications.go
generated
vendored
2
vendor/cloud.google.com/go/storage/notifications.go
generated
vendored
|
@ -21,8 +21,8 @@ import (
|
|||
"regexp"
|
||||
|
||||
"cloud.google.com/go/internal/trace"
|
||||
storagepb "cloud.google.com/go/storage/internal/apiv2/stubs"
|
||||
raw "google.golang.org/api/storage/v1"
|
||||
storagepb "google.golang.org/genproto/googleapis/storage/v2"
|
||||
)
|
||||
|
||||
// A Notification describes how to send Cloud PubSub messages when certain
|
||||
|
|
36
vendor/cloud.google.com/go/storage/storage.go
generated
vendored
36
vendor/cloud.google.com/go/storage/storage.go
generated
vendored
|
@ -40,6 +40,7 @@ import (
|
|||
"cloud.google.com/go/internal/optional"
|
||||
"cloud.google.com/go/internal/trace"
|
||||
"cloud.google.com/go/storage/internal"
|
||||
storagepb "cloud.google.com/go/storage/internal/apiv2/stubs"
|
||||
"github.com/googleapis/gax-go/v2"
|
||||
"golang.org/x/oauth2/google"
|
||||
"google.golang.org/api/googleapi"
|
||||
|
@ -48,7 +49,6 @@ import (
|
|||
raw "google.golang.org/api/storage/v1"
|
||||
"google.golang.org/api/transport"
|
||||
htransport "google.golang.org/api/transport/http"
|
||||
storagepb "google.golang.org/genproto/googleapis/storage/v2"
|
||||
"google.golang.org/protobuf/proto"
|
||||
"google.golang.org/protobuf/reflect/protoreflect"
|
||||
"google.golang.org/protobuf/types/known/timestamppb"
|
||||
|
@ -1208,8 +1208,11 @@ func (o *ObjectAttrs) toProtoObject(b string) *storagepb.Object {
|
|||
}
|
||||
|
||||
// For now, there are only globally unique buckets, and "_" is the alias
|
||||
// project ID for such buckets.
|
||||
b = bucketResourceName("_", b)
|
||||
// project ID for such buckets. If the bucket is not provided, like in the
|
||||
// destination ObjectAttrs of a Copy, do not attempt to format it.
|
||||
if b != "" {
|
||||
b = bucketResourceName(globalProjectAlias, b)
|
||||
}
|
||||
|
||||
return &storagepb.Object{
|
||||
Bucket: b,
|
||||
|
@ -1838,6 +1841,33 @@ func applySourceConds(gen int64, conds *Conditions, call *raw.ObjectsRewriteCall
|
|||
return nil
|
||||
}
|
||||
|
||||
func applySourceCondsProto(gen int64, conds *Conditions, call *storagepb.RewriteObjectRequest) error {
|
||||
if gen >= 0 {
|
||||
call.SourceGeneration = gen
|
||||
}
|
||||
if conds == nil {
|
||||
return nil
|
||||
}
|
||||
if err := conds.validate("CopyTo source"); err != nil {
|
||||
return err
|
||||
}
|
||||
switch {
|
||||
case conds.GenerationMatch != 0:
|
||||
call.IfSourceGenerationMatch = proto.Int64(conds.GenerationMatch)
|
||||
case conds.GenerationNotMatch != 0:
|
||||
call.IfSourceGenerationNotMatch = proto.Int64(conds.GenerationNotMatch)
|
||||
case conds.DoesNotExist:
|
||||
call.IfSourceGenerationMatch = proto.Int64(0)
|
||||
}
|
||||
switch {
|
||||
case conds.MetagenerationMatch != 0:
|
||||
call.IfSourceMetagenerationMatch = proto.Int64(conds.MetagenerationMatch)
|
||||
case conds.MetagenerationNotMatch != 0:
|
||||
call.IfSourceMetagenerationNotMatch = proto.Int64(conds.MetagenerationNotMatch)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// setConditionField sets a field on a *raw.WhateverCall.
|
||||
// We can't use anonymous interfaces because the return type is
|
||||
// different, since the field setters are builders.
|
||||
|
|
2
vendor/cloud.google.com/go/storage/writer.go
generated
vendored
2
vendor/cloud.google.com/go/storage/writer.go
generated
vendored
|
@ -24,9 +24,9 @@ import (
|
|||
"time"
|
||||
"unicode/utf8"
|
||||
|
||||
storagepb "cloud.google.com/go/storage/internal/apiv2/stubs"
|
||||
"google.golang.org/api/googleapi"
|
||||
raw "google.golang.org/api/storage/v1"
|
||||
storagepb "google.golang.org/genproto/googleapis/storage/v2"
|
||||
)
|
||||
|
||||
const (
|
||||
|
|
70
vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go
generated
vendored
70
vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go
generated
vendored
|
@ -7599,6 +7599,28 @@ var awsPartition = partition{
|
|||
},
|
||||
},
|
||||
},
|
||||
"edge.sagemaker": service{
|
||||
Endpoints: serviceEndpoints{
|
||||
endpointKey{
|
||||
Region: "ap-northeast-1",
|
||||
}: endpoint{},
|
||||
endpointKey{
|
||||
Region: "eu-central-1",
|
||||
}: endpoint{},
|
||||
endpointKey{
|
||||
Region: "eu-west-1",
|
||||
}: endpoint{},
|
||||
endpointKey{
|
||||
Region: "us-east-1",
|
||||
}: endpoint{},
|
||||
endpointKey{
|
||||
Region: "us-east-2",
|
||||
}: endpoint{},
|
||||
endpointKey{
|
||||
Region: "us-west-2",
|
||||
}: endpoint{},
|
||||
},
|
||||
},
|
||||
"eks": service{
|
||||
Defaults: endpointDefaults{
|
||||
defaultKey{}: endpoint{
|
||||
|
@ -11009,7 +11031,23 @@ var awsPartition = partition{
|
|||
},
|
||||
},
|
||||
"health": service{
|
||||
PartitionEndpoint: "aws-global",
|
||||
IsRegionalized: boxedFalse,
|
||||
Defaults: endpointDefaults{
|
||||
defaultKey{}: endpoint{
|
||||
SSLCommonName: "health.us-east-1.amazonaws.com",
|
||||
Protocols: []string{"https"},
|
||||
},
|
||||
},
|
||||
Endpoints: serviceEndpoints{
|
||||
endpointKey{
|
||||
Region: "aws-global",
|
||||
}: endpoint{
|
||||
Hostname: "global.health.amazonaws.com",
|
||||
CredentialScope: credentialScope{
|
||||
Region: "us-east-1",
|
||||
},
|
||||
},
|
||||
endpointKey{
|
||||
Region: "fips-us-east-2",
|
||||
}: endpoint{
|
||||
|
@ -24165,6 +24203,18 @@ var awsPartition = partition{
|
|||
},
|
||||
"workspaces-web": service{
|
||||
Endpoints: serviceEndpoints{
|
||||
endpointKey{
|
||||
Region: "ap-northeast-1",
|
||||
}: endpoint{},
|
||||
endpointKey{
|
||||
Region: "ap-south-1",
|
||||
}: endpoint{},
|
||||
endpointKey{
|
||||
Region: "ap-southeast-1",
|
||||
}: endpoint{},
|
||||
endpointKey{
|
||||
Region: "ap-southeast-2",
|
||||
}: endpoint{},
|
||||
endpointKey{
|
||||
Region: "eu-west-1",
|
||||
}: endpoint{},
|
||||
|
@ -25127,13 +25177,23 @@ var awscnPartition = partition{
|
|||
},
|
||||
},
|
||||
"health": service{
|
||||
PartitionEndpoint: "aws-cn-global",
|
||||
IsRegionalized: boxedFalse,
|
||||
Defaults: endpointDefaults{
|
||||
defaultKey{}: endpoint{
|
||||
SSLCommonName: "health.cn-northwest-1.amazonaws.com.cn",
|
||||
Protocols: []string{"https"},
|
||||
},
|
||||
},
|
||||
Endpoints: serviceEndpoints{
|
||||
endpointKey{
|
||||
Region: "cn-north-1",
|
||||
}: endpoint{},
|
||||
endpointKey{
|
||||
Region: "cn-northwest-1",
|
||||
}: endpoint{},
|
||||
Region: "aws-cn-global",
|
||||
}: endpoint{
|
||||
Hostname: "global.health.amazonaws.com.cn",
|
||||
CredentialScope: credentialScope{
|
||||
Region: "cn-northwest-1",
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
"iam": service{
|
||||
|
|
2
vendor/github.com/aws/aws-sdk-go/aws/version.go
generated
vendored
2
vendor/github.com/aws/aws-sdk-go/aws/version.go
generated
vendored
|
@ -5,4 +5,4 @@ package aws
|
|||
const SDKName = "aws-sdk-go"
|
||||
|
||||
// SDKVersion is the version of this SDK
|
||||
const SDKVersion = "1.44.56"
|
||||
const SDKVersion = "1.44.59"
|
||||
|
|
62
vendor/github.com/golang/protobuf/ptypes/empty/empty.pb.go
generated
vendored
Normal file
62
vendor/github.com/golang/protobuf/ptypes/empty/empty.pb.go
generated
vendored
Normal file
|
@ -0,0 +1,62 @@
|
|||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// source: github.com/golang/protobuf/ptypes/empty/empty.proto
|
||||
|
||||
package empty
|
||||
|
||||
import (
|
||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||
emptypb "google.golang.org/protobuf/types/known/emptypb"
|
||||
reflect "reflect"
|
||||
)
|
||||
|
||||
// Symbols defined in public import of google/protobuf/empty.proto.
|
||||
|
||||
type Empty = emptypb.Empty
|
||||
|
||||
var File_github_com_golang_protobuf_ptypes_empty_empty_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_github_com_golang_protobuf_ptypes_empty_empty_proto_rawDesc = []byte{
|
||||
0x0a, 0x33, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x6f, 0x6c,
|
||||
0x61, 0x6e, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x70, 0x74, 0x79,
|
||||
0x70, 0x65, 0x73, 0x2f, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x2f, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x2e,
|
||||
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1b, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72,
|
||||
0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x2e, 0x70, 0x72, 0x6f,
|
||||
0x74, 0x6f, 0x42, 0x2f, 0x5a, 0x2d, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d,
|
||||
0x2f, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66,
|
||||
0x2f, 0x70, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x3b, 0x65, 0x6d,
|
||||
0x70, 0x74, 0x79, 0x50, 0x00, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var file_github_com_golang_protobuf_ptypes_empty_empty_proto_goTypes = []interface{}{}
|
||||
var file_github_com_golang_protobuf_ptypes_empty_empty_proto_depIdxs = []int32{
|
||||
0, // [0:0] is the sub-list for method output_type
|
||||
0, // [0:0] is the sub-list for method input_type
|
||||
0, // [0:0] is the sub-list for extension type_name
|
||||
0, // [0:0] is the sub-list for extension extendee
|
||||
0, // [0:0] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_github_com_golang_protobuf_ptypes_empty_empty_proto_init() }
|
||||
func file_github_com_golang_protobuf_ptypes_empty_empty_proto_init() {
|
||||
if File_github_com_golang_protobuf_ptypes_empty_empty_proto != nil {
|
||||
return
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_github_com_golang_protobuf_ptypes_empty_empty_proto_rawDesc,
|
||||
NumEnums: 0,
|
||||
NumMessages: 0,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_github_com_golang_protobuf_ptypes_empty_empty_proto_goTypes,
|
||||
DependencyIndexes: file_github_com_golang_protobuf_ptypes_empty_empty_proto_depIdxs,
|
||||
}.Build()
|
||||
File_github_com_golang_protobuf_ptypes_empty_empty_proto = out.File
|
||||
file_github_com_golang_protobuf_ptypes_empty_empty_proto_rawDesc = nil
|
||||
file_github_com_golang_protobuf_ptypes_empty_empty_proto_goTypes = nil
|
||||
file_github_com_golang_protobuf_ptypes_empty_empty_proto_depIdxs = nil
|
||||
}
|
202
vendor/github.com/googleapis/go-type-adapters/LICENSE
generated
vendored
202
vendor/github.com/googleapis/go-type-adapters/LICENSE
generated
vendored
|
@ -1,202 +0,0 @@
|
|||
|
||||
Apache License
|
||||
Version 2.0, January 2004
|
||||
http://www.apache.org/licenses/
|
||||
|
||||
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
||||
|
||||
1. Definitions.
|
||||
|
||||
"License" shall mean the terms and conditions for use, reproduction,
|
||||
and distribution as defined by Sections 1 through 9 of this document.
|
||||
|
||||
"Licensor" shall mean the copyright owner or entity authorized by
|
||||
the copyright owner that is granting the License.
|
||||
|
||||
"Legal Entity" shall mean the union of the acting entity and all
|
||||
other entities that control, are controlled by, or are under common
|
||||
control with that entity. For the purposes of this definition,
|
||||
"control" means (i) the power, direct or indirect, to cause the
|
||||
direction or management of such entity, whether by contract or
|
||||
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
||||
outstanding shares, or (iii) beneficial ownership of such entity.
|
||||
|
||||
"You" (or "Your") shall mean an individual or Legal Entity
|
||||
exercising permissions granted by this License.
|
||||
|
||||
"Source" form shall mean the preferred form for making modifications,
|
||||
including but not limited to software source code, documentation
|
||||
source, and configuration files.
|
||||
|
||||
"Object" form shall mean any form resulting from mechanical
|
||||
transformation or translation of a Source form, including but
|
||||
not limited to compiled object code, generated documentation,
|
||||
and conversions to other media types.
|
||||
|
||||
"Work" shall mean the work of authorship, whether in Source or
|
||||
Object form, made available under the License, as indicated by a
|
||||
copyright notice that is included in or attached to the work
|
||||
(an example is provided in the Appendix below).
|
||||
|
||||
"Derivative Works" shall mean any work, whether in Source or Object
|
||||
form, that is based on (or derived from) the Work and for which the
|
||||
editorial revisions, annotations, elaborations, or other modifications
|
||||
represent, as a whole, an original work of authorship. For the purposes
|
||||
of this License, Derivative Works shall not include works that remain
|
||||
separable from, or merely link (or bind by name) to the interfaces of,
|
||||
the Work and Derivative Works thereof.
|
||||
|
||||
"Contribution" shall mean any work of authorship, including
|
||||
the original version of the Work and any modifications or additions
|
||||
to that Work or Derivative Works thereof, that is intentionally
|
||||
submitted to Licensor for inclusion in the Work by the copyright owner
|
||||
or by an individual or Legal Entity authorized to submit on behalf of
|
||||
the copyright owner. For the purposes of this definition, "submitted"
|
||||
means any form of electronic, verbal, or written communication sent
|
||||
to the Licensor or its representatives, including but not limited to
|
||||
communication on electronic mailing lists, source code control systems,
|
||||
and issue tracking systems that are managed by, or on behalf of, the
|
||||
Licensor for the purpose of discussing and improving the Work, but
|
||||
excluding communication that is conspicuously marked or otherwise
|
||||
designated in writing by the copyright owner as "Not a Contribution."
|
||||
|
||||
"Contributor" shall mean Licensor and any individual or Legal Entity
|
||||
on behalf of whom a Contribution has been received by Licensor and
|
||||
subsequently incorporated within the Work.
|
||||
|
||||
2. Grant of Copyright License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
copyright license to reproduce, prepare Derivative Works of,
|
||||
publicly display, publicly perform, sublicense, and distribute the
|
||||
Work and such Derivative Works in Source or Object form.
|
||||
|
||||
3. Grant of Patent License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
(except as stated in this section) patent license to make, have made,
|
||||
use, offer to sell, sell, import, and otherwise transfer the Work,
|
||||
where such license applies only to those patent claims licensable
|
||||
by such Contributor that are necessarily infringed by their
|
||||
Contribution(s) alone or by combination of their Contribution(s)
|
||||
with the Work to which such Contribution(s) was submitted. If You
|
||||
institute patent litigation against any entity (including a
|
||||
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
||||
or a Contribution incorporated within the Work constitutes direct
|
||||
or contributory patent infringement, then any patent licenses
|
||||
granted to You under this License for that Work shall terminate
|
||||
as of the date such litigation is filed.
|
||||
|
||||
4. Redistribution. You may reproduce and distribute copies of the
|
||||
Work or Derivative Works thereof in any medium, with or without
|
||||
modifications, and in Source or Object form, provided that You
|
||||
meet the following conditions:
|
||||
|
||||
(a) You must give any other recipients of the Work or
|
||||
Derivative Works a copy of this License; and
|
||||
|
||||
(b) You must cause any modified files to carry prominent notices
|
||||
stating that You changed the files; and
|
||||
|
||||
(c) You must retain, in the Source form of any Derivative Works
|
||||
that You distribute, all copyright, patent, trademark, and
|
||||
attribution notices from the Source form of the Work,
|
||||
excluding those notices that do not pertain to any part of
|
||||
the Derivative Works; and
|
||||
|
||||
(d) If the Work includes a "NOTICE" text file as part of its
|
||||
distribution, then any Derivative Works that You distribute must
|
||||
include a readable copy of the attribution notices contained
|
||||
within such NOTICE file, excluding those notices that do not
|
||||
pertain to any part of the Derivative Works, in at least one
|
||||
of the following places: within a NOTICE text file distributed
|
||||
as part of the Derivative Works; within the Source form or
|
||||
documentation, if provided along with the Derivative Works; or,
|
||||
within a display generated by the Derivative Works, if and
|
||||
wherever such third-party notices normally appear. The contents
|
||||
of the NOTICE file are for informational purposes only and
|
||||
do not modify the License. You may add Your own attribution
|
||||
notices within Derivative Works that You distribute, alongside
|
||||
or as an addendum to the NOTICE text from the Work, provided
|
||||
that such additional attribution notices cannot be construed
|
||||
as modifying the License.
|
||||
|
||||
You may add Your own copyright statement to Your modifications and
|
||||
may provide additional or different license terms and conditions
|
||||
for use, reproduction, or distribution of Your modifications, or
|
||||
for any such Derivative Works as a whole, provided Your use,
|
||||
reproduction, and distribution of the Work otherwise complies with
|
||||
the conditions stated in this License.
|
||||
|
||||
5. Submission of Contributions. Unless You explicitly state otherwise,
|
||||
any Contribution intentionally submitted for inclusion in the Work
|
||||
by You to the Licensor shall be under the terms and conditions of
|
||||
this License, without any additional terms or conditions.
|
||||
Notwithstanding the above, nothing herein shall supersede or modify
|
||||
the terms of any separate license agreement you may have executed
|
||||
with Licensor regarding such Contributions.
|
||||
|
||||
6. Trademarks. This License does not grant permission to use the trade
|
||||
names, trademarks, service marks, or product names of the Licensor,
|
||||
except as required for reasonable and customary use in describing the
|
||||
origin of the Work and reproducing the content of the NOTICE file.
|
||||
|
||||
7. Disclaimer of Warranty. Unless required by applicable law or
|
||||
agreed to in writing, Licensor provides the Work (and each
|
||||
Contributor provides its Contributions) on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
||||
implied, including, without limitation, any warranties or conditions
|
||||
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
||||
PARTICULAR PURPOSE. You are solely responsible for determining the
|
||||
appropriateness of using or redistributing the Work and assume any
|
||||
risks associated with Your exercise of permissions under this License.
|
||||
|
||||
8. Limitation of Liability. In no event and under no legal theory,
|
||||
whether in tort (including negligence), contract, or otherwise,
|
||||
unless required by applicable law (such as deliberate and grossly
|
||||
negligent acts) or agreed to in writing, shall any Contributor be
|
||||
liable to You for damages, including any direct, indirect, special,
|
||||
incidental, or consequential damages of any character arising as a
|
||||
result of this License or out of the use or inability to use the
|
||||
Work (including but not limited to damages for loss of goodwill,
|
||||
work stoppage, computer failure or malfunction, or any and all
|
||||
other commercial damages or losses), even if such Contributor
|
||||
has been advised of the possibility of such damages.
|
||||
|
||||
9. Accepting Warranty or Additional Liability. While redistributing
|
||||
the Work or Derivative Works thereof, You may choose to offer,
|
||||
and charge a fee for, acceptance of support, warranty, indemnity,
|
||||
or other liability obligations and/or rights consistent with this
|
||||
License. However, in accepting such obligations, You may act only
|
||||
on Your own behalf and on Your sole responsibility, not on behalf
|
||||
of any other Contributor, and only if You agree to indemnify,
|
||||
defend, and hold each Contributor harmless for any liability
|
||||
incurred by, or claims asserted against, such Contributor by reason
|
||||
of your accepting any such warranty or additional liability.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
APPENDIX: How to apply the Apache License to your work.
|
||||
|
||||
To apply the Apache License to your work, attach the following
|
||||
boilerplate notice, with the fields enclosed by brackets "[]"
|
||||
replaced with your own identifying information. (Don't include
|
||||
the brackets!) The text should be enclosed in the appropriate
|
||||
comment syntax for the file format. We also recommend that a
|
||||
file or class name and description of purpose be included on the
|
||||
same "printed page" as the copyright notice for easier
|
||||
identification within third-party archives.
|
||||
|
||||
Copyright [yyyy] [name of copyright owner]
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
https://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
81
vendor/github.com/googleapis/go-type-adapters/adapters/color.go
generated
vendored
81
vendor/github.com/googleapis/go-type-adapters/adapters/color.go
generated
vendored
|
@ -1,81 +0,0 @@
|
|||
// Copyright 2021 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// https://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package adapters
|
||||
|
||||
import (
|
||||
"image/color"
|
||||
"math"
|
||||
|
||||
cpb "google.golang.org/genproto/googleapis/type/color"
|
||||
wpb "google.golang.org/protobuf/types/known/wrapperspb"
|
||||
)
|
||||
|
||||
// ProtoColorToRGBA returns an RGBA based on the provided google.type.Color.
|
||||
// If alpha is not set in the proto, full opacity is assumed.
|
||||
//
|
||||
// Note: Converting between a float using [0, 1] to an int using [0, 256)
|
||||
// causes some cognitive dissonance between accuracy and user expectations.
|
||||
// For example, most people writing CSS use 0x80 (decimal 128) to mean "half",
|
||||
// but it is not actually half (it is slightly over). There is actually no
|
||||
// way to precisely specify the 0.5 float value in a [0, 256) range of
|
||||
// integers.
|
||||
//
|
||||
// This function uses math.Round to address this, meaning that 0.5 will be
|
||||
// rounded up to 128 rather than rounded down to 127.
|
||||
//
|
||||
// Because of this fuzziness and precision loss, it is NOT guaranteed that
|
||||
// ProtoColorToRGBA and RGBAToProtoColor are exact inverses, and both functions
|
||||
// will lose precision.
|
||||
func ProtoColorToRGBA(c *cpb.Color) *color.RGBA {
|
||||
// Determine the appropriate alpha value.
|
||||
// If alpha is unset, full opacity is the proper default.
|
||||
alpha := uint8(255)
|
||||
if c.Alpha != nil {
|
||||
alpha = uint8(math.Round(float64(c.GetAlpha().GetValue() * 255)))
|
||||
}
|
||||
|
||||
// Return the RGBA.
|
||||
return &color.RGBA{
|
||||
R: uint8(math.Round(float64(c.GetRed()) * 255)),
|
||||
G: uint8(math.Round(float64(c.GetGreen()) * 255)),
|
||||
B: uint8(math.Round(float64(c.GetBlue()) * 255)),
|
||||
A: alpha,
|
||||
}
|
||||
}
|
||||
|
||||
// RGBAToProtoColor returns a google.type.Color based on the provided RGBA.
|
||||
//
|
||||
// Note: Converting between ints using [0, 256) and a float using [0, 1]
|
||||
// causes some cognitive dissonance between accuracy and user expectations.
|
||||
// For example, most people using CSS use 0x80 (decimal 128) to mean "half",
|
||||
// but it is not actually half (it is slightly over). These is actually no
|
||||
// way to precisely specify the 0.5 float value in a [0, 256) range of
|
||||
// integers.
|
||||
//
|
||||
// This function addresses this by limiting decimal precision to 0.01, on
|
||||
// the rationale that most precision beyond this point is probably
|
||||
// unintentional.
|
||||
//
|
||||
// Because of this fuzziness and precision loss, it is NOT guaranteed that
|
||||
// ProtoColorToRGBA and RGBAToProtoColor are exact inverses, and both functions
|
||||
// will lose precision.
|
||||
func RGBAToProtoColor(rgba *color.RGBA) *cpb.Color {
|
||||
return &cpb.Color{
|
||||
Red: float32(int(rgba.R)*100/255) / 100,
|
||||
Green: float32(int(rgba.G)*100/255) / 100,
|
||||
Blue: float32(int(rgba.B)*100/255) / 100,
|
||||
Alpha: &wpb.FloatValue{Value: float32(int(rgba.A)*100/255) / 100},
|
||||
}
|
||||
}
|
54
vendor/github.com/googleapis/go-type-adapters/adapters/date.go
generated
vendored
54
vendor/github.com/googleapis/go-type-adapters/adapters/date.go
generated
vendored
|
@ -1,54 +0,0 @@
|
|||
// Copyright 2021 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// https://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package adapters
|
||||
|
||||
import (
|
||||
"time"
|
||||
|
||||
dpb "google.golang.org/genproto/googleapis/type/date"
|
||||
)
|
||||
|
||||
// ProtoDateToLocalTime returns a new Time based on the google.type.Date, in
|
||||
// the system's time zone.
|
||||
//
|
||||
// Hours, minues, seconds, and nanoseconds are set to 0.
|
||||
func ProtoDateToLocalTime(d *dpb.Date) time.Time {
|
||||
return ProtoDateToTime(d, time.Local)
|
||||
}
|
||||
|
||||
// ProtoDateToUTCTime returns a new Time based on the google.type.Date, in UTC.
|
||||
//
|
||||
// Hours, minutes, seconds, and nanoseconds are set to 0.
|
||||
func ProtoDateToUTCTime(d *dpb.Date) time.Time {
|
||||
return ProtoDateToTime(d, time.UTC)
|
||||
}
|
||||
|
||||
// ProtoDateToTime returns a new Time based on the google.type.Date and provided
|
||||
// *time.Location.
|
||||
//
|
||||
// Hours, minutes, seconds, and nanoseconds are set to 0.
|
||||
func ProtoDateToTime(d *dpb.Date, l *time.Location) time.Time {
|
||||
return time.Date(int(d.GetYear()), time.Month(d.GetMonth()), int(d.GetDay()), 0, 0, 0, 0, l)
|
||||
}
|
||||
|
||||
// TimeToProtoDate returns a new google.type.Date based on the provided time.Time.
|
||||
// The location is ignored, as is anything more precise than the day.
|
||||
func TimeToProtoDate(t time.Time) *dpb.Date {
|
||||
return &dpb.Date{
|
||||
Year: int32(t.Year()),
|
||||
Month: int32(t.Month()),
|
||||
Day: int32(t.Day()),
|
||||
}
|
||||
}
|
93
vendor/github.com/googleapis/go-type-adapters/adapters/datetime.go
generated
vendored
93
vendor/github.com/googleapis/go-type-adapters/adapters/datetime.go
generated
vendored
|
@ -1,93 +0,0 @@
|
|||
// Copyright 2021 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// https://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package adapters
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"regexp"
|
||||
"strconv"
|
||||
"time"
|
||||
|
||||
dtpb "google.golang.org/genproto/googleapis/type/datetime"
|
||||
durpb "google.golang.org/protobuf/types/known/durationpb"
|
||||
)
|
||||
|
||||
// ProtoDateTimeToTime returns a new Time based on the google.type.DateTime.
|
||||
//
|
||||
// It errors if it gets invalid time zone information.
|
||||
func ProtoDateTimeToTime(d *dtpb.DateTime) (time.Time, error) {
|
||||
var err error
|
||||
|
||||
// Determine the location.
|
||||
loc := time.UTC
|
||||
if tz := d.GetTimeZone(); tz != nil {
|
||||
loc, err = time.LoadLocation(tz.GetId())
|
||||
if err != nil {
|
||||
return time.Time{}, err
|
||||
}
|
||||
}
|
||||
if offset := d.GetUtcOffset(); offset != nil {
|
||||
hours := int(offset.GetSeconds()) / 3600
|
||||
loc = time.FixedZone(fmt.Sprintf("UTC%+d", hours), hours)
|
||||
}
|
||||
|
||||
// Return the Time.
|
||||
return time.Date(
|
||||
int(d.GetYear()),
|
||||
time.Month(d.GetMonth()),
|
||||
int(d.GetDay()),
|
||||
int(d.GetHours()),
|
||||
int(d.GetMinutes()),
|
||||
int(d.GetSeconds()),
|
||||
int(d.GetNanos()),
|
||||
loc,
|
||||
), nil
|
||||
}
|
||||
|
||||
// TimeToProtoDateTime returns a new google.type.DateTime based on the
|
||||
// provided time.Time.
|
||||
//
|
||||
// It errors if it gets invalid time zone information.
|
||||
func TimeToProtoDateTime(t time.Time) (*dtpb.DateTime, error) {
|
||||
dt := &dtpb.DateTime{
|
||||
Year: int32(t.Year()),
|
||||
Month: int32(t.Month()),
|
||||
Day: int32(t.Day()),
|
||||
Hours: int32(t.Hour()),
|
||||
Minutes: int32(t.Minute()),
|
||||
Seconds: int32(t.Second()),
|
||||
Nanos: int32(t.Nanosecond()),
|
||||
}
|
||||
|
||||
// If the location is a UTC offset, encode it as such in the proto.
|
||||
loc := t.Location().String()
|
||||
if match := offsetRegexp.FindStringSubmatch(loc); len(match) > 0 {
|
||||
offsetInt, err := strconv.Atoi(match[1])
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
dt.TimeOffset = &dtpb.DateTime_UtcOffset{
|
||||
UtcOffset: &durpb.Duration{Seconds: int64(offsetInt) * 3600},
|
||||
}
|
||||
} else if loc != "" {
|
||||
dt.TimeOffset = &dtpb.DateTime_TimeZone{
|
||||
TimeZone: &dtpb.TimeZone{Id: loc},
|
||||
}
|
||||
}
|
||||
|
||||
return dt, nil
|
||||
}
|
||||
|
||||
var offsetRegexp = regexp.MustCompile(`^UTC([+-][\d]{1,2})$`)
|
68
vendor/github.com/googleapis/go-type-adapters/adapters/decimal.go
generated
vendored
68
vendor/github.com/googleapis/go-type-adapters/adapters/decimal.go
generated
vendored
|
@ -1,68 +0,0 @@
|
|||
// Copyright 2021 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// https://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package adapters
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"math"
|
||||
"math/big"
|
||||
"regexp"
|
||||
"strings"
|
||||
|
||||
dpb "google.golang.org/genproto/googleapis/type/decimal"
|
||||
)
|
||||
|
||||
// ProtoDecimalToFloat converts the provided google.type.Decimal to a big.Float.
|
||||
func ProtoDecimalToFloat(d *dpb.Decimal) (*big.Float, error) {
|
||||
value := strings.ToLower(d.GetValue())
|
||||
|
||||
// Determine the required precision.
|
||||
v := value
|
||||
if strings.ContainsRune(v, 'e') {
|
||||
v = v[0:strings.IndexRune(v, 'e')]
|
||||
}
|
||||
v = nan.ReplaceAllLiteralString(v, "")
|
||||
prec := uint(math.Pow(2, float64(len(v)+1)))
|
||||
|
||||
// Parse and return a big.Float.
|
||||
f, _, err := big.ParseFloat(value, 10, prec, big.AwayFromZero)
|
||||
return f, err
|
||||
}
|
||||
|
||||
// ProtoDecimalToFloat64 converts the provided google.type.Decimal to a float64.
|
||||
func ProtoDecimalToFloat64(d *dpb.Decimal) (float64, big.Accuracy, error) {
|
||||
f, err := ProtoDecimalToFloat(d)
|
||||
if err != nil {
|
||||
return 0.0, big.Exact, err
|
||||
}
|
||||
f64, accuracy := f.Float64()
|
||||
return f64, accuracy, nil
|
||||
}
|
||||
|
||||
// Float64ToProtoDecimal converts the provided float64 to a google.type.Decimal.
|
||||
func Float64ToProtoDecimal(f float64) *dpb.Decimal {
|
||||
return &dpb.Decimal{
|
||||
Value: fmt.Sprintf("%f", f),
|
||||
}
|
||||
}
|
||||
|
||||
// FloatToProtoDecimal converts the provided big.Float to a google.type.Decimal.
|
||||
func FloatToProtoDecimal(f *big.Float) *dpb.Decimal {
|
||||
return &dpb.Decimal{
|
||||
Value: f.String(),
|
||||
}
|
||||
}
|
||||
|
||||
var nan = regexp.MustCompile(`[^\d]`)
|
17
vendor/github.com/googleapis/go-type-adapters/adapters/doc.go
generated
vendored
17
vendor/github.com/googleapis/go-type-adapters/adapters/doc.go
generated
vendored
|
@ -1,17 +0,0 @@
|
|||
// Copyright 2021 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// https://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// package adapters provides helper functions for the google.type protobuf
|
||||
// messages (Decimal, Fraction, etc.).
|
||||
package adapters
|
35
vendor/github.com/googleapis/go-type-adapters/adapters/fraction.go
generated
vendored
35
vendor/github.com/googleapis/go-type-adapters/adapters/fraction.go
generated
vendored
|
@ -1,35 +0,0 @@
|
|||
// Copyright 2021 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// https://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package adapters
|
||||
|
||||
import (
|
||||
"math/big"
|
||||
|
||||
fpb "google.golang.org/genproto/googleapis/type/fraction"
|
||||
)
|
||||
|
||||
// ProtoFractionToRat returns a math/big Rat (rational number) based on the given
|
||||
// google.type.fraction.
|
||||
func ProtoFractionToRat(f *fpb.Fraction) *big.Rat {
|
||||
return big.NewRat(f.GetNumerator(), f.GetDenominator())
|
||||
}
|
||||
|
||||
// RatToProtoFraction returns a google.type.Fraction from a math/big Rat.
|
||||
func RatToProtoFraction(r *big.Rat) *fpb.Fraction {
|
||||
return &fpb.Fraction{
|
||||
Numerator: r.Num().Int64(),
|
||||
Denominator: r.Denom().Int64(),
|
||||
}
|
||||
}
|
31
vendor/github.com/googleapis/go-type-adapters/adapters/month.go
generated
vendored
31
vendor/github.com/googleapis/go-type-adapters/adapters/month.go
generated
vendored
|
@ -1,31 +0,0 @@
|
|||
// Copyright 2021 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// https://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package adapters
|
||||
|
||||
import (
|
||||
"time"
|
||||
|
||||
mpb "google.golang.org/genproto/googleapis/type/month"
|
||||
)
|
||||
|
||||
// ToMonth converts a google.type.Month to a golang Month.
|
||||
func ToMonth(m mpb.Month) time.Month {
|
||||
return time.Month(m.Number())
|
||||
}
|
||||
|
||||
// ToProtoMonth converts a golang Month to a google.type.Month.
|
||||
func ToProtoMonth(m time.Month) mpb.Month {
|
||||
return mpb.Month(m)
|
||||
}
|
10
vendor/github.com/klauspost/compress/README.md
generated
vendored
10
vendor/github.com/klauspost/compress/README.md
generated
vendored
|
@ -17,6 +17,16 @@ This package provides various compression algorithms.
|
|||
|
||||
# changelog
|
||||
|
||||
* July 13, 2022 (v1.15.8)
|
||||
|
||||
* gzip: fix stack exhaustion bug in Reader.Read https://github.com/klauspost/compress/pull/641
|
||||
* s2: Add Index header trim/restore https://github.com/klauspost/compress/pull/638
|
||||
* zstd: Optimize seqdeq amd64 asm by @greatroar in https://github.com/klauspost/compress/pull/636
|
||||
* zstd: Improve decoder memcopy https://github.com/klauspost/compress/pull/637
|
||||
* huff0: Pass a single bitReader pointer to asm by @greatroar in https://github.com/klauspost/compress/pull/634
|
||||
* zstd: Branchless getBits for amd64 w/o BMI2 by @greatroar in https://github.com/klauspost/compress/pull/640
|
||||
* gzhttp: Remove header before writing https://github.com/klauspost/compress/pull/639
|
||||
|
||||
* June 29, 2022 (v1.15.7)
|
||||
|
||||
* s2: Fix absolute forward seeks https://github.com/klauspost/compress/pull/633
|
||||
|
|
15
vendor/github.com/klauspost/compress/zstd/bytebuf.go
generated
vendored
15
vendor/github.com/klauspost/compress/zstd/bytebuf.go
generated
vendored
|
@ -23,7 +23,7 @@ type byteBuffer interface {
|
|||
readByte() (byte, error)
|
||||
|
||||
// Skip n bytes.
|
||||
skipN(n int) error
|
||||
skipN(n int64) error
|
||||
}
|
||||
|
||||
// in-memory buffer
|
||||
|
@ -62,9 +62,12 @@ func (b *byteBuf) readByte() (byte, error) {
|
|||
return r, nil
|
||||
}
|
||||
|
||||
func (b *byteBuf) skipN(n int) error {
|
||||
func (b *byteBuf) skipN(n int64) error {
|
||||
bb := *b
|
||||
if len(bb) < n {
|
||||
if n < 0 {
|
||||
return fmt.Errorf("negative skip (%d) requested", n)
|
||||
}
|
||||
if int64(len(bb)) < n {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
*b = bb[n:]
|
||||
|
@ -120,9 +123,9 @@ func (r *readerWrapper) readByte() (byte, error) {
|
|||
return r.tmp[0], nil
|
||||
}
|
||||
|
||||
func (r *readerWrapper) skipN(n int) error {
|
||||
n2, err := io.CopyN(ioutil.Discard, r.r, int64(n))
|
||||
if n2 != int64(n) {
|
||||
func (r *readerWrapper) skipN(n int64) error {
|
||||
n2, err := io.CopyN(ioutil.Discard, r.r, n)
|
||||
if n2 != n {
|
||||
err = io.ErrUnexpectedEOF
|
||||
}
|
||||
return err
|
||||
|
|
3
vendor/github.com/klauspost/compress/zstd/decoder.go
generated
vendored
3
vendor/github.com/klauspost/compress/zstd/decoder.go
generated
vendored
|
@ -348,6 +348,9 @@ func (d *Decoder) DecodeAll(input, dst []byte) ([]byte, error) {
|
|||
frame.history.setDict(&dict)
|
||||
}
|
||||
if frame.WindowSize > d.o.maxWindowSize {
|
||||
if debugDecoder {
|
||||
println("window size exceeded:", frame.WindowSize, ">", d.o.maxWindowSize)
|
||||
}
|
||||
return dst, ErrWindowSizeExceeded
|
||||
}
|
||||
if frame.FrameContentSize != fcsUnknown {
|
||||
|
|
4
vendor/github.com/klauspost/compress/zstd/encoder.go
generated
vendored
4
vendor/github.com/klauspost/compress/zstd/encoder.go
generated
vendored
|
@ -528,8 +528,8 @@ func (e *Encoder) EncodeAll(src, dst []byte) []byte {
|
|||
// If a non-single block is needed the encoder will reset again.
|
||||
e.encoders <- enc
|
||||
}()
|
||||
// Use single segments when above minimum window and below 1MB.
|
||||
single := len(src) < 1<<20 && len(src) > MinWindowSize
|
||||
// Use single segments when above minimum window and below window size.
|
||||
single := len(src) <= e.o.windowSize && len(src) > MinWindowSize
|
||||
if e.o.single != nil {
|
||||
single = *e.o.single
|
||||
}
|
||||
|
|
2
vendor/github.com/klauspost/compress/zstd/encoder_options.go
generated
vendored
2
vendor/github.com/klauspost/compress/zstd/encoder_options.go
generated
vendored
|
@ -283,7 +283,7 @@ func WithNoEntropyCompression(b bool) EOption {
|
|||
// a decoder is allowed to reject a compressed frame which requests a memory size beyond decoder's authorized range.
|
||||
// For broader compatibility, decoders are recommended to support memory sizes of at least 8 MB.
|
||||
// This is only a recommendation, each decoder is free to support higher or lower limits, depending on local limitations.
|
||||
// If this is not specified, block encodes will automatically choose this based on the input size.
|
||||
// If this is not specified, block encodes will automatically choose this based on the input size and the window size.
|
||||
// This setting has no effect on streamed encodes.
|
||||
func WithSingleSegment(b bool) EOption {
|
||||
return func(o *encoderOptions) error {
|
||||
|
|
21
vendor/github.com/klauspost/compress/zstd/framedec.go
generated
vendored
21
vendor/github.com/klauspost/compress/zstd/framedec.go
generated
vendored
|
@ -106,7 +106,7 @@ func (d *frameDec) reset(br byteBuffer) error {
|
|||
}
|
||||
n := uint32(b[0]) | (uint32(b[1]) << 8) | (uint32(b[2]) << 16) | (uint32(b[3]) << 24)
|
||||
println("Skipping frame with", n, "bytes.")
|
||||
err = br.skipN(int(n))
|
||||
err = br.skipN(int64(n))
|
||||
if err != nil {
|
||||
if debugDecoder {
|
||||
println("Reading discarded frame", err)
|
||||
|
@ -231,20 +231,27 @@ func (d *frameDec) reset(br byteBuffer) error {
|
|||
d.crc.Reset()
|
||||
}
|
||||
|
||||
if d.WindowSize > d.o.maxWindowSize {
|
||||
if debugDecoder {
|
||||
printf("window size %d > max %d\n", d.WindowSize, d.o.maxWindowSize)
|
||||
}
|
||||
return ErrWindowSizeExceeded
|
||||
}
|
||||
|
||||
if d.WindowSize == 0 && d.SingleSegment {
|
||||
// We may not need window in this case.
|
||||
d.WindowSize = d.FrameContentSize
|
||||
if d.WindowSize < MinWindowSize {
|
||||
d.WindowSize = MinWindowSize
|
||||
}
|
||||
if d.WindowSize > d.o.maxDecodedSize {
|
||||
if debugDecoder {
|
||||
printf("window size %d > max %d\n", d.WindowSize, d.o.maxWindowSize)
|
||||
}
|
||||
return ErrDecoderSizeExceeded
|
||||
}
|
||||
}
|
||||
|
||||
if d.WindowSize > uint64(d.o.maxWindowSize) {
|
||||
if debugDecoder {
|
||||
printf("window size %d > max %d\n", d.WindowSize, d.o.maxWindowSize)
|
||||
}
|
||||
return ErrWindowSizeExceeded
|
||||
}
|
||||
// The minimum Window_Size is 1 KB.
|
||||
if d.WindowSize < MinWindowSize {
|
||||
if debugDecoder {
|
||||
|
|
4
vendor/github.com/klauspost/compress/zstd/fse_decoder_amd64.go
generated
vendored
4
vendor/github.com/klauspost/compress/zstd/fse_decoder_amd64.go
generated
vendored
|
@ -34,8 +34,8 @@ const (
|
|||
// buildDtable will build the decoding table.
|
||||
func (s *fseDecoder) buildDtable() error {
|
||||
ctx := buildDtableAsmContext{
|
||||
stateTable: (*uint16)(&s.stateTable[0]),
|
||||
norm: (*int16)(&s.norm[0]),
|
||||
stateTable: &s.stateTable[0],
|
||||
norm: &s.norm[0],
|
||||
dt: (*uint64)(&s.dt[0]),
|
||||
}
|
||||
code := buildDtable_asm(s, &ctx)
|
||||
|
|
26
vendor/github.com/klauspost/compress/zstd/seqdec_amd64.go
generated
vendored
26
vendor/github.com/klauspost/compress/zstd/seqdec_amd64.go
generated
vendored
|
@ -55,16 +55,22 @@ func (s *sequenceDecs) decodeSyncSimple(hist []byte) (bool, error) {
|
|||
if s.maxSyncLen == 0 && cap(s.out)-len(s.out) < maxCompressedBlockSize {
|
||||
return false, nil
|
||||
}
|
||||
useSafe := false
|
||||
if s.maxSyncLen == 0 && cap(s.out)-len(s.out) < maxCompressedBlockSizeAlloc {
|
||||
useSafe = true
|
||||
}
|
||||
if s.maxSyncLen > 0 && cap(s.out)-len(s.out)-compressedBlockOverAlloc < int(s.maxSyncLen) {
|
||||
useSafe = true
|
||||
}
|
||||
if cap(s.literals) < len(s.literals)+compressedBlockOverAlloc {
|
||||
useSafe = true
|
||||
}
|
||||
|
||||
// FIXME: Using unsafe memory copies leads to rare, random crashes
|
||||
// with fuzz testing. It is therefore disabled for now.
|
||||
const useSafe = true
|
||||
/*
|
||||
useSafe := false
|
||||
if s.maxSyncLen == 0 && cap(s.out)-len(s.out) < maxCompressedBlockSizeAlloc {
|
||||
useSafe = true
|
||||
}
|
||||
if s.maxSyncLen > 0 && cap(s.out)-len(s.out)-compressedBlockOverAlloc < int(s.maxSyncLen) {
|
||||
useSafe = true
|
||||
}
|
||||
if cap(s.literals) < len(s.literals)+compressedBlockOverAlloc {
|
||||
useSafe = true
|
||||
}
|
||||
*/
|
||||
|
||||
br := s.br
|
||||
|
||||
|
|
460
vendor/github.com/klauspost/compress/zstd/seqdec_amd64.s
generated
vendored
460
vendor/github.com/klauspost/compress/zstd/seqdec_amd64.s
generated
vendored
|
@ -52,34 +52,46 @@ sequenceDecs_decode_amd64_fill_byte_by_byte:
|
|||
|
||||
sequenceDecs_decode_amd64_fill_end:
|
||||
// Update offset
|
||||
MOVQ R9, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R15
|
||||
SHLQ CL, R15
|
||||
MOVB AH, CL
|
||||
ADDQ CX, BX
|
||||
NEGL CX
|
||||
SHRQ CL, R15
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
CMOVQEQ CX, R15
|
||||
ADDQ R15, AX
|
||||
MOVQ AX, 16(R10)
|
||||
MOVQ R9, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R15
|
||||
SHLQ CL, R15
|
||||
MOVB AH, CL
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
JZ sequenceDecs_decode_amd64_of_update_zero
|
||||
ADDQ CX, BX
|
||||
CMPQ BX, $0x40
|
||||
JA sequenceDecs_decode_amd64_of_update_zero
|
||||
CMPQ CX, $0x40
|
||||
JAE sequenceDecs_decode_amd64_of_update_zero
|
||||
NEGQ CX
|
||||
SHRQ CL, R15
|
||||
ADDQ R15, AX
|
||||
|
||||
sequenceDecs_decode_amd64_of_update_zero:
|
||||
MOVQ AX, 16(R10)
|
||||
|
||||
// Update match length
|
||||
MOVQ R8, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R15
|
||||
SHLQ CL, R15
|
||||
MOVB AH, CL
|
||||
ADDQ CX, BX
|
||||
NEGL CX
|
||||
SHRQ CL, R15
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
CMOVQEQ CX, R15
|
||||
ADDQ R15, AX
|
||||
MOVQ AX, 8(R10)
|
||||
MOVQ R8, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R15
|
||||
SHLQ CL, R15
|
||||
MOVB AH, CL
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
JZ sequenceDecs_decode_amd64_ml_update_zero
|
||||
ADDQ CX, BX
|
||||
CMPQ BX, $0x40
|
||||
JA sequenceDecs_decode_amd64_ml_update_zero
|
||||
CMPQ CX, $0x40
|
||||
JAE sequenceDecs_decode_amd64_ml_update_zero
|
||||
NEGQ CX
|
||||
SHRQ CL, R15
|
||||
ADDQ R15, AX
|
||||
|
||||
sequenceDecs_decode_amd64_ml_update_zero:
|
||||
MOVQ AX, 8(R10)
|
||||
|
||||
// Fill bitreader to have enough for the remaining
|
||||
CMPQ SI, $0x08
|
||||
|
@ -107,19 +119,25 @@ sequenceDecs_decode_amd64_fill_2_byte_by_byte:
|
|||
|
||||
sequenceDecs_decode_amd64_fill_2_end:
|
||||
// Update literal length
|
||||
MOVQ DI, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R15
|
||||
SHLQ CL, R15
|
||||
MOVB AH, CL
|
||||
ADDQ CX, BX
|
||||
NEGL CX
|
||||
SHRQ CL, R15
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
CMOVQEQ CX, R15
|
||||
ADDQ R15, AX
|
||||
MOVQ AX, (R10)
|
||||
MOVQ DI, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R15
|
||||
SHLQ CL, R15
|
||||
MOVB AH, CL
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
JZ sequenceDecs_decode_amd64_ll_update_zero
|
||||
ADDQ CX, BX
|
||||
CMPQ BX, $0x40
|
||||
JA sequenceDecs_decode_amd64_ll_update_zero
|
||||
CMPQ CX, $0x40
|
||||
JAE sequenceDecs_decode_amd64_ll_update_zero
|
||||
NEGQ CX
|
||||
SHRQ CL, R15
|
||||
ADDQ R15, AX
|
||||
|
||||
sequenceDecs_decode_amd64_ll_update_zero:
|
||||
MOVQ AX, (R10)
|
||||
|
||||
// Fill bitreader for state updates
|
||||
MOVQ R14, (SP)
|
||||
|
@ -198,7 +216,7 @@ sequenceDecs_decode_amd64_skip_update:
|
|||
MOVQ R12, R13
|
||||
MOVQ R11, R12
|
||||
MOVQ CX, R11
|
||||
JMP sequenceDecs_decode_amd64_adjust_end
|
||||
JMP sequenceDecs_decode_amd64_after_adjust
|
||||
|
||||
sequenceDecs_decode_amd64_adjust_offsetB_1_or_0:
|
||||
CMPQ (R10), $0x00000000
|
||||
|
@ -210,7 +228,7 @@ sequenceDecs_decode_amd64_adjust_offset_maybezero:
|
|||
TESTQ CX, CX
|
||||
JNZ sequenceDecs_decode_amd64_adjust_offset_nonzero
|
||||
MOVQ R11, CX
|
||||
JMP sequenceDecs_decode_amd64_adjust_end
|
||||
JMP sequenceDecs_decode_amd64_after_adjust
|
||||
|
||||
sequenceDecs_decode_amd64_adjust_offset_nonzero:
|
||||
CMPQ CX, $0x01
|
||||
|
@ -247,7 +265,7 @@ sequenceDecs_decode_amd64_adjust_temp_valid:
|
|||
MOVQ AX, R11
|
||||
MOVQ AX, CX
|
||||
|
||||
sequenceDecs_decode_amd64_adjust_end:
|
||||
sequenceDecs_decode_amd64_after_adjust:
|
||||
MOVQ CX, 16(R10)
|
||||
|
||||
// Check values
|
||||
|
@ -356,49 +374,67 @@ sequenceDecs_decode_56_amd64_fill_byte_by_byte:
|
|||
|
||||
sequenceDecs_decode_56_amd64_fill_end:
|
||||
// Update offset
|
||||
MOVQ R9, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R15
|
||||
SHLQ CL, R15
|
||||
MOVB AH, CL
|
||||
ADDQ CX, BX
|
||||
NEGL CX
|
||||
SHRQ CL, R15
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
CMOVQEQ CX, R15
|
||||
ADDQ R15, AX
|
||||
MOVQ AX, 16(R10)
|
||||
MOVQ R9, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R15
|
||||
SHLQ CL, R15
|
||||
MOVB AH, CL
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
JZ sequenceDecs_decode_56_amd64_of_update_zero
|
||||
ADDQ CX, BX
|
||||
CMPQ BX, $0x40
|
||||
JA sequenceDecs_decode_56_amd64_of_update_zero
|
||||
CMPQ CX, $0x40
|
||||
JAE sequenceDecs_decode_56_amd64_of_update_zero
|
||||
NEGQ CX
|
||||
SHRQ CL, R15
|
||||
ADDQ R15, AX
|
||||
|
||||
sequenceDecs_decode_56_amd64_of_update_zero:
|
||||
MOVQ AX, 16(R10)
|
||||
|
||||
// Update match length
|
||||
MOVQ R8, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R15
|
||||
SHLQ CL, R15
|
||||
MOVB AH, CL
|
||||
ADDQ CX, BX
|
||||
NEGL CX
|
||||
SHRQ CL, R15
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
CMOVQEQ CX, R15
|
||||
ADDQ R15, AX
|
||||
MOVQ AX, 8(R10)
|
||||
MOVQ R8, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R15
|
||||
SHLQ CL, R15
|
||||
MOVB AH, CL
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
JZ sequenceDecs_decode_56_amd64_ml_update_zero
|
||||
ADDQ CX, BX
|
||||
CMPQ BX, $0x40
|
||||
JA sequenceDecs_decode_56_amd64_ml_update_zero
|
||||
CMPQ CX, $0x40
|
||||
JAE sequenceDecs_decode_56_amd64_ml_update_zero
|
||||
NEGQ CX
|
||||
SHRQ CL, R15
|
||||
ADDQ R15, AX
|
||||
|
||||
sequenceDecs_decode_56_amd64_ml_update_zero:
|
||||
MOVQ AX, 8(R10)
|
||||
|
||||
// Update literal length
|
||||
MOVQ DI, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R15
|
||||
SHLQ CL, R15
|
||||
MOVB AH, CL
|
||||
ADDQ CX, BX
|
||||
NEGL CX
|
||||
SHRQ CL, R15
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
CMOVQEQ CX, R15
|
||||
ADDQ R15, AX
|
||||
MOVQ AX, (R10)
|
||||
MOVQ DI, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R15
|
||||
SHLQ CL, R15
|
||||
MOVB AH, CL
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
JZ sequenceDecs_decode_56_amd64_ll_update_zero
|
||||
ADDQ CX, BX
|
||||
CMPQ BX, $0x40
|
||||
JA sequenceDecs_decode_56_amd64_ll_update_zero
|
||||
CMPQ CX, $0x40
|
||||
JAE sequenceDecs_decode_56_amd64_ll_update_zero
|
||||
NEGQ CX
|
||||
SHRQ CL, R15
|
||||
ADDQ R15, AX
|
||||
|
||||
sequenceDecs_decode_56_amd64_ll_update_zero:
|
||||
MOVQ AX, (R10)
|
||||
|
||||
// Fill bitreader for state updates
|
||||
MOVQ R14, (SP)
|
||||
|
@ -477,7 +513,7 @@ sequenceDecs_decode_56_amd64_skip_update:
|
|||
MOVQ R12, R13
|
||||
MOVQ R11, R12
|
||||
MOVQ CX, R11
|
||||
JMP sequenceDecs_decode_56_amd64_adjust_end
|
||||
JMP sequenceDecs_decode_56_amd64_after_adjust
|
||||
|
||||
sequenceDecs_decode_56_amd64_adjust_offsetB_1_or_0:
|
||||
CMPQ (R10), $0x00000000
|
||||
|
@ -489,7 +525,7 @@ sequenceDecs_decode_56_amd64_adjust_offset_maybezero:
|
|||
TESTQ CX, CX
|
||||
JNZ sequenceDecs_decode_56_amd64_adjust_offset_nonzero
|
||||
MOVQ R11, CX
|
||||
JMP sequenceDecs_decode_56_amd64_adjust_end
|
||||
JMP sequenceDecs_decode_56_amd64_after_adjust
|
||||
|
||||
sequenceDecs_decode_56_amd64_adjust_offset_nonzero:
|
||||
CMPQ CX, $0x01
|
||||
|
@ -526,7 +562,7 @@ sequenceDecs_decode_56_amd64_adjust_temp_valid:
|
|||
MOVQ AX, R11
|
||||
MOVQ AX, CX
|
||||
|
||||
sequenceDecs_decode_56_amd64_adjust_end:
|
||||
sequenceDecs_decode_56_amd64_after_adjust:
|
||||
MOVQ CX, 16(R10)
|
||||
|
||||
// Check values
|
||||
|
@ -757,7 +793,7 @@ sequenceDecs_decode_bmi2_skip_update:
|
|||
MOVQ R11, R12
|
||||
MOVQ R10, R11
|
||||
MOVQ CX, R10
|
||||
JMP sequenceDecs_decode_bmi2_adjust_end
|
||||
JMP sequenceDecs_decode_bmi2_after_adjust
|
||||
|
||||
sequenceDecs_decode_bmi2_adjust_offsetB_1_or_0:
|
||||
CMPQ (R9), $0x00000000
|
||||
|
@ -769,7 +805,7 @@ sequenceDecs_decode_bmi2_adjust_offset_maybezero:
|
|||
TESTQ CX, CX
|
||||
JNZ sequenceDecs_decode_bmi2_adjust_offset_nonzero
|
||||
MOVQ R10, CX
|
||||
JMP sequenceDecs_decode_bmi2_adjust_end
|
||||
JMP sequenceDecs_decode_bmi2_after_adjust
|
||||
|
||||
sequenceDecs_decode_bmi2_adjust_offset_nonzero:
|
||||
CMPQ CX, $0x01
|
||||
|
@ -806,7 +842,7 @@ sequenceDecs_decode_bmi2_adjust_temp_valid:
|
|||
MOVQ R13, R10
|
||||
MOVQ R13, CX
|
||||
|
||||
sequenceDecs_decode_bmi2_adjust_end:
|
||||
sequenceDecs_decode_bmi2_after_adjust:
|
||||
MOVQ CX, 16(R9)
|
||||
|
||||
// Check values
|
||||
|
@ -1012,7 +1048,7 @@ sequenceDecs_decode_56_bmi2_skip_update:
|
|||
MOVQ R11, R12
|
||||
MOVQ R10, R11
|
||||
MOVQ CX, R10
|
||||
JMP sequenceDecs_decode_56_bmi2_adjust_end
|
||||
JMP sequenceDecs_decode_56_bmi2_after_adjust
|
||||
|
||||
sequenceDecs_decode_56_bmi2_adjust_offsetB_1_or_0:
|
||||
CMPQ (R9), $0x00000000
|
||||
|
@ -1024,7 +1060,7 @@ sequenceDecs_decode_56_bmi2_adjust_offset_maybezero:
|
|||
TESTQ CX, CX
|
||||
JNZ sequenceDecs_decode_56_bmi2_adjust_offset_nonzero
|
||||
MOVQ R10, CX
|
||||
JMP sequenceDecs_decode_56_bmi2_adjust_end
|
||||
JMP sequenceDecs_decode_56_bmi2_after_adjust
|
||||
|
||||
sequenceDecs_decode_56_bmi2_adjust_offset_nonzero:
|
||||
CMPQ CX, $0x01
|
||||
|
@ -1061,7 +1097,7 @@ sequenceDecs_decode_56_bmi2_adjust_temp_valid:
|
|||
MOVQ R13, R10
|
||||
MOVQ R13, CX
|
||||
|
||||
sequenceDecs_decode_56_bmi2_adjust_end:
|
||||
sequenceDecs_decode_56_bmi2_after_adjust:
|
||||
MOVQ CX, 16(R9)
|
||||
|
||||
// Check values
|
||||
|
@ -1749,6 +1785,10 @@ TEXT ·sequenceDecs_decodeSync_amd64(SB), $64-32
|
|||
MOVQ 72(AX), DI
|
||||
MOVQ 80(AX), R8
|
||||
MOVQ 88(AX), R9
|
||||
XORQ CX, CX
|
||||
MOVQ CX, 8(SP)
|
||||
MOVQ CX, 16(SP)
|
||||
MOVQ CX, 24(SP)
|
||||
MOVQ 112(AX), R10
|
||||
MOVQ 128(AX), CX
|
||||
MOVQ CX, 32(SP)
|
||||
|
@ -1798,34 +1838,46 @@ sequenceDecs_decodeSync_amd64_fill_byte_by_byte:
|
|||
|
||||
sequenceDecs_decodeSync_amd64_fill_end:
|
||||
// Update offset
|
||||
MOVQ R9, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R14
|
||||
SHLQ CL, R14
|
||||
MOVB AH, CL
|
||||
ADDQ CX, BX
|
||||
NEGL CX
|
||||
SHRQ CL, R14
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
CMOVQEQ CX, R14
|
||||
ADDQ R14, AX
|
||||
MOVQ AX, 8(SP)
|
||||
MOVQ R9, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R14
|
||||
SHLQ CL, R14
|
||||
MOVB AH, CL
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
JZ sequenceDecs_decodeSync_amd64_of_update_zero
|
||||
ADDQ CX, BX
|
||||
CMPQ BX, $0x40
|
||||
JA sequenceDecs_decodeSync_amd64_of_update_zero
|
||||
CMPQ CX, $0x40
|
||||
JAE sequenceDecs_decodeSync_amd64_of_update_zero
|
||||
NEGQ CX
|
||||
SHRQ CL, R14
|
||||
ADDQ R14, AX
|
||||
|
||||
sequenceDecs_decodeSync_amd64_of_update_zero:
|
||||
MOVQ AX, 8(SP)
|
||||
|
||||
// Update match length
|
||||
MOVQ R8, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R14
|
||||
SHLQ CL, R14
|
||||
MOVB AH, CL
|
||||
ADDQ CX, BX
|
||||
NEGL CX
|
||||
SHRQ CL, R14
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
CMOVQEQ CX, R14
|
||||
ADDQ R14, AX
|
||||
MOVQ AX, 16(SP)
|
||||
MOVQ R8, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R14
|
||||
SHLQ CL, R14
|
||||
MOVB AH, CL
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
JZ sequenceDecs_decodeSync_amd64_ml_update_zero
|
||||
ADDQ CX, BX
|
||||
CMPQ BX, $0x40
|
||||
JA sequenceDecs_decodeSync_amd64_ml_update_zero
|
||||
CMPQ CX, $0x40
|
||||
JAE sequenceDecs_decodeSync_amd64_ml_update_zero
|
||||
NEGQ CX
|
||||
SHRQ CL, R14
|
||||
ADDQ R14, AX
|
||||
|
||||
sequenceDecs_decodeSync_amd64_ml_update_zero:
|
||||
MOVQ AX, 16(SP)
|
||||
|
||||
// Fill bitreader to have enough for the remaining
|
||||
CMPQ SI, $0x08
|
||||
|
@ -1853,19 +1905,25 @@ sequenceDecs_decodeSync_amd64_fill_2_byte_by_byte:
|
|||
|
||||
sequenceDecs_decodeSync_amd64_fill_2_end:
|
||||
// Update literal length
|
||||
MOVQ DI, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R14
|
||||
SHLQ CL, R14
|
||||
MOVB AH, CL
|
||||
ADDQ CX, BX
|
||||
NEGL CX
|
||||
SHRQ CL, R14
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
CMOVQEQ CX, R14
|
||||
ADDQ R14, AX
|
||||
MOVQ AX, 24(SP)
|
||||
MOVQ DI, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R14
|
||||
SHLQ CL, R14
|
||||
MOVB AH, CL
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
JZ sequenceDecs_decodeSync_amd64_ll_update_zero
|
||||
ADDQ CX, BX
|
||||
CMPQ BX, $0x40
|
||||
JA sequenceDecs_decodeSync_amd64_ll_update_zero
|
||||
CMPQ CX, $0x40
|
||||
JAE sequenceDecs_decodeSync_amd64_ll_update_zero
|
||||
NEGQ CX
|
||||
SHRQ CL, R14
|
||||
ADDQ R14, AX
|
||||
|
||||
sequenceDecs_decodeSync_amd64_ll_update_zero:
|
||||
MOVQ AX, 24(SP)
|
||||
|
||||
// Fill bitreader for state updates
|
||||
MOVQ R13, (SP)
|
||||
|
@ -1945,7 +2003,7 @@ sequenceDecs_decodeSync_amd64_skip_update:
|
|||
MOVUPS 144(CX), X0
|
||||
MOVQ R13, 144(CX)
|
||||
MOVUPS X0, 152(CX)
|
||||
JMP sequenceDecs_decodeSync_amd64_adjust_end
|
||||
JMP sequenceDecs_decodeSync_amd64_after_adjust
|
||||
|
||||
sequenceDecs_decodeSync_amd64_adjust_offsetB_1_or_0:
|
||||
CMPQ 24(SP), $0x00000000
|
||||
|
@ -1957,7 +2015,7 @@ sequenceDecs_decodeSync_amd64_adjust_offset_maybezero:
|
|||
TESTQ R13, R13
|
||||
JNZ sequenceDecs_decodeSync_amd64_adjust_offset_nonzero
|
||||
MOVQ 144(CX), R13
|
||||
JMP sequenceDecs_decodeSync_amd64_adjust_end
|
||||
JMP sequenceDecs_decodeSync_amd64_after_adjust
|
||||
|
||||
sequenceDecs_decodeSync_amd64_adjust_offset_nonzero:
|
||||
MOVQ R13, AX
|
||||
|
@ -1966,8 +2024,7 @@ sequenceDecs_decodeSync_amd64_adjust_offset_nonzero:
|
|||
CMPQ R13, $0x03
|
||||
CMOVQEQ R14, AX
|
||||
CMOVQEQ R15, R14
|
||||
LEAQ 144(CX), R15
|
||||
ADDQ (R15)(AX*8), R14
|
||||
ADDQ 144(CX)(AX*8), R14
|
||||
JNZ sequenceDecs_decodeSync_amd64_adjust_temp_valid
|
||||
MOVQ $0x00000001, R14
|
||||
|
||||
|
@ -1983,7 +2040,7 @@ sequenceDecs_decodeSync_amd64_adjust_skip:
|
|||
MOVQ R14, 144(CX)
|
||||
MOVQ R14, R13
|
||||
|
||||
sequenceDecs_decodeSync_amd64_adjust_end:
|
||||
sequenceDecs_decodeSync_amd64_after_adjust:
|
||||
MOVQ R13, 8(SP)
|
||||
|
||||
// Check values
|
||||
|
@ -2280,6 +2337,10 @@ TEXT ·sequenceDecs_decodeSync_bmi2(SB), $64-32
|
|||
MOVQ 72(CX), SI
|
||||
MOVQ 80(CX), DI
|
||||
MOVQ 88(CX), R8
|
||||
XORQ R9, R9
|
||||
MOVQ R9, 8(SP)
|
||||
MOVQ R9, 16(SP)
|
||||
MOVQ R9, 24(SP)
|
||||
MOVQ 112(CX), R9
|
||||
MOVQ 128(CX), R10
|
||||
MOVQ R10, 32(SP)
|
||||
|
@ -2452,7 +2513,7 @@ sequenceDecs_decodeSync_bmi2_skip_update:
|
|||
MOVUPS 144(CX), X0
|
||||
MOVQ R13, 144(CX)
|
||||
MOVUPS X0, 152(CX)
|
||||
JMP sequenceDecs_decodeSync_bmi2_adjust_end
|
||||
JMP sequenceDecs_decodeSync_bmi2_after_adjust
|
||||
|
||||
sequenceDecs_decodeSync_bmi2_adjust_offsetB_1_or_0:
|
||||
CMPQ 24(SP), $0x00000000
|
||||
|
@ -2464,7 +2525,7 @@ sequenceDecs_decodeSync_bmi2_adjust_offset_maybezero:
|
|||
TESTQ R13, R13
|
||||
JNZ sequenceDecs_decodeSync_bmi2_adjust_offset_nonzero
|
||||
MOVQ 144(CX), R13
|
||||
JMP sequenceDecs_decodeSync_bmi2_adjust_end
|
||||
JMP sequenceDecs_decodeSync_bmi2_after_adjust
|
||||
|
||||
sequenceDecs_decodeSync_bmi2_adjust_offset_nonzero:
|
||||
MOVQ R13, R12
|
||||
|
@ -2473,8 +2534,7 @@ sequenceDecs_decodeSync_bmi2_adjust_offset_nonzero:
|
|||
CMPQ R13, $0x03
|
||||
CMOVQEQ R14, R12
|
||||
CMOVQEQ R15, R14
|
||||
LEAQ 144(CX), R15
|
||||
ADDQ (R15)(R12*8), R14
|
||||
ADDQ 144(CX)(R12*8), R14
|
||||
JNZ sequenceDecs_decodeSync_bmi2_adjust_temp_valid
|
||||
MOVQ $0x00000001, R14
|
||||
|
||||
|
@ -2490,7 +2550,7 @@ sequenceDecs_decodeSync_bmi2_adjust_skip:
|
|||
MOVQ R14, 144(CX)
|
||||
MOVQ R14, R13
|
||||
|
||||
sequenceDecs_decodeSync_bmi2_adjust_end:
|
||||
sequenceDecs_decodeSync_bmi2_after_adjust:
|
||||
MOVQ R13, 8(SP)
|
||||
|
||||
// Check values
|
||||
|
@ -2787,6 +2847,10 @@ TEXT ·sequenceDecs_decodeSync_safe_amd64(SB), $64-32
|
|||
MOVQ 72(AX), DI
|
||||
MOVQ 80(AX), R8
|
||||
MOVQ 88(AX), R9
|
||||
XORQ CX, CX
|
||||
MOVQ CX, 8(SP)
|
||||
MOVQ CX, 16(SP)
|
||||
MOVQ CX, 24(SP)
|
||||
MOVQ 112(AX), R10
|
||||
MOVQ 128(AX), CX
|
||||
MOVQ CX, 32(SP)
|
||||
|
@ -2836,34 +2900,46 @@ sequenceDecs_decodeSync_safe_amd64_fill_byte_by_byte:
|
|||
|
||||
sequenceDecs_decodeSync_safe_amd64_fill_end:
|
||||
// Update offset
|
||||
MOVQ R9, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R14
|
||||
SHLQ CL, R14
|
||||
MOVB AH, CL
|
||||
ADDQ CX, BX
|
||||
NEGL CX
|
||||
SHRQ CL, R14
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
CMOVQEQ CX, R14
|
||||
ADDQ R14, AX
|
||||
MOVQ AX, 8(SP)
|
||||
MOVQ R9, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R14
|
||||
SHLQ CL, R14
|
||||
MOVB AH, CL
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
JZ sequenceDecs_decodeSync_safe_amd64_of_update_zero
|
||||
ADDQ CX, BX
|
||||
CMPQ BX, $0x40
|
||||
JA sequenceDecs_decodeSync_safe_amd64_of_update_zero
|
||||
CMPQ CX, $0x40
|
||||
JAE sequenceDecs_decodeSync_safe_amd64_of_update_zero
|
||||
NEGQ CX
|
||||
SHRQ CL, R14
|
||||
ADDQ R14, AX
|
||||
|
||||
sequenceDecs_decodeSync_safe_amd64_of_update_zero:
|
||||
MOVQ AX, 8(SP)
|
||||
|
||||
// Update match length
|
||||
MOVQ R8, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R14
|
||||
SHLQ CL, R14
|
||||
MOVB AH, CL
|
||||
ADDQ CX, BX
|
||||
NEGL CX
|
||||
SHRQ CL, R14
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
CMOVQEQ CX, R14
|
||||
ADDQ R14, AX
|
||||
MOVQ AX, 16(SP)
|
||||
MOVQ R8, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R14
|
||||
SHLQ CL, R14
|
||||
MOVB AH, CL
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
JZ sequenceDecs_decodeSync_safe_amd64_ml_update_zero
|
||||
ADDQ CX, BX
|
||||
CMPQ BX, $0x40
|
||||
JA sequenceDecs_decodeSync_safe_amd64_ml_update_zero
|
||||
CMPQ CX, $0x40
|
||||
JAE sequenceDecs_decodeSync_safe_amd64_ml_update_zero
|
||||
NEGQ CX
|
||||
SHRQ CL, R14
|
||||
ADDQ R14, AX
|
||||
|
||||
sequenceDecs_decodeSync_safe_amd64_ml_update_zero:
|
||||
MOVQ AX, 16(SP)
|
||||
|
||||
// Fill bitreader to have enough for the remaining
|
||||
CMPQ SI, $0x08
|
||||
|
@ -2891,19 +2967,25 @@ sequenceDecs_decodeSync_safe_amd64_fill_2_byte_by_byte:
|
|||
|
||||
sequenceDecs_decodeSync_safe_amd64_fill_2_end:
|
||||
// Update literal length
|
||||
MOVQ DI, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R14
|
||||
SHLQ CL, R14
|
||||
MOVB AH, CL
|
||||
ADDQ CX, BX
|
||||
NEGL CX
|
||||
SHRQ CL, R14
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
CMOVQEQ CX, R14
|
||||
ADDQ R14, AX
|
||||
MOVQ AX, 24(SP)
|
||||
MOVQ DI, AX
|
||||
MOVQ BX, CX
|
||||
MOVQ DX, R14
|
||||
SHLQ CL, R14
|
||||
MOVB AH, CL
|
||||
SHRQ $0x20, AX
|
||||
TESTQ CX, CX
|
||||
JZ sequenceDecs_decodeSync_safe_amd64_ll_update_zero
|
||||
ADDQ CX, BX
|
||||
CMPQ BX, $0x40
|
||||
JA sequenceDecs_decodeSync_safe_amd64_ll_update_zero
|
||||
CMPQ CX, $0x40
|
||||
JAE sequenceDecs_decodeSync_safe_amd64_ll_update_zero
|
||||
NEGQ CX
|
||||
SHRQ CL, R14
|
||||
ADDQ R14, AX
|
||||
|
||||
sequenceDecs_decodeSync_safe_amd64_ll_update_zero:
|
||||
MOVQ AX, 24(SP)
|
||||
|
||||
// Fill bitreader for state updates
|
||||
MOVQ R13, (SP)
|
||||
|
@ -2983,7 +3065,7 @@ sequenceDecs_decodeSync_safe_amd64_skip_update:
|
|||
MOVUPS 144(CX), X0
|
||||
MOVQ R13, 144(CX)
|
||||
MOVUPS X0, 152(CX)
|
||||
JMP sequenceDecs_decodeSync_safe_amd64_adjust_end
|
||||
JMP sequenceDecs_decodeSync_safe_amd64_after_adjust
|
||||
|
||||
sequenceDecs_decodeSync_safe_amd64_adjust_offsetB_1_or_0:
|
||||
CMPQ 24(SP), $0x00000000
|
||||
|
@ -2995,7 +3077,7 @@ sequenceDecs_decodeSync_safe_amd64_adjust_offset_maybezero:
|
|||
TESTQ R13, R13
|
||||
JNZ sequenceDecs_decodeSync_safe_amd64_adjust_offset_nonzero
|
||||
MOVQ 144(CX), R13
|
||||
JMP sequenceDecs_decodeSync_safe_amd64_adjust_end
|
||||
JMP sequenceDecs_decodeSync_safe_amd64_after_adjust
|
||||
|
||||
sequenceDecs_decodeSync_safe_amd64_adjust_offset_nonzero:
|
||||
MOVQ R13, AX
|
||||
|
@ -3004,8 +3086,7 @@ sequenceDecs_decodeSync_safe_amd64_adjust_offset_nonzero:
|
|||
CMPQ R13, $0x03
|
||||
CMOVQEQ R14, AX
|
||||
CMOVQEQ R15, R14
|
||||
LEAQ 144(CX), R15
|
||||
ADDQ (R15)(AX*8), R14
|
||||
ADDQ 144(CX)(AX*8), R14
|
||||
JNZ sequenceDecs_decodeSync_safe_amd64_adjust_temp_valid
|
||||
MOVQ $0x00000001, R14
|
||||
|
||||
|
@ -3021,7 +3102,7 @@ sequenceDecs_decodeSync_safe_amd64_adjust_skip:
|
|||
MOVQ R14, 144(CX)
|
||||
MOVQ R14, R13
|
||||
|
||||
sequenceDecs_decodeSync_safe_amd64_adjust_end:
|
||||
sequenceDecs_decodeSync_safe_amd64_after_adjust:
|
||||
MOVQ R13, 8(SP)
|
||||
|
||||
// Check values
|
||||
|
@ -3420,6 +3501,10 @@ TEXT ·sequenceDecs_decodeSync_safe_bmi2(SB), $64-32
|
|||
MOVQ 72(CX), SI
|
||||
MOVQ 80(CX), DI
|
||||
MOVQ 88(CX), R8
|
||||
XORQ R9, R9
|
||||
MOVQ R9, 8(SP)
|
||||
MOVQ R9, 16(SP)
|
||||
MOVQ R9, 24(SP)
|
||||
MOVQ 112(CX), R9
|
||||
MOVQ 128(CX), R10
|
||||
MOVQ R10, 32(SP)
|
||||
|
@ -3592,7 +3677,7 @@ sequenceDecs_decodeSync_safe_bmi2_skip_update:
|
|||
MOVUPS 144(CX), X0
|
||||
MOVQ R13, 144(CX)
|
||||
MOVUPS X0, 152(CX)
|
||||
JMP sequenceDecs_decodeSync_safe_bmi2_adjust_end
|
||||
JMP sequenceDecs_decodeSync_safe_bmi2_after_adjust
|
||||
|
||||
sequenceDecs_decodeSync_safe_bmi2_adjust_offsetB_1_or_0:
|
||||
CMPQ 24(SP), $0x00000000
|
||||
|
@ -3604,7 +3689,7 @@ sequenceDecs_decodeSync_safe_bmi2_adjust_offset_maybezero:
|
|||
TESTQ R13, R13
|
||||
JNZ sequenceDecs_decodeSync_safe_bmi2_adjust_offset_nonzero
|
||||
MOVQ 144(CX), R13
|
||||
JMP sequenceDecs_decodeSync_safe_bmi2_adjust_end
|
||||
JMP sequenceDecs_decodeSync_safe_bmi2_after_adjust
|
||||
|
||||
sequenceDecs_decodeSync_safe_bmi2_adjust_offset_nonzero:
|
||||
MOVQ R13, R12
|
||||
|
@ -3613,8 +3698,7 @@ sequenceDecs_decodeSync_safe_bmi2_adjust_offset_nonzero:
|
|||
CMPQ R13, $0x03
|
||||
CMOVQEQ R14, R12
|
||||
CMOVQEQ R15, R14
|
||||
LEAQ 144(CX), R15
|
||||
ADDQ (R15)(R12*8), R14
|
||||
ADDQ 144(CX)(R12*8), R14
|
||||
JNZ sequenceDecs_decodeSync_safe_bmi2_adjust_temp_valid
|
||||
MOVQ $0x00000001, R14
|
||||
|
||||
|
@ -3630,7 +3714,7 @@ sequenceDecs_decodeSync_safe_bmi2_adjust_skip:
|
|||
MOVQ R14, 144(CX)
|
||||
MOVQ R14, R13
|
||||
|
||||
sequenceDecs_decodeSync_safe_bmi2_adjust_end:
|
||||
sequenceDecs_decodeSync_safe_bmi2_after_adjust:
|
||||
MOVQ R13, 8(SP)
|
||||
|
||||
// Check values
|
||||
|
|
2
vendor/github.com/urfave/cli/v2/flag_timestamp.go
generated
vendored
2
vendor/github.com/urfave/cli/v2/flag_timestamp.go
generated
vendored
|
@ -90,7 +90,7 @@ func (f *TimestampFlag) GetCategory() string {
|
|||
// GetValue returns the flags value as string representation and an empty
|
||||
// string if the flag takes no value at all.
|
||||
func (f *TimestampFlag) GetValue() string {
|
||||
if f.Value != nil {
|
||||
if f.Value != nil && f.Value.timestamp != nil {
|
||||
return f.Value.timestamp.String()
|
||||
}
|
||||
return ""
|
||||
|
|
18
vendor/golang.org/x/oauth2/google/google.go
generated
vendored
18
vendor/golang.org/x/oauth2/google/google.go
generated
vendored
|
@ -122,6 +122,7 @@ type credentialsFile struct {
|
|||
TokenURLExternal string `json:"token_url"`
|
||||
TokenInfoURL string `json:"token_info_url"`
|
||||
ServiceAccountImpersonationURL string `json:"service_account_impersonation_url"`
|
||||
ServiceAccountImpersonation serviceAccountImpersonationInfo `json:"service_account_impersonation"`
|
||||
Delegates []string `json:"delegates"`
|
||||
CredentialSource externalaccount.CredentialSource `json:"credential_source"`
|
||||
QuotaProjectID string `json:"quota_project_id"`
|
||||
|
@ -131,6 +132,10 @@ type credentialsFile struct {
|
|||
SourceCredentials *credentialsFile `json:"source_credentials"`
|
||||
}
|
||||
|
||||
type serviceAccountImpersonationInfo struct {
|
||||
TokenLifetimeSeconds int `json:"token_lifetime_seconds"`
|
||||
}
|
||||
|
||||
func (f *credentialsFile) jwtConfig(scopes []string, subject string) *jwt.Config {
|
||||
cfg := &jwt.Config{
|
||||
Email: f.ClientEmail,
|
||||
|
@ -178,12 +183,13 @@ func (f *credentialsFile) tokenSource(ctx context.Context, params CredentialsPar
|
|||
TokenURL: f.TokenURLExternal,
|
||||
TokenInfoURL: f.TokenInfoURL,
|
||||
ServiceAccountImpersonationURL: f.ServiceAccountImpersonationURL,
|
||||
ClientSecret: f.ClientSecret,
|
||||
ClientID: f.ClientID,
|
||||
CredentialSource: f.CredentialSource,
|
||||
QuotaProjectID: f.QuotaProjectID,
|
||||
Scopes: params.Scopes,
|
||||
WorkforcePoolUserProject: f.WorkforcePoolUserProject,
|
||||
ServiceAccountImpersonationLifetimeSeconds: f.ServiceAccountImpersonation.TokenLifetimeSeconds,
|
||||
ClientSecret: f.ClientSecret,
|
||||
ClientID: f.ClientID,
|
||||
CredentialSource: f.CredentialSource,
|
||||
QuotaProjectID: f.QuotaProjectID,
|
||||
Scopes: params.Scopes,
|
||||
WorkforcePoolUserProject: f.WorkforcePoolUserProject,
|
||||
}
|
||||
return cfg.TokenSource(ctx)
|
||||
case impersonatedServiceAccount:
|
||||
|
|
12
vendor/golang.org/x/oauth2/google/internal/externalaccount/basecredentials.go
generated
vendored
12
vendor/golang.org/x/oauth2/google/internal/externalaccount/basecredentials.go
generated
vendored
|
@ -39,6 +39,9 @@ type Config struct {
|
|||
// ServiceAccountImpersonationURL is the URL for the service account impersonation request. This is only
|
||||
// required for workload identity pools when APIs to be accessed have not integrated with UberMint.
|
||||
ServiceAccountImpersonationURL string
|
||||
// ServiceAccountImpersonationLifetimeSeconds is the number of seconds the service account impersonation
|
||||
// token will be valid for.
|
||||
ServiceAccountImpersonationLifetimeSeconds int
|
||||
// ClientSecret is currently only required if token_info endpoint also
|
||||
// needs to be called with the generated GCP access token. When provided, STS will be
|
||||
// called with additional basic authentication using client_id as username and client_secret as password.
|
||||
|
@ -141,10 +144,11 @@ func (c *Config) tokenSource(ctx context.Context, tokenURLValidPats []*regexp.Re
|
|||
scopes := c.Scopes
|
||||
ts.conf.Scopes = []string{"https://www.googleapis.com/auth/cloud-platform"}
|
||||
imp := ImpersonateTokenSource{
|
||||
Ctx: ctx,
|
||||
URL: c.ServiceAccountImpersonationURL,
|
||||
Scopes: scopes,
|
||||
Ts: oauth2.ReuseTokenSource(nil, ts),
|
||||
Ctx: ctx,
|
||||
URL: c.ServiceAccountImpersonationURL,
|
||||
Scopes: scopes,
|
||||
Ts: oauth2.ReuseTokenSource(nil, ts),
|
||||
TokenLifetimeSeconds: c.ServiceAccountImpersonationLifetimeSeconds,
|
||||
}
|
||||
return oauth2.ReuseTokenSource(nil, imp), nil
|
||||
}
|
||||
|
|
9
vendor/golang.org/x/oauth2/google/internal/externalaccount/impersonate.go
generated
vendored
9
vendor/golang.org/x/oauth2/google/internal/externalaccount/impersonate.go
generated
vendored
|
@ -48,12 +48,19 @@ type ImpersonateTokenSource struct {
|
|||
// Each service account must be granted roles/iam.serviceAccountTokenCreator
|
||||
// on the next service account in the chain. Optional.
|
||||
Delegates []string
|
||||
// TokenLifetimeSeconds is the number of seconds the impersonation token will
|
||||
// be valid for.
|
||||
TokenLifetimeSeconds int
|
||||
}
|
||||
|
||||
// Token performs the exchange to get a temporary service account token to allow access to GCP.
|
||||
func (its ImpersonateTokenSource) Token() (*oauth2.Token, error) {
|
||||
lifetimeString := "3600s"
|
||||
if its.TokenLifetimeSeconds != 0 {
|
||||
lifetimeString = fmt.Sprintf("%ds", its.TokenLifetimeSeconds)
|
||||
}
|
||||
reqBody := generateAccessTokenReq{
|
||||
Lifetime: "3600s",
|
||||
Lifetime: lifetimeString,
|
||||
Scope: its.Scopes,
|
||||
Delegates: its.Delegates,
|
||||
}
|
||||
|
|
2
vendor/google.golang.org/api/internal/version.go
generated
vendored
2
vendor/google.golang.org/api/internal/version.go
generated
vendored
|
@ -5,4 +5,4 @@
|
|||
package internal
|
||||
|
||||
// Version is the current tagged release of the library.
|
||||
const Version = "0.87.0"
|
||||
const Version = "0.88.0"
|
||||
|
|
335
vendor/google.golang.org/genproto/googleapis/type/color/color.pb.go
generated
vendored
335
vendor/google.golang.org/genproto/googleapis/type/color/color.pb.go
generated
vendored
|
@ -1,335 +0,0 @@
|
|||
// Copyright 2021 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.26.0
|
||||
// protoc v3.12.2
|
||||
// source: google/type/color.proto
|
||||
|
||||
package color
|
||||
|
||||
import (
|
||||
reflect "reflect"
|
||||
sync "sync"
|
||||
|
||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||
wrapperspb "google.golang.org/protobuf/types/known/wrapperspb"
|
||||
)
|
||||
|
||||
const (
|
||||
// Verify that this generated code is sufficiently up-to-date.
|
||||
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
|
||||
// Verify that runtime/protoimpl is sufficiently up-to-date.
|
||||
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
||||
)
|
||||
|
||||
// Represents a color in the RGBA color space. This representation is designed
|
||||
// for simplicity of conversion to/from color representations in various
|
||||
// languages over compactness. For example, the fields of this representation
|
||||
// can be trivially provided to the constructor of `java.awt.Color` in Java; it
|
||||
// can also be trivially provided to UIColor's `+colorWithRed:green:blue:alpha`
|
||||
// method in iOS; and, with just a little work, it can be easily formatted into
|
||||
// a CSS `rgba()` string in JavaScript.
|
||||
//
|
||||
// This reference page doesn't carry information about the absolute color
|
||||
// space
|
||||
// that should be used to interpret the RGB value (e.g. sRGB, Adobe RGB,
|
||||
// DCI-P3, BT.2020, etc.). By default, applications should assume the sRGB color
|
||||
// space.
|
||||
//
|
||||
// When color equality needs to be decided, implementations, unless
|
||||
// documented otherwise, treat two colors as equal if all their red,
|
||||
// green, blue, and alpha values each differ by at most 1e-5.
|
||||
//
|
||||
// Example (Java):
|
||||
//
|
||||
// import com.google.type.Color;
|
||||
//
|
||||
// // ...
|
||||
// public static java.awt.Color fromProto(Color protocolor) {
|
||||
// float alpha = protocolor.hasAlpha()
|
||||
// ? protocolor.getAlpha().getValue()
|
||||
// : 1.0;
|
||||
//
|
||||
// return new java.awt.Color(
|
||||
// protocolor.getRed(),
|
||||
// protocolor.getGreen(),
|
||||
// protocolor.getBlue(),
|
||||
// alpha);
|
||||
// }
|
||||
//
|
||||
// public static Color toProto(java.awt.Color color) {
|
||||
// float red = (float) color.getRed();
|
||||
// float green = (float) color.getGreen();
|
||||
// float blue = (float) color.getBlue();
|
||||
// float denominator = 255.0;
|
||||
// Color.Builder resultBuilder =
|
||||
// Color
|
||||
// .newBuilder()
|
||||
// .setRed(red / denominator)
|
||||
// .setGreen(green / denominator)
|
||||
// .setBlue(blue / denominator);
|
||||
// int alpha = color.getAlpha();
|
||||
// if (alpha != 255) {
|
||||
// result.setAlpha(
|
||||
// FloatValue
|
||||
// .newBuilder()
|
||||
// .setValue(((float) alpha) / denominator)
|
||||
// .build());
|
||||
// }
|
||||
// return resultBuilder.build();
|
||||
// }
|
||||
// // ...
|
||||
//
|
||||
// Example (iOS / Obj-C):
|
||||
//
|
||||
// // ...
|
||||
// static UIColor* fromProto(Color* protocolor) {
|
||||
// float red = [protocolor red];
|
||||
// float green = [protocolor green];
|
||||
// float blue = [protocolor blue];
|
||||
// FloatValue* alpha_wrapper = [protocolor alpha];
|
||||
// float alpha = 1.0;
|
||||
// if (alpha_wrapper != nil) {
|
||||
// alpha = [alpha_wrapper value];
|
||||
// }
|
||||
// return [UIColor colorWithRed:red green:green blue:blue alpha:alpha];
|
||||
// }
|
||||
//
|
||||
// static Color* toProto(UIColor* color) {
|
||||
// CGFloat red, green, blue, alpha;
|
||||
// if (![color getRed:&red green:&green blue:&blue alpha:&alpha]) {
|
||||
// return nil;
|
||||
// }
|
||||
// Color* result = [[Color alloc] init];
|
||||
// [result setRed:red];
|
||||
// [result setGreen:green];
|
||||
// [result setBlue:blue];
|
||||
// if (alpha <= 0.9999) {
|
||||
// [result setAlpha:floatWrapperWithValue(alpha)];
|
||||
// }
|
||||
// [result autorelease];
|
||||
// return result;
|
||||
// }
|
||||
// // ...
|
||||
//
|
||||
// Example (JavaScript):
|
||||
//
|
||||
// // ...
|
||||
//
|
||||
// var protoToCssColor = function(rgb_color) {
|
||||
// var redFrac = rgb_color.red || 0.0;
|
||||
// var greenFrac = rgb_color.green || 0.0;
|
||||
// var blueFrac = rgb_color.blue || 0.0;
|
||||
// var red = Math.floor(redFrac * 255);
|
||||
// var green = Math.floor(greenFrac * 255);
|
||||
// var blue = Math.floor(blueFrac * 255);
|
||||
//
|
||||
// if (!('alpha' in rgb_color)) {
|
||||
// return rgbToCssColor(red, green, blue);
|
||||
// }
|
||||
//
|
||||
// var alphaFrac = rgb_color.alpha.value || 0.0;
|
||||
// var rgbParams = [red, green, blue].join(',');
|
||||
// return ['rgba(', rgbParams, ',', alphaFrac, ')'].join('');
|
||||
// };
|
||||
//
|
||||
// var rgbToCssColor = function(red, green, blue) {
|
||||
// var rgbNumber = new Number((red << 16) | (green << 8) | blue);
|
||||
// var hexString = rgbNumber.toString(16);
|
||||
// var missingZeros = 6 - hexString.length;
|
||||
// var resultBuilder = ['#'];
|
||||
// for (var i = 0; i < missingZeros; i++) {
|
||||
// resultBuilder.push('0');
|
||||
// }
|
||||
// resultBuilder.push(hexString);
|
||||
// return resultBuilder.join('');
|
||||
// };
|
||||
//
|
||||
// // ...
|
||||
type Color struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
// The amount of red in the color as a value in the interval [0, 1].
|
||||
Red float32 `protobuf:"fixed32,1,opt,name=red,proto3" json:"red,omitempty"`
|
||||
// The amount of green in the color as a value in the interval [0, 1].
|
||||
Green float32 `protobuf:"fixed32,2,opt,name=green,proto3" json:"green,omitempty"`
|
||||
// The amount of blue in the color as a value in the interval [0, 1].
|
||||
Blue float32 `protobuf:"fixed32,3,opt,name=blue,proto3" json:"blue,omitempty"`
|
||||
// The fraction of this color that should be applied to the pixel. That is,
|
||||
// the final pixel color is defined by the equation:
|
||||
//
|
||||
// `pixel color = alpha * (this color) + (1.0 - alpha) * (background color)`
|
||||
//
|
||||
// This means that a value of 1.0 corresponds to a solid color, whereas
|
||||
// a value of 0.0 corresponds to a completely transparent color. This
|
||||
// uses a wrapper message rather than a simple float scalar so that it is
|
||||
// possible to distinguish between a default value and the value being unset.
|
||||
// If omitted, this color object is rendered as a solid color
|
||||
// (as if the alpha value had been explicitly given a value of 1.0).
|
||||
Alpha *wrapperspb.FloatValue `protobuf:"bytes,4,opt,name=alpha,proto3" json:"alpha,omitempty"`
|
||||
}
|
||||
|
||||
func (x *Color) Reset() {
|
||||
*x = Color{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_google_type_color_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *Color) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*Color) ProtoMessage() {}
|
||||
|
||||
func (x *Color) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_google_type_color_proto_msgTypes[0]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use Color.ProtoReflect.Descriptor instead.
|
||||
func (*Color) Descriptor() ([]byte, []int) {
|
||||
return file_google_type_color_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *Color) GetRed() float32 {
|
||||
if x != nil {
|
||||
return x.Red
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *Color) GetGreen() float32 {
|
||||
if x != nil {
|
||||
return x.Green
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *Color) GetBlue() float32 {
|
||||
if x != nil {
|
||||
return x.Blue
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *Color) GetAlpha() *wrapperspb.FloatValue {
|
||||
if x != nil {
|
||||
return x.Alpha
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
var File_google_type_color_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_google_type_color_proto_rawDesc = []byte{
|
||||
0x0a, 0x17, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x2f, 0x63, 0x6f,
|
||||
0x6c, 0x6f, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0b, 0x67, 0x6f, 0x6f, 0x67, 0x6c,
|
||||
0x65, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x1a, 0x1e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70,
|
||||
0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72, 0x73,
|
||||
0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x76, 0x0a, 0x05, 0x43, 0x6f, 0x6c, 0x6f, 0x72, 0x12,
|
||||
0x10, 0x0a, 0x03, 0x72, 0x65, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x02, 0x52, 0x03, 0x72, 0x65,
|
||||
0x64, 0x12, 0x14, 0x0a, 0x05, 0x67, 0x72, 0x65, 0x65, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x02,
|
||||
0x52, 0x05, 0x67, 0x72, 0x65, 0x65, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x62, 0x6c, 0x75, 0x65, 0x18,
|
||||
0x03, 0x20, 0x01, 0x28, 0x02, 0x52, 0x04, 0x62, 0x6c, 0x75, 0x65, 0x12, 0x31, 0x0a, 0x05, 0x61,
|
||||
0x6c, 0x70, 0x68, 0x61, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x67, 0x6f, 0x6f,
|
||||
0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x6c, 0x6f,
|
||||
0x61, 0x74, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x52, 0x05, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x42, 0x60,
|
||||
0x0a, 0x0f, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x74, 0x79, 0x70,
|
||||
0x65, 0x42, 0x0a, 0x43, 0x6f, 0x6c, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a,
|
||||
0x36, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f,
|
||||
0x72, 0x67, 0x2f, 0x67, 0x65, 0x6e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x6f, 0x67,
|
||||
0x6c, 0x65, 0x61, 0x70, 0x69, 0x73, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6f,
|
||||
0x72, 0x3b, 0x63, 0x6f, 0x6c, 0x6f, 0x72, 0xf8, 0x01, 0x01, 0xa2, 0x02, 0x03, 0x47, 0x54, 0x50,
|
||||
0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
file_google_type_color_proto_rawDescOnce sync.Once
|
||||
file_google_type_color_proto_rawDescData = file_google_type_color_proto_rawDesc
|
||||
)
|
||||
|
||||
func file_google_type_color_proto_rawDescGZIP() []byte {
|
||||
file_google_type_color_proto_rawDescOnce.Do(func() {
|
||||
file_google_type_color_proto_rawDescData = protoimpl.X.CompressGZIP(file_google_type_color_proto_rawDescData)
|
||||
})
|
||||
return file_google_type_color_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_google_type_color_proto_msgTypes = make([]protoimpl.MessageInfo, 1)
|
||||
var file_google_type_color_proto_goTypes = []interface{}{
|
||||
(*Color)(nil), // 0: google.type.Color
|
||||
(*wrapperspb.FloatValue)(nil), // 1: google.protobuf.FloatValue
|
||||
}
|
||||
var file_google_type_color_proto_depIdxs = []int32{
|
||||
1, // 0: google.type.Color.alpha:type_name -> google.protobuf.FloatValue
|
||||
1, // [1:1] is the sub-list for method output_type
|
||||
1, // [1:1] is the sub-list for method input_type
|
||||
1, // [1:1] is the sub-list for extension type_name
|
||||
1, // [1:1] is the sub-list for extension extendee
|
||||
0, // [0:1] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_google_type_color_proto_init() }
|
||||
func file_google_type_color_proto_init() {
|
||||
if File_google_type_color_proto != nil {
|
||||
return
|
||||
}
|
||||
if !protoimpl.UnsafeEnabled {
|
||||
file_google_type_color_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*Color); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_google_type_color_proto_rawDesc,
|
||||
NumEnums: 0,
|
||||
NumMessages: 1,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_google_type_color_proto_goTypes,
|
||||
DependencyIndexes: file_google_type_color_proto_depIdxs,
|
||||
MessageInfos: file_google_type_color_proto_msgTypes,
|
||||
}.Build()
|
||||
File_google_type_color_proto = out.File
|
||||
file_google_type_color_proto_rawDesc = nil
|
||||
file_google_type_color_proto_goTypes = nil
|
||||
file_google_type_color_proto_depIdxs = nil
|
||||
}
|
401
vendor/google.golang.org/genproto/googleapis/type/datetime/datetime.pb.go
generated
vendored
401
vendor/google.golang.org/genproto/googleapis/type/datetime/datetime.pb.go
generated
vendored
|
@ -1,401 +0,0 @@
|
|||
// Copyright 2021 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.26.0
|
||||
// protoc v3.12.2
|
||||
// source: google/type/datetime.proto
|
||||
|
||||
package datetime
|
||||
|
||||
import (
|
||||
reflect "reflect"
|
||||
sync "sync"
|
||||
|
||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||
durationpb "google.golang.org/protobuf/types/known/durationpb"
|
||||
)
|
||||
|
||||
const (
|
||||
// Verify that this generated code is sufficiently up-to-date.
|
||||
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
|
||||
// Verify that runtime/protoimpl is sufficiently up-to-date.
|
||||
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
||||
)
|
||||
|
||||
// Represents civil time (or occasionally physical time).
|
||||
//
|
||||
// This type can represent a civil time in one of a few possible ways:
|
||||
//
|
||||
// * When utc_offset is set and time_zone is unset: a civil time on a calendar
|
||||
// day with a particular offset from UTC.
|
||||
// * When time_zone is set and utc_offset is unset: a civil time on a calendar
|
||||
// day in a particular time zone.
|
||||
// * When neither time_zone nor utc_offset is set: a civil time on a calendar
|
||||
// day in local time.
|
||||
//
|
||||
// The date is relative to the Proleptic Gregorian Calendar.
|
||||
//
|
||||
// If year is 0, the DateTime is considered not to have a specific year. month
|
||||
// and day must have valid, non-zero values.
|
||||
//
|
||||
// This type may also be used to represent a physical time if all the date and
|
||||
// time fields are set and either case of the `time_offset` oneof is set.
|
||||
// Consider using `Timestamp` message for physical time instead. If your use
|
||||
// case also would like to store the user's timezone, that can be done in
|
||||
// another field.
|
||||
//
|
||||
// This type is more flexible than some applications may want. Make sure to
|
||||
// document and validate your application's limitations.
|
||||
type DateTime struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
// Optional. Year of date. Must be from 1 to 9999, or 0 if specifying a
|
||||
// datetime without a year.
|
||||
Year int32 `protobuf:"varint,1,opt,name=year,proto3" json:"year,omitempty"`
|
||||
// Required. Month of year. Must be from 1 to 12.
|
||||
Month int32 `protobuf:"varint,2,opt,name=month,proto3" json:"month,omitempty"`
|
||||
// Required. Day of month. Must be from 1 to 31 and valid for the year and
|
||||
// month.
|
||||
Day int32 `protobuf:"varint,3,opt,name=day,proto3" json:"day,omitempty"`
|
||||
// Required. Hours of day in 24 hour format. Should be from 0 to 23. An API
|
||||
// may choose to allow the value "24:00:00" for scenarios like business
|
||||
// closing time.
|
||||
Hours int32 `protobuf:"varint,4,opt,name=hours,proto3" json:"hours,omitempty"`
|
||||
// Required. Minutes of hour of day. Must be from 0 to 59.
|
||||
Minutes int32 `protobuf:"varint,5,opt,name=minutes,proto3" json:"minutes,omitempty"`
|
||||
// Required. Seconds of minutes of the time. Must normally be from 0 to 59. An
|
||||
// API may allow the value 60 if it allows leap-seconds.
|
||||
Seconds int32 `protobuf:"varint,6,opt,name=seconds,proto3" json:"seconds,omitempty"`
|
||||
// Required. Fractions of seconds in nanoseconds. Must be from 0 to
|
||||
// 999,999,999.
|
||||
Nanos int32 `protobuf:"varint,7,opt,name=nanos,proto3" json:"nanos,omitempty"`
|
||||
// Optional. Specifies either the UTC offset or the time zone of the DateTime.
|
||||
// Choose carefully between them, considering that time zone data may change
|
||||
// in the future (for example, a country modifies their DST start/end dates,
|
||||
// and future DateTimes in the affected range had already been stored).
|
||||
// If omitted, the DateTime is considered to be in local time.
|
||||
//
|
||||
// Types that are assignable to TimeOffset:
|
||||
// *DateTime_UtcOffset
|
||||
// *DateTime_TimeZone
|
||||
TimeOffset isDateTime_TimeOffset `protobuf_oneof:"time_offset"`
|
||||
}
|
||||
|
||||
func (x *DateTime) Reset() {
|
||||
*x = DateTime{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_google_type_datetime_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *DateTime) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*DateTime) ProtoMessage() {}
|
||||
|
||||
func (x *DateTime) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_google_type_datetime_proto_msgTypes[0]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use DateTime.ProtoReflect.Descriptor instead.
|
||||
func (*DateTime) Descriptor() ([]byte, []int) {
|
||||
return file_google_type_datetime_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *DateTime) GetYear() int32 {
|
||||
if x != nil {
|
||||
return x.Year
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *DateTime) GetMonth() int32 {
|
||||
if x != nil {
|
||||
return x.Month
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *DateTime) GetDay() int32 {
|
||||
if x != nil {
|
||||
return x.Day
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *DateTime) GetHours() int32 {
|
||||
if x != nil {
|
||||
return x.Hours
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *DateTime) GetMinutes() int32 {
|
||||
if x != nil {
|
||||
return x.Minutes
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *DateTime) GetSeconds() int32 {
|
||||
if x != nil {
|
||||
return x.Seconds
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *DateTime) GetNanos() int32 {
|
||||
if x != nil {
|
||||
return x.Nanos
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *DateTime) GetTimeOffset() isDateTime_TimeOffset {
|
||||
if m != nil {
|
||||
return m.TimeOffset
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *DateTime) GetUtcOffset() *durationpb.Duration {
|
||||
if x, ok := x.GetTimeOffset().(*DateTime_UtcOffset); ok {
|
||||
return x.UtcOffset
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *DateTime) GetTimeZone() *TimeZone {
|
||||
if x, ok := x.GetTimeOffset().(*DateTime_TimeZone); ok {
|
||||
return x.TimeZone
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
type isDateTime_TimeOffset interface {
|
||||
isDateTime_TimeOffset()
|
||||
}
|
||||
|
||||
type DateTime_UtcOffset struct {
|
||||
// UTC offset. Must be whole seconds, between -18 hours and +18 hours.
|
||||
// For example, a UTC offset of -4:00 would be represented as
|
||||
// { seconds: -14400 }.
|
||||
UtcOffset *durationpb.Duration `protobuf:"bytes,8,opt,name=utc_offset,json=utcOffset,proto3,oneof"`
|
||||
}
|
||||
|
||||
type DateTime_TimeZone struct {
|
||||
// Time zone.
|
||||
TimeZone *TimeZone `protobuf:"bytes,9,opt,name=time_zone,json=timeZone,proto3,oneof"`
|
||||
}
|
||||
|
||||
func (*DateTime_UtcOffset) isDateTime_TimeOffset() {}
|
||||
|
||||
func (*DateTime_TimeZone) isDateTime_TimeOffset() {}
|
||||
|
||||
// Represents a time zone from the
|
||||
// [IANA Time Zone Database](https://www.iana.org/time-zones).
|
||||
type TimeZone struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
// IANA Time Zone Database time zone, e.g. "America/New_York".
|
||||
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
|
||||
// Optional. IANA Time Zone Database version number, e.g. "2019a".
|
||||
Version string `protobuf:"bytes,2,opt,name=version,proto3" json:"version,omitempty"`
|
||||
}
|
||||
|
||||
func (x *TimeZone) Reset() {
|
||||
*x = TimeZone{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_google_type_datetime_proto_msgTypes[1]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *TimeZone) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*TimeZone) ProtoMessage() {}
|
||||
|
||||
func (x *TimeZone) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_google_type_datetime_proto_msgTypes[1]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use TimeZone.ProtoReflect.Descriptor instead.
|
||||
func (*TimeZone) Descriptor() ([]byte, []int) {
|
||||
return file_google_type_datetime_proto_rawDescGZIP(), []int{1}
|
||||
}
|
||||
|
||||
func (x *TimeZone) GetId() string {
|
||||
if x != nil {
|
||||
return x.Id
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *TimeZone) GetVersion() string {
|
||||
if x != nil {
|
||||
return x.Version
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
var File_google_type_datetime_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_google_type_datetime_proto_rawDesc = []byte{
|
||||
0x0a, 0x1a, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x2f, 0x64, 0x61,
|
||||
0x74, 0x65, 0x74, 0x69, 0x6d, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0b, 0x67, 0x6f,
|
||||
0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x1a, 0x1e, 0x67, 0x6f, 0x6f, 0x67, 0x6c,
|
||||
0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x64, 0x75, 0x72, 0x61, 0x74,
|
||||
0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xa7, 0x02, 0x0a, 0x08, 0x44, 0x61,
|
||||
0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x79, 0x65, 0x61, 0x72, 0x18, 0x01,
|
||||
0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x79, 0x65, 0x61, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x6d, 0x6f,
|
||||
0x6e, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x6d, 0x6f, 0x6e, 0x74, 0x68,
|
||||
0x12, 0x10, 0x0a, 0x03, 0x64, 0x61, 0x79, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x64,
|
||||
0x61, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x68, 0x6f, 0x75, 0x72, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28,
|
||||
0x05, 0x52, 0x05, 0x68, 0x6f, 0x75, 0x72, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x69, 0x6e, 0x75,
|
||||
0x74, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x6d, 0x69, 0x6e, 0x75, 0x74,
|
||||
0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x65, 0x63, 0x6f, 0x6e, 0x64, 0x73, 0x18, 0x06, 0x20,
|
||||
0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x65, 0x63, 0x6f, 0x6e, 0x64, 0x73, 0x12, 0x14, 0x0a, 0x05,
|
||||
0x6e, 0x61, 0x6e, 0x6f, 0x73, 0x18, 0x07, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x6e, 0x61, 0x6e,
|
||||
0x6f, 0x73, 0x12, 0x3a, 0x0a, 0x0a, 0x75, 0x74, 0x63, 0x5f, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74,
|
||||
0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e,
|
||||
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f,
|
||||
0x6e, 0x48, 0x00, 0x52, 0x09, 0x75, 0x74, 0x63, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x12, 0x34,
|
||||
0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x7a, 0x6f, 0x6e, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28,
|
||||
0x0b, 0x32, 0x15, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e,
|
||||
0x54, 0x69, 0x6d, 0x65, 0x5a, 0x6f, 0x6e, 0x65, 0x48, 0x00, 0x52, 0x08, 0x74, 0x69, 0x6d, 0x65,
|
||||
0x5a, 0x6f, 0x6e, 0x65, 0x42, 0x0d, 0x0a, 0x0b, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x6f, 0x66, 0x66,
|
||||
0x73, 0x65, 0x74, 0x22, 0x34, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x5a, 0x6f, 0x6e, 0x65, 0x12,
|
||||
0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12,
|
||||
0x18, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x42, 0x69, 0x0a, 0x0f, 0x63, 0x6f, 0x6d,
|
||||
0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x42, 0x0d, 0x44, 0x61,
|
||||
0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3c, 0x67,
|
||||
0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67,
|
||||
0x2f, 0x67, 0x65, 0x6e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
|
||||
0x61, 0x70, 0x69, 0x73, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x2f, 0x64, 0x61, 0x74, 0x65, 0x74, 0x69,
|
||||
0x6d, 0x65, 0x3b, 0x64, 0x61, 0x74, 0x65, 0x74, 0x69, 0x6d, 0x65, 0xf8, 0x01, 0x01, 0xa2, 0x02,
|
||||
0x03, 0x47, 0x54, 0x50, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
file_google_type_datetime_proto_rawDescOnce sync.Once
|
||||
file_google_type_datetime_proto_rawDescData = file_google_type_datetime_proto_rawDesc
|
||||
)
|
||||
|
||||
func file_google_type_datetime_proto_rawDescGZIP() []byte {
|
||||
file_google_type_datetime_proto_rawDescOnce.Do(func() {
|
||||
file_google_type_datetime_proto_rawDescData = protoimpl.X.CompressGZIP(file_google_type_datetime_proto_rawDescData)
|
||||
})
|
||||
return file_google_type_datetime_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_google_type_datetime_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
|
||||
var file_google_type_datetime_proto_goTypes = []interface{}{
|
||||
(*DateTime)(nil), // 0: google.type.DateTime
|
||||
(*TimeZone)(nil), // 1: google.type.TimeZone
|
||||
(*durationpb.Duration)(nil), // 2: google.protobuf.Duration
|
||||
}
|
||||
var file_google_type_datetime_proto_depIdxs = []int32{
|
||||
2, // 0: google.type.DateTime.utc_offset:type_name -> google.protobuf.Duration
|
||||
1, // 1: google.type.DateTime.time_zone:type_name -> google.type.TimeZone
|
||||
2, // [2:2] is the sub-list for method output_type
|
||||
2, // [2:2] is the sub-list for method input_type
|
||||
2, // [2:2] is the sub-list for extension type_name
|
||||
2, // [2:2] is the sub-list for extension extendee
|
||||
0, // [0:2] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_google_type_datetime_proto_init() }
|
||||
func file_google_type_datetime_proto_init() {
|
||||
if File_google_type_datetime_proto != nil {
|
||||
return
|
||||
}
|
||||
if !protoimpl.UnsafeEnabled {
|
||||
file_google_type_datetime_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DateTime); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_google_type_datetime_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*TimeZone); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
}
|
||||
file_google_type_datetime_proto_msgTypes[0].OneofWrappers = []interface{}{
|
||||
(*DateTime_UtcOffset)(nil),
|
||||
(*DateTime_TimeZone)(nil),
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_google_type_datetime_proto_rawDesc,
|
||||
NumEnums: 0,
|
||||
NumMessages: 2,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_google_type_datetime_proto_goTypes,
|
||||
DependencyIndexes: file_google_type_datetime_proto_depIdxs,
|
||||
MessageInfos: file_google_type_datetime_proto_msgTypes,
|
||||
}.Build()
|
||||
File_google_type_datetime_proto = out.File
|
||||
file_google_type_datetime_proto_rawDesc = nil
|
||||
file_google_type_datetime_proto_goTypes = nil
|
||||
file_google_type_datetime_proto_depIdxs = nil
|
||||
}
|
230
vendor/google.golang.org/genproto/googleapis/type/decimal/decimal.pb.go
generated
vendored
230
vendor/google.golang.org/genproto/googleapis/type/decimal/decimal.pb.go
generated
vendored
|
@ -1,230 +0,0 @@
|
|||
// Copyright 2021 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.26.0
|
||||
// protoc v3.12.2
|
||||
// source: google/type/decimal.proto
|
||||
|
||||
package decimal
|
||||
|
||||
import (
|
||||
reflect "reflect"
|
||||
sync "sync"
|
||||
|
||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||
)
|
||||
|
||||
const (
|
||||
// Verify that this generated code is sufficiently up-to-date.
|
||||
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
|
||||
// Verify that runtime/protoimpl is sufficiently up-to-date.
|
||||
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
||||
)
|
||||
|
||||
// A representation of a decimal value, such as 2.5. Clients may convert values
|
||||
// into language-native decimal formats, such as Java's [BigDecimal][] or
|
||||
// Python's [decimal.Decimal][].
|
||||
//
|
||||
// [BigDecimal]:
|
||||
// https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/math/BigDecimal.html
|
||||
// [decimal.Decimal]: https://docs.python.org/3/library/decimal.html
|
||||
type Decimal struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
// The decimal value, as a string.
|
||||
//
|
||||
// The string representation consists of an optional sign, `+` (`U+002B`)
|
||||
// or `-` (`U+002D`), followed by a sequence of zero or more decimal digits
|
||||
// ("the integer"), optionally followed by a fraction, optionally followed
|
||||
// by an exponent.
|
||||
//
|
||||
// The fraction consists of a decimal point followed by zero or more decimal
|
||||
// digits. The string must contain at least one digit in either the integer
|
||||
// or the fraction. The number formed by the sign, the integer and the
|
||||
// fraction is referred to as the significand.
|
||||
//
|
||||
// The exponent consists of the character `e` (`U+0065`) or `E` (`U+0045`)
|
||||
// followed by one or more decimal digits.
|
||||
//
|
||||
// Services **should** normalize decimal values before storing them by:
|
||||
//
|
||||
// - Removing an explicitly-provided `+` sign (`+2.5` -> `2.5`).
|
||||
// - Replacing a zero-length integer value with `0` (`.5` -> `0.5`).
|
||||
// - Coercing the exponent character to lower-case (`2.5E8` -> `2.5e8`).
|
||||
// - Removing an explicitly-provided zero exponent (`2.5e0` -> `2.5`).
|
||||
//
|
||||
// Services **may** perform additional normalization based on its own needs
|
||||
// and the internal decimal implementation selected, such as shifting the
|
||||
// decimal point and exponent value together (example: `2.5e-1` <-> `0.25`).
|
||||
// Additionally, services **may** preserve trailing zeroes in the fraction
|
||||
// to indicate increased precision, but are not required to do so.
|
||||
//
|
||||
// Note that only the `.` character is supported to divide the integer
|
||||
// and the fraction; `,` **should not** be supported regardless of locale.
|
||||
// Additionally, thousand separators **should not** be supported. If a
|
||||
// service does support them, values **must** be normalized.
|
||||
//
|
||||
// The ENBF grammar is:
|
||||
//
|
||||
// DecimalString =
|
||||
// [Sign] Significand [Exponent];
|
||||
//
|
||||
// Sign = '+' | '-';
|
||||
//
|
||||
// Significand =
|
||||
// Digits ['.'] [Digits] | [Digits] '.' Digits;
|
||||
//
|
||||
// Exponent = ('e' | 'E') [Sign] Digits;
|
||||
//
|
||||
// Digits = { '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' };
|
||||
//
|
||||
// Services **should** clearly document the range of supported values, the
|
||||
// maximum supported precision (total number of digits), and, if applicable,
|
||||
// the scale (number of digits after the decimal point), as well as how it
|
||||
// behaves when receiving out-of-bounds values.
|
||||
//
|
||||
// Services **may** choose to accept values passed as input even when the
|
||||
// value has a higher precision or scale than the service supports, and
|
||||
// **should** round the value to fit the supported scale. Alternatively, the
|
||||
// service **may** error with `400 Bad Request` (`INVALID_ARGUMENT` in gRPC)
|
||||
// if precision would be lost.
|
||||
//
|
||||
// Services **should** error with `400 Bad Request` (`INVALID_ARGUMENT` in
|
||||
// gRPC) if the service receives a value outside of the supported range.
|
||||
Value string `protobuf:"bytes,1,opt,name=value,proto3" json:"value,omitempty"`
|
||||
}
|
||||
|
||||
func (x *Decimal) Reset() {
|
||||
*x = Decimal{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_google_type_decimal_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *Decimal) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*Decimal) ProtoMessage() {}
|
||||
|
||||
func (x *Decimal) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_google_type_decimal_proto_msgTypes[0]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use Decimal.ProtoReflect.Descriptor instead.
|
||||
func (*Decimal) Descriptor() ([]byte, []int) {
|
||||
return file_google_type_decimal_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *Decimal) GetValue() string {
|
||||
if x != nil {
|
||||
return x.Value
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
var File_google_type_decimal_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_google_type_decimal_proto_rawDesc = []byte{
|
||||
0x0a, 0x19, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x2f, 0x64, 0x65,
|
||||
0x63, 0x69, 0x6d, 0x61, 0x6c, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0b, 0x67, 0x6f, 0x6f,
|
||||
0x67, 0x6c, 0x65, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x22, 0x1f, 0x0a, 0x07, 0x44, 0x65, 0x63, 0x69,
|
||||
0x6d, 0x61, 0x6c, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01,
|
||||
0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x42, 0x66, 0x0a, 0x0f, 0x63, 0x6f, 0x6d,
|
||||
0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x42, 0x0c, 0x44, 0x65,
|
||||
0x63, 0x69, 0x6d, 0x61, 0x6c, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3a, 0x67, 0x6f,
|
||||
0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f,
|
||||
0x67, 0x65, 0x6e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x61,
|
||||
0x70, 0x69, 0x73, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x2f, 0x64, 0x65, 0x63, 0x69, 0x6d, 0x61, 0x6c,
|
||||
0x3b, 0x64, 0x65, 0x63, 0x69, 0x6d, 0x61, 0x6c, 0xf8, 0x01, 0x01, 0xa2, 0x02, 0x03, 0x47, 0x54,
|
||||
0x50, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
file_google_type_decimal_proto_rawDescOnce sync.Once
|
||||
file_google_type_decimal_proto_rawDescData = file_google_type_decimal_proto_rawDesc
|
||||
)
|
||||
|
||||
func file_google_type_decimal_proto_rawDescGZIP() []byte {
|
||||
file_google_type_decimal_proto_rawDescOnce.Do(func() {
|
||||
file_google_type_decimal_proto_rawDescData = protoimpl.X.CompressGZIP(file_google_type_decimal_proto_rawDescData)
|
||||
})
|
||||
return file_google_type_decimal_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_google_type_decimal_proto_msgTypes = make([]protoimpl.MessageInfo, 1)
|
||||
var file_google_type_decimal_proto_goTypes = []interface{}{
|
||||
(*Decimal)(nil), // 0: google.type.Decimal
|
||||
}
|
||||
var file_google_type_decimal_proto_depIdxs = []int32{
|
||||
0, // [0:0] is the sub-list for method output_type
|
||||
0, // [0:0] is the sub-list for method input_type
|
||||
0, // [0:0] is the sub-list for extension type_name
|
||||
0, // [0:0] is the sub-list for extension extendee
|
||||
0, // [0:0] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_google_type_decimal_proto_init() }
|
||||
func file_google_type_decimal_proto_init() {
|
||||
if File_google_type_decimal_proto != nil {
|
||||
return
|
||||
}
|
||||
if !protoimpl.UnsafeEnabled {
|
||||
file_google_type_decimal_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*Decimal); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_google_type_decimal_proto_rawDesc,
|
||||
NumEnums: 0,
|
||||
NumMessages: 1,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_google_type_decimal_proto_goTypes,
|
||||
DependencyIndexes: file_google_type_decimal_proto_depIdxs,
|
||||
MessageInfos: file_google_type_decimal_proto_msgTypes,
|
||||
}.Build()
|
||||
File_google_type_decimal_proto = out.File
|
||||
file_google_type_decimal_proto_rawDesc = nil
|
||||
file_google_type_decimal_proto_goTypes = nil
|
||||
file_google_type_decimal_proto_depIdxs = nil
|
||||
}
|
178
vendor/google.golang.org/genproto/googleapis/type/fraction/fraction.pb.go
generated
vendored
178
vendor/google.golang.org/genproto/googleapis/type/fraction/fraction.pb.go
generated
vendored
|
@ -1,178 +0,0 @@
|
|||
// Copyright 2021 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.26.0
|
||||
// protoc v3.12.2
|
||||
// source: google/type/fraction.proto
|
||||
|
||||
package fraction
|
||||
|
||||
import (
|
||||
reflect "reflect"
|
||||
sync "sync"
|
||||
|
||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||
)
|
||||
|
||||
const (
|
||||
// Verify that this generated code is sufficiently up-to-date.
|
||||
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
|
||||
// Verify that runtime/protoimpl is sufficiently up-to-date.
|
||||
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
||||
)
|
||||
|
||||
// Represents a fraction in terms of a numerator divided by a denominator.
|
||||
type Fraction struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
// The numerator in the fraction, e.g. 2 in 2/3.
|
||||
Numerator int64 `protobuf:"varint,1,opt,name=numerator,proto3" json:"numerator,omitempty"`
|
||||
// The value by which the numerator is divided, e.g. 3 in 2/3. Must be
|
||||
// positive.
|
||||
Denominator int64 `protobuf:"varint,2,opt,name=denominator,proto3" json:"denominator,omitempty"`
|
||||
}
|
||||
|
||||
func (x *Fraction) Reset() {
|
||||
*x = Fraction{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_google_type_fraction_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *Fraction) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*Fraction) ProtoMessage() {}
|
||||
|
||||
func (x *Fraction) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_google_type_fraction_proto_msgTypes[0]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use Fraction.ProtoReflect.Descriptor instead.
|
||||
func (*Fraction) Descriptor() ([]byte, []int) {
|
||||
return file_google_type_fraction_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *Fraction) GetNumerator() int64 {
|
||||
if x != nil {
|
||||
return x.Numerator
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *Fraction) GetDenominator() int64 {
|
||||
if x != nil {
|
||||
return x.Denominator
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
var File_google_type_fraction_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_google_type_fraction_proto_rawDesc = []byte{
|
||||
0x0a, 0x1a, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x2f, 0x66, 0x72,
|
||||
0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0b, 0x67, 0x6f,
|
||||
0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x22, 0x4a, 0x0a, 0x08, 0x46, 0x72, 0x61,
|
||||
0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x6e, 0x75, 0x6d, 0x65, 0x72, 0x61, 0x74,
|
||||
0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x6e, 0x75, 0x6d, 0x65, 0x72, 0x61,
|
||||
0x74, 0x6f, 0x72, 0x12, 0x20, 0x0a, 0x0b, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x69, 0x6e, 0x61, 0x74,
|
||||
0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x69,
|
||||
0x6e, 0x61, 0x74, 0x6f, 0x72, 0x42, 0x66, 0x0a, 0x0f, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x6f, 0x6f,
|
||||
0x67, 0x6c, 0x65, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x42, 0x0d, 0x46, 0x72, 0x61, 0x63, 0x74, 0x69,
|
||||
0x6f, 0x6e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3c, 0x67, 0x6f, 0x6f, 0x67, 0x6c,
|
||||
0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x67, 0x65, 0x6e,
|
||||
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x61, 0x70, 0x69, 0x73,
|
||||
0x2f, 0x74, 0x79, 0x70, 0x65, 0x2f, 0x66, 0x72, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x3b, 0x66,
|
||||
0x72, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0xa2, 0x02, 0x03, 0x47, 0x54, 0x50, 0x62, 0x06, 0x70,
|
||||
0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
file_google_type_fraction_proto_rawDescOnce sync.Once
|
||||
file_google_type_fraction_proto_rawDescData = file_google_type_fraction_proto_rawDesc
|
||||
)
|
||||
|
||||
func file_google_type_fraction_proto_rawDescGZIP() []byte {
|
||||
file_google_type_fraction_proto_rawDescOnce.Do(func() {
|
||||
file_google_type_fraction_proto_rawDescData = protoimpl.X.CompressGZIP(file_google_type_fraction_proto_rawDescData)
|
||||
})
|
||||
return file_google_type_fraction_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_google_type_fraction_proto_msgTypes = make([]protoimpl.MessageInfo, 1)
|
||||
var file_google_type_fraction_proto_goTypes = []interface{}{
|
||||
(*Fraction)(nil), // 0: google.type.Fraction
|
||||
}
|
||||
var file_google_type_fraction_proto_depIdxs = []int32{
|
||||
0, // [0:0] is the sub-list for method output_type
|
||||
0, // [0:0] is the sub-list for method input_type
|
||||
0, // [0:0] is the sub-list for extension type_name
|
||||
0, // [0:0] is the sub-list for extension extendee
|
||||
0, // [0:0] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_google_type_fraction_proto_init() }
|
||||
func file_google_type_fraction_proto_init() {
|
||||
if File_google_type_fraction_proto != nil {
|
||||
return
|
||||
}
|
||||
if !protoimpl.UnsafeEnabled {
|
||||
file_google_type_fraction_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*Fraction); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_google_type_fraction_proto_rawDesc,
|
||||
NumEnums: 0,
|
||||
NumMessages: 1,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_google_type_fraction_proto_goTypes,
|
||||
DependencyIndexes: file_google_type_fraction_proto_depIdxs,
|
||||
MessageInfos: file_google_type_fraction_proto_msgTypes,
|
||||
}.Build()
|
||||
File_google_type_fraction_proto = out.File
|
||||
file_google_type_fraction_proto_rawDesc = nil
|
||||
file_google_type_fraction_proto_goTypes = nil
|
||||
file_google_type_fraction_proto_depIdxs = nil
|
||||
}
|
203
vendor/google.golang.org/genproto/googleapis/type/month/month.pb.go
generated
vendored
203
vendor/google.golang.org/genproto/googleapis/type/month/month.pb.go
generated
vendored
|
@ -1,203 +0,0 @@
|
|||
// Copyright 2021 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.26.0
|
||||
// protoc v3.12.2
|
||||
// source: google/type/month.proto
|
||||
|
||||
package month
|
||||
|
||||
import (
|
||||
reflect "reflect"
|
||||
sync "sync"
|
||||
|
||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||
)
|
||||
|
||||
const (
|
||||
// Verify that this generated code is sufficiently up-to-date.
|
||||
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
|
||||
// Verify that runtime/protoimpl is sufficiently up-to-date.
|
||||
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
||||
)
|
||||
|
||||
// Represents a month in the Gregorian calendar.
|
||||
type Month int32
|
||||
|
||||
const (
|
||||
// The unspecified month.
|
||||
Month_MONTH_UNSPECIFIED Month = 0
|
||||
// The month of January.
|
||||
Month_JANUARY Month = 1
|
||||
// The month of February.
|
||||
Month_FEBRUARY Month = 2
|
||||
// The month of March.
|
||||
Month_MARCH Month = 3
|
||||
// The month of April.
|
||||
Month_APRIL Month = 4
|
||||
// The month of May.
|
||||
Month_MAY Month = 5
|
||||
// The month of June.
|
||||
Month_JUNE Month = 6
|
||||
// The month of July.
|
||||
Month_JULY Month = 7
|
||||
// The month of August.
|
||||
Month_AUGUST Month = 8
|
||||
// The month of September.
|
||||
Month_SEPTEMBER Month = 9
|
||||
// The month of October.
|
||||
Month_OCTOBER Month = 10
|
||||
// The month of November.
|
||||
Month_NOVEMBER Month = 11
|
||||
// The month of December.
|
||||
Month_DECEMBER Month = 12
|
||||
)
|
||||
|
||||
// Enum value maps for Month.
|
||||
var (
|
||||
Month_name = map[int32]string{
|
||||
0: "MONTH_UNSPECIFIED",
|
||||
1: "JANUARY",
|
||||
2: "FEBRUARY",
|
||||
3: "MARCH",
|
||||
4: "APRIL",
|
||||
5: "MAY",
|
||||
6: "JUNE",
|
||||
7: "JULY",
|
||||
8: "AUGUST",
|
||||
9: "SEPTEMBER",
|
||||
10: "OCTOBER",
|
||||
11: "NOVEMBER",
|
||||
12: "DECEMBER",
|
||||
}
|
||||
Month_value = map[string]int32{
|
||||
"MONTH_UNSPECIFIED": 0,
|
||||
"JANUARY": 1,
|
||||
"FEBRUARY": 2,
|
||||
"MARCH": 3,
|
||||
"APRIL": 4,
|
||||
"MAY": 5,
|
||||
"JUNE": 6,
|
||||
"JULY": 7,
|
||||
"AUGUST": 8,
|
||||
"SEPTEMBER": 9,
|
||||
"OCTOBER": 10,
|
||||
"NOVEMBER": 11,
|
||||
"DECEMBER": 12,
|
||||
}
|
||||
)
|
||||
|
||||
func (x Month) Enum() *Month {
|
||||
p := new(Month)
|
||||
*p = x
|
||||
return p
|
||||
}
|
||||
|
||||
func (x Month) String() string {
|
||||
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
||||
}
|
||||
|
||||
func (Month) Descriptor() protoreflect.EnumDescriptor {
|
||||
return file_google_type_month_proto_enumTypes[0].Descriptor()
|
||||
}
|
||||
|
||||
func (Month) Type() protoreflect.EnumType {
|
||||
return &file_google_type_month_proto_enumTypes[0]
|
||||
}
|
||||
|
||||
func (x Month) Number() protoreflect.EnumNumber {
|
||||
return protoreflect.EnumNumber(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use Month.Descriptor instead.
|
||||
func (Month) EnumDescriptor() ([]byte, []int) {
|
||||
return file_google_type_month_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
var File_google_type_month_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_google_type_month_proto_rawDesc = []byte{
|
||||
0x0a, 0x17, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x2f, 0x6d, 0x6f,
|
||||
0x6e, 0x74, 0x68, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0b, 0x67, 0x6f, 0x6f, 0x67, 0x6c,
|
||||
0x65, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2a, 0xb0, 0x01, 0x0a, 0x05, 0x4d, 0x6f, 0x6e, 0x74, 0x68,
|
||||
0x12, 0x15, 0x0a, 0x11, 0x4d, 0x4f, 0x4e, 0x54, 0x48, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43,
|
||||
0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x0b, 0x0a, 0x07, 0x4a, 0x41, 0x4e, 0x55, 0x41,
|
||||
0x52, 0x59, 0x10, 0x01, 0x12, 0x0c, 0x0a, 0x08, 0x46, 0x45, 0x42, 0x52, 0x55, 0x41, 0x52, 0x59,
|
||||
0x10, 0x02, 0x12, 0x09, 0x0a, 0x05, 0x4d, 0x41, 0x52, 0x43, 0x48, 0x10, 0x03, 0x12, 0x09, 0x0a,
|
||||
0x05, 0x41, 0x50, 0x52, 0x49, 0x4c, 0x10, 0x04, 0x12, 0x07, 0x0a, 0x03, 0x4d, 0x41, 0x59, 0x10,
|
||||
0x05, 0x12, 0x08, 0x0a, 0x04, 0x4a, 0x55, 0x4e, 0x45, 0x10, 0x06, 0x12, 0x08, 0x0a, 0x04, 0x4a,
|
||||
0x55, 0x4c, 0x59, 0x10, 0x07, 0x12, 0x0a, 0x0a, 0x06, 0x41, 0x55, 0x47, 0x55, 0x53, 0x54, 0x10,
|
||||
0x08, 0x12, 0x0d, 0x0a, 0x09, 0x53, 0x45, 0x50, 0x54, 0x45, 0x4d, 0x42, 0x45, 0x52, 0x10, 0x09,
|
||||
0x12, 0x0b, 0x0a, 0x07, 0x4f, 0x43, 0x54, 0x4f, 0x42, 0x45, 0x52, 0x10, 0x0a, 0x12, 0x0c, 0x0a,
|
||||
0x08, 0x4e, 0x4f, 0x56, 0x45, 0x4d, 0x42, 0x45, 0x52, 0x10, 0x0b, 0x12, 0x0c, 0x0a, 0x08, 0x44,
|
||||
0x45, 0x43, 0x45, 0x4d, 0x42, 0x45, 0x52, 0x10, 0x0c, 0x42, 0x5d, 0x0a, 0x0f, 0x63, 0x6f, 0x6d,
|
||||
0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x42, 0x0a, 0x4d, 0x6f,
|
||||
0x6e, 0x74, 0x68, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x36, 0x67, 0x6f, 0x6f, 0x67,
|
||||
0x6c, 0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x67, 0x65,
|
||||
0x6e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x61, 0x70, 0x69,
|
||||
0x73, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x2f, 0x6d, 0x6f, 0x6e, 0x74, 0x68, 0x3b, 0x6d, 0x6f, 0x6e,
|
||||
0x74, 0x68, 0xa2, 0x02, 0x03, 0x47, 0x54, 0x50, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
file_google_type_month_proto_rawDescOnce sync.Once
|
||||
file_google_type_month_proto_rawDescData = file_google_type_month_proto_rawDesc
|
||||
)
|
||||
|
||||
func file_google_type_month_proto_rawDescGZIP() []byte {
|
||||
file_google_type_month_proto_rawDescOnce.Do(func() {
|
||||
file_google_type_month_proto_rawDescData = protoimpl.X.CompressGZIP(file_google_type_month_proto_rawDescData)
|
||||
})
|
||||
return file_google_type_month_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_google_type_month_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
|
||||
var file_google_type_month_proto_goTypes = []interface{}{
|
||||
(Month)(0), // 0: google.type.Month
|
||||
}
|
||||
var file_google_type_month_proto_depIdxs = []int32{
|
||||
0, // [0:0] is the sub-list for method output_type
|
||||
0, // [0:0] is the sub-list for method input_type
|
||||
0, // [0:0] is the sub-list for extension type_name
|
||||
0, // [0:0] is the sub-list for extension extendee
|
||||
0, // [0:0] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_google_type_month_proto_init() }
|
||||
func file_google_type_month_proto_init() {
|
||||
if File_google_type_month_proto != nil {
|
||||
return
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_google_type_month_proto_rawDesc,
|
||||
NumEnums: 1,
|
||||
NumMessages: 0,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_google_type_month_proto_goTypes,
|
||||
DependencyIndexes: file_google_type_month_proto_depIdxs,
|
||||
EnumInfos: file_google_type_month_proto_enumTypes,
|
||||
}.Build()
|
||||
File_google_type_month_proto = out.File
|
||||
file_google_type_month_proto_rawDesc = nil
|
||||
file_google_type_month_proto_goTypes = nil
|
||||
file_google_type_month_proto_depIdxs = nil
|
||||
}
|
|
@ -1,4 +1,4 @@
|
|||
// Copyright 2019 Google LLC
|
||||
// Copyright 2020 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
|
@ -12,12 +12,12 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// This file, and the cloud.google.com/go import, won't actually become part of
|
||||
// the resultant binary.
|
||||
//go:build modhack
|
||||
// +build modhack
|
||||
// Package field_mask aliases all exported identifiers in
|
||||
// package "google.golang.org/protobuf/types/known/fieldmaskpb".
|
||||
package field_mask
|
||||
|
||||
package storage
|
||||
import "google.golang.org/protobuf/types/known/fieldmaskpb"
|
||||
|
||||
// Necessary for safely adding multi-module repo. See: https://github.com/golang/go/wiki/Modules#is-it-possible-to-add-a-module-to-a-multi-module-repository
|
||||
import _ "cloud.google.com/go"
|
||||
type FieldMask = fieldmaskpb.FieldMask
|
||||
|
||||
var File_google_protobuf_field_mask_proto = fieldmaskpb.File_google_protobuf_field_mask_proto
|
760
vendor/google.golang.org/protobuf/types/known/wrapperspb/wrappers.pb.go
generated
vendored
760
vendor/google.golang.org/protobuf/types/known/wrapperspb/wrappers.pb.go
generated
vendored
|
@ -1,760 +0,0 @@
|
|||
// Protocol Buffers - Google's data interchange format
|
||||
// Copyright 2008 Google Inc. All rights reserved.
|
||||
// https://developers.google.com/protocol-buffers/
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without
|
||||
// modification, are permitted provided that the following conditions are
|
||||
// met:
|
||||
//
|
||||
// * Redistributions of source code must retain the above copyright
|
||||
// notice, this list of conditions and the following disclaimer.
|
||||
// * Redistributions in binary form must reproduce the above
|
||||
// copyright notice, this list of conditions and the following disclaimer
|
||||
// in the documentation and/or other materials provided with the
|
||||
// distribution.
|
||||
// * Neither the name of Google Inc. nor the names of its
|
||||
// contributors may be used to endorse or promote products derived from
|
||||
// this software without specific prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
// Wrappers for primitive (non-message) types. These types are useful
|
||||
// for embedding primitives in the `google.protobuf.Any` type and for places
|
||||
// where we need to distinguish between the absence of a primitive
|
||||
// typed field and its default value.
|
||||
//
|
||||
// These wrappers have no meaningful use within repeated fields as they lack
|
||||
// the ability to detect presence on individual elements.
|
||||
// These wrappers have no meaningful use within a map or a oneof since
|
||||
// individual entries of a map or fields of a oneof can already detect presence.
|
||||
|
||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// source: google/protobuf/wrappers.proto
|
||||
|
||||
package wrapperspb
|
||||
|
||||
import (
|
||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||
reflect "reflect"
|
||||
sync "sync"
|
||||
)
|
||||
|
||||
// Wrapper message for `double`.
|
||||
//
|
||||
// The JSON representation for `DoubleValue` is JSON number.
|
||||
type DoubleValue struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
// The double value.
|
||||
Value float64 `protobuf:"fixed64,1,opt,name=value,proto3" json:"value,omitempty"`
|
||||
}
|
||||
|
||||
// Double stores v in a new DoubleValue and returns a pointer to it.
|
||||
func Double(v float64) *DoubleValue {
|
||||
return &DoubleValue{Value: v}
|
||||
}
|
||||
|
||||
func (x *DoubleValue) Reset() {
|
||||
*x = DoubleValue{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *DoubleValue) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*DoubleValue) ProtoMessage() {}
|
||||
|
||||
func (x *DoubleValue) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[0]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use DoubleValue.ProtoReflect.Descriptor instead.
|
||||
func (*DoubleValue) Descriptor() ([]byte, []int) {
|
||||
return file_google_protobuf_wrappers_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *DoubleValue) GetValue() float64 {
|
||||
if x != nil {
|
||||
return x.Value
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
// Wrapper message for `float`.
|
||||
//
|
||||
// The JSON representation for `FloatValue` is JSON number.
|
||||
type FloatValue struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
// The float value.
|
||||
Value float32 `protobuf:"fixed32,1,opt,name=value,proto3" json:"value,omitempty"`
|
||||
}
|
||||
|
||||
// Float stores v in a new FloatValue and returns a pointer to it.
|
||||
func Float(v float32) *FloatValue {
|
||||
return &FloatValue{Value: v}
|
||||
}
|
||||
|
||||
func (x *FloatValue) Reset() {
|
||||
*x = FloatValue{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[1]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *FloatValue) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*FloatValue) ProtoMessage() {}
|
||||
|
||||
func (x *FloatValue) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[1]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use FloatValue.ProtoReflect.Descriptor instead.
|
||||
func (*FloatValue) Descriptor() ([]byte, []int) {
|
||||
return file_google_protobuf_wrappers_proto_rawDescGZIP(), []int{1}
|
||||
}
|
||||
|
||||
func (x *FloatValue) GetValue() float32 {
|
||||
if x != nil {
|
||||
return x.Value
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
// Wrapper message for `int64`.
|
||||
//
|
||||
// The JSON representation for `Int64Value` is JSON string.
|
||||
type Int64Value struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
// The int64 value.
|
||||
Value int64 `protobuf:"varint,1,opt,name=value,proto3" json:"value,omitempty"`
|
||||
}
|
||||
|
||||
// Int64 stores v in a new Int64Value and returns a pointer to it.
|
||||
func Int64(v int64) *Int64Value {
|
||||
return &Int64Value{Value: v}
|
||||
}
|
||||
|
||||
func (x *Int64Value) Reset() {
|
||||
*x = Int64Value{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[2]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *Int64Value) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*Int64Value) ProtoMessage() {}
|
||||
|
||||
func (x *Int64Value) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[2]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use Int64Value.ProtoReflect.Descriptor instead.
|
||||
func (*Int64Value) Descriptor() ([]byte, []int) {
|
||||
return file_google_protobuf_wrappers_proto_rawDescGZIP(), []int{2}
|
||||
}
|
||||
|
||||
func (x *Int64Value) GetValue() int64 {
|
||||
if x != nil {
|
||||
return x.Value
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
// Wrapper message for `uint64`.
|
||||
//
|
||||
// The JSON representation for `UInt64Value` is JSON string.
|
||||
type UInt64Value struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
// The uint64 value.
|
||||
Value uint64 `protobuf:"varint,1,opt,name=value,proto3" json:"value,omitempty"`
|
||||
}
|
||||
|
||||
// UInt64 stores v in a new UInt64Value and returns a pointer to it.
|
||||
func UInt64(v uint64) *UInt64Value {
|
||||
return &UInt64Value{Value: v}
|
||||
}
|
||||
|
||||
func (x *UInt64Value) Reset() {
|
||||
*x = UInt64Value{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[3]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *UInt64Value) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*UInt64Value) ProtoMessage() {}
|
||||
|
||||
func (x *UInt64Value) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[3]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use UInt64Value.ProtoReflect.Descriptor instead.
|
||||
func (*UInt64Value) Descriptor() ([]byte, []int) {
|
||||
return file_google_protobuf_wrappers_proto_rawDescGZIP(), []int{3}
|
||||
}
|
||||
|
||||
func (x *UInt64Value) GetValue() uint64 {
|
||||
if x != nil {
|
||||
return x.Value
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
// Wrapper message for `int32`.
|
||||
//
|
||||
// The JSON representation for `Int32Value` is JSON number.
|
||||
type Int32Value struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
// The int32 value.
|
||||
Value int32 `protobuf:"varint,1,opt,name=value,proto3" json:"value,omitempty"`
|
||||
}
|
||||
|
||||
// Int32 stores v in a new Int32Value and returns a pointer to it.
|
||||
func Int32(v int32) *Int32Value {
|
||||
return &Int32Value{Value: v}
|
||||
}
|
||||
|
||||
func (x *Int32Value) Reset() {
|
||||
*x = Int32Value{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[4]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *Int32Value) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*Int32Value) ProtoMessage() {}
|
||||
|
||||
func (x *Int32Value) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[4]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use Int32Value.ProtoReflect.Descriptor instead.
|
||||
func (*Int32Value) Descriptor() ([]byte, []int) {
|
||||
return file_google_protobuf_wrappers_proto_rawDescGZIP(), []int{4}
|
||||
}
|
||||
|
||||
func (x *Int32Value) GetValue() int32 {
|
||||
if x != nil {
|
||||
return x.Value
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
// Wrapper message for `uint32`.
|
||||
//
|
||||
// The JSON representation for `UInt32Value` is JSON number.
|
||||
type UInt32Value struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
// The uint32 value.
|
||||
Value uint32 `protobuf:"varint,1,opt,name=value,proto3" json:"value,omitempty"`
|
||||
}
|
||||
|
||||
// UInt32 stores v in a new UInt32Value and returns a pointer to it.
|
||||
func UInt32(v uint32) *UInt32Value {
|
||||
return &UInt32Value{Value: v}
|
||||
}
|
||||
|
||||
func (x *UInt32Value) Reset() {
|
||||
*x = UInt32Value{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[5]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *UInt32Value) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*UInt32Value) ProtoMessage() {}
|
||||
|
||||
func (x *UInt32Value) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[5]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use UInt32Value.ProtoReflect.Descriptor instead.
|
||||
func (*UInt32Value) Descriptor() ([]byte, []int) {
|
||||
return file_google_protobuf_wrappers_proto_rawDescGZIP(), []int{5}
|
||||
}
|
||||
|
||||
func (x *UInt32Value) GetValue() uint32 {
|
||||
if x != nil {
|
||||
return x.Value
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
// Wrapper message for `bool`.
|
||||
//
|
||||
// The JSON representation for `BoolValue` is JSON `true` and `false`.
|
||||
type BoolValue struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
// The bool value.
|
||||
Value bool `protobuf:"varint,1,opt,name=value,proto3" json:"value,omitempty"`
|
||||
}
|
||||
|
||||
// Bool stores v in a new BoolValue and returns a pointer to it.
|
||||
func Bool(v bool) *BoolValue {
|
||||
return &BoolValue{Value: v}
|
||||
}
|
||||
|
||||
func (x *BoolValue) Reset() {
|
||||
*x = BoolValue{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[6]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *BoolValue) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*BoolValue) ProtoMessage() {}
|
||||
|
||||
func (x *BoolValue) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[6]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use BoolValue.ProtoReflect.Descriptor instead.
|
||||
func (*BoolValue) Descriptor() ([]byte, []int) {
|
||||
return file_google_protobuf_wrappers_proto_rawDescGZIP(), []int{6}
|
||||
}
|
||||
|
||||
func (x *BoolValue) GetValue() bool {
|
||||
if x != nil {
|
||||
return x.Value
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
// Wrapper message for `string`.
|
||||
//
|
||||
// The JSON representation for `StringValue` is JSON string.
|
||||
type StringValue struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
// The string value.
|
||||
Value string `protobuf:"bytes,1,opt,name=value,proto3" json:"value,omitempty"`
|
||||
}
|
||||
|
||||
// String stores v in a new StringValue and returns a pointer to it.
|
||||
func String(v string) *StringValue {
|
||||
return &StringValue{Value: v}
|
||||
}
|
||||
|
||||
func (x *StringValue) Reset() {
|
||||
*x = StringValue{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[7]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *StringValue) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*StringValue) ProtoMessage() {}
|
||||
|
||||
func (x *StringValue) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[7]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use StringValue.ProtoReflect.Descriptor instead.
|
||||
func (*StringValue) Descriptor() ([]byte, []int) {
|
||||
return file_google_protobuf_wrappers_proto_rawDescGZIP(), []int{7}
|
||||
}
|
||||
|
||||
func (x *StringValue) GetValue() string {
|
||||
if x != nil {
|
||||
return x.Value
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
// Wrapper message for `bytes`.
|
||||
//
|
||||
// The JSON representation for `BytesValue` is JSON string.
|
||||
type BytesValue struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
// The bytes value.
|
||||
Value []byte `protobuf:"bytes,1,opt,name=value,proto3" json:"value,omitempty"`
|
||||
}
|
||||
|
||||
// Bytes stores v in a new BytesValue and returns a pointer to it.
|
||||
func Bytes(v []byte) *BytesValue {
|
||||
return &BytesValue{Value: v}
|
||||
}
|
||||
|
||||
func (x *BytesValue) Reset() {
|
||||
*x = BytesValue{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[8]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *BytesValue) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*BytesValue) ProtoMessage() {}
|
||||
|
||||
func (x *BytesValue) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_google_protobuf_wrappers_proto_msgTypes[8]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use BytesValue.ProtoReflect.Descriptor instead.
|
||||
func (*BytesValue) Descriptor() ([]byte, []int) {
|
||||
return file_google_protobuf_wrappers_proto_rawDescGZIP(), []int{8}
|
||||
}
|
||||
|
||||
func (x *BytesValue) GetValue() []byte {
|
||||
if x != nil {
|
||||
return x.Value
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
var File_google_protobuf_wrappers_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_google_protobuf_wrappers_proto_rawDesc = []byte{
|
||||
0x0a, 0x1e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75,
|
||||
0x66, 0x2f, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
|
||||
0x12, 0x0f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75,
|
||||
0x66, 0x22, 0x23, 0x0a, 0x0b, 0x44, 0x6f, 0x75, 0x62, 0x6c, 0x65, 0x56, 0x61, 0x6c, 0x75, 0x65,
|
||||
0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x01, 0x52,
|
||||
0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x22, 0x0a, 0x0a, 0x46, 0x6c, 0x6f, 0x61, 0x74, 0x56,
|
||||
0x61, 0x6c, 0x75, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20,
|
||||
0x01, 0x28, 0x02, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x22, 0x0a, 0x0a, 0x49, 0x6e,
|
||||
0x74, 0x36, 0x34, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75,
|
||||
0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x23,
|
||||
0x0a, 0x0b, 0x55, 0x49, 0x6e, 0x74, 0x36, 0x34, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x14, 0x0a,
|
||||
0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x76, 0x61,
|
||||
0x6c, 0x75, 0x65, 0x22, 0x22, 0x0a, 0x0a, 0x49, 0x6e, 0x74, 0x33, 0x32, 0x56, 0x61, 0x6c, 0x75,
|
||||
0x65, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05,
|
||||
0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x23, 0x0a, 0x0b, 0x55, 0x49, 0x6e, 0x74, 0x33,
|
||||
0x32, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18,
|
||||
0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x21, 0x0a, 0x09,
|
||||
0x42, 0x6f, 0x6f, 0x6c, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c,
|
||||
0x75, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22,
|
||||
0x23, 0x0a, 0x0b, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x14,
|
||||
0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76,
|
||||
0x61, 0x6c, 0x75, 0x65, 0x22, 0x22, 0x0a, 0x0a, 0x42, 0x79, 0x74, 0x65, 0x73, 0x56, 0x61, 0x6c,
|
||||
0x75, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28,
|
||||
0x0c, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x42, 0x83, 0x01, 0x0a, 0x13, 0x63, 0x6f, 0x6d,
|
||||
0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66,
|
||||
0x42, 0x0d, 0x57, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50,
|
||||
0x01, 0x5a, 0x31, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67,
|
||||
0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x74, 0x79,
|
||||
0x70, 0x65, 0x73, 0x2f, 0x6b, 0x6e, 0x6f, 0x77, 0x6e, 0x2f, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65,
|
||||
0x72, 0x73, 0x70, 0x62, 0xf8, 0x01, 0x01, 0xa2, 0x02, 0x03, 0x47, 0x50, 0x42, 0xaa, 0x02, 0x1e,
|
||||
0x47, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e,
|
||||
0x57, 0x65, 0x6c, 0x6c, 0x4b, 0x6e, 0x6f, 0x77, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x73, 0x62, 0x06,
|
||||
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
file_google_protobuf_wrappers_proto_rawDescOnce sync.Once
|
||||
file_google_protobuf_wrappers_proto_rawDescData = file_google_protobuf_wrappers_proto_rawDesc
|
||||
)
|
||||
|
||||
func file_google_protobuf_wrappers_proto_rawDescGZIP() []byte {
|
||||
file_google_protobuf_wrappers_proto_rawDescOnce.Do(func() {
|
||||
file_google_protobuf_wrappers_proto_rawDescData = protoimpl.X.CompressGZIP(file_google_protobuf_wrappers_proto_rawDescData)
|
||||
})
|
||||
return file_google_protobuf_wrappers_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_google_protobuf_wrappers_proto_msgTypes = make([]protoimpl.MessageInfo, 9)
|
||||
var file_google_protobuf_wrappers_proto_goTypes = []interface{}{
|
||||
(*DoubleValue)(nil), // 0: google.protobuf.DoubleValue
|
||||
(*FloatValue)(nil), // 1: google.protobuf.FloatValue
|
||||
(*Int64Value)(nil), // 2: google.protobuf.Int64Value
|
||||
(*UInt64Value)(nil), // 3: google.protobuf.UInt64Value
|
||||
(*Int32Value)(nil), // 4: google.protobuf.Int32Value
|
||||
(*UInt32Value)(nil), // 5: google.protobuf.UInt32Value
|
||||
(*BoolValue)(nil), // 6: google.protobuf.BoolValue
|
||||
(*StringValue)(nil), // 7: google.protobuf.StringValue
|
||||
(*BytesValue)(nil), // 8: google.protobuf.BytesValue
|
||||
}
|
||||
var file_google_protobuf_wrappers_proto_depIdxs = []int32{
|
||||
0, // [0:0] is the sub-list for method output_type
|
||||
0, // [0:0] is the sub-list for method input_type
|
||||
0, // [0:0] is the sub-list for extension type_name
|
||||
0, // [0:0] is the sub-list for extension extendee
|
||||
0, // [0:0] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_google_protobuf_wrappers_proto_init() }
|
||||
func file_google_protobuf_wrappers_proto_init() {
|
||||
if File_google_protobuf_wrappers_proto != nil {
|
||||
return
|
||||
}
|
||||
if !protoimpl.UnsafeEnabled {
|
||||
file_google_protobuf_wrappers_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DoubleValue); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_google_protobuf_wrappers_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*FloatValue); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_google_protobuf_wrappers_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*Int64Value); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_google_protobuf_wrappers_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*UInt64Value); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_google_protobuf_wrappers_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*Int32Value); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_google_protobuf_wrappers_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*UInt32Value); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_google_protobuf_wrappers_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*BoolValue); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_google_protobuf_wrappers_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*StringValue); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_google_protobuf_wrappers_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*BytesValue); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_google_protobuf_wrappers_proto_rawDesc,
|
||||
NumEnums: 0,
|
||||
NumMessages: 9,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_google_protobuf_wrappers_proto_goTypes,
|
||||
DependencyIndexes: file_google_protobuf_wrappers_proto_depIdxs,
|
||||
MessageInfos: file_google_protobuf_wrappers_proto_msgTypes,
|
||||
}.Build()
|
||||
File_google_protobuf_wrappers_proto = out.File
|
||||
file_google_protobuf_wrappers_proto_rawDesc = nil
|
||||
file_google_protobuf_wrappers_proto_goTypes = nil
|
||||
file_google_protobuf_wrappers_proto_depIdxs = nil
|
||||
}
|
29
vendor/modules.txt
vendored
29
vendor/modules.txt
vendored
|
@ -11,11 +11,12 @@ cloud.google.com/go/compute/metadata
|
|||
# cloud.google.com/go/iam v0.3.0
|
||||
## explicit; go 1.15
|
||||
cloud.google.com/go/iam
|
||||
# cloud.google.com/go/storage v1.23.0
|
||||
## explicit; go 1.15
|
||||
# cloud.google.com/go/storage v1.24.0
|
||||
## explicit; go 1.17
|
||||
cloud.google.com/go/storage
|
||||
cloud.google.com/go/storage/internal
|
||||
cloud.google.com/go/storage/internal/apiv2
|
||||
cloud.google.com/go/storage/internal/apiv2/stubs
|
||||
# github.com/VictoriaMetrics/fastcache v1.10.0
|
||||
## explicit; go 1.13
|
||||
github.com/VictoriaMetrics/fastcache
|
||||
|
@ -34,7 +35,7 @@ github.com/VictoriaMetrics/metricsql/binaryop
|
|||
# github.com/VividCortex/ewma v1.2.0
|
||||
## explicit; go 1.12
|
||||
github.com/VividCortex/ewma
|
||||
# github.com/aws/aws-sdk-go v1.44.56
|
||||
# github.com/aws/aws-sdk-go v1.44.59
|
||||
## explicit; go 1.11
|
||||
github.com/aws/aws-sdk-go/aws
|
||||
github.com/aws/aws-sdk-go/aws/arn
|
||||
|
@ -124,6 +125,7 @@ github.com/golang/protobuf/proto
|
|||
github.com/golang/protobuf/ptypes
|
||||
github.com/golang/protobuf/ptypes/any
|
||||
github.com/golang/protobuf/ptypes/duration
|
||||
github.com/golang/protobuf/ptypes/empty
|
||||
github.com/golang/protobuf/ptypes/timestamp
|
||||
# github.com/golang/snappy v0.0.4
|
||||
## explicit
|
||||
|
@ -148,9 +150,6 @@ github.com/googleapis/gax-go/v2
|
|||
github.com/googleapis/gax-go/v2/apierror
|
||||
github.com/googleapis/gax-go/v2/apierror/internal/proto
|
||||
github.com/googleapis/gax-go/v2/internal
|
||||
# github.com/googleapis/go-type-adapters v1.0.0
|
||||
## explicit; go 1.11
|
||||
github.com/googleapis/go-type-adapters/adapters
|
||||
# github.com/influxdata/influxdb v1.9.8
|
||||
## explicit; go 1.17
|
||||
github.com/influxdata/influxdb/client/v2
|
||||
|
@ -159,7 +158,7 @@ github.com/influxdata/influxdb/pkg/escape
|
|||
# github.com/jmespath/go-jmespath v0.4.0
|
||||
## explicit; go 1.14
|
||||
github.com/jmespath/go-jmespath
|
||||
# github.com/klauspost/compress v1.15.8
|
||||
# github.com/klauspost/compress v1.15.9
|
||||
## explicit; go 1.16
|
||||
github.com/klauspost/compress
|
||||
github.com/klauspost/compress/flate
|
||||
|
@ -229,7 +228,7 @@ github.com/rivo/uniseg
|
|||
# github.com/russross/blackfriday/v2 v2.1.0
|
||||
## explicit
|
||||
github.com/russross/blackfriday/v2
|
||||
# github.com/urfave/cli/v2 v2.11.0
|
||||
# github.com/urfave/cli/v2 v2.11.1
|
||||
## explicit; go 1.18
|
||||
github.com/urfave/cli/v2
|
||||
# github.com/valyala/bytebufferpool v1.0.0
|
||||
|
@ -293,7 +292,7 @@ golang.org/x/net/internal/socks
|
|||
golang.org/x/net/internal/timeseries
|
||||
golang.org/x/net/proxy
|
||||
golang.org/x/net/trace
|
||||
# golang.org/x/oauth2 v0.0.0-20220630143837-2104d58473e0
|
||||
# golang.org/x/oauth2 v0.0.0-20220718184931-c8730f7fcb92
|
||||
## explicit; go 1.17
|
||||
golang.org/x/oauth2
|
||||
golang.org/x/oauth2/authhandler
|
||||
|
@ -321,7 +320,7 @@ golang.org/x/text/unicode/norm
|
|||
## explicit; go 1.17
|
||||
golang.org/x/xerrors
|
||||
golang.org/x/xerrors/internal
|
||||
# google.golang.org/api v0.87.0
|
||||
# google.golang.org/api v0.88.0
|
||||
## explicit; go 1.15
|
||||
google.golang.org/api/googleapi
|
||||
google.golang.org/api/googleapi/transport
|
||||
|
@ -354,21 +353,16 @@ google.golang.org/appengine/internal/socket
|
|||
google.golang.org/appengine/internal/urlfetch
|
||||
google.golang.org/appengine/socket
|
||||
google.golang.org/appengine/urlfetch
|
||||
# google.golang.org/genproto v0.0.0-20220715211116-798f69b842b9
|
||||
# google.golang.org/genproto v0.0.0-20220720214146-176da50484ac
|
||||
## explicit; go 1.17
|
||||
google.golang.org/genproto/googleapis/api/annotations
|
||||
google.golang.org/genproto/googleapis/iam/v1
|
||||
google.golang.org/genproto/googleapis/rpc/code
|
||||
google.golang.org/genproto/googleapis/rpc/errdetails
|
||||
google.golang.org/genproto/googleapis/rpc/status
|
||||
google.golang.org/genproto/googleapis/storage/v2
|
||||
google.golang.org/genproto/googleapis/type/color
|
||||
google.golang.org/genproto/googleapis/type/date
|
||||
google.golang.org/genproto/googleapis/type/datetime
|
||||
google.golang.org/genproto/googleapis/type/decimal
|
||||
google.golang.org/genproto/googleapis/type/expr
|
||||
google.golang.org/genproto/googleapis/type/fraction
|
||||
google.golang.org/genproto/googleapis/type/month
|
||||
google.golang.org/genproto/protobuf/field_mask
|
||||
# google.golang.org/grpc v1.48.0
|
||||
## explicit; go 1.14
|
||||
google.golang.org/grpc
|
||||
|
@ -467,7 +461,6 @@ google.golang.org/protobuf/types/known/durationpb
|
|||
google.golang.org/protobuf/types/known/emptypb
|
||||
google.golang.org/protobuf/types/known/fieldmaskpb
|
||||
google.golang.org/protobuf/types/known/timestamppb
|
||||
google.golang.org/protobuf/types/known/wrapperspb
|
||||
# gopkg.in/yaml.v2 v2.4.0
|
||||
## explicit; go 1.15
|
||||
gopkg.in/yaml.v2
|
||||
|
|
Loading…
Reference in a new issue