def createLsbootPolicy(inUcsmHost, lsbootPolicyStr):
        """Configures the LsbootPolicy policies."""
        logging.debug('create LsbootPolicy ' + lsbootPolicyStr)
        lsbootPolicyList = ast.literal_eval(lsbootPolicyStr)

        pDn = lsbootPolicyList['TargetOrg']

        lsbootPolicyDn = pDn + "/boot-policy-" + lsbootPolicyList[LsbootPolicy.NAME]
        inUcsmHost.debug = True
        lsbootPolicyResList = {
                                LsbootPolicy.NAME: lsbootPolicyList[LsbootPolicy.NAME], \
                                LsbootPolicy.PURPOSE: lsbootPolicyList[LsbootPolicy.PURPOSE], \
                                LsbootPolicy.REBOOT_ON_UPDATE: lsbootPolicyList[LsbootPolicy.REBOOT_ON_UPDATE], \
                                LsbootPolicy.ENFORCE_VNIC_NAME: lsbootPolicyList[LsbootPolicy.ENFORCE_VNIC_NAME], \
                                LsbootPolicy.DESCR: lsbootPolicyList[LsbootPolicy.DESCR]
                               }

        addObjectToUcs(inUcsmHost, pDn, OrgOrg.ClassId(), LsbootPolicy.ClassId(), lsbootPolicyResList, lsbootPolicyDn)

        # VirtualMedia read-only Access
        if 'vm-ro' in lsbootPolicyList.keys():
                rnPrefix = lsbootPolicyList['vm-ro']['Access'] + "-" + lsbootPolicyList['vm-ro']['Type']
                lsbootVirtualMediaDn = lsbootPolicyDn + "/" + rnPrefix
                lsbootVirtualMediaList = lsbootPolicyList['vm-ro'] 
        	addObjectToUcs(inUcsmHost, lsbootPolicyDn, LsbootPolicy.ClassId(), LsbootVirtualMedia.ClassId(), lsbootVirtualMediaList, lsbootVirtualMediaDn)
	pass

        # LAN or PXE Boot option
        if 'lan' in lsbootPolicyList.keys():
                rnPrefix = lsbootPolicyList['lan']['Type']
                lsbootLanDn = lsbootPolicyDn + "/" + rnPrefix
		lsbootLanImagePathList = lsbootPolicyList['lan'].pop('ImagePath')
                lsbootLanList = lsbootPolicyList['lan']
	        addObjectToUcs(inUcsmHost, lsbootPolicyDn, LsbootPolicy.ClassId(), LsbootLan.ClassId(), lsbootLanList, lsbootLanDn)
		#ImagePath
		lsbootLanImagePathDn = lsbootLanDn + "/path-" + lsbootLanImagePathList['Type']
		addObjectToUcs(inUcsmHost, lsbootLanDn, LsbootLan.ClassId(), LsbootLanImagePath.ClassId(), lsbootLanImagePathList, lsbootLanImagePathDn)

	pass

        # Storage/LocalStorage
        if 'storage' in lsbootPolicyList.keys():

                rnPrefix = lsbootPolicyList['storage']['Type']

                lsbootStorageDn = lsbootPolicyDn + "/" + rnPrefix
                lsbootStorageList = lsbootPolicyList['storage'] 
        	addObjectToUcs(inUcsmHost, lsbootPolicyDn, LsbootPolicy.ClassId(), LsbootStorage.ClassId(), lsbootStorageList, lsbootStorageDn)
		lsbootLocalStorageDn = lsbootStorageDn + "/" + "local-storage"
		addObjectToUcs(inUcsmHost, lsbootStorageDn, LsbootStorage.ClassId(), LsbootLocalStorage.ClassId(), {}, lsbootLocalStorageDn)

	pass

        # VirtualMedia read-write Access
        if 'vm-rw' in lsbootPolicyList.keys():
                rnPrefix = lsbootPolicyList['vm-rw']['Access'] + "-" + lsbootPolicyList['vm-rw']['Type']
                lsbootVirtualMediaDn = lsbootPolicyDn + "/" + rnPrefix
                lsbootVirtualMediaList = lsbootPolicyList['vm-rw']
        	addObjectToUcs(inUcsmHost, lsbootPolicyDn, LsbootPolicy.ClassId(), LsbootVirtualMedia.ClassId(), lsbootVirtualMediaList, lsbootVirtualMediaDn)
	pass
dataset/ETHPy150Open Havate/havate-openstack/proto-build/gui/horizon/Horizon_GUI/openstack_dashboard/static-raw/scripts/UcsUtils.py/createLsbootPolicy/original