resultRow.put("name", logicalTable.getName()); resultRow.put("longName", logicalTable.getLongName()); resultRow.put("retention", logicalTable.getRetention().toString()); resultRow.put("granularity", logicalTable.getGranularity().getName()); resultRow.put("description", logicalTable.getDescription());
new SimpleImmutableEntry<>("name", logicalTable.getName()), new SimpleImmutableEntry<>("longName", logicalTable.getLongName()), new SimpleImmutableEntry<>("retention", logicalTable.getRetention().toString()), new SimpleImmutableEntry<>("granularity", logicalTable.getGranularity().getName()), new SimpleImmutableEntry<>("description", logicalTable.getDescription()),
/** * Method to provide grain level details(with metrics and dimensions) of the given logical table. * * @param logicalTable Logical Table at the grain level * @param grain Table grain * @param uriInfo Uri information to construct the uri's * * @return logical table details at grain level with all the associated meta data */ @Override public TableGrainView formatTableGrain(LogicalTable logicalTable, String grain, UriInfo uriInfo) { TableGrainView resultRow = new TableGrainView(); resultRow.put("name", grain); resultRow.put("longName", StringUtils.capitalize(grain)); resultRow.put("description", "The " + logicalTable.getName() + " " + grain + " grain"); resultRow.put("retention", logicalTable.getRetention().toString()); resultRow.put("dimensions", getDimensionListFullView(logicalTable.getDimensions(), uriInfo)); resultRow.put( "metrics", MetricsServlet.getLogicalMetricListSummaryView(logicalTable.getLogicalMetrics(), uriInfo) ); return resultRow; }