### Question:
AsmMetric { @VisibleForTesting public abstract Object getValue(Integer window); AsmMetric(); static void setSampleRate(double sampleRate); abstract void update(Number obj); abstract void updateTime(long obj); void updateDirectly(Number obj); abstract AsmMetric clone(); AsmMetric setOp(int op); int getOp(); static void setWindowSeconds(List<Integer> windows); static int getMinWindow(List<Integer> windows); void addAssocMetrics(AsmMetric... metrics); long getMetricId(); void setMetricId(long metricId); String getMetricName(); void setMetricName(String metricName); String getShortName(); void flush(); @VisibleForTesting void forceFlush(); List<Integer> rollWindows(long time, List<Integer> windows); abstract Map<Integer, T> getWindowMetricMap(); abstract T mkInstance(); @VisibleForTesting abstract Object getValue(Integer window); Map<Integer, AsmSnapshot> getSnapshots(); List<Integer> getValidWindows(); @VisibleForTesting List<Integer> getWindows(); boolean isAggregate(); void setAggregate(boolean aggregate); Set<AsmMetric> getAssocMetrics(); AsmMetric setEnabled(boolean enabled); boolean isAttached(); void setAttached(boolean attached); static String mkName(Object... parts);  }### Answer:
@Test public void testGetValue() { AsmCounter counter = new AsmCounter(); for (int i = 0; i < 100; i++) { counter.inc(); } long v = (Long) counter.getValue(AsmWindow.M1_WINDOW); Assert.assertEquals(100, v); }