LightJason / Java-AgentSpeak

LightJason - AgentSpeak(L++) for Java
https://agentspeak-java.lightjason.org
Other
23 stars 7 forks source link

Many general exceptions #59

Closed michalsustr closed 6 years ago

michalsustr commented 6 years ago

There are many places in the code that throw too general exceptions, for example IBaseAgentGenerator throws an Exception in the constructor. These should be better named, maybe with some exception hierarchy (eg LJException -> ParsingException -> InvalidCharacterException or something like that)

flashpixx commented 6 years ago

We are using for exceptions specified exception e.g. runtime errors contains agent and execution context https://github.com/LightJason/AgentSpeak/tree/master/src/main/java/org/lightjason/agentspeak/error

But the general exceptions are not encapsulated by LJ itself, e.g. the AntLR exceptions are passed. So in my opinion we should encapsulate any kind of exception in such a hierarchy. I will took this as an enhancement