public ProcessTemplate ( string sourceText, string>.IDictionary |
||
sourceText | string | The source text. |
parameters | string>.IDictionary | The parameters. |
removeFileHeaders | bool | if set to |
removeXmlComments | bool | if set to |
removeThisPointer | bool | if set to |
리턴 | TextTransformation |
/// <summary> /// Transforms the specified source file. /// </summary> /// <param name="textTransformationRequest">The text transformation request.</param> /// <returns>The Text Transformation.</returns> public TextTransformation Transform(TextTransformationRequest textTransformationRequest) { TraceService.WriteLine("TextTransformationService::Transform sourceFile=" + textTransformationRequest.SourceFile); string sourceText = this.GetText(textTransformationRequest.SourceFile); TraceService.WriteDebugLine("sourceText=" + sourceText); SimpleTextTemplatingEngine engine = new SimpleTextTemplatingEngine(); TraceService.WriteLine("Before processing template via SimpleTextTemplatingEngine"); TextTransformation textTransformation = engine.ProcessTemplate( sourceText, textTransformationRequest.Parameters, textTransformationRequest.RemoveFileHeaders, textTransformationRequest.RemoveXmlComments, textTransformationRequest.RemoveThisPointer); TraceService.WriteLine("After processing template via SimpleTextTemplatingEngine = SUCCESS!"); TraceService.WriteDebugLine("output=" + textTransformation.Output); return(textTransformation); }
/// <summary> /// Gets the text output. /// </summary> /// <param name="sourceText">The source text.</param> /// <param name="parameters">The parameters.</param> /// <param name="removeFileHeaders">if set to <c>true</c> [remove file headers].</param> /// <param name="removeXmlComments">if set to <c>true</c> [remove XML comments].</param> /// <param name="removeThisPointer">if set to <c>true</c> [remove this pointer].</param> /// <returns></returns> public string GetTextOutput( string sourceText, IDictionary <string, string> parameters, bool removeFileHeaders, bool removeXmlComments, bool removeThisPointer) { SimpleTextTemplatingEngine engine = new SimpleTextTemplatingEngine(); TextTransformation textTransformation = engine.ProcessTemplate(sourceText, parameters, removeFileHeaders, removeXmlComments, removeThisPointer); return(textTransformation.Output); }
/// <summary> /// Gets the text output. /// </summary> /// <param name="sourceText">The source text.</param> /// <param name="parameters">The parameters.</param> /// <param name="removeFileHeaders">if set to <c>true</c> [remove file headers].</param> /// <param name="removeXmlComments">if set to <c>true</c> [remove XML comments].</param> /// <param name="removeThisPointer">if set to <c>true</c> [remove this pointer].</param> /// <returns></returns> public string GetTextOutput( string sourceText, IDictionary<string, string> parameters, bool removeFileHeaders, bool removeXmlComments, bool removeThisPointer) { SimpleTextTemplatingEngine engine = new SimpleTextTemplatingEngine(); TextTransformation textTransformation = engine.ProcessTemplate(sourceText, parameters, removeFileHeaders, removeXmlComments, removeThisPointer); return textTransformation.Output; }
/// <summary> /// Transforms the specified source file. /// </summary> /// <param name="textTransformationRequest">The text transformation request.</param> /// <returns>The Text Transformation.</returns> public TextTransformation Transform(TextTransformationRequest textTransformationRequest) { TraceService.WriteLine("TextTransformationService::Transform sourceFile=" + textTransformationRequest.SourceFile); string sourceText = this.GetText(textTransformationRequest.SourceFile); ////TraceService.WriteDebugLine("sourceText=" + sourceText); SimpleTextTemplatingEngine engine = new SimpleTextTemplatingEngine(); TraceService.WriteLine("Before processing template via SimpleTextTemplatingEngine"); TextTransformation textTransformation = engine.ProcessTemplate( sourceText, textTransformationRequest.Parameters, textTransformationRequest.RemoveFileHeaders, textTransformationRequest.RemoveXmlComments, textTransformationRequest.RemoveThisPointer); TraceService.WriteLine("After processing template via SimpleTextTemplatingEngine = SUCCESS!"); ////TraceService.WriteDebugLine("output=" + textTransformation.Output); return textTransformation; }