dell_storagecenter_driver/dell_storagecenter_api.py
def _create_folder_path(self, url, foldername):
        """Creates a folder path from a fully qualified name.

        The REST url sent in defines the folder type being created on the Dell
        Storage Center backend.  Thus this is generic to server and volume
        folders.

        :param url: This is the Dell SC REST url for creating the specific
                    (server or volume) folder type.
        :param foldername: The full folder name with path.
        :returns: The REST folder object.
        """
        path = self._path_to_array(foldername)
        folderpath = ''
        instanceId = ''
        # Technically the first folder is the root so that is already created.
        found = True
        scfolder = None
        for folder in path:
            folderpath = folderpath + folder
            # If the last was found see if this part of the path exists too
            if found:
                listurl = url + '/GetList'
                scfolder = self._find_folder(listurl,
                                             folderpath)
                if not scfolder:
                    found = False
            # We didn't find it so create it
            if not found:
                scfolder = self._create_folder(url,
                                               instanceId,
                                               folder)
            # If we haven't found a folder or created it then leave
            if not scfolder:
                LOG.error('Unable to create folder path %s',
                          folderpath)
                break
            # Next part of the path will need this
            instanceId = self._get_id(scfolder)
            folderpath = folderpath + '/'
        return scfolder
Creates a folder path from a fully qualified name.

        The REST url sent in defines the folder type being created on the Dell
        Storage Center backend.  Thus this is generic to server and volume
        folders.

        :param url: This is the Dell SC REST url for creating the specific
                    (server or volume) folder type.
        :param foldername: The full folder name with path.
        :returns: The REST folder object.
        
Creates a folder path from a fully qualified name.
The REST url sent in defines the folder type being created on the Dell
Storage Center backend.  Thus this is generic to server and volume
folders.
Creates a folder path from a fully qualified name . The REST url sent in defines the folder type being created on the Dell Storage Center backend . Thus this is generic to server and volume folders .
def _create_folder_path(self, url, foldername):
        path = self._path_to_array(foldername)
        folderpath = ''
        instanceId = ''
        found = True
        scfolder = None
        for folder in path:
            folderpath = folderpath + folder
            if found:
                listurl = url + '/GetList'
                scfolder = self._find_folder(listurl,
                                             folderpath)
                if not scfolder:
                    found = False
            if not found:
                scfolder = self._create_folder(url,
                                               instanceId,
                                               folder)
            if not scfolder:
                LOG.error('Unable to create folder path %s',
                          folderpath)
                break
            instanceId = self._get_id(scfolder)
            folderpath = folderpath + '/'
        return scfolder
def _create_folder_path ( self , url , foldername ) : path = self . _path_to_array ( foldername ) folderpath = '' instanceId = '' found = True scfolder = None for folder in path : folderpath = folderpath + folder if found : listurl = url + '/GetList' scfolder = self . _find_folder ( listurl , folderpath ) if not scfolder : found = False if not found : scfolder = self . _create_folder ( url , instanceId , folder ) if not scfolder : LOG . error ( 'Unable to create folder path %s' , folderpath ) break instanceId = self . _get_id ( scfolder ) folderpath = folderpath + '/' return scfolder
Creates a folder path from a fully qualified name.
Creates a folder path from a fully qualified name .
"""Creates a folder path from a fully qualified name.

        The REST url sent in defines the folder type being created on the Dell
        Storage Center backend.  Thus this is generic to server and volume
        folders.

        :param url: This is the Dell SC REST url for creating the specific
                    (server or volume) folder type.
        :param foldername: The full folder name with path.
        :returns: The REST folder object.
        """ # Technically the first folder is the root so that is already created. # If the last was found see if this part of the path exists too # We didn't find it so create it # If we haven't found a folder or created it then leave # Next part of the path will need this
The REST folder object.
The REST folder object .
self
url
This is the Dell SC REST url for creating the specific
(server or volume) folder type.
This is the Dell SC REST url for creating the specific ( server or volume ) folder type .
foldername
The full folder name with path.
The full folder name with path .