1. /*
  2. * @(#)file SnmpTableCallbackHandler.java
  3. * @(#)author Sun Microsystems, Inc.
  4. * @(#)version 1.6
  5. * @(#)date 04/09/15
  6. *
  7. * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
  8. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
  9. */
  10. package com.sun.jmx.snmp.agent;
  11. import javax.management.ObjectName;
  12. import com.sun.jmx.snmp.SnmpStatusException;
  13. import com.sun.jmx.snmp.SnmpOid;
  14. import com.sun.jmx.snmp.agent.SnmpMibTable;
  15. /**
  16. * This interface ensures the synchronization between Metadata table objects
  17. * and bean-like table objects.
  18. *
  19. * It is used between mibgen generated table meta and table classes.
  20. * <p><b><i>
  21. * You should never need to use this interface directly.
  22. * </p></b></i>
  23. *
  24. * <p><b>This API is a Sun Microsystems internal API and is subject
  25. * to change without notice.</b></p>
  26. **/
  27. public interface SnmpTableCallbackHandler {
  28. /**
  29. * This method is called by the SNMP runtime after a new entry
  30. * has been added to the table.
  31. *
  32. * If an SnmpStatusException is raised, the entry will be removed
  33. * and the operation will be aborted. In this case, the removeEntryCb()
  34. * callback will not be called.
  35. *
  36. * <p><b><i>
  37. * You should never need to use this method directly.
  38. * </p></b></i>
  39. *
  40. **/
  41. public void addEntryCb(int pos, SnmpOid row, ObjectName name,
  42. Object entry, SnmpMibTable meta)
  43. throws SnmpStatusException;
  44. /**
  45. * This method is called by the SNMP runtime after a new entry
  46. * has been removed from the table.
  47. *
  48. * If raised, SnmpStatusException will be ignored.
  49. *
  50. * <p><b><i>
  51. * You should never need to use this method directly.
  52. * </p></b></i>
  53. *
  54. **/
  55. public void removeEntryCb(int pos, SnmpOid row, ObjectName name,
  56. Object entry, SnmpMibTable meta)
  57. throws SnmpStatusException;
  58. }