void nuiHTML::GetAbsoluteURL(const nglString& rBaseURL, nglString& url) { int32 colon = url.Find(':'); if (colon > 0) { // complete url link } else if (url[0] == '/') { // Site absolute int32 col = rBaseURL.Find(_T("://")); if (col > 0) { int32 end = rBaseURL.Find('/', col + 3); if (end) url = rBaseURL.Extract(0, end) + url; } } else { // Site relative int32 end = rBaseURL.FindLast(_T('/')); if (end >= 0) { url = rBaseURL.Extract(0, end + 1) + url; } else { url = rBaseURL + _T("/") + url; } } Canonize(url); }
void Dictionary::serialize(StringBuf &res) const { res.append(Canonize(entries.size())); for(physx::PxU32 i = 0; i < entries.size(); ++i) { const char *s = entries[i].s; res.appendBytes(s, 1 + (physx::PxU32)strlen(s)); } }
CqBitVector& CqBitVector::Intersect( CqBitVector& from ) { TqInt size = ( from.m_cLength < m_cLength ) ? from.m_cLength : m_cLength; SetSize( size ); TqInt numints = NumberOfInts( size ); TqInt i; for ( i = 0; i < numints; i++ ) m_aBits[ i ] = ( m_aBits[ i ] & from.m_aBits[ i ] ); Canonize(); return ( *this ); }
void SuffixTree<Symb,NSymb>::MoveSuffix(Point& p, const uchar* s) { p.n = GetNode(p.n).suf; Canonize(p, s); }