yast2-sound
YastChannelId.h
Go to the documentation of this file.
1 /* ------------------------------------------------------------------------------
2  * Copyright (c) 2009 Novell, Inc. All Rights Reserved.
3  *
4  *
5  * This program is free software; you can redistribute it and/or modify it under
6  * the terms of version 2 of the GNU General Public License as published by the
7  * Free Software Foundation.
8  *
9  * This program is distributed in the hope that it will be useful, but WITHOUT
10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11  * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
12  *
13  * You should have received a copy of the GNU General Public License along with
14  * this program; if not, contact Novell, Inc.
15  *
16  * To contact Novell about this file by physical or electronic mail, you may find
17  * current contact information at www.novell.com.
18  * ------------------------------------------------------------------------------
19  */
20 
21 /*
22  Author: Ladislav Slezák <lslezak@novell.com>
23  Summary: Class for converting Alsa channel name to Yast channel ID and vice versea.
24 */
25 
26 #include <string>
27 
29 {
30  public:
31 
33  YastChannelId(const char* alsa_name, unsigned alsa_index) : channel_name(alsa_name), channel_index(alsa_index) {}
34  YastChannelId(const std::string &YastID);
35 
36  std::string name() {return channel_name;}
37  unsigned index() {return channel_index;}
38 
39  std::string asString();
40 
41  private:
42 
43  std::string channel_name;
44  unsigned channel_index;
45 };
46 
std::string name()
Definition: YastChannelId.h:36
YastChannelId()
Definition: YastChannelId.h:32
std::string asString()
Definition: YastChannelId.cc:122
std::string channel_name
Definition: YastChannelId.h:43
unsigned channel_index
Definition: YastChannelId.h:44
YastChannelId(const char *alsa_name, unsigned alsa_index)
Definition: YastChannelId.h:33
unsigned index()
Definition: YastChannelId.h:37
Definition: YastChannelId.h:28

Generated on a sunny day for yast2-sound by doxygen 1.8.6