Diffstat (limited to 'noncore/settings/networksettings2/lancard/lancard_NN.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/settings/networksettings2/lancard/lancard_NN.cpp | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/noncore/settings/networksettings2/lancard/lancard_NN.cpp b/noncore/settings/networksettings2/lancard/lancard_NN.cpp index 05cd06d..20ae7f6 100644 --- a/noncore/settings/networksettings2/lancard/lancard_NN.cpp +++ b/noncore/settings/networksettings2/lancard/lancard_NN.cpp | |||
@@ -33,39 +33,16 @@ ANetNodeInstance * LanCardNetNode::createInstance( void ) { | |||
33 | const char ** LanCardNetNode::needs( void ) { | 33 | const char ** LanCardNetNode::needs( void ) { |
34 | return LanCardNeeds; | 34 | return LanCardNeeds; |
35 | } | 35 | } |
36 | 36 | ||
37 | const char * LanCardNetNode::provides( void ) { | 37 | const char * LanCardNetNode::provides( void ) { |
38 | return "device"; | 38 | return "device"; |
39 | } | 39 | } |
40 | 40 | ||
41 | bool LanCardNetNode::generateProperFilesFor( | ||
42 | ANetNodeInstance * ) { | ||
43 | return 0; | ||
44 | } | ||
45 | |||
46 | bool LanCardNetNode::hasDataFor( const QString & S ) { | ||
47 | return S == "interfaces"; | ||
48 | } | ||
49 | |||
50 | bool LanCardNetNode::generateDeviceDataForCommonFile( | ||
51 | SystemFile & S , | ||
52 | long DevNr ) { | ||
53 | QString NIC = genNic( DevNr ); | ||
54 | |||
55 | if( S.name() == "interfaces" ) { | ||
56 | // generate mapping stanza for this interface | ||
57 | S << "# check if " << NIC << " can be brought UP" << endl; | ||
58 | S << "mapping " << NIC << endl; | ||
59 | S << " script networksettings2-request" << endl << endl; | ||
60 | } | ||
61 | return 0; | ||
62 | } | ||
63 | |||
64 | QString LanCardNetNode::genNic( long nr ) { | 41 | QString LanCardNetNode::genNic( long nr ) { |
65 | QString S; | 42 | QString S; |
66 | return S.sprintf( "eth%ld", nr ); | 43 | return S.sprintf( "eth%ld", nr ); |
67 | } | 44 | } |
68 | 45 | ||
69 | void LanCardNetNode::setSpecificAttribute( QString & A, QString & V ) { | 46 | void LanCardNetNode::setSpecificAttribute( QString & A, QString & V ) { |
70 | if( A == "interfacecount" ) { | 47 | if( A == "interfacecount" ) { |
71 | InstanceCount = V.toLong(); | 48 | InstanceCount = V.toLong(); |