1 /*
2  * Copyright (C) 2017 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 package com.android.dx.cf.cst;
18 
19 /**
20  * Method Handle kinds for {@code CONSTANT_MethodHandle_info} constants.
21  */
22 public interface MethodHandleKind {
23     /** A method handle that gets an instance field. */
24     int REF_getField = 1;
25 
26     /** A method handle that gets a static field. */
27     int REF_getStatic = 2;
28 
29     /** A method handle that sets an instance field. */
30     int REF_putField = 3;
31 
32     /** A method handle that sets a static field. */
33     int REF_putStatic = 4;
34 
35     /** A method handle for {@code invokevirtual}. */
36     int REF_invokeVirtual = 5;
37 
38     /** A method handle for {@code invokestatic}. */
39     int REF_invokeStatic = 6;
40 
41     /** A method handle for {@code invokespecial}. */
42     int REF_invokeSpecial = 7;
43 
44     /** A method handle for invoking a constructor. */
45     int REF_newInvokeSpecial = 8;
46 
47     /** A method handle for {@code invokeinterface}. */
48     int REF_invokeInterface = 9;
49 }
50