client/operations.go
func (op *operation) Wait() error {
	// Check if not done already
	if op.StatusCode.IsFinal() {
		if op.Err != "" {
			return fmt.Errorf(op.Err)
		}

		return nil
	}

	// Make sure we have a listener setup
	err := op.setupListener()
	if err != nil {
		return err
	}

	<-op.chActive

	// We're done, parse the result
	if op.Err != "" {
		return fmt.Errorf(op.Err)
	}

	return nil
}
func (op *operation) Wait() error {
	// Check if not done already
	if op.StatusCode.IsFinal() {
		if op.Err != "" {
			return fmt.Errorf(op.Err)
		}

		return nil
	}

	// Make sure we have a listener setup
	err := op.setupListener()
	if err != nil {
		return err
	}

	<-op.chActive

	// We're done, parse the result
	if op.Err != "" {
		return fmt.Errorf(op.Err)
	}

	return nil
}
func ( op * operation ) Wait ( ) error { // Check if not done already if op . StatusCode . IsFinal ( ) { if op . Err != " " { return fmt . Errorf ( op . Err ) } return nil } // Make sure we have a listener setup err := op . setupListener ( ) if err != nil { return err } <- op . chActive // We're done, parse the result if op . Err != " " { return fmt . Errorf ( op . Err ) } return nil }
// Wait lets you wait until the operation reaches a final state
Wait lets you wait until the operation reaches a final state