All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.jolira.st4j.Metric Maven / Gradle / Ivy

Go to download

A client library for the Server Tracker. (http://github.com/jolira/server-tracker)

There is a newer version: 1.1.1
Show newest version
/**
 * Copyright (c) 2011 jolira. All rights reserved. This program and the accompanying materials are made available under
 * the terms of the GNU Public License 2.0 which is available at http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
 */

package com.jolira.st4j;

import static java.lang.annotation.ElementType.FIELD;
import static java.lang.annotation.ElementType.PARAMETER;
import static java.lang.annotation.ElementType.TYPE;
import static java.lang.annotation.RetentionPolicy.RUNTIME;

import java.lang.annotation.Documented;
import java.lang.annotation.Retention;
import java.lang.annotation.Target;

import com.google.inject.ScopeAnnotation;

/**
 * Used to annotate any metric instance.
 * 
 * @author jfk
 * @date Aug 12, 2011 8:54:14 PM
 * @since 1.0
 * 
 */
@Target({ TYPE, FIELD, PARAMETER })
@Retention(RUNTIME)
@ScopeAnnotation
@Documented
public @interface Metric {
    /**
     * @return {@literal true} to indicate that only one of these metric should be produced for any given event.
     */
    boolean unique() default true;

    /**
     * @return the name to be for the metric when marshalling
     */
    String value() default "##default";
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy