Allow RefactoringTool to write to memory instead of always to disk
    
RefactoringTool::run() always writes the result of rewrites to disk.
Instead, make this optional and provide a method for getting the
refactoring results in a memory buffer instead.

Also made ClangTool polymorphic so RefactoringTool could inherit from it
to properly express the IS-A relationship. This change also provides
access to ClangTool's public interface, e.g. mapVirtualFile() which is
important once refactored buffers start living in memory instead of on
disk.

Reviewers: klimek



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@172219 91177308-0d34-0410-b5e6-96231b3b80d8