|
V8 Project
|
Collaboration diagram for v8::internal::CompiledReplacement:Classes | |
| struct | ReplacementPart |
Public Member Functions | |
| CompiledReplacement (Zone *zone) | |
| bool | Compile (Handle< String > replacement, int capture_count, int subject_length) |
| void | Apply (ReplacementStringBuilder *builder, int match_from, int match_to, int32_t *match) |
| int | parts () |
| Zone * | zone () const |
Private Types | |
| enum | PartType { SUBJECT_PREFIX = 1 , SUBJECT_SUFFIX , SUBJECT_CAPTURE , REPLACEMENT_SUBSTRING , REPLACEMENT_STRING , NUMBER_OF_PART_TYPES } |
Private Member Functions | |
| template<typename Char > | |
| bool | ParseReplacementPattern (ZoneList< ReplacementPart > *parts, Vector< Char > characters, int capture_count, int subject_length, Zone *zone) |
Private Attributes | |
| ZoneList< ReplacementPart > | parts_ |
| ZoneList< Handle< String > > | replacement_substrings_ |
| Zone * | zone_ |
Definition at line 18 of file runtime-regexp.cc.
|
private |
| Enumerator | |
|---|---|
| SUBJECT_PREFIX | |
| SUBJECT_SUFFIX | |
| SUBJECT_CAPTURE | |
| REPLACEMENT_SUBSTRING | |
| REPLACEMENT_STRING | |
| NUMBER_OF_PART_TYPES | |
Definition at line 37 of file runtime-regexp.cc.
|
inlineexplicit |
Definition at line 20 of file runtime-regexp.cc.
| void v8::internal::CompiledReplacement::Apply | ( | ReplacementStringBuilder * | builder, |
| int | match_from, | ||
| int | match_to, | ||
| int32_t * | match | ||
| ) |
Definition at line 246 of file runtime-regexp.cc.
References v8::internal::ReplacementStringBuilder::AddString(), v8::internal::ReplacementStringBuilder::AddSubjectSlice(), v8::internal::CompiledReplacement::ReplacementPart::data, DCHECK_LT, parts_, REPLACEMENT_STRING, REPLACEMENT_SUBSTRING, replacement_substrings_, SUBJECT_CAPTURE, SUBJECT_PREFIX, SUBJECT_SUFFIX, v8::internal::CompiledReplacement::ReplacementPart::tag, to(), and UNREACHABLE.
Referenced by v8::internal::StringReplaceGlobalRegExpWithString().
Here is the call graph for this function:
Here is the caller graph for this function:| bool v8::internal::CompiledReplacement::Compile | ( | Handle< String > | replacement, |
| int | capture_count, | ||
| int | subject_length | ||
| ) |
Definition at line 205 of file runtime-regexp.cc.
References DCHECK, v8::internal::Isolate::factory(), v8::internal::String::FlatContent::IsFlat(), v8::internal::String::FlatContent::IsOneByte(), v8::internal::String::FlatContent::IsTwoByte(), ParseReplacementPattern(), parts_, REPLACEMENT_STRING, REPLACEMENT_SUBSTRING, replacement_substrings_, to(), v8::internal::String::FlatContent::ToOneByteVector(), v8::internal::String::FlatContent::ToUC16Vector(), and zone().
Referenced by v8::internal::StringReplaceGlobalRegExpWithString().
Here is the call graph for this function:
Here is the caller graph for this function:
|
inlineprivate |
Definition at line 92 of file runtime-regexp.cc.
References DCHECK, v8::internal::Vector< T >::length(), parts(), v8::internal::CompiledReplacement::ReplacementPart::ReplacementSubString(), v8::internal::CompiledReplacement::ReplacementPart::SubjectCapture(), v8::internal::CompiledReplacement::ReplacementPart::SubjectMatch(), v8::internal::CompiledReplacement::ReplacementPart::SubjectPrefix(), v8::internal::CompiledReplacement::ReplacementPart::SubjectSuffix(), and zone().
Referenced by Compile().
Here is the call graph for this function:
Here is the caller graph for this function:
|
inline |
Definition at line 32 of file runtime-regexp.cc.
References parts_.
Referenced by ParseReplacementPattern(), and v8::internal::StringReplaceGlobalRegExpWithString().
Here is the caller graph for this function:
|
inline |
Definition at line 34 of file runtime-regexp.cc.
References zone_.
Referenced by Compile(), and ParseReplacementPattern().
Here is the caller graph for this function:
|
private |
Definition at line 199 of file runtime-regexp.cc.
Definition at line 200 of file runtime-regexp.cc.
|
private |
Definition at line 201 of file runtime-regexp.cc.
Referenced by zone().