'Copies self to destination.
If self doesn\'t exist, an OSError is raised.
If self is a directory, this method copies its children (but not
itself) recursively to destination - if destination does not exist as a
directory, this method creates it.  If destination is a file, an
IOError will be raised.
If self is a file, this method copies it to destination.  If
destination is a file, this method overwrites it.  If destination is a
directory, an IOError will be raised.
If self is a link (and followLinks is False), self will be copied
over as a new symlink with the same target as returned by os.readlink.
That means that if it is absolute, both the old and new symlink will
link to the same thing.  If it\'s relative, then perhaps not (and
it\'s also possible that this relative link will be broken).
File/directory permissions and ownership will NOT be copied over.
If followLinks is True, symlinks are followed so that they\'re treated
as their targets.  In other words, if self is a link, the link\'s target
will be copied.  If destination is a link, self will be copied to the
destination\'s target (the actual destination will be destination\'s
target).  Symlinks under self (if self is a directory) will be
followed and its target\'s children be copied recursively.
If followLinks is False, symlinks will be copied over as symlinks.
@param destination: the destination (a FilePath) to which self
should be copied
@param followLinks: whether symlinks in self should be treated as links
or as their targets'

def copyTo(self, destination, followLinks=True):

    if (self.islink() and (not followLinks)):
        os.symlink(os.readlink(self.path), destination.path)
        return
    if self.isdir():
        if (not destination.exists()):
            destination.createDirectory()
        for child in self.children():
            destChild = destination.child(child.basename())
            child.copyTo(destChild, followLinks)
    elif self.isfile():
        with destination.open('w') as writefile:
            with self.open() as readfile:
                while 1:
                    chunk = readfile.read(self._chunkSize)
                    writefile.write(chunk)
                    if (len(chunk) < self._chunkSize):
                        break
    elif (not self.exists()):
        raise OSError(errno.ENOENT, 'No    such    file    or    directory')
    else:
        raise NotImplementedError('Only    copying    of    files    and    directories    supported')
