// Validate inspects the fields of the type to determine if they are valid.
Validate inspects the fields of the type to determine if they are valid.
// Validate inspects the fields of the type to determine if they are valid .
func (s *ReceiptAction) Validate() error {
	invalidParams := request.ErrInvalidParams{Context: "ReceiptAction"}
	if s.AddHeaderAction != nil {
		if err := s.AddHeaderAction.Validate(); err != nil {
			invalidParams.AddNested("AddHeaderAction", err.(request.ErrInvalidParams))
		}
	}
	if s.BounceAction != nil {
		if err := s.BounceAction.Validate(); err != nil {
			invalidParams.AddNested("BounceAction", err.(request.ErrInvalidParams))
		}
	}
	if s.LambdaAction != nil {
		if err := s.LambdaAction.Validate(); err != nil {
			invalidParams.AddNested("LambdaAction", err.(request.ErrInvalidParams))
		}
	}
	if s.S3Action != nil {
		if err := s.S3Action.Validate(); err != nil {
			invalidParams.AddNested("S3Action", err.(request.ErrInvalidParams))
		}
	}
	if s.SNSAction != nil {
		if err := s.SNSAction.Validate(); err != nil {
			invalidParams.AddNested("SNSAction", err.(request.ErrInvalidParams))
		}
	}
	if s.StopAction != nil {
		if err := s.StopAction.Validate(); err != nil {
			invalidParams.AddNested("StopAction", err.(request.ErrInvalidParams))
		}
	}
	if s.WorkmailAction != nil {
		if err := s.WorkmailAction.Validate(); err != nil {
			invalidParams.AddNested("WorkmailAction", err.(request.ErrInvalidParams))
		}
	}
	if invalidParams.Len() > 0 {
		return invalidParams
	}
	return nil
}
func ( s * ReceiptAction ) Validate ( ) error { invalidParams := request . ErrInvalidParams { Context : " " } if s . AddHeaderAction != nil { if err := s . AddHeaderAction . Validate ( ) ; err != nil { invalidParams . AddNested ( " " , err . ( request . ErrInvalidParams ) ) } } if s . BounceAction != nil { if err := s . BounceAction . Validate ( ) ; err != nil { invalidParams . AddNested ( " " , err . ( request . ErrInvalidParams ) ) } } if s . LambdaAction != nil { if err := s . LambdaAction . Validate ( ) ; err != nil { invalidParams . AddNested ( " " , err . ( request . ErrInvalidParams ) ) } } if s . S3Action != nil { if err := s . S3Action . Validate ( ) ; err != nil { invalidParams . AddNested ( " " , err . ( request . ErrInvalidParams ) ) } } if s . SNSAction != nil { if err := s . SNSAction . Validate ( ) ; err != nil { invalidParams . AddNested ( " " , err . ( request . ErrInvalidParams ) ) } } if s . StopAction != nil { if err := s . StopAction . Validate ( ) ; err != nil { invalidParams . AddNested ( " " , err . ( request . ErrInvalidParams ) ) } } if s . WorkmailAction != nil { if err := s . WorkmailAction . Validate ( ) ; err != nil { invalidParams . AddNested ( " " , err . ( request . ErrInvalidParams ) ) } } if invalidParams . Len ( ) > 0 { return invalidParams } return nil }
Validate inspects the fields of the type to determine if they are valid.
Validate inspects the fields of the type to determine if they are valid .