/* * @(#)AnnotationValue.java 1.6 04/07/19 * * Copyright 2004 Sun Microsystems, Inc. All rights reserved. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms. */ package com.sun.mirror.declaration; import com.sun.mirror.util.SourcePosition; /** * Represents a value of an annotation type element. * * @author Joseph D. Darcy * @author Scott Seligman * @version 1.6 04/07/19 * @since 1.5 */ public interface AnnotationValue { /** * Returns the value. * The result has one of the following types: * * * @return the value */ Object getValue(); /** * Returns the source position of the beginning of this annotation value. * Returns null if the position is unknown or not applicable. * *

This source position is intended for use in providing diagnostics, * and indicates only approximately where an annotation value begins. * * @return the source position of the beginning of this annotation value or * null if the position is unknown or not applicable */ SourcePosition getPosition(); /** * Returns a string representation of this value. * This is returned in a form suitable for representing this value * in the source code of an annotation. * * @return a string representation of this value */ String toString(); }