From 4c06eca38e4441eee69a5a54cf96790becb750b9 Mon Sep 17 00:00:00 2001 From: "Fay.Liang" Date: Mon, 21 Jul 2014 12:51:31 -0400 Subject: [PATCH 01/11] ASM #15630 -- GFE: Missing ISC Wind Grids Change-Id: I289f1fafac8e034faa38dcddf639d5744fabe901 Former-commit-id: 8de6be5219b267ed29e8298dd9d9fad5d3552031 [formerly a5791db7cbbea5e60a83e8399f2cf0e99ab97ed2 [formerly db678db964b46a46e062cd0602cf9ce8bc96e4cd]] Former-commit-id: a5791db7cbbea5e60a83e8399f2cf0e99ab97ed2 Former-commit-id: 212fcd9eb403c3397564a55267fa0bbadf5c8d65 --- .../edex_static/base/gfe/isc/iscMosaic.py | 30 ++++++++++++------- 1 file changed, 19 insertions(+), 11 deletions(-) diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/gfe/isc/iscMosaic.py b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/gfe/isc/iscMosaic.py index 5fdd6066ac..b145b1189d 100644 --- a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/gfe/isc/iscMosaic.py +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/gfe/isc/iscMosaic.py @@ -38,6 +38,7 @@ from com.raytheon.uf.common.time import TimeRange from com.vividsolutions.jts.geom import Coordinate from java.awt import Point +from com.raytheon.edex.plugin.gfe.server import GridParmManager from com.raytheon.edex.plugin.gfe.config import IFPServerConfigManager from com.raytheon.edex.plugin.gfe.smartinit import IFPDB from com.raytheon.uf.common.dataplugin.gfe import GridDataHistory @@ -61,6 +62,7 @@ from com.raytheon.uf.common.dataplugin.gfe.reference import ReferenceID from com.raytheon.uf.common.dataplugin.gfe.reference import ReferenceData_CoordinateType as CoordinateType from com.raytheon.uf.edex.database.cluster import ClusterLockUtils from com.raytheon.uf.edex.database.cluster import ClusterTask +from java.lang import System # # Port of iscMosaic.py @@ -80,13 +82,10 @@ from com.raytheon.uf.edex.database.cluster import ClusterTask # 05/23/13 1759 dgilling Remove unnecessary imports. # 06/05/13 2063 dgilling Change __siteInDbGrid() to # call IFPWE.history() like A1. -# 09/05/13 2307 dgilling Fix breakage caused by #2044. -# 10/31/2013 2508 randerso Change to use DiscreteGridSlice.getKeys() # 11/05/13 2517 randerso Restructured logging so it coulde be used by WECache # Changed WECache to limit the number of cached grids kept in memory # 01/09/14 16952 randerso Fix regression made in #2517 which caused errors with overlapping grids # 02/04/14 17042 ryu Check in changes for randerso. -# 04/11/2014 17242 David Gillingham (code checked in by zhao) # BATCH_DELAY = 0.0 @@ -419,12 +418,18 @@ class WECache(object): elif gridType == "VECTOR": vecGrids = grid.__numpy__ return (vecGrids[0], vecGrids[1]) - elif gridType == "WEATHER" or gridType =="DISCRETE": + elif gridType == "WEATHER": keys = grid.getKeys() keyList = [] for theKey in keys: keyList.append(theKey.toString()) return (grid.__numpy__[0], keyList) + elif gridType == "DISCRETE": + keys = grid.getKey() + keyList = [] + for theKey in keys: + keyList.append(theKey.toString()) + return (grid.__numpy__[0], keyList) def __encodeGridHistory(self, histories): retVal = [] @@ -726,6 +731,9 @@ class IscMosaic: # process incoming grids for i in xrange(len(inTimes)): + # update cluster lock time to avoid time out + ClusterLockUtils.updateLockTime("ISC Write Lock", parmName , System.currentTimeMillis()) + # Put in a delay so we don't hammer the server so hard. if self.__gridDelay > 0.0: time.sleep(self.__gridDelay) @@ -747,7 +755,7 @@ class IscMosaic: grid = self.__validateAdjustWeatherKeys(grid, self.__parmName, tr) - grid = self.__remap(self.__dbwe, grid, inGeoDict, inFillV) + grid = self.__remap(self.__dbwe.getParmid(), grid, inGeoDict, inFillV) # if rate parm, then may need to adjust the values if self.__rateParm and inTimes[i] != tr: @@ -1224,12 +1232,13 @@ class IscMosaic: return grid.astype(numpy.float32) - def __remap(self, we, grid, inGeoDict, inFillV): - gpi = we.getGpi() + def __remap(self, pid, grid, inGeoDict, inFillV): + + gpi = GridParmManager.getGridParmInfo(pid).getPayload() gridType = gpi.getGridType().toString() - gs = self.__decodeGridSlice(we, grid, TimeRange()) + gs = self.__decodeGridSlice(pid, grid, TimeRange()) pd = self.__decodeProj(inGeoDict) fill = inFillV @@ -1259,10 +1268,9 @@ class IscMosaic: newGrid = mapper.remap(gs.getDiscreteGrid(), fill, fill) return (newGrid.__numpy__[0], grid[1]) - def __decodeGridSlice(self, we, value, tr, history=None): - pid = we.getParmid() - gpi = we.getGpi() + def __decodeGridSlice(self, pid, value, tr, history=None): + gpi = GridParmManager.getGridParmInfo(pid).getPayload() gridType = gpi.getGridType().toString() hist = ArrayList() From c3c267fbdca4cf25498a08a3fee5d47652a6e49d Mon Sep 17 00:00:00 2001 From: Shawn Hooper Date: Tue, 22 Jul 2014 10:15:46 -0500 Subject: [PATCH 02/11] Revert "ASM #15630 -- GFE: Missing ISC Wind Grids" This reverts commit 4c06eca38e4441eee69a5a54cf96790becb750b9 [formerly 212fcd9eb403c3397564a55267fa0bbadf5c8d65] [formerly a5791db7cbbea5e60a83e8399f2cf0e99ab97ed2] [formerly 8de6be5219b267ed29e8298dd9d9fad5d3552031 [formerly a5791db7cbbea5e60a83e8399f2cf0e99ab97ed2 [formerly db678db964b46a46e062cd0602cf9ce8bc96e4cd]]]. Change-Id: Ib5d03f81b35c0371e063a89739b823b8264c439f Former-commit-id: 65802e34fd03d5be5e52db57188d6043e0fe9a97 [formerly 425bcea65d86fce5c1781d186e3655558245f45d [formerly 7dcfb55353ba7ec9d0619737da37781b0b186e5d]] Former-commit-id: 425bcea65d86fce5c1781d186e3655558245f45d Former-commit-id: faf934a05a32efbd196196b56a52b820587d6346 --- .../edex_static/base/gfe/isc/iscMosaic.py | 30 +++++++------------ 1 file changed, 11 insertions(+), 19 deletions(-) diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/gfe/isc/iscMosaic.py b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/gfe/isc/iscMosaic.py index b145b1189d..5fdd6066ac 100644 --- a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/gfe/isc/iscMosaic.py +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/gfe/isc/iscMosaic.py @@ -38,7 +38,6 @@ from com.raytheon.uf.common.time import TimeRange from com.vividsolutions.jts.geom import Coordinate from java.awt import Point -from com.raytheon.edex.plugin.gfe.server import GridParmManager from com.raytheon.edex.plugin.gfe.config import IFPServerConfigManager from com.raytheon.edex.plugin.gfe.smartinit import IFPDB from com.raytheon.uf.common.dataplugin.gfe import GridDataHistory @@ -62,7 +61,6 @@ from com.raytheon.uf.common.dataplugin.gfe.reference import ReferenceID from com.raytheon.uf.common.dataplugin.gfe.reference import ReferenceData_CoordinateType as CoordinateType from com.raytheon.uf.edex.database.cluster import ClusterLockUtils from com.raytheon.uf.edex.database.cluster import ClusterTask -from java.lang import System # # Port of iscMosaic.py @@ -82,10 +80,13 @@ from java.lang import System # 05/23/13 1759 dgilling Remove unnecessary imports. # 06/05/13 2063 dgilling Change __siteInDbGrid() to # call IFPWE.history() like A1. +# 09/05/13 2307 dgilling Fix breakage caused by #2044. +# 10/31/2013 2508 randerso Change to use DiscreteGridSlice.getKeys() # 11/05/13 2517 randerso Restructured logging so it coulde be used by WECache # Changed WECache to limit the number of cached grids kept in memory # 01/09/14 16952 randerso Fix regression made in #2517 which caused errors with overlapping grids # 02/04/14 17042 ryu Check in changes for randerso. +# 04/11/2014 17242 David Gillingham (code checked in by zhao) # BATCH_DELAY = 0.0 @@ -418,18 +419,12 @@ class WECache(object): elif gridType == "VECTOR": vecGrids = grid.__numpy__ return (vecGrids[0], vecGrids[1]) - elif gridType == "WEATHER": + elif gridType == "WEATHER" or gridType =="DISCRETE": keys = grid.getKeys() keyList = [] for theKey in keys: keyList.append(theKey.toString()) return (grid.__numpy__[0], keyList) - elif gridType == "DISCRETE": - keys = grid.getKey() - keyList = [] - for theKey in keys: - keyList.append(theKey.toString()) - return (grid.__numpy__[0], keyList) def __encodeGridHistory(self, histories): retVal = [] @@ -731,9 +726,6 @@ class IscMosaic: # process incoming grids for i in xrange(len(inTimes)): - # update cluster lock time to avoid time out - ClusterLockUtils.updateLockTime("ISC Write Lock", parmName , System.currentTimeMillis()) - # Put in a delay so we don't hammer the server so hard. if self.__gridDelay > 0.0: time.sleep(self.__gridDelay) @@ -755,7 +747,7 @@ class IscMosaic: grid = self.__validateAdjustWeatherKeys(grid, self.__parmName, tr) - grid = self.__remap(self.__dbwe.getParmid(), grid, inGeoDict, inFillV) + grid = self.__remap(self.__dbwe, grid, inGeoDict, inFillV) # if rate parm, then may need to adjust the values if self.__rateParm and inTimes[i] != tr: @@ -1232,13 +1224,12 @@ class IscMosaic: return grid.astype(numpy.float32) - def __remap(self, pid, grid, inGeoDict, inFillV): - - gpi = GridParmManager.getGridParmInfo(pid).getPayload() + def __remap(self, we, grid, inGeoDict, inFillV): + gpi = we.getGpi() gridType = gpi.getGridType().toString() - gs = self.__decodeGridSlice(pid, grid, TimeRange()) + gs = self.__decodeGridSlice(we, grid, TimeRange()) pd = self.__decodeProj(inGeoDict) fill = inFillV @@ -1268,9 +1259,10 @@ class IscMosaic: newGrid = mapper.remap(gs.getDiscreteGrid(), fill, fill) return (newGrid.__numpy__[0], grid[1]) - def __decodeGridSlice(self, pid, value, tr, history=None): + def __decodeGridSlice(self, we, value, tr, history=None): + pid = we.getParmid() + gpi = we.getGpi() - gpi = GridParmManager.getGridParmInfo(pid).getPayload() gridType = gpi.getGridType().toString() hist = ArrayList() From 11196e72751023ba4f67e89e70853e6208763bef Mon Sep 17 00:00:00 2001 From: "Shawn.Hooper" Date: Tue, 22 Jul 2014 15:55:31 -0400 Subject: [PATCH 03/11] ASM #15630 - Check-in fix for GFE: Missing ISC Wind Grids on behalf of Ron Anderson Change-Id: I9053182b6c02d6c77e10e23b017b94bcff4da58b Former-commit-id: ae272328a3b2755e272a335114993f9278e06aea [formerly 2a32d5945c91a22f4c48030c20a62b9842d19706 [formerly 4bca3ffd258a6869150154e93abb652a1f22bc4d]] Former-commit-id: 2a32d5945c91a22f4c48030c20a62b9842d19706 Former-commit-id: a70786ff22e7216948248d7cc4d2bfde940c09ab --- .../utility/edex_static/base/gfe/isc/iscMosaic.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/gfe/isc/iscMosaic.py b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/gfe/isc/iscMosaic.py index 5fdd6066ac..70bf4b68fe 100644 --- a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/gfe/isc/iscMosaic.py +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/gfe/isc/iscMosaic.py @@ -30,6 +30,7 @@ except: import numpy import JUtil +from java.lang import System from java.util import ArrayList from java.util import LinkedHashMap from com.raytheon.uf.common.dataplugin.gfe.grid import Grid2DFloat @@ -87,6 +88,7 @@ from com.raytheon.uf.edex.database.cluster import ClusterTask # 01/09/14 16952 randerso Fix regression made in #2517 which caused errors with overlapping grids # 02/04/14 17042 ryu Check in changes for randerso. # 04/11/2014 17242 David Gillingham (code checked in by zhao) +# 07/22/2014 17484 randerso Update cluster lock time to prevent time out # BATCH_DELAY = 0.0 @@ -726,6 +728,9 @@ class IscMosaic: # process incoming grids for i in xrange(len(inTimes)): + # update cluster lock time to avoid time out + ClusterLockUtils.updateLockTime("ISC Write Lock", parmName ,System.currentTimeMillis()) + # Put in a delay so we don't hammer the server so hard. if self.__gridDelay > 0.0: time.sleep(self.__gridDelay) From a258d2fe226b72af7084db8b133bb42eaf961b47 Mon Sep 17 00:00:00 2001 From: "Ying-Lian.Shi" Date: Tue, 22 Jul 2014 19:18:16 +0000 Subject: [PATCH 04/11] ASM #15649 - these 5 files are rolled back to 14.1.3 Change-Id: Ifc52168f1faf3984f2a2d72947273686c5a00fd9 Former-commit-id: 1f6d24a076017b717d6b38ae9f8e592c4723017b [formerly 22d46f265834021bf6a6a593e6df2347cd5d579e [formerly ab5a6807a591605e230d4180f1dcf3c2eaa8657f]] Former-commit-id: 22d46f265834021bf6a6a593e6df2347cd5d579e Former-commit-id: 9dbfbbe0c30e4c9f762baf4c1986ce8e1e0c5a25 --- nativeLib/edex_com/src/Notification_types.cpp | 18 +- .../src/PointDataServer_constants.cpp | 22 +- .../edex_com/src/PointDataServer_types.cpp | 408 ++-- .../edex_com/src/PointData_constants.cpp | 22 +- nativeLib/edex_com/src/PointData_types.cpp | 1999 ++++++++--------- 5 files changed, 1192 insertions(+), 1277 deletions(-) diff --git a/nativeLib/edex_com/src/Notification_types.cpp b/nativeLib/edex_com/src/Notification_types.cpp index 651ae811c6..6a4c9de10a 100644 --- a/nativeLib/edex_com/src/Notification_types.cpp +++ b/nativeLib/edex_com/src/Notification_types.cpp @@ -1,5 +1,5 @@ /** - * Autogenerated by Thrift Compiler (0.9.0) + * Autogenerated by Thrift Compiler (0.8.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated @@ -35,6 +35,7 @@ * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * 07/29/13 2215 bkowal Regenerated for thrift 0.9.0 + * 07/22/14 15649 lshi Rollback to thrift 0.8.0 * * * @@ -43,14 +44,13 @@ */ #include "Notification_types.h" -#include - const char* com_raytheon_uf_common_dataplugin_message_DataURINotificationMessage::ascii_fingerprint = "ACE4F644F0FDD289DDC4EE5B83BC13C0"; const uint8_t com_raytheon_uf_common_dataplugin_message_DataURINotificationMessage::binary_fingerprint[16] = {0xAC,0xE4,0xF6,0x44,0xF0,0xFD,0xD2,0x89,0xDD,0xC4,0xEE,0x5B,0x83,0xBC,0x13,0xC0}; uint32_t com_raytheon_uf_common_dataplugin_message_DataURINotificationMessage::read(::apache::thrift::protocol::TProtocol* iprot) { + uint32_t xfer = 0; std::string fname; ::apache::thrift::protocol::TType ftype; @@ -75,14 +75,14 @@ uint32_t com_raytheon_uf_common_dataplugin_message_DataURINotificationMessage::r this->dataURIs.clear(); uint32_t _size0; ::apache::thrift::protocol::TType _etype3; - xfer += iprot->readListBegin(_etype3, _size0); + iprot->readListBegin(_etype3, _size0); this->dataURIs.resize(_size0); uint32_t _i4; for (_i4 = 0; _i4 < _size0; ++_i4) { xfer += iprot->readString(this->dataURIs[_i4]); } - xfer += iprot->readListEnd(); + iprot->readListEnd(); } this->__isset.dataURIs = true; } else { @@ -104,7 +104,6 @@ uint32_t com_raytheon_uf_common_dataplugin_message_DataURINotificationMessage::r uint32_t com_raytheon_uf_common_dataplugin_message_DataURINotificationMessage::write(::apache::thrift::protocol::TProtocol* oprot) const { uint32_t xfer = 0; xfer += oprot->writeStructBegin("com_raytheon_uf_common_dataplugin_message_DataURINotificationMessage"); - xfer += oprot->writeFieldBegin("dataURIs", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->dataURIs.size())); @@ -116,16 +115,9 @@ uint32_t com_raytheon_uf_common_dataplugin_message_DataURINotificationMessage::w xfer += oprot->writeListEnd(); } xfer += oprot->writeFieldEnd(); - xfer += oprot->writeFieldStop(); xfer += oprot->writeStructEnd(); return xfer; } -void swap(com_raytheon_uf_common_dataplugin_message_DataURINotificationMessage &a, com_raytheon_uf_common_dataplugin_message_DataURINotificationMessage &b) { - using ::std::swap; - swap(a.dataURIs, b.dataURIs); - swap(a.__isset, b.__isset); -} - diff --git a/nativeLib/edex_com/src/PointDataServer_constants.cpp b/nativeLib/edex_com/src/PointDataServer_constants.cpp index efda7a0ec5..d42c1c9302 100644 --- a/nativeLib/edex_com/src/PointDataServer_constants.cpp +++ b/nativeLib/edex_com/src/PointDataServer_constants.cpp @@ -1,10 +1,3 @@ -/** - * Autogenerated by Thrift Compiler (0.9.0) - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ - /***************************************************************************************** * COPYRIGHT (c), 2009, RAYTHEON COMPANY * ALL RIGHTS RESERVED, An Unpublished Work @@ -26,7 +19,8 @@ ******************************************************************************************/ /* - * Extended thrift protocol to handle messages from edex. + * Support for point data request capability to retrieve point data and metadata + * from EDEX Thrift service. * *
  *
@@ -34,13 +28,21 @@
  *
  * Date         Ticket#     Engineer    Description
  * ------------ ----------  ----------- --------------------------
- * 07/29/13       2215       bkowal     Regenerated for thrift 0.9.0
+ * 08/08/11     9696        gzhou       Initial Creation
+ * 07/29/13     2215        bkowal      Regenerated for thrift 0.9.0
+ * 07/22/14     15649       lshi        Rollback to Initial Creation
  *
  * 
* - * @author bkowal + * @author gzhou * @version 1 */ + +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + */ #include "PointDataServer_constants.h" diff --git a/nativeLib/edex_com/src/PointDataServer_types.cpp b/nativeLib/edex_com/src/PointDataServer_types.cpp index e8c8713053..7c20e78d3d 100644 --- a/nativeLib/edex_com/src/PointDataServer_types.cpp +++ b/nativeLib/edex_com/src/PointDataServer_types.cpp @@ -1,10 +1,3 @@ -/** - * Autogenerated by Thrift Compiler (0.9.0) - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ - /***************************************************************************************** * COPYRIGHT (c), 2009, RAYTHEON COMPANY * ALL RIGHTS RESERVED, An Unpublished Work @@ -26,7 +19,8 @@ ******************************************************************************************/ /* - * Extended thrift protocol to handle messages from edex. + * Support for point data request capability to retrieve point data and metadata + * from EDEX Thrift service. * *
  *
@@ -34,240 +28,222 @@
  *
  * Date         Ticket#     Engineer    Description
  * ------------ ----------  ----------- --------------------------
- * 07/29/13       2215       bkowal     Regenerated for thrift 0.9.0
+ * 08/08/11     9696        gzhou       Initial Creation
+ * 07/29/13     2215        bkowal      Regenerated for thrift 0.9.0
+ * 07/22/14     15649       lshi        Rollback to Initial Creation
  *
  * 
* - * @author bkowal + * @author gzhou * @version 1 */ + #include "PointDataServer_types.h" -#include +const char + * com_raytheon_uf_common_dataquery_requests_ConstraintType::ascii_fingerprint = + "EFB929595D312AC8F305D5A794CFEDA1"; +const uint8_t + com_raytheon_uf_common_dataquery_requests_ConstraintType::binary_fingerprint[16] = + { 0xEF, 0xB9, 0x29, 0x59, 0x5D, 0x31, 0x2A, 0xC8, 0xF3, 0x05, + 0xD5, 0xA7, 0x94, 0xCF, 0xED, 0xA1 }; +uint32_t com_raytheon_uf_common_dataquery_requests_ConstraintType::read( + ::apache::thrift::protocol::TProtocol* iprot) { + uint32_t xfer = 0; + std::string fname; + ::apache::thrift::protocol::TType ftype; + int16_t fid; -const char* com_raytheon_uf_common_dataquery_requests_ConstraintType::ascii_fingerprint = "EFB929595D312AC8F305D5A794CFEDA1"; -const uint8_t com_raytheon_uf_common_dataquery_requests_ConstraintType::binary_fingerprint[16] = {0xEF,0xB9,0x29,0x59,0x5D,0x31,0x2A,0xC8,0xF3,0x05,0xD5,0xA7,0x94,0xCF,0xED,0xA1}; + xfer += iprot->readStructBegin(fname); -uint32_t com_raytheon_uf_common_dataquery_requests_ConstraintType::read(::apache::thrift::protocol::TProtocol* iprot) { + using ::apache::thrift::protocol::TProtocolException; - uint32_t xfer = 0; - std::string fname; - ::apache::thrift::protocol::TType ftype; - int16_t fid; + xfer += iprot->readFieldBegin(fname, ftype, fid); + if (ftype == ::apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(operand); + this->__isset.operand = true; + } else + xfer += iprot->skip(ftype); + xfer += iprot->readFieldEnd(); - xfer += iprot->readStructBegin(fname); + xfer += iprot->readStructEnd(); - using ::apache::thrift::protocol::TProtocolException; - - - while (true) - { - xfer += iprot->readFieldBegin(fname, ftype, fid); - if (ftype == ::apache::thrift::protocol::T_STOP) { - break; - } - switch (fid) - { - case 1: - if (ftype == ::apache::thrift::protocol::T_STRING) { - xfer += iprot->readString(this->operand); - this->__isset.operand = true; - } else { - xfer += iprot->skip(ftype); - } - break; - default: - xfer += iprot->skip(ftype); - break; - } - xfer += iprot->readFieldEnd(); - } - - xfer += iprot->readStructEnd(); - - return xfer; + return xfer; } -uint32_t com_raytheon_uf_common_dataquery_requests_ConstraintType::write(::apache::thrift::protocol::TProtocol* oprot) const { - uint32_t xfer = 0; - xfer += oprot->writeStructBegin("com_raytheon_uf_common_dataquery_requests_ConstraintType"); - - xfer += oprot->writeFieldBegin("operand", ::apache::thrift::protocol::T_STRING, 1); - xfer += oprot->writeString(this->operand); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldStop(); - xfer += oprot->writeStructEnd(); - return xfer; +uint32_t com_raytheon_uf_common_dataquery_requests_ConstraintType::write( + ::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer + += oprot->writeStructBegin( + "com_raytheon_uf_common_dataquery_requests_RequestConstraint$ConstraintType"); + xfer += oprot->writeFieldBegin("__enumValue__", + ::apache::thrift::protocol::T_STRING, 1); + xfer += oprot->writeString(this->operand); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeStructEnd(); + return xfer; } -void swap(com_raytheon_uf_common_dataquery_requests_ConstraintType &a, com_raytheon_uf_common_dataquery_requests_ConstraintType &b) { - using ::std::swap; - swap(a.operand, b.operand); - swap(a.__isset, b.__isset); +const char + * com_raytheon_uf_common_dataquery_requests_RequestConstraint::ascii_fingerprint = + "BDAF55DAA660FA1ADBE30760752211A8"; +const uint8_t + com_raytheon_uf_common_dataquery_requests_RequestConstraint::binary_fingerprint[16] = + { 0xBD, 0xAF, 0x55, 0xDA, 0xA6, 0x60, 0xFA, 0x1A, 0xDB, 0xE3, + 0x07, 0x60, 0x75, 0x22, 0x11, 0xA8 }; + +uint32_t com_raytheon_uf_common_dataquery_requests_RequestConstraint::read( + ::apache::thrift::protocol::TProtocol* iprot) { + + uint32_t xfer = 0; + std::string fname; + ::apache::thrift::protocol::TType ftype; + int16_t fid; + + xfer += iprot->readStructBegin(fname); + + using ::apache::thrift::protocol::TProtocolException; + + while (true) { + xfer += iprot->readFieldBegin(fname, ftype, fid); + if (ftype == ::apache::thrift::protocol::T_STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->constraintType.read(iprot); + this->__isset.constraintType = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == ::apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->constraintValue); + this->__isset.constraintValue = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; } -const char* com_raytheon_uf_common_dataquery_requests_RequestConstraint::ascii_fingerprint = "BDAF55DAA660FA1ADBE30760752211A8"; -const uint8_t com_raytheon_uf_common_dataquery_requests_RequestConstraint::binary_fingerprint[16] = {0xBD,0xAF,0x55,0xDA,0xA6,0x60,0xFA,0x1A,0xDB,0xE3,0x07,0x60,0x75,0x22,0x11,0xA8}; - -uint32_t com_raytheon_uf_common_dataquery_requests_RequestConstraint::read(::apache::thrift::protocol::TProtocol* iprot) { - - uint32_t xfer = 0; - std::string fname; - ::apache::thrift::protocol::TType ftype; - int16_t fid; - - xfer += iprot->readStructBegin(fname); - - using ::apache::thrift::protocol::TProtocolException; - - - while (true) - { - xfer += iprot->readFieldBegin(fname, ftype, fid); - if (ftype == ::apache::thrift::protocol::T_STOP) { - break; - } - switch (fid) - { - case 1: - if (ftype == ::apache::thrift::protocol::T_STRUCT) { - xfer += this->constraintType.read(iprot); - this->__isset.constraintType = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 2: - if (ftype == ::apache::thrift::protocol::T_STRING) { - xfer += iprot->readString(this->constraintValue); - this->__isset.constraintValue = true; - } else { - xfer += iprot->skip(ftype); - } - break; - default: - xfer += iprot->skip(ftype); - break; - } - xfer += iprot->readFieldEnd(); - } - - xfer += iprot->readStructEnd(); - - return xfer; +uint32_t com_raytheon_uf_common_dataquery_requests_RequestConstraint::write( + ::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin( + "com_raytheon_uf_common_dataquery_requests_RequestConstraint"); + xfer += oprot->writeFieldBegin("constraintType", + ::apache::thrift::protocol::T_STRUCT, 1); + xfer += this->constraintType.write(oprot); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("constraintValue", + ::apache::thrift::protocol::T_STRING, 2); + xfer += oprot->writeString(this->constraintValue); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; } -uint32_t com_raytheon_uf_common_dataquery_requests_RequestConstraint::write(::apache::thrift::protocol::TProtocol* oprot) const { - uint32_t xfer = 0; - xfer += oprot->writeStructBegin("com_raytheon_uf_common_dataquery_requests_RequestConstraint"); +const char + * com_raytheon_uf_common_pointdata_PointDataServerRequest::ascii_fingerprint = + "C9F1CC9CD1A896EE01B7C5215E2BE99F"; +const uint8_t + com_raytheon_uf_common_pointdata_PointDataServerRequest::binary_fingerprint[16] = + { 0xC9, 0xF1, 0xCC, 0x9C, 0xD1, 0xA8, 0x96, 0xEE, 0x01, 0xB7, + 0xC5, 0x21, 0x5E, 0x2B, 0xE9, 0x9F }; - xfer += oprot->writeFieldBegin("constraintType", ::apache::thrift::protocol::T_STRUCT, 1); - xfer += this->constraintType.write(oprot); - xfer += oprot->writeFieldEnd(); +uint32_t com_raytheon_uf_common_pointdata_PointDataServerRequest::read( + ::apache::thrift::protocol::TProtocol* iprot) { - xfer += oprot->writeFieldBegin("constraintValue", ::apache::thrift::protocol::T_STRING, 2); - xfer += oprot->writeString(this->constraintValue); - xfer += oprot->writeFieldEnd(); + uint32_t xfer = 0; + std::string fname; + ::apache::thrift::protocol::TType ftype; + int16_t fid; - xfer += oprot->writeFieldStop(); - xfer += oprot->writeStructEnd(); - return xfer; + xfer += iprot->readStructBegin(fname); + + using ::apache::thrift::protocol::TProtocolException; + + while (true) { + xfer += iprot->readFieldBegin(fname, ftype, fid); + if (ftype == ::apache::thrift::protocol::T_STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == ::apache::thrift::protocol::T_MAP) { + { + this->rcMap.clear(); + uint32_t _size0; + ::apache::thrift::protocol::TType _ktype1; + ::apache::thrift::protocol::TType _vtype2; + iprot->readMapBegin(_ktype1, _vtype2, _size0); + uint32_t _i4; + for (_i4 = 0; _i4 < _size0; ++_i4) { + std::string _key5; + xfer += iprot->readString(_key5); + com_raytheon_uf_common_dataquery_requests_RequestConstraint + & _val6 = this->rcMap[_key5]; + xfer += _val6.read(iprot); + } + iprot->readMapEnd(); + } + this->__isset.rcMap = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; } -void swap(com_raytheon_uf_common_dataquery_requests_RequestConstraint &a, com_raytheon_uf_common_dataquery_requests_RequestConstraint &b) { - using ::std::swap; - swap(a.constraintType, b.constraintType); - swap(a.constraintValue, b.constraintValue); - swap(a.__isset, b.__isset); +uint32_t com_raytheon_uf_common_pointdata_PointDataServerRequest::write( + ::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin( + "com_raytheon_uf_common_pointdata_PointDataServerRequest"); + xfer += oprot->writeFieldBegin("rcMap", ::apache::thrift::protocol::T_MAP, + 1); + { + xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, + ::apache::thrift::protocol::T_STRUCT, this->rcMap.size()); + std::map::const_iterator + _iter7; + for (_iter7 = this->rcMap.begin(); _iter7 != this->rcMap.end(); ++_iter7) { + xfer += oprot->writeStructBegin("11"); + xfer += oprot->writeString(_iter7->first); + xfer += oprot->writeStructEnd(); + xfer += _iter7->second.write(oprot); + } + xfer += oprot->writeMapEnd(); + } + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; } -const char* com_raytheon_uf_common_pointdata_PointDataServerRequest::ascii_fingerprint = "C9F1CC9CD1A896EE01B7C5215E2BE99F"; -const uint8_t com_raytheon_uf_common_pointdata_PointDataServerRequest::binary_fingerprint[16] = {0xC9,0xF1,0xCC,0x9C,0xD1,0xA8,0x96,0xEE,0x01,0xB7,0xC5,0x21,0x5E,0x2B,0xE9,0x9F}; - -uint32_t com_raytheon_uf_common_pointdata_PointDataServerRequest::read(::apache::thrift::protocol::TProtocol* iprot) { - - uint32_t xfer = 0; - std::string fname; - ::apache::thrift::protocol::TType ftype; - int16_t fid; - - xfer += iprot->readStructBegin(fname); - - using ::apache::thrift::protocol::TProtocolException; - - - while (true) - { - xfer += iprot->readFieldBegin(fname, ftype, fid); - if (ftype == ::apache::thrift::protocol::T_STOP) { - break; - } - switch (fid) - { - case 1: - if (ftype == ::apache::thrift::protocol::T_MAP) { - { - this->rcMap.clear(); - uint32_t _size0; - ::apache::thrift::protocol::TType _ktype1; - ::apache::thrift::protocol::TType _vtype2; - xfer += iprot->readMapBegin(_ktype1, _vtype2, _size0); - uint32_t _i4; - for (_i4 = 0; _i4 < _size0; ++_i4) - { - std::string _key5; - xfer += iprot->readString(_key5); - com_raytheon_uf_common_dataquery_requests_RequestConstraint& _val6 = this->rcMap[_key5]; - xfer += _val6.read(iprot); - } - xfer += iprot->readMapEnd(); - } - this->__isset.rcMap = true; - } else { - xfer += iprot->skip(ftype); - } - break; - default: - xfer += iprot->skip(ftype); - break; - } - xfer += iprot->readFieldEnd(); - } - - xfer += iprot->readStructEnd(); - - return xfer; -} - -uint32_t com_raytheon_uf_common_pointdata_PointDataServerRequest::write(::apache::thrift::protocol::TProtocol* oprot) const { - uint32_t xfer = 0; - xfer += oprot->writeStructBegin("com_raytheon_uf_common_pointdata_PointDataServerRequest"); - - xfer += oprot->writeFieldBegin("rcMap", ::apache::thrift::protocol::T_MAP, 1); - { - xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRUCT, static_cast(this->rcMap.size())); - std::map ::const_iterator _iter7; - for (_iter7 = this->rcMap.begin(); _iter7 != this->rcMap.end(); ++_iter7) - { - xfer += oprot->writeString(_iter7->first); - xfer += _iter7->second.write(oprot); - } - xfer += oprot->writeMapEnd(); - } - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldStop(); - xfer += oprot->writeStructEnd(); - return xfer; -} - -void swap(com_raytheon_uf_common_pointdata_PointDataServerRequest &a, com_raytheon_uf_common_pointdata_PointDataServerRequest &b) { - using ::std::swap; - swap(a.rcMap, b.rcMap); - swap(a.__isset, b.__isset); -} - - diff --git a/nativeLib/edex_com/src/PointData_constants.cpp b/nativeLib/edex_com/src/PointData_constants.cpp index d1320a0071..f9a3740b12 100644 --- a/nativeLib/edex_com/src/PointData_constants.cpp +++ b/nativeLib/edex_com/src/PointData_constants.cpp @@ -1,10 +1,3 @@ -/** - * Autogenerated by Thrift Compiler (0.9.0) - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ - /***************************************************************************************** * COPYRIGHT (c), 2009, RAYTHEON COMPANY * ALL RIGHTS RESERVED, An Unpublished Work @@ -26,7 +19,8 @@ ******************************************************************************************/ /* - * Extended thrift protocol to handle messages from edex. + * Support for point data request capability to retrieve point data + * from EDEX Thrift service. * *
  *
@@ -34,13 +28,21 @@
  *
  * Date         Ticket#     Engineer    Description
  * ------------ ----------  ----------- --------------------------
- * 07/29/13       2215       bkowal     Regenerated for thrift 0.9.0
+ * 01/18/10     3747        brockwoo    Initial Creation
+ * 07/29/13     2215        bkowal      Regenerated for thrift 0.9.0
+ * 07/22/14     15649       lshi		Rollback to Initial Creation
  *
  * 
* - * @author bkowal + * @author brockwoo * @version 1 */ + +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + */ #include "PointData_constants.h" diff --git a/nativeLib/edex_com/src/PointData_types.cpp b/nativeLib/edex_com/src/PointData_types.cpp index b9af07f958..b20d79c78f 100644 --- a/nativeLib/edex_com/src/PointData_types.cpp +++ b/nativeLib/edex_com/src/PointData_types.cpp @@ -1,10 +1,3 @@ -/** - * Autogenerated by Thrift Compiler (0.9.0) - * - * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING - * @generated - */ - /***************************************************************************************** * COPYRIGHT (c), 2009, RAYTHEON COMPANY * ALL RIGHTS RESERVED, An Unpublished Work @@ -26,7 +19,8 @@ ******************************************************************************************/ /* - * Extended thrift protocol to handle messages from edex. + * Support for point data request capability to retrieve point data + * from EDEX Thrift service. * *
  *
@@ -34,1091 +28,1040 @@
  *
  * Date         Ticket#     Engineer    Description
  * ------------ ----------  ----------- --------------------------
- * 07/29/13       2215       bkowal     Regenerated for thrift 0.9.0
+ * 01/18/10     3747        brockwoo    Initial Creation
+ * 07/29/13     2215        bkowal      Regenerated for thrift 0.9.0
+ * 07/22/14     15649       lshi        Rollback to Initial Creation
  *
  * 
* - * @author bkowal + * @author brockwoo * @version 1 */ + +/** + * Autogenerated by Thrift + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + */ #include "PointData_types.h" -#include +const char + * com_raytheon_uf_common_pointdata_ParameterDescription::ascii_fingerprint = + "F8914BAC237E22C5EFA279EDDBA3C5C6"; +const uint8_t + com_raytheon_uf_common_pointdata_ParameterDescription::binary_fingerprint[16] = { + 0xF8, 0x91, 0x4B, 0xAC, 0x23, 0x7E, 0x22, 0xC5, 0xEF, 0xA2, + 0x79, 0xED, 0xDB, 0xA3, 0xC5, 0xC6 }; +uint32_t com_raytheon_uf_common_pointdata_ParameterDescription::read( + apache::thrift::protocol::TProtocol* iprot) { + uint32_t xfer = 0; + std::string fname; + apache::thrift::protocol::TType ftype; + int16_t fid; -const char* com_raytheon_uf_common_pointdata_ParameterDescription::ascii_fingerprint = "F8914BAC237E22C5EFA279EDDBA3C5C6"; -const uint8_t com_raytheon_uf_common_pointdata_ParameterDescription::binary_fingerprint[16] = {0xF8,0x91,0x4B,0xAC,0x23,0x7E,0x22,0xC5,0xEF,0xA2,0x79,0xED,0xDB,0xA3,0xC5,0xC6}; + xfer += iprot->readStructBegin(fname); -uint32_t com_raytheon_uf_common_pointdata_ParameterDescription::read(::apache::thrift::protocol::TProtocol* iprot) { + using apache::thrift::protocol::TProtocolException; - uint32_t xfer = 0; - std::string fname; - ::apache::thrift::protocol::TType ftype; - int16_t fid; + while (true) { + xfer += iprot->readFieldBegin(fname, ftype, fid); + if (ftype == apache::thrift::protocol::T_STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->dimension); + this->__isset.dimension = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == apache::thrift::protocol::T_I32) { + xfer += iprot->readI32(this->dimensionAsInt); + this->__isset.dimensionAsInt = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 3: + if (ftype == apache::thrift::protocol::T_DOUBLE) { + xfer += iprot->readDouble(this->fillValue); + this->__isset.fillValue = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 4: + if (ftype == apache::thrift::protocol::T_I32) { + xfer += iprot->readI32(this->maxLength); + this->__isset.maxLength = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 5: + if (ftype == apache::thrift::protocol::T_I32) { + xfer += iprot->readI32(this->numDims); + this->__isset.numDims = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 6: + if (ftype == apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->parameterName); + this->__isset.parameterName = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 7: + if (ftype == apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->unit); + this->__isset.unit = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } - xfer += iprot->readStructBegin(fname); + xfer += iprot->readStructEnd(); - using ::apache::thrift::protocol::TProtocolException; - - - while (true) - { - xfer += iprot->readFieldBegin(fname, ftype, fid); - if (ftype == ::apache::thrift::protocol::T_STOP) { - break; - } - switch (fid) - { - case 1: - if (ftype == ::apache::thrift::protocol::T_STRING) { - xfer += iprot->readString(this->dimension); - this->__isset.dimension = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 2: - if (ftype == ::apache::thrift::protocol::T_I32) { - xfer += iprot->readI32(this->dimensionAsInt); - this->__isset.dimensionAsInt = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 3: - if (ftype == ::apache::thrift::protocol::T_DOUBLE) { - xfer += iprot->readDouble(this->fillValue); - this->__isset.fillValue = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 4: - if (ftype == ::apache::thrift::protocol::T_I32) { - xfer += iprot->readI32(this->maxLength); - this->__isset.maxLength = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 5: - if (ftype == ::apache::thrift::protocol::T_I32) { - xfer += iprot->readI32(this->numDims); - this->__isset.numDims = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 6: - if (ftype == ::apache::thrift::protocol::T_STRING) { - xfer += iprot->readString(this->parameterName); - this->__isset.parameterName = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 7: - if (ftype == ::apache::thrift::protocol::T_STRING) { - xfer += iprot->readString(this->unit); - this->__isset.unit = true; - } else { - xfer += iprot->skip(ftype); - } - break; - default: - xfer += iprot->skip(ftype); - break; - } - xfer += iprot->readFieldEnd(); - } - - xfer += iprot->readStructEnd(); - - return xfer; + return xfer; } -uint32_t com_raytheon_uf_common_pointdata_ParameterDescription::write(::apache::thrift::protocol::TProtocol* oprot) const { - uint32_t xfer = 0; - xfer += oprot->writeStructBegin("com_raytheon_uf_common_pointdata_ParameterDescription"); - - xfer += oprot->writeFieldBegin("dimension", ::apache::thrift::protocol::T_STRING, 1); - xfer += oprot->writeString(this->dimension); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("dimensionAsInt", ::apache::thrift::protocol::T_I32, 2); - xfer += oprot->writeI32(this->dimensionAsInt); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("fillValue", ::apache::thrift::protocol::T_DOUBLE, 3); - xfer += oprot->writeDouble(this->fillValue); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("maxLength", ::apache::thrift::protocol::T_I32, 4); - xfer += oprot->writeI32(this->maxLength); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("numDims", ::apache::thrift::protocol::T_I32, 5); - xfer += oprot->writeI32(this->numDims); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("parameterName", ::apache::thrift::protocol::T_STRING, 6); - xfer += oprot->writeString(this->parameterName); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("unit", ::apache::thrift::protocol::T_STRING, 7); - xfer += oprot->writeString(this->unit); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldStop(); - xfer += oprot->writeStructEnd(); - return xfer; +uint32_t com_raytheon_uf_common_pointdata_ParameterDescription::write( + apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin( + "com_raytheon_uf_common_pointdata_ParameterDescription"); + xfer += oprot->writeFieldBegin("dimension", + apache::thrift::protocol::T_STRING, 1); + xfer += oprot->writeString(this->dimension); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("dimensionAsInt", + apache::thrift::protocol::T_I32, 2); + xfer += oprot->writeI32(this->dimensionAsInt); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("fillValue", + apache::thrift::protocol::T_DOUBLE, 3); + xfer += oprot->writeDouble(this->fillValue); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("maxLength", + apache::thrift::protocol::T_I32, 4); + xfer += oprot->writeI32(this->maxLength); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("numDims", apache::thrift::protocol::T_I32, + 5); + xfer += oprot->writeI32(this->numDims); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("parameterName", + apache::thrift::protocol::T_STRING, 6); + xfer += oprot->writeString(this->parameterName); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("unit", apache::thrift::protocol::T_STRING, + 7); + xfer += oprot->writeString(this->unit); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; } -void swap(com_raytheon_uf_common_pointdata_ParameterDescription &a, com_raytheon_uf_common_pointdata_ParameterDescription &b) { - using ::std::swap; - swap(a.dimension, b.dimension); - swap(a.dimensionAsInt, b.dimensionAsInt); - swap(a.fillValue, b.fillValue); - swap(a.maxLength, b.maxLength); - swap(a.numDims, b.numDims); - swap(a.parameterName, b.parameterName); - swap(a.unit, b.unit); - swap(a.__isset, b.__isset); +const char + * com_raytheon_uf_common_pointdata_elements_StringPointDataObject::ascii_fingerprint = + "8432CD88CCBAE483EB61F9210360E5F9"; +const uint8_t + com_raytheon_uf_common_pointdata_elements_StringPointDataObject::binary_fingerprint[16] = { + 0x84, 0x32, 0xCD, 0x88, 0xCC, 0xBA, 0xE4, 0x83, 0xEB, 0x61, + 0xF9, 0x21, 0x03, 0x60, 0xE5, 0xF9 }; + +uint32_t com_raytheon_uf_common_pointdata_elements_StringPointDataObject::read( + apache::thrift::protocol::TProtocol* iprot) { + + uint32_t xfer = 0; + std::string fname; + apache::thrift::protocol::TType ftype; + int16_t fid; + + xfer += iprot->readStructBegin(fname); + + using apache::thrift::protocol::TProtocolException; + + while (true) { + xfer += iprot->readFieldBegin(fname, ftype, fid); + if (ftype == apache::thrift::protocol::T_STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == apache::thrift::protocol::T_STRUCT) { + xfer += this->description.read(iprot); + this->__isset.description = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == apache::thrift::protocol::T_I32) { + xfer += iprot->readI32(this->dimensions); + this->__isset.dimensions = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 3: + if (ftype == apache::thrift::protocol::T_LIST) { + { + this->stringData.clear(); + uint32_t _size0; + apache::thrift::protocol::TType _etype3; + iprot->readListBegin(_etype3, _size0); + this->stringData.resize(_size0); + uint32_t _i4; + for (_i4 = 0; _i4 < _size0; ++_i4) { + xfer += iprot->readString(this->stringData[_i4]); + } + iprot->readListEnd(); + } + this->__isset.stringData = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; } -const char* com_raytheon_uf_common_pointdata_elements_StringPointDataObject::ascii_fingerprint = "8432CD88CCBAE483EB61F9210360E5F9"; -const uint8_t com_raytheon_uf_common_pointdata_elements_StringPointDataObject::binary_fingerprint[16] = {0x84,0x32,0xCD,0x88,0xCC,0xBA,0xE4,0x83,0xEB,0x61,0xF9,0x21,0x03,0x60,0xE5,0xF9}; - -uint32_t com_raytheon_uf_common_pointdata_elements_StringPointDataObject::read(::apache::thrift::protocol::TProtocol* iprot) { - - uint32_t xfer = 0; - std::string fname; - ::apache::thrift::protocol::TType ftype; - int16_t fid; - - xfer += iprot->readStructBegin(fname); - - using ::apache::thrift::protocol::TProtocolException; - - - while (true) - { - xfer += iprot->readFieldBegin(fname, ftype, fid); - if (ftype == ::apache::thrift::protocol::T_STOP) { - break; - } - switch (fid) - { - case 1: - if (ftype == ::apache::thrift::protocol::T_STRUCT) { - xfer += this->description.read(iprot); - this->__isset.description = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 2: - if (ftype == ::apache::thrift::protocol::T_I32) { - xfer += iprot->readI32(this->dimensions); - this->__isset.dimensions = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 3: - if (ftype == ::apache::thrift::protocol::T_LIST) { - { - this->stringData.clear(); - uint32_t _size0; - ::apache::thrift::protocol::TType _etype3; - xfer += iprot->readListBegin(_etype3, _size0); - this->stringData.resize(_size0); - uint32_t _i4; - for (_i4 = 0; _i4 < _size0; ++_i4) - { - xfer += iprot->readString(this->stringData[_i4]); - } - xfer += iprot->readListEnd(); - } - this->__isset.stringData = true; - } else { - xfer += iprot->skip(ftype); - } - break; - default: - xfer += iprot->skip(ftype); - break; - } - xfer += iprot->readFieldEnd(); - } - - xfer += iprot->readStructEnd(); - - return xfer; +uint32_t com_raytheon_uf_common_pointdata_elements_StringPointDataObject::write( + apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin( + "com_raytheon_uf_common_pointdata_elements_StringPointDataObject"); + xfer += oprot->writeFieldBegin("description", + apache::thrift::protocol::T_STRUCT, 1); + xfer += this->description.write(oprot); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("dimensions", + apache::thrift::protocol::T_I32, 2); + xfer += oprot->writeI32(this->dimensions); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("stringData", + apache::thrift::protocol::T_LIST, 3); + { + xfer += oprot->writeListBegin(apache::thrift::protocol::T_STRING, + this->stringData.size()); + std::vector::const_iterator _iter5; + for (_iter5 = this->stringData.begin(); _iter5 + != this->stringData.end(); ++_iter5) { + xfer += oprot->writeString((*_iter5)); + } + xfer += oprot->writeListEnd(); + } + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; } -uint32_t com_raytheon_uf_common_pointdata_elements_StringPointDataObject::write(::apache::thrift::protocol::TProtocol* oprot) const { - uint32_t xfer = 0; - xfer += oprot->writeStructBegin("com_raytheon_uf_common_pointdata_elements_StringPointDataObject"); +const char + * com_raytheon_uf_common_pointdata_elements_FloatPointDataObject::ascii_fingerprint = + "3E090BC5D21490BE0856576B426175A4"; +const uint8_t + com_raytheon_uf_common_pointdata_elements_FloatPointDataObject::binary_fingerprint[16] = { + 0x3E, 0x09, 0x0B, 0xC5, 0xD2, 0x14, 0x90, 0xBE, 0x08, 0x56, + 0x57, 0x6B, 0x42, 0x61, 0x75, 0xA4 }; - xfer += oprot->writeFieldBegin("description", ::apache::thrift::protocol::T_STRUCT, 1); - xfer += this->description.write(oprot); - xfer += oprot->writeFieldEnd(); +uint32_t com_raytheon_uf_common_pointdata_elements_FloatPointDataObject::read( + apache::thrift::protocol::TProtocol* iprot) { - xfer += oprot->writeFieldBegin("dimensions", ::apache::thrift::protocol::T_I32, 2); - xfer += oprot->writeI32(this->dimensions); - xfer += oprot->writeFieldEnd(); + uint32_t xfer = 0; + std::string fname; + apache::thrift::protocol::TType ftype; + int16_t fid; - xfer += oprot->writeFieldBegin("stringData", ::apache::thrift::protocol::T_LIST, 3); - { - xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->stringData.size())); - std::vector ::const_iterator _iter5; - for (_iter5 = this->stringData.begin(); _iter5 != this->stringData.end(); ++_iter5) - { - xfer += oprot->writeString((*_iter5)); - } - xfer += oprot->writeListEnd(); - } - xfer += oprot->writeFieldEnd(); + xfer += iprot->readStructBegin(fname); - xfer += oprot->writeFieldStop(); - xfer += oprot->writeStructEnd(); - return xfer; + using apache::thrift::protocol::TProtocolException; + + while (true) { + xfer += iprot->readFieldBegin(fname, ftype, fid); + if (ftype == apache::thrift::protocol::T_STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == apache::thrift::protocol::T_STRUCT) { + xfer += this->description.read(iprot); + this->__isset.description = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == apache::thrift::protocol::T_I32) { + xfer += iprot->readI32(this->dimensions); + this->__isset.dimensions = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 3: + if (ftype == apache::thrift::protocol::T_LIST) { + { + this->floatData.clear(); + uint32_t _size6; + apache::thrift::protocol::TType _etype9; + iprot->readListBegin(_etype9, _size6); + this->floatData.resize(_size6); + uint32_t _i10; + for (_i10 = 0; _i10 < _size6; ++_i10) { + xfer += iprot->readI32(this->floatData[_i10]); + } + iprot->readListEnd(); + } + this->__isset.floatData = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + union { + int32_t i; + float f; + } u; + //u.i = (long)v; + //return (jfloat)u.f; + + int intCounter = 0; + for (intCounter = 0; intCounter < (int)this->floatData.size(); intCounter++) { + u.i = this->floatData.at(intCounter); + float holder = (float)u.f; + this->trueFloatData.push_back(holder); + } + + xfer += iprot->readStructEnd(); + + return xfer; } -void swap(com_raytheon_uf_common_pointdata_elements_StringPointDataObject &a, com_raytheon_uf_common_pointdata_elements_StringPointDataObject &b) { - using ::std::swap; - swap(a.description, b.description); - swap(a.dimensions, b.dimensions); - swap(a.stringData, b.stringData); - swap(a.__isset, b.__isset); +uint32_t com_raytheon_uf_common_pointdata_elements_FloatPointDataObject::write( + apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin( + "com_raytheon_uf_common_pointdata_elements_FloatPointDataObject"); + xfer += oprot->writeFieldBegin("description", + apache::thrift::protocol::T_STRUCT, 1); + xfer += this->description.write(oprot); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("dimensions", + apache::thrift::protocol::T_I32, 2); + xfer += oprot->writeI32(this->dimensions); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("floatData", + apache::thrift::protocol::T_LIST, 3); + { + xfer += oprot->writeListBegin(apache::thrift::protocol::T_I32, + this->floatData.size()); + std::vector::const_iterator _iter11; + for (_iter11 = this->floatData.begin(); _iter11 + != this->floatData.end(); ++_iter11) { + xfer += oprot->writeI32((*_iter11)); + } + xfer += oprot->writeListEnd(); + } + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; } -const char* com_raytheon_uf_common_pointdata_elements_FloatPointDataObject::ascii_fingerprint = "89584E5DAFB01EC75A91F6E88874692D"; -const uint8_t com_raytheon_uf_common_pointdata_elements_FloatPointDataObject::binary_fingerprint[16] = {0x89,0x58,0x4E,0x5D,0xAF,0xB0,0x1E,0xC7,0x5A,0x91,0xF6,0xE8,0x88,0x74,0x69,0x2D}; +const char + * com_raytheon_uf_common_pointdata_elements_IntPointDataObject::ascii_fingerprint = + "3E090BC5D21490BE0856576B426175A4"; +const uint8_t + com_raytheon_uf_common_pointdata_elements_IntPointDataObject::binary_fingerprint[16] = { + 0x3E, 0x09, 0x0B, 0xC5, 0xD2, 0x14, 0x90, 0xBE, 0x08, 0x56, + 0x57, 0x6B, 0x42, 0x61, 0x75, 0xA4 }; -uint32_t com_raytheon_uf_common_pointdata_elements_FloatPointDataObject::read(::apache::thrift::protocol::TProtocol* iprot) { +uint32_t com_raytheon_uf_common_pointdata_elements_IntPointDataObject::read( + apache::thrift::protocol::TProtocol* iprot) { - uint32_t xfer = 0; - std::string fname; - ::apache::thrift::protocol::TType ftype; - int16_t fid; + uint32_t xfer = 0; + std::string fname; + apache::thrift::protocol::TType ftype; + int16_t fid; - xfer += iprot->readStructBegin(fname); + xfer += iprot->readStructBegin(fname); - using ::apache::thrift::protocol::TProtocolException; + using apache::thrift::protocol::TProtocolException; + while (true) { + xfer += iprot->readFieldBegin(fname, ftype, fid); + if (ftype == apache::thrift::protocol::T_STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == apache::thrift::protocol::T_STRUCT) { + xfer += this->description.read(iprot); + this->__isset.description = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == apache::thrift::protocol::T_I32) { + xfer += iprot->readI32(this->dimensions); + this->__isset.dimensions = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 3: + if (ftype == apache::thrift::protocol::T_LIST) { + { + this->intData.clear(); + uint32_t _size12; + apache::thrift::protocol::TType _etype15; + iprot->readListBegin(_etype15, _size12); + this->intData.resize(_size12); + uint32_t _i16; + for (_i16 = 0; _i16 < _size12; ++_i16) { + xfer += iprot->readI32(this->intData[_i16]); + } + iprot->readListEnd(); + } + this->__isset.intData = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } - while (true) - { - xfer += iprot->readFieldBegin(fname, ftype, fid); - if (ftype == ::apache::thrift::protocol::T_STOP) { - break; - } - switch (fid) - { - case 1: - if (ftype == ::apache::thrift::protocol::T_STRUCT) { - xfer += this->description.read(iprot); - this->__isset.description = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 2: - if (ftype == ::apache::thrift::protocol::T_I32) { - xfer += iprot->readI32(this->dimensions); - this->__isset.dimensions = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 3: - if (ftype == ::apache::thrift::protocol::T_LIST) { - { - this->floatData.clear(); - uint32_t _size6; - ::apache::thrift::protocol::TType _etype9; - xfer += iprot->readListBegin(_etype9, _size6); - this->floatData.resize(_size6); - uint32_t _i10; - for (_i10 = 0; _i10 < _size6; ++_i10) - { - xfer += iprot->readI32(this->floatData[_i10]); - } - xfer += iprot->readListEnd(); - } - this->__isset.floatData = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 4: - if (ftype == ::apache::thrift::protocol::T_LIST) { - { - this->trueFloatData.clear(); - uint32_t _size11; - ::apache::thrift::protocol::TType _etype14; - xfer += iprot->readListBegin(_etype14, _size11); - this->trueFloatData.resize(_size11); - uint32_t _i15; - for (_i15 = 0; _i15 < _size11; ++_i15) - { - xfer += iprot->readDouble(this->trueFloatData[_i15]); - } - xfer += iprot->readListEnd(); - } - this->__isset.trueFloatData = true; - } else { - xfer += iprot->skip(ftype); - } - break; - default: - xfer += iprot->skip(ftype); - break; - } - xfer += iprot->readFieldEnd(); - } + xfer += iprot->readStructEnd(); - xfer += iprot->readStructEnd(); - - return xfer; + return xfer; } -uint32_t com_raytheon_uf_common_pointdata_elements_FloatPointDataObject::write(::apache::thrift::protocol::TProtocol* oprot) const { - uint32_t xfer = 0; - xfer += oprot->writeStructBegin("com_raytheon_uf_common_pointdata_elements_FloatPointDataObject"); - - xfer += oprot->writeFieldBegin("description", ::apache::thrift::protocol::T_STRUCT, 1); - xfer += this->description.write(oprot); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("dimensions", ::apache::thrift::protocol::T_I32, 2); - xfer += oprot->writeI32(this->dimensions); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("floatData", ::apache::thrift::protocol::T_LIST, 3); - { - xfer += oprot->writeListBegin(::apache::thrift::protocol::T_I32, static_cast(this->floatData.size())); - std::vector ::const_iterator _iter16; - for (_iter16 = this->floatData.begin(); _iter16 != this->floatData.end(); ++_iter16) - { - xfer += oprot->writeI32((*_iter16)); - } - xfer += oprot->writeListEnd(); - } - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("trueFloatData", ::apache::thrift::protocol::T_LIST, 4); - { - xfer += oprot->writeListBegin(::apache::thrift::protocol::T_DOUBLE, static_cast(this->trueFloatData.size())); - std::vector ::const_iterator _iter17; - for (_iter17 = this->trueFloatData.begin(); _iter17 != this->trueFloatData.end(); ++_iter17) - { - xfer += oprot->writeDouble((*_iter17)); - } - xfer += oprot->writeListEnd(); - } - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldStop(); - xfer += oprot->writeStructEnd(); - return xfer; +uint32_t com_raytheon_uf_common_pointdata_elements_IntPointDataObject::write( + apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin( + "com_raytheon_uf_common_pointdata_elements_IntPointDataObject"); + xfer += oprot->writeFieldBegin("description", + apache::thrift::protocol::T_STRUCT, 1); + xfer += this->description.write(oprot); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("dimensions", + apache::thrift::protocol::T_I32, 2); + xfer += oprot->writeI32(this->dimensions); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("intData", apache::thrift::protocol::T_LIST, + 3); + { + xfer += oprot->writeListBegin(apache::thrift::protocol::T_I32, + this->intData.size()); + std::vector::const_iterator _iter17; + for (_iter17 = this->intData.begin(); _iter17 != this->intData.end(); ++_iter17) { + xfer += oprot->writeI32((*_iter17)); + } + xfer += oprot->writeListEnd(); + } + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; } -void swap(com_raytheon_uf_common_pointdata_elements_FloatPointDataObject &a, com_raytheon_uf_common_pointdata_elements_FloatPointDataObject &b) { - using ::std::swap; - swap(a.description, b.description); - swap(a.dimensions, b.dimensions); - swap(a.floatData, b.floatData); - swap(a.trueFloatData, b.trueFloatData); - swap(a.__isset, b.__isset); +const char + * com_raytheon_uf_common_pointdata_elements_LongPointDataObject::ascii_fingerprint = + "135921A65C05459AFDDA382E27DDA225"; +const uint8_t + com_raytheon_uf_common_pointdata_elements_LongPointDataObject::binary_fingerprint[16] = { + 0x13, 0x59, 0x21, 0xA6, 0x5C, 0x05, 0x45, 0x9A, 0xFD, 0xDA, + 0x38, 0x2E, 0x27, 0xDD, 0xA2, 0x25 }; + +uint32_t com_raytheon_uf_common_pointdata_elements_LongPointDataObject::read( + apache::thrift::protocol::TProtocol* iprot) { + + uint32_t xfer = 0; + std::string fname; + apache::thrift::protocol::TType ftype; + int16_t fid; + + xfer += iprot->readStructBegin(fname); + + using apache::thrift::protocol::TProtocolException; + + while (true) { + xfer += iprot->readFieldBegin(fname, ftype, fid); + if (ftype == apache::thrift::protocol::T_STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == apache::thrift::protocol::T_STRUCT) { + xfer += this->description.read(iprot); + this->__isset.description = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == apache::thrift::protocol::T_I32) { + xfer += iprot->readI32(this->dimensions); + this->__isset.dimensions = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 3: + if (ftype == apache::thrift::protocol::T_LIST) { + { + this->longData.clear(); + uint32_t _size18; + apache::thrift::protocol::TType _etype21; + iprot->readListBegin(_etype21, _size18); + this->longData.resize(_size18); + uint32_t _i22; + for (_i22 = 0; _i22 < _size18; ++_i22) { + xfer += iprot->readI64(this->longData[_i22]); + } + iprot->readListEnd(); + } + this->__isset.longData = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; } -const char* com_raytheon_uf_common_pointdata_elements_IntPointDataObject::ascii_fingerprint = "3E090BC5D21490BE0856576B426175A4"; -const uint8_t com_raytheon_uf_common_pointdata_elements_IntPointDataObject::binary_fingerprint[16] = {0x3E,0x09,0x0B,0xC5,0xD2,0x14,0x90,0xBE,0x08,0x56,0x57,0x6B,0x42,0x61,0x75,0xA4}; - -uint32_t com_raytheon_uf_common_pointdata_elements_IntPointDataObject::read(::apache::thrift::protocol::TProtocol* iprot) { - - uint32_t xfer = 0; - std::string fname; - ::apache::thrift::protocol::TType ftype; - int16_t fid; - - xfer += iprot->readStructBegin(fname); - - using ::apache::thrift::protocol::TProtocolException; - - - while (true) - { - xfer += iprot->readFieldBegin(fname, ftype, fid); - if (ftype == ::apache::thrift::protocol::T_STOP) { - break; - } - switch (fid) - { - case 1: - if (ftype == ::apache::thrift::protocol::T_STRUCT) { - xfer += this->description.read(iprot); - this->__isset.description = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 2: - if (ftype == ::apache::thrift::protocol::T_I32) { - xfer += iprot->readI32(this->dimensions); - this->__isset.dimensions = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 3: - if (ftype == ::apache::thrift::protocol::T_LIST) { - { - this->intData.clear(); - uint32_t _size18; - ::apache::thrift::protocol::TType _etype21; - xfer += iprot->readListBegin(_etype21, _size18); - this->intData.resize(_size18); - uint32_t _i22; - for (_i22 = 0; _i22 < _size18; ++_i22) - { - xfer += iprot->readI32(this->intData[_i22]); - } - xfer += iprot->readListEnd(); - } - this->__isset.intData = true; - } else { - xfer += iprot->skip(ftype); - } - break; - default: - xfer += iprot->skip(ftype); - break; - } - xfer += iprot->readFieldEnd(); - } - - xfer += iprot->readStructEnd(); - - return xfer; +uint32_t com_raytheon_uf_common_pointdata_elements_LongPointDataObject::write( + apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin( + "com_raytheon_uf_common_pointdata_elements_LongPointDataObject"); + xfer += oprot->writeFieldBegin("description", + apache::thrift::protocol::T_STRUCT, 1); + xfer += this->description.write(oprot); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("dimensions", + apache::thrift::protocol::T_I32, 2); + xfer += oprot->writeI32(this->dimensions); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("longData", + apache::thrift::protocol::T_LIST, 3); + { + xfer += oprot->writeListBegin(apache::thrift::protocol::T_I64, + this->longData.size()); + std::vector::const_iterator _iter23; + for (_iter23 = this->longData.begin(); _iter23 != this->longData.end(); ++_iter23) { + xfer += oprot->writeI64((*_iter23)); + } + xfer += oprot->writeListEnd(); + } + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; } -uint32_t com_raytheon_uf_common_pointdata_elements_IntPointDataObject::write(::apache::thrift::protocol::TProtocol* oprot) const { - uint32_t xfer = 0; - xfer += oprot->writeStructBegin("com_raytheon_uf_common_pointdata_elements_IntPointDataObject"); +const char + * com_raytheon_uf_common_pointdata_PointDataThriftContainer::ascii_fingerprint = + "1FBB5099264525B0793D6869D0E4CD21"; +const uint8_t + com_raytheon_uf_common_pointdata_PointDataThriftContainer::binary_fingerprint[16] = { + 0x1F, 0xBB, 0x50, 0x99, 0x26, 0x45, 0x25, 0xB0, 0x79, 0x3D, + 0x68, 0x69, 0xD0, 0xE4, 0xCD, 0x21 }; - xfer += oprot->writeFieldBegin("description", ::apache::thrift::protocol::T_STRUCT, 1); - xfer += this->description.write(oprot); - xfer += oprot->writeFieldEnd(); +uint32_t com_raytheon_uf_common_pointdata_PointDataThriftContainer::read( + apache::thrift::protocol::TProtocol* iprot) { - xfer += oprot->writeFieldBegin("dimensions", ::apache::thrift::protocol::T_I32, 2); - xfer += oprot->writeI32(this->dimensions); - xfer += oprot->writeFieldEnd(); + uint32_t xfer = 0; + std::string fname; + apache::thrift::protocol::TType ftype; + int16_t fid; - xfer += oprot->writeFieldBegin("intData", ::apache::thrift::protocol::T_LIST, 3); - { - xfer += oprot->writeListBegin(::apache::thrift::protocol::T_I32, static_cast(this->intData.size())); - std::vector ::const_iterator _iter23; - for (_iter23 = this->intData.begin(); _iter23 != this->intData.end(); ++_iter23) - { - xfer += oprot->writeI32((*_iter23)); - } - xfer += oprot->writeListEnd(); - } - xfer += oprot->writeFieldEnd(); + xfer += iprot->readStructBegin(fname); - xfer += oprot->writeFieldStop(); - xfer += oprot->writeStructEnd(); - return xfer; + using apache::thrift::protocol::TProtocolException; + + while (true) { + xfer += iprot->readFieldBegin(fname, ftype, fid); + if (ftype == apache::thrift::protocol::T_STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == apache::thrift::protocol::T_LIST) { + { + this->floatData.clear(); + uint32_t _size24; + apache::thrift::protocol::TType _etype27; + iprot->readListBegin(_etype27, _size24); + this->floatData.resize(_size24); + uint32_t _i28; + for (_i28 = 0; _i28 < _size24; ++_i28) { + xfer += this->floatData[_i28].read(iprot); + } + iprot->readListEnd(); + } + this->__isset.floatData = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == apache::thrift::protocol::T_LIST) { + { + this->intData.clear(); + uint32_t _size29; + apache::thrift::protocol::TType _etype32; + iprot->readListBegin(_etype32, _size29); + this->intData.resize(_size29); + uint32_t _i33; + for (_i33 = 0; _i33 < _size29; ++_i33) { + xfer += this->intData[_i33].read(iprot); + } + iprot->readListEnd(); + } + this->__isset.intData = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 3: + if (ftype == apache::thrift::protocol::T_LIST) { + { + this->longData.clear(); + uint32_t _size34; + apache::thrift::protocol::TType _etype37; + iprot->readListBegin(_etype37, _size34); + this->longData.resize(_size34); + uint32_t _i38; + for (_i38 = 0; _i38 < _size34; ++_i38) { + xfer += this->longData[_i38].read(iprot); + } + iprot->readListEnd(); + } + this->__isset.longData = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 4: + if (ftype == apache::thrift::protocol::T_I32) { + xfer += iprot->readI32(this->size); + this->__isset.size = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 5: + if (ftype == apache::thrift::protocol::T_LIST) { + { + this->stringData.clear(); + uint32_t _size39; + apache::thrift::protocol::TType _etype42; + iprot->readListBegin(_etype42, _size39); + this->stringData.resize(_size39); + uint32_t _i43; + for (_i43 = 0; _i43 < _size39; ++_i43) { + xfer += this->stringData[_i43].read(iprot); + } + iprot->readListEnd(); + } + this->__isset.stringData = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; } -void swap(com_raytheon_uf_common_pointdata_elements_IntPointDataObject &a, com_raytheon_uf_common_pointdata_elements_IntPointDataObject &b) { - using ::std::swap; - swap(a.description, b.description); - swap(a.dimensions, b.dimensions); - swap(a.intData, b.intData); - swap(a.__isset, b.__isset); +uint32_t com_raytheon_uf_common_pointdata_PointDataThriftContainer::write( + apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin( + "com_raytheon_uf_common_pointdata_PointDataThriftContainer"); + xfer += oprot->writeFieldBegin("floatData", + apache::thrift::protocol::T_LIST, 1); + { + xfer += oprot->writeListBegin(apache::thrift::protocol::T_STRUCT, + this->floatData.size()); + std::vector< + com_raytheon_uf_common_pointdata_elements_FloatPointDataObject>::const_iterator + _iter44; + for (_iter44 = this->floatData.begin(); _iter44 + != this->floatData.end(); ++_iter44) { + xfer += (*_iter44).write(oprot); + } + xfer += oprot->writeListEnd(); + } + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("intData", apache::thrift::protocol::T_LIST, + 2); + { + xfer += oprot->writeListBegin(apache::thrift::protocol::T_STRUCT, + this->intData.size()); + std::vector< + com_raytheon_uf_common_pointdata_elements_IntPointDataObject>::const_iterator + _iter45; + for (_iter45 = this->intData.begin(); _iter45 != this->intData.end(); ++_iter45) { + xfer += (*_iter45).write(oprot); + } + xfer += oprot->writeListEnd(); + } + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("longData", + apache::thrift::protocol::T_LIST, 3); + { + xfer += oprot->writeListBegin(apache::thrift::protocol::T_STRUCT, + this->longData.size()); + std::vector< + com_raytheon_uf_common_pointdata_elements_LongPointDataObject>::const_iterator + _iter46; + for (_iter46 = this->longData.begin(); _iter46 != this->longData.end(); ++_iter46) { + xfer += (*_iter46).write(oprot); + } + xfer += oprot->writeListEnd(); + } + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("size", apache::thrift::protocol::T_I32, 4); + xfer += oprot->writeI32(this->size); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("stringData", + apache::thrift::protocol::T_LIST, 5); + { + xfer += oprot->writeListBegin(apache::thrift::protocol::T_STRUCT, + this->stringData.size()); + std::vector< + com_raytheon_uf_common_pointdata_elements_StringPointDataObject>::const_iterator + _iter47; + for (_iter47 = this->stringData.begin(); _iter47 + != this->stringData.end(); ++_iter47) { + xfer += (*_iter47).write(oprot); + } + xfer += oprot->writeListEnd(); + } + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; } -const char* com_raytheon_uf_common_pointdata_elements_LongPointDataObject::ascii_fingerprint = "135921A65C05459AFDDA382E27DDA225"; -const uint8_t com_raytheon_uf_common_pointdata_elements_LongPointDataObject::binary_fingerprint[16] = {0x13,0x59,0x21,0xA6,0x5C,0x05,0x45,0x9A,0xFD,0xDA,0x38,0x2E,0x27,0xDD,0xA2,0x25}; +const char + * com_raytheon_uf_common_pointdata_PointDataRequestMessageConstraint::ascii_fingerprint = + "3368C2F81F2FEF71F11EDACDB2A3ECEF"; +const uint8_t + com_raytheon_uf_common_pointdata_PointDataRequestMessageConstraint::binary_fingerprint[16] = { + 0x33, 0x68, 0xC2, 0xF8, 0x1F, 0x2F, 0xEF, 0x71, 0xF1, 0x1E, + 0xDA, 0xCD, 0xB2, 0xA3, 0xEC, 0xEF }; -uint32_t com_raytheon_uf_common_pointdata_elements_LongPointDataObject::read(::apache::thrift::protocol::TProtocol* iprot) { +uint32_t com_raytheon_uf_common_pointdata_PointDataRequestMessageConstraint::read( + apache::thrift::protocol::TProtocol* iprot) { - uint32_t xfer = 0; - std::string fname; - ::apache::thrift::protocol::TType ftype; - int16_t fid; + uint32_t xfer = 0; + std::string fname; + apache::thrift::protocol::TType ftype; + int16_t fid; - xfer += iprot->readStructBegin(fname); + xfer += iprot->readStructBegin(fname); - using ::apache::thrift::protocol::TProtocolException; + using apache::thrift::protocol::TProtocolException; + while (true) { + xfer += iprot->readFieldBegin(fname, ftype, fid); + if (ftype == apache::thrift::protocol::T_STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == apache::thrift::protocol::T_I32) { + xfer += iprot->readI32(this->constraintType); + this->__isset.constraintType = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->parameter); + this->__isset.parameter = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 3: + if (ftype == apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->value); + this->__isset.value = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } - while (true) - { - xfer += iprot->readFieldBegin(fname, ftype, fid); - if (ftype == ::apache::thrift::protocol::T_STOP) { - break; - } - switch (fid) - { - case 1: - if (ftype == ::apache::thrift::protocol::T_STRUCT) { - xfer += this->description.read(iprot); - this->__isset.description = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 2: - if (ftype == ::apache::thrift::protocol::T_I32) { - xfer += iprot->readI32(this->dimensions); - this->__isset.dimensions = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 3: - if (ftype == ::apache::thrift::protocol::T_LIST) { - { - this->longData.clear(); - uint32_t _size24; - ::apache::thrift::protocol::TType _etype27; - xfer += iprot->readListBegin(_etype27, _size24); - this->longData.resize(_size24); - uint32_t _i28; - for (_i28 = 0; _i28 < _size24; ++_i28) - { - xfer += iprot->readI64(this->longData[_i28]); - } - xfer += iprot->readListEnd(); - } - this->__isset.longData = true; - } else { - xfer += iprot->skip(ftype); - } - break; - default: - xfer += iprot->skip(ftype); - break; - } - xfer += iprot->readFieldEnd(); - } + xfer += iprot->readStructEnd(); - xfer += iprot->readStructEnd(); - - return xfer; + return xfer; } -uint32_t com_raytheon_uf_common_pointdata_elements_LongPointDataObject::write(::apache::thrift::protocol::TProtocol* oprot) const { - uint32_t xfer = 0; - xfer += oprot->writeStructBegin("com_raytheon_uf_common_pointdata_elements_LongPointDataObject"); - - xfer += oprot->writeFieldBegin("description", ::apache::thrift::protocol::T_STRUCT, 1); - xfer += this->description.write(oprot); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("dimensions", ::apache::thrift::protocol::T_I32, 2); - xfer += oprot->writeI32(this->dimensions); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("longData", ::apache::thrift::protocol::T_LIST, 3); - { - xfer += oprot->writeListBegin(::apache::thrift::protocol::T_I64, static_cast(this->longData.size())); - std::vector ::const_iterator _iter29; - for (_iter29 = this->longData.begin(); _iter29 != this->longData.end(); ++_iter29) - { - xfer += oprot->writeI64((*_iter29)); - } - xfer += oprot->writeListEnd(); - } - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldStop(); - xfer += oprot->writeStructEnd(); - return xfer; +uint32_t com_raytheon_uf_common_pointdata_PointDataRequestMessageConstraint::write( + apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer + += oprot->writeStructBegin( + "com_raytheon_uf_common_pointdata_PointDataRequestMessageConstraint"); + xfer += oprot->writeFieldBegin("constraintType", + apache::thrift::protocol::T_I32, 1); + xfer += oprot->writeI32(this->constraintType); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("parameter", + apache::thrift::protocol::T_STRING, 2); + xfer += oprot->writeString(this->parameter); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("value", apache::thrift::protocol::T_STRING, + 3); + xfer += oprot->writeString(this->value); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; } -void swap(com_raytheon_uf_common_pointdata_elements_LongPointDataObject &a, com_raytheon_uf_common_pointdata_elements_LongPointDataObject &b) { - using ::std::swap; - swap(a.description, b.description); - swap(a.dimensions, b.dimensions); - swap(a.longData, b.longData); - swap(a.__isset, b.__isset); +const char + * com_raytheon_uf_common_pointdata_PointDataRequestMessage::ascii_fingerprint = + "781EA3AAB5B079D92C9DA7774B669520"; +const uint8_t + com_raytheon_uf_common_pointdata_PointDataRequestMessage::binary_fingerprint[16] = { + 0x78, 0x1E, 0xA3, 0xAA, 0xB5, 0xB0, 0x79, 0xD9, 0x2C, 0x9D, + 0xA7, 0x77, 0x4B, 0x66, 0x95, 0x20 }; + +uint32_t com_raytheon_uf_common_pointdata_PointDataRequestMessage::read( + apache::thrift::protocol::TProtocol* iprot) { + + uint32_t xfer = 0; + std::string fname; + apache::thrift::protocol::TType ftype; + int16_t fid; + + xfer += iprot->readStructBegin(fname); + + using apache::thrift::protocol::TProtocolException; + + while (true) { + xfer += iprot->readFieldBegin(fname, ftype, fid); + if (ftype == apache::thrift::protocol::T_STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == apache::thrift::protocol::T_BOOL) { + xfer += iprot->readBool(this->allLevels); + this->__isset.allLevels = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == apache::thrift::protocol::T_LIST) { + { + this->constraints.clear(); + uint32_t _size48; + apache::thrift::protocol::TType _etype51; + iprot->readListBegin(_etype51, _size48); + this->constraints.resize(_size48); + uint32_t _i52; + for (_i52 = 0; _i52 < _size48; ++_i52) { + xfer += this->constraints[_i52].read(iprot); + } + iprot->readListEnd(); + } + this->__isset.constraints = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 3: + if (ftype == apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->levelParameter); + this->__isset.levelParameter = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 4: + if (ftype == apache::thrift::protocol::T_LIST) { + { + this->levelValue.clear(); + uint32_t _size53; + apache::thrift::protocol::TType _etype56; + iprot->readListBegin(_etype56, _size53); + this->levelValue.resize(_size53); + uint32_t _i57; + for (_i57 = 0; _i57 < _size53; ++_i57) { + xfer += iprot->readDouble(this->levelValue[_i57]); + } + iprot->readListEnd(); + } + this->__isset.levelValue = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 5: + if (ftype == apache::thrift::protocol::T_LIST) { + { + this->parameters.clear(); + uint32_t _size58; + apache::thrift::protocol::TType _etype61; + iprot->readListBegin(_etype61, _size58); + this->parameters.resize(_size58); + uint32_t _i62; + for (_i62 = 0; _i62 < _size58; ++_i62) { + xfer += iprot->readString(this->parameters[_i62]); + } + iprot->readListEnd(); + } + this->__isset.parameters = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 6: + if (ftype == apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->pluginName); + this->__isset.pluginName = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; } -const char* com_raytheon_uf_common_pointdata_PointDataThriftContainer::ascii_fingerprint = "8E622421D449B7CCD34FF11BE324DA19"; -const uint8_t com_raytheon_uf_common_pointdata_PointDataThriftContainer::binary_fingerprint[16] = {0x8E,0x62,0x24,0x21,0xD4,0x49,0xB7,0xCC,0xD3,0x4F,0xF1,0x1B,0xE3,0x24,0xDA,0x19}; - -uint32_t com_raytheon_uf_common_pointdata_PointDataThriftContainer::read(::apache::thrift::protocol::TProtocol* iprot) { - - uint32_t xfer = 0; - std::string fname; - ::apache::thrift::protocol::TType ftype; - int16_t fid; - - xfer += iprot->readStructBegin(fname); - - using ::apache::thrift::protocol::TProtocolException; - - - while (true) - { - xfer += iprot->readFieldBegin(fname, ftype, fid); - if (ftype == ::apache::thrift::protocol::T_STOP) { - break; - } - switch (fid) - { - case 1: - if (ftype == ::apache::thrift::protocol::T_LIST) { - { - this->floatData.clear(); - uint32_t _size30; - ::apache::thrift::protocol::TType _etype33; - xfer += iprot->readListBegin(_etype33, _size30); - this->floatData.resize(_size30); - uint32_t _i34; - for (_i34 = 0; _i34 < _size30; ++_i34) - { - xfer += this->floatData[_i34].read(iprot); - } - xfer += iprot->readListEnd(); - } - this->__isset.floatData = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 2: - if (ftype == ::apache::thrift::protocol::T_LIST) { - { - this->intData.clear(); - uint32_t _size35; - ::apache::thrift::protocol::TType _etype38; - xfer += iprot->readListBegin(_etype38, _size35); - this->intData.resize(_size35); - uint32_t _i39; - for (_i39 = 0; _i39 < _size35; ++_i39) - { - xfer += this->intData[_i39].read(iprot); - } - xfer += iprot->readListEnd(); - } - this->__isset.intData = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 3: - if (ftype == ::apache::thrift::protocol::T_LIST) { - { - this->longData.clear(); - uint32_t _size40; - ::apache::thrift::protocol::TType _etype43; - xfer += iprot->readListBegin(_etype43, _size40); - this->longData.resize(_size40); - uint32_t _i44; - for (_i44 = 0; _i44 < _size40; ++_i44) - { - xfer += this->longData[_i44].read(iprot); - } - xfer += iprot->readListEnd(); - } - this->__isset.longData = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 4: - if (ftype == ::apache::thrift::protocol::T_I32) { - xfer += iprot->readI32(this->size); - this->__isset.size = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 5: - if (ftype == ::apache::thrift::protocol::T_LIST) { - { - this->stringData.clear(); - uint32_t _size45; - ::apache::thrift::protocol::TType _etype48; - xfer += iprot->readListBegin(_etype48, _size45); - this->stringData.resize(_size45); - uint32_t _i49; - for (_i49 = 0; _i49 < _size45; ++_i49) - { - xfer += this->stringData[_i49].read(iprot); - } - xfer += iprot->readListEnd(); - } - this->__isset.stringData = true; - } else { - xfer += iprot->skip(ftype); - } - break; - default: - xfer += iprot->skip(ftype); - break; - } - xfer += iprot->readFieldEnd(); - } - - xfer += iprot->readStructEnd(); - - return xfer; +uint32_t com_raytheon_uf_common_pointdata_PointDataRequestMessage::write( + apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin( + "com_raytheon_uf_common_pointdata_PointDataRequestMessage"); + xfer += oprot->writeFieldBegin("allLevels", + apache::thrift::protocol::T_BOOL, 1); + xfer += oprot->writeBool(this->allLevels); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("constraints", + apache::thrift::protocol::T_LIST, 2); + { + xfer += oprot->writeListBegin(apache::thrift::protocol::T_STRUCT, + this->constraints.size()); + std::vector< + com_raytheon_uf_common_pointdata_PointDataRequestMessageConstraint>::const_iterator + _iter63; + for (_iter63 = this->constraints.begin(); _iter63 + != this->constraints.end(); ++_iter63) { + xfer += (*_iter63).write(oprot); + } + xfer += oprot->writeListEnd(); + } + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("levelParameter", + apache::thrift::protocol::T_STRING, 3); + xfer += oprot->writeString(this->levelParameter); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("levelValue", + apache::thrift::protocol::T_LIST, 4); + { + xfer += oprot->writeListBegin(apache::thrift::protocol::T_DOUBLE, + this->levelValue.size()); + std::vector::const_iterator _iter64; + for (_iter64 = this->levelValue.begin(); _iter64 + != this->levelValue.end(); ++_iter64) { + xfer += oprot->writeDouble((*_iter64)); + } + xfer += oprot->writeListEnd(); + } + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("parameters", + apache::thrift::protocol::T_LIST, 5); + { + xfer += oprot->writeListBegin(apache::thrift::protocol::T_STRING, + this->parameters.size()); + std::vector::const_iterator _iter65; + for (_iter65 = this->parameters.begin(); _iter65 + != this->parameters.end(); ++_iter65) { + xfer += oprot->writeString((*_iter65)); + } + xfer += oprot->writeListEnd(); + } + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldBegin("pluginName", + apache::thrift::protocol::T_STRING, 6); + xfer += oprot->writeString(this->pluginName); + xfer += oprot->writeFieldEnd(); + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; } -uint32_t com_raytheon_uf_common_pointdata_PointDataThriftContainer::write(::apache::thrift::protocol::TProtocol* oprot) const { - uint32_t xfer = 0; - xfer += oprot->writeStructBegin("com_raytheon_uf_common_pointdata_PointDataThriftContainer"); - - xfer += oprot->writeFieldBegin("floatData", ::apache::thrift::protocol::T_LIST, 1); - { - xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->floatData.size())); - std::vector ::const_iterator _iter50; - for (_iter50 = this->floatData.begin(); _iter50 != this->floatData.end(); ++_iter50) - { - xfer += (*_iter50).write(oprot); - } - xfer += oprot->writeListEnd(); - } - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("intData", ::apache::thrift::protocol::T_LIST, 2); - { - xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->intData.size())); - std::vector ::const_iterator _iter51; - for (_iter51 = this->intData.begin(); _iter51 != this->intData.end(); ++_iter51) - { - xfer += (*_iter51).write(oprot); - } - xfer += oprot->writeListEnd(); - } - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("longData", ::apache::thrift::protocol::T_LIST, 3); - { - xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->longData.size())); - std::vector ::const_iterator _iter52; - for (_iter52 = this->longData.begin(); _iter52 != this->longData.end(); ++_iter52) - { - xfer += (*_iter52).write(oprot); - } - xfer += oprot->writeListEnd(); - } - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("size", ::apache::thrift::protocol::T_I32, 4); - xfer += oprot->writeI32(this->size); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("stringData", ::apache::thrift::protocol::T_LIST, 5); - { - xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->stringData.size())); - std::vector ::const_iterator _iter53; - for (_iter53 = this->stringData.begin(); _iter53 != this->stringData.end(); ++_iter53) - { - xfer += (*_iter53).write(oprot); - } - xfer += oprot->writeListEnd(); - } - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldStop(); - xfer += oprot->writeStructEnd(); - return xfer; -} - -void swap(com_raytheon_uf_common_pointdata_PointDataThriftContainer &a, com_raytheon_uf_common_pointdata_PointDataThriftContainer &b) { - using ::std::swap; - swap(a.floatData, b.floatData); - swap(a.intData, b.intData); - swap(a.longData, b.longData); - swap(a.size, b.size); - swap(a.stringData, b.stringData); - swap(a.__isset, b.__isset); -} - -const char* com_raytheon_uf_common_pointdata_PointDataRequestMessageConstraint::ascii_fingerprint = "3368C2F81F2FEF71F11EDACDB2A3ECEF"; -const uint8_t com_raytheon_uf_common_pointdata_PointDataRequestMessageConstraint::binary_fingerprint[16] = {0x33,0x68,0xC2,0xF8,0x1F,0x2F,0xEF,0x71,0xF1,0x1E,0xDA,0xCD,0xB2,0xA3,0xEC,0xEF}; - -uint32_t com_raytheon_uf_common_pointdata_PointDataRequestMessageConstraint::read(::apache::thrift::protocol::TProtocol* iprot) { - - uint32_t xfer = 0; - std::string fname; - ::apache::thrift::protocol::TType ftype; - int16_t fid; - - xfer += iprot->readStructBegin(fname); - - using ::apache::thrift::protocol::TProtocolException; - - - while (true) - { - xfer += iprot->readFieldBegin(fname, ftype, fid); - if (ftype == ::apache::thrift::protocol::T_STOP) { - break; - } - switch (fid) - { - case 1: - if (ftype == ::apache::thrift::protocol::T_I32) { - xfer += iprot->readI32(this->constraintType); - this->__isset.constraintType = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 2: - if (ftype == ::apache::thrift::protocol::T_STRING) { - xfer += iprot->readString(this->parameter); - this->__isset.parameter = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 3: - if (ftype == ::apache::thrift::protocol::T_STRING) { - xfer += iprot->readString(this->value); - this->__isset.value = true; - } else { - xfer += iprot->skip(ftype); - } - break; - default: - xfer += iprot->skip(ftype); - break; - } - xfer += iprot->readFieldEnd(); - } - - xfer += iprot->readStructEnd(); - - return xfer; -} - -uint32_t com_raytheon_uf_common_pointdata_PointDataRequestMessageConstraint::write(::apache::thrift::protocol::TProtocol* oprot) const { - uint32_t xfer = 0; - xfer += oprot->writeStructBegin("com_raytheon_uf_common_pointdata_PointDataRequestMessageConstraint"); - - xfer += oprot->writeFieldBegin("constraintType", ::apache::thrift::protocol::T_I32, 1); - xfer += oprot->writeI32(this->constraintType); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("parameter", ::apache::thrift::protocol::T_STRING, 2); - xfer += oprot->writeString(this->parameter); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("value", ::apache::thrift::protocol::T_STRING, 3); - xfer += oprot->writeString(this->value); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldStop(); - xfer += oprot->writeStructEnd(); - return xfer; -} - -void swap(com_raytheon_uf_common_pointdata_PointDataRequestMessageConstraint &a, com_raytheon_uf_common_pointdata_PointDataRequestMessageConstraint &b) { - using ::std::swap; - swap(a.constraintType, b.constraintType); - swap(a.parameter, b.parameter); - swap(a.value, b.value); - swap(a.__isset, b.__isset); -} - -const char* com_raytheon_uf_common_pointdata_PointDataRequestMessage::ascii_fingerprint = "781EA3AAB5B079D92C9DA7774B669520"; -const uint8_t com_raytheon_uf_common_pointdata_PointDataRequestMessage::binary_fingerprint[16] = {0x78,0x1E,0xA3,0xAA,0xB5,0xB0,0x79,0xD9,0x2C,0x9D,0xA7,0x77,0x4B,0x66,0x95,0x20}; - -uint32_t com_raytheon_uf_common_pointdata_PointDataRequestMessage::read(::apache::thrift::protocol::TProtocol* iprot) { - - uint32_t xfer = 0; - std::string fname; - ::apache::thrift::protocol::TType ftype; - int16_t fid; - - xfer += iprot->readStructBegin(fname); - - using ::apache::thrift::protocol::TProtocolException; - - - while (true) - { - xfer += iprot->readFieldBegin(fname, ftype, fid); - if (ftype == ::apache::thrift::protocol::T_STOP) { - break; - } - switch (fid) - { - case 1: - if (ftype == ::apache::thrift::protocol::T_BOOL) { - xfer += iprot->readBool(this->allLevels); - this->__isset.allLevels = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 2: - if (ftype == ::apache::thrift::protocol::T_LIST) { - { - this->constraints.clear(); - uint32_t _size54; - ::apache::thrift::protocol::TType _etype57; - xfer += iprot->readListBegin(_etype57, _size54); - this->constraints.resize(_size54); - uint32_t _i58; - for (_i58 = 0; _i58 < _size54; ++_i58) - { - xfer += this->constraints[_i58].read(iprot); - } - xfer += iprot->readListEnd(); - } - this->__isset.constraints = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 3: - if (ftype == ::apache::thrift::protocol::T_STRING) { - xfer += iprot->readString(this->levelParameter); - this->__isset.levelParameter = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 4: - if (ftype == ::apache::thrift::protocol::T_LIST) { - { - this->levelValue.clear(); - uint32_t _size59; - ::apache::thrift::protocol::TType _etype62; - xfer += iprot->readListBegin(_etype62, _size59); - this->levelValue.resize(_size59); - uint32_t _i63; - for (_i63 = 0; _i63 < _size59; ++_i63) - { - xfer += iprot->readDouble(this->levelValue[_i63]); - } - xfer += iprot->readListEnd(); - } - this->__isset.levelValue = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 5: - if (ftype == ::apache::thrift::protocol::T_LIST) { - { - this->parameters.clear(); - uint32_t _size64; - ::apache::thrift::protocol::TType _etype67; - xfer += iprot->readListBegin(_etype67, _size64); - this->parameters.resize(_size64); - uint32_t _i68; - for (_i68 = 0; _i68 < _size64; ++_i68) - { - xfer += iprot->readString(this->parameters[_i68]); - } - xfer += iprot->readListEnd(); - } - this->__isset.parameters = true; - } else { - xfer += iprot->skip(ftype); - } - break; - case 6: - if (ftype == ::apache::thrift::protocol::T_STRING) { - xfer += iprot->readString(this->pluginName); - this->__isset.pluginName = true; - } else { - xfer += iprot->skip(ftype); - } - break; - default: - xfer += iprot->skip(ftype); - break; - } - xfer += iprot->readFieldEnd(); - } - - xfer += iprot->readStructEnd(); - - return xfer; -} - -uint32_t com_raytheon_uf_common_pointdata_PointDataRequestMessage::write(::apache::thrift::protocol::TProtocol* oprot) const { - uint32_t xfer = 0; - xfer += oprot->writeStructBegin("com_raytheon_uf_common_pointdata_PointDataRequestMessage"); - - xfer += oprot->writeFieldBegin("allLevels", ::apache::thrift::protocol::T_BOOL, 1); - xfer += oprot->writeBool(this->allLevels); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("constraints", ::apache::thrift::protocol::T_LIST, 2); - { - xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->constraints.size())); - std::vector ::const_iterator _iter69; - for (_iter69 = this->constraints.begin(); _iter69 != this->constraints.end(); ++_iter69) - { - xfer += (*_iter69).write(oprot); - } - xfer += oprot->writeListEnd(); - } - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("levelParameter", ::apache::thrift::protocol::T_STRING, 3); - xfer += oprot->writeString(this->levelParameter); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("levelValue", ::apache::thrift::protocol::T_LIST, 4); - { - xfer += oprot->writeListBegin(::apache::thrift::protocol::T_DOUBLE, static_cast(this->levelValue.size())); - std::vector ::const_iterator _iter70; - for (_iter70 = this->levelValue.begin(); _iter70 != this->levelValue.end(); ++_iter70) - { - xfer += oprot->writeDouble((*_iter70)); - } - xfer += oprot->writeListEnd(); - } - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("parameters", ::apache::thrift::protocol::T_LIST, 5); - { - xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->parameters.size())); - std::vector ::const_iterator _iter71; - for (_iter71 = this->parameters.begin(); _iter71 != this->parameters.end(); ++_iter71) - { - xfer += oprot->writeString((*_iter71)); - } - xfer += oprot->writeListEnd(); - } - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldBegin("pluginName", ::apache::thrift::protocol::T_STRING, 6); - xfer += oprot->writeString(this->pluginName); - xfer += oprot->writeFieldEnd(); - - xfer += oprot->writeFieldStop(); - xfer += oprot->writeStructEnd(); - return xfer; -} - -void swap(com_raytheon_uf_common_pointdata_PointDataRequestMessage &a, com_raytheon_uf_common_pointdata_PointDataRequestMessage &b) { - using ::std::swap; - swap(a.allLevels, b.allLevels); - swap(a.constraints, b.constraints); - swap(a.levelParameter, b.levelParameter); - swap(a.levelValue, b.levelValue); - swap(a.parameters, b.parameters); - swap(a.pluginName, b.pluginName); - swap(a.__isset, b.__isset); -} - - From e085f07dd5691a34f1b83b7ac28d5ba0970ae73c Mon Sep 17 00:00:00 2001 From: "Zhidong.Hao" Date: Wed, 23 Jul 2014 14:25:22 -0400 Subject: [PATCH 05/11] ASM #15645 - Fix for AvnFPS: TAF syntax check fails when equal sign is missing Change-Id: I1a4fb9be1253b4655bd43674aab4a4ddcf6d0ce7 Former-commit-id: a3cda853cf781290c66bf1664aeb2c97e3fd1ebd [formerly 26c4bb2414b3828dd163fb20270ddd4b4cfbc83f [formerly 192948e00538bcf0dfc0aaf20ea1dcb216313ffb]] Former-commit-id: 26c4bb2414b3828dd163fb20270ddd4b4cfbc83f Former-commit-id: d7cce22d02d6cef699ebc088886b756e416c2b78 --- .../aviation/editor/TafViewerEditorDlg.java | 97 ++++++++----------- 1 file changed, 39 insertions(+), 58 deletions(-) diff --git a/cave/com.raytheon.viz.aviation/src/com/raytheon/viz/aviation/editor/TafViewerEditorDlg.java b/cave/com.raytheon.viz.aviation/src/com/raytheon/viz/aviation/editor/TafViewerEditorDlg.java index ad97eb88c4..59d2cfa47e 100644 --- a/cave/com.raytheon.viz.aviation/src/com/raytheon/viz/aviation/editor/TafViewerEditorDlg.java +++ b/cave/com.raytheon.viz.aviation/src/com/raytheon/viz/aviation/editor/TafViewerEditorDlg.java @@ -235,6 +235,7 @@ import com.raytheon.viz.ui.dialogs.ICloseCallback; * 02/19/2014 16980 zhao add code to ensure the Alt flag is false after the Alt kay is released * 09Apr2014 #3005 lvenable Added calls to mark the tabs as not current when the tabs are changed. * This will show the tab as updating in the header and data text controls. + * 07/23/2014 15645 zhao modified checkBasicSyntaxError() * * * @@ -2109,19 +2110,29 @@ public class TafViewerEditorDlg extends CaveSWTDialog implements ITafSettable, return editorComp; } - /** + /** + * Check if there is an extra '=' sign in a TAF * * @param doLogMessage * @return true if error found, otherwise false */ private boolean checkBasicSyntaxError(boolean doLogMessage) { + boolean errorFound = false; + String in = editorTafTabComp.getTextEditorControl().getText(); clearSyntaxErrorLevel(); st = editorTafTabComp.getTextEditorControl(); + in = in.toUpperCase().replaceAll("TAF", "\n\nTAF").trim(); + while ( in.contains("\n\n\n") ) { + in = in.replace("\n\n\n", "\n\n"); + } + + st.setText(in); + final Map syntaxMap = new HashMap(); st.addMouseTrackListener(new MouseTrackAdapter() { @@ -2153,66 +2164,36 @@ public class TafViewerEditorDlg extends CaveSWTDialog implements ITafSettable, } }); - int tafIndex = in.indexOf("TAF"); - int equalSignIndex = in.indexOf("="); - int lastEqualSignIndex = equalSignIndex; - - if (tafIndex < 0 && equalSignIndex < 0) { // empty TAF - return false; - } - - while (tafIndex > -1 || equalSignIndex > -1) { - - if (tafIndex == -1 || tafIndex > equalSignIndex) { - - int lineIndexOfFirstEqualSign = st - .getLineAtOffset(lastEqualSignIndex); - int lineIndexOfSecondEqualSign = st - .getLineAtOffset(equalSignIndex); - if (lineIndexOfFirstEqualSign == lineIndexOfSecondEqualSign) { - StyleRange sr = new StyleRange(lastEqualSignIndex, 1, null, - qcColors[3]); - String msg = "Syntax error: there is an extra '=' sign in this line"; - syntaxMap.put(sr, msg); - st.setStyleRange(null); - st.setStyleRange(sr); - if (doLogMessage) { - msgStatComp.setMessageText(msg, qcColors[3].getRGB()); - } - return true; - } - - int startIndex = lastEqualSignIndex; - - while (!in.substring(startIndex, startIndex + 1).matches( - "[A-Z]") - && !in.substring(startIndex, startIndex + 1).matches( - "[0-9]")) { - startIndex++; - } - int length = 6; - if ((equalSignIndex - startIndex) < 6) { - length = equalSignIndex - startIndex; - } - StyleRange sr = new StyleRange(startIndex, length, null, - qcColors[3]); - String msg = "Syntax error: There is an extra '=' sign before this point, or 'TAF' is missing at beginning of TAF"; - syntaxMap.put(sr, msg); - st.setStyleRange(null); - st.setStyleRange(sr); - if (doLogMessage) { - msgStatComp.setMessageText(msg, qcColors[3].getRGB()); - } - - return true; + String msg = "Syntax error: There is an extra '=' sign or 'TAF' is missing at beginning of TAF"; + String[] tafs = in.split("\n\n"); + int tafStartIndex = 0; + for ( String taf : tafs ) { + int firstEqualSignIndex = taf.indexOf('='); + if ( firstEqualSignIndex == -1 ) { + tafStartIndex += taf.length() + 2; + continue; } - - tafIndex = in.indexOf("TAF", tafIndex + 1); - lastEqualSignIndex = equalSignIndex; - equalSignIndex = in.indexOf("=", equalSignIndex + 1); + int secondEqualSignIndex = taf.indexOf('=', firstEqualSignIndex+1); + if ( secondEqualSignIndex == -1 ) { + tafStartIndex += taf.length() + 2; + continue; + } + while ( secondEqualSignIndex > -1 ) { + int secondEqualSignIndexInEditorText = tafStartIndex + secondEqualSignIndex; + StyleRange sr = new StyleRange(secondEqualSignIndexInEditorText, 1, null, qcColors[3]); + syntaxMap.put(sr, msg); + st.setStyleRange(sr); + secondEqualSignIndex = taf.indexOf('=', secondEqualSignIndex+1); + } + errorFound = true; + tafStartIndex += taf.length() + 2; } - return false; + if ( doLogMessage ) { + msgStatComp.setMessageText(msg, qcColors[3].getRGB()); + } + + return errorFound; } private void syntaxCheck() { From 9b78be1622ef41f629ef1a567c195afb9dbfd849 Mon Sep 17 00:00:00 2001 From: "Rici.Yu" Date: Mon, 28 Jul 2014 11:30:49 -0400 Subject: [PATCH 06/11] ASM #15655 - Negate raising exception for empty db from IFPDB() Change-Id: I5c96d654f3080a4b0f10113648f290a0d09961cb Former-commit-id: 661737fb39ea93fcb806094830834398ca7808c6 [formerly 9a1310d1acd303cc9a152ff87e68662227a9cdf0 [formerly 9af51efbef229984de09a5ad338885d54f720270]] Former-commit-id: 9a1310d1acd303cc9a152ff87e68662227a9cdf0 Former-commit-id: a75c0c2f15e2b0680b3a5ab77842232a0182b896 --- .../src/com/raytheon/edex/plugin/gfe/smartinit/IFPDB.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/smartinit/IFPDB.java b/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/smartinit/IFPDB.java index fb342d4aff..224a3b8e7e 100644 --- a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/smartinit/IFPDB.java +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/smartinit/IFPDB.java @@ -41,6 +41,7 @@ import com.raytheon.uf.common.dataplugin.gfe.server.message.ServerResponse; * ------------ ---------- ----------- -------------------------- * May 7, 2008 njensen Initial creation * Jun 13, 2013 #2044 randerso Refactored to use IFPServer + * Jul 28, 2014 RM 15655 ryu Negate raising exception for empty db in constructor * * * @@ -88,7 +89,6 @@ public class IFPDB { } } else { this.keys = Collections.emptyList(); - throw new GfeException(sr.message()); } } From 632ec498ffbf3353cb076110843906f9a852debe Mon Sep 17 00:00:00 2001 From: "Qinglu.Lin" Date: Mon, 28 Jul 2014 12:36:07 -0400 Subject: [PATCH 07/11] ASM #15554 - Improve speed/efficiency of WarngenLayer.populateStrings Change-Id: I6a3b9823ac7c23ba171206708187ab3fc3c7c1ca Former-commit-id: 2aa16c114a52523e7ff08e45c06817597cc5022b [formerly 1eca5ef51a3e1714e17b77e0e1ae1ad7213ed35e [formerly 3b971d52a82099142fe08986df879a379dfa6314]] Former-commit-id: 1eca5ef51a3e1714e17b77e0e1ae1ad7213ed35e Former-commit-id: f69a06238bf3335337a7268e872a86d0a1b95e1d --- .../raytheon/viz/warngen/gis/PolygonUtil.java | 13 +- .../viz/warngen/gui/WarngenLayer.java | 205 +++++++++++------- 2 files changed, 141 insertions(+), 77 deletions(-) diff --git a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gis/PolygonUtil.java b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gis/PolygonUtil.java index 139ece3233..9943db6592 100644 --- a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gis/PolygonUtil.java +++ b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gis/PolygonUtil.java @@ -88,6 +88,7 @@ import com.vividsolutions.jts.precision.SimpleGeometryPrecisionReducer; * 05/16/2014 DR 17365 D. Friedman Prevent some Coordinate reuse. Add reducePrecision. * 06/27/2014 DR 17443 D. Friedman Fix some odd cases in which parts of a polygon not covering a * hatched area would be retained after redrawing. + * 07/22/2014 DR 17475 Qinglu Lin Updated createPolygonByPoints() and created second createPolygonByPoints(). * * * @author mschenke @@ -1718,11 +1719,11 @@ public class PolygonUtil { } return slope; } - + /** * Create a polygon whose two diagonal coordinates are a and b. **/ - static public Geometry createPolygonByPoints(Coordinate a, Coordinate b) { + static public Geometry createPolygonByPoints(GeometryFactory gf, Coordinate a, Coordinate b) { double maxX, minX, maxY, minY; maxX = Math.max(a.x, b.x); minX = Math.min(a.x, b.x); @@ -1734,10 +1735,14 @@ public class PolygonUtil { coord[2] = new Coordinate(maxX, maxY); coord[3] = new Coordinate(minX, maxY); coord[4] = new Coordinate(coord[0]); - GeometryFactory gf = new GeometryFactory(); LinearRing lr = gf.createLinearRing(coord); return gf.createPolygon(lr, null); - } + } + + static public Geometry createPolygonByPoints(GeometryFactory gf, Coordinate a, double shift) { + Coordinate b = new Coordinate(a.x + shift, a.y + shift); + return createPolygonByPoints(gf, a, b); + } /** Creates a copy of a Geometry with reduced precision to reduce the chance of topology errors when used * in intersection operations. diff --git a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenLayer.java b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenLayer.java index 72506a7994..ac4bdacd2d 100644 --- a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenLayer.java +++ b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenLayer.java @@ -210,6 +210,8 @@ import com.vividsolutions.jts.io.WKTReader; * 04/28,2014 3033 jsanchez Properly handled back up configuration (*.xml) files. Set backupSite to null when backup site is not selected. * 05/16/2014 DR 17365 D. Friedman Check if moved vertex results in polygon valid in both lat/lon and local coordinates. * 07/01/2014 DR 17450 D. Friedman Use list of templates from backup site. + * 07/28/2014 DR 17475 Qinglu Lin Updated populateStrings() and findLargestQuadrant(), removed findLargestGeometry(), + * added createAreaAndCentroidMaps() and movePopulatePt(), updated paintText() to center W. * * * @author mschenke @@ -222,6 +224,9 @@ public class WarngenLayer extends AbstractStormTrackResource { String uniqueFip = null; + Map geomArea = new HashMap(); + Map geomCentroid = new HashMap(); + private static class GeospatialDataList { private static final String LOCAL_GEOM = "localGeometry"; @@ -1087,6 +1092,8 @@ public class WarngenLayer extends AbstractStormTrackResource { DrawableString string = new DrawableString(text, textColor); string.magnification = magnification; string.setCoordinates(out[0], out[1]); + string.horizontalAlignment = IGraphicsTarget.HorizontalAlignment.CENTER; + string.verticallAlignment = IGraphicsTarget.VerticalAlignment.MIDDLE; strings.add(string); } } @@ -1170,6 +1177,8 @@ public class WarngenLayer extends AbstractStormTrackResource { }// end synchronize customMaps.loadCustomMaps(Arrays.asList(config.getMaps())); + createAreaAndCentroidMaps(); + this.configuration = config; System.out.println("Total time to init warngen config = " + (System.currentTimeMillis() - t0) + "ms"); @@ -3169,66 +3178,127 @@ public class WarngenLayer extends AbstractStormTrackResource { toKeep.toArray(new Geometry[0])); } + private void createAreaAndCentroidMaps() { + String gid; + geomArea.clear(); + geomCentroid.clear(); + for (GeospatialData f : geoData.features) { + Geometry geom = f.getGeometry(); + gid = ((CountyUserData)geom.getUserData()).gid; + geomArea.put(gid, geom.getArea()); + geomCentroid.put(gid, geom.getCentroid()); + } + } + /** * Populate the W strings with the included counties */ private void populateStrings() { state.strings.clear(); + Geometry warningArea = state.getWarningArea(); Set prefixes = new HashSet(Arrays.asList(GeometryUtil - .getGID(state.getWarningArea()))); + .getGID(warningArea))); prefixes = removeDuplicateGid(prefixes); - for (GeospatialData f : geoData.features) { - Geometry geom = f.geometry; - Geometry geom2 = null; - Geometry warningAreaN = null; - Coordinate populatePt = null; - Geometry populatePtGeom; - boolean contained = false, closeTo = false; - double shift = 1.E-8, distance, minDistance = 10.0; - int loop, maxLoop = 10; - Geometry warningArea = state.getWarningArea(); - String prefix = GeometryUtil.getPrefix(geom.getUserData()); - if (prefixes.contains(prefix)) { - loop = 0; - warningAreaN = findLargestGeometry(GeometryUtil.intersection(geom, warningArea)); - do { - if (!warningAreaN.isEmpty()) { - populatePt = GisUtil.d2dCoordinate(warningAreaN.getCentroid() - .getCoordinate()); - for (GeospatialData f2 : geoData.features) { - geom2 = f2.getGeometry(); - if (!GeometryUtil.getPrefix(geom2.getUserData()).equals(prefix)) { - contained = false; - closeTo = false; - populatePtGeom = PolygonUtil.createPolygonByPoints(populatePt, - new Coordinate(populatePt.x + shift, populatePt.y + shift)); - if (GeometryUtil.contains(geom2, populatePtGeom)) { - // populatePt is in another county/zone. - warningAreaN = findLargestQuadrant(warningAreaN, geom); - contained = true; - break; - } else { - distance = populatePtGeom.distance(geom2); - if (distance < minDistance) { - // populatePt is very close to the boundary of another county/zone. - warningAreaN = findLargestQuadrant(warningAreaN, geom); - closeTo = true; - break; - } - } - } + Set indexes = new HashSet(); + String prefixM, prefixN; + double areaM, areaN, maxArea = -1.0; + int geomIndex = -1; + int geomNum = warningArea.getNumGeometries(); + // Find an unique index for each county in warningArea. If there is more than one index + // for one county, find the one with max area. + Geometry warningAreaM = null, warningAreaN = null; + for (int i = 0; i < geomNum; i++) { + warningAreaM = warningArea.getGeometryN(i); + prefixM = GeometryUtil.getPrefix(warningAreaM.getUserData()); + if (!prefixes.contains(prefixM)) { + continue; + } + areaM = warningAreaM.getArea(); + geomIndex = i; + while (i + 1 < geomNum) { + warningAreaN = warningArea.getGeometryN(i + 1); + prefixN = GeometryUtil.getPrefix(warningAreaN.getUserData()); + if (prefixN.equals(prefixM)) { + areaN = warningAreaN.getArea(); + if (areaN > areaM) { + if (areaN > maxArea) { + maxArea = areaN; + geomIndex = i + 1; } } else { - // use the existing populatePt - break; + if (areaM > maxArea) { + maxArea = areaM; + } } - loop += 1; - } while ((contained || closeTo) && loop <= maxLoop); - state.strings.put(populatePt, "W"); + } else { + break; + } + i = i + 1; } + indexes.add(geomIndex); } + + Map populatePtMap = new HashMap(); + GeometryFactory gf = new GeometryFactory(); + Geometry geomN = null, populatePtGeom = null; + Coordinate populatePt = new Coordinate(); + Point centroid = null; + int loop, maxLoop = 10; + double threshold = 0.1, weight = 0.5, shift = 1.E-8, minArea = 1.0E-2, area; + Iterator iter = indexes.iterator(); + while (iter.hasNext()) { + warningAreaM = warningArea.getGeometryN(iter.next().intValue()); + prefixM = GeometryUtil.getPrefix(warningAreaM.getUserData()); + area = warningAreaM.getArea(); + if (area < minArea || area / geomArea.get(prefixM) < threshold) { + // Hatched area inside a county is small, move W toward to default centroid + centroid = movePopulatePt(gf, warningAreaM, geomCentroid.get(prefixM), weight); + populatePt = new Coordinate(centroid.getX(), centroid.getY()); + populatePtGeom = PolygonUtil.createPolygonByPoints(gf, populatePt, shift); + } else { + // Use the controid of the hatched area in a county + centroid = warningAreaM.getCentroid(); + populatePt = new Coordinate(centroid.getX(), centroid.getY()); + populatePtGeom = PolygonUtil.createPolygonByPoints(gf, populatePt, shift); + } + for (GeospatialData gd : geoData.features) { + geomN = gd.getGeometry(); + CountyUserData cud = (CountyUserData)geomN.getUserData(); + prefixN = cud.gid; + if (prefixN.length() > 0 && prefixM.length() > 0 && + !prefixN.equals(prefixM)) { + if (GeometryUtil.contains(geomN, populatePtGeom)) { + // W is inside a county. Use default centroid of a county (not that of its hatched area) + centroid = geomCentroid.get(prefixM); + populatePt = new Coordinate(centroid.getX(), centroid.getY()); + populatePtGeom = PolygonUtil.createPolygonByPoints(gf, populatePt, shift); + } + loop = 1; + while (GeometryUtil.contains(geomN, populatePtGeom) && loop < maxLoop) { + // W is still inside a county, move W to the largest quadrant + warningAreaM = findLargestQuadrant(gf, warningAreaM); + centroid = warningAreaM.getCentroid(); + populatePt = new Coordinate(centroid.getX(), centroid.getY()); + populatePtGeom = PolygonUtil.createPolygonByPoints(gf, populatePt, shift); + loop += 1; + } + } + } + populatePtMap.put(prefixM, populatePt); + } + for (String key: populatePtMap.keySet()) { + state.strings.put(populatePtMap.get(key), "W"); + } + } + + private Point movePopulatePt(GeometryFactory gf, Geometry geom, Point point, double weight) { + Point centroid = geom.getCentroid(); + Coordinate coord = new Coordinate(); + coord.x = centroid.getX() * weight + point.getX() * (1.0 - weight); + coord.y = centroid.getY() * weight + point.getY() * (1.0 - weight); + return gf.createPoint(new Coordinate(coord.x, coord.y)); } public boolean featureProduct(Coordinate c) { @@ -3504,21 +3574,6 @@ public class WarngenLayer extends AbstractStormTrackResource { * A Geometry or a GeometryCollection. * @return Geometry */ - private Geometry findLargestGeometry(Geometry g) { - int size = g.getNumGeometries(); - if (size == 1) - return g; - double area, maxArea = -1.0; - int index = 0; - for (int i = 0; i < size; i++) { - area = g.getGeometryN(i).getArea(); - if (area > maxArea) { - maxArea = area; - index = i; - } - } - return g.getGeometryN(index); - } /** * Split the hatched area into four quadrants, and return the largest one. @@ -3529,10 +3584,10 @@ public class WarngenLayer extends AbstractStormTrackResource { * The geometry of a county/zone. * @return Geometry * The geometey of largest quadrant among the four, which are the result of - * splitting of hatchedArea. + * splitting of a county's hatched area. */ - private Geometry findLargestQuadrant(Geometry hatchedArea, Geometry geom) { - Geometry envelope = hatchedArea.getEnvelope(); + private Geometry findLargestQuadrant(GeometryFactory gf, Geometry geom) { + Geometry envelope = geom.getEnvelope(); Coordinate centroidCoord = GisUtil.d2dCoordinate(envelope.getCentroid() .getCoordinate()); Coordinate[] envCoords = envelope.getCoordinates(); @@ -3542,19 +3597,23 @@ public class WarngenLayer extends AbstractStormTrackResource { double largestArea = -1.0, area = -1.0; int index = -1; for (int i = 0; i < size; i++) { - quadrants[i] = PolygonUtil.createPolygonByPoints(envCoords[i], centroidCoord); - intersections[i] = GeometryUtil.intersection(quadrants[i], hatchedArea); - area = intersections[i].getArea(); - if (area > largestArea) { - largestArea = area; - index = i; + quadrants[i] = PolygonUtil.createPolygonByPoints(gf, envCoords[i], centroidCoord); + try { + intersections[i] = GeometryUtil.intersection(quadrants[i], geom); + area = intersections[i].getArea(); + if (area > largestArea) { + largestArea = area; + index = i; + } + } catch (Exception e) { + ; } } - if (intersections[index].isValid()) + if (null != intersections[index] && intersections[index].isValid()) return intersections[index]; else { - // "intersections[" + index + "] is invalid" - return hatchedArea; + return geom; } } + } From c71189dd922fea5c9dc08c9cca48bdb9b0519655 Mon Sep 17 00:00:00 2001 From: Michael Gamazaychikov Date: Mon, 28 Jul 2014 15:12:10 -0400 Subject: [PATCH 08/11] ASM #15627 - WarnGen leaving out reference to State that is under SVR or TOR Watch in SPS text products. Change-Id: Ic5689db7714be086d6e4543602db33a07e5b2fc1 Former-commit-id: 8cffe955a9d215c5f3e293ade959e1f4b45c3682 [formerly ba4c386f308147743e1772bca49fb0393a9d50e6 [formerly 00ec5e2d47809d084b3e24e1f1503af96d129fed]] Former-commit-id: ba4c386f308147743e1772bca49fb0393a9d50e6 Former-commit-id: e24dd6958e442b52ace317edc824d18bc66a40b5 --- .../viz/warngen/gui/WarngenLayer.java | 51 ++++++++++++++--- .../viz/warngen/template/TemplateRunner.java | 29 +++++----- .../warngen/watchAreaSourceConfiguration.xml | 55 +++++++++++++++++++ 3 files changed, 113 insertions(+), 22 deletions(-) create mode 100755 edexOsgi/com.raytheon.uf.common.dataplugin.warning/utility/common_static/base/warngen/watchAreaSourceConfiguration.xml diff --git a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenLayer.java b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenLayer.java index ac4bdacd2d..f584abf32a 100644 --- a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenLayer.java +++ b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenLayer.java @@ -212,6 +212,7 @@ import com.vividsolutions.jts.io.WKTReader; * 07/01/2014 DR 17450 D. Friedman Use list of templates from backup site. * 07/28/2014 DR 17475 Qinglu Lin Updated populateStrings() and findLargestQuadrant(), removed findLargestGeometry(), * added createAreaAndCentroidMaps() and movePopulatePt(), updated paintText() to center W. + * 07/28/2014 DR15627 mgamazaychikov Change access qualifiers for some fields, methods for GeospatialDataList and GeospatialDataAccessor classes, create setAccessorAreaSourceConfiguration method. * * * @author mschenke @@ -246,10 +247,22 @@ public class WarngenLayer extends AbstractStormTrackResource { GeneralGridGeometry localGridGeometry; } - private static class GeospatialDataAccessor { - GeospatialDataList geoData; + public static class GeospatialDataAccessor { + public GeospatialDataList geoData; - AreaSourceConfiguration areaConfig; + public AreaSourceConfiguration areaConfig; + + public GeospatialDataList getGeoData() { + return geoData; + } + + public AreaSourceConfiguration getAreaConfig() { + return areaConfig; + } + + public GeospatialData[] getFeatures() { + return Arrays.copyOf(geoData.features, geoData.features.length); + } public GeospatialDataAccessor(GeospatialDataList geoData, AreaSourceConfiguration areaConfig) { @@ -1550,7 +1563,7 @@ public class WarngenLayer extends AbstractStormTrackResource { return ugcs; } - private GeospatialDataAccessor getGeospatialDataAcessor() + public GeospatialDataAccessor getGeospatialDataAcessor() throws Exception { GeospatialDataList gdl = searchGeospatialDataAccessor(); if (gdl == null) { @@ -1571,12 +1584,36 @@ public class WarngenLayer extends AbstractStormTrackResource { // TODO: There should be some way to get the "county" configuration by // name // independent of a template - AreaSourceConfiguration areaConfig = new AreaSourceConfiguration(); - areaConfig.setFipsField("FIPS"); - + AreaSourceConfiguration areaConfig = getAccessorAreaSourceConfiguration(); return new GeospatialDataAccessor(gdl, areaConfig); } + private static String ASC_MARINE = "MarineZones"; + private static String ASC_COUNTY = "County"; + + /** + * Returns the AreaSourceConfiguration for either county or marine zones based product + * + * @return + * @throws Exception + */ + private AreaSourceConfiguration getAccessorAreaSourceConfiguration() throws Exception { + boolean isMarineZone = configuration.getGeospatialConfig() + .getAreaSource().equalsIgnoreCase(MARINE); + WarngenConfiguration ascConfig = WarngenConfiguration.loadConfig( + "watchAreaSourceConfiguration", getLocalizedSite(), null); + AreaSourceConfiguration[] areaConfigs = ascConfig.getAreaSources(); + for (AreaSourceConfiguration af:areaConfigs){ + if (!isMarineZone && af.getAreaSource().equalsIgnoreCase(ASC_COUNTY)) {; + return af; + } + else if (isMarineZone && af.getAreaSource().equalsIgnoreCase(ASC_MARINE) ) { + return af; + } + } + return new AreaSourceConfiguration(); + } + private GeospatialDataList searchGeospatialDataAccessor() { synchronized (siteMap) { for (Map.Entry entry : siteMap diff --git a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/template/TemplateRunner.java b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/template/TemplateRunner.java index 1ab7ab65d1..527c276403 100644 --- a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/template/TemplateRunner.java +++ b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/template/TemplateRunner.java @@ -63,7 +63,6 @@ import com.raytheon.uf.common.dataplugin.warning.AbstractWarningRecord; import com.raytheon.uf.common.dataplugin.warning.WarningConstants; import com.raytheon.uf.common.dataplugin.warning.WarningRecord.WarningAction; import com.raytheon.uf.common.dataplugin.warning.config.AreaSourceConfiguration; -import com.raytheon.uf.common.dataplugin.warning.config.AreaSourceConfiguration.AreaType; import com.raytheon.uf.common.dataplugin.warning.config.WarngenConfiguration; import com.raytheon.uf.common.dataplugin.warning.gis.GeospatialData; import com.raytheon.uf.common.dataplugin.warning.util.GeometryUtil; @@ -103,6 +102,7 @@ import com.raytheon.viz.warngen.gis.Wx; import com.raytheon.viz.warngen.gui.BackupData; import com.raytheon.viz.warngen.gui.FollowupData; import com.raytheon.viz.warngen.gui.WarngenLayer; +import com.raytheon.viz.warngen.gui.WarngenLayer.GeospatialDataAccessor; import com.raytheon.viz.warngen.gui.WarngenUIState; import com.raytheon.viz.warngen.text.WarningTextHandler; import com.raytheon.viz.warngen.text.WarningTextHandlerFactory; @@ -159,6 +159,8 @@ import com.vividsolutions.jts.io.WKTReader; * Apr 28, 2014 3033 jsanchez Set the site and backup site in Velocity Engine's properties * Mar 17, 2014 DR 16309 Qinglu Lin Updated getWatches(), processATEntries() and determineAffectedPortions(), and * added determineAffectedMarinePortions(). + * Jul 17, 2014 DR15627 mgamazaychikov Fix setting asc and geoData in processATEntries, update getStateName, + * determineAffectedPortions and determineAffectedMarinePortions. * * * @author njensen @@ -1153,14 +1155,14 @@ public class TemplateRunner { Set validUgcZones) { WatchUtil rval = new WatchUtil(); TreeMap map = new TreeMap(); - + GeospatialData[] geoData = null; AreaSourceConfiguration asc = null; - for (AreaSourceConfiguration a : warngenLayer.getConfiguration() - .getAreaSources()) { - if (a.getType() == AreaType.HATCHING) { - asc = a; - break; - } + try { + GeospatialDataAccessor gda = warngenLayer.getGeospatialDataAcessor(); + geoData = gda.getFeatures(); + asc = gda.getAreaConfig(); + } catch (Exception e) { + statusHandler.handle(Priority.PROBLEM, e.getLocalizedMessage(),e); } if (asc == null) { statusHandler @@ -1168,8 +1170,6 @@ public class TemplateRunner { "Cannot process watches: missing HATCHING area source configuration"); return rval; } - GeospatialData[] geoData = warngenLayer.getGeodataFeatures( - asc.getAreaSource(), warngenLayer.getLocalizedSite()); if ((geoData == null) || (geoData.length == 0)) { statusHandler.handle(Priority.ERROR, "Cannot process watches: cannot get geospatial data"); @@ -1232,7 +1232,7 @@ public class TemplateRunner { rval.addWaw(work.waw); } } else { - if (determineAffectedMarinePortions(work.ugcZone, asc, geoData, work.waw)) { + if (determineAffectedMarinePortions(work.ugcZone, geoData, work.waw)) { rval.addWaw(work.waw); } } @@ -1297,7 +1297,7 @@ public class TemplateRunner { for (Entry> e : map.entrySet()) { Portion portion = new Portion(); try { - portion.parentRegion = getStateName(e.getKey(), asc, geoData) + portion.parentRegion = getStateName(e.getKey(), geoData) .toUpperCase(); } catch (RuntimeException exc) { statusHandler.handle(Priority.ERROR, @@ -1330,8 +1330,7 @@ public class TemplateRunner { */ @SuppressWarnings("deprecation") private static boolean determineAffectedMarinePortions(List ugcs, - AreaSourceConfiguration asc, GeospatialData[] geoData, - WeatherAdvisoryWatch waw) { + GeospatialData[] geoData, WeatherAdvisoryWatch waw) { // Maps state abbreviation to unique fe_area values HashMap> map = new HashMap>(); @@ -1510,7 +1509,7 @@ public class TemplateRunner { return abrev; } - private static String getStateName(String key, AreaSourceConfiguration asc, + private static String getStateName(String key, GeospatialData[] geoData) { for (GeospatialData g : geoData) { if (key.equals(g.attributes.get("STATE"))) { diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.warning/utility/common_static/base/warngen/watchAreaSourceConfiguration.xml b/edexOsgi/com.raytheon.uf.common.dataplugin.warning/utility/common_static/base/warngen/watchAreaSourceConfiguration.xml new file mode 100755 index 0000000000..8efb1a476a --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.warning/utility/common_static/base/warngen/watchAreaSourceConfiguration.xml @@ -0,0 +1,55 @@ + + + + + + + County + 0 + AND + 0 + COUNTYNAME + NAME + STATE + FE_AREA + TIME_ZONE + countyTypes.txt + FIPS + NAME + + parent + + + + + + + 0 + + + + + MarineZones + 0 + AND + 0 + NAME + NAME + NAME + countyTypes.txt + ID + NAME + + parent + + + + + + + 0 + + + From d7c8a9a458f8cfd1751134ec638627da1c0eca6a Mon Sep 17 00:00:00 2001 From: "Kiran.Shrestha" Date: Mon, 28 Jul 2014 16:18:39 -0400 Subject: [PATCH 09/11] ASM #97 - Freezing Level Height AGL for all models has units of dam instead of feet Change-Id: Ib92fbb1c153a8a4739371d8148673a5e32ea36f9 Former-commit-id: 11bab40785647e05e89eaaa2265a7963ef6ff23a [formerly a044b44c8bd9352874d8933083d314266b5a834e [formerly 1730a6dea78cfd922b59c6cccc1c6f44d3a56949]] Former-commit-id: a044b44c8bd9352874d8933083d314266b5a834e Former-commit-id: e9a417f5f8ce88e7ab1c70e51b624c8a65b8a9f9 --- .../common_static/base/styleRules/d2dContourStyleRules.xml | 2 +- .../common_static/base/styleRules/gridImageryStyleRules.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/styleRules/d2dContourStyleRules.xml b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/styleRules/d2dContourStyleRules.xml index c46b09f8bb..cd0173fc21 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/styleRules/d2dContourStyleRules.xml +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/styleRules/d2dContourStyleRules.xml @@ -31,7 +31,7 @@ zAGL - dam + ft 50 diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/styleRules/gridImageryStyleRules.xml b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/styleRules/gridImageryStyleRules.xml index 7e50d4aa9a..98760217c6 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/styleRules/gridImageryStyleRules.xml +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/styleRules/gridImageryStyleRules.xml @@ -74,7 +74,7 @@ Topo - km + ft Grid/gridded data From 0604b6151ffb2b86f2ab02a00bd99e519250b054 Mon Sep 17 00:00:00 2001 From: "Daniel.Huffman" Date: Tue, 29 Jul 2014 21:40:46 +0000 Subject: [PATCH 10/11] ASM #15648 Change to Cities.xml Change-Id: Idc89484cf45fcd1fb30538119d254ed9c0fd79e2 Former-commit-id: ea11c480080f1b3fe09faa4133a5154022062bf5 [formerly aca63e248f1c4b7efb6b38507cef3cc82b03b16b [formerly 1e2b8582fa4dec428b70a2e8aaa1e401ddbfcee7]] Former-commit-id: aca63e248f1c4b7efb6b38507cef3cc82b03b16b Former-commit-id: 008255ad0ef45349a47c2fec16567dc4e76cb875 --- .../localization/bundles/maps/Cities.xml | 42 ++++++++++--------- 1 file changed, 22 insertions(+), 20 deletions(-) diff --git a/cave/com.raytheon.uf.viz.core.maps/localization/bundles/maps/Cities.xml b/cave/com.raytheon.uf.viz.core.maps/localization/bundles/maps/Cities.xml index aff2ef1b06..a6c0b21089 100644 --- a/cave/com.raytheon.uf.viz.core.maps/localization/bundles/maps/Cities.xml +++ b/cave/com.raytheon.uf.viz.core.maps/localization/bundles/maps/Cities.xml @@ -26,7 +26,10 @@ - + + + + PLAN_VIEW @@ -37,7 +40,23 @@ - + PLAN_VIEW + + + + + + cities.lpi + Cities + + + Cities + + + + + outlineWidth="1" /> PLAN_VIEW @@ -51,27 +70,10 @@ Cities - - - - - - - - PLAN_VIEW - - - - - - cities.lpi - Cities - - - Cities + From adcd4dfa64daddfe50b887062bf35d521407f9c6 Mon Sep 17 00:00:00 2001 From: "Shawn.Hooper" Date: Wed, 30 Jul 2014 14:02:42 -0400 Subject: [PATCH 11/11] ASM #15627 Revert "ASM #15627 - WarnGen leaving out reference to State that is under SVR or TOR Watch in SPS text products." This reverts commit c71189dd922fea5c9dc08c9cca48bdb9b0519655 [formerly e24dd6958e442b52ace317edc824d18bc66a40b5] [formerly ba4c386f308147743e1772bca49fb0393a9d50e6] [formerly 8cffe955a9d215c5f3e293ade959e1f4b45c3682 [formerly ba4c386f308147743e1772bca49fb0393a9d50e6 [formerly 00ec5e2d47809d084b3e24e1f1503af96d129fed]]]. Change-Id: Ie01ca9463a4db371ffce0b6e38d5c43e1f9addf2 Former-commit-id: 4e322737cece643661b73035ff3c3399bf412d05 [formerly 976c7b2d4af499de11d4e951382c1a7a90b87b73 [formerly d272d426f8bd218954a75a7b2e19d21b30f975cb]] Former-commit-id: 976c7b2d4af499de11d4e951382c1a7a90b87b73 Former-commit-id: 27f50397aadc7d23b993784d77552f99cff8c947 --- .../viz/warngen/gui/WarngenLayer.java | 51 +++-------------- .../viz/warngen/template/TemplateRunner.java | 29 +++++----- .../warngen/watchAreaSourceConfiguration.xml | 55 ------------------- 3 files changed, 22 insertions(+), 113 deletions(-) delete mode 100755 edexOsgi/com.raytheon.uf.common.dataplugin.warning/utility/common_static/base/warngen/watchAreaSourceConfiguration.xml diff --git a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenLayer.java b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenLayer.java index f584abf32a..ac4bdacd2d 100644 --- a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenLayer.java +++ b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenLayer.java @@ -212,7 +212,6 @@ import com.vividsolutions.jts.io.WKTReader; * 07/01/2014 DR 17450 D. Friedman Use list of templates from backup site. * 07/28/2014 DR 17475 Qinglu Lin Updated populateStrings() and findLargestQuadrant(), removed findLargestGeometry(), * added createAreaAndCentroidMaps() and movePopulatePt(), updated paintText() to center W. - * 07/28/2014 DR15627 mgamazaychikov Change access qualifiers for some fields, methods for GeospatialDataList and GeospatialDataAccessor classes, create setAccessorAreaSourceConfiguration method. * * * @author mschenke @@ -247,22 +246,10 @@ public class WarngenLayer extends AbstractStormTrackResource { GeneralGridGeometry localGridGeometry; } - public static class GeospatialDataAccessor { - public GeospatialDataList geoData; + private static class GeospatialDataAccessor { + GeospatialDataList geoData; - public AreaSourceConfiguration areaConfig; - - public GeospatialDataList getGeoData() { - return geoData; - } - - public AreaSourceConfiguration getAreaConfig() { - return areaConfig; - } - - public GeospatialData[] getFeatures() { - return Arrays.copyOf(geoData.features, geoData.features.length); - } + AreaSourceConfiguration areaConfig; public GeospatialDataAccessor(GeospatialDataList geoData, AreaSourceConfiguration areaConfig) { @@ -1563,7 +1550,7 @@ public class WarngenLayer extends AbstractStormTrackResource { return ugcs; } - public GeospatialDataAccessor getGeospatialDataAcessor() + private GeospatialDataAccessor getGeospatialDataAcessor() throws Exception { GeospatialDataList gdl = searchGeospatialDataAccessor(); if (gdl == null) { @@ -1584,36 +1571,12 @@ public class WarngenLayer extends AbstractStormTrackResource { // TODO: There should be some way to get the "county" configuration by // name // independent of a template - AreaSourceConfiguration areaConfig = getAccessorAreaSourceConfiguration(); + AreaSourceConfiguration areaConfig = new AreaSourceConfiguration(); + areaConfig.setFipsField("FIPS"); + return new GeospatialDataAccessor(gdl, areaConfig); } - private static String ASC_MARINE = "MarineZones"; - private static String ASC_COUNTY = "County"; - - /** - * Returns the AreaSourceConfiguration for either county or marine zones based product - * - * @return - * @throws Exception - */ - private AreaSourceConfiguration getAccessorAreaSourceConfiguration() throws Exception { - boolean isMarineZone = configuration.getGeospatialConfig() - .getAreaSource().equalsIgnoreCase(MARINE); - WarngenConfiguration ascConfig = WarngenConfiguration.loadConfig( - "watchAreaSourceConfiguration", getLocalizedSite(), null); - AreaSourceConfiguration[] areaConfigs = ascConfig.getAreaSources(); - for (AreaSourceConfiguration af:areaConfigs){ - if (!isMarineZone && af.getAreaSource().equalsIgnoreCase(ASC_COUNTY)) {; - return af; - } - else if (isMarineZone && af.getAreaSource().equalsIgnoreCase(ASC_MARINE) ) { - return af; - } - } - return new AreaSourceConfiguration(); - } - private GeospatialDataList searchGeospatialDataAccessor() { synchronized (siteMap) { for (Map.Entry entry : siteMap diff --git a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/template/TemplateRunner.java b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/template/TemplateRunner.java index 527c276403..1ab7ab65d1 100644 --- a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/template/TemplateRunner.java +++ b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/template/TemplateRunner.java @@ -63,6 +63,7 @@ import com.raytheon.uf.common.dataplugin.warning.AbstractWarningRecord; import com.raytheon.uf.common.dataplugin.warning.WarningConstants; import com.raytheon.uf.common.dataplugin.warning.WarningRecord.WarningAction; import com.raytheon.uf.common.dataplugin.warning.config.AreaSourceConfiguration; +import com.raytheon.uf.common.dataplugin.warning.config.AreaSourceConfiguration.AreaType; import com.raytheon.uf.common.dataplugin.warning.config.WarngenConfiguration; import com.raytheon.uf.common.dataplugin.warning.gis.GeospatialData; import com.raytheon.uf.common.dataplugin.warning.util.GeometryUtil; @@ -102,7 +103,6 @@ import com.raytheon.viz.warngen.gis.Wx; import com.raytheon.viz.warngen.gui.BackupData; import com.raytheon.viz.warngen.gui.FollowupData; import com.raytheon.viz.warngen.gui.WarngenLayer; -import com.raytheon.viz.warngen.gui.WarngenLayer.GeospatialDataAccessor; import com.raytheon.viz.warngen.gui.WarngenUIState; import com.raytheon.viz.warngen.text.WarningTextHandler; import com.raytheon.viz.warngen.text.WarningTextHandlerFactory; @@ -159,8 +159,6 @@ import com.vividsolutions.jts.io.WKTReader; * Apr 28, 2014 3033 jsanchez Set the site and backup site in Velocity Engine's properties * Mar 17, 2014 DR 16309 Qinglu Lin Updated getWatches(), processATEntries() and determineAffectedPortions(), and * added determineAffectedMarinePortions(). - * Jul 17, 2014 DR15627 mgamazaychikov Fix setting asc and geoData in processATEntries, update getStateName, - * determineAffectedPortions and determineAffectedMarinePortions. * * * @author njensen @@ -1155,14 +1153,14 @@ public class TemplateRunner { Set validUgcZones) { WatchUtil rval = new WatchUtil(); TreeMap map = new TreeMap(); - GeospatialData[] geoData = null; + AreaSourceConfiguration asc = null; - try { - GeospatialDataAccessor gda = warngenLayer.getGeospatialDataAcessor(); - geoData = gda.getFeatures(); - asc = gda.getAreaConfig(); - } catch (Exception e) { - statusHandler.handle(Priority.PROBLEM, e.getLocalizedMessage(),e); + for (AreaSourceConfiguration a : warngenLayer.getConfiguration() + .getAreaSources()) { + if (a.getType() == AreaType.HATCHING) { + asc = a; + break; + } } if (asc == null) { statusHandler @@ -1170,6 +1168,8 @@ public class TemplateRunner { "Cannot process watches: missing HATCHING area source configuration"); return rval; } + GeospatialData[] geoData = warngenLayer.getGeodataFeatures( + asc.getAreaSource(), warngenLayer.getLocalizedSite()); if ((geoData == null) || (geoData.length == 0)) { statusHandler.handle(Priority.ERROR, "Cannot process watches: cannot get geospatial data"); @@ -1232,7 +1232,7 @@ public class TemplateRunner { rval.addWaw(work.waw); } } else { - if (determineAffectedMarinePortions(work.ugcZone, geoData, work.waw)) { + if (determineAffectedMarinePortions(work.ugcZone, asc, geoData, work.waw)) { rval.addWaw(work.waw); } } @@ -1297,7 +1297,7 @@ public class TemplateRunner { for (Entry> e : map.entrySet()) { Portion portion = new Portion(); try { - portion.parentRegion = getStateName(e.getKey(), geoData) + portion.parentRegion = getStateName(e.getKey(), asc, geoData) .toUpperCase(); } catch (RuntimeException exc) { statusHandler.handle(Priority.ERROR, @@ -1330,7 +1330,8 @@ public class TemplateRunner { */ @SuppressWarnings("deprecation") private static boolean determineAffectedMarinePortions(List ugcs, - GeospatialData[] geoData, WeatherAdvisoryWatch waw) { + AreaSourceConfiguration asc, GeospatialData[] geoData, + WeatherAdvisoryWatch waw) { // Maps state abbreviation to unique fe_area values HashMap> map = new HashMap>(); @@ -1509,7 +1510,7 @@ public class TemplateRunner { return abrev; } - private static String getStateName(String key, + private static String getStateName(String key, AreaSourceConfiguration asc, GeospatialData[] geoData) { for (GeospatialData g : geoData) { if (key.equals(g.attributes.get("STATE"))) { diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.warning/utility/common_static/base/warngen/watchAreaSourceConfiguration.xml b/edexOsgi/com.raytheon.uf.common.dataplugin.warning/utility/common_static/base/warngen/watchAreaSourceConfiguration.xml deleted file mode 100755 index 8efb1a476a..0000000000 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.warning/utility/common_static/base/warngen/watchAreaSourceConfiguration.xml +++ /dev/null @@ -1,55 +0,0 @@ - - - - - - - County - 0 - AND - 0 - COUNTYNAME - NAME - STATE - FE_AREA - TIME_ZONE - countyTypes.txt - FIPS - NAME - - parent - - - - - - - 0 - - - - - MarineZones - 0 - AND - 0 - NAME - NAME - NAME - countyTypes.txt - ID - NAME - - parent - - - - - - - 0 - - -