Merge branch 'master_14.3.1' (14.3.1-5) into omaha_14.3.1

Former-commit-id: 74c5b0454c [formerly 0a3b23d055] [formerly 4899c4f56a] [formerly 74c5b0454c [formerly 0a3b23d055] [formerly 4899c4f56a] [formerly 2059fc9c0e [formerly 4899c4f56a [formerly eae5c3e75061566e40194730c2cfb2003d952e62]]]]
Former-commit-id: 2059fc9c0e
Former-commit-id: aa266f6ded [formerly 805aae1a70] [formerly 075083683c45c73e61f607291d9d32a3cc865f27 [formerly 0df4af413b]]
Former-commit-id: ef4132ffa26246b1912b6d1234a3a9d9d473e8aa [formerly e7e48b2abb]
Former-commit-id: 5aca60f422
This commit is contained in:
Steve Harris 2014-05-22 14:05:06 -05:00
commit 2118803e86
44 changed files with 445 additions and 119 deletions

View file

@ -181,6 +181,7 @@ import com.vividsolutions.jts.geom.Point;
* Jan 21, 2014 DR 15874 gzhang Use getValue() for QPFSCAN independent.
* Feb 19, 2014 2819 randerso Removed unnecessary .clone() call
* Mar 3, 2014 2804 mschenke Set back up clipping pane
* Apr 30, 2014 DR 16148 gzhang Filter Basin Dates for Trend and Table Gap.
* May 05, 2014 3026 mpduff Display Hpe bias source.
* </pre>
*
@ -3152,6 +3153,9 @@ public class FFMPResource extends
boolean guid = false;
Date oldestRefTime = getOldestTime();
Date mostRecentRefTime = getPaintTime().getRefTime();
Date barrierTime = getTableTime();// DR 16148
Date minUriTime = getTimeOrderedKeys().get(0);// DR 16148
// grabs the basins we need
try {
@ -3164,7 +3168,10 @@ public class FFMPResource extends
if (rateBasin != null) {
for (Date date : rateBasin.getValues().keySet()) {
if (date.before(minUriTime) || date.before(barrierTime) || date.after(mostRecentRefTime))
continue;// DR 16148
double dtime = FFMPGuiUtils.getTimeDiff(mostRecentRefTime,
date);
fgd.setRate(dtime, (double) rateBasin.getValue(date));
@ -3189,6 +3196,9 @@ public class FFMPResource extends
if (qpeBasin != null) {
for (Date date : qpeBasin.getValues().keySet()) {
if (date.before(minUriTime) || date.before(barrierTime) || date.after(mostRecentRefTime))
continue;// DR 16148
double dtime = FFMPGuiUtils.getTimeDiff(mostRecentRefTime,
date);

View file

@ -318,7 +318,7 @@
# Date Ticket# Engineer Description
# ------------ ---------- ----------- --------------------------
# 02APR2014 17211 zhao (code obtained from the listserver via Virgil that implements a new rule regarding CB, TS etc)
#
# May 12, 2014 16928 zhao Modified check_prev_time()
#
#
import exceptions, re, time, types
@ -939,6 +939,8 @@ class Decoder(tpg.VerboseParser):
try:
if t['from'] <= max(period['prev']['time']['from'], self._cutoff):
add_msg(t, 'error', 49)
elif t['from'] <= self._taf['vtime']['from']:
add_msg(t, 'error', 49)
if 'ocnl' in period and t['from'] < period['ocnl']['time']['to']:
add_msg(t, 'error', 50)
period['prev']['time']['to'] = t['from']

View file

@ -101,6 +101,8 @@ import com.vividsolutions.jts.geom.LineString;
* 01-28-2014 DR16465 mgamazaychikov Fixed the problem with anchor point when frame
* count changes; made line width configurable.
* 04-07-2014 DR 17232 D. Friedman Make sure pivot indexes are valid.
* 04-24-2014 DR 16356 Qinglu Lin Updated generateTrackInfo(), generateNewTrackInfo(),
* and createTrack().
*
* </pre>
*
@ -691,6 +693,14 @@ public class StormTrackDisplay implements IRenderable {
if (cachedTrack != null) {
cachedTrack.dispose();
}
if (StormTrackState.trackType.equals("lineOfStorms") && state.justSwitchedToLOS) {
GeodeticCalculator gc = new GeodeticCalculator();
Coordinate[] coords = state.dragMeGeom.getCoordinates();
gc.setStartingGeographicPoint(coords[0].x, coords[0].y);
gc.setDestinationGeographicPoint(coords[coords.length - 1].x,
coords[coords.length - 1].y);
state.angle = adjustAngle(gc.getAzimuth() - 90);
}
generateTrackInfo(state, paintProps);
if (state.mode == Mode.TRACK) {
createTrack(target, paintProps);
@ -703,6 +713,9 @@ public class StormTrackDisplay implements IRenderable {
state.lineWidth, state.lineStyle);
paintLabels(target, paintProps);
}
if (StormTrackState.trackType.equals("lineOfStorms") && state.justSwitchedToLOS) {
state.angle = StormTrackState.oneStormAngle;
}
}
/**
@ -781,6 +794,10 @@ public class StormTrackDisplay implements IRenderable {
currentState.pointMoved = false;
currentState.originalTrack = false;
moved = true;
if (StormTrackState.trackType.equals("lineOfStorms") &&
currentState.justSwitchedToLOS) {
currentState.justSwitchedToLOS = false;
}
}
currentDisplayedTimes = trackUtil.getDataTimes(paintProps
@ -959,6 +976,7 @@ public class StormTrackDisplay implements IRenderable {
state.futurePoints = futurePoints;
state.angle = angle;
StormTrackState.oneStormAngle = angle;
state.speed = speed;
postData(state);
@ -995,7 +1013,11 @@ public class StormTrackDisplay implements IRenderable {
coords[coords.length - 1].y);
angle = adjustAngle(gc.getAzimuth() - 90);
} else {
angle = adjustAngle(std.getMotionDirection());
if (state.justSwitchedToOS) {
angle = StormTrackState.oneStormAngle;
} else {
angle = adjustAngle(std.getMotionDirection());
}
}
state.angle = angle;
state.speed = speed;
@ -1182,6 +1204,11 @@ public class StormTrackDisplay implements IRenderable {
compiler.handle(gf.createLineString(coords));
double angle = state.angle;
if(!state.justSwitchedToOS) {
if (StormTrackState.trackType.equals("oneStorm")) {
StormTrackState.oneStormAngle = angle;
}
}
// Draw ticks, X and Arrow
for (int i = 0; i < orig.length - 1; ++i) {
GeodeticCalculator gc = new GeodeticCalculator();
@ -1189,6 +1216,10 @@ public class StormTrackDisplay implements IRenderable {
gc.setDestinationGeographicPoint(orig[i + 1].x, orig[i + 1].y);
angle = gc.getAzimuth();
if (state.justSwitchedToLOS) {
angle = 90.0;
state.justSwitchedToLOS = false;
}
if (i == state.displayedPivotIndex) {
double tickLen = SQRT_2 * tickLengthInMeters;

View file

@ -47,6 +47,8 @@ import com.vividsolutions.jts.geom.Point;
* 11/29/2012 15571 Qinglu Lin Added compuateCurrentStormCenter();
* 15Mar2013 15693 mgamazaychikov Added magnification.
* 06-24-2013 DR 16317 D. Friedman Handle "motionless" track.
* 04-24-2014 DR 16356 Qinglu Lin Added newWarnGen, oneStormAngle, justSwitchedToLOS,
* justSwitchedToOS, and trackType.
*
* </pre>
*
@ -198,6 +200,16 @@ public class StormTrackState {
private boolean initiallyMotionless;
public static boolean newWarnGen = true;
public static double oneStormAngle = Double.NaN;
public boolean justSwitchedToLOS = false;
public boolean justSwitchedToOS = false;
public static String trackType = null;
/** Compute the coordinate of the storm center at the time defined by dataTime via interpolation. */
public boolean compuateCurrentStormCenter(Coordinate coord, DataTime dateTime) {
if (futurePoints == null) return false;

View file

@ -157,6 +157,7 @@ import com.raytheon.viz.ui.dialogs.ICloseCallback;
* aren't being corrected.
* 02/05/2014 17022 ryu Modified loadDraft() to fix merging of WMO heading and AWIPS ID.
* 03/25/2014 #2884 randerso Added xxxid to check for disabling editor
* 05/12/2014 16195 zhao Modified widgetSelected() for "Auto Wrap" option widget
*
* </pre>
*
@ -865,7 +866,8 @@ public class ProductEditorComp extends Composite implements
autoWrapMI.addSelectionListener(new SelectionAdapter() {
@Override
public void widgetSelected(SelectionEvent e) {
textComp.setAutoWrapMode(autoWrapMI.getSelection());
wrapMode = !wrapMode;
textComp.setAutoWrapMode(wrapMode);
}
});

View file

@ -60,6 +60,7 @@ import com.raytheon.viz.gfe.smartscript.FieldDefinition.FieldType;
* Date Ticket# Engineer Description
* ------------ ---------- ----------- --------------------------
* May 30, 2012 randerso Initial creation
* May 12, 2014 16167 ryu Fix sizing and accessibility of content.
*
* </pre>
*
@ -72,7 +73,7 @@ public class DialogAreaComposite extends ScrolledComposite {
private static final transient IUFStatusHandler statusHandler = UFStatus
.getHandler(DialogAreaComposite.class);
private static final double MAX_HEIGHT_RATIO = 0.85;
private static final double MAX_HEIGHT_RATIO = 0.80;
private static final double MAX_WIDTH_RATIO = 0.85;
@ -225,30 +226,27 @@ public class DialogAreaComposite extends ScrolledComposite {
}
}
Point compositeSize = varFrame.computeSize(SWT.DEFAULT, SWT.DEFAULT);
int xSize = compositeSize.x;
int ySize = compositeSize.y;
this.setMinSize(new Point(xSize, ySize));
this.setExpandHorizontal(true);
this.setExpandVertical(true);
Rectangle monitorBounds = this.getDisplay().getPrimaryMonitor()
.getBounds();
int maxXSize = (int) (monitorBounds.width * MAX_WIDTH_RATIO);
int maxYSize = (int) (monitorBounds.height * MAX_HEIGHT_RATIO);
Point compositeSize = varFrame.computeSize(SWT.DEFAULT, SWT.DEFAULT);
int xSize = compositeSize.x;
int ySize = compositeSize.y;
if (xSize > maxXSize) {
xSize = maxXSize;
}
if (ySize > maxYSize) {
ySize = maxYSize;
}
maxXSize = Math.min(maxXSize, xSize);
maxYSize = Math.min(maxYSize, ySize);
GridData gd = new GridData(SWT.FILL, SWT.FILL, true, true);
gd.heightHint = ySize;
gd.widthHint = xSize;
gd.heightHint = maxYSize;
gd.widthHint = maxXSize;
this.setLayoutData(gd);
this.setMinSize(new Point(xSize, ySize));
this.setExpandHorizontal(true);
this.setExpandVertical(true);
// Make sure widgets are scrolled into view when they gain focus
// see:
// http://www.java2s.com/Code/Java/SWT-JFace-Eclipse/ScrollSWTwidgetsintoviewwhentheygetfocus.htm

View file

@ -71,6 +71,7 @@ import com.raytheon.viz.hydrocommon.util.DbUtils;
* May 30 2012 14967 wkwock overload insertRejectedData method
* Feb 22 2013 14676 lbousaidi check when producttime is null
* Mar 25, 2013 1781 mpduff Constrain time series table query with a start time.
* May 12 2014 16705 lbousaidi update revision and shef_qual_code in edit routine.
* </pre>
*
* @author dhladky
@ -1167,6 +1168,8 @@ public class TimeSeriesDataManager extends HydroDataManager {
SqlBuilder sql = new SqlBuilder(tablename);
sql.setSqlType(SqlBuilder.UPDATE);
sql.addDouble("value", data.getValue());
sql.addString("shef_qual_code", "M");
sql.addInt("revision", 1);
sql.addString("postingTime", HydroConstants.DATE_FORMAT.format(now));
if (data.getProductTime() == null) {
sql.addString(

View file

@ -71,10 +71,13 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog;
* SOFTWARE HISTORY
* Date Ticket# Engineer Description
* ------------ ---------- ----------- --------------------------
* Sep 4, 2008 lvenable Initial creation
* Sep 4, 2008 lvenable Initial creation
* Dec 11, 2008 1787 askripsk Connect to DB
* Apr 18, 2013 1790 rferrel Make dialog non-blocking.
* Mar 31, 2014 #2970 lvenable Put dispose checks in the runAsync calls.
* May 1, 2014 17096 xwei By default the first item of the data
* list is selected
*
*
* </pre>
*
@ -642,7 +645,7 @@ public class DataIngestFilterDlg extends CaveSWTDialog {
typeSrcLbl.setEnabled(false);
typeSrcLbl.setLayoutData(gd);
gd = new GridData();
gd = new GridData(SWT.FILL, SWT.CENTER, false, true);
gd.horizontalSpan = 3;
typeSrcFilterCbo = new Combo(filterGroup, SWT.DROP_DOWN | SWT.READ_ONLY);
typeSrcFilterCbo.select(0);
@ -1045,6 +1048,8 @@ public class DataIngestFilterDlg extends CaveSWTDialog {
if (ingestDataList.getItemCount() > 0) {
updateDialogState(DialogStates.DATA_AVAILABLE);
ingestDataList.select(0);
updateSelectedInformation();
} else {
updateDialogState(DialogStates.NO_DATA);
}

View file

@ -37,6 +37,8 @@ import com.raytheon.viz.hydrocommon.data.DataIngestFilterData;
* ------------ ---------- ----------- --------------------------
* Dec 11, 2008 1787 askripsky Initial Creation
* Apr 18, 2013 1790 rferrel Code clean up with non-blocking dialogs.
* May 1, 2014 17096 xwei Updated the filter list SQL statement
*
*
* </pre>
*
@ -220,7 +222,7 @@ public class DataIngestFilterDataManager {
StringBuffer whereClause = new StringBuffer();
if (filterByLocation) {
whereClause.append("lid like '%" + selectedLocation + "%'");
whereClause.append( "lid='" + selectedLocation + "'" );
}
if (filterByPE && (selectedPE.size() > 0)) {

View file

@ -22,6 +22,7 @@ package com.raytheon.viz.mpe.ui.actions;
import java.awt.image.BufferedImage;
import java.io.File;
import java.io.IOException;
import java.text.SimpleDateFormat;
import java.util.Arrays;
import java.util.Date;
import java.util.Iterator;
@ -58,6 +59,8 @@ import com.raytheon.viz.mpe.ui.MPEDisplayManager;
* Dec 11, 2012 mschenke Initial creation
* Feb 2, 2014 16201 snaples Added saved data flag support
*
* Apr29, 2014 16308 lbousaidi transmit RFC Bias when an hour
* MPE is saved via the GUI.
* </pre>
*
* @author mschenke
@ -256,13 +259,21 @@ public class SaveBestEstimate {
boolean transmit_bias_on_save = appsDefaults.getBoolean(
"transmit_bias_on_save", true);
if (transmit_rfc_bias && transmit_bias_on_save) {
// sprintf ( command_string, "%s/transmit_rfc_bias %s",
// precip_proc_bin_dir, cdate );
// UFStatus.handle(Priority.VERBOSE, Activator.PLUGIN_ID,
// StatusConstants.CATEGORY_MPE, null,
// String.format("Invoking transmit_rfc_bias script using command:\n"
// "%s\n", command_string ));
// system ( command_string );
Date currentDate = MPEDisplayManager.getCurrent().getCurrentEditDate();
SimpleDateFormat formatter = new SimpleDateFormat("yyyyMMddHH");
String transmitDate = formatter.format(currentDate);
String scriptDir = appsDefaults.getToken("pproc_bin");
String scriptName = "transmit_rfc_bias";
ProcessBuilder pb = new ProcessBuilder(scriptDir + "/" + scriptName,
transmitDate);
try {
pb.start();
} catch (IOException e) {
e.printStackTrace();
}
}
MPEDisplayManager.getCurrent().setSavedData(true);
}

View file

@ -23,6 +23,7 @@ import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Date;
import java.util.HashMap;
import java.util.Iterator;
import java.util.Map;
import java.util.TimeZone;
@ -32,10 +33,10 @@ import org.eclipse.swt.events.ControlAdapter;
import org.eclipse.swt.events.ControlEvent;
import org.eclipse.swt.events.ModifyEvent;
import org.eclipse.swt.events.ModifyListener;
import org.eclipse.swt.graphics.Rectangle;
import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.graphics.Font;
import org.eclipse.swt.graphics.Rectangle;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.Button;
@ -72,6 +73,7 @@ import com.raytheon.viz.mpe.ui.radartable.ReadBiasTableParam;
* Feb 2, 2014 16201 snaples Added saved data flag support
* Apr 4, 2014 17223 snaples Updated other_office_id and rfc_bias to object
* array so that called procedure can update and return values properly.
* May 1, 2014 16626 snaples Updated the Manual Bias button to allow revert to original value.
*
* </pre>
*
@ -147,6 +149,10 @@ public class RadarBiasTableDialog extends Dialog {
Button mbiasBtn = null;
Button[] manEdit = null;
Text[] lbTxts = null;
private final Map<String, Integer> biasChgs = new HashMap<String, Integer>();
static {
sdf.setTimeZone(TimeZone.getTimeZone("GMT"));
@ -343,7 +349,7 @@ public class RadarBiasTableDialog extends Dialog {
dt = pgsdf.format(dt3);
rsList = new HashMap<String, MPERadarData>(radIds.length);
rsList = MPEDataManager.getInstance().readRadarData(dt3);
Text[] lbTxts = new Text[radIds.length];
lbTxts = new Text[radIds.length];
manEdit = new Button[radIds.length];
for (int i = 0; i < radIds.length; i++) {
@ -398,9 +404,10 @@ public class RadarBiasTableDialog extends Dialog {
});
bias = String.format("%-1.2f", radarresultdata.getRwBiasValUsed());
oldbias[i] = (float) radarresultdata.getRwBiasValUsed();
editbias[i] = 0.0f;
editbias[i] = 0.0f;
editbias[i] = oldbias[i];
bias = String.format("%-1.2f", editbias[i]);
gd = new GridData(SWT.FILL, SWT.CENTER, true, true);
final Text lbiasTxt = new Text(biasListComp, SWT.SINGLE
@ -419,17 +426,16 @@ public class RadarBiasTableDialog extends Dialog {
lbiasTxt.setData(i);
lbiasTxt.addModifyListener(new ModifyListener() {
@Override
public void modifyText(ModifyEvent e) {
@Override
public void modifyText(ModifyEvent e) {
final int ei = (Integer) lbiasTxt.getData();
try {
float parsedFloat = Float.parseFloat(lbiasTxt.getText());
editbias[ei] = parsedFloat;
manEdit[ei].setSelection(!mbiasBtn.getSelection());
manEdit[ei].setText("YES");
lbiasTxt.setBackground(getParent().getDisplay()
.getSystemColor(SWT.COLOR_WHITE));
biasChgs.put(radIds[ei], ei);
applyBtn.setEnabled(true);
} catch (NumberFormatException e1) {
lbiasTxt.setBackground(getParent().getDisplay()
@ -442,16 +448,36 @@ public class RadarBiasTableDialog extends Dialog {
lbTxts[i] = lbiasTxt;
gd = new GridData(SWT.FILL, SWT.CENTER, true, true);
mbiasBtn = new Button(biasListComp, SWT.TOGGLE | SWT.READ_ONLY);
// mbiasBtn.setEnabled(false);
final Button mbiasBtn = new Button(biasListComp, SWT.TOGGLE);
mbias = ("n".equalsIgnoreCase(radarresultdata.getEditBias()) || radarresultdata
.getEditBias() == null) ? "NO" : "YES";
mbiasBtn.setText(mbias);
mbiasBtn.setLayoutData(gd);
mbiasBtn.setData(i);
mbiasBtn.setSelection(false);
manEdit[i] = mbiasBtn;
mbiasBtn.addSelectionListener(new SelectionAdapter() {
/**
* (non-Javadoc)
*
* @see
* org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse
* .swt.events.SelectionEvent)
*/
@Override
public void widgetSelected(SelectionEvent e) {
final int ai = (Integer) mbiasBtn.getData();
if ("YES".equalsIgnoreCase(mbiasBtn.getText())) {
manEdit[ai].setSelection(false);
editbias[ai] = oldbias[ai];
lbTxts[ai].setText(String.format("%-1.2f", editbias[ai]));
biasChgs.put(radIds[ai], ai);
applyBtn.setEnabled(false);
manEdit[ai].setText("NO");
}
}
});
gd = new GridData(SWT.FILL, SWT.CENTER, true, true);
Label acoefLbl = new Label(biasListComp, SWT.CENTER);
if (abzerocoef.mlt_zrcoef == 0.0) {
@ -515,29 +541,27 @@ public class RadarBiasTableDialog extends Dialog {
final float memspan = -99.0f;
ArrayList<Rwradarresult> rwr = new ArrayList<Rwradarresult>();
Rwradarresult rwrr = new Rwradarresult();
for (int i = 0; i < radIds.length; i++) {
if (radIds[i].equals("ZZZ")) {
continue;
}
if (manEdit[i] != null
&& "YES".equalsIgnoreCase(manEdit[i].getText())) {
where = String.format("WHERE radid='%s' AND obstime='%s'",
radIds[i], obstime);
rwr = (ArrayList<Rwradarresult>) IHFSDbGenerated
.GetRWRadarResult(where);
if (rwr.size() != 0) {
rwrr = rwr.get(0);
} else {
continue;
}
rwrr.setEditBias("y");
rwrr.setMemSpanUsed((double) memspan);
rwrr.setRwBiasValUsed((double) editbias[i]);
IHFSDbGenerated.UpdateRWRadarResult(rwrr);
} else {
continue;
}
Iterator<String> bi = biasChgs.keySet().iterator();
while (bi.hasNext()) {
String rid = bi.next();
where = String.format("WHERE radid='%s' AND obstime='%s'",rid, obstime);
rwr = (ArrayList<Rwradarresult>) IHFSDbGenerated.GetRWRadarResult(where);
if (rwr.size() != 0) {
rwrr = rwr.get(0);
} else {
continue;
}
int indexval = biasChgs.get(rid);
if("YES".equalsIgnoreCase(manEdit[indexval].getText())){
rwrr.setEditBias("y");
rwrr.setMemSpanUsed((double) memspan);
} else {
rwrr.setEditBias("n");
}
rwrr.setRwBiasValUsed((double) editbias[indexval]);
IHFSDbGenerated.UpdateRWRadarResult(rwrr);
}
biasChgs.clear();
return;
}
}

View file

@ -24,6 +24,8 @@ import java.util.Date;
import java.util.List;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.ControlAdapter;
import org.eclipse.swt.events.ControlEvent;
import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.graphics.Cursor;
@ -60,6 +62,7 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog;
* Sep 11, 2013 #2353 lvenable Fixed cursor memory leak.
* Jan 29, 2014 16561 snaples Updated processDrawPrecipValue to remove polygon wireframe after setting value.
* Feb 2, 2014 16201 snaples Added saved data flag support
* Apr 28, 2014 16707 snaples Added code to save and set location of dialog box when moved.
*
*
* </pre>
@ -113,6 +116,12 @@ public class DrawPolygonDlg extends CaveSWTDialog {
/** The polygon resource */
private final MPEPolygonResource resource;
/** Point to hold location of dialog */
private static org.eclipse.swt.graphics.Point dlgLoc = null;
/** Status of dialog opened or not */
private boolean dialogOpened = false;
/**
* Constructor.
@ -144,13 +153,28 @@ public class DrawPolygonDlg extends CaveSWTDialog {
}
@Override
protected void initializeComponents(Shell shell) {
protected void initializeComponents(final Shell shell) {
setReturnValue(false);
boldFont = new Font(shell.getDisplay(), "Monospace", 10, SWT.BOLD);
font = new Font(shell.getDisplay(), "Monospace", 10, SWT.NORMAL);
// Initialize all of the controls and layoutsendCal
initializeComponents();
shell.addControlListener(new ControlAdapter() {
@Override
public void controlMoved(ControlEvent e) {
if (!dialogOpened) {
return;
}
if (dlgLoc == null) {
return;
}
dlgLoc.x = shell.getBounds().x;
dlgLoc.y = shell.getBounds().y;
}
});
}
/**
@ -162,6 +186,18 @@ public class DrawPolygonDlg extends CaveSWTDialog {
createCloseBtn();
}
@Override
protected void opened() {
if (dlgLoc == null) {
dlgLoc = new org.eclipse.swt.graphics.Point(shell.getBounds().x, shell.getBounds().y);
}
else {
shell.setLocation(dlgLoc);
}
dialogOpened = true;
}
/**
* Create the persistent group.
*/

View file

@ -19,6 +19,7 @@
**/
package com.raytheon.viz.mpe.core;
import java.io.IOException;
import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Date;
@ -38,6 +39,7 @@ import com.raytheon.uf.common.dataplugin.shef.tables.Hourlypp;
import com.raytheon.uf.common.dataplugin.shef.tables.Pseudogageval;
import com.raytheon.uf.common.dataplugin.shef.tables.Rawpp;
import com.raytheon.uf.common.dataplugin.shef.util.ShefConstants;
import com.raytheon.uf.common.ohd.AppsDefaults;
import com.raytheon.uf.viz.core.exception.VizException;
import com.raytheon.viz.hydrocommon.whfslib.GagePPOptions;
import com.raytheon.viz.hydrocommon.whfslib.GagePPOptions.shef_dup;
@ -56,6 +58,8 @@ import com.raytheon.viz.mpe.core.MPEDataManager.MPEGageData;
* Jan 02, 2013 15565 snaples Fixed problem with wrong time being sent to mpe_fieldgen
* Mar 14, 2013 1457 mpduff Fixed memory leak.
* Jun 18, 2013 16053 snaples Removed check for Radar Edit flag
* Apr 24, 2014 16308 lbousaidi added the ability to send RFC Bias across the WAN
* after Mpe fieldgen run.
* </pre>
*
* @author snaples
@ -293,6 +297,22 @@ public class RegenHrFlds {
e.printStackTrace();
}
/*-------------------------------------------------------------------------*/
/* send RFC Bias across the WAN if the tokens TRANSMIT_BIAS_ON_RERUN
* and MPE_TRANSMIT_BIAS are both ON. The script rerun_mpe_fieldgen
* only run transmit_rfc_bias but it doesn't rerun mpe_fieldgen
/*-------------------------------------------------------------------------*/
AppsDefaults appsDefaults = AppsDefaults.getInstance();
String scriptDir = appsDefaults.getToken("pproc_bin");
String scriptName ="rerun_mpe_fieldgen";
String transmitRun= dr.format(datetime);
ProcessBuilder pb = new ProcessBuilder(scriptDir + "/" + scriptName ,hour,
transmitRun);
try {
pb.start();
} catch (IOException e) {
e.printStackTrace();
}
MPEDataManager.getInstance().clearEditGages();
shell.setCursor(null);
}

View file

@ -99,6 +99,8 @@ import com.raytheon.viz.ui.dialogs.ICloseCallback;
* 11/26/2012 14526 mgamazaychikov Added traverse listener for RETURN key
* 10/07/2013 16664 mgamazaychikov Added padProdDesignatorText method
* 11/21/2013 16633 mgamazaychikov Improved consistency between AFOS PIL and WMO Heading fields.
* 08May2014 16041 kshrestha Save unofficial text products from text editor.
*
* </pre>
*
* @author lvenable
@ -646,6 +648,7 @@ public class AWIPSHeaderBlockDlg extends CaveSWTDialog implements
return;
}
boolean sendEnabled = true;
boolean unOfficialProd = false;
if (!isProductValid()) {
// Notify the user that the product may not be valid.
//
@ -665,6 +668,9 @@ public class AWIPSHeaderBlockDlg extends CaveSWTDialog implements
}
parentEditor.enableSend(false);
sendEnabled = false;
if(isAfosPilComplete()) {
unOfficialProd = true;
}
} else {
parentEditor.enableSend(true);
}
@ -672,7 +678,7 @@ public class AWIPSHeaderBlockDlg extends CaveSWTDialog implements
// call the set methods
parentEditor.setCurrentWmoId(wmoTtaaiiTF.getText());
parentEditor.setCurrentSiteId(ccccTF.getText());
if (sendEnabled) {
if (sendEnabled || (sendEnabled == false && unOfficialProd == true)) {
parentEditor.setCurrentWsfoId(wsfoIdTF.getText());
parentEditor.setCurrentProdCategory(prodCatTF.getText());
parentEditor.setCurrentProdDesignator(prodDesignatorTF.getText());

View file

@ -336,6 +336,8 @@ import com.raytheon.viz.ui.dialogs.SWTMessageBox;
* 10Dec2013 2601 mpduff Fix NullPointerException.
* 28Jan2014 DR14595 mgamazaychikov Added template loading and editing functionality.
* 14Mar2014 DR 17175 D. Friedman Get correct time zone for MND header time sync.
* 08May2014 DR 16041 kshrestha Save unofficial text products from text editor.
*
* </pre>
*
* @author lvenable
@ -4396,7 +4398,7 @@ public class TextEditorDialog extends CaveSWTDialog implements VerifyListener,
.getProductCategory(token)
+ tdm.getProductDesignator(token);
// Set the header text field.
if (bbbid.equals("NOR")) {
if (bbbid.equals("NOR") || tdm.getAfosPil(token) != null) {
String wmoId = tdm.getWmoId(token);
wmoId = (wmoId.length() > 0 ? wmoId : "-");
String siteId = tdm.getSiteId(token);
@ -5297,8 +5299,11 @@ public class TextEditorDialog extends CaveSWTDialog implements VerifyListener,
if (!isAutoSave) {
if (!resend) {
// If not a resend, set the DDHHMM field to the current time
if (productText.startsWith("- -") && productText.contains("DDHHMM")) {
productText = getUnofficeProduct(currentDate);
} else {
productText = replaceDDHHMM(productText, currentDate);
}
VtecObject vtecObj = VtecUtil.parseMessage(productText);
if (warnGenFlag) {
/*
@ -8628,4 +8633,34 @@ public class TextEditorDialog extends CaveSWTDialog implements VerifyListener,
modifiedText = removeSoftReturns(modifiedText);
return modifiedText;
}
private String getUnofficeProduct(String currDate)
{
StdTextProduct textProd = TextDisplayModel.getInstance().getStdTextProduct(token);
String header = headerTF.getText();
String nnn = textProd.getNnnid();
String xxx = textProd.getXxxid();
String nnnXxx = nnn + xxx;
String site = SiteMap.getInstance().getSite4LetterId(
textProd.getCccid());
String wmoId = textProd.getCccid() + nnnXxx + " "
+ getAddressee() + "\nTTAA00 " + site;
header = header.replaceFirst("\n" + nnnXxx, "");
header = header.replaceFirst("-", "ZCZC");
header = header.replaceFirst("-", wmoId);
if (currDate != null)
header = header.replaceFirst("DDHHMM", currDate);
else
header = header.replaceFirst("DDHHMM", textProd.getHdrtime());
String body = textEditor.getText().toUpperCase();
header = header + "\n\n"+body +"\n!--not sent--!";
return header;
}
}

View file

@ -42,6 +42,7 @@ import com.raytheon.viz.texteditor.util.VtecUtil;
* Date Ticket# Engineer Description
* ------------ ---------- ----------- --------------------------
* May 24, 2010 jsanchez Initial creation
* Apr 25, 2014 DR 16668 D. Friedman Only notify on NEW products.
*
* </pre>
*
@ -83,7 +84,7 @@ public class NotifyExpiration {
}
VtecObject vtecObject = VtecUtil.parseMessage(warning);
if (vtecObject == null) {
if (vtecObject == null || !"NEW".equals(vtecObject.getAction())) {
return;
}
Calendar expire = vtecObject.getEndTime();

View file

@ -51,6 +51,7 @@ import com.raytheon.viz.ui.dialogs.SWTMessageBox;
* Sep 21, 2010 2187 cjeanbap Removed hard coded values of
* tables names.
* Dec 20, 2010 7210 cjeanbap Added non-blocking dialog.
* Apr 25, 2014 DR 16668 D. Friedman Handle partial cancellations
* </pre>
*
* @author jsanchez
@ -114,8 +115,6 @@ public class NotifyExpirationTask extends TimerTask {
req.setMode(ActiveTableMode.OPERATIONAL);
}
/* textNotifyExpiration.tcl ln 76: Only queries for a CAN */
req.setAct("CAN");
req.setSiteID(office);
req.setPhensigList(phenSig);
req.setEtn(etn);
@ -127,22 +126,32 @@ public class NotifyExpirationTask extends TimerTask {
activeTable = resp.getActiveTable();
} catch (VizException e) {
statusHandler.handle(Priority.ERROR,
"Error querying active table for CAN." + office + "."
"Error querying active table for " + office + "."
+ phenSig + "." + etn, e);
}
if (activeTable != null && activeTable.size() > 0) {
ActiveTableRecord record = activeTable.get(0);
/*
* textNotifyExpiration.tcl ln 97: If any of the found products are
* less than 48 hours old,return true.
*/
if (record != null
&& (System.currentTimeMillis()
- record.getIssueTime().getTimeInMillis() < TWO_DAYS)) {
return true;
if (activeTable != null) {
boolean haveCAN = false;
for (ActiveTableRecord record : activeTable) {
if (record != null) {
/*
* textNotifyExpiration.tcl ln 106: If any of the found products are
* less than 48 hours old,return true.
*/
if ("CAN".equals(record.getAct())
&& (System.currentTimeMillis()
- record.getIssueTime().getTimeInMillis() < TWO_DAYS)) {
haveCAN = true;
} else if ("CON".equals(record.getAct())) {
/* If there CANs and the event is still active, there
* should be some CONs. Thus, it is not necessary to
* check for every other kind of non-terminal action.
*/
return false;
}
}
}
return haveCAN;
}
return false;

View file

@ -58,6 +58,7 @@ import com.raytheon.viz.texteditor.util.VtecUtil;
* 07 NOV 2012 15003 mgamazaychikov Do not perform QC check on standalone MWS headline.
* 21 MAY 2013 16200 Qinglu Lin Prevent countyOrZoneCounter from being increased for a line
* that has no word County/Parish/Municipality in it.
* 13 MAY 2014 17177 Qinglu Lin Updated runQC().
*
* </pre>
*
@ -305,7 +306,7 @@ public class TextSegmentCheck implements IQCCheck {
// second bullet
if (line.startsWith("*") && nb == 2) {
m = secondBulletPtrn.matcher(line);
if (m.find()) {
if (m.find() || line.contains("* UNTIL NOON") || line.contains("* UNTIL MIDNIGHT")) {
secondBulletFound = true;
insideFirstBullet = false;
continue;

View file

@ -42,6 +42,7 @@ import com.raytheon.viz.texteditor.util.VtecUtil;
* Initial creation
* Aug 25, 2011 10719 rferrel ugcPtrn now local to file.
* Mar 14, 2014 DR 17175 D. Friedman Get correct time zone from times.
* May 13, 2014 DR 17177 Qinglu Lin Updated runQC().
* </pre>
*
* @version 1.0
@ -89,7 +90,9 @@ public class TimeConsistentCheck implements IQCCheck {
}
// Event ending time (second bullet) vs Expiration
m = secondBulletPtrn.matcher(body);
String newBody = body.replaceAll("UNTIL NOON", "UNTIL 1200 PM");
newBody = newBody.replaceAll("UNTIL MIDNIGHT", "UNTIL 1200 AM");
m = secondBulletPtrn.matcher(newBody);
if (m.find()) {
TimeZone timeZone = TextWarningConstants.timeZoneShortNameMap
.get(m.group(4));

View file

@ -21,8 +21,11 @@
package com.raytheon.viz.ui.dialogs.colordialog;
import java.text.DecimalFormat;
import java.text.NumberFormat;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import javax.measure.converter.UnitConverter;
@ -61,9 +64,11 @@ import com.raytheon.uf.common.colormap.prefs.ColorMapParameters;
*
* SOFTWARE HISTORY
*
* Date Ticket# Engineer Description
* ------------- -------- ----------- --------------------------
* Apr 08, 2014 2950 bsteffen Support dynamic color counts and resizing.
* Date Ticket# Engineer Description
* ------------ ---------- ----------- --------------------------
* Apr 08, 2014 2950 bsteffen Support dynamic color counts and resizing.
* for color editor's color bar for radar correlation coefficient.
* Apr 11, 2014 DR 15811 Qinglu Lin Added decimalPlaceMap and logic to have 4 decimal places
*
* </pre>
*
@ -148,6 +153,18 @@ public class ColorBar extends Composite implements MouseListener,
/** The color bar image with mask applied */
protected Image colorBarWithMask;
private final Map<String, String> decimalPlaceMap = new HashMap<String, String>() {
private static final long serialVersionUID = 1L;
{
// keys are the last portion of the title in the color table editor for
// a specific radar product, in lower case and value is the decimals expected
// to be displayed in color bar.
put("correlation coeff", "0000");
}
};
private NumberFormat numberFormat = null;
/**
* Constructor.
*
@ -181,6 +198,13 @@ public class ColorBar extends Composite implements MouseListener,
this.enabledColorMask = enableColorMask;
this.cmapParams = cmapParams;
for (String s: decimalPlaceMap.keySet()) {
if (parent.getShell().getText().toLowerCase().contains(s)) {
numberFormat = new DecimalFormat("###,###,##0." + decimalPlaceMap.get(s));
break;
}
}
colorHistory = new ArrayList<List<ColorData>>();
colorHistory.add(ColorUtil.buildColorData(cmapParams.getColorMap()));
@ -880,7 +904,10 @@ public class ColorBar extends Composite implements MouseListener,
if (Double.isNaN(lastVal)) {
return "NO DATA";
} else if (((Double) value).isNaN()) {
return "> " + lastVal;
if (numberFormat != null)
return "> " + numberFormat.format(lastVal);
else
return "> " + lastVal;
}
}
@ -892,7 +919,9 @@ public class ColorBar extends Composite implements MouseListener,
return dmLabel;
}
}
return new DecimalFormat("0.0##").format(value);
NumberFormat format = numberFormat != null ?
numberFormat : new DecimalFormat("0.0##");
return format.format(value);
}
public Point getSliderRange() {

View file

@ -1198,6 +1198,7 @@
</Level>
<Level displayName="Wet Bulb 0" key="WetBulb0" group="S">
<DatabaseLevel levelName="TW0" levelOneValue="0" />
<DatabaseLevel levelName="WBZ" levelOneValue="0" />
</Level>
<Level displayName="Low Wet Bulb 0" key="LowWetBulb0" group="S"> <!-- Lowest Level of the wet bulb zero -->
<DatabaseLevel levelName="LLTW" levelOneValue="0" />

View file

@ -68,6 +68,7 @@
<vbSource key="ENPWAVE253" category="SfcGrid" views="PLANVIEW TIMESERIES" />
<vbSource key="EPwave10" category="SfcGrid" views="PLANVIEW TIMESERIES" />
<vbSource key="GFE" category="SfcGrid" views="PLANVIEW TIMESERIES" />
<vbSource key="GFS199" category="SfcGrid" views="PLANVIEW TIMESERIES" />
<vbSource key="GFSGuide" category="SfcGrid" views="PLANVIEW TIMESERIES" />
<vbSource key="GFSLAMPTstorm" name="GFSLAMP-Grid" category="SfcGrid" views="PLANVIEW TIMESERIES" />
<vbSource key="GLERL" category="SfcGrid" views="PLANVIEW TIMESERIES" />

View file

@ -152,6 +152,8 @@ import com.vividsolutions.jts.geom.Polygon;
* Sep 24, 2013 #2401 lvenable Fixed font memory leak.
* Oct 01, 2013 DR16612 m.gamazaychikov Fixed inconsistencies with track locking and updateListSelected method
* Oct 29, 2013 DR 16734 D. Friedman If redraw-from-hatched-area fails, don't allow the polygon the be used.
* Apr 24, 2014 DR 16356 Qinglu Lin Updated selectOneStorm() and selectLineOfStorms().
* May 09, 2014 DR16694 m.gamazaychikov Fixed disabled duration menu after creating text for a COR SVS.
* </pre>
*
* @author chammack
@ -1250,6 +1252,7 @@ public class WarngenDialog extends CaveSWTDialog implements
warngenLayer.resetState();
warngenLayer.getStormTrackState().duration = ((DurationData) durationList
.getData(durationList.getItem(durationList.getSelectionIndex()))).minutes;
durationList.setEnabled(warngenLayer.getConfiguration().isEnableDuration());
if (lineOfStorms.getSelection()) {
selectLineOfStorms();
} else {
@ -1323,6 +1326,8 @@ public class WarngenDialog extends CaveSWTDialog implements
*/
private void selectOneStorm() {
if (warngenLayer.state.followupData == null) {
warngenLayer.resetState();
warngenLayer.reset("oneStorm");
warngenLayer.clearWarningGeometries();
warngenLayer.getStormTrackState().dragMeLine = null;
warngenLayer.getStormTrackState().dragMeGeom = null;
@ -1338,6 +1343,8 @@ public class WarngenDialog extends CaveSWTDialog implements
*/
private void selectLineOfStorms() {
if (warngenLayer.state.followupData == null) {
warngenLayer.resetState();
warngenLayer.reset("lineOfStorms");
warngenLayer.clearWarningGeometries();
warngenLayer.getStormTrackState().dragMeLine = null;
warngenLayer.getStormTrackState().dragMeGeom = null;

View file

@ -205,10 +205,11 @@ import com.vividsolutions.jts.io.WKTReader;
* 02/07/2014 DR16090 m.gamazaychikov Added GeomMetaDataUpdateNotificationObserver class to get notification
* when geometry file get updated to re-read them in.
* 02/19/2014 2819 randerso Removed unnecessary .clone() call
* 03/17/2014 DR16309 Qinglu Lin Updated getWarningAreaFromPolygon(); changed searchCountyGeospatialDataAccessor) to
* 03/17/2014 DR 16309 Qinglu Lin Updated getWarningAreaFromPolygon(); changed searchCountyGeospatialDataAccessor) to
* searchGeospatialDataAccessor() and updated it; changed getCountyGeospatialDataAcessor()
* to getGeospatialDataAcessor(); changed getAllCountyUgcs() to getAllUgcs(); changed
* getUgcsForWatches() to getUgcsForCountyWatches().
* 04/23/2014 DR 16356 Qinglu Lin Updated initializeState() and added reset().
* </pre>
*
* @author mschenke
@ -737,6 +738,11 @@ public class WarngenLayer extends AbstractStormTrackResource {
// Default angle for POINT
displayState.labelMode = LabelMode.TIME;
state.angle = 60;
if (StormTrackState.newWarnGen) {
StormTrackState.oneStormAngle = state.angle;
StormTrackState.trackType = "oneStorm";
StormTrackState.newWarnGen = false;
}
state.speed = 35;
state.dragMePoint = null;
state.resetAnchor = true;
@ -3493,4 +3499,17 @@ public class WarngenLayer extends AbstractStormTrackResource {
return hatchedArea;
}
}
public void reset(String trackType) {
if (trackType.equals("oneStorm")) {
getStormTrackState().justSwitchedToOS = true;
getStormTrackState().justSwitchedToLOS = false;
StormTrackState.trackType = "oneStorm";
getStormTrackState().angle = StormTrackState.oneStormAngle;
} else if (trackType.equals("lineOfStorms")) {
getStormTrackState().justSwitchedToOS = false;
getStormTrackState().justSwitchedToLOS = true;
StormTrackState.trackType = "lineOfStorms";
}
}
}

View file

@ -54,6 +54,7 @@ import com.raytheon.viz.warngen.gis.AffectedAreas;
* bulletIndices(), header(), firstBullet(), secondBullet(), getImmediateCausesPtrn();
* updated body(), header(), and secondBullet();
* Mar 13, 2013 DR 15892 D. Friedman Fix bullet parsing.
* May 13, 2014 DR 17177 Qinglu Lin Updated secondBullet().
*
* </pre>
*
@ -255,14 +256,14 @@ abstract public class AbstractLockingBehavior implements ICommonPatterns {
* Locks the second bullet.
*/
private void secondBullet() {
// LOCK_END should not be found at the beginning since the previous line
// should be blank.
String secondBullet =
"\\* UNTIL \\d{3,4} (AM|PM) \\w{3,4}( \\w{6,9}){0,1}(\\/\\d{3,4} (AM|PM) \\w{3,4}( \\w{6,9}){0,1}\\/){0,1}"
+ newline;
Pattern secondBulletPtrn = Pattern.compile(secondBullet,
Pattern.MULTILINE);
find(secondBulletPtrn.matcher(text));
// LOCK_END should not be found at the beginning since the previous line
// should be blank.
String secondBullet =
"\\* UNTIL (\\d{3,4} (AM|PM)|NOON|MIDNIGHT) \\w{3,4}( \\w{6,9}){0,1}(\\/(\\d{3,4} (AM|PM)|NOON|MIDNIGHT) \\w{3,4}( \\w{6,9}){0,1}\\/){0,1}"
+ newline;
Pattern secondBulletPtrn = Pattern.compile(secondBullet,
Pattern.MULTILINE);
find(secondBulletPtrn.matcher(text));
}
/**

View file

@ -342,9 +342,9 @@
<dt>6</dt>
</info>
<info>
<title>Guam-GFS</title>
<title>Guam-GFSDNG</title>
<datasetId>GFS199</datasetId>
<dt>6</dt>
<dt>3</dt>
</info>
<info>
<title>RAP13</title>

View file

@ -79,6 +79,7 @@ import com.vividsolutions.jts.geom.impl.CoordinateArraySequence;
* Nov 11, 2008 1684 chammack Camel refactor.
* Aug 30, 2013 2298 rjpeter Make getPluginName abstract
* Sep 17, 2013 2378 njensen Improve 3/6 hr precip decoding
* May 12, 2014 DR 17151 D. Friedman Fix 6hr min/max temp decoding.
* </pre>
*
* @author bphillip
@ -254,16 +255,17 @@ public class MetarDecoder extends AbstractDecoder {
record.setMessageData(message);
message = cleanMessage(message);
String trailingData = null;
String remarks = null;
int cutPos = message.indexOf(" RMK ");
if (cutPos >= 0) {
trailingData = message.substring(cutPos);
remarks = message.substring(cutPos);
// Now truncate the message data.
message = message.substring(0, cutPos);
} else {
trailingData = message;
remarks = "";
}
trailingData = trailingData + " ";
StringBuilder trailingData = new StringBuilder(remarks);
trailingData.append(' ');
StringBuilder obsMsg = new StringBuilder(message);
@ -730,6 +732,7 @@ public class MetarDecoder extends AbstractDecoder {
pkTim.add(Calendar.DAY_OF_MONTH, -1);
}
record.setPkWndTime(pkTim);
trailingData.delete(matcher.start(), matcher.end());
}
// Gets the temperature and dew point in tenths precision

View file

@ -127,6 +127,7 @@
<doTry>
<pipeline>
<bean ref="shefDecoder" method="decode" />
<bean ref="processUtil" method="log"/>
</pipeline>
<doCatch>
<exception>java.lang.Throwable</exception>
@ -146,6 +147,7 @@
<pipeline>
<bean ref="stringToFile" />
<bean ref="shefDecoder" method="decode" />
<bean ref="processUtil" method="log"/>
</pipeline>
<doCatch>
<exception>java.lang.Throwable</exception>

View file

@ -111,7 +111,7 @@ import com.raytheon.uf.edex.decodertools.time.TimeTools;
* data can be posted to appropriate pe-based tables only if the data
* type is not READING like in A1 code.
* 02/18/2014 16572 l. Bousaidi only apply adjust factor to non missing values.
*
* 04/24/2014 16904 lbousaidi gross check should be applied to adjusted value.
* </pre>
*
* @author mduff
@ -646,6 +646,8 @@ public class PostShef {
if (!dataValue.equals(ShefConstants.SHEF_MISSING)) {
adjustRawValue(locId, data);
}
dataValue = data.getStringValue();
/*
* multiply non-missing values of discharge values and unspecified

View file

@ -40,7 +40,7 @@ import com.raytheon.uf.common.style.level.SingleLevel;
* Date Ticket# Engineer Description
* ------------ ---------- ----------- --------------------------
* Jul 30, 2007 chammack Initial Creation.
*
* May 1, 2014 DCS 027 MPorricelli Add WBZ level
* </pre>
*
* @author chammack
@ -83,6 +83,8 @@ public class GridLevelTranslator {
level = new SingleLevel(Level.LevelType.TEMP);
} else if (levelType.equalsIgnoreCase("FRZ")) {
level = new SingleLevel(Level.LevelType.FRZ);
} else if (levelType.equalsIgnoreCase("WBZ")) {
level = new SingleLevel(Level.LevelType.WBZ);
} else {
return new SingleLevel(Level.LevelType.DEFAULT);
}

View file

@ -70,7 +70,7 @@
<alias base="ETA">NAM80</alias>
<alias base="GFS160">AK-GFS</alias>
<alias base="GFS161">SJU-GFS</alias>
<alias base="GFS199">Guam-GFS</alias>
<alias base="GFS199">Guam-GFSDNG</alias>
<alias base="GFS201">GFS360</alias>
<alias base="GFS212">GFS40</alias>
<alias base="GFS213">GFS90</alias>

View file

@ -4174,6 +4174,7 @@ in | .03937 | 0 | 4 | | |..|8000F0FF| | 16 | \
<parameter>GH</parameter>
<singleLevel units="FRZ" />
<singleLevel units="TW0" />
<singleLevel units="WBZ" />
</paramLevelMatches>
<contourStyle>
<displayUnits>ft</displayUnits>

View file

@ -4907,6 +4907,7 @@
<parameter>GH</parameter>
<singleLevel units="FRZ" />
<singleLevel units="TW0" />
<singleLevel units="WBZ" />
</paramLevelMatches>
<imageStyle>
<displayUnits>ft</displayUnits>

View file

@ -11,6 +11,7 @@
##### Evan Bookbinder 05-05-2013 handleClosesPoints and 3rd bullet changes (OVER & now)
##### Evan Bookbinder 09-20-2013 Fixed rural area otherPoints in pathcast section, added rural phrase
##### Qinglu Lin 03-17-2014 DR 16309. Updated inserttorwatches and insertsvrwatches.
##### Qinglu Lin 05-13-2014 DR 17177. Updated secondBullet.
####################################################################################################
#*
Mile Marker Test Code
@ -1142,10 +1143,13 @@ ${partOfArea}${area.name}...
######### MACRO TO GENERATE SECOND BULLET (UNTIL XXXX AMPM TZ (DAY) IN WARNINGS ##########
#macro(secondBullet $dateUtil $expire $timeFormat $localtimezone $secondtimezone $duration)
#if(${duration} >= 360)
UNTIL ${dateUtil.format(${expire}, ${timeFormat.plain}, 15, ${localtimezone})}##
#set($text = "UNTIL ${dateUtil.format(${expire}, ${timeFormat.plain}, 15, ${localtimezone})}")
#else
UNTIL ${dateUtil.format(${expire}, ${timeFormat.clock}, 15, ${localtimezone})}##
#set($text = "UNTIL ${dateUtil.format(${expire}, ${timeFormat.clock}, 15, ${localtimezone})}")
#end
#set($text = $text.replace("1200 PM", "NOON"))
#set($text = $text.replace("1200 AM", "MIDNIGHT"))
${text}##
#if(${secondtimezone})
#if(${duration} >= 360)
/${dateUtil.format(${expire}, ${timeFormat.plain}, 15, ${secondtimezone})}/##

View file

@ -15,4 +15,5 @@ PUERTO RICO \ MUNICIPALITY
PR+ \ MUNICIPALITIES
PUERTO RICO+ \ MUNICIPALITIES
DEFAULT+ \ COUNTIES
DEFAULT \ COUNTY
DEFAULT \ COUNTY
CITY \

View file

@ -183,4 +183,7 @@
<Field level="Surface" abbreviation="CCag"/>
<Field level="Surface" abbreviation="GH"/>
</Method>
<Method name="Alias" levels="BLyr">
<Field abbreviation="GH" level="0BLD"/>
</Method>
</DerivedParameter>

View file

@ -77,4 +77,7 @@
<Field abbreviation="T"/>
<Field abbreviation="SHx"/>
</Method>
<Method name="Alias" levels="BLyr">
<Field abbreviation="RH" level="0BLD"/>
</Method>
</DerivedParameter>

View file

@ -36,6 +36,7 @@ import javax.xml.bind.annotation.XmlAttribute;
* ------------ ---------- ----------- --------------------------
* Sep 24, 2007 njensen Initial creation
* Nov 14, 2013 2361 njensen Remove ISerializableObject
* May 1, 2014 DCS 027 MPorricelli Add WBZ level
*
* </pre>
*
@ -45,7 +46,7 @@ import javax.xml.bind.annotation.XmlAttribute;
public abstract class Level {
public static enum LevelType {
THETA, HEIGHT_AGL, HEIGHT_MSL, PRESSURE, SURFACE, TILT, MB_AGL, MAXW, TW0, TEMP, FRZ, DEFAULT
THETA, HEIGHT_AGL, HEIGHT_MSL, PRESSURE, SURFACE, TILT, MB_AGL, MAXW, TW0, TEMP, FRZ, DEFAULT, WBZ
};
protected LevelType type;

View file

@ -72,6 +72,9 @@ import com.raytheon.uf.edex.plugin.grid.dao.GridDao;
* Feb 15, 2013 1638 mschenke Moved DataURINotificationMessage to uf.common.dataplugin
* Mar 07, 2013 1587 bsteffen rewrite static data generation.
* Mar 14, 2013 1587 bsteffen Fix persisting to datastore.
* Apr 14, 2014 DR 16752 MPorricelli Add ensembleid to hash key to allow
* creation of static data for all perturbations
* of Ensemble models
* Apr 21, 2014 2060 njensen Remove dependency on grid dataURI column
*
* </pre>
@ -446,12 +449,15 @@ public class StaticDataGenerator {
private final int forecastTime;
private final int coverageid;
private final String ensembleid;
public CacheKey(GridRecord record) {
this.datasetid = record.getDatasetId();
this.refTime = record.getDataTime().getRefTime();
this.forecastTime = record.getDataTime().getFcstTime();
this.coverageid = record.getLocation().getId();
this.ensembleid = record.getEnsembleId();
}
@Override
@ -464,6 +470,8 @@ public class StaticDataGenerator {
result = (prime * result) + forecastTime;
result = (prime * result)
+ ((refTime == null) ? 0 : refTime.hashCode());
result = (prime * result)
+ ((ensembleid == null) ? 0 : ensembleid.hashCode());
return result;
}
@ -499,6 +507,13 @@ public class StaticDataGenerator {
} else if (!refTime.equals(other.refTime)) {
return false;
}
if (ensembleid == null) {
if (other.ensembleid != null) {
return false;
}
} else if (!ensembleid.equals(other.ensembleid)) {
return false;
}
return true;
}

View file

@ -732,6 +732,12 @@
<versionsToKeep>5</versionsToKeep>
<modTimeToWait>00-00:15:00</modTimeToWait>
</rule>
<!-- Purge rule for the GFS199 (Guam-GFSDNG) model -->
<rule>
<keyValue>GFS199</keyValue>
<versionsToKeep>4</versionsToKeep>
<modTimeToWait>00-01:00:00</modTimeToWait>
</rule>
<!-- Purge rules for the Multi-grid Hurricane Wave Models -->
<rule>

View file

@ -58,6 +58,7 @@ import conf.TDBConfig as config
# 10/29/10 7354 cjeanbap Updated if-statement to handle None
# 12/07/10 7656 cjeanbap Retrieve environment variable.
# 04/07/11 8686 cjeanbap Fixed $ACTION has -i associated
# 05/12/14 16954 kshrestha Added Multiple flag functionality for textdb
##############################################################################
class TextDB:
@ -226,6 +227,7 @@ class TextDB:
msg = MSG.Message(True)
msg.initializeMessage(False)
commands = self.commands['command']
isJoin = False
for command in commands:
data = self.commands[command]
message = config.message[command]
@ -233,6 +235,8 @@ class TextDB:
for tuple in message[config.MSG_START:]:
key = tuple[config.MSG_KEY]
value = tuple[config.MSG_VALUE]
if ((key == "SUBOP") and (value == "JOIN")):
isJoin = True
if isinstance(value,types.IntType):
if args == config.MSG_VAR_ARGS:
for item in data:
@ -242,6 +246,9 @@ class TextDB:
if ((key == "SITE") and (self.commands.get("site_node") is not None) and (len(self.commands.get("site_node")) == 0)):
val = str(os.getenv("sitename"))
msg.addProperty(name=key,value=val,replace=True)
elif(isJoin == True):
msg.addProperty(name=key,value=data,replace=True)
isJoin = False
else:
msg.addProperty(name=key,value=data[value],replace=True)
else:
@ -472,7 +479,7 @@ class TextDB:
subJoins = self.commands.get(key)
length = len(self.commands.get(key))
#specifically looking for config.flags of subJoins
if length == 6:
if length <= 6:
for pos in range(0, length, 2):
value = config.flags.get(subJoins[pos])[0]
try:

View file

@ -42,6 +42,7 @@
# include path to python lib.
# 11/02/12 1236 dgilling Add --forcepractice flag to
# bypass test mode check.
# 05/09/12 16215 m.gamazaychikov Added quotes around $flag.
##############################################################################
# this allows you to run this script from outside of ./bin
@ -59,11 +60,11 @@ export PYTHONPATH=${RUN_FROM_DIR}/src:$PYTHONPATH
forcePractice="FALSE"
declare -a parsedArgs
for flag in $@; do
if [ $flag == "--forcepractice" ]; then
for flag in "$@"; do
if [ "$flag" == "--forcepractice" ]; then
forcePractice="TRUE"
else
parsedArgs=("${parsedArgs[@]}" $flag)
parsedArgs=("${parsedArgs[@]}" "$flag")
fi
done

View file

@ -12,8 +12,11 @@
# This allows you to call this script from outside of ./standard/bin
RUN_FROM_DIR=`dirname $0`
. $RUN_FROM_DIR/../../set_hydro_env
export MPE_TRANSMIT_BIAS=$(get_apps_defaults mpe_transmit_bias)
export TRANSMIT_BIAS_ON_RERUN=$(get_apps_defaults transmit_bias_on_rerun)
export PPROC_BIN=$(get_apps_defaults pproc_bin)
#
# Transmit the RFC bias message if the user has
# elected to do so on reruns.
#
@ -21,6 +24,8 @@ if [[ "$MPE_TRANSMIT_BIAS" = "ON" && "$TRANSMIT_BIAS_ON_RERUN" = "YES" ]]
then
year=`echo $2 | cut -c5-8`
monthday=`echo $2 | cut -c1-4`
hour=`echo $1`
echo $year$monthday$1
$PPROC_BIN/transmit_rfc_bias $year$monthday$1
fi

View file

@ -43,13 +43,13 @@ RUN_FROM_DIR=`dirname $0`
# These lines are commented out because this script will be run
# from mpe_editor using mpe_editor's environment. If this script
# is run stand alone, these lines must be uncommented.
export FXA_HOME=/awips/fxa
. $FXA_HOME/readenv.sh
. $RUN_FROM_DIR/../../set_hydro_env
export RFC_BIAS_OUTPUT_DIR=$(get_apps_defaults rfc_bias_output_dir)
export PROCESS_BIAS_LOG_DIR=$(get_apps_defaults process_bias_log_dir)
export MPE_TRANSMIT_BIAS=$(get_apps_defaults mpe_transmit_bias)
export PPROC_BIN=$(get_apps_defaults pproc_bin)
export FXA_LOCAL_SITE=$(get_apps_defaults fxa_local_site)
export SYS_JAVA_DIR=$(get_apps_defaults sys_java_dir)
# set java classpath
export CLASSPATH=$DB_DRIVER_PATH:$PPROC_BIN/bias_trans.jar