8#ifndef INCLUDED_BALST_STACKTRACEFRAME
9#define INCLUDED_BALST_STACKTRACEFRAME
185#include <balscm_version.h>
197#include <bsl_cstddef.h>
198#include <bsl_iosfwd.h>
199#include <bsl_string.h>
201#ifndef BDE_DONT_ALLOW_TRANSITIVE_INCLUDES
204#include <bsl_algorithm.h>
226 const void *d_address;
245 bsl::size_t d_offsetFromSymbol;
439 bsl::ostream&
print(bsl::ostream& stream,
441 int spacesPerLevel = 4)
const;
489, d_libraryFileName(basicAllocator)
491, d_mangledSymbolName(basicAllocator)
492, d_offsetFromSymbol((
bsl::size_t)-1)
493, d_sourceFileName(basicAllocator)
494, d_symbolName(basicAllocator)
503 bsl::size_t offsetFromSymbol,
508, d_libraryFileName(libraryFileName.begin(),
509 libraryFileName.end(),
511, d_lineNumber(lineNumber)
512, d_mangledSymbolName(mangledSymbolName.begin(),
513 mangledSymbolName.end(),
515, d_offsetFromSymbol(offsetFromSymbol)
516, d_sourceFileName(sourceFileName.begin(),
517 sourceFileName.end(),
519, d_symbolName(symbolName.begin(), symbolName.end(), basicAllocator)
531: d_address(original.d_address)
532, d_libraryFileName(original.d_libraryFileName, basicAllocator)
533, d_lineNumber(original.d_lineNumber)
534, d_mangledSymbolName(original.d_mangledSymbolName, basicAllocator)
535, d_offsetFromSymbol(original.d_offsetFromSymbol)
536, d_sourceFileName(original.d_sourceFileName, basicAllocator)
537, d_symbolName(original.d_symbolName, basicAllocator)
579 d_lineNumber = value;
593 d_offsetFromSymbol = value;
622 return d_libraryFileName;
634 return d_offsetFromSymbol;
640 return d_mangledSymbolName;
646 return d_sourceFileName;
659 return 0 != d_address;
665 return !d_libraryFileName.
empty();
671 return d_lineNumber > 0;
677 return !d_mangledSymbolName.
empty();
683 return (bsl::size_t)-1 != d_offsetFromSymbol;
689 return !d_sourceFileName.
empty();
695 return !d_symbolName.
empty();
712 return lhs.address() == rhs.address()
713 && lhs.libraryFileName() == rhs.libraryFileName()
714 && lhs.lineNumber() == rhs.lineNumber()
715 && lhs.mangledSymbolName() == rhs.mangledSymbolName()
716 && lhs.offsetFromSymbol() == rhs.offsetFromSymbol()
717 && lhs.sourceFileName() == rhs.sourceFileName()
718 && lhs.symbolName() == rhs.symbolName();
724 return lhs.address() != rhs.address()
725 || lhs.libraryFileName() != rhs.libraryFileName()
726 || lhs.lineNumber() != rhs.lineNumber()
727 || lhs.mangledSymbolName() != rhs.mangledSymbolName()
728 || lhs.offsetFromSymbol() != rhs.offsetFromSymbol()
729 || lhs.sourceFileName() != rhs.sourceFileName()
730 || lhs.symbolName() != rhs.symbolName();
Definition balst_stacktraceframe.h:222
BSLMF_NESTED_TRAIT_DECLARATION(StackTraceFrame, bslma::UsesBslmaAllocator)
void setLineNumber(int value)
Definition balst_stacktraceframe.h:575
int lineNumber() const
Definition balst_stacktraceframe.h:626
void swap(StackTraceFrame &other)
bool isLibraryFileNameKnown() const
Definition balst_stacktraceframe.h:663
const bsl::string & mangledSymbolName() const
Definition balst_stacktraceframe.h:638
void setOffsetFromSymbol(bsl::size_t value)
Definition balst_stacktraceframe.h:591
bool isAddressKnown() const
Definition balst_stacktraceframe.h:657
bool isSourceFileNameKnown() const
Definition balst_stacktraceframe.h:687
void setAddress(const void *value)
Definition balst_stacktraceframe.h:561
const bsl::string & libraryFileName() const
Definition balst_stacktraceframe.h:620
StackTraceFrame & operator=(const StackTraceFrame &rhs)
Definition balst_stacktraceframe.h:549
bsl::ostream & print(bsl::ostream &stream, int level=0, int spacesPerLevel=4) const
const bsl::string & symbolName() const
Definition balst_stacktraceframe.h:650
void setSymbolName(const bsl::string_view &value)
Definition balst_stacktraceframe.h:605
void setMangledSymbolName(const bsl::string_view &value)
Definition balst_stacktraceframe.h:583
StackTraceFrame(bslma::Allocator *basicAllocator=0)
Definition balst_stacktraceframe.h:487
~StackTraceFrame()
Destroy this object.
Definition balst_stacktraceframe.h:542
const bsl::string & sourceFileName() const
Definition balst_stacktraceframe.h:644
bslma::Allocator * allocator() const
Definition balst_stacktraceframe.h:701
bool isMangledSymbolNameKnown() const
Definition balst_stacktraceframe.h:675
bsl::size_t offsetFromSymbol() const
Definition balst_stacktraceframe.h:632
bool isSymbolNameKnown() const
Definition balst_stacktraceframe.h:693
bool isLineNumberKnown() const
Definition balst_stacktraceframe.h:669
void setLibraryFileName(const bsl::string_view &value)
Definition balst_stacktraceframe.h:567
bool isOffsetFromSymbolKnown() const
Definition balst_stacktraceframe.h:681
void setSourceFileName(const bsl::string_view &value)
Definition balst_stacktraceframe.h:597
const void * address() const
Definition balst_stacktraceframe.h:614
Definition bslstl_stringview.h:441
BSLS_KEYWORD_CONSTEXPR const_iterator end() const BSLS_KEYWORD_NOEXCEPT
Return the past-the-end iterator for this view.
Definition bslstl_stringview.h:1620
BSLS_KEYWORD_CONSTEXPR const_pointer data() const BSLS_KEYWORD_NOEXCEPT
Definition bslstl_stringview.h:1760
BSLS_KEYWORD_CONSTEXPR const_iterator begin() const BSLS_KEYWORD_NOEXCEPT
Definition bslstl_stringview.h:1602
Definition bslstl_string.h:1281
basic_string & assign(const basic_string &replacement)
Definition bslstl_string.h:5716
allocator_type get_allocator() const BSLS_KEYWORD_NOEXCEPT
Return the allocator used by this string to supply memory.
Definition bslstl_string.h:6723
bool empty() const BSLS_KEYWORD_NOEXCEPT
Return true if this string has length 0, and false otherwise.
Definition bslstl_string.h:6631
CHAR_TYPE * data() BSLS_KEYWORD_NOEXCEPT
Definition bslstl_string.h:6477
Definition bslma_allocator.h:457
#define BSLS_ASSERT(X)
Definition bsls_assert.h:1804
#define BSLS_IDENT(str)
Definition bsls_ident.h:195
Definition balst_objectfileformat.h:161
bsl::ostream & operator<<(bsl::ostream &stream, const StackTrace &object)
bool operator==(const StackTrace &lhs, const StackTrace &rhs)
bool operator!=(const StackTrace &lhs, const StackTrace &rhs)
Definition bdlb_printmethods.h:283
Definition bslma_usesbslmaallocator.h:343