Example #1
0
        public CodePatternMatch FirstMatchInResourcesSegment(MemoryAddress start, int length, string pattern)
        {
            if (start < Resources.Start ||
                start >= Resources.Start + Resources.Size)
            {
                throw new ArgumentOutOfRangeException(nameof(start));
            }
            if (length <= 0)
            {
                throw new ArgumentOutOfRangeException(nameof(length));
            }
            if (pattern == null)
            {
                throw new ArgumentNullException(nameof(pattern));
            }

            return(CodePattern.Parse(pattern).Matches(Resources.Start, ResourcesBuffer, start, length).First());
        }
Example #2
0
 public IEnumerable <CodePatternMatch> MatchesInTextSegment(string pattern)
 {
     return(CodePattern.Parse(pattern)
            .Matches(Text.Start, TextBuffer));
 }
Example #3
0
 public CodePatternMatch FirstMatchInDataSegment(string pattern)
 {
     return(CodePattern.Parse(pattern)
            .Matches(Data.Start, DataBuffer)
            .First());
 }