1 |
iliev |
787 |
/* |
2 |
|
|
* JSampler - a java front-end for LinuxSampler |
3 |
|
|
* |
4 |
iliev |
2288 |
* Copyright (C) 2005-2011 Grigor Iliev <grigor@grigoriliev.com> |
5 |
iliev |
787 |
* |
6 |
|
|
* This file is part of JSampler. |
7 |
|
|
* |
8 |
|
|
* JSampler is free software; you can redistribute it and/or modify |
9 |
|
|
* it under the terms of the GNU General Public License version 2 |
10 |
|
|
* as published by the Free Software Foundation. |
11 |
|
|
* |
12 |
|
|
* JSampler is distributed in the hope that it will be useful, |
13 |
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
14 |
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
15 |
|
|
* GNU General Public License for more details. |
16 |
|
|
* |
17 |
|
|
* You should have received a copy of the GNU General Public License |
18 |
|
|
* along with JSampler; if not, write to the Free Software |
19 |
|
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, |
20 |
|
|
* MA 02111-1307 USA |
21 |
|
|
*/ |
22 |
|
|
|
23 |
|
|
package org.jsampler.view; |
24 |
|
|
|
25 |
|
|
import org.jsampler.SamplerChannelModel; |
26 |
|
|
import org.linuxsampler.lscp.SamplerChannel; |
27 |
|
|
|
28 |
|
|
|
29 |
|
|
/** |
30 |
iliev |
911 |
* This class defines the skeleton of a sampler channel. |
31 |
iliev |
787 |
* @author Grigor Iliev |
32 |
|
|
*/ |
33 |
iliev |
2288 |
public interface JSChannel { |
34 |
iliev |
787 |
/** |
35 |
|
|
* Gets the model that is currently used by this channel. |
36 |
|
|
* @return model The <code>SamplerChannelModel</code> instance |
37 |
|
|
* which provides information about this channel. |
38 |
|
|
*/ |
39 |
iliev |
2288 |
public SamplerChannelModel getModel(); |
40 |
iliev |
787 |
|
41 |
|
|
/** |
42 |
|
|
* Gets the numerical ID of this sampler channel. |
43 |
|
|
* @return The numerical ID of this sampler channel or -1 if the channel's ID is not set. |
44 |
|
|
*/ |
45 |
iliev |
2288 |
public int getChannelId(); |
46 |
iliev |
787 |
|
47 |
|
|
/** |
48 |
|
|
* Gets the current settings of this sampler channel. |
49 |
|
|
* @return <code>SamplerChannel</code> instance containing |
50 |
|
|
* the current settings of this sampler channel. |
51 |
|
|
*/ |
52 |
iliev |
2288 |
public SamplerChannel getChannelInfo(); |
53 |
iliev |
787 |
|
54 |
|
|
/** |
55 |
|
|
* Determines whether the channel is selected. |
56 |
|
|
* @return <code>true</code> if the channel is selected, <code>false</code> otherwise. |
57 |
|
|
*/ |
58 |
iliev |
2288 |
public boolean isSelected(); |
59 |
iliev |
787 |
|
60 |
|
|
/** |
61 |
|
|
* Sets the selection state of this channel. |
62 |
|
|
* This method is invoked when the selection state of the channel has changed. |
63 |
|
|
* @param select Specifies the new selection state of this channel; |
64 |
|
|
* <code>true</code> to select the channel, <code>false</code> otherwise. |
65 |
|
|
*/ |
66 |
iliev |
2288 |
public void setSelected(boolean select); |
67 |
iliev |
787 |
} |