/**
  * Invoke the action asynchronously. Returns immediately and will run the client-specified
  * callback when the action later completes. Any output arguments can then be retrieved by calling
  * {@link #endTime}.
  *
  * @param aCallback listener to call back when action completes. This is guaranteed to be run but
  *     may indicate an error.
  */
 public void beginTime(ICpProxyListener aCallback) {
   Invocation invocation = iService.getInvocation(iActionTime, aCallback);
   int outIndex = 0;
   invocation.addOutput(
       new ArgumentUint((ParameterUint) iActionTime.getOutputParameter(outIndex++)));
   invocation.addOutput(
       new ArgumentUint((ParameterUint) iActionTime.getOutputParameter(outIndex++)));
   invocation.addOutput(
       new ArgumentUint((ParameterUint) iActionTime.getOutputParameter(outIndex++)));
   iService.invokeAction(invocation);
 }
  /**
   * Constructor. Use {@link #subscribe}/{@link #unsubscribe} to enable/disable querying of state
   * variable and reporting of their changes.
   *
   * @param aDevice the device to use.
   */
  public CpProxyAvOpenhomeOrgTime1(CpDevice aDevice) {
    super("av-openhome-org", "Time", 1, aDevice);
    Parameter param;

    iActionTime = new Action("Time");
    param = new ParameterUint("TrackCount");
    iActionTime.addOutputParameter(param);
    param = new ParameterUint("Duration");
    iActionTime.addOutputParameter(param);
    param = new ParameterUint("Seconds");
    iActionTime.addOutputParameter(param);

    iTrackCountChanged = new PropertyChangeListener();
    iTrackCount =
        new PropertyUint(
            "TrackCount",
            new PropertyChangeListener() {
              public void notifyChange() {
                trackCountPropertyChanged();
              }
            });
    addProperty(iTrackCount);
    iDurationChanged = new PropertyChangeListener();
    iDuration =
        new PropertyUint(
            "Duration",
            new PropertyChangeListener() {
              public void notifyChange() {
                durationPropertyChanged();
              }
            });
    addProperty(iDuration);
    iSecondsChanged = new PropertyChangeListener();
    iSeconds =
        new PropertyUint(
            "Seconds",
            new PropertyChangeListener() {
              public void notifyChange() {
                secondsPropertyChanged();
              }
            });
    addProperty(iSeconds);
    iPropertyLock = new Object();
  }
 /**
  * Dispose of this control point proxy. Must be called for each class instance. Must be called
  * before <tt>Library.close()</tt>.
  */
 public void dispose() {
   synchronized (this) {
     if (iHandle == 0) {
       return;
     }
     disposeProxy();
     iHandle = 0;
     iActionTime.destroy();
     iTrackCount.destroy();
     iDuration.destroy();
     iSeconds.destroy();
   }
 }