Diffstat (limited to 'noncore/settings/networksettings2/networksettings2/netnode.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/settings/networksettings2/networksettings2/netnode.h | 50 |
1 files changed, 34 insertions, 16 deletions
diff --git a/noncore/settings/networksettings2/networksettings2/netnode.h b/noncore/settings/networksettings2/networksettings2/netnode.h index f4a5e30..9681c6e 100644 --- a/noncore/settings/networksettings2/networksettings2/netnode.h +++ b/noncore/settings/networksettings2/networksettings2/netnode.h | |||
@@ -96,13 +96,9 @@ public: | |||
96 | // return TRUE if this node has data to be inserted in systemfile | 96 | // return TRUE if this node has data to be inserted in systemfile |
97 | // with name S | 97 | // with name S |
98 | virtual bool hasDataFor( const QString & S, bool DeviceSpecific ) = 0; | 98 | virtual bool hasDataFor( const QString & S ) = 0; |
99 | // generate data specific for a profile and for the system file S | ||
100 | // called only IF data was needed | ||
101 | virtual bool generateDataForCommonFile( | ||
102 | SystemFile & SF, long DevNr, ANetNodeInstance * NNI ) = 0; | ||
103 | // generate data specific for the device for the system file S | 99 | // generate data specific for the device for the system file S |
104 | // called only IF data was needed | 100 | // called only IF data was needed |
105 | virtual bool generateDeviceDataForCommonFile( | 101 | virtual bool generateDeviceDataForCommonFile( |
106 | SystemFile & SF, long DevNr, ANetNodeInstance * NNI ) = 0; | 102 | SystemFile & SF, long DevNr ) = 0; |
107 | 103 | ||
108 | // does this Node provide a Connection | 104 | // does this Node provide a Connection |
@@ -110,4 +106,14 @@ public: | |||
110 | { return strcmp( provides(), "fullsetup") == 0 ; } | 106 | { return strcmp( provides(), "fullsetup") == 0 ; } |
111 | 107 | ||
108 | // generate NIC name based on instance nr | ||
109 | // only relevant if node instances are devices | ||
110 | virtual QString genNic( long ) | ||
111 | { return QString(""); } | ||
112 | |||
113 | // max number of instances for this node type | ||
114 | // only relevant if node instances are devices | ||
115 | virtual long instanceCount( void ) | ||
116 | { return 1; } | ||
117 | |||
112 | // compiled references to 'needed' NetNodes -> needs list | 118 | // compiled references to 'needed' NetNodes -> needs list |
113 | void setAlternatives( NetNodeList * Alt ) | 119 | void setAlternatives( NetNodeList * Alt ) |
@@ -155,5 +161,5 @@ public: | |||
155 | ANetNodeInstance * nextNode(); | 161 | ANetNodeInstance * nextNode(); |
156 | // return NetNode this is an instance of | 162 | // return NetNode this is an instance of |
157 | ANetNode * netNode( void ) | 163 | ANetNode * nodeClass( void ) |
158 | { return NodeType; } | 164 | { return NodeType; } |
159 | 165 | ||
@@ -195,4 +201,13 @@ public: | |||
195 | virtual void * data( void ) = 0; | 201 | virtual void * data( void ) = 0; |
196 | 202 | ||
203 | // return TRUE if this node has data to be inserted in systemfile | ||
204 | // with name S | ||
205 | virtual bool hasDataFor( const QString & S ) = 0; | ||
206 | |||
207 | // generate data specific for a profile and for the system file S | ||
208 | // called only IF data was needed | ||
209 | virtual bool generateDataForCommonFile( | ||
210 | SystemFile & SF, long DevNr ) = 0; | ||
211 | |||
197 | protected : | 212 | protected : |
198 | 213 | ||
@@ -221,11 +236,11 @@ public : | |||
221 | 236 | ||
222 | // downcast implemented by specify runtime classes | 237 | // downcast implemented by specify runtime classes |
223 | AsDevice * asDevice( void ) | 238 | virtual AsDevice * asDevice( void ) |
224 | { return 0; } | 239 | { return 0; } |
225 | AsConnection * asConnection( void ) | 240 | virtual AsConnection * asConnection( void ) |
226 | { return 0; } | 241 | { return 0; } |
227 | AsLine * asLine( void ) | 242 | virtual AsLine * asLine( void ) |
228 | { return 0; } | 243 | { return 0; } |
229 | AsFullSetup * asFullSetup( void ) | 244 | virtual AsFullSetup * asFullSetup( void ) |
230 | { return 0; } | 245 | { return 0; } |
231 | 246 | ||
@@ -389,11 +404,8 @@ public: | |||
389 | virtual bool generateProperFilesFor( ANetNodeInstance * ) | 404 | virtual bool generateProperFilesFor( ANetNodeInstance * ) |
390 | { return 0; } | 405 | { return 0; } |
391 | virtual bool hasDataFor( const QString &, bool DS ) | 406 | virtual bool hasDataFor( const QString & ) |
392 | { return 0; } | 407 | { return 0; } |
393 | virtual bool generateDataForCommonFile( | ||
394 | SystemFile & , long , ANetNodeInstance * ) | ||
395 | {return 1; } | ||
396 | virtual bool generateDeviceDataForCommonFile( | 408 | virtual bool generateDeviceDataForCommonFile( |
397 | SystemFile & , long , ANetNodeInstance * ) | 409 | SystemFile & , long ) |
398 | {return 1; } | 410 | {return 1; } |
399 | 411 | ||
@@ -435,4 +447,10 @@ public: | |||
435 | { return 0; } | 447 | { return 0; } |
436 | 448 | ||
449 | virtual bool hasDataFor( const QString & ) | ||
450 | { return 0; } | ||
451 | |||
452 | virtual bool generateDataForCommonFile( SystemFile & , long ) | ||
453 | { return 1; } | ||
454 | |||
437 | protected : | 455 | protected : |
438 | 456 | ||