GPUdb C++ API  Version 7.1.10.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
match_graph.h
Go to the documentation of this file.
1 /*
2  * This file was autogenerated by the GPUdb schema processor.
3  *
4  * DO NOT EDIT DIRECTLY.
5  */
6 #ifndef __MATCH_GRAPH_H__
7 #define __MATCH_GRAPH_H__
8 
9 namespace gpudb
10 {
11 
33  {
34 
39  graphName(std::string()),
40  samplePoints(std::vector<std::string>()),
41  solveMethod(std::string()),
42  solutionTable(std::string()),
43  options(std::map<std::string, std::string>())
44  {
45  }
46 
548  MatchGraphRequest(const std::string& graphName_, const std::vector<std::string>& samplePoints_, const std::string& solveMethod_, const std::string& solutionTable_, const std::map<std::string, std::string>& options_):
549  graphName( graphName_ ),
550  samplePoints( samplePoints_ ),
551  solveMethod( solveMethod_ ),
552  solutionTable( solutionTable_ ),
553  options( options_ )
554  {
555  }
556 
557  std::string graphName;
558  std::vector<std::string> samplePoints;
559  std::string solveMethod;
560  std::string solutionTable;
561  std::map<std::string, std::string> options;
562  };
563 }
564 
565 namespace avro
566 {
567  template<> struct codec_traits<gpudb::MatchGraphRequest>
568  {
569  static void encode(Encoder& e, const gpudb::MatchGraphRequest& v)
570  {
571  ::avro::encode(e, v.graphName);
572  ::avro::encode(e, v.samplePoints);
573  ::avro::encode(e, v.solveMethod);
574  ::avro::encode(e, v.solutionTable);
575  ::avro::encode(e, v.options);
576  }
577 
578  static void decode(Decoder& d, gpudb::MatchGraphRequest& v)
579  {
580  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
581  {
582  const std::vector<size_t> fo = rd->fieldOrder();
583 
584  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
585  {
586  switch (*it)
587  {
588  case 0:
589  ::avro::decode(d, v.graphName);
590  break;
591 
592  case 1:
593  ::avro::decode(d, v.samplePoints);
594  break;
595 
596  case 2:
597  ::avro::decode(d, v.solveMethod);
598  break;
599 
600  case 3:
601  ::avro::decode(d, v.solutionTable);
602  break;
603 
604  case 4:
605  ::avro::decode(d, v.options);
606  break;
607 
608  default:
609  break;
610  }
611  }
612  }
613  else
614  {
615  ::avro::decode(d, v.graphName);
616  ::avro::decode(d, v.samplePoints);
617  ::avro::decode(d, v.solveMethod);
618  ::avro::decode(d, v.solutionTable);
619  ::avro::decode(d, v.options);
620  }
621  }
622  };
623 }
624 
625 namespace gpudb
626 {
627 
649  {
650 
656  result(bool()),
657  matchScore(float()),
658  info(std::map<std::string, std::string>())
659  {
660  }
661 
662  bool result;
663  float matchScore;
664  std::map<std::string, std::string> info;
665  };
666 }
667 
668 namespace avro
669 {
670  template<> struct codec_traits<gpudb::MatchGraphResponse>
671  {
672  static void encode(Encoder& e, const gpudb::MatchGraphResponse& v)
673  {
674  ::avro::encode(e, v.result);
675  ::avro::encode(e, v.matchScore);
676  ::avro::encode(e, v.info);
677  }
678 
679  static void decode(Decoder& d, gpudb::MatchGraphResponse& v)
680  {
681  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
682  {
683  const std::vector<size_t> fo = rd->fieldOrder();
684 
685  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
686  {
687  switch (*it)
688  {
689  case 0:
690  ::avro::decode(d, v.result);
691  break;
692 
693  case 1:
694  ::avro::decode(d, v.matchScore);
695  break;
696 
697  case 2:
698  ::avro::decode(d, v.info);
699  break;
700 
701  default:
702  break;
703  }
704  }
705  }
706  else
707  {
708  ::avro::decode(d, v.result);
709  ::avro::decode(d, v.matchScore);
710  ::avro::decode(d, v.info);
711  }
712  }
713  };
714 }
715 
716 #endif
MatchGraphResponse()
Constructs a MatchGraphResponse object with default parameter values.
Definition: match_graph.h:655
A set of input parameters for const.
Definition: match_graph.h:32
std::map< std::string, std::string > options
Definition: match_graph.h:561
MatchGraphRequest(const std::string &graphName_, const std::vector< std::string > &samplePoints_, const std::string &solveMethod_, const std::string &solutionTable_, const std::map< std::string, std::string > &options_)
Constructs a MatchGraphRequest object with the specified parameters.
Definition: match_graph.h:548
std::map< std::string, std::string > info
Definition: match_graph.h:664
MatchGraphRequest()
Constructs a MatchGraphRequest object with default parameter values.
Definition: match_graph.h:38
std::vector< std::string > samplePoints
Definition: match_graph.h:558
A set of output parameters for const.
Definition: match_graph.h:648