'Get the clone spec.
:param datastore: Reference to datastore
:param disk_move_type: Disk move type
:param snapshot: Reference to snapshot
:param backing: Source backing VM
:param disk_type: Disk type of clone
:param host: Target host
:param resource_pool: Target resource pool
:param extra_config: Key-value pairs to be written to backing\'s
extra-config
:return: Clone spec'

def _get_clone_spec(self, datastore, disk_move_type, snapshot, backing, disk_type, host=None, resource_pool=None, extra_config=None):

    if (disk_type is not None):
        disk_device = self._get_disk_device(backing)
    else:
        disk_device = None
    relocate_spec = self._get_relocate_spec(datastore, resource_pool, host, disk_move_type, disk_type, disk_device)
    cf = self._session.vim.client.factory
    clone_spec = cf.create('ns0:VirtualMachineCloneSpec')
    clone_spec.location = relocate_spec
    clone_spec.powerOn = False
    clone_spec.template = False
    clone_spec.snapshot = snapshot
    if extra_config:
        config_spec = cf.create('ns0:VirtualMachineConfigSpec')
        if (BACKING_UUID_KEY in extra_config):
            config_spec.instanceUuid = extra_config.pop(BACKING_UUID_KEY)
        config_spec.extraConfig = self._get_extra_config_option_values(extra_config)
        clone_spec.config = config_spec
    LOG.debug('Spec    for    cloning    the    backing:    %s.', clone_spec)
    return clone_spec
