我是JADE的新手。我正在尝试在intellij上运行代理,我已经将jade.jar文件添加到模块并检查模块上的导出选项并创建了具有以下特征的运行配置:
关于其余部分,我已将其保留原样。 我还在newPackage包中创建了NewAgent,并使其扩展为jade.core.Agent。尽管如此,当我运行程序时它永远不会工作,总是会出现以下错误:
dez 27, 2017 3:43:19 DA TARDE jade.core.Runtime beginContainer
INFO: ----------------------------------
This is JADE 4.5.0 - revision 6825 of 23-05-2017 10:06:04
downloaded in Open Source, under LGPL restrictions,
at http://jade.tilab.com/
----------------------------------------
dez 27, 2017 3:43:19 DA TARDE jade.imtp.leap.LEAPIMTPManager initialize
INFO: Listening for intra-platform commands on address:
- jicp://192.168.1.3:1099
dez 27, 2017 3:43:19 DA TARDE jade.core.BaseService init
INFO: Service jade.core.management.AgentManagement initialized
dez 27, 2017 3:43:19 DA TARDE jade.core.BaseService init
INFO: Service jade.core.messaging.Messaging initialized
dez 27, 2017 3:43:19 DA TARDE jade.core.BaseService init
INFO: Service jade.core.resource.ResourceManagement initialized
dez 27, 2017 3:43:19 DA TARDE jade.core.BaseService init
INFO: Service jade.core.mobility.AgentMobility initialized
dez 27, 2017 3:43:19 DA TARDE jade.core.BaseService init
INFO: Service jade.core.event.Notification initialized
dez 27, 2017 3:43:19 DA TARDE jade.mtp.http.HTTPServer <init>
INFO: HTTP-MTP Using XML parser com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser
dez 27, 2017 3:43:19 DA TARDE jade.core.messaging.MessagingService boot
INFO: MTP addresses:
http://mbp-de-stefan.home:7778/acc
dez 27, 2017 3:43:19 DA TARDE jade.core.AgentContainerImpl startBootstrapAgents
SEVERE: Cannot create agent agent1: Class newPackage.NewAgent for agent ( agent-identifier :name agent1@192.168.1.3:1099/JADE ) not found - Caused by: newPackage.NewAgent
dez 27, 2017 3:43:19 DA TARDE jade.core.AgentContainerImpl joinPlatform
INFO: --------------------------------------
Agent container Main-Container@192.168.1.3 is ready.
--------------------------------------------
我认为只有在我创建项目并在Intellij上运行时才会发生这种情况。如果我在Eclipse上创建相同的项目,我在Eclipse上运行项目,一切运行正常。为什么会这样?