0

如果我想使用 Agile 中的 API 功能与 Eclipse Jee Neon 进行交互。我怎么可能这样做。为了创建此链接,我必须在 Eclipse 中执行哪些步骤。我究竟做错了什么?我应该在哪里寻找?

4

1 回答 1

0

您必须为您要连接的 Agile PLM 版本添加对 AgileAPI.jar 文件的引用。然后使用样板文件创建到敏捷实例的连接,例如入门指南中所引用的:

private IAgileSession login(String username, String password) throws APIException 
{
    //Create the params variable to hold login parameters
    HashMap params = new HashMap();

    //Put username and password values into params          
    params.put(AgileSessionFactory.USERNAME, username);
    params.put(AgileSessionFactory.PASSWORD, password);

    // Get an Agile server instance. ("agileserver" is the name of the Agile     
    // proxy server, and "virtualPath" is the name of the virtual path used 
    // for the Agile system.)

    AgileSessionFactory instance =
        AgileSessionFactory.getInstance("http://<agileserver>/<virtualPath>");

    //Create the Agile PLM session and log in
    return instance.createSession(params);
}
于 2016-07-29T21:28:04.973 回答