Merge branch 'master_16.2.1' into master_16.2.1-lx

Former-commit-id: c2912e8f8c98c1e7a4b97fc431db7f054452425a
This commit is contained in:
Shawn.Hooper 2016-05-03 13:51:27 -04:00
commit 6dd7d6e445
2 changed files with 9 additions and 4 deletions

View file

@ -39,11 +39,11 @@
<substitute key="negOffset" value="60"/>
<substitute key="binRepeatCount" value="5"/>
</contribute>
<contribute xsi:type="bundleItem" file="bundles/TotalLightningPlot.xml"
<contribute xsi:type="bundleItem" file="bundles/LightningPlot.xml"
menuText="1min plot" id="1MinLightningStrokePlot">
<substitute key="negOffset" value="60"/>
</contribute>
<contribute xsi:type="bundleItem" file="bundles/LightningSeq.xml"
menuText="1min Lgtng Seq" id="1MinLightningStrokeSeq">
menuText="1min Lgtng Seq Plot" id="1MinLightningStrokeSeq">
</contribute>
</menuTemplate>

View file

@ -64,6 +64,7 @@ import com.raytheon.viz.texteditor.util.VtecUtil;
* 15 SEP 2014 529 mgamazaychikov Create firstBulletImmediateCauseQCExclusions list and add IC to it.
* 29 MAY 2015 4441 randerso Fixed QC to work with mixed case
* 24 NOV 2015 DR 17501 dhuffman Added lookaheads to ugc pattern to remove the telephone number special case.
* 28 APR 2016 DR 18947 D. Friedman Fixed UGC pattern.
*
* </pre>
*
@ -71,8 +72,12 @@ import com.raytheon.viz.texteditor.util.VtecUtil;
*/
public class TextSegmentCheck implements IQCCheck {
/*
* In order to keep this pattern simple, it does not exclude empty lines.
* The empty line case must be handled separately.
*/
private static final Pattern ugcPtrn = Pattern
.compile("(^(?!\\d{3}-\\d{4}[^-]*)^(?!\\d{3}-\\d{3}-\\d{4}[^-]*)(((\\w{2}[CZ](\\d{3}-){1,}){1,})|(\\d{3}-){1,})(((\\d{2})(\\d{2})(\\d{2})-){0,1}))");
.compile("^(?:(?:[A-Z]{2}[CZ]\\d{3}-)?(?:\\d{3}-)*)*(?:\\d{6}-)?$");
private static Map<String, List<String>> bulletTypeMaps;
static {
@ -191,7 +196,7 @@ public class TextSegmentCheck implements IQCCheck {
}
m = ugcPtrn.matcher(line);
if (m.find()) {
if (m.find() && m.start() != m.end()) {
ugc += line;
countUGC = true;
continue;