decompiler: cleanup

This commit is contained in:
Egor.Ushakov
2015-03-27 12:56:07 +03:00
parent d5e22fe0c9
commit 262d580ccc
28 changed files with 107 additions and 98 deletions

View File

@@ -34,7 +34,7 @@ public class ConstantPool implements NewClassNameBuilder {
public static final int FIELD = 1;
public static final int METHOD = 2;
private List<PooledConstant> pool = new ArrayList<PooledConstant>();
private final List<PooledConstant> pool = new ArrayList<PooledConstant>();
private final PoolInterceptor interceptor;

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2000-2014 JetBrains s.r.o.
* Copyright 2000-2015 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -22,9 +22,9 @@ public class GenericClassDescriptor {
public GenericType superclass;
public List<GenericType> superinterfaces = new ArrayList<GenericType>();
public final List<GenericType> superinterfaces = new ArrayList<GenericType>();
public List<String> fparameters = new ArrayList<String>();
public final List<String> fparameters = new ArrayList<String>();
public List<List<GenericType>> fbounds = new ArrayList<List<GenericType>>();
public final List<List<GenericType>> fbounds = new ArrayList<List<GenericType>>();
}

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2000-2014 JetBrains s.r.o.
* Copyright 2000-2015 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -20,13 +20,13 @@ import java.util.List;
public class GenericMethodDescriptor {
public List<String> fparameters = new ArrayList<String>();
public final List<String> fparameters = new ArrayList<String>();
public List<List<GenericType>> fbounds = new ArrayList<List<GenericType>>();
public final List<List<GenericType>> fbounds = new ArrayList<List<GenericType>>();
public List<GenericType> params = new ArrayList<GenericType>();
public final List<GenericType> params = new ArrayList<GenericType>();
public GenericType ret;
public List<GenericType> exceptions = new ArrayList<GenericType>();
public final List<GenericType> exceptions = new ArrayList<GenericType>();
}

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2000-2014 JetBrains s.r.o.
* Copyright 2000-2015 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -160,9 +160,9 @@ public class LazyLoader {
public static final int CLASS = 1;
public static final int ENTRY = 2;
public int type;
public String externalPath;
public String internalPath;
public final int type;
public final String externalPath;
public final String internalPath;
public Link(int type, String externalPath, String internalPath) {
this.type = type;

View File

@@ -1,9 +1,24 @@
/*
* Copyright 2000-2015 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.jetbrains.java.decompiler.struct.match;
public interface IMatchable {
public enum MatchProperties {
enum MatchProperties {
STATEMENT_TYPE,
STATEMENT_RET,
STATEMENT_STATSIZE,
@@ -25,8 +40,8 @@ public interface IMatchable {
EXPRENT_FIELD_NAME,
}
public IMatchable findObject(MatchNode matchNode, int index);
IMatchable findObject(MatchNode matchNode, int index);
public boolean match(MatchNode matchNode, MatchEngine engine);
boolean match(MatchNode matchNode, MatchEngine engine);
}

View File

@@ -25,8 +25,8 @@ import org.jetbrains.java.decompiler.struct.match.IMatchable.MatchProperties;
public class MatchNode {
public static class RuleValue {
public int parameter;
public Object value;
public final int parameter;
public final Object value;
public RuleValue(int parameter, Object value) {
this.parameter = parameter;