class TStringRef: public TRefCnt


TString

Basic string class.

Cannot be stored in a TCollection... use TObjString instead.


Function Members (Methods)

public:
TStringRef()
TStringRef(const TStringRef&)
~TStringRef()
voidTRefCnt::AddReference()
TStringRef&operator=(const TStringRef&)
UInt_tTRefCnt::References() const
UInt_tTRefCnt::RemoveReference()
voidTRefCnt::SetRefCount(UInt_t r)
private:
Ssiz_tCapacity() const
char*Data() const
Ssiz_tFirst(char c) const
Ssiz_tFirst(const char* s) const
static TStringRef*GetRep(Ssiz_t capac, Ssiz_t nchar)
UInt_tHash() const
UInt_tHashFoldCase() const
Ssiz_tLast(char) const
Ssiz_tLength() const
char&operator[](Ssiz_t i)
charoperator[](Ssiz_t i) const
voidUnLink()

Data Members

public:
enum TRefCnt::EReferenceFlag { kStaticInit
};
protected:
UInt_tTRefCnt::fRefs(1 less than) number of references
private:
Ssiz_tfCapacityMax string length (excluding null)
Ssiz_tfNcharsString length (excluding null)

Class Charts

Inheritance Inherited Members Includes Libraries
Class Charts

Function documentation

TStringRef * GetRep(Ssiz_t capac, Ssiz_t nchar)
 Static member function returning an empty string representation of
 size capacity and containing nchar characters.
Ssiz_t First(char c)
 Find first occurrence of a character c.
Ssiz_t First(const char *cs)
 Find first occurrence of a character in cs.
UInt_t Hash()
 Return a case-sensitive hash value.
UInt_t HashFoldCase()
 Return a case-insensitive hash value.
Ssiz_t Last(char ) const
 Find last occurrence of a character c.
void UnLink()
{ if (RemoveReference() == 0) delete [] (char*)this; }
Ssiz_t Length()
{ return fNchars; }
Ssiz_t Capacity()
{ return fCapacity; }
char * Data()
{ return (char*)(this+1); }
char & operator[](Ssiz_t i)
{ return ((char*)(this+1))[i]; }
char operator[](Ssiz_t i)
{ return ((char*)(this+1))[i]; }
TSubString & operator=(const TStringRef& )

Author: Fons Rademakers 04/08/95
Last change: root/base:$Id: TString.h 23536 2008-04-24 19:39:05Z rdm $
Last generated: 2008-06-25 08:53
Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *

This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.