Imported Upstream version 0.4.8
[platform/upstream/libsmi.git] / test / dumps / jax / UsrHistoryObjectEntryImpl.java
1 /*
2  * This Java file has been generated by smidump 0.4.5. It
3  * is intended to be edited by the application programmer and
4  * to be used within a Java AgentX sub-agent environment.
5  *
6  * $Id: UsrHistoryObjectEntryImpl.java 4432 2006-05-29 16:21:11Z strauss $
7  */
8
9 /**
10     This class extends the Java AgentX (JAX) implementation of
11     the table row usrHistoryObjectEntry defined in RMON2-MIB.
12  */
13
14 import jax.AgentXOID;
15 import jax.AgentXSetPhase;
16 import jax.AgentXResponsePDU;
17 import jax.AgentXEntry;
18
19 public class UsrHistoryObjectEntryImpl extends UsrHistoryObjectEntry
20 {
21
22     // constructor
23     public UsrHistoryObjectEntryImpl(int usrHistoryControlIndex,
24                                  int usrHistoryObjectIndex)
25     {
26         super(usrHistoryControlIndex,
27                        usrHistoryObjectIndex);
28     }
29
30     public AgentXOID get_usrHistoryObjectVariable()
31     {
32         return usrHistoryObjectVariable;
33     }
34
35     public int set_usrHistoryObjectVariable(AgentXSetPhase phase, AgentXOID value)
36     {
37         switch (phase.getPhase()) {
38         case AgentXSetPhase.TEST_SET:
39             break;
40         case AgentXSetPhase.COMMIT:
41             undo_usrHistoryObjectVariable = usrHistoryObjectVariable;
42             usrHistoryObjectVariable = value;
43             break;
44         case AgentXSetPhase.UNDO:
45             usrHistoryObjectVariable = undo_usrHistoryObjectVariable;
46             break;
47         case AgentXSetPhase.CLEANUP:
48             break;
49         default:
50             return AgentXResponsePDU.PROCESSING_ERROR;
51         }
52         return AgentXResponsePDU.NO_ERROR;
53     }
54     public int get_usrHistoryObjectSampleType()
55     {
56         return usrHistoryObjectSampleType;
57     }
58
59     public int set_usrHistoryObjectSampleType(AgentXSetPhase phase, int value)
60     {
61         switch (phase.getPhase()) {
62         case AgentXSetPhase.TEST_SET:
63             break;
64         case AgentXSetPhase.COMMIT:
65             undo_usrHistoryObjectSampleType = usrHistoryObjectSampleType;
66             usrHistoryObjectSampleType = value;
67             break;
68         case AgentXSetPhase.UNDO:
69             usrHistoryObjectSampleType = undo_usrHistoryObjectSampleType;
70             break;
71         case AgentXSetPhase.CLEANUP:
72             break;
73         default:
74             return AgentXResponsePDU.PROCESSING_ERROR;
75         }
76         return AgentXResponsePDU.NO_ERROR;
77     }
78 }
79