PageRenderTime 5ms CodeModel.GetById 1ms app.highlight 2ms RepoModel.GetById 1ms app.codeStats 0ms

/protocols/jain-megaco/megaco-api/src/main/java/javax/megaco/pkg/AnalogLineSPkg/AnalogLineSParamCad.java

http://mobicents.googlecode.com/
Java | 99 lines | 31 code | 13 blank | 55 comment | 0 complexity | f2dc6f300540f6b12627aaf8b374e8cc MD5 | raw file
 1package javax.megaco.pkg.AnalogLineSPkg;
 2
 3import javax.megaco.message.DescriptorType;
 4import javax.megaco.pkg.ParamValueType;
 5import javax.megaco.pkg.PkgConsts;
 6import javax.megaco.pkg.PkgItemParam;
 7
 8/**
 9 * The MEGACO parameter class for the Cadence Parameter is associated with Ring
10 * signal of Analog Line Supervision Package. This class defines all the static
11 * information for this parameter.
12 */
13public class AnalogLineSParamCad extends PkgItemParam {
14
15	/**
16	 *Identifies Cadence parameter of the MEGACO Analog Line Supervision
17	 * Package. Its value shall be set equal to 0x0006.
18	 */
19	public static final int ANALOG_LINE_PARAM_CAD = 0x0006;
20
21	protected int[] paramsItemIds = null;
22
23	/**
24	 * Constructs a parameter class for Analog Line Supervision package that
25	 * specifies the parameter as Cadence.
26	 */
27	public AnalogLineSParamCad() {
28		super();
29		super.paramId = ANALOG_LINE_PARAM_CAD;
30		super.itemValueType = ParamValueType.M_INTEGER;
31		super.paramsDescriptorIds = new int[] { DescriptorType.M_SIGNAL_DESC };
32
33		// FIXME: ANALOG_LINE_RING_SIGNAL ??
34		this.paramsItemIds = new int[] {};
35	}
36
37	/**
38	 * The method can be used to get the parameter identifier as defined in the
39	 * MEGACO packages. The implementation of this method in this class returns
40	 * Id of Cadence parameter.
41	 * 
42	 * @return paramId - Returns param id as {@link ANALOG_LINE_PARAM_CAD}.
43	 */
44	public int getParamId() {
45
46		return super.paramId;
47	}
48
49	/**
50	 * The method can be used to get the type of the parameter as defined in the
51	 * MEGACO packages. These could be one of string or enumerated value or
52	 * integer or double value or boolean.
53	 * 
54	 * @return It returns {@link ParamValueType.M_INTEGER}
55	 *         indicating that the parameter is a string.
56	 */
57	public int getParamValueType() {
58
59		return super.itemValueType;
60	}
61
62	/**
63	 * The method can be used to get the item ids corresponding to the
64	 * parameters to which the parameter can be set. This method specifies the
65	 * valid item (event/signal) ids to which the parameter can belong to.
66	 * 
67	 * @return The integer value corresponding to Ring. Thus this shall return
68	 *         {@link ANALOG_LINE_RING_SIGNAL}.
69	 */
70	public int[] getParamsItemIds() {
71		return this.paramsItemIds;
72	}
73
74	/**
75	 * The method can be used to get the package id corresponding to the to
76	 * which the parameter can be set. This method specifies the package for
77	 * which the parameter is valid. Even though the parameter may be set for an
78	 * item, but the parameter may not be valid for package to which the item
79	 * belongs, but may be valid for a package which has extended this package.
80	 * 
81	 * @return This shall return {@link PkgConsts.ANALOG_LINE_PACKAGE} as the
82	 *         integer value. The integer values are defined in
83	 *         {@link PkgConsts}.
84	 */
85	public int getParamsPkgId() {
86		return PkgConsts.ANALOG_LINE_PACKAGE;
87	}
88
89	/**
90	 * The method can be used to get the descriptor ids corresponding to the
91	 * parameters to which the parameter can be set.
92	 * 
93	 * @return This parameter can be present in Event descriptor. It shall thus
94	 *         return a value {@link DescriptorType.M_SIGNAL_DESC}
95	 */
96	public int[] getParamsDescriptorIds() {
97		return super.paramsDescriptorIds;
98	}
99}