/
cells-chat.validator.pb.go
140 lines (136 loc) · 4.28 KB
/
cells-chat.validator.pb.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
// Code generated by protoc-gen-gogo. DO NOT EDIT.
// source: cells-chat.proto
package chat
import (
fmt "fmt"
math "math"
proto "google.golang.org/protobuf/proto"
_ "github.com/pydio/cells/v4/common/proto/activity"
github_com_mwitkow_go_proto_validators "github.com/mwitkow/go-proto-validators"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
func (this *ChatRoom) Validate() error {
return nil
}
func (this *ChatMessage) Validate() error {
if this.Activity != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(this.Activity); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("Activity", err)
}
}
// Validation of proto3 map<> fields is unsupported.
return nil
}
func (this *PutRoomRequest) Validate() error {
if this.Room != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(this.Room); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("Room", err)
}
}
return nil
}
func (this *PutRoomResponse) Validate() error {
if this.Room != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(this.Room); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("Room", err)
}
}
return nil
}
func (this *PostMessageRequest) Validate() error {
for _, item := range this.Messages {
if item != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("Messages", err)
}
}
}
// Validation of proto3 map<> fields is unsupported.
return nil
}
func (this *PostMessageResponse) Validate() error {
for _, item := range this.Messages {
if item != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("Messages", err)
}
}
}
return nil
}
func (this *DeleteMessageRequest) Validate() error {
for _, item := range this.Messages {
if item != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("Messages", err)
}
}
}
// Validation of proto3 map<> fields is unsupported.
return nil
}
func (this *DeleteMessageResponse) Validate() error {
return nil
}
func (this *ListMessagesRequest) Validate() error {
return nil
}
func (this *ListMessagesResponse) Validate() error {
if this.Message != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(this.Message); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("Message", err)
}
}
return nil
}
func (this *ListRoomsRequest) Validate() error {
return nil
}
func (this *ListRoomsResponse) Validate() error {
if this.Room != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(this.Room); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("Room", err)
}
}
return nil
}
func (this *DeleteRoomRequest) Validate() error {
if this.Room != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(this.Room); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("Room", err)
}
}
return nil
}
func (this *DeleteRoomResponse) Validate() error {
return nil
}
func (this *ChatEvent) Validate() error {
if this.Message != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(this.Message); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("Message", err)
}
}
if this.Room != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(this.Room); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("Room", err)
}
}
return nil
}
func (this *WebSocketMessage) Validate() error {
if this.Room != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(this.Room); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("Room", err)
}
}
if this.Message != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(this.Message); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("Message", err)
}
}
return nil
}