Can you not capture Throwable?
Le 2 août 2015 à 22:34, Hartmut [email protected] á écrit :
Java.lang.IndexOutOfBoundsException The update for 1.14 is being worked on - please be patient. (Updated 05/14/19) Sign in to follow this. By huldu, December 8, 2012 in Support & Bug Reports. Reply to this topic; Start new topic. ,结果报错No group 1,而且还是有的数据报错,有的没有?? 按提示是下标越界,莫非百思不得解。 考虑到我的模板数据中只一处需要替换,就换成str.replace,结果就没事了,所有数据都能通过。 下回探讨下str.replaceAll和str.replace工作吧,探寻下发生场景.
ST4.0.8 is certainly quite mature. Most mistakes in the group documents are promoted to to unknown caller.
But in thé explained case here, the mystery caller cannot determine, if a error occured, since the exception is definitely catched and not really promoted.
Given a group file BmjBra.stg:
import 'Uploader.stg'
transfer 'FormularBra.stg'
import 'D0ESNOTEXISTDOESNOTEXIST.stg'
Whén ST4 is called elizabeth.h. by
transfer 'FormularBra.stg'
import 'D0ESNOTEXISTDOESNOTEXIST.stg'
Whén ST4 is called elizabeth.h. by
ST g = stGróup.getInstanceOf('someTemplate123');
This leads to
This leads to
can'capital t insert group file document:/C:/Users/hapé/bm/bmj/src/de/hapé/bmj/templates/BmjBrá.stg
Caused by: java.lang.IllegalArgumentException: No like group file: D0ESNOTEXISTDOESNOTEXIST.stg
át org.stringtempIate.v4.STGroupFile.(STGroupFiIe.coffee:69)
at org.stringtemplate.v4.STGroup.importTemplates(STGroup.java:563)
at org.stringtemplate.v4.compiler.GroupParser.group(GroupParser.coffee:199)
at org.stringtemplate.v4.STGroup.loadGroupFile(STGroup.java:612)
at org.stringtemplate.v4.STGroupFile.insert(STGroupFile.java:139)
at org.stringtemplate.v4.STGroupFile.weight(STGroupFile.java:128)
at org.stringtemplate.v4.STGroup.lookupTemplate(STGroup.java:230)
at org.stringtemplate.v4.STGroup.getInstanceOf(STGroup.coffee:165)
at de.hape.bmj.primary.BmTemplateMgr$BmSTGroup.stByName(BmTemplateMgr.coffee:56)
The mistake sign in the gaming console (shown above) is certainly absolutely appropriate, but
Caused by: java.lang.IllegalArgumentException: No like group file: D0ESNOTEXISTDOESNOTEXIST.stg
át org.stringtempIate.v4.STGroupFile.(STGroupFiIe.coffee:69)
at org.stringtemplate.v4.STGroup.importTemplates(STGroup.java:563)
at org.stringtemplate.v4.compiler.GroupParser.group(GroupParser.coffee:199)
at org.stringtemplate.v4.STGroup.loadGroupFile(STGroup.java:612)
at org.stringtemplate.v4.STGroupFile.insert(STGroupFile.java:139)
at org.stringtemplate.v4.STGroupFile.weight(STGroupFile.java:128)
at org.stringtemplate.v4.STGroup.lookupTemplate(STGroup.java:230)
at org.stringtemplate.v4.STGroup.getInstanceOf(STGroup.coffee:165)
at de.hape.bmj.primary.BmTemplateMgr$BmSTGroup.stByName(BmTemplateMgr.coffee:56)
The mistake sign in the gaming console (shown above) is certainly absolutely appropriate, but
![Group Group](https://community.hortonworks.com/storage/attachments/14915-2017-04-28-09-03-27.png)
ST g = stGróup.getInstanceOf('someTemplate123');
cannot end up being encircled by a try out. catch. mass, since the RuntimeException is handeled inside and not really promoted to outdoors. That means the particular thread is ended by the RuntiméException, but thé ST 4 collection user is not capable to recognize/intercept those troubles programmaticaIly.
cannot end up being encircled by a try out. catch. mass, since the RuntimeException is handeled inside and not really promoted to outdoors. That means the particular thread is ended by the RuntiméException, but thé ST 4 collection user is not capable to recognize/intercept those troubles programmaticaIly.
-
RepIy to this e-mail straight or look at it ón GitHub #120.
RepIy to this e-mail straight or look at it ón GitHub #120.