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
12 replies
Subscribers
7 subscribers
Views
5011 views
Users
0 members are here
Share
More
Cancel
Related Discussions
Home
»
Discussions
»
Integrations
Hi Guys, is there a way to call an Appian function within my Java Code (Smart Se
Jess
over 9 years ago
Hi Guys, is there a way to call an Appian function within my Java Code (Smart Service Plugin)? I need to use todocument() function to convert the input string (ex. "[DocumentId: xxxx]" ) to a document.
Also, once I got the document, I need to get the server path/filename of that file.
Thanks in advance!
OriginalPostID-192788
OriginalPostID-192788
Discussion posts and replies are publicly visible
Parents
0
Jess
over 9 years ago
Hi rahul, please advise if the contentService can only work if passed as a parameter to the constructor:
ex.
public GoogleCalendarCreateEvent(SmartServiceContext smartServiceCtx, ContentService contentService) {
super();
this.smartServiceCtx = smartServiceCtx;
this.contentService = contentService;
}
coz, currently I'm using it on a separate class that I'm calling on the run() method of the smart service class and it seems that the code below returns null.
doc = this.contentService.download(documentId, ContentConstants.VERSION_CURRENT, Boolean.FALSE)[0];
Thanks in advance!
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
Reply
0
Jess
over 9 years ago
Hi rahul, please advise if the contentService can only work if passed as a parameter to the constructor:
ex.
public GoogleCalendarCreateEvent(SmartServiceContext smartServiceCtx, ContentService contentService) {
super();
this.smartServiceCtx = smartServiceCtx;
this.contentService = contentService;
}
coz, currently I'm using it on a separate class that I'm calling on the run() method of the smart service class and it seems that the code below returns null.
doc = this.contentService.download(documentId, ContentConstants.VERSION_CURRENT, Boolean.FALSE)[0];
Thanks in advance!
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
Children
No Data