github.com/LazyboyChen7/engine@v17.12.1-ce-rc2+incompatible/builder/remotecontext/errors.go (about)

     1  package remotecontext
     2  
     3  type notFoundError string
     4  
     5  func (e notFoundError) Error() string {
     6  	return string(e)
     7  }
     8  
     9  func (notFoundError) NotFound() {}
    10  
    11  type requestError string
    12  
    13  func (e requestError) Error() string {
    14  	return string(e)
    15  }
    16  
    17  func (e requestError) InvalidParameter() {}
    18  
    19  type unauthorizedError string
    20  
    21  func (e unauthorizedError) Error() string {
    22  	return string(e)
    23  }
    24  
    25  func (unauthorizedError) Unauthorized() {}
    26  
    27  type forbiddenError string
    28  
    29  func (e forbiddenError) Error() string {
    30  	return string(e)
    31  }
    32  
    33  func (forbiddenError) Forbidden() {}
    34  
    35  type dnsError struct {
    36  	cause error
    37  }
    38  
    39  func (e dnsError) Error() string {
    40  	return e.cause.Error()
    41  }
    42  
    43  func (e dnsError) NotFound() {}
    44  
    45  func (e dnsError) Cause() error {
    46  	return e.cause
    47  }
    48  
    49  type systemError struct {
    50  	cause error
    51  }
    52  
    53  func (e systemError) Error() string {
    54  	return e.cause.Error()
    55  }
    56  
    57  func (e systemError) SystemError() {}
    58  
    59  func (e systemError) Cause() error {
    60  	return e.cause
    61  }
    62  
    63  type unknownError struct {
    64  	cause error
    65  }
    66  
    67  func (e unknownError) Error() string {
    68  	return e.cause.Error()
    69  }
    70  
    71  func (unknownError) Unknown() {}
    72  
    73  func (e unknownError) Cause() error {
    74  	return e.cause
    75  }