source: XIOS/dev/dev_trunk_graph/src/filter/client_to_server_store_filter.hpp @ 2027

Last change on this file since 2027 was 2019, checked in by yushan, 3 years ago

Graph intermedia commit to a tmp branch

  • Property svn:executable set to *
File size: 1.7 KB
Line 
1#ifndef __XIOS_CLIENT_TO_SERVER_STORE_FILTER__
2#define __XIOS_CLIENT_TO_SERVER_STORE_FILTER__
3
4#include "input_pin.hpp"
5#include "graph_package.hpp"
6
7namespace xios
8{
9  class CField;
10  class CContextClient ;
11
12  /*!
13   * A terminal filter which transmits the packets it receives to a field for writting in a file.
14   */
15  class CClientToServerStoreFilter : public CInputPin
16  {
17    public:
18      /*!
19       * Constructs the filter (with one input slot) associated to the specified field
20       * and a garbage collector.
21       *
22       * \param gc the associated garbage collector
23       * \param field the associated field
24       */
25      CClientToServerStoreFilter(CGarbageCollector& gc, CField* field, CContextClient* client);
26
27      /*!
28       * Tests if the filter must auto-trigger.
29       *
30       * \return true if the filter must auto-trigger
31       */
32      bool virtual mustAutoTrigger() const;
33     
34      void buildWorkflowGraph(std::vector<CDataPacketPtr> data);
35
36      /*!
37       * Tests whether data is expected for the specified date.
38       *
39       * \param date the date associated to the data
40       */
41      bool virtual isDataExpected(const CDate& date) const;
42      CGraphPackage * graphPackage;
43      bool graphEnabled;
44
45    protected:
46      /*!
47       * Callbacks a field to write a packet to a file.
48       *
49       * \param data a vector of packets corresponding to each slot
50       */
51      void virtual onInputReady(std::vector<CDataPacketPtr> data);
52
53    private:
54      CField* field_; //<! The associated field
55      CContextClient* client_ ; //! the associated context client
56  }; // class CClientToServerStoreFilter
57} // namespace xios
58
59#endif //__XIOS_CLIENT_TO_SERVER_STORE_FILTER__
Note: See TracBrowser for help on using the repository browser.