Muster SDK  8.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
MHistoryChunk.h
Go to the documentation of this file.
1 /*****************************************************************************
2  **
3  ** Header file for Muster API History chunk object
4  **
5  ** Name : MRepository.h
6  ** Author : Leonardo Bernardini
7  ** Version : 1.0, Sat Mar 2nd 2013
8  **
9  ** Copyright 2000-2014, Virtual Vertex
10  ** All Rights Reserved.
11  **
12  ** This file contains UNPUBLISHED PROPRIETARY SOURCE CODE.
13  ** The contents of this file may not be disclosed to third parties, copied
14  ** or duplicated in any form, in whole or in part, without the prior written
15  ** permission of the author.
16  **
17  *****************************************************************************/
18 #ifndef MHISTORYCHUNK_H
19 #define MHISTORYCHUNK_H
20 
21 #ifdef WIN32
22 // Windows definitions
23 #ifdef MCLIENTLIB_EXPORTS
24 #define MCLIENTLIB_API __declspec(dllexport)
25 #else
26 #define MCLIENTLIB_API __declspec(dllimport)
27 #endif
28 #else
29 
30 #ifndef MCLIENTLIB_EXPORTS
31 #ifdef LINUX
32 #define MCLIENTLIB_API
33 #else
34 #define MCLIENTLIB_API
35 #endif
36 #else
37 #define MCLIENTLIB_API
38 #endif
39 #endif
40 
41 
42 // Disable STL Export warning, member is private, we don't need direct access from the DLL client
43 #if defined(_WIN32)
44 #pragma warning(disable: 4251)
45 #endif // _WIN32
46 
47 #include <string>
48 #include <list>
49 #include <vector>
50 
51 namespace MClientLib {
52 
57  public:
58 
63  kHistoryChunkStatusCompleted = 0x01,
64  kHistoryChunkStatusWarning = 0x02,
65  kHistoryChunkStatusAborted = 0x04,
66  kHistoryChunkStatusError = 0x08,
67  kHistoryChunkStatusTimeout = 0x10
68  };
69 
70  private:
71  long id;
72  long jobId;
73  int status;
74  float startFrame;
75  float endFrame;
76  float byFrame;
77  long long int startTime;
78  long long int endTime;
79  std::string renderingHost;
80  std::string result;
81  long chunkId;
82  int startingNumber;
83  bool isAssembler;
84  std::string jobName;
85  std::string jobGroup;
86  std::string jobDepartment;
87  std::string jobFile;
88  std::string jobProject;
89  int stepBy;
90  int packetSize;
91  public:
92  MHistoryChunk();
93  ~MHistoryChunk();
94 
95  long getId();
96  long getJobId();
97  int getStatus();
98  float getStartFrame();
99  float getEndFrame();
100  float getByFrame();
101  long long int getStartTime();
102  long long int getEndTime();
103  std::string getRenderingHost();
104  std::string getResult();
105  long getChunkId();
106  int getStartingNumber();
107  bool getIsAssembler();
108  std::string getJobName();
109  std::string getJobGroup();
110  std::string getJobDepartment();
111  std::string getJobFile();
112  std::string getJobProject();
113  int getStepBy();
114  int getPacketSize();
115 
116  void setId(long);
117  void setJobId(long);
118  void setStatus(int);
119  void setStartFrame(float);
120  void setEndFrame(float);
121  void setByFrame(float);
122  void setStartTime(long long int);
123  void setEndTime(long long int);
124  void setRenderingHost(const std::string&);
125  void setResult(const std::string&);
126  void setChunkId(long);
127  void setStartingNumber(int);
128  void setIsAssembler(bool);
129  void setJobName(const std::string&);
130  void setJobGroup(const std::string&);
131  void setJobDepartment(const std::string&);
132  void setJobFile(const std::string&);
133  void setJobProject(const std::string&);
134  void setStepBy(int);
135  void setPacketSize(int);
136 
137  bool Unmarshall(std::vector<std::string>& items);
138  bool Unmarshall(const char* data);
139  std::string Marshall();
140  };
141 }
142 
143 #endif