First one is better than second one.
You are defining your own message accessing methods even though there is already similar method in Exception Class. Normally exception messages are available during the creation of the exception message.
Further to that it requires the code that is catching this exception to be tightly coupled with this code meaning it needs to know how to get the message. In situation where this exception is caught by default handler such as JVM which called main method wont be able to show the message.
Second option has it's benefit as well but you should use it only when required for example you need to set the message down the exception chain.
catch(ParserException ex){
String rootMessage = ex.getExpMsg();
ex.setExpMsg(rootMessage + "SOME EXTRA DATA");
throw ex ;
}
I wish other will contribute as well in this topic ..