MetadataColumnAPI.js 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418
  1. "use strict";
  2. function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
  3. /**
  4. * Licensed Materials - Property of IBM
  5. * IBM Business Analytics (C) Copyright IBM Corp. 2018, 2019
  6. * US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
  7. */
  8. /**
  9. * @class MetadataColumnAPI
  10. * @hideconstructor
  11. * @classdesc implementation of the MetadataColumnAPI interface.
  12. */
  13. define([], function () {
  14. var MetadataColumnAPI = function () {
  15. function MetadataColumnAPI() {
  16. _classCallCheck(this, MetadataColumnAPI);
  17. }
  18. /**
  19. * @function MetadataColumnAPI#getObjectType
  20. * @description Return the object type (e.g. 'QueryItem').
  21. * @public
  22. *
  23. * @return {String} objectType
  24. */
  25. MetadataColumnAPI.prototype.getObjectType = function getObjectType() {};
  26. /**
  27. * @function MetadataColumnAPI#getId
  28. * @description Return the metadata column unique indentifier.
  29. * @public
  30. *
  31. * @return {String} unique identifier
  32. */
  33. MetadataColumnAPI.prototype.getId = function getId() {};
  34. /**
  35. * @function MetadataColumnAPI#getSourceId
  36. * @description Return the unique identifier of the metadata source.
  37. * @public
  38. *
  39. * @return {String} unique data source identifier
  40. */
  41. MetadataColumnAPI.prototype.getSourceId = function getSourceId() {};
  42. /**
  43. * @function MetadataColumnAPI#getLabel
  44. * @description Return the display label of the metadata column.
  45. * @public
  46. *
  47. * @return {String} display label
  48. */
  49. MetadataColumnAPI.prototype.getLabel = function getLabel() {};
  50. /**
  51. * @function MetadataColumnAPI#getType
  52. * @description Return the column type (e.g. 'attribute', 'fact').
  53. * @public
  54. *
  55. * @return {String} type
  56. */
  57. MetadataColumnAPI.prototype.getType = function getType() {};
  58. /**
  59. * @function MetadataColumnAPI#getDataType
  60. * @description Return the column data type (e.g. 'integer', 'string', etc ).
  61. * @public
  62. *
  63. * @return {String} type - possible values: 'integer' 'decimal', 'double', 'float', 'string', 'date', 'datetime', 'time'
  64. *
  65. *
  66. */
  67. MetadataColumnAPI.prototype.getDataType = function getDataType() {};
  68. /**
  69. * @function MetadataColumnAPI#getDefaultAggregation
  70. * @description Return the column default aggregation.
  71. * @public
  72. *
  73. * @return {String} defaultAggregation
  74. */
  75. MetadataColumnAPI.prototype.getDefaultAggregation = function getDefaultAggregation() {};
  76. /**
  77. * @function MetadataColumnAPI#getAggregationMode
  78. * @description Return the column aggregation mode.
  79. * @public
  80. *
  81. * @return {String} aggregationMode
  82. */
  83. MetadataColumnAPI.prototype.getAggregationMode = function getAggregationMode() {};
  84. /**
  85. * @function MetadataColumnAPI#getTaxonomyList
  86. * @description Return the list of column taxonomy.
  87. * @public
  88. *
  89. * @return {TaxonomyAPI[]} taxnonomy list
  90. */
  91. MetadataColumnAPI.prototype.getTaxonomyList = function getTaxonomyList() {};
  92. /**
  93. * @function MetadataColumnAPI#getDefaultSortType
  94. * @description Return the column sort type.
  95. * @public
  96. *
  97. * @return {String} sortType
  98. */
  99. MetadataColumnAPI.prototype.getDefaultSortType = function getDefaultSortType() {};
  100. /**
  101. * @function MetadataColumnAPI#getFormat
  102. * @description Return the column data format setting.
  103. * @public
  104. *
  105. * @param {Object} options ignoreDefaultFormatting - Ignore any default formatting
  106. * @return {FormatSpec} formatSpec
  107. */
  108. MetadataColumnAPI.prototype.getFormat = function getFormat() /* options */{};
  109. /**
  110. * @public
  111. * @function MetadataColumnAPI#getRootMember
  112. * @description Return the rootmember id when the column is a hierarchy.
  113. * @return {String} rootMember
  114. */
  115. MetadataColumnAPI.prototype.getRootMember = function getRootMember() {};
  116. /**
  117. * @async
  118. * @public
  119. * @function MetadataColumnAPI#isLeafMember
  120. * @description Determines whether a member is a leaf member.
  121. * @param {String} memberId Member unique name of the given member
  122. * @return {Promise<Boolean>} True if the member is a leaf, otherwise false
  123. */
  124. MetadataColumnAPI.prototype.isLeafMember = function isLeafMember() {};
  125. /**
  126. * @function MetadataColumnAPI#setLabel
  127. * @description Set the display label of the metadata column.
  128. * @param {String} label
  129. * @public
  130. */
  131. MetadataColumnAPI.prototype.setLabel = function setLabel() /* label */{};
  132. /**
  133. * @function MetadataColumnAPI#setHidden
  134. * @description Hide or show the column
  135. * @param {Boolean} bool
  136. * @public
  137. */
  138. MetadataColumnAPI.prototype.setHidden = function setHidden() /* bool */{};
  139. /**
  140. * @function MetadataColumnAPI#isFacetDefinitionEnabled
  141. * @description Determine whether the facet definition is enabled.
  142. * @public
  143. *
  144. * @return {Boolean} true if facet definition is enabled, otherwise false
  145. *
  146. */
  147. MetadataColumnAPI.prototype.isFacetDefinitionEnabled = function isFacetDefinitionEnabled() {};
  148. /**
  149. * @function MetadataColumnAPI#getSourceCategory
  150. * @description Returns the source category of the column, such as 'hierarchy', or 'level', etc. For relational type of dataset, this should return as 'column'.
  151. * @public
  152. *
  153. * @return {String} sourceCategory
  154. **/
  155. MetadataColumnAPI.prototype.getSourceCategory = function getSourceCategory() {};
  156. /**
  157. * @function MetadataColumnAPI#isHierarchy
  158. * @description Determine whether the column is an OLAP hierarchy.
  159. * @public
  160. *
  161. * @return {Boolean} true if the column is an OLAP hierarchy, otherwise false
  162. *
  163. **/
  164. MetadataColumnAPI.prototype.isHierarchy = function isHierarchy() {};
  165. /**
  166. * @function MetadataColumnAPI#isNamedSet
  167. * @description Determine whether the column is a named set.
  168. * @public
  169. *
  170. * @return {Boolean} true if hte column is a named set, otherwise false
  171. *
  172. **/
  173. MetadataColumnAPI.prototype.isNamedSet = function isNamedSet() {};
  174. /**
  175. * @function MetadataColumnAPI#isProperty
  176. * @description Determine whether the column is a property.
  177. * @public
  178. *
  179. * @return {Boolean} true if the column is a property, otherwise false
  180. *
  181. **/
  182. MetadataColumnAPI.prototype.isProperty = function isProperty() {};
  183. /**
  184. * @function MetadataColumnAPI#isLevel
  185. * @description Determine whether the column is a level.
  186. * @public
  187. *
  188. * @return {Boolean} true if the column is a level, otherwise false
  189. *
  190. **/
  191. MetadataColumnAPI.prototype.isLevel = function isLevel() {};
  192. /**
  193. * @function MetadataColumnAPI#isSingleRootHierarchy
  194. * @description Determine whether the column is a single root hierarchy
  195. * @public
  196. *
  197. * @return {Boolean} true if the column is a single root hierarchy, otherwise false
  198. *
  199. **/
  200. MetadataColumnAPI.prototype.isSingleRootHierarchy = function isSingleRootHierarchy() {};
  201. /**
  202. * @function MetadataColumnAPI#getReferencedHierarchyId
  203. * @description Returns the referenced hierarchy when it exists. For example, the referenced hierarchy of a namedSet object
  204. * is the hierarchy the namedSet belongs to
  205. * @public
  206. *
  207. * @return {string} hierarchy identifier
  208. */
  209. MetadataColumnAPI.prototype.getReferencedHierarchyId = function getReferencedHierarchyId() {};
  210. /**
  211. * @function MetadataColumnAPI#isOlapColumn
  212. * @description Determine whether the column is an OLAP column
  213. * @public
  214. *
  215. * @return {Boolean} true if the column is an OLAP column, otherwise false
  216. */
  217. MetadataColumnAPI.prototype.isOlapColumn = function isOlapColumn() {};
  218. /**
  219. * @function MetadataColumnAPI#isNumericDataType
  220. * @description Determine whether the column is a number data type (e.g. 'integer', 'decimal', etc) column
  221. * @public
  222. *
  223. * @return {Boolean} true if the column is a number type, otherwise false
  224. */
  225. MetadataColumnAPI.prototype.isNumericDataType = function isNumericDataType() {};
  226. /**
  227. * @function MetadataColumnAPI#isDateTimeDataType
  228. * @description Determine whether the column is a data/time data type (e.g. 'date', 'time', etc) column
  229. * @public
  230. * @return {Boolean} true if the column is a date/time type, otherwise false
  231. */
  232. MetadataColumnAPI.prototype.isDateTimeDataType = function isDateTimeDataType() {};
  233. /**
  234. * @function MetadataColumnAPI#isFilter
  235. * @description Determine whether the column is a filter
  236. * @public
  237. * @return {Boolean} true if the column is a filter, otherwise false
  238. */
  239. MetadataColumnAPI.prototype.isFilter = function isFilter() {};
  240. /**
  241. * @function MetadataColumnAPI#isEditableCalculation
  242. * @description Determine whether the column is an editable calculation
  243. * @public
  244. *
  245. * @return {Boolean} true if the column is an editable calculation, otherwise false
  246. */
  247. MetadataColumnAPI.prototype.isEditableCalculation = function isEditableCalculation() {};
  248. /**
  249. * @function MetadataColumnAPI#getTableId
  250. * @description Get table id
  251. * @public
  252. *
  253. * @return {Boolean} true if the column is an editable calculation, otherwise false
  254. */
  255. MetadataColumnAPI.prototype.getTableId = function getTableId() {};
  256. /**
  257. * @function MetadataColumnAPI#getTableName
  258. * @description Get the table name that this column belongs to
  259. * @public
  260. *
  261. * @return {String} tableName
  262. */
  263. MetadataColumnAPI.prototype.getTableName = function getTableName() {};
  264. /**
  265. * @public
  266. * @deprecated
  267. * @function MetadataColumnAPI#getDeprecatedMetadataColumn
  268. * @description Get the legacy metadata column object
  269. * @return {Object} legacy metadata column object
  270. *
  271. * @TODO - livewidget_cleanup - demolish this API
  272. */
  273. MetadataColumnAPI.prototype.getDeprecatedMetadataColumn = function getDeprecatedMetadataColumn() {};
  274. /**
  275. * @function MetadataColumnAPI#isHidden
  276. * @description Determine whether the column is hidden
  277. * @public
  278. *
  279. * @return {Boolean} true if the column is hidden, otherwise false
  280. */
  281. MetadataColumnAPI.prototype.isHidden = function isHidden() {};
  282. /**
  283. * @function MetadataColumnAPI#isMissing
  284. * @description Determine whether the column is missing
  285. * @public
  286. *
  287. * @return {Boolean} true if the column is missing, otherwise false
  288. */
  289. MetadataColumnAPI.prototype.isMissing = function isMissing() {};
  290. /**
  291. * @function MetadataColumnAPI#getParent
  292. * @description Returns the parent MetadataColumnAPI
  293. * @public
  294. *
  295. * @return {MetadataColumnAPI} MetadataColumnAPI or null
  296. */
  297. MetadataColumnAPI.prototype.getParent = function getParent() {};
  298. /**
  299. * @function MetadataColumnAPI#getHierarchyLevelIds
  300. * @description Returns the levelIds of the hierarchy in natural order.
  301. * @public
  302. *
  303. * @return {String[]} an array of levelIds
  304. */
  305. MetadataColumnAPI.prototype.getHierarchyLevelIds = function getHierarchyLevelIds() {};
  306. return MetadataColumnAPI;
  307. }();
  308. return MetadataColumnAPI;
  309. });
  310. //# sourceMappingURL=MetadataColumnAPI.js.map