// Details returns e.Error(), e's stacktrace, and any additional details which have
// be registered with RegisterDetail.  User message and HTTP code are already registered.
//
// The details of each error in e's cause chain will also be printed.
340631
func Details(e error) string {
	if e == nil {
		return ""
	}
	msg := Message(e)

	detailsLock.Lock()

	var dets []string
	for label, key := range detailFields {
		v := Value(e, key)
		if v != nil {
			dets = append(dets, fmt.Sprintf("%s: %v", label, v))
		}
	}

	detailsLock.Unlock()
	if len(dets) > 0 {
		// sort so output is predictable
		sort.Strings(dets)
		msg += "\n" + strings.Join(dets, "\n")
	}

	//userMsg := UserMessage(e)
	//if userMsg != "" {
	//	msg = fmt.Sprintf("%s\n\nUser Message: %s", msg, userMsg)
	//}
	s := Stacktrace(e)
	if s != "" {
		msg += "\n\n" + s
	}

	if c := Cause(e); c != nil {
		msg += "\n\nCaused By: " + Details(c)
	}
	return msg
}
1081412
func (api *API) RailgunDetails(railgunID string) (Railgun, error) {
	uri := api.userBaseURL("") + "/railguns/" + railgunID
	res, err := api.makeRequest("GET", uri, nil)
	if err != nil {
		return Railgun{}, errors.Wrap(err, errMakeRequestError)
	}
	var r railgunResponse
	if err := json.Unmarshal(res, &r); err != nil {
		return Railgun{}, errors.Wrap(err, errUnmarshalError)
	}
	return r.Result, nil
}
612930
func (code Code) Error(details string) error {
	if !code.IsError() {
		return nil
	}
	err := &Error{
		code:    code,
		message: ErrorTable[code],
	}
	if details != "" {
		err.message = err.message + ": " + details
	}
	return err
}
884321
func (records *Records) Details(ctx context.Context, zoneID, recordID string) (record *Record, err error) {
	response, err := httpDo(ctx, records.Options, "GET", apiURL("/zones/%s/dns_records/%s", zoneID, recordID), nil)
	if err != nil {
		return
	}
	defer response.Body.Close()
	result, err := readResponse(response.Body)
	if err != nil {
		return
	}
	record = new(Record)
	err = json.Unmarshal(result.Result, &record)
	return
}
91016
func (e *Errors) Info(format string, a ...interface{}) error {
	return e.add(Info, format, a...)
}
439459
func (pr *PubrelPacket) Details() Details {
	return Details{Qos: pr.Qos, MessageID: pr.MessageID}
}
91647
func (err *Error) Error() string {
	if err.Context == nil {
		return "ERROR " + err.Message
	}
	return "ERROR " + err.Context.Description() + " " + err.Message
}
392697
func (u unstableAPI) TxDetails(txHash *chainhash.Hash) (*wtxmgr.TxDetails, error) {
	var details *wtxmgr.TxDetails
	err := walletdb.View(u.w.db, func(dbtx walletdb.ReadTx) error {
		txmgrNs := dbtx.ReadBucket(wtxmgrNamespaceKey)
		var err error
		details, err = u.w.TxStore.TxDetails(txmgrNs, txHash)
		return err
	})
	return details, err
}
1254859
func (s deviceService) DeviceDetails(devices []string) (*DeviceDetailsResponse, error) {
	request := struct {
		Devices []string `json:"devices"`
	}{
		Devices: devices,
	}
	var response DeviceDetailsResponse
	req, err := s.client.NewRequest("POST", deviceDetailsPath, request)
	if err != nil {
		return nil, err
	}
	err = s.client.Do(req, &response)
	if err != nil {
		return nil, err
	}
	return &response, nil
}
159294
func (n *TxNotifier) dispatchSpendDetails(ntfn *SpendNtfn, details *SpendDetail) error {
	// If there are no spend details to dispatch or if the notification has
	// already been dispatched, then we can skip dispatching to this client.
	if details == nil || ntfn.dispatched {
		return nil
	}

	Log.Infof("Dispatching confirmed spend notification for %v at height=%d",
		ntfn.SpendRequest, n.currentHeight)

	select {
	case ntfn.Event.Spend <- details:
		ntfn.dispatched = true
	case <-n.quit:
		return ErrTxNotifierExiting
	}

	return nil
}
311990
func (s *RecordActivityTaskHeartbeatInput) SetDetails(v string) *RecordActivityTaskHeartbeatInput {
	s.Details = &v
	return s
}
160477
func (w *WalletState) Details(ctx context.Context, accountID stellar1.AccountID) (stellar1.AccountDetails, error) {
	a, err := w.accountStateRefresh(ctx, accountID, "Details")
	if err != nil {
		return stellar1.AccountDetails{}, err
	}
	details, err := a.Details(ctx)
	if err == nil && details.AccountID != accountID {
		w.G().Log.CDebugf(ctx, "WalletState:Details account id mismatch.  returning %+v for account id %q", details, accountID)
	}
	return details, err
}
878665
func (s *Service) ResourceDetails(publicId string) (*ResourceDetails, error) {
	return s.doGetResourceDetails(publicId)
}
538335
func (e *Error) Trace(fields ...string) *Error {
	if e == nil {
		return nil
	}

	e.lock.Lock()
	defer e.lock.Unlock()

	return e.trace(fields...)
}
362654
func ValidateAccountDetails(details AccountDetails) error {
	if err := validateUser(details.User); err != nil {
		return errors.Trace(err)
	}
	// It is valid for a password to be blank, because the client
	// may use macaroons instead.
	return nil
}
861753
func (s *Status) WithDetails(details ...proto.Message) (*Status, error) {
	if s.Code() == codes.OK {
		return nil, errors.New("no error details for status with code OK")
	}
	// s.Code() != OK implies that s.Proto() != nil.
	p := s.Proto()
	for _, detail := range details {
		any, err := types.MarshalAny(detail)
		if err != nil {
			return nil, err
		}
		p.Details = append(p.Details, any)
	}
	return &Status{s: p}, nil
}
1270532
func GetOrderDetails(rw http.ResponseWriter, req *http.Request, params denco.Params) {
	// some actual stuff should happen in here
}