F´ Flight Software - C/C++ Documentation
A framework for building embedded system applications to NASA flight quality standards.
FileManagerComponentAc.hpp
Go to the documentation of this file.
1 // ======================================================================
2 // \title FileManagerComponentAc.hpp
3 // \author Generated by fpp-to-cpp
4 // \brief hpp file for FileManager component base class
5 // ======================================================================
6 
7 #ifndef Svc_FileManagerComponentAc_HPP
8 #define Svc_FileManagerComponentAc_HPP
9 
10 #include <atomic>
11 
12 #include "Fw/Cmd/CmdPortAc.hpp"
13 #include "Fw/Cmd/CmdRegPortAc.hpp"
15 #include "Fw/Cmd/CmdString.hpp"
17 #include "Fw/FPrimeBasicTypes.hpp"
18 #include "Fw/Log/LogPortAc.hpp"
19 #include "Fw/Log/LogString.hpp"
20 #include "Fw/Log/LogTextPortAc.hpp"
21 #if !FW_DIRECT_PORT_CALLS
23 #endif
24 #if !FW_DIRECT_PORT_CALLS
26 #endif
27 #include "Fw/Time/TimePortAc.hpp"
28 #include "Fw/Tlm/TlmPortAc.hpp"
29 #include "Fw/Tlm/TlmString.hpp"
32 #include "Svc/Ping/PingPortAc.hpp"
36 
37 namespace Svc {
38 
45  {
46 
47  // ----------------------------------------------------------------------
48  // Friend classes
49  // ----------------------------------------------------------------------
50 
52  friend class FileManagerTesterBase;
54  friend class FileManagerTester;
55 
56  protected:
57 
58  // ----------------------------------------------------------------------
59  // Constants
60  // ----------------------------------------------------------------------
61 
63  enum {
65  };
66 
68  enum {
71  };
72 
74  enum {
81  };
82 
84  enum {
86  };
87 
89  enum {
98  };
99 
101  enum {
129  };
130 
132  enum {
135  };
136 
137  public:
138 
139  // ----------------------------------------------------------------------
140  // Component initialization
141  // ----------------------------------------------------------------------
142 
144  void init(
145  FwSizeType queueDepth,
146  FwEnumStoreType instance = 0
147  );
148 
149 #if !FW_DIRECT_PORT_CALLS
150 
151  public:
152 
153  // ----------------------------------------------------------------------
154  // Getters for special input ports
155  // ----------------------------------------------------------------------
156 
161  FwIndexType portNum
162  );
163 
164 #endif
165 
166 #if !FW_DIRECT_PORT_CALLS
167 
168  public:
169 
170  // ----------------------------------------------------------------------
171  // Getters for typed input ports
172  // ----------------------------------------------------------------------
173 
178  FwIndexType portNum
179  );
180 
185  FwIndexType portNum
186  );
187 
188 #endif
189 
190 #if !FW_DIRECT_PORT_CALLS
191 
192  public:
193 
194  // ----------------------------------------------------------------------
195  // Connect input ports to special output ports
196  // ----------------------------------------------------------------------
197 
198 #if FW_ENABLE_TEXT_LOGGING == 1
199 
201  void set_LogText_OutputPort(
202  FwIndexType portNum,
203  Fw::InputLogTextPort* port
204  );
205 
206 #endif
207 
210  FwIndexType portNum,
211  Fw::InputCmdRegPort* port
212  );
213 
216  FwIndexType portNum,
218  );
219 
222  FwIndexType portNum,
223  Fw::InputLogPort* port
224  );
225 
228  FwIndexType portNum,
229  Fw::InputTimePort* port
230  );
231 
234  FwIndexType portNum,
235  Fw::InputTlmPort* port
236  );
237 
238 #endif
239 
240 #if !FW_DIRECT_PORT_CALLS
241 
242  public:
243 
244  // ----------------------------------------------------------------------
245  // Connect typed input ports to typed output ports
246  // ----------------------------------------------------------------------
247 
250  FwIndexType portNum,
251  Svc::InputPingPort* port
252  );
253 
254 #endif
255 
256 #if !FW_DIRECT_PORT_CALLS && FW_PORT_SERIALIZATION
257 
258  public:
259 
260  // ----------------------------------------------------------------------
261  // Connect serial input ports to special output ports
262  // ----------------------------------------------------------------------
263 
264 #if FW_ENABLE_TEXT_LOGGING == 1
265 
267  void set_LogText_OutputPort(
268  FwIndexType portNum,
269  Fw::InputSerializePort* port
270  );
271 
272 #endif
273 
276  FwIndexType portNum,
277  Fw::InputSerializePort* port
278  );
279 
282  FwIndexType portNum,
283  Fw::InputSerializePort* port
284  );
285 
288  FwIndexType portNum,
289  Fw::InputSerializePort* port
290  );
291 
294  FwIndexType portNum,
295  Fw::InputSerializePort* port
296  );
297 
300  FwIndexType portNum,
301  Fw::InputSerializePort* port
302  );
303 
304 #endif
305 
306 #if !FW_DIRECT_PORT_CALLS && FW_PORT_SERIALIZATION
307 
308  public:
309 
310  // ----------------------------------------------------------------------
311  // Connect serial input ports to typed output ports
312  // ----------------------------------------------------------------------
313 
316  FwIndexType portNum,
317  Fw::InputSerializePort* port
318  );
319 
320 #endif
321 
322  public:
323 
324  // ----------------------------------------------------------------------
325  // Command registration
326  // ----------------------------------------------------------------------
327 
331  void regCommands();
332 
333  protected:
334 
335  // ----------------------------------------------------------------------
336  // Component construction and destruction
337  // ----------------------------------------------------------------------
338 
341  const char* compName = ""
342  );
343 
345  virtual ~FileManagerComponentBase();
346 
347  protected:
348 
349  // ----------------------------------------------------------------------
350  // Getters for numbers of special input ports
351  // ----------------------------------------------------------------------
352 
357  return NUM_CMDIN_INPUT_PORTS;
358  }
359 
360  protected:
361 
362  // ----------------------------------------------------------------------
363  // Getters for numbers of typed input ports
364  // ----------------------------------------------------------------------
365 
370  return NUM_PINGIN_INPUT_PORTS;
371  }
372 
378  }
379 
380  protected:
381 
382  // ----------------------------------------------------------------------
383  // Getters for numbers of special output ports
384  // ----------------------------------------------------------------------
385 
386 #if FW_ENABLE_TEXT_LOGGING == 1
387 
391  static constexpr FwIndexType getNum_LogText_OutputPorts() {
393  }
394 
395 #endif
396 
402  }
403 
409  }
410 
416  }
417 
423  }
424 
430  }
431 
432  protected:
433 
434  // ----------------------------------------------------------------------
435  // Getters for numbers of typed output ports
436  // ----------------------------------------------------------------------
437 
443  }
444 
445  protected:
446 
447  // ----------------------------------------------------------------------
448  // Connection status queries for special output ports
449  // ----------------------------------------------------------------------
450 
451 #if FW_ENABLE_TEXT_LOGGING == 1
452 
456  bool isConnected_LogText_OutputPort(
457  FwIndexType portNum
458  ) const;
459 
460 #endif
461 
466  FwIndexType portNum
467  ) const;
468 
473  FwIndexType portNum
474  ) const;
475 
480  FwIndexType portNum
481  ) const;
482 
487  FwIndexType portNum
488  ) const;
489 
494  FwIndexType portNum
495  ) const;
496 
497  protected:
498 
499  // ----------------------------------------------------------------------
500  // Connection status queries for typed output ports
501  // ----------------------------------------------------------------------
502 
507  FwIndexType portNum
508  ) const;
509 
510 #if FW_DIRECT_PORT_CALLS
511  public:
512 #else
513  protected:
514 #endif
515 
516  // ----------------------------------------------------------------------
517  // Port handler base-class functions for special input ports
518  //
519  // Call these functions directly to bypass the corresponding ports
520  // ----------------------------------------------------------------------
521 
523  void cmdIn_handlerBase(
524  FwIndexType portNum,
525  FwOpcodeType opCode,
526  U32 cmdSeq,
527  Fw::CmdArgBuffer& args
528  );
529 
530  protected:
531 
532  // ----------------------------------------------------------------------
533  // Handlers to implement for typed input ports
534  // ----------------------------------------------------------------------
535 
537  virtual void pingIn_handler(
538  FwIndexType portNum,
539  U32 key
540  ) = 0;
541 
543  virtual void schedIn_handler(
544  FwIndexType portNum,
545  U32 context
546  ) = 0;
547 
548 #if FW_DIRECT_PORT_CALLS
549  public:
550 #else
551  protected:
552 #endif
553 
554  // ----------------------------------------------------------------------
555  // Port handler base-class functions for typed input ports
556  //
557  // Call these functions directly to bypass the corresponding ports
558  // ----------------------------------------------------------------------
559 
561  void pingIn_handlerBase(
562  FwIndexType portNum,
563  U32 key
564  );
565 
567  void schedIn_handlerBase(
568  FwIndexType portNum,
569  U32 context
570  );
571 
572  protected:
573 
574  // ----------------------------------------------------------------------
575  // Pre-message hooks for typed async input ports
576  //
577  // Each of these functions is invoked just before processing a message
578  // on the corresponding port. By default, they do nothing. You can
579  // override them to provide specific pre-message behavior.
580  // ----------------------------------------------------------------------
581 
583  virtual void pingIn_preMsgHook(
584  FwIndexType portNum,
585  U32 key
586  );
587 
588  protected:
589 
590  // ----------------------------------------------------------------------
591  // Invocation functions for typed output ports
592  // ----------------------------------------------------------------------
593 
595  void pingOut_out(
596  FwIndexType portNum,
597  U32 key
598  ) const;
599 
600  protected:
601 
602  // ----------------------------------------------------------------------
603  // Internal interface handlers
604  // ----------------------------------------------------------------------
605 
607  virtual void run_internalInterfaceHandler() = 0;
608 
609  protected:
610 
611  // ----------------------------------------------------------------------
612  // Internal interface base-class functions
613  // ----------------------------------------------------------------------
614 
617 
618  protected:
619 
620  // ----------------------------------------------------------------------
621  // Command response
622  // ----------------------------------------------------------------------
623 
625  void cmdResponse_out(
626  FwOpcodeType opCode,
627  U32 cmdSeq,
628  Fw::CmdResponse response
629  );
630 
631  protected:
632 
633  // ----------------------------------------------------------------------
634  // Command handlers to implement
635  // ----------------------------------------------------------------------
636 
640  virtual void CreateDirectory_cmdHandler(
641  FwOpcodeType opCode,
642  U32 cmdSeq,
643  const Fw::CmdStringArg& dirName
644  ) = 0;
645 
649  virtual void MoveFile_cmdHandler(
650  FwOpcodeType opCode,
651  U32 cmdSeq,
652  const Fw::CmdStringArg& sourceFileName,
653  const Fw::CmdStringArg& destFileName
654  ) = 0;
655 
659  virtual void RemoveDirectory_cmdHandler(
660  FwOpcodeType opCode,
661  U32 cmdSeq,
662  const Fw::CmdStringArg& dirName
663  ) = 0;
664 
668  virtual void RemoveFile_cmdHandler(
669  FwOpcodeType opCode,
670  U32 cmdSeq,
671  const Fw::CmdStringArg& fileName,
672  bool ignoreErrors
673  ) = 0;
674 
678  virtual void AppendFile_cmdHandler(
679  FwOpcodeType opCode,
680  U32 cmdSeq,
681  const Fw::CmdStringArg& source,
682  const Fw::CmdStringArg& target
683  ) = 0;
684 
688  virtual void FileSize_cmdHandler(
689  FwOpcodeType opCode,
690  U32 cmdSeq,
691  const Fw::CmdStringArg& fileName
692  ) = 0;
693 
697  virtual void ListDirectory_cmdHandler(
698  FwOpcodeType opCode,
699  U32 cmdSeq,
700  const Fw::CmdStringArg& dirName
701  ) = 0;
702 
706  virtual void CalculateCrc_cmdHandler(
707  FwOpcodeType opCode,
708  U32 cmdSeq,
709  const Fw::CmdStringArg& filename
710  ) = 0;
711 
712  protected:
713 
714  // ----------------------------------------------------------------------
715  // Command handler base-class functions
716  //
717  // Call these functions directly to bypass the command input port
718  // ----------------------------------------------------------------------
719 
724  FwOpcodeType opCode,
725  U32 cmdSeq,
726  Fw::CmdArgBuffer& args
727  );
728 
733  FwOpcodeType opCode,
734  U32 cmdSeq,
735  Fw::CmdArgBuffer& args
736  );
737 
742  FwOpcodeType opCode,
743  U32 cmdSeq,
744  Fw::CmdArgBuffer& args
745  );
746 
751  FwOpcodeType opCode,
752  U32 cmdSeq,
753  Fw::CmdArgBuffer& args
754  );
755 
760  FwOpcodeType opCode,
761  U32 cmdSeq,
762  Fw::CmdArgBuffer& args
763  );
764 
769  FwOpcodeType opCode,
770  U32 cmdSeq,
771  Fw::CmdArgBuffer& args
772  );
773 
778  FwOpcodeType opCode,
779  U32 cmdSeq,
780  Fw::CmdArgBuffer& args
781  );
782 
787  FwOpcodeType opCode,
788  U32 cmdSeq,
789  Fw::CmdArgBuffer& args
790  );
791 
792  protected:
793 
794  // ----------------------------------------------------------------------
795  // Pre-message hooks for async commands
796  //
797  // Each of these functions is invoked just before processing the
798  // corresponding command. By default they do nothing. You can
799  // override them to provide specific pre-command behavior.
800  // ----------------------------------------------------------------------
801 
803  virtual void CreateDirectory_preMsgHook(
804  FwOpcodeType opCode,
805  U32 cmdSeq
806  );
807 
809  virtual void MoveFile_preMsgHook(
810  FwOpcodeType opCode,
811  U32 cmdSeq
812  );
813 
815  virtual void RemoveDirectory_preMsgHook(
816  FwOpcodeType opCode,
817  U32 cmdSeq
818  );
819 
821  virtual void RemoveFile_preMsgHook(
822  FwOpcodeType opCode,
823  U32 cmdSeq
824  );
825 
827  virtual void AppendFile_preMsgHook(
828  FwOpcodeType opCode,
829  U32 cmdSeq
830  );
831 
833  virtual void FileSize_preMsgHook(
834  FwOpcodeType opCode,
835  U32 cmdSeq
836  );
837 
839  virtual void ListDirectory_preMsgHook(
840  FwOpcodeType opCode,
841  U32 cmdSeq
842  );
843 
845  virtual void CalculateCrc_preMsgHook(
846  FwOpcodeType opCode,
847  U32 cmdSeq
848  );
849 
850  protected:
851 
852  // ----------------------------------------------------------------------
853  // Event logging functions
854  // ----------------------------------------------------------------------
855 
860  const Fw::StringBase& dirName,
861  U32 status
862  ) const;
863 
868  const Fw::StringBase& dirName,
869  U32 status
870  ) const;
871 
876  const Fw::StringBase& sourceFileName,
877  const Fw::StringBase& destFileName,
878  U32 status
879  ) const;
880 
885  const Fw::StringBase& fileName,
886  U32 status
887  ) const;
888 
893  const Fw::StringBase& source,
894  const Fw::StringBase& target,
895  U32 status
896  ) const;
897 
902  const Fw::StringBase& source,
903  const Fw::StringBase& target
904  ) const;
905 
910  const Fw::StringBase& dirName
911  ) const;
912 
917  const Fw::StringBase& dirName
918  ) const;
919 
924  const Fw::StringBase& sourceFileName,
925  const Fw::StringBase& destFileName
926  ) const;
927 
932  const Fw::StringBase& fileName
933  ) const;
934 
939  const Fw::StringBase& source,
940  const Fw::StringBase& target
941  ) const;
942 
947  const Fw::StringBase& dirName
948  ) const;
949 
954  const Fw::StringBase& dirName
955  ) const;
956 
961  const Fw::StringBase& sourceFileName,
962  const Fw::StringBase& destFileName
963  ) const;
964 
969  const Fw::StringBase& fileName
970  ) const;
971 
976  const Fw::StringBase& fileName,
977  FwSizeType size
978  ) const;
979 
984  const Fw::StringBase& fileName,
985  U32 status
986  ) const;
987 
992  const Fw::StringBase& fileName
993  ) const;
994 
999  const Fw::StringBase& dirName
1000  ) const;
1001 
1006  const Fw::StringBase& dirName,
1007  U32 fileCount
1008  ) const;
1009 
1014  const Fw::StringBase& dirName,
1015  U32 status
1016  ) const;
1017 
1022  const Fw::StringBase& dirName,
1023  const Fw::StringBase& fileName,
1024  FwSizeType fileSize
1025  ) const;
1026 
1031  const Fw::StringBase& dirName,
1032  const Fw::StringBase& subdirName
1033  ) const;
1034 
1039  const Fw::StringBase& fileName
1040  ) const;
1041 
1046  const Fw::StringBase& fileName,
1047  U32 status
1048  ) const;
1049 
1054  const Fw::StringBase& fileName,
1055  U32 crc
1056  ) const;
1057 
1062  const Fw::StringBase& fileName,
1063  const Fw::StringFormatStatus& status
1064  ) const;
1065 
1066  protected:
1067 
1068  // ----------------------------------------------------------------------
1069  // Telemetry serialized write
1070  // ----------------------------------------------------------------------
1071 
1076  void tlmWrite(
1077  FwChanIdType id,
1078  Fw::TlmBuffer& _tlmBuff,
1079  Fw::Time _tlmTime = Fw::Time()
1080  ) const;
1081 
1082  protected:
1083 
1084  // ----------------------------------------------------------------------
1085  // Telemetry write functions
1086  // ----------------------------------------------------------------------
1087 
1092  U32 arg,
1093  Fw::Time _tlmTime = Fw::Time()
1094  ) const;
1095 
1099  void tlmWrite_Errors(
1100  U32 arg,
1101  Fw::Time _tlmTime = Fw::Time()
1102  ) const;
1103 
1104  protected:
1105 
1106  // ----------------------------------------------------------------------
1107  // Time
1108  // ----------------------------------------------------------------------
1109 
1113  Fw::Time getTime() const;
1114 
1115  private:
1116 
1117  // ----------------------------------------------------------------------
1118  // Message dispatch functions
1119  // ----------------------------------------------------------------------
1120 
1122  virtual MsgDispatchStatus doDispatch();
1123 
1124  private:
1125 
1126  // ----------------------------------------------------------------------
1127  // Calls for messages received on special input ports
1128  // ----------------------------------------------------------------------
1129 
1131  static void m_p_cmdIn_in(
1132  Fw::PassiveComponentBase* callComp,
1133  FwIndexType portNum,
1134  FwOpcodeType opCode,
1135  U32 cmdSeq,
1136  Fw::CmdArgBuffer& args
1137  );
1138 
1139  private:
1140 
1141  // ----------------------------------------------------------------------
1142  // Calls for messages received on typed input ports
1143  // ----------------------------------------------------------------------
1144 
1146  static void m_p_pingIn_in(
1147  Fw::PassiveComponentBase* callComp,
1148  FwIndexType portNum,
1149  U32 key
1150  );
1151 
1153  static void m_p_schedIn_in(
1154  Fw::PassiveComponentBase* callComp,
1155  FwIndexType portNum,
1156  U32 context
1157  );
1158 
1159  private:
1160 
1161  // ----------------------------------------------------------------------
1162  // Invocation functions for special output ports
1163  // ----------------------------------------------------------------------
1164 
1165 #if FW_ENABLE_TEXT_LOGGING
1166 
1168  void LogText_out(
1169  FwIndexType portNum,
1170  FwEventIdType id,
1171  Fw::Time& timeTag,
1172  const Fw::LogSeverity& severity,
1173  Fw::TextLogString& text
1174  ) const;
1175 
1176 #endif
1177 
1179  void cmdRegOut_out(
1180  FwIndexType portNum,
1181  FwOpcodeType opCode
1182  ) const;
1183 
1185  void cmdResponseOut_out(
1186  FwIndexType portNum,
1187  FwOpcodeType opCode,
1188  U32 cmdSeq,
1189  const Fw::CmdResponse& response
1190  ) const;
1191 
1193  void eventOut_out(
1194  FwIndexType portNum,
1195  FwEventIdType id,
1196  Fw::Time& timeTag,
1197  const Fw::LogSeverity& severity,
1198  Fw::LogBuffer& args
1199  ) const;
1200 
1202  void timeCaller_out(
1203  FwIndexType portNum,
1204  Fw::Time& time
1205  ) const;
1206 
1208  void tlmOut_out(
1209  FwIndexType portNum,
1210  FwChanIdType id,
1211  Fw::Time& timeTag,
1212  Fw::TlmBuffer& val
1213  ) const;
1214 
1215 #if !FW_DIRECT_PORT_CALLS
1216 
1217  private:
1218 
1219  // ----------------------------------------------------------------------
1220  // Special input ports
1221  // ----------------------------------------------------------------------
1222 
1224  Fw::InputCmdPort m_cmdIn_InputPort[NUM_CMDIN_INPUT_PORTS];
1225 
1226 #endif
1227 
1228 #if !FW_DIRECT_PORT_CALLS
1229 
1230  private:
1231 
1232  // ----------------------------------------------------------------------
1233  // Typed input ports
1234  // ----------------------------------------------------------------------
1235 
1237  Svc::InputPingPort m_pingIn_InputPort[NUM_PINGIN_INPUT_PORTS];
1238 
1240  Svc::InputSchedPort m_schedIn_InputPort[NUM_SCHEDIN_INPUT_PORTS];
1241 
1242 #endif
1243 
1244 #if !FW_DIRECT_PORT_CALLS
1245 
1246  private:
1247 
1248  // ----------------------------------------------------------------------
1249  // Special output ports
1250  // ----------------------------------------------------------------------
1251 
1252 #if FW_ENABLE_TEXT_LOGGING == 1
1253 
1255  Fw::OutputLogTextPort m_LogText_OutputPort[NUM_LOGTEXT_OUTPUT_PORTS];
1256 
1257 #endif
1258 
1260  Fw::OutputCmdRegPort m_cmdRegOut_OutputPort[NUM_CMDREGOUT_OUTPUT_PORTS];
1261 
1263  Fw::OutputCmdResponsePort m_cmdResponseOut_OutputPort[NUM_CMDRESPONSEOUT_OUTPUT_PORTS];
1264 
1266  Fw::OutputLogPort m_eventOut_OutputPort[NUM_EVENTOUT_OUTPUT_PORTS];
1267 
1269  Fw::OutputTimePort m_timeCaller_OutputPort[NUM_TIMECALLER_OUTPUT_PORTS];
1270 
1272  Fw::OutputTlmPort m_tlmOut_OutputPort[NUM_TLMOUT_OUTPUT_PORTS];
1273 
1274 #endif
1275 
1276 #if !FW_DIRECT_PORT_CALLS
1277 
1278  private:
1279 
1280  // ----------------------------------------------------------------------
1281  // Typed output ports
1282  // ----------------------------------------------------------------------
1283 
1285  Svc::OutputPingPort m_pingOut_OutputPort[NUM_PINGOUT_OUTPUT_PORTS];
1286 
1287 #endif
1288 
1289  };
1290 
1291 }
1292 
1293 #endif
void set_eventOut_OutputPort(FwIndexType portNum, Fw::InputLogPort *port)
Connect port to eventOut[portNum].
virtual void run_internalInterfaceHandler()=0
Internal interface handler for run.
An error occurred while attempting to remove a directory.
void log_WARNING_HI_ListDirectoryError(const Fw::StringBase &dirName, U32 status) const
The File System component moved a file to a new location without error.
void AppendFile_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
void log_ACTIVITY_HI_DirectoryListingSubdir(const Fw::StringBase &dirName, const Fw::StringBase &subdirName) const
void log_ACTIVITY_HI_CreateDirectoryStarted(const Fw::StringBase &dirName) const
FwIdType FwOpcodeType
The type of a command opcode.
An error occurred while attempting to create a directory.
virtual void ListDirectory_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command ListDirectory.
void log_ACTIVITY_HI_RemoveDirectorySucceeded(const Fw::StringBase &dirName) const
void log_ACTIVITY_HI_DirectoryListing(const Fw::StringBase &dirName, const Fw::StringBase &fileName, FwSizeType fileSize) const
virtual void MoveFile_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdStringArg &sourceFileName, const Fw::CmdStringArg &destFileName)=0
PlatformSizeType FwSizeType
virtual void MoveFile_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command MoveFile.
void log_ACTIVITY_HI_CalculateCrcStarted(const Fw::StringBase &fileName) const
I32 FwEnumStoreType
virtual void CalculateCrc_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdStringArg &filename)=0
void log_WARNING_HI_FileSizeError(const Fw::StringBase &fileName, U32 status) const
void run_internalInterfaceInvoke()
Internal interface base-class function for run.
The File System component began moving a file to a new location.
static constexpr FwIndexType getNum_tlmOut_OutputPorts()
virtual void pingIn_handler(FwIndexType portNum, U32 key)=0
Handler for input port pingIn.
void FileSize_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
The File System component began deleting a directory.
An error occurred while attempting to remove a file.
void log_ACTIVITY_HI_FileSizeSucceeded(const Fw::StringBase &fileName, FwSizeType size) const
virtual void RemoveFile_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdStringArg &fileName, bool ignoreErrors)=0
void log_ACTIVITY_HI_ListDirectorySucceeded(const Fw::StringBase &dirName, U32 fileCount) const
void cmdIn_handlerBase(FwIndexType portNum, FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
Handler base-class function for input port cmdIn.
Auto-generated base for FileManager component.
static constexpr FwIndexType getNum_timeCaller_OutputPorts()
void log_ACTIVITY_HI_CalculateCrcSucceeded(const Fw::StringBase &fileName, U32 crc) const
The File System component created a new directory without error.
void CalculateCrc_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
An error occurred while attempting to move a file.
void log_ACTIVITY_HI_ListDirectoryStarted(const Fw::StringBase &dirName) const
bool isConnected_tlmOut_OutputPort(FwIndexType portNum) const
static constexpr FwIndexType getNum_pingOut_OutputPorts()
Enum representing a command response.
virtual void RemoveFile_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command RemoveFile.
virtual void schedIn_handler(FwIndexType portNum, U32 context)=0
Handler for input port schedIn.
void log_ACTIVITY_HI_MoveFileStarted(const Fw::StringBase &sourceFileName, const Fw::StringBase &destFileName) const
FPP shadow-enum representing Fw::FormatStatus.
bool isConnected_pingOut_OutputPort(FwIndexType portNum) const
static constexpr FwIndexType getNum_eventOut_OutputPorts()
Svc::InputPingPort * get_pingIn_InputPort(FwIndexType portNum)
void pingOut_out(FwIndexType portNum, U32 key) const
Invoke output port pingOut.
void log_ACTIVITY_HI_AppendFileSucceeded(const Fw::StringBase &source, const Fw::StringBase &target) const
FileManagerComponentBase(const char *compName="")
Construct FileManagerComponentBase object.
void ListDirectory_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
The File System component began deleting an existing file.
void init()
Object initializer.
Definition: ObjBase.cpp:24
The File System component began creating a new directory.
void log_ACTIVITY_HI_CreateDirectorySucceeded(const Fw::StringBase &dirName) const
void set_cmdResponseOut_OutputPort(FwIndexType portNum, Fw::InputCmdResponsePort *port)
Connect port to cmdResponseOut[portNum].
FwIdType FwEventIdType
The type of an event identifier.
void set_pingOut_OutputPort(FwIndexType portNum, Svc::InputPingPort *port)
Connect port to pingOut[portNum].
bool isConnected_cmdResponseOut_OutputPort(FwIndexType portNum) const
The File System component deleted an existing file without error.
virtual void CreateDirectory_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdStringArg &dirName)=0
virtual void ListDirectory_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdStringArg &dirName)=0
void RemoveFile_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
friend class FileManagerTester
Friend class tester implementation to support white-box testing.
The File System component deleted and existing directory without error.
void log_ACTIVITY_HI_RemoveDirectoryStarted(const Fw::StringBase &dirName) const
Fw::InputCmdPort * get_cmdIn_InputPort(FwIndexType portNum)
void RemoveDirectory_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
static constexpr FwIndexType getNum_schedIn_InputPorts()
virtual void FileSize_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command FileSize.
FwIdType FwChanIdType
The type of a telemetry channel identifier.
virtual void CreateDirectory_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command CreateDirectory.
Svc::InputSchedPort * get_schedIn_InputPort(FwIndexType portNum)
void cmdResponse_out(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdResponse response)
Emit command response.
bool isConnected_timeCaller_OutputPort(FwIndexType portNum) const
void log_ACTIVITY_HI_FileSizeStarted(const Fw::StringBase &fileName) const
void log_WARNING_HI_FileNameFormatError(const Fw::StringBase &fileName, const Fw::StringFormatStatus &status) const
Enum representing event severity.
virtual ~FileManagerComponentBase()
Destroy FileManagerComponentBase object.
void tlmWrite(FwChanIdType id, Fw::TlmBuffer &_tlmBuff, Fw::Time _tlmTime=Fw::Time()) const
static constexpr FwIndexType getNum_cmdResponseOut_OutputPorts()
void MoveFile_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
The File System component appended 2 files without error.
The File System component returned status non-zero when trying to append 2 files together.
void schedIn_handlerBase(FwIndexType portNum, U32 context)
Handler base-class function for input port schedIn.
virtual void FileSize_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdStringArg &fileName)=0
void log_ACTIVITY_HI_MoveFileSucceeded(const Fw::StringBase &sourceFileName, const Fw::StringBase &destFileName) const
void log_WARNING_HI_DirectoryRemoveError(const Fw::StringBase &dirName, U32 status) const
void pingIn_handlerBase(FwIndexType portNum, U32 key)
Handler base-class function for input port pingIn.
void log_ACTIVITY_HI_AppendFileStarted(const Fw::StringBase &source, const Fw::StringBase &target) const
bool isConnected_eventOut_OutputPort(FwIndexType portNum) const
void tlmWrite_Errors(U32 arg, Fw::Time _tlmTime=Fw::Time()) const
void log_ACTIVITY_HI_RemoveFileStarted(const Fw::StringBase &fileName) const
void set_tlmOut_OutputPort(FwIndexType portNum, Fw::InputTlmPort *port)
Connect port to tlmOut[portNum].
void set_cmdRegOut_OutputPort(FwIndexType portNum, Fw::InputCmdRegPort *port)
Connect port to cmdRegOut[portNum].
bool isConnected_cmdRegOut_OutputPort(FwIndexType portNum) const
PlatformIndexType FwIndexType
void set_timeCaller_OutputPort(FwIndexType portNum, Fw::InputTimePort *port)
Connect port to timeCaller[portNum].
static constexpr FwIndexType getNum_pingIn_InputPorts()
void log_WARNING_HI_AppendFileFailed(const Fw::StringBase &source, const Fw::StringBase &target, U32 status) const
void regCommands()
Register commands with the Command Dispatcher.
static constexpr FwIndexType getNum_cmdIn_InputPorts()
RateGroupDivider component implementation.
virtual void pingIn_preMsgHook(FwIndexType portNum, U32 key)
Pre-message hook for async input port pingIn.
void log_WARNING_HI_CalculateCrcFailed(const Fw::StringBase &fileName, U32 status) const
virtual void AppendFile_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command AppendFile.
virtual void RemoveDirectory_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command RemoveDirectory.
The File System component appended 2 files without error.
void log_WARNING_HI_DirectoryCreateError(const Fw::StringBase &dirName, U32 status) const
Append 1 file&#39;s contents to the end of another.
void log_ACTIVITY_HI_RemoveFileSucceeded(const Fw::StringBase &fileName) const
void log_WARNING_HI_FileMoveError(const Fw::StringBase &sourceFileName, const Fw::StringBase &destFileName, U32 status) const
void tlmWrite_CommandsExecuted(U32 arg, Fw::Time _tlmTime=Fw::Time()) const
void CreateDirectory_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
virtual void RemoveDirectory_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdStringArg &dirName)=0
void log_WARNING_HI_FileRemoveError(const Fw::StringBase &fileName, U32 status) const
friend class FileManagerTesterBase
Friend class tester to support autocoded test harness.
virtual void CalculateCrc_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command CalculateCrc.
static constexpr FwIndexType getNum_cmdRegOut_OutputPorts()
virtual void AppendFile_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdStringArg &source, const Fw::CmdStringArg &target)=0