class TStringRef: public TRefCnt


Basic string class.

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

Function Members (Methods)

TStringRef(const TStringRef&)
TStringRef&operator=(const TStringRef&)
UInt_tTRefCnt::References() const
voidTRefCnt::SetRefCount(UInt_t r)
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

Data Members

enum TRefCnt::EReferenceFlag { kStaticInit
UInt_tTRefCnt::fRefs(1 less than) number of references
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 24963 2008-07-28 13:49:23Z rdm $
Last generated: 2008-08-06 08:07
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.