Пример #1
0
            public string Serialize(SC3String s)
            {
                _writer = new StringWriter();
                foreach (var segment in s.Segments)
                {
                    Visit(segment);
                }

                return(_writer.ToString());
            }
Пример #2
0
            public ImmutableArray <byte> Encode(SC3String sc3String)
            {
                _builder = ImmutableArray.CreateBuilder <byte>();
                foreach (var segment in sc3String.Segments)
                {
                    Visit(segment);
                }

                Append(StringSegmentCodes.StringTerminator);
                return(_builder.ToImmutable());
            }
Пример #3
0
        public override string Serialize(SC3String sc3String)
        {
            var impl = new SerializerImpl();

            return(impl.Serialize(sc3String));
        }
Пример #4
0
        public ImmutableArray <byte> Encode(SC3String sc3String)
        {
            var impl = new EncoderImpl(_data);

            return(impl.Encode(sc3String));
        }