cn.chenlichao.wmi4j
类 SWbemEventSource

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

public class SWbemEventSource
extends AbstractSecurityScriptingObject

Retrieves events from an event query in conjunction with SWbemServices.execNotificationQuery(). You get an SWbemEventSource object if you make a call to SWbemServices.execNotificationQuery(). to make an event query. You can then use the nextEvent(java.lang.Long) method to retrieve events as they arrive. Created by chenlichao on 14-7-23.


方法摘要
 SWbemObject nextEvent(Long timeoutMs)
          If an event is available, the nextEvent method retrieves the event from an event query.
 
从类 cn.chenlichao.wmi4j.AbstractSecurityScriptingObject 继承的方法
getSecurity
 
从类 java.lang.Object 继承的方法
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

方法详细信息

nextEvent

public SWbemObject nextEvent(Long timeoutMs)
                      throws WMIException
If an event is available, the nextEvent method retrieves the event from an event query.

参数:
timeoutMs - [Optional] Number of milliseconds the call waits for an event before returning a time-out error. The default value for this parameter is -1, which directs the call to wait indefinitely.
返回:
If successful, it returns an SWbemObject object that contains the requested event. If the call times out, the returned object is NULL and an error is raised.
抛出:
WMIException


Copyright © 2014. All rights reserved.