161db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti/* 2afa8f6f583892db62572d5db3a419c98d6ad936aFederico Tomassetti * Copyright (C) 2007-2010 Júlio Vilmar Gesser. 3afa8f6f583892db62572d5db3a419c98d6ad936aFederico Tomassetti * Copyright (C) 2011, 2013-2016 The JavaParser Team. 461db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti * 5afa8f6f583892db62572d5db3a419c98d6ad936aFederico Tomassetti * This file is part of JavaParser. 661db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti * 7afa8f6f583892db62572d5db3a419c98d6ad936aFederico Tomassetti * JavaParser can be used either under the terms of 8afa8f6f583892db62572d5db3a419c98d6ad936aFederico Tomassetti * a) the GNU Lesser General Public License as published by 9afa8f6f583892db62572d5db3a419c98d6ad936aFederico Tomassetti * the Free Software Foundation, either version 3 of the License, or 10afa8f6f583892db62572d5db3a419c98d6ad936aFederico Tomassetti * (at your option) any later version. 11afa8f6f583892db62572d5db3a419c98d6ad936aFederico Tomassetti * b) the terms of the Apache License 1261db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti * 13afa8f6f583892db62572d5db3a419c98d6ad936aFederico Tomassetti * You should have received a copy of both licenses in LICENCE.LGPL and 14afa8f6f583892db62572d5db3a419c98d6ad936aFederico Tomassetti * LICENCE.APACHE. Please refer to those files for details. 15afa8f6f583892db62572d5db3a419c98d6ad936aFederico Tomassetti * 16afa8f6f583892db62572d5db3a419c98d6ad936aFederico Tomassetti * JavaParser is distributed in the hope that it will be useful, 17afa8f6f583892db62572d5db3a419c98d6ad936aFederico Tomassetti * but WITHOUT ANY WARRANTY; without even the implied warranty of 18afa8f6f583892db62572d5db3a419c98d6ad936aFederico Tomassetti * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 19afa8f6f583892db62572d5db3a419c98d6ad936aFederico Tomassetti * GNU Lesser General Public License for more details. 2061db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti */ 2161db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti 2261db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassettipackage com.github.javaparser.resolution.declarations; 2361db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti 2461db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti/** 2561db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti * Declaration of a field. 2661db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti * 2761db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti * @author Federico Tomassetti 2861db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti */ 290bab9a0e7ef3725f252498316f37d7eddbdfcf81Federico Tomassettipublic interface ResolvedFieldDeclaration extends ResolvedValueDeclaration, HasAccessSpecifier { 3061db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti 3161db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti /** 3261db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti * Is the field static? 3361db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti */ 3461db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti boolean isStatic(); 3561db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti 3661db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti @Override 3761db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti default boolean isField() { 3861db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti return true; 3961db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti } 4061db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti 4161db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti @Override 4261db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti default ResolvedFieldDeclaration asField() { 4361db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti return this; 4461db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti } 4561db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti 4661db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti /** 4761db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti * The type on which this field has been declared 4861db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti */ 4961db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti ResolvedTypeDeclaration declaringType(); 5061db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti 5161db2ec5c6d8a2146b83bc92203c844b82d6f345Federico Tomassetti} 52