Exemple #1
0
        public int WriteTo(TextWriter writer)
        {
            int length = 0;

            Path8 parent = this.Parent;

            if (!parent.IsRoot)
            {
                length += Parent.WriteTo(writer);
                writer.Write((char)_delimiter);
                length++;
            }

            length += Name.WriteTo(writer);

            return(length);
        }
Exemple #2
0
        public int WriteTo(Stream stream)
        {
            int length = 0;

            Path8 parent = this.Parent;

            if (!parent.IsRoot)
            {
                length += Parent.WriteTo(stream);
                stream.WriteByte(_delimiter);
                length++;
            }

            length += Name.WriteTo(stream);

            return(length);
        }
Exemple #3
0
        public int WriteTo(byte[] buffer, int index)
        {
            int length = 0;

            Path8 parent = this.Parent;

            if (!parent.IsRoot)
            {
                length += parent.WriteTo(buffer, index + length);

                buffer[index + length] = _delimiter;
                length++;
            }

            length += Name.WriteTo(buffer, index + length);

            return(length);
        }