Based on Holger answer (thank you very much) and my tests I resolved this issue.
Step 1: list of all adapter services
WmART → pub.art.service:listAdapterServices (this method takes only one input parameter - adapterTypeName. If you don’t know the name you may use pub.art:listRegisteredAdapters method to find it)
Step 2: loop over list of adapter services
LOOP
Step 3: prepare path to node.ndf file (java service) (input params: nodeName, packageName from current iteration of loop)
public static final void preparePath(IData pipeline) throws ServiceException {
// pipeline
IDataCursor pipelineCursor = pipeline.getCursor();
String nodeName = IDataUtil.getString( pipelineCursor, "nodeName" );
String packageName = IDataUtil.getString( pipelineCursor, "packageName" );
pipelineCursor.destroy();
//convert : and . to /
String adapterPath = nodeName.replace(".", "/");
String adapterPath2 = replace.replace(":", "/");
//create relative path - recommended
String path = "packages/" + packageName + "/ns/" + adapterPath2 + "/node.ndf";
//version to fullpath, not recommended because of possibility of different IS and OS settings
//String path = "E:/SoftwareAG/IntegrationServer/instances/default/packages/" + packageName + "/ns/" + adapterPath2 + "/node.ndf";
// pipeline out
IDataCursor pipelineCursor_1 = pipeline.getCursor();
IDataUtil.put( pipelineCursor_1, "path", path );
pipelineCursor_1.destroy();
}
Step 4: WmPublic → pub.file:getFile (input parameter: loadAs → String)
Step 5: convert string to xml
WmPublic → pub.xml.xmlStringToXMLNode
Step 6: find IRTNODE_PROPERTY node in xml
WmPublic → pub.xml.queryXMLNode
(input parameters: node → from step 5 node, fields: name → myVariable, resultType → String, query → /Values/value[@name=‘IRTNODE_PROPERTY’], queryType → XQL
Step 7: decode base64 token
WmPublic → pub.string.base64Decode
Step 8: convert to string
WmPublic → pub.string.bytesToString
Step 9: clear string from non-letters (java service)
public static final void clearString(IData pipeline) throws ServiceException {
// pipeline
IDataCursor pipelineCursor = pipeline.getCursor();
String inputStr = IDataUtil.getString( pipelineCursor, "inputStr" );
pipelineCursor.destroy();
StringBuffer sb = new StringBuffer();
//loop over all char in string
for(int i = 0; i < inputStr.length(); i++){
boolean isLett = Character.isLetter(inputStr.charAt(i));
//if is a letter -> append to string buffer object
if (isLett)
sb.append(inputStr.charAt(i));
}
String outputStr = null;
//search "CustomSQL" in string
if (sb.toString().indexOf("CustomSQL") > 0 ){
outputStr = "1";
}else{
outputStr = "0";
}
// pipeline
IDataCursor pipelineCursor_1 = pipeline.getCursor();
IDataUtil.put( pipelineCursor_1, "outputStr", outputStr );
pipelineCursor_1.destroy();
}
Step 10: branch on step 9 result. if outputStr == 1 → append to string list (or document list).
END LOOP
Thats all! Ten steps “only” for listing CustomSQL adapter services.