com.splunk
Class WindowsWmiInput

java.lang.Object
  extended by com.splunk.Resource
      extended by com.splunk.Entity
          extended by com.splunk.Input
              extended by com.splunk.WindowsWmiInput
All Implemented Interfaces:
java.util.Map<java.lang.String,java.lang.Object>

public class WindowsWmiInput
extends Input

The WindowsWmiInput class represents a Windows Management Instrumentation (WMI) data input.


Nested Class Summary
 
Nested classes/interfaces inherited from interface java.util.Map
java.util.Map.Entry<K,V>
 
Field Summary
 
Fields inherited from class com.splunk.Entity
toUpdate
 
Fields inherited from class com.splunk.Resource
actions, path, refreshArgs, service, title
 
Method Summary
 java.lang.String getClasses()
          Returns the WMI class name of this WMI input.
 java.lang.String[] getFields()
          Returns the properties (fields) collected for this class for this WMI input.
 java.lang.String getIndex()
          Returns the index name of this WMI input.
 java.lang.String[] getInstances()
          Returns a list of the WMI class instances for this WMI input.
 int getInterval()
          Returns the interval at which WMI input providers are queried for this WMI input.
 InputKind getKind()
          Returns the input kind of this input.
 java.lang.String getLocalName()
          Returns the collection name for this WMI input.
 java.lang.String getLookupHost()
          Returns the main server for this WMI input.
 java.lang.String getServers()
          Returns a list of secondary servers used for monitoring.
 java.lang.String getWql()
          Returns the query string for this WMI input.
 void setClasses(java.lang.String classes)
          Sets the WMI class name.
 void setDisabled(boolean disabled)
          Sets whether this input is enabled or disabled.
 void setFields(java.lang.String field)
          Sets a property (field) that you want to gather from the given class.
 void setFields(java.lang.String[] fields)
          Sets the properties (fields) that you want to gather from the given class.
 void setIndex(java.lang.String index)
          Sets the index in which to store all generated events.
 void setInstances(java.lang.String instance)
          Sets a counter instance to monitor.
 void setInstances(java.lang.String[] instances)
          Sets the counter instances to monitor.
 void setInterval(int interval)
          Sets the frequency at which the WMI providers are queried.
 void setLookupHost(java.lang.String lookup_host)
          Sets the main server from which to monitor log events.
 void setServers(java.lang.String servers)
          Sets secondary servers that you want to gather data from.
 void update()
          Updates the entity with the accumulated arguments, established by the individual setter methods for each specific entity class.
 void update(java.util.Map<java.lang.String,java.lang.Object> args)
          Updates the entity with the values you previously set using the setter methods, and any additional specified arguments.
 
Methods inherited from class com.splunk.Entity
actionPath, clear, containsKey, containsValue, disable, enable, entrySet, get, getMetadata, isDisabled, isEmpty, isNameChangeAllowed, keySet, put, putAll, refresh, remove, remove, size, validate, values
 
Methods inherited from class com.splunk.Resource
getName, getPath, getService, getTitle, invalidate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.Map
equals, hashCode
 

Method Detail

getClasses

public java.lang.String getClasses()
Returns the WMI class name of this WMI input.

Returns:
The WMI class name.

getFields

public java.lang.String[] getFields()
Returns the properties (fields) collected for this class for this WMI input.

Returns:
The list of properties collected for this class, or null if not specified.

getIndex

public java.lang.String getIndex()
Returns the index name of this WMI input.

Returns:
The index name, or null if not specified.

getInstances

public java.lang.String[] getInstances()
Returns a list of the WMI class instances for this WMI input.

Returns:
A list of the WMI class instances, or null if not specified.

getInterval

public int getInterval()
Returns the interval at which WMI input providers are queried for this WMI input.

Returns:
The WMI query interval, in seconds.

getKind

public InputKind getKind()
Returns the input kind of this input.

Overrides:
getKind in class Input
Returns:
The input kind.

getLookupHost

public java.lang.String getLookupHost()
Returns the main server for this WMI input. To list secondary servers, use the getServers method.

Returns:
The main server.
See Also:
getServers()

getLocalName

public java.lang.String getLocalName()
Returns the collection name for this WMI input. This name appears in configuration file, the source, and the sourcetype of the indexed data.

Returns:
The collection name.

getServers

public java.lang.String getServers()
Returns a list of secondary servers used for monitoring. To list the main server, use the getLookupHost method.

Returns:
A comma-separated list of additional servers, or null if not specified.
See Also:
getLookupHost()

getWql

public java.lang.String getWql()
Returns the query string for this WMI input.

Returns:
The query string.

setClasses

public void setClasses(java.lang.String classes)
Sets the WMI class name.

Parameters:
classes - A valid WMI class name.

setDisabled

public void setDisabled(boolean disabled)
Sets whether this input is enabled or disabled.

Note: Using this method requires you to restart Splunk before this setting takes effect. To avoid restarting Splunk, use the Entity.disable and Entity.enable methods instead, which take effect immediately.

Parameters:
disabled - true to disable this input, false to enable it.

setFields

public void setFields(java.lang.String[] fields)
Sets the properties (fields) that you want to gather from the given class.

Parameters:
fields - An array of properties (fields) to gather.

setFields

public void setFields(java.lang.String field)
Sets a property (field) that you want to gather from the given class. Use this method to set a single field rather than an array.

Parameters:
field - A property (field) to gather.

setIndex

public void setIndex(java.lang.String index)
Sets the index in which to store all generated events.

Parameters:
index - The index name.

setInstances

public void setInstances(java.lang.String[] instances)
Sets the counter instances to monitor.

Parameters:
instances - The counter instances to monitor.

setInstances

public void setInstances(java.lang.String instance)
Sets a counter instance to monitor. Use this method to set a single instance rather than an array.

Parameters:
instance - A counter instance to monitor.

setInterval

public void setInterval(int interval)
Sets the frequency at which the WMI providers are queried.

Parameters:
interval - The polling frequency, in seconds.

setLookupHost

public void setLookupHost(java.lang.String lookup_host)
Sets the main server from which to monitor log events. To specify additional servers to monitor using WMI, use the setServers method.

Parameters:
lookup_host - The main server.
See Also:
setServers(java.lang.String)

setServers

public void setServers(java.lang.String servers)
Sets secondary servers that you want to gather data from. Use this method if you need to gather more than a single server. To specify the main server, use the setLookupHost method.

Parameters:
servers - A comma-separated list of additional servers.
See Also:
setLookupHost(java.lang.String)

update

public void update(java.util.Map<java.lang.String,java.lang.Object> args)
Updates the entity with the values you previously set using the setter methods, and any additional specified arguments. The specified arguments take precedent over the values that were set using the setter methods.

Overrides:
update in class Entity
Parameters:
args - The arguments to update.

update

public void update()
Updates the entity with the accumulated arguments, established by the individual setter methods for each specific entity class.

Overrides:
update in class Entity