github.com/cloudwan/edgelq-sdk@v1.15.4/devices/client/v1/broker/broker_msgs.pb.validate.go (about)

     1  // Code generated by protoc-gen-goten-validate
     2  // File: edgelq/devices/proto/v1/broker_msgs.proto
     3  // DO NOT EDIT!!!
     4  
     5  package broker
     6  
     7  import (
     8  	"bytes"
     9  	"errors"
    10  	"fmt"
    11  	"net"
    12  	"net/url"
    13  	"regexp"
    14  	"strings"
    15  	"time"
    16  	"unicode/utf8"
    17  
    18  	gotenvalidate "github.com/cloudwan/goten-sdk/runtime/validate"
    19  )
    20  
    21  // proto imports
    22  import ()
    23  
    24  var (
    25  	_ = bytes.Equal
    26  	_ = errors.New
    27  	_ = fmt.Errorf
    28  	_ = net.ParseIP
    29  	_ = regexp.Match
    30  	_ = strings.Split
    31  	_ = time.Now
    32  	_ = utf8.RuneCountInString
    33  	_ = url.Parse
    34  	_ = gotenvalidate.NewValidationError
    35  )
    36  
    37  // make sure we're using proto imports
    38  var ()
    39  
    40  func (obj *SSHService) GotenValidate() error {
    41  	if obj == nil {
    42  		return nil
    43  	}
    44  	if cvobj, ok := interface{}(obj).(gotenvalidate.CustomValidator); ok {
    45  		return cvobj.GotenCustomValidate()
    46  	}
    47  	return nil
    48  }
    49  func (obj *SSHService_Hello) GotenValidate() error {
    50  	if obj == nil {
    51  		return nil
    52  	}
    53  	if cvobj, ok := interface{}(obj).(gotenvalidate.CustomValidator); ok {
    54  		return cvobj.GotenCustomValidate()
    55  	}
    56  	return nil
    57  }
    58  func (obj *SSHService_TerminalSize) GotenValidate() error {
    59  	if obj == nil {
    60  		return nil
    61  	}
    62  	if cvobj, ok := interface{}(obj).(gotenvalidate.CustomValidator); ok {
    63  		return cvobj.GotenCustomValidate()
    64  	}
    65  	return nil
    66  }
    67  func (obj *SSHService_ClientOut) GotenValidate() error {
    68  	if obj == nil {
    69  		return nil
    70  	}
    71  	switch opt := obj.Msg.(type) {
    72  	case *SSHService_ClientOut_Data:
    73  	case *SSHService_ClientOut_SshHello:
    74  		if subobj, ok := interface{}(opt.SshHello).(gotenvalidate.Validator); ok {
    75  			if err := subobj.GotenValidate(); err != nil {
    76  				return gotenvalidate.NewValidationError("ClientOut", "sshHello", opt.SshHello, "nested object validation failed", err)
    77  			}
    78  		}
    79  	case *SSHService_ClientOut_SshResizeTerminal:
    80  		if subobj, ok := interface{}(opt.SshResizeTerminal).(gotenvalidate.Validator); ok {
    81  			if err := subobj.GotenValidate(); err != nil {
    82  				return gotenvalidate.NewValidationError("ClientOut", "sshResizeTerminal", opt.SshResizeTerminal, "nested object validation failed", err)
    83  			}
    84  		}
    85  	default:
    86  		_ = opt
    87  	}
    88  	if cvobj, ok := interface{}(obj).(gotenvalidate.CustomValidator); ok {
    89  		return cvobj.GotenCustomValidate()
    90  	}
    91  	return nil
    92  }
    93  func (obj *SSHService_ClientIn) GotenValidate() error {
    94  	if obj == nil {
    95  		return nil
    96  	}
    97  	switch opt := obj.Msg.(type) {
    98  	case *SSHService_ClientIn_Data:
    99  	default:
   100  		_ = opt
   101  	}
   102  	if cvobj, ok := interface{}(obj).(gotenvalidate.CustomValidator); ok {
   103  		return cvobj.GotenCustomValidate()
   104  	}
   105  	return nil
   106  }
   107  func (obj *SCPService) GotenValidate() error {
   108  	if obj == nil {
   109  		return nil
   110  	}
   111  	switch opt := obj.Msg.(type) {
   112  	case *SCPService_Dir:
   113  		if subobj, ok := interface{}(opt.Dir).(gotenvalidate.Validator); ok {
   114  			if err := subobj.GotenValidate(); err != nil {
   115  				return gotenvalidate.NewValidationError("SCPService", "dir", opt.Dir, "nested object validation failed", err)
   116  			}
   117  		}
   118  	case *SCPService_File:
   119  		if subobj, ok := interface{}(opt.File).(gotenvalidate.Validator); ok {
   120  			if err := subobj.GotenValidate(); err != nil {
   121  				return gotenvalidate.NewValidationError("SCPService", "file", opt.File, "nested object validation failed", err)
   122  			}
   123  		}
   124  	case *SCPService_Eot:
   125  	case *SCPService_Config:
   126  		if subobj, ok := interface{}(opt.Config).(gotenvalidate.Validator); ok {
   127  			if err := subobj.GotenValidate(); err != nil {
   128  				return gotenvalidate.NewValidationError("SCPService", "config", opt.Config, "nested object validation failed", err)
   129  			}
   130  		}
   131  	default:
   132  		_ = opt
   133  	}
   134  	if cvobj, ok := interface{}(obj).(gotenvalidate.CustomValidator); ok {
   135  		return cvobj.GotenCustomValidate()
   136  	}
   137  	return nil
   138  }
   139  func (obj *SCPService_Configure) GotenValidate() error {
   140  	if obj == nil {
   141  		return nil
   142  	}
   143  	if cvobj, ok := interface{}(obj).(gotenvalidate.CustomValidator); ok {
   144  		return cvobj.GotenCustomValidate()
   145  	}
   146  	return nil
   147  }
   148  func (obj *SCPService_CreateDirectory) GotenValidate() error {
   149  	if obj == nil {
   150  		return nil
   151  	}
   152  	if cvobj, ok := interface{}(obj).(gotenvalidate.CustomValidator); ok {
   153  		return cvobj.GotenCustomValidate()
   154  	}
   155  	return nil
   156  }
   157  func (obj *SCPService_CreateFile) GotenValidate() error {
   158  	if obj == nil {
   159  		return nil
   160  	}
   161  	switch opt := obj.Msg.(type) {
   162  	case *SCPService_CreateFile_Init:
   163  		if subobj, ok := interface{}(opt.Init).(gotenvalidate.Validator); ok {
   164  			if err := subobj.GotenValidate(); err != nil {
   165  				return gotenvalidate.NewValidationError("CreateFile", "init", opt.Init, "nested object validation failed", err)
   166  			}
   167  		}
   168  	case *SCPService_CreateFile_Data:
   169  	case *SCPService_CreateFile_Eof:
   170  	default:
   171  		_ = opt
   172  	}
   173  	if cvobj, ok := interface{}(obj).(gotenvalidate.CustomValidator); ok {
   174  		return cvobj.GotenCustomValidate()
   175  	}
   176  	return nil
   177  }
   178  func (obj *SCPService_CreateFile_Initialize) GotenValidate() error {
   179  	if obj == nil {
   180  		return nil
   181  	}
   182  	if cvobj, ok := interface{}(obj).(gotenvalidate.CustomValidator); ok {
   183  		return cvobj.GotenCustomValidate()
   184  	}
   185  	return nil
   186  }
   187  func (obj *LogsService) GotenValidate() error {
   188  	if obj == nil {
   189  		return nil
   190  	}
   191  	if cvobj, ok := interface{}(obj).(gotenvalidate.CustomValidator); ok {
   192  		return cvobj.GotenCustomValidate()
   193  	}
   194  	return nil
   195  }
   196  func (obj *LogsService_ToDevice) GotenValidate() error {
   197  	if obj == nil {
   198  		return nil
   199  	}
   200  	if cvobj, ok := interface{}(obj).(gotenvalidate.CustomValidator); ok {
   201  		return cvobj.GotenCustomValidate()
   202  	}
   203  	return nil
   204  }
   205  func (obj *LogsService_ToClient) GotenValidate() error {
   206  	if obj == nil {
   207  		return nil
   208  	}
   209  	if cvobj, ok := interface{}(obj).(gotenvalidate.CustomValidator); ok {
   210  		return cvobj.GotenCustomValidate()
   211  	}
   212  	return nil
   213  }
   214  func (obj *PodManagementService) GotenValidate() error {
   215  	if obj == nil {
   216  		return nil
   217  	}
   218  	if cvobj, ok := interface{}(obj).(gotenvalidate.CustomValidator); ok {
   219  		return cvobj.GotenCustomValidate()
   220  	}
   221  	return nil
   222  }
   223  func (obj *SystemStateService) GotenValidate() error {
   224  	if obj == nil {
   225  		return nil
   226  	}
   227  	if cvobj, ok := interface{}(obj).(gotenvalidate.CustomValidator); ok {
   228  		return cvobj.GotenCustomValidate()
   229  	}
   230  	return nil
   231  }