AFeatureObject.js 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495
  1. /****************************************************************
  2. ** Licensed Materials - Property of IBM
  3. **
  4. ** BI and PM: qs
  5. **
  6. ** (C) Copyright IBM Corp. 2001, 2015
  7. **
  8. ** US Government Users Restricted Rights - Use, duplication or
  9. ** disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
  10. *****************************************************************/
  11. // Copyright (C) 2008 Cognos ULC, an IBM Company. All Rights Reserved.
  12. // Cognos and the Cognos logo are trademarks of Cognos ULC (formerly Cognos Incorporated) in the United States and/or other countries. IBM and the IBM logo are trademarks of International Business Machines Corporation in the United States, or other countries, or both. Other company, product, or service names may be trademarks or service marks of others.
  13. var FEATURE_OBJECT_NO_ERROR = 0;
  14. function AFeatureObject()
  15. {
  16. this.m_iErrorState = FEATURE_OBJECT_NO_ERROR;
  17. this.m_bRequiresDialog = false;
  18. this.m_bFeatureRequiresQualityOfService = false;
  19. this.m_aParams = new Array();
  20. this.m_sFeatureName = "undefinedFeature";
  21. this.m_sFeatureState = "uninitialized";
  22. };
  23. AFeatureObject.prototype.isInErrorState = function ()
  24. {
  25. if (this.m_iErrorState === FEATURE_OBJECT_NO_ERROR)
  26. {
  27. return false;
  28. }
  29. else
  30. {
  31. return true;
  32. }
  33. };
  34. AFeatureObject.prototype.isDialogRequired = function ()
  35. {
  36. return this.m_bRequiresDialog;
  37. };
  38. AFeatureObject.prototype.isSafeWithoutDialog = function ()
  39. {
  40. if (this.m_bRequiresDialog === false && this.isInErrorState() === false)
  41. {
  42. return true;
  43. }
  44. return false;
  45. };
  46. AFeatureObject.prototype.setQualityOfServiceStatus = function (bQOS)
  47. {
  48. this.m_bFeatureRequiresQualityOfService = (bQOS === true);
  49. };
  50. AFeatureObject.prototype.isQualityOfServiceRequired = function ()
  51. {
  52. return this.m_bFeatureRequiresQualityOfService;
  53. };
  54. AFeatureObject.prototype.getDialogParameters = function ()
  55. {
  56. return this.m_aParams;
  57. };
  58. AFeatureObject.prototype.getFeatureObjectName = function ()
  59. {
  60. return this.m_sFeatureName;
  61. };
  62. AFeatureObject.prototype.processErrorState = function ()
  63. {
  64. };
  65. AFeatureObject.prototype.proceedWithoutDialog = function ()
  66. {
  67. };
  68. AFeatureObject.prototype.setup = function ()
  69. {
  70. };
  71. AFeatureObject.prototype.execute = function (aParameters)
  72. {
  73. };