SolidModules
network.cpp
Go to the documentation of this file.00001 /* This file is part of kdebase/workspace/solid 00002 Copyright (C) 2005,2007 Will Stephenson <wstephenson@kde.org> 00003 00004 This library is free software; you can redistribute it and/or 00005 modify it under the terms of the GNU Library General Public 00006 License version 2 as published by the Free Software Foundation. 00007 00008 This library is distributed in the hope that it will be useful, 00009 but WITHOUT ANY WARRANTY; without even the implied warranty of 00010 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00011 Library General Public License for more details. 00012 00013 You should have received a copy of the GNU Library General Public License 00014 along with this library. If not, write to the Free Software 00015 Foundation, Inc., 51 Franklin Street, Fifth Floor, 00016 Boston, MA 02110-1301, USA. 00017 00018 As a special exception, permission is given to link this library 00019 with any edition of Qt, and distribute the resulting executable, 00020 without including the source code for Qt in the source distribution. 00021 */ 00022 00023 #include "network.h" 00024 00025 #include <KDebug> 00026 00027 Network::Network( const QString & name, int status, const QString & serviceName ) 00028 : m_name( name ), m_status( (Solid::Networking::Status)status ), m_service( serviceName ) 00029 { 00030 } 00031 00032 void Network::setStatus( Solid::Networking::Status status ) 00033 { 00034 m_status = status; 00035 } 00036 00037 Solid::Networking::Status Network::status() const 00038 { 00039 return m_status; 00040 } 00041 00042 void Network::setName( const QString& name ) 00043 { 00044 m_name = name; 00045 } 00046 00047 QString Network::name() const 00048 { 00049 return m_name; 00050 } 00051 00052 QString Network::service() const 00053 { 00054 return m_service; 00055 } 00056 00057 void Network::setService( const QString& service ) 00058 { 00059 m_service = service; 00060 } 00061 00062 // vim: sw=4 ts=4