JX Application Framework
Loading...
Searching...
No Matches
Public Member Functions | Protected Member Functions | Friends | List of all members
JStringMatch Class Reference

#include <JStringMatch.h>

Public Member Functions

 JStringMatch (const JString &target)
 
 JStringMatch (const JStringMatch &source)
 
 ~JStringMatch ()
 
bool IsEmpty () const
 
JSize GetCharacterCount () const
 
JSize GetByteCount () const
 
JSize GetSubstringCount () const
 
JString GetString () const
 
JString GetSubstring (const JIndex submatchIndex) const
 
JString GetSubstring (const JUtf8Byte *name) const
 
JString GetSubstring (const JString &name) const
 
JCharacterRange GetCharacterRange (const JIndex submatchIndex=0) const
 
JUtf8ByteRange GetUtf8ByteRange (const JIndex submatchIndex=0) const
 

Protected Member Functions

 JStringMatch (const JString &target, const JUtf8ByteRange &byteRange, const JRegex *regex=nullptr, JArray< JUtf8ByteRange > *list=nullptr)
 
void SetFirstCharacterIndex (const JIndex index)
 
void SetLastCharacterIndex (const JIndex index)
 
void SetCharacterRange (const JCharacterRange &range)
 
 JStringMatch (const JString &target, JStringMatch &dyingSource)
 
JStringMatchoperator= (const JStringMatch &source)
 

Friends

class JStringIterator
 
class JRegex
 

Detailed Description

Stores information about a successful match by a JStringIterator.

Constructor & Destructor Documentation

◆ JStringMatch() [1/4]

JStringMatch::JStringMatch ( const JString target)

If a list of submatches is provided, we take ownership of the list.

Privileged creators may also call one of Set(First|Last)CharacterIndex or SetCharacterRange.

◆ JStringMatch() [2/4]

JStringMatch::JStringMatch ( const JStringMatch source)

◆ ~JStringMatch()

JStringMatch::~JStringMatch ( )

◆ JStringMatch() [3/4]

JStringMatch::JStringMatch ( const JString target,
const JUtf8ByteRange byteRange,
const JRegex regex = nullptr,
JArray< JUtf8ByteRange > *  list = nullptr 
)
protected

◆ JStringMatch() [4/4]

JStringMatch::JStringMatch ( const JString target,
JStringMatch dyingSource 
)
protected

Member Function Documentation

◆ GetByteCount()

JSize JStringMatch::GetByteCount ( ) const
inline

◆ GetCharacterCount()

JSize JStringMatch::GetCharacterCount ( ) const

◆ GetCharacterRange()

JCharacterRange JStringMatch::GetCharacterRange ( const JIndex  submatchIndex = 0) const

◆ GetString()

JString JStringMatch::GetString ( ) const
inline

◆ GetSubstring() [1/3]

JString JStringMatch::GetSubstring ( const JIndex  submatchIndex) const

◆ GetSubstring() [2/3]

JString JStringMatch::GetSubstring ( const JString name) const
inline

◆ GetSubstring() [3/3]

JString JStringMatch::GetSubstring ( const JUtf8Byte name) const

◆ GetSubstringCount()

JSize JStringMatch::GetSubstringCount ( ) const
inline

◆ GetUtf8ByteRange()

JUtf8ByteRange JStringMatch::GetUtf8ByteRange ( const JIndex  submatchIndex = 0) const
inline

◆ IsEmpty()

bool JStringMatch::IsEmpty ( ) const
inline

◆ operator=()

JStringMatch & JStringMatch::operator= ( const JStringMatch source)
protected

◆ SetCharacterRange()

void JStringMatch::SetCharacterRange ( const JCharacterRange range)
protected

◆ SetFirstCharacterIndex()

void JStringMatch::SetFirstCharacterIndex ( const JIndex  index)
protected

◆ SetLastCharacterIndex()

void JStringMatch::SetLastCharacterIndex ( const JIndex  index)
protected

Friends And Related Symbol Documentation

◆ JRegex

friend class JRegex
friend

◆ JStringIterator

friend class JStringIterator
friend

The documentation for this class was generated from the following files: