GetReference () Deprecation
Author: vasanth
Publication Date: 2/10/2017 15:13
Hello Team,
We are migration from FS 5.1.507 to FS 5.2.611, in the module we have geca.getData ().getReferences () which is deprecated and now we need to replace it with code. But the module has doing some operation and finally the setting new reference in to the reference object.
How to achieve the setReferencedObject () in the new api ??
for (GCAPage gcaPage : gcaPages) {
Reference[] references = gcaPage.getData().getReferences();
if (references != null && references.length != 0) {
for (Reference ref : references) {
reference.setReferencedObject(new Object ());
}
}
}
Tags: deprecated, getreference
-
Author: MarsDD - 2/15/2017 8:14
Hi,
use this one
References[] references = gcaPage.getIncomingReferences();
for(Reference ref : references){
// ...
}
Best regards,
Marcel
0 -
Author: vasanth - 2/15/2017 8:20
Hello Mr. Marcel Liebgott
I already tried it is not working. getIncomingReferences will return the GCA's references but the data's references.
Regards,
Vasandharaj M.
0 -
Author: zeus83 - 2/15/2017 10:52
Hi,
I'm not a professional but in the documentation stands:
getData() Deprecated since 4.2.440 - use getFormData() instead.
Reference[] references = gcaPage.getData()getFormData.getReferences();
The references you can call directly:
Reference[] references = gcaPage.getReferences();
I hope it helps :smileyhappy:
Best regards,
Ahmad
0 -
Author: vasanth - 2/15/2017 11:23
Hello Ahmad,
The API clearly mentioned that its referenceEntry not the Reference. Anyway i am looking to FormData to get the reference. will let you know once i found the way for this.
Set<ReferenceEntry> refSet = gca.getReferences();
0 -
Author: tenter - 3/1/2017 12:59
Hi,
since the new API seems to not provide the methods you need anymore, did you find a solution for your problem already?
Best regards,
Hanes
0
Please sign in to leave a comment.
Comments
5 comments