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

http://mobicents.googlecode.com/ · Java · 65 lines · 21 code · 9 blank · 35 comment · 0 complexity · a432ea2175383c0f1132938290717c25 MD5 · raw file

  1. package javax.megaco.pkg.AnalogLineSPkg;
  2. import javax.megaco.pkg.MegacoPkg;
  3. import javax.megaco.pkg.PkgEventItem;
  4. /**
  5. * The MEGACO On Hook event class extends the PkgEventItem class. This is a
  6. * final class. This class defines On Hook event of Analog Line Supervision
  7. * package. The methods shall define that this event item belongs to the Analog
  8. * Line Supervision package.
  9. */
  10. public final class AnalogLineSOnEvt extends PkgEventItem {
  11. /**
  12. * Identifies On Hook event of the MEGACO Analog Line Supervision Package.
  13. * Its value shall be set equal to 0x0004.
  14. */
  15. public static final int ANALOG_LINE_ONHOOK_EVENT = 0x0004;
  16. /**
  17. * Constructs a Jain MEGACO Object representing event Item of the MEGACO
  18. * Package for event OnHook and package as Analog Line Supervision.
  19. */
  20. public AnalogLineSOnEvt() {
  21. super();
  22. super.itemId = ANALOG_LINE_ONHOOK_EVENT;
  23. super.eventId = ANALOG_LINE_ONHOOK_EVENT;
  24. super.packageId = new AnalogLineSPkg();
  25. }
  26. /**
  27. * This method is used to get the event identifier from an Event Item
  28. * object. The implementations of this method in this class returns the id
  29. * of the On Hook event of Analog Line Supervision Package.
  30. *
  31. * @return It shall {@link ANALOG_LINE_ONHOOK_EVENT}.
  32. */
  33. public int getEventId() {
  34. return super.itemId;
  35. }
  36. /**
  37. * This method is used to get the item identifier from an Item object. The
  38. * implementations of this method in this class returns the id of the On
  39. * Hook event of Analog Line Supervision Package.
  40. *
  41. * @return It shall return {@link ANALOG_LINE_ONHOOK_EVENT}.
  42. */
  43. public int getItemId() {
  44. return super.itemId;
  45. }
  46. /**
  47. * This method gets the package to which the item belongs. Since the On Hook
  48. * event is defined in the Analog Line Supervision Package of MEGACO
  49. * protocol, this method returns the AnalogLineSPkg class object.
  50. *
  51. * @return The package is {@link AnalogLineSPkg}.
  52. */
  53. public MegacoPkg getItemsPkgId() {
  54. return super.packageId;
  55. }
  56. }