DataWindowScript.java
2.75 KB
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
/*
* Decompiled with CFR 0_118.
*/
package com.adobe.xfa.data;
import com.adobe.xfa.Arg;
import com.adobe.xfa.Obj;
import com.adobe.xfa.ObjScript;
import com.adobe.xfa.ScriptFuncObj;
import com.adobe.xfa.ScriptPropObj;
import com.adobe.xfa.ScriptTable;
import com.adobe.xfa.data.DataNode;
import com.adobe.xfa.data.DataWindow;
import com.adobe.xfa.ut.ExFull;
import com.adobe.xfa.ut.ResId;
public class DataWindowScript
extends ObjScript {
protected static final ScriptTable moScriptTable = new ScriptTable(ObjScript.moScriptTable, "dataWindow", new ScriptPropObj[]{new ScriptPropObj(DataWindowScript.class, "recordsBefore", "getRecordsBefore", null, 4, 10, 9, 0), new ScriptPropObj(DataWindowScript.class, "recordsAfter", "getRecordsAfter", null, 4, 10, 9, 0), new ScriptPropObj(DataWindowScript.class, "currentRecordNumber", "getCurrentRecordNumber", null, 4, 10, 9, 0), new ScriptPropObj(DataWindowScript.class, "isDefined", "getIsDefined", null, 3, 10, 9, 0)}, new ScriptFuncObj[]{new ScriptFuncObj(DataWindowScript.class, "record", "record", 7, new int[]{4}, 1, 10, 9, 0), new ScriptFuncObj(DataWindowScript.class, "moveCurrentRecord", "moveCurrentRecord", 1, new int[]{4}, 1, 10, 9, 0), new ScriptFuncObj(DataWindowScript.class, "gotoRecord", "gotoRecord", 1, new int[]{4}, 1, 10, 9, 0), new ScriptFuncObj(DataWindowScript.class, "isRecordGroup", "isRecordGroup", 3, new int[]{7}, 1, 10, 9, 0)});
public static ScriptTable getScriptTable() {
return moScriptTable;
}
public static void getRecordsBefore(Obj pObj, Arg oRetVal) {
oRetVal.setInteger(((DataWindow)pObj).recordsBefore());
}
public static void getRecordsAfter(Obj pObj, Arg oRetVal) {
oRetVal.setInteger(((DataWindow)pObj).recordsAfter());
}
public static void getCurrentRecordNumber(Obj pObj, Arg oRetVal) {
oRetVal.setInteger(((DataWindow)pObj).currentRecordNumber());
}
public static void getIsDefined(Obj pObj, Arg oRetVal) {
oRetVal.setBool(((DataWindow)pObj).isDefined());
}
public static void record(Obj pObj, Arg oRetVal, Arg[] pArgs) {
oRetVal.setObject(((DataWindow)pObj).record(pArgs[0].getInteger()));
}
public static void moveCurrentRecord(Obj pObj, Arg oRetVal, Arg[] pArgs) {
((DataWindow)pObj).moveCurrentRecord(pArgs[0].getInteger());
}
public static void gotoRecord(Obj pObj, Arg oRetVal, Arg[] pArgs) {
((DataWindow)pObj).gotoRecord(pArgs[0].getInteger());
}
public static void isRecordGroup(Obj pObj, Arg oRetVal, Arg[] pArgs) {
Obj oObject = pArgs[0].getObject();
if (!oObject.isSameClass("dataGroup")) {
throw new ExFull(ResId.ArgumentMismatchException);
}
oRetVal.setBool(((DataWindow)pObj).isRecordGroup((DataNode)oObject));
}
}