cn.chenlichao.wmi4j
类 SWbemObjectPath

java.lang.Object
  继承者 cn.chenlichao.wmi4j.AbstractSecurityScriptingObject
      继承者 cn.chenlichao.wmi4j.SWbemObjectPath

public class SWbemObjectPath
extends AbstractSecurityScriptingObject

Use the methods and properties of the SWbemObjectPath object to construct and validate an object path.

Created by chenlichao on 14-7-26.


方法摘要
 String getAuthority()
          Get the Authority component of the object path.
 String getClazz()
          Get the name of the class that is part of the object path.
 String getDisplayName()
          Get the path in a form that can be used as a moniker display name.
 SWbemNamedValueSet getKeys()
          Get an SWbemObjectSet object that contains the key value bindings.
 String getLocale()
          The Locale property of the SWbemObjectPath object contains the locale of object path.
 String getNamespace()
          Get the name of the namespace that is part of the object path.
 String getParentNamespace()
          Get the name of the parent namespace that is part of the object path.
 String getPath()
          Get the absolute path.
 String getRelPath()
          Get the relative path from the complete path.
 String getServer()
          Get the name of the server that is part of the object path.
 boolean isClass()
          Indicates if this path represents a class.
 boolean isSingleton()
          Indicates if this path represents a singleton instance.
 void setAsClass()
          Forces the path to address a WMI class.
 void setAsSingleton()
          Forces the path to address a singleton WMI instance of a class.
 void setAuthority(String authority)
          Set the Authority component of the object path.
 void setClass(String className)
          Set the name of the class that is part of the object path.
 void setDisplayName(String displayName)
          Set the path in a form that can be used as a moniker display name.
 void setLocale(String locale)
          Set the locale of object path.
 void setNamespace(String namespace)
          Set the name of the namespace that is part of the object path.
 void setPath(String path)
          Set the absolute path.
 void setRelPath(String relPath)
          Set the relative path from the complete path.
 void setServer(String server)
          Set the name of the server that is part of the object path.
 
从类 cn.chenlichao.wmi4j.AbstractSecurityScriptingObject 继承的方法
getSecurity
 
从类 java.lang.Object 继承的方法
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

方法详细信息

setAsClass

public void setAsClass()
                throws WMIException
Forces the path to address a WMI class.

抛出:
WMIException

setAsSingleton

public void setAsSingleton()
                    throws WMIException
Forces the path to address a singleton WMI instance of a class. A singleton class is a class that can never have more than one instance.

抛出:
WMIException

getAuthority

public String getAuthority()
                    throws WMIException
Get the Authority component of the object path.

返回:
the Authority component of the object path.
抛出:
WMIException

setAuthority

public void setAuthority(String authority)
                  throws WMIException
Set the Authority component of the object path.

参数:
authority - the Authority component of the object path.
抛出:
WMIException

getClazz

public String getClazz()
                throws WMIException
Get the name of the class that is part of the object path.

返回:
the name of the class that is part of the object path.
抛出:
WMIException

setClass

public void setClass(String className)
              throws WMIException
Set the name of the class that is part of the object path.

参数:
className - the name of the class that is part of the object path.
抛出:
WMIException

getDisplayName

public String getDisplayName()
                      throws WMIException
Get the path in a form that can be used as a moniker display name.

返回:
the path in a form that can be used as a moniker display name.
抛出:
WMIException

setDisplayName

public void setDisplayName(String displayName)
                    throws WMIException
Set the path in a form that can be used as a moniker display name.

参数:
displayName - the path in a form that can be used as a moniker display name.
抛出:
WMIException

isClass

public boolean isClass()
                throws WMIException
Indicates if this path represents a class. This property is read-only.

返回:
True if this path represents a class, otherwise return false.
抛出:
WMIException

isSingleton

public boolean isSingleton()
                    throws WMIException
Indicates if this path represents a singleton instance. A singleton instance is an instance of a class that can never have more than one instance. This property is read-only.

返回:
True if this path represents a singleton instance, otherwise return false.
抛出:
WMIException

getKeys

public SWbemNamedValueSet getKeys()
                           throws WMIException
Get an SWbemObjectSet object that contains the key value bindings. This property is read-only.

返回:
an SWbemObjectSet object that contains the key value bindings.
抛出:
WMIException

getLocale

public String getLocale()
                 throws WMIException
The Locale property of the SWbemObjectPath object contains the locale of object path.

When the locale property is part of a standalone SWbemObjectPath object, it is read/write and can be used to set the locale component of the moniker.

When the locale property is accessed as part of a SWbemObject.getPath() property, it is read-only and reports the value of the locale used in binding to the namespace from which the object was obtained.

For Microsoft locale identifiers, the format of the string is "MS_xxxx", where xxxx is a string in hexadecimal form that indicates the LCID. For example, the American English locale identifier is "MS_409".

返回:
the locale of object path.
抛出:
WMIException

setLocale

public void setLocale(String locale)
               throws WMIException
Set the locale of object path.

When the locale property is accessed as part of a SWbemObject.getPath() property, it is read-only and reports the value of the locale used in binding to the namespace from which the object was obtained.

参数:
locale - the locale of object path.
抛出:
WMIException

getNamespace

public String getNamespace()
                    throws WMIException
Get the name of the namespace that is part of the object path. For example, the following path shows the namespace property that returns root\cimv2:
\\computer\root\cimv2:win32_logicaldisk="a:"

返回:
the name of the namespace that is part of the object path.
抛出:
WMIException

setNamespace

public void setNamespace(String namespace)
                  throws WMIException
Set the name of the namespace that is part of the object path.

参数:
namespace - the name of the namespace that is part of the object path.
抛出:
WMIException

getParentNamespace

public String getParentNamespace()
                          throws WMIException
Get the name of the parent namespace that is part of the object path. This property is read-only.

返回:
the name of the parent namespace that is part of the object path.
抛出:
WMIException

getPath

public String getPath()
               throws WMIException
Get the absolute path.

返回:
the absolute path.
抛出:
WMIException

setPath

public void setPath(String path)
             throws WMIException
Set the absolute path.

参数:
path - the absolute path.
抛出:
WMIException

getRelPath

public String getRelPath()
                  throws WMIException
Get the relative path from the complete path.

返回:
the relative path from the complete path.
抛出:
WMIException

setRelPath

public void setRelPath(String relPath)
                throws WMIException
Set the relative path from the complete path.

参数:
relPath - the relative path from the complete path.
抛出:
WMIException

getServer

public String getServer()
                 throws WMIException
Get the name of the server that is part of the object path.

返回:
the name of the server that is part of the object path.
抛出:
WMIException

setServer

public void setServer(String server)
               throws WMIException
Set the name of the server that is part of the object path.

参数:
server - the name of the server that is part of the object path.
抛出:
WMIException


Copyright © 2014. All rights reserved.