Genesys CTI User Forum
Genesys CTI User Forum => Genesys-related Development => Topic started by: nikhiltrivedi84 on February 19, 2016, 05:27:30 PM
-
I am new to using genesys apis. I am trying to use ConfService APIs to access transactions. The issue I am facing is while creating confservice, I am getting a compile error on the ConfServiceFactory.createConfService(protocol) line.
Endpoint cfgServerEndpoint =
new Endpoint(cfgsrvEndpointName, cfgsrvHost, cfgsrvPort);
ConfServerProtocol protocol = new ConfServerProtocol(cfgServerEndpoint);
protocol.setClientName(clientName);
protocol.setClientApplicationType(clientType.ordinal());
protocol.setUserName(username);
protocol.setUserPassword(password);
[i] IConfService service = ConfServiceFactory.createConfService(protocol)[/i]
I am using Genesys Platform SDK 8.0.
Regards
Nikhs
-
These are the imports.
import com.genesyslab.platform.applicationblocks.com.IConfService;
import com.genesyslab.platform.applicationblocks.com.ConfServiceFactory;
import com.genesyslab.platform.applicationblocks.com.ConfigException;
import com.genesyslab.platform.configuration.protocol.types.CfgAppType;
import com.genesyslab.platform.configuration.protocol.ConfServerProtocol;
import com.genesyslab.platform.commons.protocol.ChannelState;
import com.genesyslab.platform.commons.protocol.Endpoint;
import com.genesyslab.platform.commons.protocol.ProtocolException;
-
Try something like this:
protocol = new ConfServerProtocol(cfgServerEndpoint);
protocol.setClientApplicationType(CfgAppType.CFGSCE.asInteger());
protocol.setClientName("default");
protocol.setUserName(username);
protocol.setUserPassword(password);
[i]ConfService confservice = (ConfService) ConfServiceFactory.createConfService(protocol);[/i]
-
It gives me same compilation error. It says "Add argument .......". I think it requires SubScriptionService<message>. What should that do? The confservice sample does not have that.
-
that's strange... It compiles fine here with this.
My imports are:
import com.genesyslab.platform.applicationblocks.com.*;
import com.genesyslab.platform.configuration.protocol.*;
import com.genesyslab.platform.configuration.protocol.types.*;
import com.genesyslab.platform.commons.protocol.*;
-
You're using an old version of the Platform SDK that requires EventBrokerService (EventBrokerService is a subclass of SubscriptionService).. 8.1 has it, 8.5 doesn't
-
James, Do you know how to accomplish this in 8.1 version? The code snippet is shown in below. Let me know what is wrong with it. Appreciate your help.