I am trying to search for users based on users LASTNAME. I am getting the following Java Exception.
get(name) not implemented for this datatype
com.opentext.api.LLIllegalOperationException: get(name) not implemented for this
datatype
at com.opentext.api.LLInstance.get(LLInstance.java:77)
at com.opentext.api.LLValue.toValue(LLValue.java:800)
at com.opentext.api.LLConnect.unMarshall(LLConnect.java:303)
at com.opentext.api.LAPI_USERS.ListUserGroup(LAPI_USERS.java:914)
at GetUserInfo.main(GetUserInfo.java:106)
I am not sure where I am doing wrong. I am new to LAPI and any help will be hightly appreciated. I am attaching the code here.
Thanks & Regards,
Satish
########################################################
import com.opentext.api.*;
import java.io.*;
import java.util.*;
public class GetUserInfo
{
private static String Server = "kpvf058.mis.amat.com";
private static int Port = 2099;
private static String DFT = "";
private static String User = "Admin";
private static String Pass = "livelink";
public static void main (String [] args)
{
try
{
//variables
LLSession session;
LAPI_USERS user;
LLValue attribs = new LLValue();
LLValue searchParams = (new LLValue()).setAssoc();
LLValue usersList = new LLValue();
String name, lName;
session = new LLSession (Server, Port, DFT, User, Pass);
user = new LAPI_USERS (session);
searchParams.add("TargetType",LAPI_USERS.SYSTEM);
searchParams.add("SearchType",LAPI_USERS.USER);
searchParams.add("SearchValue","chiluvuri");
searchParams.add("Action",LAPI_USERS.NEXT);
searchParams.add("SearchColumn","LASTNAME");
searchParams.add("SearchOpr","SOUNDSLIKE");
if (user.ListUserGroup( 10, 0, "", 0, searchParams, usersList) != 0)
{
System.out.println("Failed to get User Info");
int ErrorNo = session.getStatus();
String StatusMessage = session.getStatusMessage();
String ErrMsg = session.getErrMsg();
String ApiError = session.getApiError();
System.out.println( "\n Output userInfo -2 -- ErrorNo:" + ErrorNo);
System.out.println( "\n Output userInfo -2 -- StatusMessage:" + StatusMessage);
System.out.println( "\n Output userInfo -2 -- ErrMsg:" + ErrMsg);
System.out.println( "\n Output userInfo -2 -- ApiError:" + ApiError);
}
else
{
System.out.println("Search successful");
System.out.println("The number of users = "+usersList.size());
//lName = attribs.toString("LastName");
//System.out.println(lName);
}
}
catch (Throwable e)
{
System.err.println(e.getMessage() );
e.printStackTrace (System.err);
}
}
}
get(name) not implemented for this datatype
com.opentext.api.LLIllegalOperationException: get(name) not implemented for this
datatype
at com.opentext.api.LLInstance.get(LLInstance.java:77)
at com.opentext.api.LLValue.toValue(LLValue.java:800)
at com.opentext.api.LLConnect.unMarshall(LLConnect.java:303)
at com.opentext.api.LAPI_USERS.ListUserGroup(LAPI_USERS.java:914)
at GetUserInfo.main(GetUserInfo.java:106)
I am not sure where I am doing wrong. I am new to LAPI and any help will be hightly appreciated. I am attaching the code here.
Thanks & Regards,
Satish
########################################################
import com.opentext.api.*;
import java.io.*;
import java.util.*;
public class GetUserInfo
{
private static String Server = "kpvf058.mis.amat.com";
private static int Port = 2099;
private static String DFT = "";
private static String User = "Admin";
private static String Pass = "livelink";
public static void main (String [] args)
{
try
{
//variables
LLSession session;
LAPI_USERS user;
LLValue attribs = new LLValue();
LLValue searchParams = (new LLValue()).setAssoc();
LLValue usersList = new LLValue();
String name, lName;
session = new LLSession (Server, Port, DFT, User, Pass);
user = new LAPI_USERS (session);
searchParams.add("TargetType",LAPI_USERS.SYSTEM);
searchParams.add("SearchType",LAPI_USERS.USER);
searchParams.add("SearchValue","chiluvuri");
searchParams.add("Action",LAPI_USERS.NEXT);
searchParams.add("SearchColumn","LASTNAME");
searchParams.add("SearchOpr","SOUNDSLIKE");
if (user.ListUserGroup( 10, 0, "", 0, searchParams, usersList) != 0)
{
System.out.println("Failed to get User Info");
int ErrorNo = session.getStatus();
String StatusMessage = session.getStatusMessage();
String ErrMsg = session.getErrMsg();
String ApiError = session.getApiError();
System.out.println( "\n Output userInfo -2 -- ErrorNo:" + ErrorNo);
System.out.println( "\n Output userInfo -2 -- StatusMessage:" + StatusMessage);
System.out.println( "\n Output userInfo -2 -- ErrMsg:" + ErrMsg);
System.out.println( "\n Output userInfo -2 -- ApiError:" + ApiError);
}
else
{
System.out.println("Search successful");
System.out.println("The number of users = "+usersList.size());
//lName = attribs.toString("LastName");
//System.out.println(lName);
}
}
catch (Throwable e)
{
System.err.println(e.getMessage() );
e.printStackTrace (System.err);
}
}
}