forked from powerdata/com.powerdata.openpa
-
Notifications
You must be signed in to change notification settings - Fork 0
/
TwoTermDev.java
78 lines (62 loc) · 1.52 KB
/
TwoTermDev.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
package com.powerdata.openpa;
import com.powerdata.openpa.TwoTermBaseList.TwoTermBase;
public class TwoTermDev extends OutOfService implements TwoTermBase
{
TwoTermDevListIfc<? extends TwoTermDev> _list;
public enum Side {From,To};
public TwoTermDev(TwoTermDevListIfc<? extends TwoTermDev> list, int ndx)
{
super(list, ndx);
_list = list;
}
@Override
public Bus getFromBus() throws PAModelException
{
return _list.getFromBus(_ndx);
}
@Override
public Bus getToBus() throws PAModelException
{
return _list.getToBus(_ndx);
}
/** from-side active power (MW) */
public float getFromP() throws PAModelException
{
return _list.getFromP(_ndx);
}
/** from-side active power (MW) */
public void setFromP(float mw) throws PAModelException
{
_list.setFromP(_ndx, mw);
}
/** from-side reactive power (MVAr) */
public float getFromQ() throws PAModelException
{
return _list.getFromQ(_ndx);
}
/** from-side reactive power (MVAr) */
public void setFromQ(float mvar) throws PAModelException
{
_list.setFromQ(_ndx, mvar);
}
/** to-side active power (MW) */
public float getToP() throws PAModelException
{
return _list.getToP(_ndx);
}
/** to-side active power (MW) */
public void setToP(float mw) throws PAModelException
{
_list.setToP(_ndx, mw);
}
/** to-side reactive power (MVAr) */
public float getToQ() throws PAModelException
{
return _list.getToQ(_ndx);
}
/** to-side reactive power (MVAr) */
public void setToQ(float mvar) throws PAModelException
{
_list.setToQ(_ndx, mvar);
}
}