Exemplo n.º 1
0
        public CSharpLineMappingWriter(CSharpCodeWriter writer, SourceLocation documentLocation, int contentLength, string sourceFilename)
            : this(writer, documentLocation, contentLength)
        {
            _writePragmas = true;

            // TODO: Should this just be '\n'?
            if (!_writer.LastWrite.EndsWith("\n"))
            {
                _writer.WriteLine();
            }

            _writer.WriteLineNumberDirective(documentLocation.LineIndex + 1, sourceFilename);

            _generatedLocation = _writer.GetCurrentSourceLocation();
        }
Exemplo n.º 2
0
        public CSharpLineMappingWriter(CSharpCodeWriter writer, SourceLocation documentLocation, int contentLength)
        {
            _writer = writer;
            _documentMapping = new MappingLocation(documentLocation, contentLength);

            _startIndent = _writer.CurrentIndent;
            _generatedContentLength = 0;
            _writer.ResetIndent();
            
            _generatedLocation = _writer.GetCurrentSourceLocation();
        }
Exemplo n.º 3
0
        public CSharpLineMappingWriter(CSharpCodeWriter writer, SourceLocation documentLocation, int contentLength)
        {
            _writer          = writer;
            _documentMapping = new MappingLocation(documentLocation, contentLength);

            _startIndent            = _writer.CurrentIndent;
            _generatedContentLength = 0;
            _writer.ResetIndent();

            _generatedLocation = _writer.GetCurrentSourceLocation();
        }
Exemplo n.º 4
0
 public CSharpLineMappingWriter(CSharpCodeWriter writer, SourceLocation documentLocation, int contentLength)
     : this(writer, addLineMappings : true)
 {
     _documentMapping   = new MappingLocation(documentLocation, contentLength);
     _generatedLocation = _writer.GetCurrentSourceLocation();
 }