Fix clang style warnings in webrtc/base

Mostly this consists of marking functions with override when
applicable, and moving function bodies from .h to .cc files.

Not inlining virtual functions with simple bodies such as

  { return false; }

strikes me as probably losing more in readability than we gain in
binary size and compilation time, but I guess it's just like any other
case where enabling a generally good warning forces us to write
slightly worse code in a couple of places.

BUG=163
R=kjellander@webrtc.org, tommi@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/47429004

Cr-Commit-Position: refs/heads/master@{#8656}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8656 4adac7df-926f-26a2-2b94-8c16560cd09d
diff --git a/webrtc/base/unixfilesystem.h b/webrtc/base/unixfilesystem.h
index 7b6c20e..e220911 100644
--- a/webrtc/base/unixfilesystem.h
+++ b/webrtc/base/unixfilesystem.h
@@ -20,7 +20,7 @@
 class UnixFilesystem : public FilesystemInterface {
  public:
   UnixFilesystem();
-  virtual ~UnixFilesystem();
+  ~UnixFilesystem() override;
 
 #if defined(WEBRTC_ANDROID) || defined(WEBRTC_IOS)
   // Android does not have a native code API to fetch the app data or temp
@@ -36,21 +36,21 @@
 
   // Opens a file. Returns an open StreamInterface if function succeeds.
   // Otherwise, returns NULL.
-  virtual FileStream *OpenFile(const Pathname &filename,
-                               const std::string &mode);
+  FileStream* OpenFile(const Pathname& filename,
+                       const std::string& mode) override;
 
   // Atomically creates an empty file accessible only to the current user if one
   // does not already exist at the given path, otherwise fails.
-  virtual bool CreatePrivateFile(const Pathname &filename);
+  bool CreatePrivateFile(const Pathname& filename) override;
 
   // This will attempt to delete the file located at filename.
   // It will fail with VERIY if you pass it a non-existant file, or a directory.
-  virtual bool DeleteFile(const Pathname &filename);
+  bool DeleteFile(const Pathname& filename) override;
 
   // This will attempt to delete the folder located at 'folder'
   // It ASSERTs and returns false if you pass it a non-existant folder or a
   // plain file.
-  virtual bool DeleteEmptyFolder(const Pathname &folder);
+  bool DeleteEmptyFolder(const Pathname& folder) override;
 
   // Creates a directory. This will call itself recursively to create /foo/bar
   // even if /foo does not exist. All created directories are created with the
@@ -59,56 +59,58 @@
   virtual bool CreateFolder(const Pathname &pathname, mode_t mode);
 
   // As above, with mode = 0755.
-  virtual bool CreateFolder(const Pathname &pathname);
+  bool CreateFolder(const Pathname& pathname) override;
 
   // This moves a file from old_path to new_path, where "file" can be a plain
   // file or directory, which will be moved recursively.
   // Returns true if function succeeds.
-  virtual bool MoveFile(const Pathname &old_path, const Pathname &new_path);
-  virtual bool MoveFolder(const Pathname &old_path, const Pathname &new_path);
+  bool MoveFile(const Pathname& old_path, const Pathname& new_path) override;
+  bool MoveFolder(const Pathname& old_path, const Pathname& new_path) override;
 
   // This copies a file from old_path to _new_path where "file" can be a plain
   // file or directory, which will be copied recursively.
   // Returns true if function succeeds
-  virtual bool CopyFile(const Pathname &old_path, const Pathname &new_path);
+  bool CopyFile(const Pathname& old_path, const Pathname& new_path) override;
 
   // Returns true if a pathname is a directory
-  virtual bool IsFolder(const Pathname& pathname);
+  bool IsFolder(const Pathname& pathname) override;
 
   // Returns true if pathname represents a temporary location on the system.
-  virtual bool IsTemporaryPath(const Pathname& pathname);
+  bool IsTemporaryPath(const Pathname& pathname) override;
 
   // Returns true of pathname represents an existing file
-  virtual bool IsFile(const Pathname& pathname);
+  bool IsFile(const Pathname& pathname) override;
 
   // Returns true if pathname refers to no filesystem object, every parent
   // directory either exists, or is also absent.
-  virtual bool IsAbsent(const Pathname& pathname);
+  bool IsAbsent(const Pathname& pathname) override;
 
-  virtual std::string TempFilename(const Pathname &dir,
-                                   const std::string &prefix);
+  std::string TempFilename(const Pathname& dir,
+                           const std::string& prefix) override;
 
   // A folder appropriate for storing temporary files (Contents are
   // automatically deleted when the program exists)
-  virtual bool GetTemporaryFolder(Pathname &path, bool create,
-                                 const std::string *append);
+  bool GetTemporaryFolder(Pathname& path,
+                          bool create,
+                          const std::string* append) override;
 
-  virtual bool GetFileSize(const Pathname& path, size_t* size);
-  virtual bool GetFileTime(const Pathname& path, FileTimeType which,
-                           time_t* time);
+  bool GetFileSize(const Pathname& path, size_t* size) override;
+  bool GetFileTime(const Pathname& path,
+                   FileTimeType which,
+                   time_t* time) override;
 
   // Returns the path to the running application.
-  virtual bool GetAppPathname(Pathname* path);
+  bool GetAppPathname(Pathname* path) override;
 
-  virtual bool GetAppDataFolder(Pathname* path, bool per_user);
+  bool GetAppDataFolder(Pathname* path, bool per_user) override;
 
   // Get a temporary folder that is unique to the current user and application.
-  virtual bool GetAppTempFolder(Pathname* path);
+  bool GetAppTempFolder(Pathname* path) override;
 
-  virtual bool GetDiskFreeSpace(const Pathname& path, int64 *freebytes);
+  bool GetDiskFreeSpace(const Pathname& path, int64* freebytes) override;
 
   // Returns the absolute path of the current directory.
-  virtual Pathname GetCurrentDirectory();
+  Pathname GetCurrentDirectory() override;
 
  private:
 #if defined(WEBRTC_ANDROID) || defined(WEBRTC_IOS)