Beispiel #1
0
 private string GetQNameDictionaryText()
 {
     DiagnosticUtility.DebugAssert(_type == ValueHandleType.QName, "");
     return(string.Concat(PrefixHandle.GetString(PrefixHandle.GetAlphaPrefix(_length)), ":", _bufferReader.GetDictionaryString(_offset)));
 }
 string GetQNameDictionaryText()
 {
     Fx.Assert(type == ValueHandleType.QName, "");
     return(string.Concat(PrefixHandle.GetString(PrefixHandle.GetAlphaPrefix(length)), ":", bufferReader.GetDictionaryString(offset)));
 }
        private void ReadQualifiedName(PrefixHandle prefix, StringHandle localName)
        {
            int num;
            int num2;

            byte[] buffer = base.BufferReader.GetBuffer(out num, out num2);
            int    index  = 0;
            int    num4   = 0;
            int    num5   = 0;
            int    offset = num;

            if (num < num2)
            {
                index = buffer[num];
                num5  = index;
                if ((charType[index] & 1) == 0)
                {
                    num4 |= 0x80;
                }
                num4 |= index;
                num++;
                while (num < num2)
                {
                    index = buffer[num];
                    if ((charType[index] & 2) == 0)
                    {
                        break;
                    }
                    num4 |= index;
                    num++;
                }
            }
            else
            {
                num4 |= 0x80;
                index = 0;
            }
            if (index != 0x3a)
            {
                prefix.SetValue(PrefixHandleType.Empty);
                localName.SetValue(offset, num - offset);
                if (num4 >= 0x80)
                {
                    this.VerifyNCName(localName.GetString());
                }
            }
            else
            {
                int length = num - offset;
                if (((length == 1) && (num5 >= 0x61)) && (num5 <= 0x7a))
                {
                    prefix.SetValue(PrefixHandle.GetAlphaPrefix(num5 - 0x61));
                }
                else
                {
                    prefix.SetValue(offset, length);
                }
                num++;
                int num8 = num;
                if (num < num2)
                {
                    index = buffer[num];
                    if ((charType[index] & 1) == 0)
                    {
                        num4 |= 0x80;
                    }
                    num4 |= index;
                    num++;
                    while (num < num2)
                    {
                        index = buffer[num];
                        if ((charType[index] & 2) == 0)
                        {
                            break;
                        }
                        num4 |= index;
                        num++;
                    }
                }
                else
                {
                    num4 |= 0x80;
                    index = 0;
                }
                localName.SetValue(num8, num - num8);
                if (num4 >= 0x80)
                {
                    this.VerifyNCName(prefix.GetString());
                    this.VerifyNCName(localName.GetString());
                }
            }
            base.BufferReader.Advance(num - offset);
        }
Beispiel #4
0
 private string GetQNameDictionaryText()
 {
     return(PrefixHandle.GetString(PrefixHandle.GetAlphaPrefix(this.length)) + ":" + this.bufferReader.GetDictionaryString(this.offset));
 }