001package io.ebean.meta;
002
003/**
004 * Query execution metrics.
005 */
006public interface MetaQueryMetric extends MetaTimedMetric {
007
008  /**
009   * The type of entity or DTO bean.
010   */
011  Class<?> type();
012
013  /**
014   * Migrate to type().
015   */
016  @Deprecated
017  default Class<?> getType() {
018    return type();
019  }
020
021  /**
022   * The label for the query (can be null).
023   */
024  String label();
025
026  /**
027   * Migrate to label().
028   */
029  @Deprecated
030  default String getLabel() {
031    return label();
032  }
033
034  /**
035   * The actual SQL of the query.
036   */
037  String sql();
038
039  /**
040   * Migrate to sql().
041   */
042  @Deprecated
043  default String getSql() {
044    return sql();
045  }
046
047  /**
048   * Return the hash of the plan.
049   */
050  String hash();
051
052}