예제 #1
0
 /// <summary>
 /// Swap return type to built in type.
 /// </summary>
 /// <param name="methodDeclaration">
 /// The method declaration.
 /// </param>
 private static void SwapReturnTypeToBuiltInType(IMethodDeclaration methodDeclaration)
 {
     using (WriteLockCookie.Create(true))
     {
         methodDeclaration.SetType(methodDeclaration.GetReturnType());
     }
 }
예제 #2
0
 private static void SetSignature([NotNull] IMethodDeclaration methodDeclaration, [NotNull] IType newReturnValue, [NotNull] string newName)
 {
     methodDeclaration.SetType(newReturnValue);
     if(!methodDeclaration.IsAbstract)
         methodDeclaration.SetAsync(true);
     methodDeclaration.SetName(newName);
 }
 /// <summary>
 /// Swap return type to built in type.
 /// </summary>
 /// <param name="methodDeclaration">
 /// The method declaration.
 /// </param>
 private static void SwapReturnTypeToBuiltInType(IMethodDeclaration methodDeclaration)
 {
     using (WriteLockCookie.Create(true))
     {
         methodDeclaration.SetType(methodDeclaration.GetReturnType());
     }
 }