I am retrieving data from MySql database as list.My code is When I passed table name it gives list of data based on table name. Now how to create WSDL file to my class.
Below is My code:
@WebService
public class GetEmployeeImpl implements GetEmployee {
EntityManager entityManager = EntityManagerUtil.getEmf().createEntityManager();
@Override
public List getEmployee(String tableName) {
String tableName1=tableName;
Query query = entityManager.createNativeQuery("select name,age from "+tableName1);
List userList =new ArrayList();
try{
userList= query.getResultList();
}
catch(Exception e){
e.printStackTrace();
}
return userList;
}
}