GPUdb C++ API  Version 7.2.3.0
visualize_isochrone.h
Go to the documentation of this file.
1 /*
2  * This file was autogenerated by the Kinetica schema processor.
3  *
4  * DO NOT EDIT DIRECTLY.
5  */
6 #ifndef __VISUALIZE_ISOCHRONE_H__
7 #define __VISUALIZE_ISOCHRONE_H__
8 
9 namespace gpudb
10 {
24  {
30  graphName(std::string()),
31  sourceNode(std::string()),
32  maxSolutionRadius(double()),
33  weightsOnEdges(std::vector<std::string>()),
34  restrictions(std::vector<std::string>()),
35  numLevels(int32_t()),
36  generateImage(bool()),
37  levelsTable(std::string()),
38  styleOptions(std::map<std::string, std::string>()),
39  solveOptions(std::map<std::string, std::string>()),
40  contourOptions(std::map<std::string, std::string>()),
41  options(std::map<std::string, std::string>())
42  {
43  }
44 
783  VisualizeIsochroneRequest(const std::string& graphName_, const std::string& sourceNode_, const double maxSolutionRadius_, const std::vector<std::string>& weightsOnEdges_, const std::vector<std::string>& restrictions_, const int32_t numLevels_, const bool generateImage_, const std::string& levelsTable_, const std::map<std::string, std::string>& styleOptions_, const std::map<std::string, std::string>& solveOptions_, const std::map<std::string, std::string>& contourOptions_, const std::map<std::string, std::string>& options_):
784  graphName( graphName_ ),
785  sourceNode( sourceNode_ ),
786  maxSolutionRadius( maxSolutionRadius_ ),
787  weightsOnEdges( weightsOnEdges_ ),
788  restrictions( restrictions_ ),
789  numLevels( numLevels_ ),
790  generateImage( generateImage_ ),
791  levelsTable( levelsTable_ ),
792  styleOptions( styleOptions_ ),
793  solveOptions( solveOptions_ ),
794  contourOptions( contourOptions_ ),
795  options( options_ )
796  {
797  }
798 
802  std::string graphName;
803 
808  std::string sourceNode;
809 
815 
830  std::vector<std::string> weightsOnEdges;
831 
852  std::vector<std::string> restrictions;
853 
858  int32_t numLevels;
859 
871 
882  std::string levelsTable;
883 
1071  std::map<std::string, std::string> styleOptions;
1072 
1106  std::map<std::string, std::string> solveOptions;
1107 
1232  std::map<std::string, std::string> contourOptions;
1233 
1321  std::map<std::string, std::string> options;
1322  };
1323 } // end namespace gpudb
1324 
1325 namespace avro
1326 {
1327  template<> struct codec_traits<gpudb::VisualizeIsochroneRequest>
1328  {
1329  static void encode(Encoder& e, const gpudb::VisualizeIsochroneRequest& v)
1330  {
1331  ::avro::encode(e, v.graphName);
1332  ::avro::encode(e, v.sourceNode);
1333  ::avro::encode(e, v.maxSolutionRadius);
1334  ::avro::encode(e, v.weightsOnEdges);
1335  ::avro::encode(e, v.restrictions);
1336  ::avro::encode(e, v.numLevels);
1337  ::avro::encode(e, v.generateImage);
1338  ::avro::encode(e, v.levelsTable);
1339  ::avro::encode(e, v.styleOptions);
1340  ::avro::encode(e, v.solveOptions);
1341  ::avro::encode(e, v.contourOptions);
1342  ::avro::encode(e, v.options);
1343  }
1344 
1345  static void decode(Decoder& d, gpudb::VisualizeIsochroneRequest& v)
1346  {
1347  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
1348  {
1349  const std::vector<size_t> fo = rd->fieldOrder();
1350 
1351  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
1352  {
1353  switch (*it)
1354  {
1355  case 0:
1356  ::avro::decode(d, v.graphName);
1357  break;
1358 
1359  case 1:
1360  ::avro::decode(d, v.sourceNode);
1361  break;
1362 
1363  case 2:
1364  ::avro::decode(d, v.maxSolutionRadius);
1365  break;
1366 
1367  case 3:
1368  ::avro::decode(d, v.weightsOnEdges);
1369  break;
1370 
1371  case 4:
1372  ::avro::decode(d, v.restrictions);
1373  break;
1374 
1375  case 5:
1376  ::avro::decode(d, v.numLevels);
1377  break;
1378 
1379  case 6:
1380  ::avro::decode(d, v.generateImage);
1381  break;
1382 
1383  case 7:
1384  ::avro::decode(d, v.levelsTable);
1385  break;
1386 
1387  case 8:
1388  ::avro::decode(d, v.styleOptions);
1389  break;
1390 
1391  case 9:
1392  ::avro::decode(d, v.solveOptions);
1393  break;
1394 
1395  case 10:
1396  ::avro::decode(d, v.contourOptions);
1397  break;
1398 
1399  case 11:
1400  ::avro::decode(d, v.options);
1401  break;
1402 
1403  default:
1404  break;
1405  }
1406  }
1407  }
1408  else
1409  {
1410  ::avro::decode(d, v.graphName);
1411  ::avro::decode(d, v.sourceNode);
1412  ::avro::decode(d, v.maxSolutionRadius);
1413  ::avro::decode(d, v.weightsOnEdges);
1414  ::avro::decode(d, v.restrictions);
1415  ::avro::decode(d, v.numLevels);
1416  ::avro::decode(d, v.generateImage);
1417  ::avro::decode(d, v.levelsTable);
1418  ::avro::decode(d, v.styleOptions);
1419  ::avro::decode(d, v.solveOptions);
1420  ::avro::decode(d, v.contourOptions);
1421  ::avro::decode(d, v.options);
1422  }
1423  }
1424  };
1425 } // end namespace avro
1426 
1427 namespace gpudb
1428 {
1435  {
1441  width(int32_t()),
1442  height(int32_t()),
1443  bgColor(int64_t()),
1444  imageData(std::vector<uint8_t>()),
1445  info(std::map<std::string, std::string>()),
1446  solveInfo(std::map<std::string, std::string>()),
1447  contourInfo(std::map<std::string, std::string>())
1448  {
1449  }
1450 
1455  int32_t width;
1456 
1461  int32_t height;
1462 
1467  int64_t bgColor;
1468 
1472  std::vector<uint8_t> imageData;
1473 
1477  std::map<std::string, std::string> info;
1478 
1482  std::map<std::string, std::string> solveInfo;
1483 
1487  std::map<std::string, std::string> contourInfo;
1488  };
1489 } // end namespace gpudb
1490 
1491 namespace avro
1492 {
1493  template<> struct codec_traits<gpudb::VisualizeIsochroneResponse>
1494  {
1495  static void encode(Encoder& e, const gpudb::VisualizeIsochroneResponse& v)
1496  {
1497  ::avro::encode(e, v.width);
1498  ::avro::encode(e, v.height);
1499  ::avro::encode(e, v.bgColor);
1500  ::avro::encode(e, v.imageData);
1501  ::avro::encode(e, v.info);
1502  ::avro::encode(e, v.solveInfo);
1503  ::avro::encode(e, v.contourInfo);
1504  }
1505 
1506  static void decode(Decoder& d, gpudb::VisualizeIsochroneResponse& v)
1507  {
1508  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
1509  {
1510  const std::vector<size_t> fo = rd->fieldOrder();
1511 
1512  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
1513  {
1514  switch (*it)
1515  {
1516  case 0:
1517  ::avro::decode(d, v.width);
1518  break;
1519 
1520  case 1:
1521  ::avro::decode(d, v.height);
1522  break;
1523 
1524  case 2:
1525  ::avro::decode(d, v.bgColor);
1526  break;
1527 
1528  case 3:
1529  ::avro::decode(d, v.imageData);
1530  break;
1531 
1532  case 4:
1533  ::avro::decode(d, v.info);
1534  break;
1535 
1536  case 5:
1537  ::avro::decode(d, v.solveInfo);
1538  break;
1539 
1540  case 6:
1541  ::avro::decode(d, v.contourInfo);
1542  break;
1543 
1544  default:
1545  break;
1546  }
1547  }
1548  }
1549  else
1550  {
1551  ::avro::decode(d, v.width);
1552  ::avro::decode(d, v.height);
1553  ::avro::decode(d, v.bgColor);
1554  ::avro::decode(d, v.imageData);
1555  ::avro::decode(d, v.info);
1556  ::avro::decode(d, v.solveInfo);
1557  ::avro::decode(d, v.contourInfo);
1558  }
1559  }
1560  };
1561 } // end namespace avro
1562 
1563 #endif // __VISUALIZE_ISOCHRONE_H__
std::map< std::string, std::string > info
Additional information.
VisualizeIsochroneRequest()
Constructs a VisualizeIsochroneRequest object with default parameters.
VisualizeIsochroneResponse()
Constructs a VisualizeIsochroneResponse object with default parameters.
std::map< std::string, std::string > styleOptions
Various style related options of the isochrone image.
int64_t bgColor
Background color of the image as provided in bg_color.
std::vector< uint8_t > imageData
Generated contour image data.
int32_t numLevels
Number of equally-separated isochrones to compute.
double maxSolutionRadius
Extent of the search radius around sourceNode.
bool generateImage
If set to true, generates a PNG image of the isochrones in the response.
std::string sourceNode
Starting vertex on the underlying graph from/to which the isochrones are created.
int32_t height
Height of the image as provided in height.
A set of parameters for GPUdb::visualizeIsochrone.
std::vector< std::string > weightsOnEdges
Additional weights to apply to the edges of an existing graph.
VisualizeIsochroneRequest(const std::string &graphName_, const std::string &sourceNode_, const double maxSolutionRadius_, const std::vector< std::string > &weightsOnEdges_, const std::vector< std::string > &restrictions_, const int32_t numLevels_, const bool generateImage_, const std::string &levelsTable_, const std::map< std::string, std::string > &styleOptions_, const std::map< std::string, std::string > &solveOptions_, const std::map< std::string, std::string > &contourOptions_, const std::map< std::string, std::string > &options_)
Constructs a VisualizeIsochroneRequest object with the specified parameters.
std::map< std::string, std::string > solveInfo
Additional information.
std::map< std::string, std::string > options
Additional parameters.
std::string levelsTable
Name of the table to output the isochrones to, in [ schema_name.
std::string graphName
Name of the graph on which the isochrone is to be computed.
A set of results returned by GPUdb::visualizeIsochrone.
std::map< std::string, std::string > solveOptions
Solver specific parameters.
std::map< std::string, std::string > contourInfo
Additional information.
std::vector< std::string > restrictions
Additional restrictions to apply to the nodes/edges of an existing graph.
int32_t width
Width of the image as provided in width.
std::map< std::string, std::string > contourOptions
Contour specific parameters.