Ejemplo n.º 1
0
        protected void ReadRegularProperty(string curLine)
        {
            Match  m   = PBXRegex.KeyValue.Match(curLine.Trim());
            string key = m.Groups[1].Value.Trim();

            m_Properties[key] = PBXStream.UnquoteString(m.Groups[2].Value.Trim());
        }
Ejemplo n.º 2
0
        protected override void ReadFromSectionImpl(string curLine, TextReader sr)
        {
            Match m = PBXRegex.AnyKeyValue.Match(curLine.Trim());

            text = m.Groups[2].Value;

            m    = PBXRegex.FileRef.Match(curLine);
            name = path = PBXStream.UnquoteString(m.Groups[2].Value.Trim());
            if (PBXRegex.FileRefName.IsMatch(curLine))
            {
                name = PBXStream.UnquoteString(PBXRegex.FileRefName.Match(curLine).Groups[1].Value);
            }
        }
Ejemplo n.º 3
0
        public void Read(string curLine, TextReader sr)
        {
            val.Clear();

            if (PBXRegex.ListHeader.IsMatch(curLine))
            {
                Match m = PBXRegex.ListHeader.Match(curLine);
                name = PBXStream.UnquoteString(m.Groups[1].Value);
                PBXStream.ReadLinesUntilConditionIsMet(sr, val, s => ExtractValue(s), s => s.Trim() == ");");
            }
            else
            {
                Match m = PBXRegex.KeyValue.Match(curLine);
                name = PBXStream.UnquoteString(m.Groups[1].Value);
                AddValue(PBXStream.UnquoteString(m.Groups[2].Value));
            }
        }
Ejemplo n.º 4
0
 public static string ExtractValue(string src)
 {
     return(PBXStream.UnquoteString(src.Trim().TrimEnd(',')));
 }