github.com/argoproj/argo-cd/v3@v3.2.1/commitserver/apiclient/commit.pb.go (about) 1 // Code generated by protoc-gen-gogo. DO NOT EDIT. 2 // source: commitserver/commit/commit.proto 3 4 package apiclient 5 6 import ( 7 context "context" 8 fmt "fmt" 9 v1alpha1 "github.com/argoproj/argo-cd/v3/pkg/apis/application/v1alpha1" 10 proto "github.com/gogo/protobuf/proto" 11 grpc "google.golang.org/grpc" 12 codes "google.golang.org/grpc/codes" 13 status "google.golang.org/grpc/status" 14 io "io" 15 math "math" 16 math_bits "math/bits" 17 ) 18 19 // Reference imports to suppress errors if they are not otherwise used. 20 var _ = proto.Marshal 21 var _ = fmt.Errorf 22 var _ = math.Inf 23 24 // This is a compile-time assertion to ensure that this generated file 25 // is compatible with the proto package it is being compiled against. 26 // A compilation error at this line likely means your copy of the 27 // proto package needs to be updated. 28 const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package 29 30 // CommitHydratedManifestsRequest is the request to commit hydrated manifests to a repository. 31 type CommitHydratedManifestsRequest struct { 32 // Repo contains repository information including, at minimum, the URL of the repository. Generally it will contain 33 // repo credentials. 34 Repo *v1alpha1.Repository `protobuf:"bytes,1,opt,name=repo,proto3" json:"repo,omitempty"` 35 // SyncBranch is the branch Argo CD syncs from, i.e. the hydrated branch. 36 SyncBranch string `protobuf:"bytes,2,opt,name=syncBranch,proto3" json:"syncBranch,omitempty"` 37 // TargetBranch is the branch Argo CD is committing to, i.e. the branch that will be updated. 38 TargetBranch string `protobuf:"bytes,3,opt,name=targetBranch,proto3" json:"targetBranch,omitempty"` 39 // DrySha is the commit SHA from the dry branch, i.e. pre-rendered manifest branch. 40 DrySha string `protobuf:"bytes,4,opt,name=drySha,proto3" json:"drySha,omitempty"` 41 // CommitMessage is the commit message to use when committing changes. 42 CommitMessage string `protobuf:"bytes,5,opt,name=commitMessage,proto3" json:"commitMessage,omitempty"` 43 // Paths contains the paths to write hydrated manifests to, along with the manifests and commands to execute. 44 Paths []*PathDetails `protobuf:"bytes,6,rep,name=paths,proto3" json:"paths,omitempty"` 45 // DryCommitMetadata contains metadata about the DRY commit, such as the author and committer. 46 DryCommitMetadata *v1alpha1.RevisionMetadata `protobuf:"bytes,7,opt,name=dryCommitMetadata,proto3" json:"dryCommitMetadata,omitempty"` 47 XXX_NoUnkeyedLiteral struct{} `json:"-"` 48 XXX_unrecognized []byte `json:"-"` 49 XXX_sizecache int32 `json:"-"` 50 } 51 52 func (m *CommitHydratedManifestsRequest) Reset() { *m = CommitHydratedManifestsRequest{} } 53 func (m *CommitHydratedManifestsRequest) String() string { return proto.CompactTextString(m) } 54 func (*CommitHydratedManifestsRequest) ProtoMessage() {} 55 func (*CommitHydratedManifestsRequest) Descriptor() ([]byte, []int) { 56 return fileDescriptor_cf3a3abbc35e3069, []int{0} 57 } 58 func (m *CommitHydratedManifestsRequest) XXX_Unmarshal(b []byte) error { 59 return m.Unmarshal(b) 60 } 61 func (m *CommitHydratedManifestsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 62 if deterministic { 63 return xxx_messageInfo_CommitHydratedManifestsRequest.Marshal(b, m, deterministic) 64 } else { 65 b = b[:cap(b)] 66 n, err := m.MarshalToSizedBuffer(b) 67 if err != nil { 68 return nil, err 69 } 70 return b[:n], nil 71 } 72 } 73 func (m *CommitHydratedManifestsRequest) XXX_Merge(src proto.Message) { 74 xxx_messageInfo_CommitHydratedManifestsRequest.Merge(m, src) 75 } 76 func (m *CommitHydratedManifestsRequest) XXX_Size() int { 77 return m.Size() 78 } 79 func (m *CommitHydratedManifestsRequest) XXX_DiscardUnknown() { 80 xxx_messageInfo_CommitHydratedManifestsRequest.DiscardUnknown(m) 81 } 82 83 var xxx_messageInfo_CommitHydratedManifestsRequest proto.InternalMessageInfo 84 85 func (m *CommitHydratedManifestsRequest) GetRepo() *v1alpha1.Repository { 86 if m != nil { 87 return m.Repo 88 } 89 return nil 90 } 91 92 func (m *CommitHydratedManifestsRequest) GetSyncBranch() string { 93 if m != nil { 94 return m.SyncBranch 95 } 96 return "" 97 } 98 99 func (m *CommitHydratedManifestsRequest) GetTargetBranch() string { 100 if m != nil { 101 return m.TargetBranch 102 } 103 return "" 104 } 105 106 func (m *CommitHydratedManifestsRequest) GetDrySha() string { 107 if m != nil { 108 return m.DrySha 109 } 110 return "" 111 } 112 113 func (m *CommitHydratedManifestsRequest) GetCommitMessage() string { 114 if m != nil { 115 return m.CommitMessage 116 } 117 return "" 118 } 119 120 func (m *CommitHydratedManifestsRequest) GetPaths() []*PathDetails { 121 if m != nil { 122 return m.Paths 123 } 124 return nil 125 } 126 127 func (m *CommitHydratedManifestsRequest) GetDryCommitMetadata() *v1alpha1.RevisionMetadata { 128 if m != nil { 129 return m.DryCommitMetadata 130 } 131 return nil 132 } 133 134 // PathDetails holds information about hydrated manifests to be written to a particular path in the hydrated manifests 135 // commit. 136 type PathDetails struct { 137 // Path is the path to write the hydrated manifests to. 138 Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"` 139 // Manifests contains the manifests to write to the path. 140 Manifests []*HydratedManifestDetails `protobuf:"bytes,2,rep,name=manifests,proto3" json:"manifests,omitempty"` 141 // Commands contains the commands executed when hydrating the manifests. 142 Commands []string `protobuf:"bytes,3,rep,name=commands,proto3" json:"commands,omitempty"` 143 XXX_NoUnkeyedLiteral struct{} `json:"-"` 144 XXX_unrecognized []byte `json:"-"` 145 XXX_sizecache int32 `json:"-"` 146 } 147 148 func (m *PathDetails) Reset() { *m = PathDetails{} } 149 func (m *PathDetails) String() string { return proto.CompactTextString(m) } 150 func (*PathDetails) ProtoMessage() {} 151 func (*PathDetails) Descriptor() ([]byte, []int) { 152 return fileDescriptor_cf3a3abbc35e3069, []int{1} 153 } 154 func (m *PathDetails) XXX_Unmarshal(b []byte) error { 155 return m.Unmarshal(b) 156 } 157 func (m *PathDetails) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 158 if deterministic { 159 return xxx_messageInfo_PathDetails.Marshal(b, m, deterministic) 160 } else { 161 b = b[:cap(b)] 162 n, err := m.MarshalToSizedBuffer(b) 163 if err != nil { 164 return nil, err 165 } 166 return b[:n], nil 167 } 168 } 169 func (m *PathDetails) XXX_Merge(src proto.Message) { 170 xxx_messageInfo_PathDetails.Merge(m, src) 171 } 172 func (m *PathDetails) XXX_Size() int { 173 return m.Size() 174 } 175 func (m *PathDetails) XXX_DiscardUnknown() { 176 xxx_messageInfo_PathDetails.DiscardUnknown(m) 177 } 178 179 var xxx_messageInfo_PathDetails proto.InternalMessageInfo 180 181 func (m *PathDetails) GetPath() string { 182 if m != nil { 183 return m.Path 184 } 185 return "" 186 } 187 188 func (m *PathDetails) GetManifests() []*HydratedManifestDetails { 189 if m != nil { 190 return m.Manifests 191 } 192 return nil 193 } 194 195 func (m *PathDetails) GetCommands() []string { 196 if m != nil { 197 return m.Commands 198 } 199 return nil 200 } 201 202 // ManifestDetails contains the hydrated manifests. 203 type HydratedManifestDetails struct { 204 // ManifestJSON is the hydrated manifest as JSON. 205 ManifestJSON string `protobuf:"bytes,1,opt,name=manifestJSON,proto3" json:"manifestJSON,omitempty"` 206 XXX_NoUnkeyedLiteral struct{} `json:"-"` 207 XXX_unrecognized []byte `json:"-"` 208 XXX_sizecache int32 `json:"-"` 209 } 210 211 func (m *HydratedManifestDetails) Reset() { *m = HydratedManifestDetails{} } 212 func (m *HydratedManifestDetails) String() string { return proto.CompactTextString(m) } 213 func (*HydratedManifestDetails) ProtoMessage() {} 214 func (*HydratedManifestDetails) Descriptor() ([]byte, []int) { 215 return fileDescriptor_cf3a3abbc35e3069, []int{2} 216 } 217 func (m *HydratedManifestDetails) XXX_Unmarshal(b []byte) error { 218 return m.Unmarshal(b) 219 } 220 func (m *HydratedManifestDetails) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 221 if deterministic { 222 return xxx_messageInfo_HydratedManifestDetails.Marshal(b, m, deterministic) 223 } else { 224 b = b[:cap(b)] 225 n, err := m.MarshalToSizedBuffer(b) 226 if err != nil { 227 return nil, err 228 } 229 return b[:n], nil 230 } 231 } 232 func (m *HydratedManifestDetails) XXX_Merge(src proto.Message) { 233 xxx_messageInfo_HydratedManifestDetails.Merge(m, src) 234 } 235 func (m *HydratedManifestDetails) XXX_Size() int { 236 return m.Size() 237 } 238 func (m *HydratedManifestDetails) XXX_DiscardUnknown() { 239 xxx_messageInfo_HydratedManifestDetails.DiscardUnknown(m) 240 } 241 242 var xxx_messageInfo_HydratedManifestDetails proto.InternalMessageInfo 243 244 func (m *HydratedManifestDetails) GetManifestJSON() string { 245 if m != nil { 246 return m.ManifestJSON 247 } 248 return "" 249 } 250 251 // ManifestsResponse is the response to the ManifestsRequest. 252 type CommitHydratedManifestsResponse struct { 253 // HydratedSha is the commit SHA of the hydrated manifests commit. 254 HydratedSha string `protobuf:"bytes,1,opt,name=hydratedSha,proto3" json:"hydratedSha,omitempty"` 255 XXX_NoUnkeyedLiteral struct{} `json:"-"` 256 XXX_unrecognized []byte `json:"-"` 257 XXX_sizecache int32 `json:"-"` 258 } 259 260 func (m *CommitHydratedManifestsResponse) Reset() { *m = CommitHydratedManifestsResponse{} } 261 func (m *CommitHydratedManifestsResponse) String() string { return proto.CompactTextString(m) } 262 func (*CommitHydratedManifestsResponse) ProtoMessage() {} 263 func (*CommitHydratedManifestsResponse) Descriptor() ([]byte, []int) { 264 return fileDescriptor_cf3a3abbc35e3069, []int{3} 265 } 266 func (m *CommitHydratedManifestsResponse) XXX_Unmarshal(b []byte) error { 267 return m.Unmarshal(b) 268 } 269 func (m *CommitHydratedManifestsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 270 if deterministic { 271 return xxx_messageInfo_CommitHydratedManifestsResponse.Marshal(b, m, deterministic) 272 } else { 273 b = b[:cap(b)] 274 n, err := m.MarshalToSizedBuffer(b) 275 if err != nil { 276 return nil, err 277 } 278 return b[:n], nil 279 } 280 } 281 func (m *CommitHydratedManifestsResponse) XXX_Merge(src proto.Message) { 282 xxx_messageInfo_CommitHydratedManifestsResponse.Merge(m, src) 283 } 284 func (m *CommitHydratedManifestsResponse) XXX_Size() int { 285 return m.Size() 286 } 287 func (m *CommitHydratedManifestsResponse) XXX_DiscardUnknown() { 288 xxx_messageInfo_CommitHydratedManifestsResponse.DiscardUnknown(m) 289 } 290 291 var xxx_messageInfo_CommitHydratedManifestsResponse proto.InternalMessageInfo 292 293 func (m *CommitHydratedManifestsResponse) GetHydratedSha() string { 294 if m != nil { 295 return m.HydratedSha 296 } 297 return "" 298 } 299 300 func init() { 301 proto.RegisterType((*CommitHydratedManifestsRequest)(nil), "CommitHydratedManifestsRequest") 302 proto.RegisterType((*PathDetails)(nil), "PathDetails") 303 proto.RegisterType((*HydratedManifestDetails)(nil), "HydratedManifestDetails") 304 proto.RegisterType((*CommitHydratedManifestsResponse)(nil), "CommitHydratedManifestsResponse") 305 } 306 307 func init() { proto.RegisterFile("commitserver/commit/commit.proto", fileDescriptor_cf3a3abbc35e3069) } 308 309 var fileDescriptor_cf3a3abbc35e3069 = []byte{ 310 // 479 bytes of a gzipped FileDescriptorProto 311 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x53, 0xc1, 0x6e, 0xd3, 0x40, 312 0x10, 0x95, 0xeb, 0x34, 0x90, 0x49, 0x7b, 0x60, 0x0f, 0xd4, 0xca, 0xc1, 0xb5, 0x2c, 0x0e, 0xb9, 313 0xb0, 0x56, 0x13, 0xc1, 0x8d, 0x4b, 0xc3, 0xa1, 0x42, 0xb4, 0x20, 0xe7, 0x86, 0x2a, 0xa1, 0xa9, 314 0xbd, 0xd8, 0x4b, 0x63, 0xef, 0xb2, 0xbb, 0xb1, 0x64, 0x89, 0xaf, 0xe1, 0x6b, 0x38, 0xf2, 0x09, 315 0x28, 0x5f, 0x82, 0xbc, 0xb6, 0x69, 0x02, 0x0a, 0x39, 0x70, 0xf2, 0xce, 0xbc, 0xf1, 0x7b, 0xb3, 316 0xf3, 0x76, 0x20, 0x48, 0x44, 0x51, 0x70, 0xa3, 0x99, 0xaa, 0x98, 0x8a, 0xda, 0xa0, 0xfb, 0x50, 317 0xa9, 0x84, 0x11, 0x93, 0xb7, 0x19, 0x37, 0xf9, 0xfa, 0x8e, 0x26, 0xa2, 0x88, 0x50, 0x65, 0x42, 318 0x2a, 0xf1, 0xd9, 0x1e, 0x9e, 0x27, 0x69, 0x54, 0xcd, 0x23, 0x79, 0x9f, 0x45, 0x28, 0xb9, 0x8e, 319 0x50, 0xca, 0x15, 0x4f, 0xd0, 0x70, 0x51, 0x46, 0xd5, 0x05, 0xae, 0x64, 0x8e, 0x17, 0x51, 0xc6, 320 0x4a, 0xa6, 0xd0, 0xb0, 0xb4, 0x65, 0x0b, 0xbf, 0xb9, 0xe0, 0x2f, 0x2c, 0xfd, 0x55, 0x9d, 0x5a, 321 0xe0, 0x1a, 0x4b, 0xfe, 0x89, 0x69, 0xa3, 0x63, 0xf6, 0x65, 0xcd, 0xb4, 0x21, 0xb7, 0x30, 0x50, 322 0x4c, 0x0a, 0xcf, 0x09, 0x9c, 0xe9, 0x78, 0x76, 0x45, 0x1f, 0xf4, 0x69, 0xaf, 0x6f, 0x0f, 0x1f, 323 0x93, 0x94, 0x56, 0x73, 0x2a, 0xef, 0x33, 0xda, 0xe8, 0xd3, 0x2d, 0x7d, 0xda, 0xeb, 0xd3, 0x98, 324 0x49, 0xa1, 0xb9, 0x11, 0xaa, 0x8e, 0x2d, 0x2b, 0xf1, 0x01, 0x74, 0x5d, 0x26, 0x97, 0x0a, 0xcb, 325 0x24, 0xf7, 0x8e, 0x02, 0x67, 0x3a, 0x8a, 0xb7, 0x32, 0x24, 0x84, 0x13, 0x83, 0x2a, 0x63, 0xa6, 326 0xab, 0x70, 0x6d, 0xc5, 0x4e, 0x8e, 0x3c, 0x85, 0x61, 0xaa, 0xea, 0x65, 0x8e, 0xde, 0xc0, 0xa2, 327 0x5d, 0x44, 0x9e, 0xc1, 0x69, 0x3b, 0xba, 0x6b, 0xa6, 0x35, 0x66, 0xcc, 0x3b, 0xb6, 0xf0, 0x6e, 328 0x92, 0x84, 0x70, 0x2c, 0xd1, 0xe4, 0xda, 0x1b, 0x06, 0xee, 0x74, 0x3c, 0x3b, 0xa1, 0xef, 0xd1, 329 0xe4, 0xaf, 0x99, 0x41, 0xbe, 0xd2, 0x71, 0x0b, 0x91, 0xaf, 0xf0, 0x24, 0x55, 0xf5, 0xa2, 0xfb, 330 0xcf, 0x60, 0x8a, 0x06, 0xbd, 0x47, 0x76, 0x20, 0x37, 0xff, 0x3b, 0x90, 0x8a, 0x6b, 0x2e, 0xca, 331 0x9e, 0x35, 0xfe, 0x5b, 0x28, 0x5c, 0xc3, 0x78, 0xab, 0x27, 0x42, 0x60, 0xd0, 0x74, 0x65, 0x0d, 332 0x19, 0xc5, 0xf6, 0x4c, 0x5e, 0xc2, 0xa8, 0xe8, 0x8d, 0xf3, 0x8e, 0xec, 0x45, 0x3c, 0xfa, 0xa7, 333 0xa5, 0xfd, 0xa5, 0x1e, 0x4a, 0xc9, 0x04, 0x1e, 0x37, 0xd3, 0xc0, 0x32, 0xd5, 0x9e, 0x1b, 0xb8, 334 0xd3, 0x51, 0xfc, 0x3b, 0x0e, 0x5f, 0xc1, 0xd9, 0x1e, 0x86, 0xc6, 0x95, 0x9e, 0xe3, 0xcd, 0xf2, 335 0xdd, 0x4d, 0xd7, 0xca, 0x4e, 0x2e, 0x5c, 0xc0, 0xf9, 0xde, 0x97, 0xa5, 0xa5, 0x28, 0x35, 0x23, 336 0x01, 0x8c, 0xf3, 0x0e, 0x6c, 0xdc, 0x6b, 0x59, 0xb6, 0x53, 0xb3, 0x02, 0x4e, 0x5b, 0x92, 0x25, 337 0x53, 0x15, 0x4f, 0x18, 0xb9, 0x85, 0xb3, 0x3d, 0xac, 0xe4, 0x9c, 0xfe, 0xfb, 0x25, 0x4f, 0x02, 338 0x7a, 0xa0, 0xa1, 0xcb, 0xc5, 0xf7, 0x8d, 0xef, 0xfc, 0xd8, 0xf8, 0xce, 0xcf, 0x8d, 0xef, 0x7c, 339 0x78, 0x71, 0x60, 0xd5, 0x76, 0x76, 0x15, 0x25, 0x4f, 0x56, 0x9c, 0x95, 0xe6, 0x6e, 0x68, 0x57, 340 0x6b, 0xfe, 0x2b, 0x00, 0x00, 0xff, 0xff, 0x21, 0x3b, 0xa8, 0x3c, 0xcc, 0x03, 0x00, 0x00, 341 } 342 343 // Reference imports to suppress errors if they are not otherwise used. 344 var _ context.Context 345 var _ grpc.ClientConn 346 347 // This is a compile-time assertion to ensure that this generated file 348 // is compatible with the grpc package it is being compiled against. 349 const _ = grpc.SupportPackageIsVersion4 350 351 // CommitServiceClient is the client API for CommitService service. 352 // 353 // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. 354 type CommitServiceClient interface { 355 // Commit commits hydrated manifests to a repository. 356 CommitHydratedManifests(ctx context.Context, in *CommitHydratedManifestsRequest, opts ...grpc.CallOption) (*CommitHydratedManifestsResponse, error) 357 } 358 359 type commitServiceClient struct { 360 cc *grpc.ClientConn 361 } 362 363 func NewCommitServiceClient(cc *grpc.ClientConn) CommitServiceClient { 364 return &commitServiceClient{cc} 365 } 366 367 func (c *commitServiceClient) CommitHydratedManifests(ctx context.Context, in *CommitHydratedManifestsRequest, opts ...grpc.CallOption) (*CommitHydratedManifestsResponse, error) { 368 out := new(CommitHydratedManifestsResponse) 369 err := c.cc.Invoke(ctx, "/CommitService/CommitHydratedManifests", in, out, opts...) 370 if err != nil { 371 return nil, err 372 } 373 return out, nil 374 } 375 376 // CommitServiceServer is the server API for CommitService service. 377 type CommitServiceServer interface { 378 // Commit commits hydrated manifests to a repository. 379 CommitHydratedManifests(context.Context, *CommitHydratedManifestsRequest) (*CommitHydratedManifestsResponse, error) 380 } 381 382 // UnimplementedCommitServiceServer can be embedded to have forward compatible implementations. 383 type UnimplementedCommitServiceServer struct { 384 } 385 386 func (*UnimplementedCommitServiceServer) CommitHydratedManifests(ctx context.Context, req *CommitHydratedManifestsRequest) (*CommitHydratedManifestsResponse, error) { 387 return nil, status.Errorf(codes.Unimplemented, "method CommitHydratedManifests not implemented") 388 } 389 390 func RegisterCommitServiceServer(s *grpc.Server, srv CommitServiceServer) { 391 s.RegisterService(&_CommitService_serviceDesc, srv) 392 } 393 394 func _CommitService_CommitHydratedManifests_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 395 in := new(CommitHydratedManifestsRequest) 396 if err := dec(in); err != nil { 397 return nil, err 398 } 399 if interceptor == nil { 400 return srv.(CommitServiceServer).CommitHydratedManifests(ctx, in) 401 } 402 info := &grpc.UnaryServerInfo{ 403 Server: srv, 404 FullMethod: "/CommitService/CommitHydratedManifests", 405 } 406 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 407 return srv.(CommitServiceServer).CommitHydratedManifests(ctx, req.(*CommitHydratedManifestsRequest)) 408 } 409 return interceptor(ctx, in, info, handler) 410 } 411 412 var _CommitService_serviceDesc = grpc.ServiceDesc{ 413 ServiceName: "CommitService", 414 HandlerType: (*CommitServiceServer)(nil), 415 Methods: []grpc.MethodDesc{ 416 { 417 MethodName: "CommitHydratedManifests", 418 Handler: _CommitService_CommitHydratedManifests_Handler, 419 }, 420 }, 421 Streams: []grpc.StreamDesc{}, 422 Metadata: "commitserver/commit/commit.proto", 423 } 424 425 func (m *CommitHydratedManifestsRequest) Marshal() (dAtA []byte, err error) { 426 size := m.Size() 427 dAtA = make([]byte, size) 428 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 429 if err != nil { 430 return nil, err 431 } 432 return dAtA[:n], nil 433 } 434 435 func (m *CommitHydratedManifestsRequest) MarshalTo(dAtA []byte) (int, error) { 436 size := m.Size() 437 return m.MarshalToSizedBuffer(dAtA[:size]) 438 } 439 440 func (m *CommitHydratedManifestsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { 441 i := len(dAtA) 442 _ = i 443 var l int 444 _ = l 445 if m.XXX_unrecognized != nil { 446 i -= len(m.XXX_unrecognized) 447 copy(dAtA[i:], m.XXX_unrecognized) 448 } 449 if m.DryCommitMetadata != nil { 450 { 451 size, err := m.DryCommitMetadata.MarshalToSizedBuffer(dAtA[:i]) 452 if err != nil { 453 return 0, err 454 } 455 i -= size 456 i = encodeVarintCommit(dAtA, i, uint64(size)) 457 } 458 i-- 459 dAtA[i] = 0x3a 460 } 461 if len(m.Paths) > 0 { 462 for iNdEx := len(m.Paths) - 1; iNdEx >= 0; iNdEx-- { 463 { 464 size, err := m.Paths[iNdEx].MarshalToSizedBuffer(dAtA[:i]) 465 if err != nil { 466 return 0, err 467 } 468 i -= size 469 i = encodeVarintCommit(dAtA, i, uint64(size)) 470 } 471 i-- 472 dAtA[i] = 0x32 473 } 474 } 475 if len(m.CommitMessage) > 0 { 476 i -= len(m.CommitMessage) 477 copy(dAtA[i:], m.CommitMessage) 478 i = encodeVarintCommit(dAtA, i, uint64(len(m.CommitMessage))) 479 i-- 480 dAtA[i] = 0x2a 481 } 482 if len(m.DrySha) > 0 { 483 i -= len(m.DrySha) 484 copy(dAtA[i:], m.DrySha) 485 i = encodeVarintCommit(dAtA, i, uint64(len(m.DrySha))) 486 i-- 487 dAtA[i] = 0x22 488 } 489 if len(m.TargetBranch) > 0 { 490 i -= len(m.TargetBranch) 491 copy(dAtA[i:], m.TargetBranch) 492 i = encodeVarintCommit(dAtA, i, uint64(len(m.TargetBranch))) 493 i-- 494 dAtA[i] = 0x1a 495 } 496 if len(m.SyncBranch) > 0 { 497 i -= len(m.SyncBranch) 498 copy(dAtA[i:], m.SyncBranch) 499 i = encodeVarintCommit(dAtA, i, uint64(len(m.SyncBranch))) 500 i-- 501 dAtA[i] = 0x12 502 } 503 if m.Repo != nil { 504 { 505 size, err := m.Repo.MarshalToSizedBuffer(dAtA[:i]) 506 if err != nil { 507 return 0, err 508 } 509 i -= size 510 i = encodeVarintCommit(dAtA, i, uint64(size)) 511 } 512 i-- 513 dAtA[i] = 0xa 514 } 515 return len(dAtA) - i, nil 516 } 517 518 func (m *PathDetails) Marshal() (dAtA []byte, err error) { 519 size := m.Size() 520 dAtA = make([]byte, size) 521 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 522 if err != nil { 523 return nil, err 524 } 525 return dAtA[:n], nil 526 } 527 528 func (m *PathDetails) MarshalTo(dAtA []byte) (int, error) { 529 size := m.Size() 530 return m.MarshalToSizedBuffer(dAtA[:size]) 531 } 532 533 func (m *PathDetails) MarshalToSizedBuffer(dAtA []byte) (int, error) { 534 i := len(dAtA) 535 _ = i 536 var l int 537 _ = l 538 if m.XXX_unrecognized != nil { 539 i -= len(m.XXX_unrecognized) 540 copy(dAtA[i:], m.XXX_unrecognized) 541 } 542 if len(m.Commands) > 0 { 543 for iNdEx := len(m.Commands) - 1; iNdEx >= 0; iNdEx-- { 544 i -= len(m.Commands[iNdEx]) 545 copy(dAtA[i:], m.Commands[iNdEx]) 546 i = encodeVarintCommit(dAtA, i, uint64(len(m.Commands[iNdEx]))) 547 i-- 548 dAtA[i] = 0x1a 549 } 550 } 551 if len(m.Manifests) > 0 { 552 for iNdEx := len(m.Manifests) - 1; iNdEx >= 0; iNdEx-- { 553 { 554 size, err := m.Manifests[iNdEx].MarshalToSizedBuffer(dAtA[:i]) 555 if err != nil { 556 return 0, err 557 } 558 i -= size 559 i = encodeVarintCommit(dAtA, i, uint64(size)) 560 } 561 i-- 562 dAtA[i] = 0x12 563 } 564 } 565 if len(m.Path) > 0 { 566 i -= len(m.Path) 567 copy(dAtA[i:], m.Path) 568 i = encodeVarintCommit(dAtA, i, uint64(len(m.Path))) 569 i-- 570 dAtA[i] = 0xa 571 } 572 return len(dAtA) - i, nil 573 } 574 575 func (m *HydratedManifestDetails) Marshal() (dAtA []byte, err error) { 576 size := m.Size() 577 dAtA = make([]byte, size) 578 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 579 if err != nil { 580 return nil, err 581 } 582 return dAtA[:n], nil 583 } 584 585 func (m *HydratedManifestDetails) MarshalTo(dAtA []byte) (int, error) { 586 size := m.Size() 587 return m.MarshalToSizedBuffer(dAtA[:size]) 588 } 589 590 func (m *HydratedManifestDetails) MarshalToSizedBuffer(dAtA []byte) (int, error) { 591 i := len(dAtA) 592 _ = i 593 var l int 594 _ = l 595 if m.XXX_unrecognized != nil { 596 i -= len(m.XXX_unrecognized) 597 copy(dAtA[i:], m.XXX_unrecognized) 598 } 599 if len(m.ManifestJSON) > 0 { 600 i -= len(m.ManifestJSON) 601 copy(dAtA[i:], m.ManifestJSON) 602 i = encodeVarintCommit(dAtA, i, uint64(len(m.ManifestJSON))) 603 i-- 604 dAtA[i] = 0xa 605 } 606 return len(dAtA) - i, nil 607 } 608 609 func (m *CommitHydratedManifestsResponse) Marshal() (dAtA []byte, err error) { 610 size := m.Size() 611 dAtA = make([]byte, size) 612 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 613 if err != nil { 614 return nil, err 615 } 616 return dAtA[:n], nil 617 } 618 619 func (m *CommitHydratedManifestsResponse) MarshalTo(dAtA []byte) (int, error) { 620 size := m.Size() 621 return m.MarshalToSizedBuffer(dAtA[:size]) 622 } 623 624 func (m *CommitHydratedManifestsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { 625 i := len(dAtA) 626 _ = i 627 var l int 628 _ = l 629 if m.XXX_unrecognized != nil { 630 i -= len(m.XXX_unrecognized) 631 copy(dAtA[i:], m.XXX_unrecognized) 632 } 633 if len(m.HydratedSha) > 0 { 634 i -= len(m.HydratedSha) 635 copy(dAtA[i:], m.HydratedSha) 636 i = encodeVarintCommit(dAtA, i, uint64(len(m.HydratedSha))) 637 i-- 638 dAtA[i] = 0xa 639 } 640 return len(dAtA) - i, nil 641 } 642 643 func encodeVarintCommit(dAtA []byte, offset int, v uint64) int { 644 offset -= sovCommit(v) 645 base := offset 646 for v >= 1<<7 { 647 dAtA[offset] = uint8(v&0x7f | 0x80) 648 v >>= 7 649 offset++ 650 } 651 dAtA[offset] = uint8(v) 652 return base 653 } 654 func (m *CommitHydratedManifestsRequest) Size() (n int) { 655 if m == nil { 656 return 0 657 } 658 var l int 659 _ = l 660 if m.Repo != nil { 661 l = m.Repo.Size() 662 n += 1 + l + sovCommit(uint64(l)) 663 } 664 l = len(m.SyncBranch) 665 if l > 0 { 666 n += 1 + l + sovCommit(uint64(l)) 667 } 668 l = len(m.TargetBranch) 669 if l > 0 { 670 n += 1 + l + sovCommit(uint64(l)) 671 } 672 l = len(m.DrySha) 673 if l > 0 { 674 n += 1 + l + sovCommit(uint64(l)) 675 } 676 l = len(m.CommitMessage) 677 if l > 0 { 678 n += 1 + l + sovCommit(uint64(l)) 679 } 680 if len(m.Paths) > 0 { 681 for _, e := range m.Paths { 682 l = e.Size() 683 n += 1 + l + sovCommit(uint64(l)) 684 } 685 } 686 if m.DryCommitMetadata != nil { 687 l = m.DryCommitMetadata.Size() 688 n += 1 + l + sovCommit(uint64(l)) 689 } 690 if m.XXX_unrecognized != nil { 691 n += len(m.XXX_unrecognized) 692 } 693 return n 694 } 695 696 func (m *PathDetails) Size() (n int) { 697 if m == nil { 698 return 0 699 } 700 var l int 701 _ = l 702 l = len(m.Path) 703 if l > 0 { 704 n += 1 + l + sovCommit(uint64(l)) 705 } 706 if len(m.Manifests) > 0 { 707 for _, e := range m.Manifests { 708 l = e.Size() 709 n += 1 + l + sovCommit(uint64(l)) 710 } 711 } 712 if len(m.Commands) > 0 { 713 for _, s := range m.Commands { 714 l = len(s) 715 n += 1 + l + sovCommit(uint64(l)) 716 } 717 } 718 if m.XXX_unrecognized != nil { 719 n += len(m.XXX_unrecognized) 720 } 721 return n 722 } 723 724 func (m *HydratedManifestDetails) Size() (n int) { 725 if m == nil { 726 return 0 727 } 728 var l int 729 _ = l 730 l = len(m.ManifestJSON) 731 if l > 0 { 732 n += 1 + l + sovCommit(uint64(l)) 733 } 734 if m.XXX_unrecognized != nil { 735 n += len(m.XXX_unrecognized) 736 } 737 return n 738 } 739 740 func (m *CommitHydratedManifestsResponse) Size() (n int) { 741 if m == nil { 742 return 0 743 } 744 var l int 745 _ = l 746 l = len(m.HydratedSha) 747 if l > 0 { 748 n += 1 + l + sovCommit(uint64(l)) 749 } 750 if m.XXX_unrecognized != nil { 751 n += len(m.XXX_unrecognized) 752 } 753 return n 754 } 755 756 func sovCommit(x uint64) (n int) { 757 return (math_bits.Len64(x|1) + 6) / 7 758 } 759 func sozCommit(x uint64) (n int) { 760 return sovCommit(uint64((x << 1) ^ uint64((int64(x) >> 63)))) 761 } 762 func (m *CommitHydratedManifestsRequest) Unmarshal(dAtA []byte) error { 763 l := len(dAtA) 764 iNdEx := 0 765 for iNdEx < l { 766 preIndex := iNdEx 767 var wire uint64 768 for shift := uint(0); ; shift += 7 { 769 if shift >= 64 { 770 return ErrIntOverflowCommit 771 } 772 if iNdEx >= l { 773 return io.ErrUnexpectedEOF 774 } 775 b := dAtA[iNdEx] 776 iNdEx++ 777 wire |= uint64(b&0x7F) << shift 778 if b < 0x80 { 779 break 780 } 781 } 782 fieldNum := int32(wire >> 3) 783 wireType := int(wire & 0x7) 784 if wireType == 4 { 785 return fmt.Errorf("proto: CommitHydratedManifestsRequest: wiretype end group for non-group") 786 } 787 if fieldNum <= 0 { 788 return fmt.Errorf("proto: CommitHydratedManifestsRequest: illegal tag %d (wire type %d)", fieldNum, wire) 789 } 790 switch fieldNum { 791 case 1: 792 if wireType != 2 { 793 return fmt.Errorf("proto: wrong wireType = %d for field Repo", wireType) 794 } 795 var msglen int 796 for shift := uint(0); ; shift += 7 { 797 if shift >= 64 { 798 return ErrIntOverflowCommit 799 } 800 if iNdEx >= l { 801 return io.ErrUnexpectedEOF 802 } 803 b := dAtA[iNdEx] 804 iNdEx++ 805 msglen |= int(b&0x7F) << shift 806 if b < 0x80 { 807 break 808 } 809 } 810 if msglen < 0 { 811 return ErrInvalidLengthCommit 812 } 813 postIndex := iNdEx + msglen 814 if postIndex < 0 { 815 return ErrInvalidLengthCommit 816 } 817 if postIndex > l { 818 return io.ErrUnexpectedEOF 819 } 820 if m.Repo == nil { 821 m.Repo = &v1alpha1.Repository{} 822 } 823 if err := m.Repo.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 824 return err 825 } 826 iNdEx = postIndex 827 case 2: 828 if wireType != 2 { 829 return fmt.Errorf("proto: wrong wireType = %d for field SyncBranch", wireType) 830 } 831 var stringLen uint64 832 for shift := uint(0); ; shift += 7 { 833 if shift >= 64 { 834 return ErrIntOverflowCommit 835 } 836 if iNdEx >= l { 837 return io.ErrUnexpectedEOF 838 } 839 b := dAtA[iNdEx] 840 iNdEx++ 841 stringLen |= uint64(b&0x7F) << shift 842 if b < 0x80 { 843 break 844 } 845 } 846 intStringLen := int(stringLen) 847 if intStringLen < 0 { 848 return ErrInvalidLengthCommit 849 } 850 postIndex := iNdEx + intStringLen 851 if postIndex < 0 { 852 return ErrInvalidLengthCommit 853 } 854 if postIndex > l { 855 return io.ErrUnexpectedEOF 856 } 857 m.SyncBranch = string(dAtA[iNdEx:postIndex]) 858 iNdEx = postIndex 859 case 3: 860 if wireType != 2 { 861 return fmt.Errorf("proto: wrong wireType = %d for field TargetBranch", wireType) 862 } 863 var stringLen uint64 864 for shift := uint(0); ; shift += 7 { 865 if shift >= 64 { 866 return ErrIntOverflowCommit 867 } 868 if iNdEx >= l { 869 return io.ErrUnexpectedEOF 870 } 871 b := dAtA[iNdEx] 872 iNdEx++ 873 stringLen |= uint64(b&0x7F) << shift 874 if b < 0x80 { 875 break 876 } 877 } 878 intStringLen := int(stringLen) 879 if intStringLen < 0 { 880 return ErrInvalidLengthCommit 881 } 882 postIndex := iNdEx + intStringLen 883 if postIndex < 0 { 884 return ErrInvalidLengthCommit 885 } 886 if postIndex > l { 887 return io.ErrUnexpectedEOF 888 } 889 m.TargetBranch = string(dAtA[iNdEx:postIndex]) 890 iNdEx = postIndex 891 case 4: 892 if wireType != 2 { 893 return fmt.Errorf("proto: wrong wireType = %d for field DrySha", wireType) 894 } 895 var stringLen uint64 896 for shift := uint(0); ; shift += 7 { 897 if shift >= 64 { 898 return ErrIntOverflowCommit 899 } 900 if iNdEx >= l { 901 return io.ErrUnexpectedEOF 902 } 903 b := dAtA[iNdEx] 904 iNdEx++ 905 stringLen |= uint64(b&0x7F) << shift 906 if b < 0x80 { 907 break 908 } 909 } 910 intStringLen := int(stringLen) 911 if intStringLen < 0 { 912 return ErrInvalidLengthCommit 913 } 914 postIndex := iNdEx + intStringLen 915 if postIndex < 0 { 916 return ErrInvalidLengthCommit 917 } 918 if postIndex > l { 919 return io.ErrUnexpectedEOF 920 } 921 m.DrySha = string(dAtA[iNdEx:postIndex]) 922 iNdEx = postIndex 923 case 5: 924 if wireType != 2 { 925 return fmt.Errorf("proto: wrong wireType = %d for field CommitMessage", wireType) 926 } 927 var stringLen uint64 928 for shift := uint(0); ; shift += 7 { 929 if shift >= 64 { 930 return ErrIntOverflowCommit 931 } 932 if iNdEx >= l { 933 return io.ErrUnexpectedEOF 934 } 935 b := dAtA[iNdEx] 936 iNdEx++ 937 stringLen |= uint64(b&0x7F) << shift 938 if b < 0x80 { 939 break 940 } 941 } 942 intStringLen := int(stringLen) 943 if intStringLen < 0 { 944 return ErrInvalidLengthCommit 945 } 946 postIndex := iNdEx + intStringLen 947 if postIndex < 0 { 948 return ErrInvalidLengthCommit 949 } 950 if postIndex > l { 951 return io.ErrUnexpectedEOF 952 } 953 m.CommitMessage = string(dAtA[iNdEx:postIndex]) 954 iNdEx = postIndex 955 case 6: 956 if wireType != 2 { 957 return fmt.Errorf("proto: wrong wireType = %d for field Paths", wireType) 958 } 959 var msglen int 960 for shift := uint(0); ; shift += 7 { 961 if shift >= 64 { 962 return ErrIntOverflowCommit 963 } 964 if iNdEx >= l { 965 return io.ErrUnexpectedEOF 966 } 967 b := dAtA[iNdEx] 968 iNdEx++ 969 msglen |= int(b&0x7F) << shift 970 if b < 0x80 { 971 break 972 } 973 } 974 if msglen < 0 { 975 return ErrInvalidLengthCommit 976 } 977 postIndex := iNdEx + msglen 978 if postIndex < 0 { 979 return ErrInvalidLengthCommit 980 } 981 if postIndex > l { 982 return io.ErrUnexpectedEOF 983 } 984 m.Paths = append(m.Paths, &PathDetails{}) 985 if err := m.Paths[len(m.Paths)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 986 return err 987 } 988 iNdEx = postIndex 989 case 7: 990 if wireType != 2 { 991 return fmt.Errorf("proto: wrong wireType = %d for field DryCommitMetadata", wireType) 992 } 993 var msglen int 994 for shift := uint(0); ; shift += 7 { 995 if shift >= 64 { 996 return ErrIntOverflowCommit 997 } 998 if iNdEx >= l { 999 return io.ErrUnexpectedEOF 1000 } 1001 b := dAtA[iNdEx] 1002 iNdEx++ 1003 msglen |= int(b&0x7F) << shift 1004 if b < 0x80 { 1005 break 1006 } 1007 } 1008 if msglen < 0 { 1009 return ErrInvalidLengthCommit 1010 } 1011 postIndex := iNdEx + msglen 1012 if postIndex < 0 { 1013 return ErrInvalidLengthCommit 1014 } 1015 if postIndex > l { 1016 return io.ErrUnexpectedEOF 1017 } 1018 if m.DryCommitMetadata == nil { 1019 m.DryCommitMetadata = &v1alpha1.RevisionMetadata{} 1020 } 1021 if err := m.DryCommitMetadata.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 1022 return err 1023 } 1024 iNdEx = postIndex 1025 default: 1026 iNdEx = preIndex 1027 skippy, err := skipCommit(dAtA[iNdEx:]) 1028 if err != nil { 1029 return err 1030 } 1031 if (skippy < 0) || (iNdEx+skippy) < 0 { 1032 return ErrInvalidLengthCommit 1033 } 1034 if (iNdEx + skippy) > l { 1035 return io.ErrUnexpectedEOF 1036 } 1037 m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...) 1038 iNdEx += skippy 1039 } 1040 } 1041 1042 if iNdEx > l { 1043 return io.ErrUnexpectedEOF 1044 } 1045 return nil 1046 } 1047 func (m *PathDetails) Unmarshal(dAtA []byte) error { 1048 l := len(dAtA) 1049 iNdEx := 0 1050 for iNdEx < l { 1051 preIndex := iNdEx 1052 var wire uint64 1053 for shift := uint(0); ; shift += 7 { 1054 if shift >= 64 { 1055 return ErrIntOverflowCommit 1056 } 1057 if iNdEx >= l { 1058 return io.ErrUnexpectedEOF 1059 } 1060 b := dAtA[iNdEx] 1061 iNdEx++ 1062 wire |= uint64(b&0x7F) << shift 1063 if b < 0x80 { 1064 break 1065 } 1066 } 1067 fieldNum := int32(wire >> 3) 1068 wireType := int(wire & 0x7) 1069 if wireType == 4 { 1070 return fmt.Errorf("proto: PathDetails: wiretype end group for non-group") 1071 } 1072 if fieldNum <= 0 { 1073 return fmt.Errorf("proto: PathDetails: illegal tag %d (wire type %d)", fieldNum, wire) 1074 } 1075 switch fieldNum { 1076 case 1: 1077 if wireType != 2 { 1078 return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) 1079 } 1080 var stringLen uint64 1081 for shift := uint(0); ; shift += 7 { 1082 if shift >= 64 { 1083 return ErrIntOverflowCommit 1084 } 1085 if iNdEx >= l { 1086 return io.ErrUnexpectedEOF 1087 } 1088 b := dAtA[iNdEx] 1089 iNdEx++ 1090 stringLen |= uint64(b&0x7F) << shift 1091 if b < 0x80 { 1092 break 1093 } 1094 } 1095 intStringLen := int(stringLen) 1096 if intStringLen < 0 { 1097 return ErrInvalidLengthCommit 1098 } 1099 postIndex := iNdEx + intStringLen 1100 if postIndex < 0 { 1101 return ErrInvalidLengthCommit 1102 } 1103 if postIndex > l { 1104 return io.ErrUnexpectedEOF 1105 } 1106 m.Path = string(dAtA[iNdEx:postIndex]) 1107 iNdEx = postIndex 1108 case 2: 1109 if wireType != 2 { 1110 return fmt.Errorf("proto: wrong wireType = %d for field Manifests", wireType) 1111 } 1112 var msglen int 1113 for shift := uint(0); ; shift += 7 { 1114 if shift >= 64 { 1115 return ErrIntOverflowCommit 1116 } 1117 if iNdEx >= l { 1118 return io.ErrUnexpectedEOF 1119 } 1120 b := dAtA[iNdEx] 1121 iNdEx++ 1122 msglen |= int(b&0x7F) << shift 1123 if b < 0x80 { 1124 break 1125 } 1126 } 1127 if msglen < 0 { 1128 return ErrInvalidLengthCommit 1129 } 1130 postIndex := iNdEx + msglen 1131 if postIndex < 0 { 1132 return ErrInvalidLengthCommit 1133 } 1134 if postIndex > l { 1135 return io.ErrUnexpectedEOF 1136 } 1137 m.Manifests = append(m.Manifests, &HydratedManifestDetails{}) 1138 if err := m.Manifests[len(m.Manifests)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 1139 return err 1140 } 1141 iNdEx = postIndex 1142 case 3: 1143 if wireType != 2 { 1144 return fmt.Errorf("proto: wrong wireType = %d for field Commands", wireType) 1145 } 1146 var stringLen uint64 1147 for shift := uint(0); ; shift += 7 { 1148 if shift >= 64 { 1149 return ErrIntOverflowCommit 1150 } 1151 if iNdEx >= l { 1152 return io.ErrUnexpectedEOF 1153 } 1154 b := dAtA[iNdEx] 1155 iNdEx++ 1156 stringLen |= uint64(b&0x7F) << shift 1157 if b < 0x80 { 1158 break 1159 } 1160 } 1161 intStringLen := int(stringLen) 1162 if intStringLen < 0 { 1163 return ErrInvalidLengthCommit 1164 } 1165 postIndex := iNdEx + intStringLen 1166 if postIndex < 0 { 1167 return ErrInvalidLengthCommit 1168 } 1169 if postIndex > l { 1170 return io.ErrUnexpectedEOF 1171 } 1172 m.Commands = append(m.Commands, string(dAtA[iNdEx:postIndex])) 1173 iNdEx = postIndex 1174 default: 1175 iNdEx = preIndex 1176 skippy, err := skipCommit(dAtA[iNdEx:]) 1177 if err != nil { 1178 return err 1179 } 1180 if (skippy < 0) || (iNdEx+skippy) < 0 { 1181 return ErrInvalidLengthCommit 1182 } 1183 if (iNdEx + skippy) > l { 1184 return io.ErrUnexpectedEOF 1185 } 1186 m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...) 1187 iNdEx += skippy 1188 } 1189 } 1190 1191 if iNdEx > l { 1192 return io.ErrUnexpectedEOF 1193 } 1194 return nil 1195 } 1196 func (m *HydratedManifestDetails) Unmarshal(dAtA []byte) error { 1197 l := len(dAtA) 1198 iNdEx := 0 1199 for iNdEx < l { 1200 preIndex := iNdEx 1201 var wire uint64 1202 for shift := uint(0); ; shift += 7 { 1203 if shift >= 64 { 1204 return ErrIntOverflowCommit 1205 } 1206 if iNdEx >= l { 1207 return io.ErrUnexpectedEOF 1208 } 1209 b := dAtA[iNdEx] 1210 iNdEx++ 1211 wire |= uint64(b&0x7F) << shift 1212 if b < 0x80 { 1213 break 1214 } 1215 } 1216 fieldNum := int32(wire >> 3) 1217 wireType := int(wire & 0x7) 1218 if wireType == 4 { 1219 return fmt.Errorf("proto: HydratedManifestDetails: wiretype end group for non-group") 1220 } 1221 if fieldNum <= 0 { 1222 return fmt.Errorf("proto: HydratedManifestDetails: illegal tag %d (wire type %d)", fieldNum, wire) 1223 } 1224 switch fieldNum { 1225 case 1: 1226 if wireType != 2 { 1227 return fmt.Errorf("proto: wrong wireType = %d for field ManifestJSON", wireType) 1228 } 1229 var stringLen uint64 1230 for shift := uint(0); ; shift += 7 { 1231 if shift >= 64 { 1232 return ErrIntOverflowCommit 1233 } 1234 if iNdEx >= l { 1235 return io.ErrUnexpectedEOF 1236 } 1237 b := dAtA[iNdEx] 1238 iNdEx++ 1239 stringLen |= uint64(b&0x7F) << shift 1240 if b < 0x80 { 1241 break 1242 } 1243 } 1244 intStringLen := int(stringLen) 1245 if intStringLen < 0 { 1246 return ErrInvalidLengthCommit 1247 } 1248 postIndex := iNdEx + intStringLen 1249 if postIndex < 0 { 1250 return ErrInvalidLengthCommit 1251 } 1252 if postIndex > l { 1253 return io.ErrUnexpectedEOF 1254 } 1255 m.ManifestJSON = string(dAtA[iNdEx:postIndex]) 1256 iNdEx = postIndex 1257 default: 1258 iNdEx = preIndex 1259 skippy, err := skipCommit(dAtA[iNdEx:]) 1260 if err != nil { 1261 return err 1262 } 1263 if (skippy < 0) || (iNdEx+skippy) < 0 { 1264 return ErrInvalidLengthCommit 1265 } 1266 if (iNdEx + skippy) > l { 1267 return io.ErrUnexpectedEOF 1268 } 1269 m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...) 1270 iNdEx += skippy 1271 } 1272 } 1273 1274 if iNdEx > l { 1275 return io.ErrUnexpectedEOF 1276 } 1277 return nil 1278 } 1279 func (m *CommitHydratedManifestsResponse) Unmarshal(dAtA []byte) error { 1280 l := len(dAtA) 1281 iNdEx := 0 1282 for iNdEx < l { 1283 preIndex := iNdEx 1284 var wire uint64 1285 for shift := uint(0); ; shift += 7 { 1286 if shift >= 64 { 1287 return ErrIntOverflowCommit 1288 } 1289 if iNdEx >= l { 1290 return io.ErrUnexpectedEOF 1291 } 1292 b := dAtA[iNdEx] 1293 iNdEx++ 1294 wire |= uint64(b&0x7F) << shift 1295 if b < 0x80 { 1296 break 1297 } 1298 } 1299 fieldNum := int32(wire >> 3) 1300 wireType := int(wire & 0x7) 1301 if wireType == 4 { 1302 return fmt.Errorf("proto: CommitHydratedManifestsResponse: wiretype end group for non-group") 1303 } 1304 if fieldNum <= 0 { 1305 return fmt.Errorf("proto: CommitHydratedManifestsResponse: illegal tag %d (wire type %d)", fieldNum, wire) 1306 } 1307 switch fieldNum { 1308 case 1: 1309 if wireType != 2 { 1310 return fmt.Errorf("proto: wrong wireType = %d for field HydratedSha", wireType) 1311 } 1312 var stringLen uint64 1313 for shift := uint(0); ; shift += 7 { 1314 if shift >= 64 { 1315 return ErrIntOverflowCommit 1316 } 1317 if iNdEx >= l { 1318 return io.ErrUnexpectedEOF 1319 } 1320 b := dAtA[iNdEx] 1321 iNdEx++ 1322 stringLen |= uint64(b&0x7F) << shift 1323 if b < 0x80 { 1324 break 1325 } 1326 } 1327 intStringLen := int(stringLen) 1328 if intStringLen < 0 { 1329 return ErrInvalidLengthCommit 1330 } 1331 postIndex := iNdEx + intStringLen 1332 if postIndex < 0 { 1333 return ErrInvalidLengthCommit 1334 } 1335 if postIndex > l { 1336 return io.ErrUnexpectedEOF 1337 } 1338 m.HydratedSha = string(dAtA[iNdEx:postIndex]) 1339 iNdEx = postIndex 1340 default: 1341 iNdEx = preIndex 1342 skippy, err := skipCommit(dAtA[iNdEx:]) 1343 if err != nil { 1344 return err 1345 } 1346 if (skippy < 0) || (iNdEx+skippy) < 0 { 1347 return ErrInvalidLengthCommit 1348 } 1349 if (iNdEx + skippy) > l { 1350 return io.ErrUnexpectedEOF 1351 } 1352 m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...) 1353 iNdEx += skippy 1354 } 1355 } 1356 1357 if iNdEx > l { 1358 return io.ErrUnexpectedEOF 1359 } 1360 return nil 1361 } 1362 func skipCommit(dAtA []byte) (n int, err error) { 1363 l := len(dAtA) 1364 iNdEx := 0 1365 depth := 0 1366 for iNdEx < l { 1367 var wire uint64 1368 for shift := uint(0); ; shift += 7 { 1369 if shift >= 64 { 1370 return 0, ErrIntOverflowCommit 1371 } 1372 if iNdEx >= l { 1373 return 0, io.ErrUnexpectedEOF 1374 } 1375 b := dAtA[iNdEx] 1376 iNdEx++ 1377 wire |= (uint64(b) & 0x7F) << shift 1378 if b < 0x80 { 1379 break 1380 } 1381 } 1382 wireType := int(wire & 0x7) 1383 switch wireType { 1384 case 0: 1385 for shift := uint(0); ; shift += 7 { 1386 if shift >= 64 { 1387 return 0, ErrIntOverflowCommit 1388 } 1389 if iNdEx >= l { 1390 return 0, io.ErrUnexpectedEOF 1391 } 1392 iNdEx++ 1393 if dAtA[iNdEx-1] < 0x80 { 1394 break 1395 } 1396 } 1397 case 1: 1398 iNdEx += 8 1399 case 2: 1400 var length int 1401 for shift := uint(0); ; shift += 7 { 1402 if shift >= 64 { 1403 return 0, ErrIntOverflowCommit 1404 } 1405 if iNdEx >= l { 1406 return 0, io.ErrUnexpectedEOF 1407 } 1408 b := dAtA[iNdEx] 1409 iNdEx++ 1410 length |= (int(b) & 0x7F) << shift 1411 if b < 0x80 { 1412 break 1413 } 1414 } 1415 if length < 0 { 1416 return 0, ErrInvalidLengthCommit 1417 } 1418 iNdEx += length 1419 case 3: 1420 depth++ 1421 case 4: 1422 if depth == 0 { 1423 return 0, ErrUnexpectedEndOfGroupCommit 1424 } 1425 depth-- 1426 case 5: 1427 iNdEx += 4 1428 default: 1429 return 0, fmt.Errorf("proto: illegal wireType %d", wireType) 1430 } 1431 if iNdEx < 0 { 1432 return 0, ErrInvalidLengthCommit 1433 } 1434 if depth == 0 { 1435 return iNdEx, nil 1436 } 1437 } 1438 return 0, io.ErrUnexpectedEOF 1439 } 1440 1441 var ( 1442 ErrInvalidLengthCommit = fmt.Errorf("proto: negative length found during unmarshaling") 1443 ErrIntOverflowCommit = fmt.Errorf("proto: integer overflow") 1444 ErrUnexpectedEndOfGroupCommit = fmt.Errorf("proto: unexpected end of group") 1445 )