• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C# ISymbolDocumentWriter类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中ISymbolDocumentWriter的典型用法代码示例。如果您正苦于以下问题:C# ISymbolDocumentWriter类的具体用法?C# ISymbolDocumentWriter怎么用?C# ISymbolDocumentWriter使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



ISymbolDocumentWriter类属于命名空间,在下文中一共展示了ISymbolDocumentWriter类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: ProxyBuilderGeneratorItems

        internal ProxyBuilderGeneratorItems(AssemblyBuilder assembly, ModuleBuilder module,
			ISymbolDocumentWriter symbolDocumentWriter)
            : this()
        {
            this.Assembly = assembly;
            this.Module = module;
            this.SymbolDocumentWriter = symbolDocumentWriter;
        }
开发者ID:JasonBock,项目名称:DynamicProxies,代码行数:8,代码来源:ProxyBuilderGeneratorItems.cs


示例2: AddLineNumberInfo

 internal void AddLineNumberInfo(ISymbolDocumentWriter document, int iOffset, int iStartLine, int iStartColumn, int iEndLine, int iEndColumn)
 {
     this.EnsureCapacity();
     this.m_iOffsets[this.m_iLineNumberCount] = iOffset;
     this.m_iLines[this.m_iLineNumberCount] = iStartLine;
     this.m_iColumns[this.m_iLineNumberCount] = iStartColumn;
     this.m_iEndLines[this.m_iLineNumberCount] = iEndLine;
     this.m_iEndColumns[this.m_iLineNumberCount] = iEndColumn;
     this.m_iLineNumberCount++;
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:10,代码来源:REDocument.cs


示例3: SourceCodeWriter

 internal SourceCodeWriter(string fileName, ISymbolDocumentWriter symbolDocumentWriter)
 {
     var directoryName = Path.GetDirectoryName(fileName);
     if (!string.IsNullOrEmpty(directoryName))
         Directory.CreateDirectory(directoryName);
     _stringBuilder = new StringBuilder();
     _sourceWriter = new StringWriter(_stringBuilder);
     _fileName = fileName;
     _symbolDocumentWriter = symbolDocumentWriter;
     _currentLine = 1;
     Indent = 0;
 }
开发者ID:yonglehou,项目名称:BTDB,代码行数:12,代码来源:SourceCodeWriter.cs


示例4: FindDocument

 private int FindDocument(ISymbolDocumentWriter document)
 {
     if ((this.m_iLastFound >= this.m_DocumentCount) || (this.m_Documents[this.m_iLastFound].m_document != document))
     {
         for (int i = 0; i < this.m_DocumentCount; i++)
         {
             if (this.m_Documents[i].m_document == document)
             {
                 this.m_iLastFound = i;
                 return this.m_iLastFound;
             }
         }
         this.EnsureCapacity();
         this.m_iLastFound = this.m_DocumentCount;
         this.m_Documents[this.m_iLastFound] = new REDocument(document);
         this.m_DocumentCount++;
     }
     return this.m_iLastFound;
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:19,代码来源:LineNumberInfo.cs


示例5: FindDocument

 // Find a REDocument representing document. If we cannot find one, we will add a new entry into
 // the REDocument array.
 private int FindDocument(ISymbolDocumentWriter document)
 {
     int         i;
     
     // This is an optimization. The chance that the previous line is coming from the same
     // document is very high.
     if (m_iLastFound < m_DocumentCount && m_Documents[m_iLastFound].m_document == document)
         return m_iLastFound;
         
     for (i = 0; i < m_DocumentCount; i++)
     {
         if (m_Documents[i].m_document == document)
         {
             m_iLastFound = i;
             return m_iLastFound;
         }
     }
     
     // cannot find an existing document so add one to the array                                       
     EnsureCapacity();
     m_iLastFound = m_DocumentCount;
     m_Documents[m_iLastFound] = new REDocument(document);
     checked { m_DocumentCount++; }
     return m_iLastFound;
 }
开发者ID:uQr,项目名称:referencesource,代码行数:27,代码来源:ilgenerator.cs


示例6: DefineSequencePoints

 /// <include file='doc\SymWriter.uex' path='docs/doc[@for="SymbolWriter.DefineSequencePoints"]/*' />
 public void DefineSequencePoints(ISymbolDocumentWriter document,
                           int[] offsets,
                           int[] lines,
                           int[] columns,
                           int[] endLines,
                           int[] endColumns)
 {
     m_target.DefineSequencePoints(((SymDocumentWriter)document).InternalDocumentWriter, offsets.Length,
                                 offsets, lines, columns, endLines, endColumns);
 }
开发者ID:jredville,项目名称:ipydbg,代码行数:11,代码来源:SymWriter.cs


示例7: REDocument

 internal REDocument(ISymbolDocumentWriter document)
 {
     this.m_document = document;
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:4,代码来源:REDocument.cs


示例8: MarkSequencePoint

 /// <summary>
 /// Marks a sequence point in the Microsoft intermediate language (MSIL) stream.
 /// </summary>
 /// <param name="il"/>
 /// <param name="document">The document for which the sequence point is being defined.</param>
 /// <param name="startLine">The line where the sequence point begins.</param>
 /// <param name="startColumn">The column in the line where the sequence point begins.</param>
 /// <param name="endLine">The line where the sequence point ends.</param>
 /// <param name="endColumn">The column in the line where the sequence point ends.</param>
 public static ILGenerator MarkSequencePoint(
     this ILGenerator il,
     ISymbolDocumentWriter document,
     int startLine,
     int startColumn,
     int endLine,
     int endColumn)
 {
     il.MarkSequencePoint(document, startLine, startColumn, endLine, endColumn);
     return il;
 }
开发者ID:zdomokos,项目名称:timeseriesdb,代码行数:20,代码来源:ILGeneratorExtensions.cs


示例9: MarkSequencePoint

		public virtual void MarkSequencePoint (ISymbolDocumentWriter document, int startLine,
						       int startColumn, int endLine, int endColumn)
		{
			if (currentSequence == null || currentSequence.Document != document) {
				if (sequencePointLists == null)
					sequencePointLists = new ArrayList ();
				currentSequence = new SequencePointList (document);
				sequencePointLists.Add (currentSequence);
			}
			
			currentSequence.AddSequencePoint (code_len, startLine, startColumn, endLine, endColumn);
		}
开发者ID:Profit0004,项目名称:mono,代码行数:12,代码来源:ILGenerator.cs


示例10: SequencePointList

		public SequencePointList (ISymbolDocumentWriter doc)
		{
			this.doc = doc;
		}
开发者ID:Profit0004,项目名称:mono,代码行数:4,代码来源:ILGenerator.cs


示例11: MarkSequencePoint

 public virtual void MarkSequencePoint(
     ISymbolDocumentWriter document,
     int startLine,       // line number is 1 based
     int startColumn,     // column is 0 based
     int endLine,         // line number is 1 based
     int endColumn)       // column is 0 based
 {
     if (startLine == 0 || startLine < 0 || endLine == 0 || endLine < 0)
     {
         throw new ArgumentOutOfRangeException("startLine");
     }
     Contract.EndContractBlock();
     m_LineNumberInfo.AddLineNumberInfo(document, m_length, startLine, startColumn, endLine, endColumn);
 }
开发者ID:uQr,项目名称:referencesource,代码行数:14,代码来源:ilgenerator.cs


示例12: AddLineNumberInfo

 internal void AddLineNumberInfo(
     ISymbolDocumentWriter document,
     int             iOffset,
     int             iStartLine,
     int             iStartColumn,
     int             iEndLine,
     int             iEndColumn)
 {
     Contract.Assert(document == m_document, "Bad document look up!");
     
     // make sure that arrays are large enough to hold addition info
     EnsureCapacity();
     
     m_iOffsets[m_iLineNumberCount] = iOffset;
     m_iLines[m_iLineNumberCount] = iStartLine;
     m_iColumns[m_iLineNumberCount] = iStartColumn;
     m_iEndLines[m_iLineNumberCount] = iEndLine;
     m_iEndColumns[m_iLineNumberCount] = iEndColumn;
     checked { m_iLineNumberCount++; }
 }
开发者ID:uQr,项目名称:referencesource,代码行数:20,代码来源:ilgenerator.cs


示例13: SetMethodSourceRange

 /// <include file='doc\SymWriter.uex' path='docs/doc[@for="SymbolWriter.SetMethodSourceRange"]/*' />
 public void SetMethodSourceRange(ISymbolDocumentWriter startDoc,
                                  int startLine,
                                  int startColumn,
                                  ISymbolDocumentWriter endDoc,
                                  int endLine,
                                  int endColumn)
 {
     m_target.SetMethodSourceRange(((SymDocumentWriter)startDoc).InternalDocumentWriter, startLine, startColumn,
                                   ((SymDocumentWriter)endDoc).InternalDocumentWriter, endLine, endColumn);
 }
开发者ID:jredville,项目名称:ipydbg,代码行数:11,代码来源:SymWriter.cs


示例14: MarkSequencePoint

		/// <summary>
		/// Marks a sequence point in the Microsoft intermediate language (MSIL) stream.
		/// </summary>
		/// <param name="document">The document for which the sequence point is being defined.</param>
		/// <param name="startLine">The line where the sequence point begins.</param>
		/// <param name="startColumn">The column in the line where the sequence point begins.</param>
		/// <param name="endLine">The line where the sequence point ends.</param>
		/// <param name="endColumn">The column in the line where the sequence point ends.</param>
		/// <returns>Current instance of the EmitHelper.</returns>
		public EmitHelper MarkSequencePoint(
			ISymbolDocumentWriter document,
			int startLine,
			int startColumn,
			int endLine,
			int endColumn)
		{
			_ilGenerator.MarkSequencePoint(document, startLine, startColumn, endLine, endColumn);
			return this;
		}
开发者ID:apakian,项目名称:fluorinefx,代码行数:19,代码来源:EmitHelper.cs


示例15: REDocument

 internal REDocument(ISymbolDocumentWriter document)
 {
     // initialize data variables
     m_iLineNumberCount = 0;
     m_document = document;
 }
开发者ID:uQr,项目名称:referencesource,代码行数:6,代码来源:ilgenerator.cs


示例16: MarkSequencePoint

		/// <summary>
		/// Marks a sequence point in the Microsoft intermediate language (MSIL) stream.
		/// </summary>
		public void MarkSequencePoint(ISymbolDocumentWriter document, int startLine, int startColumn, int endLine,
			int endColumn)
		{ il.MarkSequencePoint(document, startLine, startColumn, endLine, endColumn); }
开发者ID:dw4dev,项目名称:Phalanger,代码行数:6,代码来源:ILEmitter.cs


示例17: MarkSequencePoint

 [SuppressMessage("Microsoft.Contracts", "CC1055")]  // Skip extra error checking to avoid *potential* AppCompat problems.
 public override void MarkSequencePoint(ISymbolDocumentWriter document,
                                        int startLine,
                                        int startColumn,
                                        int endLine,
                                        int endColumn)
 {
     throw new NotSupportedException(Environment.GetResourceString("InvalidOperation_NotAllowedInDynamicMethod"));
 }
开发者ID:Clockwork-Muse,项目名称:coreclr,代码行数:9,代码来源:DynamicILGenerator.cs


示例18: Emitter

 public Emitter(EmitterOptions options)
 {
     _options = options;
     _assemblyName = new AssemblyName(_options.AssemblyName);
     _assembly = AppDomain.CurrentDomain.DefineDynamicAssembly(_assemblyName, AssemblyBuilderAccess.RunAndSave);// TODO: temp for debugging .RunAndCollect);
     if (_options.DebugOn)
         _assembly.SetCustomAttribute
         (
             new CustomAttributeBuilder
             (
                 typeof(DebuggableAttribute).GetConstructor
                 (
                     new System.Type[] { typeof(DebuggableAttribute.DebuggingModes) }
                 ),
                 new object[]
                 {
                     DebuggableAttribute.DebuggingModes.DisableOptimizations |
                     DebuggableAttribute.DebuggingModes.Default
                 }
             )
         );
     _module = _assembly.DefineDynamicModule(_assemblyName.Name, _assemblyName.Name + ".dll", _options.DebugOn);
     if (_options.DebugOn)
         _symbolWriter = _module.DefineDocument(_options.SourceFileName, Guid.Empty, Guid.Empty, Guid.Empty);
     _tupleToNative = new Dictionary<Type.TupleType, System.Type>();
 }
开发者ID:jgabb8989,项目名称:DotQL,代码行数:26,代码来源:Emitter.cs


示例19: ILDynamicMethodDebugImpl

 public ILDynamicMethodDebugImpl(string name, Type delegateType, Type thisType)
 {
     _delegateType = delegateType;
     _expectedLength = 64;
     var mi = delegateType.GetMethod("Invoke");
     var uniqueName = ILDynamicTypeDebugImpl.UniqueName(name);
     _assemblyBuilder = AppDomain.CurrentDomain.DefineDynamicAssembly(new AssemblyName(uniqueName), AssemblyBuilderAccess.RunAndSave, DynamicILDirectoryPath.DynamicIL);
     _moduleBuilder = _assemblyBuilder.DefineDynamicModule(uniqueName + ".dll", true);
     var sourceCodeFileName = Path.Combine(DynamicILDirectoryPath.DynamicIL, uniqueName + ".il");
     _symbolDocumentWriter = _moduleBuilder.DefineDocument(sourceCodeFileName, SymDocumentType.Text, SymLanguageType.ILAssembly, SymLanguageVendor.Microsoft);
     _sourceCodeWriter = new SourceCodeWriter(sourceCodeFileName, _symbolDocumentWriter);
     Type[] parameterTypes;
     if (thisType != null)
     {
         parameterTypes = new[] { thisType }.Concat(mi.GetParameters().Select(pi => pi.ParameterType)).ToArray();
     }
     else
     {
         parameterTypes = mi.GetParameters().Select(pi => pi.ParameterType).ToArray();
     }
     _sourceCodeWriter.StartMethod(name, mi.ReturnType, parameterTypes, MethodAttributes.Static);
     _typeBuilder = _moduleBuilder.DefineType(name, TypeAttributes.Public, typeof(object), Type.EmptyTypes);
     _forbidenInstructions = new ILGenForbidenInstructionsCheating(_typeBuilder);
     _dynamicMethod = _typeBuilder.DefineMethod("Invoke", MethodAttributes.Public | MethodAttributes.Static, mi.ReturnType, parameterTypes);
     for (int i = 0; i < parameterTypes.Length; i++)
     {
         _dynamicMethod.DefineParameter(i + 1, ParameterAttributes.In, string.Format("arg{0}", i));
     }
 }
开发者ID:yonglehou,项目名称:BTDB,代码行数:29,代码来源:ILDynamicMethodDebugImpl.cs


示例20: BeginModule

 public void BeginModule(string ifile)
 {
     appdomain	= System.Threading.Thread.GetDomain();
     appname		= getAssemblyName(filename);
     appbuild	= appdomain.DefineDynamicAssembly(appname, AssemblyBuilderAccess.Save, ".");
     emodule		= appbuild.DefineDynamicModule(filename + "_module", io.GetOutputFilename(), io.getGenDebug());
     Guid g 		= System.Guid.Empty;
     if (io.getGenDebug()) srcdoc = emodule.DefineDocument(ifile, g, g, g);
 }
开发者ID:master,项目名称:plil,代码行数:9,代码来源:exe.cs



注:本文中的ISymbolDocumentWriter类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# ISymbolWriter类代码示例发布时间:2022-05-24
下一篇:
C# ISymbolDocument类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap