Files
deb-python-pyvmomi/docs/vim/DatastoreNamespaceManager.rst
Shawn Hartsock 15f7be9a52 pyVmomi reStructured Text Documentation
This external documentation for pyVmomi was generated using Googly Docs
(aka Google Standard Documentation) which renders very cleanly in
GitHub. Internal documentation for a class should be done in Sphinx
format because tools like pyCharm and Eclipse can use that documentation
as a hint for code completion.

Note: External docs as Googly Docs, internal docs as Sphinx.

Closes bug#15
2014-06-17 14:07:42 -04:00

3.6 KiB

vim.DatastoreNamespaceManager

The DatastoreNamespaceManager managed object exposes APIs for manipulating top-level directories of datastores which do not support the traditional top-level directory creation.See topLevelDirectoryCreateSupported

since

vSphere API 5.5

Attributes

Methods

CreateDirectory(datastore, displayName, policy):

Creates a top-level directory on the given datastore, using the given user display name hint and opaque storage policy.The optional given display name hint may be used by the underlying storage system for user display purposes, but it may not be relied upon for future directory references.Clients must use the returned stable path for future directory references.See DeleteDirectory

Privilege:

Datastore.Config

Args:
datastore (vim.Datastore):

datastore on which to create a top-level directorySee DeleteDirectory

displayName (str, optional):

display name hint for the directory to createSee DeleteDirectory

policy (str, optional):

opaque storage policy to associate with the directorySee DeleteDirectory

Returns:
str:

a stable vmfs path which may be used for future reference of the created directory, of the form/vmfs/volumes/[datastore-uuid]/[directory-uuid]

Raises:

vim.fault.CannotCreateFile:

if a general system error occurred while creating directory on the datastoreSee DeleteDirectory

vim.fault.FileAlreadyExists:

if the given directory already existsSee DeleteDirectory

vim.fault.InvalidDatastore:

if the given datastore is not supported by the DatastoreNamespaceManageSee DeleteDirectory

DeleteDirectory(datacenter, datastorePath):

Deletes the given top-level directory from a datastore.The top-level directory must be a full path of the form/vmfs/volumes/[datastore-uuid]/[directory-uuid]as returned by CreateDirectory .See CreateDirectory

Privilege:

Datastore.Config

Args:
datacenter (vim.Datacenter, optional):

The datacenter of the datastore path. Needs to be set when making the call to VC; ignored when the call is made to ESX.See CreateDirectory

datastorePath (str):

Stable vmfs path of the directory to delete.See CreateDirectory

Returns:

None

Raises:

vim.fault.FileFault:

if a generic system error happened.See CreateDirectory

vim.fault.FileNotFound:

if the given directory can not be foundSee CreateDirectory

vim.fault.InvalidDatastore:

if the given datastore is not supported by the DatastoreNamespaceManagerSee CreateDirectory

vim.fault.InvalidDatastorePath:

if the given path is not a top-level directorySee CreateDirectory