rpm  5.2.1
fsm.h
Go to the documentation of this file.
1 #ifndef H_FSM
2 #define H_FSM
3 
9 #include <iosm.h>
10 
14 typedef /*@abstract@*/ struct iosm_s * FSM_t;
15 
16 /*@-exportlocal@*/
17 /*@unchecked@*/
18 extern int _fsm_debug;
19 /*@=exportlocal@*/
20 
24 typedef /*@abstract@*/ struct iosmIterator_s * FSMI_t;
25 
26 #ifdef __cplusplus
27 extern "C" {
28 #endif
29 
34 /*@only@*/ IOSM_t newFSM(void)
35  /*@*/;
36 
42 /*@null@*/ IOSM_t freeFSM(/*@only@*/ /*@null@*/ IOSM_t fsm)
43  /*@globals fileSystem @*/
44  /*@modifies fsm, fileSystem @*/;
45 
58 int fsmSetup(void * _fsm, iosmFileStage goal, /*@null@*/ const char * afmt,
59  const void * _ts,
60  const void * _fi,
61  FD_t cfd,
62  /*@out@*/ unsigned int * archiveSize,
63  /*@out@*/ const char ** failedFile)
64  /*@globals h_errno, fileSystem, internalState @*/
65  /*@modifies cfd, *archiveSize, *failedFile,
66  fileSystem, internalState @*/;
67 
73 int fsmTeardown(void * _fsm)
74  /*@globals h_errno, fileSystem, internalState @*/
75  /*@modifies _fsm, fileSystem, internalState @*/;
76 
81 int fsmMapPath(IOSM_t fsm)
82  /*@modifies fsm @*/;
83 
88 int fsmMapAttrs(IOSM_t fsm)
89  /*@modifies fsm @*/;
90 /*@=exportlocal@*/
91 
98 int fsmNext(IOSM_t fsm, iosmFileStage nstage)
99  /*@globals errno, h_errno, fileSystem, internalState @*/
100  /*@modifies fsm, errno, fileSystem, internalState @*/;
101 
108 /*@-exportlocal@*/
109 int fsmStage(/*@partial@*/ IOSM_t fsm, iosmFileStage stage)
110  /*@globals errno, h_errno, fileSystem, internalState @*/
111  /*@modifies fsm, errno, fileSystem, internalState @*/;
112 /*@=exportlocal@*/
113 
114 #ifdef __cplusplus
115 }
116 #endif
117 
118 #endif /* H_FSM */