/protocols/jain-megaco/megaco-api/src/main/java/javax/megaco/pkg/NetworkPkg/NetworkOsStats.java

http://mobicents.googlecode.com/ · Java · 83 lines · 31 code · 15 blank · 37 comment · 0 complexity · 05feba5700d7d957ca7b00c9517b59bb MD5 · raw file

  1. package javax.megaco.pkg.NetworkPkg;
  2. import javax.megaco.pkg.MegacoPkg;
  3. import javax.megaco.pkg.ParamValueType;
  4. import javax.megaco.pkg.PkgConsts;
  5. import javax.megaco.pkg.PkgStatsItem;
  6. /**
  7. * The MEGACO Octet sent statistics class extends the PkgStatsItem class. This
  8. * is a final class. This class defines Octet sent statistics of MEGACO Network
  9. * package. The methods shall define that this statistics item belongs to the
  10. * Network package.
  11. */
  12. public final class NetworkOsStats extends PkgStatsItem {
  13. /**
  14. * Identifies Octets sent statistics of the MEGACO Network Package. Its
  15. * value shall be set equal to 0x0002.
  16. */
  17. public static final int NETWORK_OS_STATS = 0x0002;
  18. /**
  19. * Constructs a Jain MEGACO Object representing statistics Item of the
  20. * MEGACO Package for statistics Octet sent and Package as Network.
  21. */
  22. public NetworkOsStats() {
  23. super();
  24. super.itemId = NETWORK_OS_STATS;
  25. super.statisticsId = NETWORK_OS_STATS;
  26. super.packageId = new NetworkPkg();
  27. super.itemType = ParamValueType.M_STRING;
  28. }
  29. /**
  30. * This method is used to get the item identifier from an Item object. The
  31. * implementations of this method in this class returns the id of the Octet
  32. * Sent statistics of Network Package.
  33. *
  34. * @return It shall return {@link NETWORK_OS_STATS}.
  35. */
  36. public int getItemId() {
  37. return super.itemId;
  38. }
  39. /**
  40. * This method is used to get the statistics identifier from an Statistics
  41. * Item object. The implementations of this method in this class returns the
  42. * id of the Octet Sent statistics of Network Package.
  43. *
  44. * @return It shall return {@link NETWORK_OS_STATS}.
  45. */
  46. public int getStatisticsId() {
  47. return super.statisticsId;
  48. }
  49. /**
  50. * This method gets the package id to which the item belongs. Since the
  51. * Octet Sent statistics is defined in the Network Package of MEGACO
  52. * protocol, this method returns the value {@link PkgConsts.NETWORK_PACKAGE}
  53. * constant. This constant is defined in the PkgConsts class.
  54. *
  55. * @return The package id {@link PkgConsts.NETWORK_PACKAGE}.
  56. */
  57. public MegacoPkg getItemsPkgId() {
  58. return super.packageId;
  59. }
  60. //FIXME: add jdoc ? those are not present
  61. public int getItemValueType() {
  62. return super.itemType;
  63. }
  64. @Override
  65. public int[] getItemsDescriptorIds() {
  66. return new int[]{};
  67. }
  68. }