Appian Community
Site
Search
Sign In/Register
Site
Search
User
DISCUSS
LEARN
SUCCESS
SUPPORT
Documentation
AppMarket
More
Cancel
I'm looking for ...
State
Not Answered
Replies
3 replies
Subscribers
5 subscribers
Views
1486 views
Users
0 members are here
Share
More
Cancel
Related Discussions
Home
»
Discussions
»
Integrations
I'm trying to write a plugin which could call Appian API which take CDT as p
pingc
over 8 years ago
I'm trying to write a plugin which could call Appian API which take CDT as parameter by using processDesignService.initiateProcess, referencing a library typetransformer-1.2.jar
I had the following exception(Log attached):
RROR com.appiancorp.suiteapi.common.TypedValueParameterConverter - unable to access property <value> in <class com.appiancorp.suiteapi.process.ProcessVariable>
Main logic Code :
//Appian CDT Type
if (processInstanceType.intValue() >= 500) {
String cdtType = ts.getType(
processVariable.getInstanceType()).getName();
String cdtNameSpace = ts.getType(
processVariable.getInstanceType()).getNamespace();
System.out.println("cdtNameSpace: "
+ cdtNameSpace);
System.out.println("cdtType: "
+ cdtType);
Datatype type = ts.getTypeByQualifiedName(new QName(
cdtNameSpace,cdtType));
AppianObject account = (AppianObject) tf.createElement(type
.getId());
...
plugin.log
OriginalPostID-171467
OriginalPostID-171467
Discussion posts and replies are publicly visible
Parents
0
pingc
over 8 years ago
... account.put("accountNumber_txt",
tf.createString("900900900"));
account.put("name_txt", tf.createString("Ping"));
System.out.println("account: "+account.toString());
TypedValue tv = tf.toTypedValue(account);
System.out.println("typedvalue for account: "+ tv);
NamedTypedValue ntv = new NamedTypedValue(tv,"account_cdt");
System.out.println("namedtypedvalue for account: "+ ntv);
pvi = new ProcessVariableInstance(ntv);
}
System.out.println("Process Parameters Length:"
+ processParameters.length);
//ProcessStartConfig processStartConfig = getProcessStarterConfig(processParameters);
ProcessStartConfig processStartConfig = getProcessStarterConfig(new ProcessVariable[]{pvi});
processId = processDesignService.initiateProcess(modelId,
processStartConfig);
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
Reply
0
pingc
over 8 years ago
... account.put("accountNumber_txt",
tf.createString("900900900"));
account.put("name_txt", tf.createString("Ping"));
System.out.println("account: "+account.toString());
TypedValue tv = tf.toTypedValue(account);
System.out.println("typedvalue for account: "+ tv);
NamedTypedValue ntv = new NamedTypedValue(tv,"account_cdt");
System.out.println("namedtypedvalue for account: "+ ntv);
pvi = new ProcessVariableInstance(ntv);
}
System.out.println("Process Parameters Length:"
+ processParameters.length);
//ProcessStartConfig processStartConfig = getProcessStarterConfig(processParameters);
ProcessStartConfig processStartConfig = getProcessStarterConfig(new ProcessVariable[]{pvi});
processId = processDesignService.initiateProcess(modelId,
processStartConfig);
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
Children
No Data