Search in sources :

Example 1 with CBstringSeq

use of alma.ACS.CBstringSeq in project ACS by ACS-Community.

the class StateChangeListener method createMonitor.

/**
	 * Creates a monitor for <code>statesProperty</code> from this instance.
	 * 
	 * @param statesProperty
	 * @param contSrv
	 * @return  usually not needed
	 * @throws Exception
	 */
public MonitorstringSeq createMonitor(ROstringSeq statesProperty, ContainerServices contSrv) throws Exception {
    this.contSrv = contSrv;
    if (monitor != null) {
        destroyMonitor();
    }
    this.statesProperty = statesProperty;
    // register this callback object with CORBA
    OffShoot offshoot = contSrv.activateOffShoot(this);
    CBstringSeq cbStringSeq = CBstringSeqHelper.narrow(offshoot);
    // register callback CORBA object with the statesProperty as a monitor  
    monitor = statesProperty.create_monitor(cbStringSeq, new CBDescIn());
    // baci.idl: "On creation, the only trigger present will be the timer trigger. 
    // Calling the set_value_trigger method determines the behaviour of the value trigger. 
    // The enable parameter determines whether the value trigger is active or not ." 
    // Strings have no triggerable value, thus don't care 
    monitor.set_value_trigger(new String[0], true);
    // baci.idl: "Timer trigger can be disabled by passing the value 0 for timer parameter." 
    monitor.set_timer_trigger(0);
    return monitor;
}
Also used : OffShoot(alma.ACS.OffShoot) CBDescIn(alma.ACS.CBDescIn) CBstringSeq(alma.ACS.CBstringSeq)

Example 2 with CBstringSeq

use of alma.ACS.CBstringSeq in project ACS by ACS-Community.

the class RequesterUtil method giveCBStringSequence.

/**
	 * 
	 * @param cs
	 * @param x
	 * @return
	 * @throws AcsJContainerServicesEx
	 */
public static CBstringSeq giveCBStringSequence(ContainerServicesBase cs, ResponseReceiver<String[]> x) throws AcsJContainerServicesEx {
    CBstringSeq ret;
    Objects.CBstringSeqImpl cb = new Objects.CBstringSeqImpl(x);
    OffShoot offshoot = cs.activateOffShoot(cb);
    ret = CBstringSeqHelper.narrow(offshoot);
    return ret;
}
Also used : OffShoot(alma.ACS.OffShoot) CBstringSeq(alma.ACS.CBstringSeq)

Aggregations

CBstringSeq (alma.ACS.CBstringSeq)2 OffShoot (alma.ACS.OffShoot)2 CBDescIn (alma.ACS.CBDescIn)1