id
int32
0
12.9k
code
sequencelengths
2
264k
5,500
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Messages", ";", "public", "class", "MoveElementsOperation", "extends", "CopyElementsOperation", "{", "public", "MoveElementsOperation", "(", "IJavaElement", "[", "]", "elementsToMove", ",", "IJavaElement", "[", "]", "destContainers", ",", "boolean", "force", ")", "{", "super", "(", "elementsToMove", ",", "destContainers", ",", "force", ")", ";", "}", "protected", "String", "getMainTaskName", "(", ")", "{", "return", "Messages", ".", "operation_moveElementProgress", ";", "}", "protected", "boolean", "isMove", "(", ")", "{", "return", "true", ";", "}", "}", "</s>" ]
5,501
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "public", "class", "ResolvedBinaryMethod", "extends", "BinaryMethod", "{", "private", "String", "uniqueKey", ";", "public", "ResolvedBinaryMethod", "(", "JavaElement", "parent", ",", "String", "name", ",", "String", "[", "]", "parameterTypes", ",", "String", "uniqueKey", ")", "{", "super", "(", "parent", ",", "name", ",", "parameterTypes", ")", ";", "this", ".", "uniqueKey", "=", "uniqueKey", ";", "}", "public", "String", "getKey", "(", ")", "{", "return", "this", ".", "uniqueKey", ";", "}", "public", "boolean", "isResolved", "(", ")", "{", "return", "true", ";", "}", "protected", "void", "toStringInfo", "(", "int", "tab", ",", "StringBuffer", "buffer", ",", "Object", "info", ",", "boolean", "showResolvedInfo", ")", "{", "super", ".", "toStringInfo", "(", "tab", ",", "buffer", ",", "info", ",", "showResolvedInfo", ")", ";", "if", "(", "showResolvedInfo", ")", "{", "buffer", ".", "append", "(", "\"", "{key=\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "uniqueKey", ")", ";", "buffer", ".", "append", "(", "\"}\"", ")", ";", "}", "}", "public", "JavaElement", "unresolved", "(", ")", "{", "SourceRefElement", "handle", "=", "new", "BinaryMethod", "(", "this", ".", "parent", ",", "this", ".", "name", ",", "this", ".", "parameterTypes", ")", ";", "handle", ".", "occurrenceCount", "=", "this", ".", "occurrenceCount", ";", "return", "handle", ";", "}", "}", "</s>" ]
5,502
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "util", ".", "Enumeration", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "LRUCache", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Messages", ";", "public", "abstract", "class", "OverflowingLRUCache", "extends", "LRUCache", "{", "protected", "int", "overflow", "=", "0", ";", "protected", "boolean", "timestampsOn", "=", "true", ";", "protected", "double", "loadFactor", "=", "0.333", ";", "public", "OverflowingLRUCache", "(", "int", "size", ")", "{", "this", "(", "size", ",", "0", ")", ";", "}", "public", "OverflowingLRUCache", "(", "int", "size", ",", "int", "overflow", ")", "{", "super", "(", "size", ")", ";", "this", ".", "overflow", "=", "overflow", ";", "}", "public", "Object", "clone", "(", ")", "{", "OverflowingLRUCache", "newCache", "=", "(", "OverflowingLRUCache", ")", "newInstance", "(", "this", ".", "spaceLimit", ",", "this", ".", "overflow", ")", ";", "LRUCacheEntry", "qEntry", ";", "qEntry", "=", "this", ".", "entryQueueTail", ";", "while", "(", "qEntry", "!=", "null", ")", "{", "newCache", ".", "privateAdd", "(", "qEntry", ".", "key", ",", "qEntry", ".", "value", ",", "qEntry", ".", "space", ")", ";", "qEntry", "=", "qEntry", ".", "previous", ";", "}", "return", "newCache", ";", "}", "protected", "abstract", "boolean", "close", "(", "LRUCacheEntry", "entry", ")", ";", "public", "Enumeration", "elements", "(", ")", "{", "if", "(", "this", ".", "entryQueue", "==", "null", ")", "return", "new", "LRUCacheEnumerator", "(", "null", ")", ";", "LRUCacheEnumerator", ".", "LRUEnumeratorElement", "head", "=", "new", "LRUCacheEnumerator", ".", "LRUEnumeratorElement", "(", "this", ".", "entryQueue", ".", "value", ")", ";", "LRUCacheEntry", "currentEntry", "=", "this", ".", "entryQueue", ".", "next", ";", "LRUCacheEnumerator", ".", "LRUEnumeratorElement", "currentElement", "=", "head", ";", "while", "(", "currentEntry", "!=", "null", ")", "{", "currentElement", ".", "next", "=", "new", "LRUCacheEnumerator", ".", "LRUEnumeratorElement", "(", "currentEntry", ".", "value", ")", ";", "currentElement", "=", "currentElement", ".", "next", ";", "currentEntry", "=", "currentEntry", ".", "next", ";", "}", "return", "new", "LRUCacheEnumerator", "(", "head", ")", ";", "}", "public", "double", "fillingRatio", "(", ")", "{", "return", "(", "this", ".", "currentSpace", "+", "this", ".", "overflow", ")", "*", "100.0", "/", "this", ".", "spaceLimit", ";", "}", "public", "java", ".", "util", ".", "Hashtable", "getEntryTable", "(", ")", "{", "return", "this", ".", "entryTable", ";", "}", "public", "double", "getLoadFactor", "(", ")", "{", "return", "this", ".", "loadFactor", ";", "}", "public", "int", "getOverflow", "(", ")", "{", "return", "this", ".", "overflow", ";", "}", "protected", "boolean", "makeSpace", "(", "int", "space", ")", "{", "int", "limit", "=", "this", ".", "spaceLimit", ";", "if", "(", "this", ".", "overflow", "==", "0", "&&", "this", ".", "currentSpace", "+", "space", "<=", "limit", ")", "{", "return", "true", ";", "}", "int", "spaceNeeded", "=", "(", "int", ")", "(", "(", "1", "-", "this", ".", "loadFactor", ")", "*", "limit", ")", ";", "spaceNeeded", "=", "(", "spaceNeeded", ">", "space", ")", "?", "spaceNeeded", ":", "space", ";", "LRUCacheEntry", "entry", "=", "this", ".", "entryQueueTail", ";", "try", "{", "this", ".", "timestampsOn", "=", "false", ";", "while", "(", "this", ".", "currentSpace", "+", "spaceNeeded", ">", "limit", "&&", "entry", "!=", "null", ")", "{", "this", ".", "privateRemoveEntry", "(", "entry", ",", "false", ",", "false", ")", ";", "entry", "=", "entry", ".", "previous", ";", "}", "}", "finally", "{", "this", ".", "timestampsOn", "=", "true", ";", "}", "if", "(", "this", ".", "currentSpace", "+", "space", "<=", "limit", ")", "{", "this", ".", "overflow", "=", "0", ";", "return", "true", ";", "}", "this", ".", "overflow", "=", "this", ".", "currentSpace", "+", "space", "-", "limit", ";", "return", "false", ";", "}", "protected", "abstract", "LRUCache", "newInstance", "(", "int", "size", ",", "int", "newOverflow", ")", ";", "public", "void", "printStats", "(", ")", "{", "int", "forwardListLength", "=", "0", ";", "LRUCacheEntry", "entry", "=", "this", ".", "entryQueue", ";", "while", "(", "entry", "!=", "null", ")", "{", "forwardListLength", "++", ";", "entry", "=", "entry", ".", "next", ";", "}", "System", ".", "out", ".", "println", "(", "\"\"", "+", "forwardListLength", ")", ";", "int", "backwardListLength", "=", "0", ";", "entry", "=", "this", ".", "entryQueueTail", ";", "while", "(", "entry", "!=", "null", ")", "{", "backwardListLength", "++", ";", "entry", "=", "entry", ".", "previous", ";", "}", "System", ".", "out", ".", "println", "(", "\"\"", "+", "backwardListLength", ")", ";", "Enumeration", "keys", "=", "this", ".", "entryTable", ".", "keys", "(", ")", ";", "class", "Temp", "{", "public", "Class", "clazz", ";", "public", "int", "count", ";", "public", "Temp", "(", "Class", "aClass", ")", "{", "this", ".", "clazz", "=", "aClass", ";", "this", ".", "count", "=", "1", ";", "}", "public", "String", "toString", "(", ")", "{", "return", "\"Class:", "\"", "+", "this", ".", "clazz", "+", "\"", "has", "\"", "+", "this", ".", "count", "+", "\"", "entries.\"", ";", "}", "}", "java", ".", "util", ".", "HashMap", "h", "=", "new", "java", ".", "util", ".", "HashMap", "(", ")", ";", "while", "(", "keys", ".", "hasMoreElements", "(", ")", ")", "{", "entry", "=", "(", "LRUCacheEntry", ")", "this", ".", "entryTable", ".", "get", "(", "keys", ".", "nextElement", "(", ")", ")", ";", "Class", "key", "=", "entry", ".", "value", ".", "getClass", "(", ")", ";", "Temp", "t", "=", "(", "Temp", ")", "h", ".", "get", "(", "key", ")", ";", "if", "(", "t", "==", "null", ")", "{", "h", ".", "put", "(", "key", ",", "new", "Temp", "(", "key", ")", ")", ";", "}", "else", "{", "t", ".", "count", "++", ";", "}", "}", "for", "(", "Iterator", "iter", "=", "h", ".", "values", "(", ")", ".", "iterator", "(", ")", ";", "iter", ".", "hasNext", "(", ")", ";", ")", "{", "System", ".", "out", ".", "println", "(", "iter", ".", "next", "(", ")", ")", ";", "}", "}", "protected", "void", "privateRemoveEntry", "(", "LRUCacheEntry", "entry", ",", "boolean", "shuffle", ")", "{", "privateRemoveEntry", "(", "entry", ",", "shuffle", ",", "true", ")", ";", "}", "protected", "void", "privateRemoveEntry", "(", "LRUCacheEntry", "entry", ",", "boolean", "shuffle", ",", "boolean", "external", ")", "{", "if", "(", "!", "shuffle", ")", "{", "if", "(", "external", ")", "{", "this", ".", "entryTable", ".", "remove", "(", "entry", ".", "key", ")", ";", "this", ".", "currentSpace", "-=", "entry", ".", "space", ";", "}", "else", "{", "if", "(", "!", "close", "(", "entry", ")", ")", "return", ";", "if", "(", "this", ".", "entryTable", ".", "get", "(", "entry", ".", "key", ")", "==", "null", ")", "{", "return", ";", "}", "else", "{", "this", ".", "entryTable", ".", "remove", "(", "entry", ".", "key", ")", ";", "this", ".", "currentSpace", "-=", "entry", ".", "space", ";", "}", "}", "}", "LRUCacheEntry", "previous", "=", "entry", ".", "previous", ";", "LRUCacheEntry", "next", "=", "entry", ".", "next", ";", "if", "(", "previous", "==", "null", ")", "{", "this", ".", "entryQueue", "=", "next", ";", "}", "else", "{", "previous", ".", "next", "=", "next", ";", "}", "if", "(", "next", "==", "null", ")", "{", "this", ".", "entryQueueTail", "=", "previous", ";", "}", "else", "{", "next", ".", "previous", "=", "previous", ";", "}", "}", "public", "Object", "put", "(", "Object", "key", ",", "Object", "value", ")", "{", "if", "(", "this", ".", "overflow", ">", "0", ")", "shrink", "(", ")", ";", "int", "newSpace", "=", "spaceFor", "(", "value", ")", ";", "LRUCacheEntry", "entry", "=", "(", "LRUCacheEntry", ")", "this", ".", "entryTable", ".", "get", "(", "key", ")", ";", "if", "(", "entry", "!=", "null", ")", "{", "int", "oldSpace", "=", "entry", ".", "space", ";", "int", "newTotal", "=", "this", ".", "currentSpace", "-", "oldSpace", "+", "newSpace", ";", "if", "(", "newTotal", "<=", "this", ".", "spaceLimit", ")", "{", "updateTimestamp", "(", "entry", ")", ";", "entry", ".", "value", "=", "value", ";", "entry", ".", "space", "=", "newSpace", ";", "this", ".", "currentSpace", "=", "newTotal", ";", "this", ".", "overflow", "=", "0", ";", "return", "value", ";", "}", "else", "{", "privateRemoveEntry", "(", "entry", ",", "false", ",", "false", ")", ";", "}", "}", "makeSpace", "(", "newSpace", ")", ";", "privateAdd", "(", "key", ",", "value", ",", "newSpace", ")", ";", "return", "value", ";", "}", "public", "Object", "remove", "(", "Object", "key", ")", "{", "return", "removeKey", "(", "key", ")", ";", "}", "public", "void", "setLoadFactor", "(", "double", "newLoadFactor", ")", "throws", "IllegalArgumentException", "{", "if", "(", "newLoadFactor", "<=", "1.0", "&&", "newLoadFactor", ">", "0.0", ")", "this", ".", "loadFactor", "=", "newLoadFactor", ";", "else", "throw", "new", "IllegalArgumentException", "(", "Messages", ".", "cache_invalidLoadFactor", ")", ";", "}", "public", "void", "setSpaceLimit", "(", "int", "limit", ")", "{", "if", "(", "limit", "<", "this", ".", "spaceLimit", ")", "{", "makeSpace", "(", "this", ".", "spaceLimit", "-", "limit", ")", ";", "}", "this", ".", "spaceLimit", "=", "limit", ";", "}", "public", "boolean", "shrink", "(", ")", "{", "if", "(", "this", ".", "overflow", ">", "0", ")", "return", "makeSpace", "(", "0", ")", ";", "return", "true", ";", "}", "public", "String", "toString", "(", ")", "{", "return", "toStringFillingRation", "(", "\"\"", ")", "+", "toStringContents", "(", ")", ";", "}", "protected", "void", "updateTimestamp", "(", "LRUCacheEntry", "entry", ")", "{", "if", "(", "this", ".", "timestampsOn", ")", "{", "entry", ".", "timestamp", "=", "this", ".", "timestampCounter", "++", ";", "if", "(", "this", ".", "entryQueue", "!=", "entry", ")", "{", "this", ".", "privateRemoveEntry", "(", "entry", ",", "true", ")", ";", "privateAddEntry", "(", "entry", ",", "true", ")", ";", "}", "}", "}", "}", "</s>" ]
5,503
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IResource", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IPath", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IProgressMonitor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IBuffer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatusConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ToolFactory", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "WorkingCopyOwner", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "util", ".", "ClassFileBytesDisassembler", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "util", ".", "IClassFileReader", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Disassembler", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "ClassFileWorkingCopy", "extends", "CompilationUnit", "{", "public", "ClassFile", "classFile", ";", "public", "ClassFileWorkingCopy", "(", "ClassFile", "classFile", ",", "WorkingCopyOwner", "owner", ")", "{", "super", "(", "(", "PackageFragment", ")", "classFile", ".", "getParent", "(", ")", ",", "(", "(", "BinaryType", ")", "classFile", ".", "getType", "(", ")", ")", ".", "getSourceFileName", "(", "null", ")", ",", "owner", ")", ";", "this", ".", "classFile", "=", "classFile", ";", "}", "public", "void", "commitWorkingCopy", "(", "boolean", "force", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "throw", "new", "JavaModelException", "(", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_ELEMENT_TYPES", ",", "this", ")", ")", ";", "}", "public", "IBuffer", "getBuffer", "(", ")", "throws", "JavaModelException", "{", "if", "(", "isWorkingCopy", "(", ")", ")", "return", "super", ".", "getBuffer", "(", ")", ";", "else", "return", "this", ".", "classFile", ".", "getBuffer", "(", ")", ";", "}", "public", "char", "[", "]", "getContents", "(", ")", "{", "try", "{", "IBuffer", "buffer", "=", "getBuffer", "(", ")", ";", "if", "(", "buffer", "==", "null", ")", "return", "CharOperation", ".", "NO_CHAR", ";", "char", "[", "]", "characters", "=", "buffer", ".", "getCharacters", "(", ")", ";", "if", "(", "characters", "==", "null", ")", "return", "CharOperation", ".", "NO_CHAR", ";", "return", "characters", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "return", "CharOperation", ".", "NO_CHAR", ";", "}", "}", "public", "IPath", "getPath", "(", ")", "{", "return", "this", ".", "classFile", ".", "getPath", "(", ")", ";", "}", "public", "IJavaElement", "getPrimaryElement", "(", "boolean", "checkOwner", ")", "{", "if", "(", "checkOwner", "&&", "isPrimary", "(", ")", ")", "return", "this", ";", "return", "new", "ClassFileWorkingCopy", "(", "this", ".", "classFile", ",", "DefaultWorkingCopyOwner", ".", "PRIMARY", ")", ";", "}", "public", "IResource", "resource", "(", "PackageFragmentRoot", "root", ")", "{", "if", "(", "root", ".", "isArchive", "(", ")", ")", "return", "root", ".", "resource", "(", "root", ")", ";", "return", "this", ".", "classFile", ".", "resource", "(", "root", ")", ";", "}", "protected", "IBuffer", "openBuffer", "(", "IProgressMonitor", "pm", ",", "Object", "info", ")", "throws", "JavaModelException", "{", "IBuffer", "buffer", "=", "this", ".", "owner", ".", "createBuffer", "(", "this", ")", ";", "if", "(", "buffer", "==", "null", ")", "return", "null", ";", "if", "(", "buffer", ".", "getCharacters", "(", ")", "==", "null", ")", "{", "IBuffer", "classFileBuffer", "=", "this", ".", "classFile", ".", "getBuffer", "(", ")", ";", "if", "(", "classFileBuffer", "!=", "null", ")", "{", "buffer", ".", "setContents", "(", "classFileBuffer", ".", "getCharacters", "(", ")", ")", ";", "}", "else", "{", "IClassFileReader", "reader", "=", "ToolFactory", ".", "createDefaultClassFileReader", "(", "this", ".", "classFile", ",", "IClassFileReader", ".", "ALL", ")", ";", "Disassembler", "disassembler", "=", "new", "Disassembler", "(", ")", ";", "String", "contents", "=", "disassembler", ".", "disassemble", "(", "reader", ",", "Util", ".", "getLineSeparator", "(", "\"\"", ",", "getJavaProject", "(", ")", ")", ",", "ClassFileBytesDisassembler", ".", "WORKING_COPY", ")", ";", "buffer", ".", "setContents", "(", "contents", ")", ";", "}", "}", "BufferManager", "bufManager", "=", "getBufferManager", "(", ")", ";", "bufManager", ".", "addBuffer", "(", "buffer", ")", ";", "buffer", ".", "addBufferChangedListener", "(", "this", ")", ";", "return", "buffer", ";", "}", "protected", "void", "toStringName", "(", "StringBuffer", "buffer", ")", "{", "buffer", ".", "append", "(", "this", ".", "classFile", ".", "getElementName", "(", ")", ")", ";", "}", "}", "</s>" ]
5,504
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "util", ".", "*", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "preferences", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaCore", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "formatter", ".", "DefaultCodeFormatterConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CompilerOptions", ";", "public", "class", "JavaCorePreferenceInitializer", "extends", "AbstractPreferenceInitializer", "{", "public", "void", "initializeDefaultPreferences", "(", ")", "{", "HashSet", "optionNames", "=", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "optionNames", ";", "Map", "defaultOptionsMap", "=", "new", "CompilerOptions", "(", ")", ".", "getMap", "(", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "COMPILER_LOCAL_VARIABLE_ATTR", ",", "JavaCore", ".", "GENERATE", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "COMPILER_CODEGEN_UNUSED_LOCAL", ",", "JavaCore", ".", "PRESERVE", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "COMPILER_TASK_TAGS", ",", "JavaCore", ".", "DEFAULT_TASK_TAGS", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "COMPILER_TASK_PRIORITIES", ",", "JavaCore", ".", "DEFAULT_TASK_PRIORITIES", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "COMPILER_TASK_CASE_SENSITIVE", ",", "JavaCore", ".", "ENABLED", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "COMPILER_DOC_COMMENT_SUPPORT", ",", "JavaCore", ".", "ENABLED", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "COMPILER_PB_FORBIDDEN_REFERENCE", ",", "JavaCore", ".", "ERROR", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CORE_JAVA_BUILD_RESOURCE_COPY_FILTER", ",", "\"\"", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CORE_JAVA_BUILD_INVALID_CLASSPATH", ",", "JavaCore", ".", "ABORT", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CORE_JAVA_BUILD_DUPLICATE_RESOURCE", ",", "JavaCore", ".", "WARNING", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CORE_JAVA_BUILD_CLEAN_OUTPUT_FOLDER", ",", "JavaCore", ".", "CLEAN", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CORE_JAVA_BUILD_RECREATE_MODIFIED_CLASS_FILES_IN_OUTPUT_FOLDER", ",", "JavaCore", ".", "IGNORE", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CORE_JAVA_BUILD_ORDER", ",", "JavaCore", ".", "IGNORE", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CORE_INCOMPLETE_CLASSPATH", ",", "JavaCore", ".", "ERROR", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CORE_CIRCULAR_CLASSPATH", ",", "JavaCore", ".", "ERROR", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CORE_INCOMPATIBLE_JDK_LEVEL", ",", "JavaCore", ".", "IGNORE", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CORE_ENABLE_CLASSPATH_EXCLUSION_PATTERNS", ",", "JavaCore", ".", "ENABLED", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CORE_ENABLE_CLASSPATH_MULTIPLE_OUTPUT_LOCATIONS", ",", "JavaCore", ".", "ENABLED", ")", ";", "optionNames", ".", "add", "(", "JavaCore", ".", "CORE_ENCODING", ")", ";", "Map", "codeFormatterOptionsMap", "=", "DefaultCodeFormatterConstants", ".", "getEclipseDefaultSettings", "(", ")", ";", "for", "(", "Iterator", "iter", "=", "codeFormatterOptionsMap", ".", "entrySet", "(", ")", ".", "iterator", "(", ")", ";", "iter", ".", "hasNext", "(", ")", ";", ")", "{", "Map", ".", "Entry", "entry", "=", "(", "Map", ".", "Entry", ")", "iter", ".", "next", "(", ")", ";", "String", "optionName", "=", "(", "String", ")", "entry", ".", "getKey", "(", ")", ";", "defaultOptionsMap", ".", "put", "(", "optionName", ",", "entry", ".", "getValue", "(", ")", ")", ";", "optionNames", ".", "add", "(", "optionName", ")", ";", "}", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_VISIBILITY_CHECK", ",", "JavaCore", ".", "DISABLED", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_DEPRECATION_CHECK", ",", "JavaCore", ".", "DISABLED", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_IMPLICIT_QUALIFICATION", ",", "JavaCore", ".", "DISABLED", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_FIELD_PREFIXES", ",", "\"\"", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_STATIC_FIELD_PREFIXES", ",", "\"\"", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_STATIC_FINAL_FIELD_PREFIXES", ",", "\"\"", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_LOCAL_PREFIXES", ",", "\"\"", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_ARGUMENT_PREFIXES", ",", "\"\"", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_FIELD_SUFFIXES", ",", "\"\"", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_STATIC_FIELD_SUFFIXES", ",", "\"\"", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_STATIC_FINAL_FIELD_SUFFIXES", ",", "\"\"", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_LOCAL_SUFFIXES", ",", "\"\"", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_ARGUMENT_SUFFIXES", ",", "\"\"", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_FORBIDDEN_REFERENCE_CHECK", ",", "JavaCore", ".", "ENABLED", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_DISCOURAGED_REFERENCE_CHECK", ",", "JavaCore", ".", "DISABLED", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_CAMEL_CASE_MATCH", ",", "JavaCore", ".", "ENABLED", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "CODEASSIST_SUGGEST_STATIC_IMPORTS", ",", "JavaCore", ".", "ENABLED", ")", ";", "defaultOptionsMap", ".", "put", "(", "JavaCore", ".", "TIMEOUT_FOR_PARAMETER_NAME_FROM_ATTACHED_JAVADOC", ",", "\"50\"", ")", ";", "IEclipsePreferences", "defaultPreferences", "=", "(", "(", "IScopeContext", ")", "new", "DefaultScope", "(", ")", ")", ".", "getNode", "(", "JavaCore", ".", "PLUGIN_ID", ")", ";", "for", "(", "Iterator", "iter", "=", "defaultOptionsMap", ".", "entrySet", "(", ")", ".", "iterator", "(", ")", ";", "iter", ".", "hasNext", "(", ")", ";", ")", "{", "Map", ".", "Entry", "entry", "=", "(", "Map", ".", "Entry", ")", "iter", ".", "next", "(", ")", ";", "String", "optionName", "=", "(", "String", ")", "entry", ".", "getKey", "(", ")", ";", "defaultPreferences", ".", "put", "(", "optionName", ",", "(", "String", ")", "entry", ".", "getValue", "(", ")", ")", ";", "optionNames", ".", "add", "(", "optionName", ")", ";", "}", "}", "}", "</s>" ]
5,505
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "public", "class", "SourceFieldWithChildrenInfo", "extends", "SourceFieldElementInfo", "{", "protected", "IJavaElement", "[", "]", "children", ";", "public", "SourceFieldWithChildrenInfo", "(", "IJavaElement", "[", "]", "children", ")", "{", "this", ".", "children", "=", "children", ";", "}", "public", "IJavaElement", "[", "]", "getChildren", "(", ")", "{", "return", "this", ".", "children", ";", "}", "}", "</s>" ]
5,506
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IStatus", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IImportDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatus", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatusConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaProject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IType", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaConventions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaCore", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "AST", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "ASTNode", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "CompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "Name", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "PackageDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "StructuralPropertyDescriptor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "rewrite", ".", "ASTRewrite", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Messages", ";", "public", "class", "CreatePackageDeclarationOperation", "extends", "CreateElementInCUOperation", "{", "protected", "String", "name", "=", "null", ";", "public", "CreatePackageDeclarationOperation", "(", "String", "name", ",", "ICompilationUnit", "parentElement", ")", "{", "super", "(", "parentElement", ")", ";", "this", ".", "name", "=", "name", ";", "}", "protected", "StructuralPropertyDescriptor", "getChildPropertyDescriptor", "(", "ASTNode", "parent", ")", "{", "return", "CompilationUnit", ".", "PACKAGE_PROPERTY", ";", "}", "protected", "ASTNode", "generateElementAST", "(", "ASTRewrite", "rewriter", ",", "ICompilationUnit", "cu", ")", "throws", "JavaModelException", "{", "IJavaElement", "[", "]", "children", "=", "getCompilationUnit", "(", ")", ".", "getChildren", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "children", ".", "length", ";", "i", "++", ")", "{", "if", "(", "children", "[", "i", "]", ".", "getElementType", "(", ")", "==", "IJavaElement", ".", "PACKAGE_DECLARATION", "&&", "this", ".", "name", ".", "equals", "(", "children", "[", "i", "]", ".", "getElementName", "(", ")", ")", ")", "{", "this", ".", "creationOccurred", "=", "false", ";", "return", "null", ";", "}", "}", "AST", "ast", "=", "this", ".", "cuAST", ".", "getAST", "(", ")", ";", "PackageDeclaration", "pkgDeclaration", "=", "ast", ".", "newPackageDeclaration", "(", ")", ";", "Name", "astName", "=", "ast", ".", "newName", "(", "this", ".", "name", ")", ";", "pkgDeclaration", ".", "setName", "(", "astName", ")", ";", "return", "pkgDeclaration", ";", "}", "protected", "IJavaElement", "generateResultHandle", "(", ")", "{", "return", "getCompilationUnit", "(", ")", ".", "getPackageDeclaration", "(", "this", ".", "name", ")", ";", "}", "public", "String", "getMainTaskName", "(", ")", "{", "return", "Messages", ".", "operation_createPackageProgress", ";", "}", "protected", "void", "initializeDefaultPosition", "(", ")", "{", "try", "{", "ICompilationUnit", "cu", "=", "getCompilationUnit", "(", ")", ";", "IImportDeclaration", "[", "]", "imports", "=", "cu", ".", "getImports", "(", ")", ";", "if", "(", "imports", ".", "length", ">", "0", ")", "{", "createBefore", "(", "imports", "[", "0", "]", ")", ";", "return", ";", "}", "IType", "[", "]", "types", "=", "cu", ".", "getTypes", "(", ")", ";", "if", "(", "types", ".", "length", ">", "0", ")", "{", "createBefore", "(", "types", "[", "0", "]", ")", ";", "return", ";", "}", "}", "catch", "(", "JavaModelException", "e", ")", "{", "}", "}", "public", "IJavaModelStatus", "verify", "(", ")", "{", "IJavaModelStatus", "status", "=", "super", ".", "verify", "(", ")", ";", "if", "(", "!", "status", ".", "isOK", "(", ")", ")", "{", "return", "status", ";", "}", "IJavaProject", "project", "=", "getParentElement", "(", ")", ".", "getJavaProject", "(", ")", ";", "if", "(", "JavaConventions", ".", "validatePackageName", "(", "this", ".", "name", ",", "project", ".", "getOption", "(", "JavaCore", ".", "COMPILER_SOURCE", ",", "true", ")", ",", "project", ".", "getOption", "(", "JavaCore", ".", "COMPILER_COMPLIANCE", ",", "true", ")", ")", ".", "getSeverity", "(", ")", "==", "IStatus", ".", "ERROR", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_NAME", ",", "this", ".", "name", ")", ";", "}", "return", "JavaModelStatus", ".", "VERIFIED_OK", ";", "}", "}", "</s>" ]
5,507
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "io", ".", "InputStream", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Assert", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IProgressMonitor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "search", ".", "SearchEngine", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "codeassist", ".", "CompletionEngine", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "Binding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "hierarchy", ".", "TypeHierarchy", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "MementoTokenizer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Messages", ";", "public", "class", "SourceType", "extends", "NamedMember", "implements", "IType", "{", "protected", "SourceType", "(", "JavaElement", "parent", ",", "String", "name", ")", "{", "super", "(", "parent", ",", "name", ")", ";", "}", "protected", "void", "closing", "(", "Object", "info", ")", "throws", "JavaModelException", "{", "super", ".", "closing", "(", "info", ")", ";", "SourceTypeElementInfo", "elementInfo", "=", "(", "SourceTypeElementInfo", ")", "info", ";", "ITypeParameter", "[", "]", "typeParameters", "=", "elementInfo", ".", "typeParameters", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "typeParameters", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "(", "(", "TypeParameter", ")", "typeParameters", "[", "i", "]", ")", ".", "close", "(", ")", ";", "}", "}", "public", "void", "codeComplete", "(", "char", "[", "]", "snippet", ",", "int", "insertion", ",", "int", "position", ",", "char", "[", "]", "[", "]", "localVariableTypeNames", ",", "char", "[", "]", "[", "]", "localVariableNames", ",", "int", "[", "]", "localVariableModifiers", ",", "boolean", "isStatic", ",", "ICompletionRequestor", "requestor", ")", "throws", "JavaModelException", "{", "codeComplete", "(", "snippet", ",", "insertion", ",", "position", ",", "localVariableTypeNames", ",", "localVariableNames", ",", "localVariableModifiers", ",", "isStatic", ",", "requestor", ",", "DefaultWorkingCopyOwner", ".", "PRIMARY", ")", ";", "}", "public", "void", "codeComplete", "(", "char", "[", "]", "snippet", ",", "int", "insertion", ",", "int", "position", ",", "char", "[", "]", "[", "]", "localVariableTypeNames", ",", "char", "[", "]", "[", "]", "localVariableNames", ",", "int", "[", "]", "localVariableModifiers", ",", "boolean", "isStatic", ",", "ICompletionRequestor", "requestor", ",", "WorkingCopyOwner", "owner", ")", "throws", "JavaModelException", "{", "if", "(", "requestor", "==", "null", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"\"", ")", ";", "}", "codeComplete", "(", "snippet", ",", "insertion", ",", "position", ",", "localVariableTypeNames", ",", "localVariableNames", ",", "localVariableModifiers", ",", "isStatic", ",", "new", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "codeassist", ".", "CompletionRequestorWrapper", "(", "requestor", ")", ",", "owner", ")", ";", "}", "public", "void", "codeComplete", "(", "char", "[", "]", "snippet", ",", "int", "insertion", ",", "int", "position", ",", "char", "[", "]", "[", "]", "localVariableTypeNames", ",", "char", "[", "]", "[", "]", "localVariableNames", ",", "int", "[", "]", "localVariableModifiers", ",", "boolean", "isStatic", ",", "CompletionRequestor", "requestor", ")", "throws", "JavaModelException", "{", "codeComplete", "(", "snippet", ",", "insertion", ",", "position", ",", "localVariableTypeNames", ",", "localVariableNames", ",", "localVariableModifiers", ",", "isStatic", ",", "requestor", ",", "DefaultWorkingCopyOwner", ".", "PRIMARY", ")", ";", "}", "public", "void", "codeComplete", "(", "char", "[", "]", "snippet", ",", "int", "insertion", ",", "int", "position", ",", "char", "[", "]", "[", "]", "localVariableTypeNames", ",", "char", "[", "]", "[", "]", "localVariableNames", ",", "int", "[", "]", "localVariableModifiers", ",", "boolean", "isStatic", ",", "CompletionRequestor", "requestor", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "codeComplete", "(", "snippet", ",", "insertion", ",", "position", ",", "localVariableTypeNames", ",", "localVariableNames", ",", "localVariableModifiers", ",", "isStatic", ",", "requestor", ",", "DefaultWorkingCopyOwner", ".", "PRIMARY", ",", "monitor", ")", ";", "}", "public", "void", "codeComplete", "(", "char", "[", "]", "snippet", ",", "int", "insertion", ",", "int", "position", ",", "char", "[", "]", "[", "]", "localVariableTypeNames", ",", "char", "[", "]", "[", "]", "localVariableNames", ",", "int", "[", "]", "localVariableModifiers", ",", "boolean", "isStatic", ",", "CompletionRequestor", "requestor", ",", "WorkingCopyOwner", "owner", ")", "throws", "JavaModelException", "{", "codeComplete", "(", "snippet", ",", "insertion", ",", "position", ",", "localVariableTypeNames", ",", "localVariableNames", ",", "localVariableModifiers", ",", "isStatic", ",", "requestor", ",", "owner", ",", "null", ")", ";", "}", "public", "void", "codeComplete", "(", "char", "[", "]", "snippet", ",", "int", "insertion", ",", "int", "position", ",", "char", "[", "]", "[", "]", "localVariableTypeNames", ",", "char", "[", "]", "[", "]", "localVariableNames", ",", "int", "[", "]", "localVariableModifiers", ",", "boolean", "isStatic", ",", "CompletionRequestor", "requestor", ",", "WorkingCopyOwner", "owner", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "if", "(", "requestor", "==", "null", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"\"", ")", ";", "}", "JavaProject", "project", "=", "(", "JavaProject", ")", "getJavaProject", "(", ")", ";", "SearchableEnvironment", "environment", "=", "project", ".", "newSearchableNameEnvironment", "(", "owner", ")", ";", "CompletionEngine", "engine", "=", "new", "CompletionEngine", "(", "environment", ",", "requestor", ",", "project", ".", "getOptions", "(", "true", ")", ",", "project", ",", "owner", ",", "monitor", ")", ";", "String", "source", "=", "getCompilationUnit", "(", ")", ".", "getSource", "(", ")", ";", "if", "(", "source", "!=", "null", "&&", "insertion", ">", "-", "1", "&&", "insertion", "<", "source", ".", "length", "(", ")", ")", "{", "char", "[", "]", "prefix", "=", "CharOperation", ".", "concat", "(", "source", ".", "substring", "(", "0", ",", "insertion", ")", ".", "toCharArray", "(", ")", ",", "new", "char", "[", "]", "{", "'{'", "}", ")", ";", "char", "[", "]", "suffix", "=", "CharOperation", ".", "concat", "(", "new", "char", "[", "]", "{", "'}'", "}", ",", "source", ".", "substring", "(", "insertion", ")", ".", "toCharArray", "(", ")", ")", ";", "char", "[", "]", "fakeSource", "=", "CharOperation", ".", "concat", "(", "prefix", ",", "snippet", ",", "suffix", ")", ";", "BasicCompilationUnit", "cu", "=", "new", "BasicCompilationUnit", "(", "fakeSource", ",", "null", ",", "getElementName", "(", ")", ",", "getParent", "(", ")", ")", ";", "engine", ".", "complete", "(", "cu", ",", "prefix", ".", "length", "+", "position", ",", "prefix", ".", "length", ",", "null", ")", ";", "}", "else", "{", "engine", ".", "complete", "(", "this", ",", "snippet", ",", "position", ",", "localVariableTypeNames", ",", "localVariableNames", ",", "localVariableModifiers", ",", "isStatic", ")", ";", "}", "if", "(", "NameLookup", ".", "VERBOSE", ")", "{", "System", ".", "out", ".", "println", "(", "Thread", ".", "currentThread", "(", ")", "+", "\"\"", "+", "environment", ".", "nameLookup", ".", "timeSpentInSeekTypesInSourcePackage", "+", "\"ms\"", ")", ";", "System", ".", "out", ".", "println", "(", "Thread", ".", "currentThread", "(", ")", "+", "\"\"", "+", "environment", ".", "nameLookup", ".", "timeSpentInSeekTypesInBinaryPackage", "+", "\"ms\"", ")", ";", "}", "}", "public", "IField", "createField", "(", "String", "contents", ",", "IJavaElement", "sibling", ",", "boolean", "force", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "CreateFieldOperation", "op", "=", "new", "CreateFieldOperation", "(", "this", ",", "contents", ",", "force", ")", ";", "if", "(", "sibling", "!=", "null", ")", "{", "op", ".", "createBefore", "(", "sibling", ")", ";", "}", "op", ".", "runOperation", "(", "monitor", ")", ";", "return", "(", "IField", ")", "op", ".", "getResultElements", "(", ")", "[", "0", "]", ";", "}", "public", "IInitializer", "createInitializer", "(", "String", "contents", ",", "IJavaElement", "sibling", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "CreateInitializerOperation", "op", "=", "new", "CreateInitializerOperation", "(", "this", ",", "contents", ")", ";", "if", "(", "sibling", "!=", "null", ")", "{", "op", ".", "createBefore", "(", "sibling", ")", ";", "}", "op", ".", "runOperation", "(", "monitor", ")", ";", "return", "(", "IInitializer", ")", "op", ".", "getResultElements", "(", ")", "[", "0", "]", ";", "}", "public", "IMethod", "createMethod", "(", "String", "contents", ",", "IJavaElement", "sibling", ",", "boolean", "force", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "CreateMethodOperation", "op", "=", "new", "CreateMethodOperation", "(", "this", ",", "contents", ",", "force", ")", ";", "if", "(", "sibling", "!=", "null", ")", "{", "op", ".", "createBefore", "(", "sibling", ")", ";", "}", "op", ".", "runOperation", "(", "monitor", ")", ";", "return", "(", "IMethod", ")", "op", ".", "getResultElements", "(", ")", "[", "0", "]", ";", "}", "public", "IType", "createType", "(", "String", "contents", ",", "IJavaElement", "sibling", ",", "boolean", "force", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "CreateTypeOperation", "op", "=", "new", "CreateTypeOperation", "(", "this", ",", "contents", ",", "force", ")", ";", "if", "(", "sibling", "!=", "null", ")", "{", "op", ".", "createBefore", "(", "sibling", ")", ";", "}", "op", ".", "runOperation", "(", "monitor", ")", ";", "return", "(", "IType", ")", "op", ".", "getResultElements", "(", ")", "[", "0", "]", ";", "}", "public", "boolean", "equals", "(", "Object", "o", ")", "{", "if", "(", "!", "(", "o", "instanceof", "SourceType", ")", ")", "return", "false", ";", "return", "super", ".", "equals", "(", "o", ")", ";", "}", "public", "IMethod", "[", "]", "findMethods", "(", "IMethod", "method", ")", "{", "try", "{", "return", "findMethods", "(", "method", ",", "getMethods", "(", ")", ")", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "return", "null", ";", "}", "}", "public", "IAnnotation", "[", "]", "getAnnotations", "(", ")", "throws", "JavaModelException", "{", "AnnotatableInfo", "info", "=", "(", "AnnotatableInfo", ")", "getElementInfo", "(", ")", ";", "return", "info", ".", "annotations", ";", "}", "public", "IJavaElement", "[", "]", "getChildrenForCategory", "(", "String", "category", ")", "throws", "JavaModelException", "{", "IJavaElement", "[", "]", "children", "=", "getChildren", "(", ")", ";", "int", "length", "=", "children", ".", "length", ";", "if", "(", "length", "==", "0", ")", "return", "NO_ELEMENTS", ";", "SourceTypeElementInfo", "info", "=", "(", "SourceTypeElementInfo", ")", "getElementInfo", "(", ")", ";", "HashMap", "categories", "=", "info", ".", "getCategories", "(", ")", ";", "if", "(", "categories", "==", "null", ")", "return", "NO_ELEMENTS", ";", "IJavaElement", "[", "]", "result", "=", "new", "IJavaElement", "[", "length", "]", ";", "int", "index", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "IJavaElement", "child", "=", "children", "[", "i", "]", ";", "String", "[", "]", "elementCategories", "=", "(", "String", "[", "]", ")", "categories", ".", "get", "(", "child", ")", ";", "if", "(", "elementCategories", "!=", "null", ")", "for", "(", "int", "j", "=", "0", ",", "length2", "=", "elementCategories", ".", "length", ";", "j", "<", "length2", ";", "j", "++", ")", "{", "if", "(", "elementCategories", "[", "j", "]", ".", "equals", "(", "category", ")", ")", "result", "[", "index", "++", "]", "=", "child", ";", "}", "}", "if", "(", "index", "==", "0", ")", "return", "NO_ELEMENTS", ";", "if", "(", "index", "<", "length", ")", "System", ".", "arraycopy", "(", "result", ",", "0", ",", "result", "=", "new", "IJavaElement", "[", "index", "]", ",", "0", ",", "index", ")", ";", "return", "result", ";", "}", "public", "IType", "getDeclaringType", "(", ")", "{", "IJavaElement", "parentElement", "=", "getParent", "(", ")", ";", "while", "(", "parentElement", "!=", "null", ")", "{", "if", "(", "parentElement", ".", "getElementType", "(", ")", "==", "IJavaElement", ".", "TYPE", ")", "{", "return", "(", "IType", ")", "parentElement", ";", "}", "else", "if", "(", "parentElement", "instanceof", "IMember", ")", "{", "parentElement", "=", "parentElement", ".", "getParent", "(", ")", ";", "}", "else", "{", "return", "null", ";", "}", "}", "return", "null", ";", "}", "public", "int", "getElementType", "(", ")", "{", "return", "TYPE", ";", "}", "public", "IField", "getField", "(", "String", "fieldName", ")", "{", "return", "new", "SourceField", "(", "this", ",", "fieldName", ")", ";", "}", "public", "IField", "[", "]", "getFields", "(", ")", "throws", "JavaModelException", "{", "ArrayList", "list", "=", "getChildrenOfType", "(", "FIELD", ")", ";", "IField", "[", "]", "array", "=", "new", "IField", "[", "list", ".", "size", "(", ")", "]", ";", "list", ".", "toArray", "(", "array", ")", ";", "return", "array", ";", "}", "public", "String", "getFullyQualifiedName", "(", ")", "{", "return", "this", ".", "getFullyQualifiedName", "(", "'$'", ")", ";", "}", "public", "String", "getFullyQualifiedName", "(", "char", "enclosingTypeSeparator", ")", "{", "try", "{", "return", "getFullyQualifiedName", "(", "enclosingTypeSeparator", ",", "false", ")", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "return", "null", ";", "}", "}", "public", "String", "getFullyQualifiedParameterizedName", "(", ")", "throws", "JavaModelException", "{", "return", "getFullyQualifiedName", "(", "'.'", ",", "true", ")", ";", "}", "public", "IJavaElement", "getHandleFromMemento", "(", "String", "token", ",", "MementoTokenizer", "memento", ",", "WorkingCopyOwner", "workingCopyOwner", ")", "{", "switch", "(", "token", ".", "charAt", "(", "0", ")", ")", "{", "case", "JEM_COUNT", ":", "return", "getHandleUpdatingCountFromMemento", "(", "memento", ",", "workingCopyOwner", ")", ";", "case", "JEM_FIELD", ":", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "String", "fieldName", "=", "memento", ".", "nextToken", "(", ")", ";", "JavaElement", "field", "=", "(", "JavaElement", ")", "getField", "(", "fieldName", ")", ";", "return", "field", ".", "getHandleFromMemento", "(", "memento", ",", "workingCopyOwner", ")", ";", "case", "JEM_INITIALIZER", ":", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "String", "count", "=", "memento", ".", "nextToken", "(", ")", ";", "JavaElement", "initializer", "=", "(", "JavaElement", ")", "getInitializer", "(", "Integer", ".", "parseInt", "(", "count", ")", ")", ";", "return", "initializer", ".", "getHandleFromMemento", "(", "memento", ",", "workingCopyOwner", ")", ";", "case", "JEM_METHOD", ":", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "String", "selector", "=", "memento", ".", "nextToken", "(", ")", ";", "ArrayList", "params", "=", "new", "ArrayList", "(", ")", ";", "nextParam", ":", "while", "(", "memento", ".", "hasMoreTokens", "(", ")", ")", "{", "token", "=", "memento", ".", "nextToken", "(", ")", ";", "switch", "(", "token", ".", "charAt", "(", "0", ")", ")", "{", "case", "JEM_TYPE", ":", "case", "JEM_TYPE_PARAMETER", ":", "case", "JEM_ANNOTATION", ":", "break", "nextParam", ";", "case", "JEM_METHOD", ":", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "String", "param", "=", "memento", ".", "nextToken", "(", ")", ";", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", ")", ";", "while", "(", "param", ".", "length", "(", ")", "==", "1", "&&", "Signature", ".", "C_ARRAY", "==", "param", ".", "charAt", "(", "0", ")", ")", "{", "buffer", ".", "append", "(", "Signature", ".", "C_ARRAY", ")", ";", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "param", "=", "memento", ".", "nextToken", "(", ")", ";", "}", "params", ".", "add", "(", "buffer", ".", "toString", "(", ")", "+", "param", ")", ";", "break", ";", "default", ":", "break", "nextParam", ";", "}", "}", "String", "[", "]", "parameters", "=", "new", "String", "[", "params", ".", "size", "(", ")", "]", ";", "params", ".", "toArray", "(", "parameters", ")", ";", "JavaElement", "method", "=", "(", "JavaElement", ")", "getMethod", "(", "selector", ",", "parameters", ")", ";", "switch", "(", "token", ".", "charAt", "(", "0", ")", ")", "{", "case", "JEM_TYPE", ":", "case", "JEM_TYPE_PARAMETER", ":", "case", "JEM_LOCALVARIABLE", ":", "case", "JEM_ANNOTATION", ":", "return", "method", ".", "getHandleFromMemento", "(", "token", ",", "memento", ",", "workingCopyOwner", ")", ";", "default", ":", "return", "method", ";", "}", "case", "JEM_TYPE", ":", "String", "typeName", ";", "if", "(", "memento", ".", "hasMoreTokens", "(", ")", ")", "{", "typeName", "=", "memento", ".", "nextToken", "(", ")", ";", "char", "firstChar", "=", "typeName", ".", "charAt", "(", "0", ")", ";", "if", "(", "firstChar", "==", "JEM_FIELD", "||", "firstChar", "==", "JEM_INITIALIZER", "||", "firstChar", "==", "JEM_METHOD", "||", "firstChar", "==", "JEM_TYPE", "||", "firstChar", "==", "JEM_COUNT", ")", "{", "token", "=", "typeName", ";", "typeName", "=", "\"\"", ";", "}", "else", "{", "token", "=", "null", ";", "}", "}", "else", "{", "typeName", "=", "\"\"", ";", "token", "=", "null", ";", "}", "JavaElement", "type", "=", "(", "JavaElement", ")", "getType", "(", "typeName", ")", ";", "if", "(", "token", "==", "null", ")", "{", "return", "type", ".", "getHandleFromMemento", "(", "memento", ",", "workingCopyOwner", ")", ";", "}", "else", "{", "return", "type", ".", "getHandleFromMemento", "(", "token", ",", "memento", ",", "workingCopyOwner", ")", ";", "}", "case", "JEM_TYPE_PARAMETER", ":", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "String", "typeParameterName", "=", "memento", ".", "nextToken", "(", ")", ";", "JavaElement", "typeParameter", "=", "new", "TypeParameter", "(", "this", ",", "typeParameterName", ")", ";", "return", "typeParameter", ".", "getHandleFromMemento", "(", "memento", ",", "workingCopyOwner", ")", ";", "case", "JEM_ANNOTATION", ":", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "String", "annotationName", "=", "memento", ".", "nextToken", "(", ")", ";", "JavaElement", "annotation", "=", "new", "Annotation", "(", "this", ",", "annotationName", ")", ";", "return", "annotation", ".", "getHandleFromMemento", "(", "memento", ",", "workingCopyOwner", ")", ";", "}", "return", "null", ";", "}", "public", "IInitializer", "getInitializer", "(", "int", "count", ")", "{", "return", "new", "Initializer", "(", "this", ",", "count", ")", ";", "}", "public", "IInitializer", "[", "]", "getInitializers", "(", ")", "throws", "JavaModelException", "{", "ArrayList", "list", "=", "getChildrenOfType", "(", "INITIALIZER", ")", ";", "IInitializer", "[", "]", "array", "=", "new", "IInitializer", "[", "list", ".", "size", "(", ")", "]", ";", "list", ".", "toArray", "(", "array", ")", ";", "return", "array", ";", "}", "public", "String", "getKey", "(", ")", "{", "try", "{", "return", "getKey", "(", "this", ",", "false", ")", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "return", "null", ";", "}", "}", "public", "IMethod", "getMethod", "(", "String", "selector", ",", "String", "[", "]", "parameterTypeSignatures", ")", "{", "return", "new", "SourceMethod", "(", "this", ",", "selector", ",", "parameterTypeSignatures", ")", ";", "}", "public", "IMethod", "[", "]", "getMethods", "(", ")", "throws", "JavaModelException", "{", "ArrayList", "list", "=", "getChildrenOfType", "(", "METHOD", ")", ";", "IMethod", "[", "]", "array", "=", "new", "IMethod", "[", "list", ".", "size", "(", ")", "]", ";", "list", ".", "toArray", "(", "array", ")", ";", "return", "array", ";", "}", "public", "IPackageFragment", "getPackageFragment", "(", ")", "{", "IJavaElement", "parentElement", "=", "this", ".", "parent", ";", "while", "(", "parentElement", "!=", "null", ")", "{", "if", "(", "parentElement", ".", "getElementType", "(", ")", "==", "IJavaElement", ".", "PACKAGE_FRAGMENT", ")", "{", "return", "(", "IPackageFragment", ")", "parentElement", ";", "}", "else", "{", "parentElement", "=", "parentElement", ".", "getParent", "(", ")", ";", "}", "}", "Assert", ".", "isTrue", "(", "false", ")", ";", "return", "null", ";", "}", "public", "IJavaElement", "getPrimaryElement", "(", "boolean", "checkOwner", ")", "{", "if", "(", "checkOwner", ")", "{", "CompilationUnit", "cu", "=", "(", "CompilationUnit", ")", "getAncestor", "(", "COMPILATION_UNIT", ")", ";", "if", "(", "cu", ".", "isPrimary", "(", ")", ")", "return", "this", ";", "}", "IJavaElement", "primaryParent", "=", "this", ".", "parent", ".", "getPrimaryElement", "(", "false", ")", ";", "switch", "(", "primaryParent", ".", "getElementType", "(", ")", ")", "{", "case", "IJavaElement", ".", "COMPILATION_UNIT", ":", "return", "(", "(", "ICompilationUnit", ")", "primaryParent", ")", ".", "getType", "(", "this", ".", "name", ")", ";", "case", "IJavaElement", ".", "TYPE", ":", "return", "(", "(", "IType", ")", "primaryParent", ")", ".", "getType", "(", "this", ".", "name", ")", ";", "case", "IJavaElement", ".", "FIELD", ":", "case", "IJavaElement", ".", "INITIALIZER", ":", "case", "IJavaElement", ".", "METHOD", ":", "return", "(", "(", "IMember", ")", "primaryParent", ")", ".", "getType", "(", "this", ".", "name", ",", "this", ".", "occurrenceCount", ")", ";", "}", "return", "this", ";", "}", "public", "String", "getSuperclassName", "(", ")", "throws", "JavaModelException", "{", "SourceTypeElementInfo", "info", "=", "(", "SourceTypeElementInfo", ")", "getElementInfo", "(", ")", ";", "char", "[", "]", "superclassName", "=", "info", ".", "getSuperclassName", "(", ")", ";", "if", "(", "superclassName", "==", "null", ")", "{", "return", "null", ";", "}", "return", "new", "String", "(", "superclassName", ")", ";", "}", "public", "String", "getSuperclassTypeSignature", "(", ")", "throws", "JavaModelException", "{", "SourceTypeElementInfo", "info", "=", "(", "SourceTypeElementInfo", ")", "getElementInfo", "(", ")", ";", "char", "[", "]", "superclassName", "=", "info", ".", "getSuperclassName", "(", ")", ";", "if", "(", "superclassName", "==", "null", ")", "{", "return", "null", ";", "}", "return", "new", "String", "(", "Signature", ".", "createTypeSignature", "(", "superclassName", ",", "false", ")", ")", ";", "}", "public", "String", "[", "]", "getSuperInterfaceNames", "(", ")", "throws", "JavaModelException", "{", "SourceTypeElementInfo", "info", "=", "(", "SourceTypeElementInfo", ")", "getElementInfo", "(", ")", ";", "char", "[", "]", "[", "]", "names", "=", "info", ".", "getInterfaceNames", "(", ")", ";", "return", "CharOperation", ".", "toStrings", "(", "names", ")", ";", "}", "public", "String", "[", "]", "getSuperInterfaceTypeSignatures", "(", ")", "throws", "JavaModelException", "{", "SourceTypeElementInfo", "info", "=", "(", "SourceTypeElementInfo", ")", "getElementInfo", "(", ")", ";", "char", "[", "]", "[", "]", "names", "=", "info", ".", "getInterfaceNames", "(", ")", ";", "if", "(", "names", "==", "null", ")", "{", "return", "CharOperation", ".", "NO_STRINGS", ";", "}", "String", "[", "]", "strings", "=", "new", "String", "[", "names", ".", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "names", ".", "length", ";", "i", "++", ")", "{", "strings", "[", "i", "]", "=", "new", "String", "(", "Signature", ".", "createTypeSignature", "(", "names", "[", "i", "]", ",", "false", ")", ")", ";", "}", "return", "strings", ";", "}", "public", "ITypeParameter", "[", "]", "getTypeParameters", "(", ")", "throws", "JavaModelException", "{", "SourceTypeElementInfo", "info", "=", "(", "SourceTypeElementInfo", ")", "getElementInfo", "(", ")", ";", "return", "info", ".", "typeParameters", ";", "}", "public", "String", "[", "]", "getTypeParameterSignatures", "(", ")", "throws", "JavaModelException", "{", "ITypeParameter", "[", "]", "typeParameters", "=", "getTypeParameters", "(", ")", ";", "int", "length", "=", "typeParameters", ".", "length", ";", "String", "[", "]", "typeParameterSignatures", "=", "new", "String", "[", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeParameter", "typeParameter", "=", "(", "TypeParameter", ")", "typeParameters", "[", "i", "]", ";", "TypeParameterElementInfo", "info", "=", "(", "TypeParameterElementInfo", ")", "typeParameter", ".", "getElementInfo", "(", ")", ";", "char", "[", "]", "[", "]", "bounds", "=", "info", ".", "bounds", ";", "if", "(", "bounds", "==", "null", ")", "{", "typeParameterSignatures", "[", "i", "]", "=", "Signature", ".", "createTypeParameterSignature", "(", "typeParameter", ".", "getElementName", "(", ")", ",", "CharOperation", ".", "NO_STRINGS", ")", ";", "}", "else", "{", "int", "boundsLength", "=", "bounds", ".", "length", ";", "char", "[", "]", "[", "]", "boundSignatures", "=", "new", "char", "[", "boundsLength", "]", "[", "]", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "boundsLength", ";", "j", "++", ")", "{", "boundSignatures", "[", "j", "]", "=", "Signature", ".", "createCharArrayTypeSignature", "(", "bounds", "[", "j", "]", ",", "false", ")", ";", "}", "typeParameterSignatures", "[", "i", "]", "=", "new", "String", "(", "Signature", ".", "createTypeParameterSignature", "(", "typeParameter", ".", "getElementName", "(", ")", ".", "toCharArray", "(", ")", ",", "boundSignatures", ")", ")", ";", "}", "}", "return", "typeParameterSignatures", ";", "}", "public", "IType", "getType", "(", "String", "typeName", ")", "{", "return", "new", "SourceType", "(", "this", ",", "typeName", ")", ";", "}", "public", "ITypeParameter", "getTypeParameter", "(", "String", "typeParameterName", ")", "{", "return", "new", "TypeParameter", "(", "this", ",", "typeParameterName", ")", ";", "}", "public", "String", "getTypeQualifiedName", "(", ")", "{", "return", "this", ".", "getTypeQualifiedName", "(", "'$'", ")", ";", "}", "public", "String", "getTypeQualifiedName", "(", "char", "enclosingTypeSeparator", ")", "{", "try", "{", "return", "getTypeQualifiedName", "(", "enclosingTypeSeparator", ",", "false", ")", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "return", "null", ";", "}", "}", "public", "IType", "[", "]", "getTypes", "(", ")", "throws", "JavaModelException", "{", "ArrayList", "list", "=", "getChildrenOfType", "(", "TYPE", ")", ";", "IType", "[", "]", "array", "=", "new", "IType", "[", "list", ".", "size", "(", ")", "]", ";", "list", ".", "toArray", "(", "array", ")", ";", "return", "array", ";", "}", "public", "boolean", "isAnonymous", "(", ")", "{", "return", "this", ".", "name", ".", "length", "(", ")", "==", "0", ";", "}", "public", "boolean", "isClass", "(", ")", "throws", "JavaModelException", "{", "SourceTypeElementInfo", "info", "=", "(", "SourceTypeElementInfo", ")", "getElementInfo", "(", ")", ";", "return", "TypeDeclaration", ".", "kind", "(", "info", ".", "getModifiers", "(", ")", ")", "==", "TypeDeclaration", ".", "CLASS_DECL", ";", "}", "public", "boolean", "isEnum", "(", ")", "throws", "JavaModelException", "{", "SourceTypeElementInfo", "info", "=", "(", "SourceTypeElementInfo", ")", "getElementInfo", "(", ")", ";", "return", "TypeDeclaration", ".", "kind", "(", "info", ".", "getModifiers", "(", ")", ")", "==", "TypeDeclaration", ".", "ENUM_DECL", ";", "}", "public", "boolean", "isInterface", "(", ")", "throws", "JavaModelException", "{", "SourceTypeElementInfo", "info", "=", "(", "SourceTypeElementInfo", ")", "getElementInfo", "(", ")", ";", "switch", "(", "TypeDeclaration", ".", "kind", "(", "info", ".", "getModifiers", "(", ")", ")", ")", "{", "case", "TypeDeclaration", ".", "INTERFACE_DECL", ":", "case", "TypeDeclaration", ".", "ANNOTATION_TYPE_DECL", ":", "return", "true", ";", "}", "return", "false", ";", "}", "public", "boolean", "isAnnotation", "(", ")", "throws", "JavaModelException", "{", "SourceTypeElementInfo", "info", "=", "(", "SourceTypeElementInfo", ")", "getElementInfo", "(", ")", ";", "return", "TypeDeclaration", ".", "kind", "(", "info", ".", "getModifiers", "(", ")", ")", "==", "TypeDeclaration", ".", "ANNOTATION_TYPE_DECL", ";", "}", "public", "boolean", "isLocal", "(", ")", "{", "switch", "(", "this", ".", "parent", ".", "getElementType", "(", ")", ")", "{", "case", "IJavaElement", ".", "METHOD", ":", "case", "IJavaElement", ".", "INITIALIZER", ":", "case", "IJavaElement", ".", "FIELD", ":", "return", "true", ";", "default", ":", "return", "false", ";", "}", "}", "public", "boolean", "isMember", "(", ")", "{", "return", "getDeclaringType", "(", ")", "!=", "null", ";", "}", "public", "boolean", "isResolved", "(", ")", "{", "return", "false", ";", "}", "public", "ITypeHierarchy", "loadTypeHierachy", "(", "InputStream", "input", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "return", "loadTypeHierachy", "(", "input", ",", "DefaultWorkingCopyOwner", ".", "PRIMARY", ",", "monitor", ")", ";", "}", "public", "ITypeHierarchy", "loadTypeHierachy", "(", "InputStream", "input", ",", "WorkingCopyOwner", "owner", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "return", "TypeHierarchy", ".", "load", "(", "this", ",", "input", ",", "owner", ")", ";", "}", "public", "ITypeHierarchy", "newSupertypeHierarchy", "(", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "return", "this", ".", "newSupertypeHierarchy", "(", "DefaultWorkingCopyOwner", ".", "PRIMARY", ",", "monitor", ")", ";", "}", "public", "ITypeHierarchy", "newSupertypeHierarchy", "(", "ICompilationUnit", "[", "]", "workingCopies", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "CreateTypeHierarchyOperation", "op", "=", "new", "CreateTypeHierarchyOperation", "(", "this", ",", "workingCopies", ",", "SearchEngine", ".", "createWorkspaceScope", "(", ")", ",", "false", ")", ";", "op", ".", "runOperation", "(", "monitor", ")", ";", "return", "op", ".", "getResult", "(", ")", ";", "}", "public", "ITypeHierarchy", "newSupertypeHierarchy", "(", "IWorkingCopy", "[", "]", "workingCopies", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "ICompilationUnit", "[", "]", "copies", ";", "if", "(", "workingCopies", "==", "null", ")", "{", "copies", "=", "null", ";", "}", "else", "{", "int", "length", "=", "workingCopies", ".", "length", ";", "System", ".", "arraycopy", "(", "workingCopies", ",", "0", ",", "copies", "=", "new", "ICompilationUnit", "[", "length", "]", ",", "0", ",", "length", ")", ";", "}", "return", "newSupertypeHierarchy", "(", "copies", ",", "monitor", ")", ";", "}", "public", "ITypeHierarchy", "newSupertypeHierarchy", "(", "WorkingCopyOwner", "owner", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "ICompilationUnit", "[", "]", "workingCopies", "=", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "getWorkingCopies", "(", "owner", ",", "true", ")", ";", "CreateTypeHierarchyOperation", "op", "=", "new", "CreateTypeHierarchyOperation", "(", "this", ",", "workingCopies", ",", "SearchEngine", ".", "createWorkspaceScope", "(", ")", ",", "false", ")", ";", "op", ".", "runOperation", "(", "monitor", ")", ";", "return", "op", ".", "getResult", "(", ")", ";", "}", "public", "ITypeHierarchy", "newTypeHierarchy", "(", "IJavaProject", "project", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "return", "newTypeHierarchy", "(", "project", ",", "DefaultWorkingCopyOwner", ".", "PRIMARY", ",", "monitor", ")", ";", "}", "public", "ITypeHierarchy", "newTypeHierarchy", "(", "IJavaProject", "project", ",", "WorkingCopyOwner", "owner", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "if", "(", "project", "==", "null", ")", "{", "throw", "new", "IllegalArgumentException", "(", "Messages", ".", "hierarchy_nullProject", ")", ";", "}", "ICompilationUnit", "[", "]", "workingCopies", "=", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "getWorkingCopies", "(", "owner", ",", "true", ")", ";", "ICompilationUnit", "[", "]", "projectWCs", "=", "null", ";", "if", "(", "workingCopies", "!=", "null", ")", "{", "int", "length", "=", "workingCopies", ".", "length", ";", "projectWCs", "=", "new", "ICompilationUnit", "[", "length", "]", ";", "int", "index", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "ICompilationUnit", "wc", "=", "workingCopies", "[", "i", "]", ";", "if", "(", "project", ".", "equals", "(", "wc", ".", "getJavaProject", "(", ")", ")", ")", "{", "projectWCs", "[", "index", "++", "]", "=", "wc", ";", "}", "}", "if", "(", "index", "!=", "length", ")", "{", "System", ".", "arraycopy", "(", "projectWCs", ",", "0", ",", "projectWCs", "=", "new", "ICompilationUnit", "[", "index", "]", ",", "0", ",", "index", ")", ";", "}", "}", "CreateTypeHierarchyOperation", "op", "=", "new", "CreateTypeHierarchyOperation", "(", "this", ",", "projectWCs", ",", "project", ",", "true", ")", ";", "op", ".", "runOperation", "(", "monitor", ")", ";", "return", "op", ".", "getResult", "(", ")", ";", "}", "public", "ITypeHierarchy", "newTypeHierarchy", "(", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "return", "newTypeHierarchy", "(", "DefaultWorkingCopyOwner", ".", "PRIMARY", ",", "monitor", ")", ";", "}", "public", "ITypeHierarchy", "newTypeHierarchy", "(", "ICompilationUnit", "[", "]", "workingCopies", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "CreateTypeHierarchyOperation", "op", "=", "new", "CreateTypeHierarchyOperation", "(", "this", ",", "workingCopies", ",", "SearchEngine", ".", "createWorkspaceScope", "(", ")", ",", "true", ")", ";", "op", ".", "runOperation", "(", "monitor", ")", ";", "return", "op", ".", "getResult", "(", ")", ";", "}", "public", "ITypeHierarchy", "newTypeHierarchy", "(", "IWorkingCopy", "[", "]", "workingCopies", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "ICompilationUnit", "[", "]", "copies", ";", "if", "(", "workingCopies", "==", "null", ")", "{", "copies", "=", "null", ";", "}", "else", "{", "int", "length", "=", "workingCopies", ".", "length", ";", "System", ".", "arraycopy", "(", "workingCopies", ",", "0", ",", "copies", "=", "new", "ICompilationUnit", "[", "length", "]", ",", "0", ",", "length", ")", ";", "}", "return", "newTypeHierarchy", "(", "copies", ",", "monitor", ")", ";", "}", "public", "ITypeHierarchy", "newTypeHierarchy", "(", "WorkingCopyOwner", "owner", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "ICompilationUnit", "[", "]", "workingCopies", "=", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "getWorkingCopies", "(", "owner", ",", "true", ")", ";", "CreateTypeHierarchyOperation", "op", "=", "new", "CreateTypeHierarchyOperation", "(", "this", ",", "workingCopies", ",", "SearchEngine", ".", "createWorkspaceScope", "(", ")", ",", "true", ")", ";", "op", ".", "runOperation", "(", "monitor", ")", ";", "return", "op", ".", "getResult", "(", ")", ";", "}", "public", "JavaElement", "resolved", "(", "Binding", "binding", ")", "{", "SourceRefElement", "resolvedHandle", "=", "new", "ResolvedSourceType", "(", "this", ".", "parent", ",", "this", ".", "name", ",", "new", "String", "(", "binding", ".", "computeUniqueKey", "(", ")", ")", ")", ";", "resolvedHandle", ".", "occurrenceCount", "=", "this", ".", "occurrenceCount", ";", "return", "resolvedHandle", ";", "}", "protected", "void", "toStringInfo", "(", "int", "tab", ",", "StringBuffer", "buffer", ",", "Object", "info", ",", "boolean", "showResolvedInfo", ")", "{", "buffer", ".", "append", "(", "tabString", "(", "tab", ")", ")", ";", "if", "(", "info", "==", "null", ")", "{", "String", "elementName", "=", "getElementName", "(", ")", ";", "if", "(", "elementName", ".", "length", "(", ")", "==", "0", ")", "{", "buffer", ".", "append", "(", "\"<anonymous", "#\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "occurrenceCount", ")", ";", "buffer", ".", "append", "(", "\">\"", ")", ";", "}", "else", "{", "toStringName", "(", "buffer", ")", ";", "}", "buffer", ".", "append", "(", "\"", "(not", "open)\"", ")", ";", "}", "else", "if", "(", "info", "==", "NO_INFO", ")", "{", "String", "elementName", "=", "getElementName", "(", ")", ";", "if", "(", "elementName", ".", "length", "(", ")", "==", "0", ")", "{", "buffer", ".", "append", "(", "\"<anonymous", "#\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "occurrenceCount", ")", ";", "buffer", ".", "append", "(", "\">\"", ")", ";", "}", "else", "{", "toStringName", "(", "buffer", ")", ";", "}", "}", "else", "{", "try", "{", "if", "(", "isEnum", "(", ")", ")", "{", "buffer", ".", "append", "(", "\"enum", "\"", ")", ";", "}", "else", "if", "(", "isAnnotation", "(", ")", ")", "{", "buffer", ".", "append", "(", "\"@interface", "\"", ")", ";", "}", "else", "if", "(", "isInterface", "(", ")", ")", "{", "buffer", ".", "append", "(", "\"interface", "\"", ")", ";", "}", "else", "{", "buffer", ".", "append", "(", "\"class", "\"", ")", ";", "}", "String", "elementName", "=", "getElementName", "(", ")", ";", "if", "(", "elementName", ".", "length", "(", ")", "==", "0", ")", "{", "buffer", ".", "append", "(", "\"<anonymous", "#\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "occurrenceCount", ")", ";", "buffer", ".", "append", "(", "\">\"", ")", ";", "}", "else", "{", "toStringName", "(", "buffer", ")", ";", "}", "}", "catch", "(", "JavaModelException", "e", ")", "{", "buffer", ".", "append", "(", "\"\"", "+", "getElementName", "(", ")", ")", ";", "}", "}", "}", "}", "</s>" ]
5,508
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "util", ".", "HashSet", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IProject", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IProjectDescription", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IResource", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IWorkspace", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IWorkspaceRoot", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IWorkspaceRunnable", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "CoreException", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IProgressMonitor", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "jobs", ".", "ISchedulingRule", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IClasspathEntry", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "ProjectReferenceChange", "{", "private", "JavaProject", "project", ";", "private", "IClasspathEntry", "[", "]", "oldResolvedClasspath", ";", "public", "ProjectReferenceChange", "(", "JavaProject", "project", ",", "IClasspathEntry", "[", "]", "oldResolvedClasspath", ")", "{", "this", ".", "project", "=", "project", ";", "this", ".", "oldResolvedClasspath", "=", "oldResolvedClasspath", ";", "}", "public", "void", "updateProjectReferencesIfNecessary", "(", ")", "throws", "JavaModelException", "{", "String", "[", "]", "oldRequired", "=", "this", ".", "oldResolvedClasspath", "==", "null", "?", "CharOperation", ".", "NO_STRINGS", ":", "this", ".", "project", ".", "projectPrerequisites", "(", "this", ".", "oldResolvedClasspath", ")", ";", "IClasspathEntry", "[", "]", "newResolvedClasspath", "=", "this", ".", "project", ".", "getResolvedClasspath", "(", ")", ";", "String", "[", "]", "newRequired", "=", "this", ".", "project", ".", "projectPrerequisites", "(", "newResolvedClasspath", ")", ";", "final", "IProject", "projectResource", "=", "this", ".", "project", ".", "getProject", "(", ")", ";", "try", "{", "IProject", "[", "]", "projectReferences", "=", "projectResource", ".", "getDescription", "(", ")", ".", "getDynamicReferences", "(", ")", ";", "HashSet", "oldReferences", "=", "new", "HashSet", "(", "projectReferences", ".", "length", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "projectReferences", ".", "length", ";", "i", "++", ")", "{", "String", "projectName", "=", "projectReferences", "[", "i", "]", ".", "getName", "(", ")", ";", "oldReferences", ".", "add", "(", "projectName", ")", ";", "}", "HashSet", "newReferences", "=", "(", "HashSet", ")", "oldReferences", ".", "clone", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "oldRequired", ".", "length", ";", "i", "++", ")", "{", "String", "projectName", "=", "oldRequired", "[", "i", "]", ";", "newReferences", ".", "remove", "(", "projectName", ")", ";", "}", "for", "(", "int", "i", "=", "0", ";", "i", "<", "newRequired", ".", "length", ";", "i", "++", ")", "{", "String", "projectName", "=", "newRequired", "[", "i", "]", ";", "newReferences", ".", "add", "(", "projectName", ")", ";", "}", "Iterator", "iter", ";", "int", "newSize", "=", "newReferences", ".", "size", "(", ")", ";", "checkIdentity", ":", "{", "if", "(", "oldReferences", ".", "size", "(", ")", "==", "newSize", ")", "{", "iter", "=", "newReferences", ".", "iterator", "(", ")", ";", "while", "(", "iter", ".", "hasNext", "(", ")", ")", "{", "if", "(", "!", "oldReferences", ".", "contains", "(", "iter", ".", "next", "(", ")", ")", ")", "{", "break", "checkIdentity", ";", "}", "}", "return", ";", "}", "}", "String", "[", "]", "requiredProjectNames", "=", "new", "String", "[", "newSize", "]", ";", "int", "index", "=", "0", ";", "iter", "=", "newReferences", ".", "iterator", "(", ")", ";", "while", "(", "iter", ".", "hasNext", "(", ")", ")", "{", "requiredProjectNames", "[", "index", "++", "]", "=", "(", "String", ")", "iter", ".", "next", "(", ")", ";", "}", "Util", ".", "sort", "(", "requiredProjectNames", ")", ";", "final", "IProject", "[", "]", "requiredProjectArray", "=", "new", "IProject", "[", "newSize", "]", ";", "IWorkspaceRoot", "wksRoot", "=", "projectResource", ".", "getWorkspace", "(", ")", ".", "getRoot", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "newSize", ";", "i", "++", ")", "{", "requiredProjectArray", "[", "i", "]", "=", "wksRoot", ".", "getProject", "(", "requiredProjectNames", "[", "i", "]", ")", ";", "}", "IWorkspace", "workspace", "=", "projectResource", ".", "getWorkspace", "(", ")", ";", "ISchedulingRule", "rule", "=", "workspace", ".", "getRuleFactory", "(", ")", ".", "modifyRule", "(", "projectResource", ")", ";", "IWorkspaceRunnable", "runnable", "=", "new", "IWorkspaceRunnable", "(", ")", "{", "public", "void", "run", "(", "IProgressMonitor", "monitor", ")", "throws", "CoreException", "{", "IProjectDescription", "description", "=", "projectResource", ".", "getDescription", "(", ")", ";", "description", ".", "setDynamicReferences", "(", "requiredProjectArray", ")", ";", "projectResource", ".", "setDescription", "(", "description", ",", "IResource", ".", "AVOID_NATURE_CONFIG", ",", "null", ")", ";", "}", "}", ";", "workspace", ".", "run", "(", "runnable", ",", "rule", ",", "IWorkspace", ".", "AVOID_UPDATE", ",", "null", ")", ";", "}", "catch", "(", "CoreException", "e", ")", "{", "if", "(", "!", "ExternalJavaProject", ".", "EXTERNAL_PROJECT_NAME", ".", "equals", "(", "this", ".", "project", ".", "getElementName", "(", ")", ")", ")", "throw", "new", "JavaModelException", "(", "e", ")", ";", "}", "}", "public", "String", "toString", "(", ")", "{", "return", "\"\"", "+", "this", ".", "project", ".", "getElementName", "(", ")", ";", "}", "}", "</s>" ]
5,509
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "LanguageSupportFactory", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IResource", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IPath", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IProgressMonitor", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Path", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IClassFile", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJarEntryResource", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatusConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "class", "JarPackageFragment", "extends", "PackageFragment", "{", "protected", "JarPackageFragment", "(", "PackageFragmentRoot", "root", ",", "String", "[", "]", "names", ")", "{", "super", "(", "root", ",", "names", ")", ";", "}", "protected", "boolean", "buildStructure", "(", "OpenableElementInfo", "info", ",", "IProgressMonitor", "pm", ",", "Map", "newElements", ",", "IResource", "underlyingResource", ")", "throws", "JavaModelException", "{", "JarPackageFragmentRoot", "root", "=", "(", "JarPackageFragmentRoot", ")", "getParent", "(", ")", ";", "JarPackageFragmentRootInfo", "parentInfo", "=", "(", "JarPackageFragmentRootInfo", ")", "root", ".", "getElementInfo", "(", ")", ";", "ArrayList", "[", "]", "entries", "=", "(", "ArrayList", "[", "]", ")", "parentInfo", ".", "rawPackageInfo", ".", "get", "(", "this", ".", "names", ")", ";", "if", "(", "entries", "==", "null", ")", "throw", "newNotPresentException", "(", ")", ";", "JarPackageFragmentInfo", "fragInfo", "=", "(", "JarPackageFragmentInfo", ")", "info", ";", "fragInfo", ".", "setChildren", "(", "computeChildren", "(", "entries", "[", "0", "]", ")", ")", ";", "fragInfo", ".", "setNonJavaResources", "(", "computeNonJavaResources", "(", "entries", "[", "1", "]", ")", ")", ";", "newElements", ".", "put", "(", "this", ",", "fragInfo", ")", ";", "return", "true", ";", "}", "private", "IJavaElement", "[", "]", "computeChildren", "(", "ArrayList", "namesWithoutExtension", ")", "{", "int", "size", "=", "namesWithoutExtension", ".", "size", "(", ")", ";", "if", "(", "size", "==", "0", ")", "return", "NO_ELEMENTS", ";", "IJavaElement", "[", "]", "children", "=", "new", "IJavaElement", "[", "size", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "size", ";", "i", "++", ")", "{", "String", "nameWithoutExtension", "=", "(", "String", ")", "namesWithoutExtension", ".", "get", "(", "i", ")", ";", "children", "[", "i", "]", "=", "new", "ClassFile", "(", "this", ",", "nameWithoutExtension", ")", ";", "}", "return", "children", ";", "}", "private", "Object", "[", "]", "computeNonJavaResources", "(", "ArrayList", "entryNames", ")", "{", "int", "length", "=", "entryNames", ".", "size", "(", ")", ";", "if", "(", "length", "==", "0", ")", "return", "JavaElementInfo", ".", "NO_NON_JAVA_RESOURCES", ";", "HashMap", "jarEntries", "=", "new", "HashMap", "(", ")", ";", "HashMap", "childrenMap", "=", "new", "HashMap", "(", ")", ";", "boolean", "isInteresting", "=", "LanguageSupportFactory", ".", "isInterestingProject", "(", "this", ".", "getJavaProject", "(", ")", ".", "getProject", "(", ")", ")", ";", "ArrayList", "topJarEntries", "=", "new", "ArrayList", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "String", "resName", "=", "(", "String", ")", "entryNames", ".", "get", "(", "i", ")", ";", "if", "(", "(", "!", "Util", ".", "isJavaLikeFileName", "(", "resName", ")", "||", "(", "isInteresting", "&&", "LanguageSupportFactory", ".", "isInterestingSourceFile", "(", "resName", ")", ")", ")", ")", "{", "IPath", "filePath", "=", "new", "Path", "(", "resName", ")", ";", "IPath", "childPath", "=", "filePath", ".", "removeFirstSegments", "(", "this", ".", "names", ".", "length", ")", ";", "if", "(", "jarEntries", ".", "containsKey", "(", "childPath", ")", ")", "{", "continue", ";", "}", "JarEntryFile", "file", "=", "new", "JarEntryFile", "(", "filePath", ".", "lastSegment", "(", ")", ")", ";", "jarEntries", ".", "put", "(", "childPath", ",", "file", ")", ";", "if", "(", "childPath", ".", "segmentCount", "(", ")", "==", "1", ")", "{", "file", ".", "setParent", "(", "this", ")", ";", "topJarEntries", ".", "add", "(", "file", ")", ";", "}", "else", "{", "IPath", "parentPath", "=", "childPath", ".", "removeLastSegments", "(", "1", ")", ";", "while", "(", "parentPath", ".", "segmentCount", "(", ")", ">", "0", ")", "{", "ArrayList", "parentChildren", "=", "(", "ArrayList", ")", "childrenMap", ".", "get", "(", "parentPath", ")", ";", "if", "(", "parentChildren", "==", "null", ")", "{", "Object", "dir", "=", "new", "JarEntryDirectory", "(", "parentPath", ".", "lastSegment", "(", ")", ")", ";", "jarEntries", ".", "put", "(", "parentPath", ",", "dir", ")", ";", "childrenMap", ".", "put", "(", "parentPath", ",", "parentChildren", "=", "new", "ArrayList", "(", ")", ")", ";", "parentChildren", ".", "add", "(", "childPath", ")", ";", "if", "(", "parentPath", ".", "segmentCount", "(", ")", "==", "1", ")", "{", "topJarEntries", ".", "add", "(", "dir", ")", ";", "break", ";", "}", "childPath", "=", "parentPath", ";", "parentPath", "=", "childPath", ".", "removeLastSegments", "(", "1", ")", ";", "}", "else", "{", "parentChildren", ".", "add", "(", "childPath", ")", ";", "break", ";", "}", "}", "}", "}", "}", "Iterator", "entries", "=", "childrenMap", ".", "entrySet", "(", ")", ".", "iterator", "(", ")", ";", "while", "(", "entries", ".", "hasNext", "(", ")", ")", "{", "Map", ".", "Entry", "entry", "=", "(", "Map", ".", "Entry", ")", "entries", ".", "next", "(", ")", ";", "IPath", "entryPath", "=", "(", "IPath", ")", "entry", ".", "getKey", "(", ")", ";", "ArrayList", "entryValue", "=", "(", "ArrayList", ")", "entry", ".", "getValue", "(", ")", ";", "JarEntryDirectory", "jarEntryDirectory", "=", "(", "JarEntryDirectory", ")", "jarEntries", ".", "get", "(", "entryPath", ")", ";", "int", "size", "=", "entryValue", ".", "size", "(", ")", ";", "IJarEntryResource", "[", "]", "children", "=", "new", "IJarEntryResource", "[", "size", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "size", ";", "i", "++", ")", "{", "JarEntryResource", "child", "=", "(", "JarEntryResource", ")", "jarEntries", ".", "get", "(", "entryValue", ".", "get", "(", "i", ")", ")", ";", "child", ".", "setParent", "(", "jarEntryDirectory", ")", ";", "children", "[", "i", "]", "=", "child", ";", "}", "jarEntryDirectory", ".", "setChildren", "(", "children", ")", ";", "if", "(", "entryPath", ".", "segmentCount", "(", ")", "==", "1", ")", "{", "jarEntryDirectory", ".", "setParent", "(", "this", ")", ";", "}", "}", "return", "topJarEntries", ".", "toArray", "(", "new", "Object", "[", "topJarEntries", ".", "size", "(", ")", "]", ")", ";", "}", "public", "boolean", "containsJavaResources", "(", ")", "throws", "JavaModelException", "{", "return", "(", "(", "JarPackageFragmentInfo", ")", "getElementInfo", "(", ")", ")", ".", "containsJavaResources", "(", ")", ";", "}", "public", "ICompilationUnit", "createCompilationUnit", "(", "String", "cuName", ",", "String", "contents", ",", "boolean", "force", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "throw", "new", "JavaModelException", "(", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "READ_ONLY", ",", "this", ")", ")", ";", "}", "protected", "Object", "createElementInfo", "(", ")", "{", "return", "new", "JarPackageFragmentInfo", "(", ")", ";", "}", "public", "IClassFile", "[", "]", "getClassFiles", "(", ")", "throws", "JavaModelException", "{", "ArrayList", "list", "=", "getChildrenOfType", "(", "CLASS_FILE", ")", ";", "IClassFile", "[", "]", "array", "=", "new", "IClassFile", "[", "list", ".", "size", "(", ")", "]", ";", "list", ".", "toArray", "(", "array", ")", ";", "return", "array", ";", "}", "public", "ICompilationUnit", "[", "]", "getCompilationUnits", "(", ")", "{", "return", "NO_COMPILATION_UNITS", ";", "}", "public", "IResource", "getCorrespondingResource", "(", ")", "{", "return", "null", ";", "}", "public", "Object", "[", "]", "getNonJavaResources", "(", ")", "throws", "JavaModelException", "{", "if", "(", "isDefaultPackage", "(", ")", ")", "{", "return", "JavaElementInfo", ".", "NO_NON_JAVA_RESOURCES", ";", "}", "else", "{", "return", "storedNonJavaResources", "(", ")", ";", "}", "}", "public", "boolean", "isReadOnly", "(", ")", "{", "return", "true", ";", "}", "protected", "Object", "[", "]", "storedNonJavaResources", "(", ")", "throws", "JavaModelException", "{", "return", "(", "(", "JarPackageFragmentInfo", ")", "getElementInfo", "(", ")", ")", ".", "getNonJavaResources", "(", ")", ";", "}", "}", "</s>" ]
5,510
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "io", ".", "ByteArrayInputStream", ";", "import", "java", ".", "io", ".", "IOException", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IFile", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IResource", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IResourceStatus", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "CoreException", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IProgressMonitor", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "ISafeRunnable", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "SafeRunner", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "content", ".", "IContentDescription", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "Buffer", "implements", "IBuffer", "{", "protected", "IFile", "file", ";", "protected", "int", "flags", ";", "protected", "char", "[", "]", "contents", ";", "protected", "ArrayList", "changeListeners", ";", "protected", "IOpenable", "owner", ";", "protected", "int", "gapStart", "=", "-", "1", ";", "protected", "int", "gapEnd", "=", "-", "1", ";", "protected", "Object", "lock", "=", "new", "Object", "(", ")", ";", "protected", "static", "final", "int", "F_HAS_UNSAVED_CHANGES", "=", "1", ";", "protected", "static", "final", "int", "F_IS_READ_ONLY", "=", "2", ";", "protected", "static", "final", "int", "F_IS_CLOSED", "=", "4", ";", "protected", "Buffer", "(", "IFile", "file", ",", "IOpenable", "owner", ",", "boolean", "readOnly", ")", "{", "this", ".", "file", "=", "file", ";", "this", ".", "owner", "=", "owner", ";", "if", "(", "file", "==", "null", ")", "{", "setReadOnly", "(", "readOnly", ")", ";", "}", "}", "public", "synchronized", "void", "addBufferChangedListener", "(", "IBufferChangedListener", "listener", ")", "{", "if", "(", "this", ".", "changeListeners", "==", "null", ")", "{", "this", ".", "changeListeners", "=", "new", "ArrayList", "(", "5", ")", ";", "}", "if", "(", "!", "this", ".", "changeListeners", ".", "contains", "(", "listener", ")", ")", "{", "this", ".", "changeListeners", ".", "add", "(", "listener", ")", ";", "}", "}", "public", "void", "append", "(", "char", "[", "]", "text", ")", "{", "if", "(", "!", "isReadOnly", "(", ")", ")", "{", "if", "(", "text", "==", "null", "||", "text", ".", "length", "==", "0", ")", "{", "return", ";", "}", "int", "length", "=", "getLength", "(", ")", ";", "synchronized", "(", "this", ".", "lock", ")", "{", "if", "(", "this", ".", "contents", "==", "null", ")", "return", ";", "moveAndResizeGap", "(", "length", ",", "text", ".", "length", ")", ";", "System", ".", "arraycopy", "(", "text", ",", "0", ",", "this", ".", "contents", ",", "length", ",", "text", ".", "length", ")", ";", "this", ".", "gapStart", "+=", "text", ".", "length", ";", "this", ".", "flags", "|=", "F_HAS_UNSAVED_CHANGES", ";", "}", "notifyChanged", "(", "new", "BufferChangedEvent", "(", "this", ",", "length", ",", "0", ",", "new", "String", "(", "text", ")", ")", ")", ";", "}", "}", "public", "void", "append", "(", "String", "text", ")", "{", "if", "(", "text", "==", "null", ")", "{", "return", ";", "}", "this", ".", "append", "(", "text", ".", "toCharArray", "(", ")", ")", ";", "}", "public", "void", "close", "(", ")", "{", "BufferChangedEvent", "event", "=", "null", ";", "synchronized", "(", "this", ".", "lock", ")", "{", "if", "(", "isClosed", "(", ")", ")", "return", ";", "event", "=", "new", "BufferChangedEvent", "(", "this", ",", "0", ",", "0", ",", "null", ")", ";", "this", ".", "contents", "=", "null", ";", "this", ".", "flags", "|=", "F_IS_CLOSED", ";", "}", "notifyChanged", "(", "event", ")", ";", "synchronized", "(", "this", ")", "{", "this", ".", "changeListeners", "=", "null", ";", "}", "}", "public", "char", "getChar", "(", "int", "position", ")", "{", "synchronized", "(", "this", ".", "lock", ")", "{", "if", "(", "this", ".", "contents", "==", "null", ")", "return", "Character", ".", "MIN_VALUE", ";", "if", "(", "position", "<", "this", ".", "gapStart", ")", "{", "return", "this", ".", "contents", "[", "position", "]", ";", "}", "int", "gapLength", "=", "this", ".", "gapEnd", "-", "this", ".", "gapStart", ";", "return", "this", ".", "contents", "[", "position", "+", "gapLength", "]", ";", "}", "}", "public", "char", "[", "]", "getCharacters", "(", ")", "{", "synchronized", "(", "this", ".", "lock", ")", "{", "if", "(", "this", ".", "contents", "==", "null", ")", "return", "null", ";", "if", "(", "this", ".", "gapStart", "<", "0", ")", "{", "return", "this", ".", "contents", ";", "}", "int", "length", "=", "this", ".", "contents", ".", "length", ";", "char", "[", "]", "newContents", "=", "new", "char", "[", "length", "-", "this", ".", "gapEnd", "+", "this", ".", "gapStart", "]", ";", "System", ".", "arraycopy", "(", "this", ".", "contents", ",", "0", ",", "newContents", ",", "0", ",", "this", ".", "gapStart", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "contents", ",", "this", ".", "gapEnd", ",", "newContents", ",", "this", ".", "gapStart", ",", "length", "-", "this", ".", "gapEnd", ")", ";", "return", "newContents", ";", "}", "}", "public", "String", "getContents", "(", ")", "{", "char", "[", "]", "chars", "=", "getCharacters", "(", ")", ";", "if", "(", "chars", "==", "null", ")", "return", "null", ";", "return", "new", "String", "(", "chars", ")", ";", "}", "public", "int", "getLength", "(", ")", "{", "synchronized", "(", "this", ".", "lock", ")", "{", "if", "(", "this", ".", "contents", "==", "null", ")", "return", "-", "1", ";", "int", "length", "=", "this", ".", "gapEnd", "-", "this", ".", "gapStart", ";", "return", "(", "this", ".", "contents", ".", "length", "-", "length", ")", ";", "}", "}", "public", "IOpenable", "getOwner", "(", ")", "{", "return", "this", ".", "owner", ";", "}", "public", "String", "getText", "(", "int", "offset", ",", "int", "length", ")", "{", "synchronized", "(", "this", ".", "lock", ")", "{", "if", "(", "this", ".", "contents", "==", "null", ")", "return", "\"\"", ";", "if", "(", "offset", "+", "length", "<", "this", ".", "gapStart", ")", "return", "new", "String", "(", "this", ".", "contents", ",", "offset", ",", "length", ")", ";", "if", "(", "this", ".", "gapStart", "<", "offset", ")", "{", "int", "gapLength", "=", "this", ".", "gapEnd", "-", "this", ".", "gapStart", ";", "return", "new", "String", "(", "this", ".", "contents", ",", "offset", "+", "gapLength", ",", "length", ")", ";", "}", "StringBuffer", "buf", "=", "new", "StringBuffer", "(", ")", ";", "buf", ".", "append", "(", "this", ".", "contents", ",", "offset", ",", "this", ".", "gapStart", "-", "offset", ")", ";", "buf", ".", "append", "(", "this", ".", "contents", ",", "this", ".", "gapEnd", ",", "offset", "+", "length", "-", "this", ".", "gapStart", ")", ";", "return", "buf", ".", "toString", "(", ")", ";", "}", "}", "public", "IResource", "getUnderlyingResource", "(", ")", "{", "return", "this", ".", "file", ";", "}", "public", "boolean", "hasUnsavedChanges", "(", ")", "{", "return", "(", "this", ".", "flags", "&", "F_HAS_UNSAVED_CHANGES", ")", "!=", "0", ";", "}", "public", "boolean", "isClosed", "(", ")", "{", "return", "(", "this", ".", "flags", "&", "F_IS_CLOSED", ")", "!=", "0", ";", "}", "public", "boolean", "isReadOnly", "(", ")", "{", "return", "(", "this", ".", "flags", "&", "F_IS_READ_ONLY", ")", "!=", "0", ";", "}", "protected", "void", "moveAndResizeGap", "(", "int", "position", ",", "int", "size", ")", "{", "char", "[", "]", "content", "=", "null", ";", "int", "oldSize", "=", "this", ".", "gapEnd", "-", "this", ".", "gapStart", ";", "if", "(", "size", "<", "0", ")", "{", "if", "(", "oldSize", ">", "0", ")", "{", "content", "=", "new", "char", "[", "this", ".", "contents", ".", "length", "-", "oldSize", "]", ";", "System", ".", "arraycopy", "(", "this", ".", "contents", ",", "0", ",", "content", ",", "0", ",", "this", ".", "gapStart", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "contents", ",", "this", ".", "gapEnd", ",", "content", ",", "this", ".", "gapStart", ",", "content", ".", "length", "-", "this", ".", "gapStart", ")", ";", "this", ".", "contents", "=", "content", ";", "}", "this", ".", "gapStart", "=", "this", ".", "gapEnd", "=", "position", ";", "return", ";", "}", "content", "=", "new", "char", "[", "this", ".", "contents", ".", "length", "+", "(", "size", "-", "oldSize", ")", "]", ";", "int", "newGapStart", "=", "position", ";", "int", "newGapEnd", "=", "newGapStart", "+", "size", ";", "if", "(", "oldSize", "==", "0", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "contents", ",", "0", ",", "content", ",", "0", ",", "newGapStart", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "contents", ",", "newGapStart", ",", "content", ",", "newGapEnd", ",", "content", ".", "length", "-", "newGapEnd", ")", ";", "}", "else", "if", "(", "newGapStart", "<", "this", ".", "gapStart", ")", "{", "int", "delta", "=", "this", ".", "gapStart", "-", "newGapStart", ";", "System", ".", "arraycopy", "(", "this", ".", "contents", ",", "0", ",", "content", ",", "0", ",", "newGapStart", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "contents", ",", "newGapStart", ",", "content", ",", "newGapEnd", ",", "delta", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "contents", ",", "this", ".", "gapEnd", ",", "content", ",", "newGapEnd", "+", "delta", ",", "this", ".", "contents", ".", "length", "-", "this", ".", "gapEnd", ")", ";", "}", "else", "{", "int", "delta", "=", "newGapStart", "-", "this", ".", "gapStart", ";", "System", ".", "arraycopy", "(", "this", ".", "contents", ",", "0", ",", "content", ",", "0", ",", "this", ".", "gapStart", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "contents", ",", "this", ".", "gapEnd", ",", "content", ",", "this", ".", "gapStart", ",", "delta", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "contents", ",", "this", ".", "gapEnd", "+", "delta", ",", "content", ",", "newGapEnd", ",", "content", ".", "length", "-", "newGapEnd", ")", ";", "}", "this", ".", "contents", "=", "content", ";", "this", ".", "gapStart", "=", "newGapStart", ";", "this", ".", "gapEnd", "=", "newGapEnd", ";", "}", "protected", "void", "notifyChanged", "(", "final", "BufferChangedEvent", "event", ")", "{", "ArrayList", "listeners", "=", "this", ".", "changeListeners", ";", "if", "(", "listeners", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "size", "=", "listeners", ".", "size", "(", ")", ";", "i", "<", "size", ";", "++", "i", ")", "{", "final", "IBufferChangedListener", "listener", "=", "(", "IBufferChangedListener", ")", "listeners", ".", "get", "(", "i", ")", ";", "SafeRunner", ".", "run", "(", "new", "ISafeRunnable", "(", ")", "{", "public", "void", "handleException", "(", "Throwable", "exception", ")", "{", "Util", ".", "log", "(", "exception", ",", "\"\"", ")", ";", "}", "public", "void", "run", "(", ")", "throws", "Exception", "{", "listener", ".", "bufferChanged", "(", "event", ")", ";", "}", "}", ")", ";", "}", "}", "}", "public", "synchronized", "void", "removeBufferChangedListener", "(", "IBufferChangedListener", "listener", ")", "{", "if", "(", "this", ".", "changeListeners", "!=", "null", ")", "{", "this", ".", "changeListeners", ".", "remove", "(", "listener", ")", ";", "if", "(", "this", ".", "changeListeners", ".", "size", "(", ")", "==", "0", ")", "{", "this", ".", "changeListeners", "=", "null", ";", "}", "}", "}", "public", "void", "replace", "(", "int", "position", ",", "int", "length", ",", "char", "[", "]", "text", ")", "{", "if", "(", "!", "isReadOnly", "(", ")", ")", "{", "int", "textLength", "=", "text", "==", "null", "?", "0", ":", "text", ".", "length", ";", "synchronized", "(", "this", ".", "lock", ")", "{", "if", "(", "this", ".", "contents", "==", "null", ")", "return", ";", "moveAndResizeGap", "(", "position", "+", "length", ",", "textLength", "-", "length", ")", ";", "int", "min", "=", "Math", ".", "min", "(", "textLength", ",", "length", ")", ";", "if", "(", "min", ">", "0", ")", "{", "System", ".", "arraycopy", "(", "text", ",", "0", ",", "this", ".", "contents", ",", "position", ",", "min", ")", ";", "}", "if", "(", "length", ">", "textLength", ")", "{", "this", ".", "gapStart", "-=", "length", "-", "textLength", ";", "}", "else", "if", "(", "textLength", ">", "length", ")", "{", "this", ".", "gapStart", "+=", "textLength", "-", "length", ";", "System", ".", "arraycopy", "(", "text", ",", "0", ",", "this", ".", "contents", ",", "position", ",", "textLength", ")", ";", "}", "this", ".", "flags", "|=", "F_HAS_UNSAVED_CHANGES", ";", "}", "String", "string", "=", "null", ";", "if", "(", "textLength", ">", "0", ")", "{", "string", "=", "new", "String", "(", "text", ")", ";", "}", "notifyChanged", "(", "new", "BufferChangedEvent", "(", "this", ",", "position", ",", "length", ",", "string", ")", ")", ";", "}", "}", "public", "void", "replace", "(", "int", "position", ",", "int", "length", ",", "String", "text", ")", "{", "this", ".", "replace", "(", "position", ",", "length", ",", "text", "==", "null", "?", "null", ":", "text", ".", "toCharArray", "(", ")", ")", ";", "}", "public", "void", "save", "(", "IProgressMonitor", "progress", ",", "boolean", "force", ")", "throws", "JavaModelException", "{", "if", "(", "isReadOnly", "(", ")", "||", "this", ".", "file", "==", "null", ")", "{", "return", ";", "}", "if", "(", "!", "hasUnsavedChanges", "(", ")", ")", "return", ";", "try", "{", "String", "stringContents", "=", "getContents", "(", ")", ";", "if", "(", "stringContents", "==", "null", ")", "return", ";", "String", "encoding", "=", "null", ";", "try", "{", "encoding", "=", "this", ".", "file", ".", "getCharset", "(", ")", ";", "}", "catch", "(", "CoreException", "ce", ")", "{", "}", "byte", "[", "]", "bytes", "=", "encoding", "==", "null", "?", "stringContents", ".", "getBytes", "(", ")", ":", "stringContents", ".", "getBytes", "(", "encoding", ")", ";", "if", "(", "encoding", "!=", "null", "&&", "encoding", ".", "equals", "(", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "Util", ".", "UTF_8", ")", ")", "{", "IContentDescription", "description", ";", "try", "{", "description", "=", "this", ".", "file", ".", "getContentDescription", "(", ")", ";", "}", "catch", "(", "CoreException", "e", ")", "{", "if", "(", "e", ".", "getStatus", "(", ")", ".", "getCode", "(", ")", "!=", "IResourceStatus", ".", "RESOURCE_NOT_FOUND", ")", "throw", "e", ";", "description", "=", "null", ";", "}", "if", "(", "description", "!=", "null", "&&", "description", ".", "getProperty", "(", "IContentDescription", ".", "BYTE_ORDER_MARK", ")", "!=", "null", ")", "{", "int", "bomLength", "=", "IContentDescription", ".", "BOM_UTF_8", ".", "length", ";", "byte", "[", "]", "bytesWithBOM", "=", "new", "byte", "[", "bytes", ".", "length", "+", "bomLength", "]", ";", "System", ".", "arraycopy", "(", "IContentDescription", ".", "BOM_UTF_8", ",", "0", ",", "bytesWithBOM", ",", "0", ",", "bomLength", ")", ";", "System", ".", "arraycopy", "(", "bytes", ",", "0", ",", "bytesWithBOM", ",", "bomLength", ",", "bytes", ".", "length", ")", ";", "bytes", "=", "bytesWithBOM", ";", "}", "}", "ByteArrayInputStream", "stream", "=", "new", "ByteArrayInputStream", "(", "bytes", ")", ";", "if", "(", "this", ".", "file", ".", "exists", "(", ")", ")", "{", "this", ".", "file", ".", "setContents", "(", "stream", ",", "force", "?", "IResource", ".", "FORCE", "|", "IResource", ".", "KEEP_HISTORY", ":", "IResource", ".", "KEEP_HISTORY", ",", "null", ")", ";", "}", "else", "{", "this", ".", "file", ".", "create", "(", "stream", ",", "force", ",", "null", ")", ";", "}", "}", "catch", "(", "IOException", "e", ")", "{", "throw", "new", "JavaModelException", "(", "e", ",", "IJavaModelStatusConstants", ".", "IO_EXCEPTION", ")", ";", "}", "catch", "(", "CoreException", "e", ")", "{", "throw", "new", "JavaModelException", "(", "e", ")", ";", "}", "this", ".", "flags", "&=", "~", "(", "F_HAS_UNSAVED_CHANGES", ")", ";", "}", "public", "void", "setContents", "(", "char", "[", "]", "newContents", ")", "{", "if", "(", "this", ".", "contents", "==", "null", ")", "{", "synchronized", "(", "this", ".", "lock", ")", "{", "this", ".", "contents", "=", "newContents", ";", "this", ".", "flags", "&=", "~", "(", "F_HAS_UNSAVED_CHANGES", ")", ";", "}", "return", ";", "}", "if", "(", "!", "isReadOnly", "(", ")", ")", "{", "String", "string", "=", "null", ";", "if", "(", "newContents", "!=", "null", ")", "{", "string", "=", "new", "String", "(", "newContents", ")", ";", "}", "synchronized", "(", "this", ".", "lock", ")", "{", "if", "(", "this", ".", "contents", "==", "null", ")", "return", ";", "this", ".", "contents", "=", "newContents", ";", "this", ".", "flags", "|=", "F_HAS_UNSAVED_CHANGES", ";", "this", ".", "gapStart", "=", "-", "1", ";", "this", ".", "gapEnd", "=", "-", "1", ";", "}", "BufferChangedEvent", "event", "=", "new", "BufferChangedEvent", "(", "this", ",", "0", ",", "getLength", "(", ")", ",", "string", ")", ";", "notifyChanged", "(", "event", ")", ";", "}", "}", "public", "void", "setContents", "(", "String", "newContents", ")", "{", "this", ".", "setContents", "(", "newContents", ".", "toCharArray", "(", ")", ")", ";", "}", "protected", "void", "setReadOnly", "(", "boolean", "readOnly", ")", "{", "if", "(", "readOnly", ")", "{", "this", ".", "flags", "|=", "F_IS_READ_ONLY", ";", "}", "else", "{", "this", ".", "flags", "&=", "~", "(", "F_IS_READ_ONLY", ")", ";", "}", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", ")", ";", "buffer", ".", "append", "(", "\"Owner:", "\"", "+", "(", "(", "JavaElement", ")", "this", ".", "owner", ")", ".", "toStringWithAncestors", "(", ")", ")", ";", "buffer", ".", "append", "(", "\"\"", "+", "hasUnsavedChanges", "(", ")", ")", ";", "buffer", ".", "append", "(", "\"\"", "+", "isReadOnly", "(", ")", ")", ";", "buffer", ".", "append", "(", "\"nIs", "closed:", "\"", "+", "isClosed", "(", ")", ")", ";", "buffer", ".", "append", "(", "\"nContents:n\"", ")", ";", "char", "[", "]", "charContents", "=", "getCharacters", "(", ")", ";", "if", "(", "charContents", "==", "null", ")", "{", "buffer", ".", "append", "(", "\"<null>\"", ")", ";", "}", "else", "{", "int", "length", "=", "charContents", ".", "length", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "char", "c", "=", "charContents", "[", "i", "]", ";", "switch", "(", "c", ")", "{", "case", "'\\n'", ":", "buffer", ".", "append", "(", "\"\\\\nn\"", ")", ";", "break", ";", "case", "'\\r'", ":", "if", "(", "i", "<", "length", "-", "1", "&&", "this", ".", "contents", "[", "i", "+", "1", "]", "==", "'\\n'", ")", "{", "buffer", ".", "append", "(", "\"\\\\r\\\\nn\"", ")", ";", "i", "++", ";", "}", "else", "{", "buffer", ".", "append", "(", "\"\\\\rn\"", ")", ";", "}", "break", ";", "default", ":", "buffer", ".", "append", "(", "c", ")", ";", "break", ";", "}", "}", "}", "return", "buffer", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
5,511
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "ISafeRunnable", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "OperationCanceledException", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "SafeRunner", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CategorizedProblem", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CompilationParticipant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "ReconcileContext", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "AST", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "CompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Messages", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "ReconcileWorkingCopyOperation", "extends", "JavaModelOperation", "{", "public", "static", "boolean", "PERF", "=", "false", ";", "public", "int", "astLevel", ";", "public", "boolean", "resolveBindings", ";", "public", "HashMap", "problems", ";", "public", "int", "reconcileFlags", ";", "WorkingCopyOwner", "workingCopyOwner", ";", "public", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "CompilationUnit", "ast", ";", "public", "JavaElementDeltaBuilder", "deltaBuilder", ";", "public", "boolean", "requestorIsActive", ";", "public", "ReconcileWorkingCopyOperation", "(", "IJavaElement", "workingCopy", ",", "int", "astLevel", ",", "int", "reconcileFlags", ",", "WorkingCopyOwner", "workingCopyOwner", ")", "{", "super", "(", "new", "IJavaElement", "[", "]", "{", "workingCopy", "}", ")", ";", "this", ".", "astLevel", "=", "astLevel", ";", "this", ".", "reconcileFlags", "=", "reconcileFlags", ";", "this", ".", "workingCopyOwner", "=", "workingCopyOwner", ";", "}", "protected", "void", "executeOperation", "(", ")", "throws", "JavaModelException", "{", "checkCanceled", "(", ")", ";", "try", "{", "beginTask", "(", "Messages", ".", "element_reconciling", ",", "2", ")", ";", "CompilationUnit", "workingCopy", "=", "getWorkingCopy", "(", ")", ";", "boolean", "wasConsistent", "=", "workingCopy", ".", "isConsistent", "(", ")", ";", "IProblemRequestor", "problemRequestor", "=", "workingCopy", ".", "getPerWorkingCopyInfo", "(", ")", ";", "if", "(", "problemRequestor", "!=", "null", ")", "problemRequestor", "=", "(", "(", "JavaModelManager", ".", "PerWorkingCopyInfo", ")", "problemRequestor", ")", ".", "getProblemRequestor", "(", ")", ";", "boolean", "defaultRequestorIsActive", "=", "problemRequestor", "!=", "null", "&&", "problemRequestor", ".", "isActive", "(", ")", ";", "IProblemRequestor", "ownerProblemRequestor", "=", "this", ".", "workingCopyOwner", ".", "getProblemRequestor", "(", "workingCopy", ")", ";", "boolean", "ownerRequestorIsActive", "=", "ownerProblemRequestor", "!=", "null", "&&", "ownerProblemRequestor", "!=", "problemRequestor", "&&", "ownerProblemRequestor", ".", "isActive", "(", ")", ";", "this", ".", "requestorIsActive", "=", "defaultRequestorIsActive", "||", "ownerRequestorIsActive", ";", "this", ".", "deltaBuilder", "=", "new", "JavaElementDeltaBuilder", "(", "workingCopy", ")", ";", "makeConsistent", "(", "workingCopy", ")", ";", "if", "(", "!", "wasConsistent", "||", "(", "(", "this", ".", "reconcileFlags", "&", "ICompilationUnit", ".", "FORCE_PROBLEM_DETECTION", ")", "!=", "0", ")", ")", "{", "notifyParticipants", "(", "workingCopy", ")", ";", "if", "(", "this", ".", "ast", "==", "null", ")", "makeConsistent", "(", "workingCopy", ")", ";", "}", "if", "(", "this", ".", "problems", "!=", "null", "&&", "(", "(", "(", "this", ".", "reconcileFlags", "&", "ICompilationUnit", ".", "FORCE_PROBLEM_DETECTION", ")", "!=", "0", ")", "||", "!", "wasConsistent", ")", ")", "{", "if", "(", "defaultRequestorIsActive", ")", "{", "reportProblems", "(", "workingCopy", ",", "problemRequestor", ")", ";", "}", "if", "(", "ownerRequestorIsActive", ")", "{", "reportProblems", "(", "workingCopy", ",", "ownerProblemRequestor", ")", ";", "}", "}", "JavaElementDelta", "delta", "=", "this", ".", "deltaBuilder", ".", "delta", ";", "if", "(", "delta", "!=", "null", ")", "{", "addReconcileDelta", "(", "workingCopy", ",", "delta", ")", ";", "}", "}", "finally", "{", "done", "(", ")", ";", "}", "}", "private", "void", "reportProblems", "(", "CompilationUnit", "workingCopy", ",", "IProblemRequestor", "problemRequestor", ")", "{", "try", "{", "problemRequestor", ".", "beginReporting", "(", ")", ";", "for", "(", "Iterator", "iteraror", "=", "this", ".", "problems", ".", "values", "(", ")", ".", "iterator", "(", ")", ";", "iteraror", ".", "hasNext", "(", ")", ";", ")", "{", "CategorizedProblem", "[", "]", "categorizedProblems", "=", "(", "CategorizedProblem", "[", "]", ")", "iteraror", ".", "next", "(", ")", ";", "if", "(", "categorizedProblems", "==", "null", ")", "continue", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "categorizedProblems", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "CategorizedProblem", "problem", "=", "categorizedProblems", "[", "i", "]", ";", "if", "(", "JavaModelManager", ".", "VERBOSE", ")", "{", "System", ".", "out", ".", "println", "(", "\"\"", "+", "problem", ".", "getMessage", "(", ")", ")", ";", "}", "if", "(", "this", ".", "progressMonitor", "!=", "null", "&&", "this", ".", "progressMonitor", ".", "isCanceled", "(", ")", ")", "break", ";", "problemRequestor", ".", "acceptProblem", "(", "problem", ")", ";", "}", "}", "}", "finally", "{", "problemRequestor", ".", "endReporting", "(", ")", ";", "}", "}", "protected", "CompilationUnit", "getWorkingCopy", "(", ")", "{", "return", "(", "CompilationUnit", ")", "getElementToProcess", "(", ")", ";", "}", "public", "boolean", "isReadOnly", "(", ")", "{", "return", "true", ";", "}", "public", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "CompilationUnit", "makeConsistent", "(", "CompilationUnit", "workingCopy", ")", "throws", "JavaModelException", "{", "if", "(", "!", "workingCopy", ".", "isConsistent", "(", ")", ")", "{", "if", "(", "this", ".", "problems", "==", "null", ")", "this", ".", "problems", "=", "new", "HashMap", "(", ")", ";", "this", ".", "resolveBindings", "=", "this", ".", "requestorIsActive", ";", "this", ".", "ast", "=", "workingCopy", ".", "makeConsistent", "(", "this", ".", "astLevel", ",", "this", ".", "resolveBindings", ",", "this", ".", "reconcileFlags", ",", "this", ".", "problems", ",", "this", ".", "progressMonitor", ")", ";", "this", ".", "deltaBuilder", ".", "buildDeltas", "(", ")", ";", "if", "(", "this", ".", "ast", "!=", "null", "&&", "this", ".", "deltaBuilder", ".", "delta", "!=", "null", ")", "this", ".", "deltaBuilder", ".", "delta", ".", "changedAST", "(", "this", ".", "ast", ")", ";", "return", "this", ".", "ast", ";", "}", "if", "(", "this", ".", "ast", "!=", "null", ")", "return", "this", ".", "ast", ";", "CompilationUnitDeclaration", "unit", "=", "null", ";", "try", "{", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "abortOnMissingSource", ".", "set", "(", "Boolean", ".", "TRUE", ")", ";", "CompilationUnit", "source", "=", "workingCopy", ".", "cloneCachingContents", "(", ")", ";", "if", "(", "JavaProject", ".", "hasJavaNature", "(", "workingCopy", ".", "getJavaProject", "(", ")", ".", "getProject", "(", ")", ")", "&&", "(", "this", ".", "reconcileFlags", "&", "ICompilationUnit", ".", "FORCE_PROBLEM_DETECTION", ")", "!=", "0", ")", "{", "this", ".", "resolveBindings", "=", "this", ".", "requestorIsActive", ";", "if", "(", "this", ".", "problems", "==", "null", ")", "this", ".", "problems", "=", "new", "HashMap", "(", ")", ";", "unit", "=", "CompilationUnitProblemFinder", ".", "process", "(", "source", ",", "this", ".", "workingCopyOwner", ",", "this", ".", "problems", ",", "this", ".", "astLevel", "!=", "ICompilationUnit", ".", "NO_AST", ",", "this", ".", "reconcileFlags", ",", "this", ".", "progressMonitor", ")", ";", "if", "(", "this", ".", "progressMonitor", "!=", "null", ")", "this", ".", "progressMonitor", ".", "worked", "(", "1", ")", ";", "}", "if", "(", "this", ".", "astLevel", "!=", "ICompilationUnit", ".", "NO_AST", "&&", "unit", "!=", "null", ")", "{", "Map", "options", "=", "workingCopy", ".", "getJavaProject", "(", ")", ".", "getOptions", "(", "true", ")", ";", "this", ".", "ast", "=", "AST", ".", "convertCompilationUnit", "(", "this", ".", "astLevel", ",", "unit", ",", "options", ",", "this", ".", "resolveBindings", ",", "source", ",", "this", ".", "reconcileFlags", ",", "this", ".", "progressMonitor", ")", ";", "if", "(", "this", ".", "ast", "!=", "null", ")", "{", "if", "(", "this", ".", "deltaBuilder", ".", "delta", "==", "null", ")", "{", "this", ".", "deltaBuilder", ".", "delta", "=", "new", "JavaElementDelta", "(", "workingCopy", ")", ";", "}", "this", ".", "deltaBuilder", ".", "delta", ".", "changedAST", "(", "this", ".", "ast", ")", ";", "}", "if", "(", "this", ".", "progressMonitor", "!=", "null", ")", "this", ".", "progressMonitor", ".", "worked", "(", "1", ")", ";", "}", "}", "catch", "(", "JavaModelException", "e", ")", "{", "if", "(", "JavaProject", ".", "hasJavaNature", "(", "workingCopy", ".", "getJavaProject", "(", ")", ".", "getProject", "(", ")", ")", ")", "throw", "e", ";", "}", "finally", "{", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "abortOnMissingSource", ".", "set", "(", "null", ")", ";", "if", "(", "unit", "!=", "null", ")", "{", "unit", ".", "cleanUp", "(", ")", ";", "}", "}", "return", "this", ".", "ast", ";", "}", "private", "void", "notifyParticipants", "(", "final", "CompilationUnit", "workingCopy", ")", "{", "IJavaProject", "javaProject", "=", "getWorkingCopy", "(", ")", ".", "getJavaProject", "(", ")", ";", "CompilationParticipant", "[", "]", "participants", "=", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "compilationParticipants", ".", "getCompilationParticipants", "(", "javaProject", ")", ";", "if", "(", "participants", "==", "null", ")", "return", ";", "final", "ReconcileContext", "context", "=", "new", "ReconcileContext", "(", "this", ",", "workingCopy", ")", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "participants", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "final", "CompilationParticipant", "participant", "=", "participants", "[", "i", "]", ";", "SafeRunner", ".", "run", "(", "new", "ISafeRunnable", "(", ")", "{", "public", "void", "handleException", "(", "Throwable", "exception", ")", "{", "if", "(", "exception", "instanceof", "Error", ")", "{", "throw", "(", "Error", ")", "exception", ";", "}", "else", "if", "(", "exception", "instanceof", "OperationCanceledException", ")", "throw", "(", "OperationCanceledException", ")", "exception", ";", "else", "if", "(", "exception", "instanceof", "UnsupportedOperationException", ")", "{", "Util", ".", "log", "(", "exception", ",", "\"\"", ")", ";", "}", "else", "Util", ".", "log", "(", "exception", ",", "\"\"", ")", ";", "}", "public", "void", "run", "(", ")", "throws", "Exception", "{", "participant", ".", "reconcile", "(", "context", ")", ";", "}", "}", ")", ";", "}", "}", "protected", "IJavaModelStatus", "verify", "(", ")", "{", "IJavaModelStatus", "status", "=", "super", ".", "verify", "(", ")", ";", "if", "(", "!", "status", ".", "isOK", "(", ")", ")", "{", "return", "status", ";", "}", "CompilationUnit", "workingCopy", "=", "getWorkingCopy", "(", ")", ";", "if", "(", "!", "workingCopy", ".", "isWorkingCopy", "(", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "ELEMENT_DOES_NOT_EXIST", ",", "workingCopy", ")", ";", "}", "return", "status", ";", "}", "}", "</s>" ]
5,512
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "Binding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "SourceMethod", "extends", "NamedMember", "implements", "IMethod", "{", "protected", "String", "[", "]", "parameterTypes", ";", "protected", "SourceMethod", "(", "JavaElement", "parent", ",", "String", "name", ",", "String", "[", "]", "parameterTypes", ")", "{", "super", "(", "parent", ",", "name", ")", ";", "if", "(", "parameterTypes", "==", "null", ")", "{", "this", ".", "parameterTypes", "=", "CharOperation", ".", "NO_STRINGS", ";", "}", "else", "{", "this", ".", "parameterTypes", "=", "parameterTypes", ";", "}", "}", "protected", "void", "closing", "(", "Object", "info", ")", "throws", "JavaModelException", "{", "super", ".", "closing", "(", "info", ")", ";", "SourceMethodElementInfo", "elementInfo", "=", "(", "SourceMethodElementInfo", ")", "info", ";", "ITypeParameter", "[", "]", "typeParameters", "=", "elementInfo", ".", "typeParameters", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "typeParameters", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "(", "(", "TypeParameter", ")", "typeParameters", "[", "i", "]", ")", ".", "close", "(", ")", ";", "}", "}", "public", "boolean", "equals", "(", "Object", "o", ")", "{", "if", "(", "!", "(", "o", "instanceof", "SourceMethod", ")", ")", "return", "false", ";", "return", "super", ".", "equals", "(", "o", ")", "&&", "Util", ".", "equalArraysOrNull", "(", "this", ".", "parameterTypes", ",", "(", "(", "SourceMethod", ")", "o", ")", ".", "parameterTypes", ")", ";", "}", "public", "IMemberValuePair", "getDefaultValue", "(", ")", "throws", "JavaModelException", "{", "SourceMethodElementInfo", "sourceMethodInfo", "=", "(", "SourceMethodElementInfo", ")", "getElementInfo", "(", ")", ";", "if", "(", "sourceMethodInfo", ".", "isAnnotationMethod", "(", ")", ")", "{", "return", "(", "(", "SourceAnnotationMethodInfo", ")", "sourceMethodInfo", ")", ".", "defaultValue", ";", "}", "return", "null", ";", "}", "public", "int", "getElementType", "(", ")", "{", "return", "METHOD", ";", "}", "public", "String", "[", "]", "getExceptionTypes", "(", ")", "throws", "JavaModelException", "{", "SourceMethodElementInfo", "info", "=", "(", "SourceMethodElementInfo", ")", "getElementInfo", "(", ")", ";", "char", "[", "]", "[", "]", "exs", "=", "info", ".", "getExceptionTypeNames", "(", ")", ";", "return", "CompilationUnitStructureRequestor", ".", "convertTypeNamesToSigs", "(", "exs", ")", ";", "}", "protected", "void", "getHandleMemento", "(", "StringBuffer", "buff", ")", "{", "(", "(", "JavaElement", ")", "getParent", "(", ")", ")", ".", "getHandleMemento", "(", "buff", ")", ";", "char", "delimiter", "=", "getHandleMementoDelimiter", "(", ")", ";", "buff", ".", "append", "(", "delimiter", ")", ";", "escapeMementoName", "(", "buff", ",", "getElementName", "(", ")", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "parameterTypes", ".", "length", ";", "i", "++", ")", "{", "buff", ".", "append", "(", "delimiter", ")", ";", "escapeMementoName", "(", "buff", ",", "this", ".", "parameterTypes", "[", "i", "]", ")", ";", "}", "if", "(", "this", ".", "occurrenceCount", ">", "1", ")", "{", "buff", ".", "append", "(", "JEM_COUNT", ")", ";", "buff", ".", "append", "(", "this", ".", "occurrenceCount", ")", ";", "}", "}", "protected", "char", "getHandleMementoDelimiter", "(", ")", "{", "return", "JavaElement", ".", "JEM_METHOD", ";", "}", "public", "String", "getKey", "(", ")", "{", "try", "{", "return", "getKey", "(", "this", ",", "false", ")", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "return", "null", ";", "}", "}", "public", "int", "getNumberOfParameters", "(", ")", "{", "return", "this", ".", "parameterTypes", "==", "null", "?", "0", ":", "this", ".", "parameterTypes", ".", "length", ";", "}", "public", "String", "[", "]", "getParameterNames", "(", ")", "throws", "JavaModelException", "{", "SourceMethodElementInfo", "info", "=", "(", "SourceMethodElementInfo", ")", "getElementInfo", "(", ")", ";", "char", "[", "]", "[", "]", "names", "=", "info", ".", "getArgumentNames", "(", ")", ";", "return", "CharOperation", ".", "toStrings", "(", "names", ")", ";", "}", "public", "String", "[", "]", "getParameterTypes", "(", ")", "{", "return", "this", ".", "parameterTypes", ";", "}", "public", "ITypeParameter", "getTypeParameter", "(", "String", "typeParameterName", ")", "{", "return", "new", "TypeParameter", "(", "this", ",", "typeParameterName", ")", ";", "}", "public", "ITypeParameter", "[", "]", "getTypeParameters", "(", ")", "throws", "JavaModelException", "{", "SourceMethodElementInfo", "info", "=", "(", "SourceMethodElementInfo", ")", "getElementInfo", "(", ")", ";", "return", "info", ".", "typeParameters", ";", "}", "public", "String", "[", "]", "getTypeParameterSignatures", "(", ")", "throws", "JavaModelException", "{", "ITypeParameter", "[", "]", "typeParameters", "=", "getTypeParameters", "(", ")", ";", "int", "length", "=", "typeParameters", ".", "length", ";", "String", "[", "]", "typeParameterSignatures", "=", "new", "String", "[", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeParameter", "typeParameter", "=", "(", "TypeParameter", ")", "typeParameters", "[", "i", "]", ";", "TypeParameterElementInfo", "info", "=", "(", "TypeParameterElementInfo", ")", "typeParameter", ".", "getElementInfo", "(", ")", ";", "char", "[", "]", "[", "]", "bounds", "=", "info", ".", "bounds", ";", "if", "(", "bounds", "==", "null", ")", "{", "typeParameterSignatures", "[", "i", "]", "=", "Signature", ".", "createTypeParameterSignature", "(", "typeParameter", ".", "getElementName", "(", ")", ",", "CharOperation", ".", "NO_STRINGS", ")", ";", "}", "else", "{", "int", "boundsLength", "=", "bounds", ".", "length", ";", "char", "[", "]", "[", "]", "boundSignatures", "=", "new", "char", "[", "boundsLength", "]", "[", "]", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "boundsLength", ";", "j", "++", ")", "{", "boundSignatures", "[", "j", "]", "=", "Signature", ".", "createCharArrayTypeSignature", "(", "bounds", "[", "j", "]", ",", "false", ")", ";", "}", "typeParameterSignatures", "[", "i", "]", "=", "new", "String", "(", "Signature", ".", "createTypeParameterSignature", "(", "typeParameter", ".", "getElementName", "(", ")", ".", "toCharArray", "(", ")", ",", "boundSignatures", ")", ")", ";", "}", "}", "return", "typeParameterSignatures", ";", "}", "public", "IJavaElement", "getPrimaryElement", "(", "boolean", "checkOwner", ")", "{", "if", "(", "checkOwner", ")", "{", "CompilationUnit", "cu", "=", "(", "CompilationUnit", ")", "getAncestor", "(", "COMPILATION_UNIT", ")", ";", "if", "(", "cu", ".", "isPrimary", "(", ")", ")", "return", "this", ";", "}", "IJavaElement", "primaryParent", "=", "this", ".", "parent", ".", "getPrimaryElement", "(", "false", ")", ";", "return", "(", "(", "IType", ")", "primaryParent", ")", ".", "getMethod", "(", "this", ".", "name", ",", "this", ".", "parameterTypes", ")", ";", "}", "public", "String", "[", "]", "getRawParameterNames", "(", ")", "throws", "JavaModelException", "{", "return", "getParameterNames", "(", ")", ";", "}", "public", "String", "getReturnType", "(", ")", "throws", "JavaModelException", "{", "SourceMethodElementInfo", "info", "=", "(", "SourceMethodElementInfo", ")", "getElementInfo", "(", ")", ";", "return", "Signature", ".", "createTypeSignature", "(", "info", ".", "getReturnTypeName", "(", ")", ",", "false", ")", ";", "}", "public", "String", "getSignature", "(", ")", "throws", "JavaModelException", "{", "SourceMethodElementInfo", "info", "=", "(", "SourceMethodElementInfo", ")", "getElementInfo", "(", ")", ";", "return", "Signature", ".", "createMethodSignature", "(", "this", ".", "parameterTypes", ",", "Signature", ".", "createTypeSignature", "(", "info", ".", "getReturnTypeName", "(", ")", ",", "false", ")", ")", ";", "}", "public", "int", "hashCode", "(", ")", "{", "int", "hash", "=", "super", ".", "hashCode", "(", ")", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "this", ".", "parameterTypes", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "hash", "=", "Util", ".", "combineHashCodes", "(", "hash", ",", "this", ".", "parameterTypes", "[", "i", "]", ".", "hashCode", "(", ")", ")", ";", "}", "return", "hash", ";", "}", "public", "boolean", "isConstructor", "(", ")", "throws", "JavaModelException", "{", "if", "(", "!", "getElementName", "(", ")", ".", "equals", "(", "this", ".", "parent", ".", "getElementName", "(", ")", ")", ")", "{", "return", "false", ";", "}", "SourceMethodElementInfo", "info", "=", "(", "SourceMethodElementInfo", ")", "getElementInfo", "(", ")", ";", "return", "info", ".", "isConstructor", "(", ")", ";", "}", "public", "boolean", "isMainMethod", "(", ")", "throws", "JavaModelException", "{", "return", "this", ".", "isMainMethod", "(", "this", ")", ";", "}", "public", "boolean", "isResolved", "(", ")", "{", "return", "false", ";", "}", "public", "boolean", "isSimilar", "(", "IMethod", "method", ")", "{", "return", "areSimilarMethods", "(", "getElementName", "(", ")", ",", "getParameterTypes", "(", ")", ",", "method", ".", "getElementName", "(", ")", ",", "method", ".", "getParameterTypes", "(", ")", ",", "null", ")", ";", "}", "public", "String", "readableName", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", "super", ".", "readableName", "(", ")", ")", ";", "buffer", ".", "append", "(", "'('", ")", ";", "int", "length", ";", "if", "(", "this", ".", "parameterTypes", "!=", "null", "&&", "(", "length", "=", "this", ".", "parameterTypes", ".", "length", ")", ">", "0", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "buffer", ".", "append", "(", "Signature", ".", "toString", "(", "this", ".", "parameterTypes", "[", "i", "]", ")", ")", ";", "if", "(", "i", "<", "length", "-", "1", ")", "{", "buffer", ".", "append", "(", "\",", "\"", ")", ";", "}", "}", "}", "buffer", ".", "append", "(", "')'", ")", ";", "return", "buffer", ".", "toString", "(", ")", ";", "}", "public", "JavaElement", "resolved", "(", "Binding", "binding", ")", "{", "SourceRefElement", "resolvedHandle", "=", "new", "ResolvedSourceMethod", "(", "this", ".", "parent", ",", "this", ".", "name", ",", "this", ".", "parameterTypes", ",", "new", "String", "(", "binding", ".", "computeUniqueKey", "(", ")", ")", ")", ";", "resolvedHandle", ".", "occurrenceCount", "=", "this", ".", "occurrenceCount", ";", "return", "resolvedHandle", ";", "}", "protected", "void", "toStringInfo", "(", "int", "tab", ",", "StringBuffer", "buffer", ",", "Object", "info", ",", "boolean", "showResolvedInfo", ")", "{", "buffer", ".", "append", "(", "tabString", "(", "tab", ")", ")", ";", "if", "(", "info", "==", "null", ")", "{", "toStringName", "(", "buffer", ")", ";", "buffer", ".", "append", "(", "\"", "(not", "open)\"", ")", ";", "}", "else", "if", "(", "info", "==", "NO_INFO", ")", "{", "toStringName", "(", "buffer", ")", ";", "}", "else", "{", "SourceMethodElementInfo", "methodInfo", "=", "(", "SourceMethodElementInfo", ")", "info", ";", "int", "flags", "=", "methodInfo", ".", "getModifiers", "(", ")", ";", "if", "(", "Flags", ".", "isStatic", "(", "flags", ")", ")", "{", "buffer", ".", "append", "(", "\"static", "\"", ")", ";", "}", "if", "(", "!", "methodInfo", ".", "isConstructor", "(", ")", ")", "{", "buffer", ".", "append", "(", "methodInfo", ".", "getReturnTypeName", "(", ")", ")", ";", "buffer", ".", "append", "(", "'", "'", ")", ";", "}", "toStringName", "(", "buffer", ",", "flags", ")", ";", "}", "}", "protected", "void", "toStringName", "(", "StringBuffer", "buffer", ")", "{", "toStringName", "(", "buffer", ",", "0", ")", ";", "}", "protected", "void", "toStringName", "(", "StringBuffer", "buffer", ",", "int", "flags", ")", "{", "buffer", ".", "append", "(", "getElementName", "(", ")", ")", ";", "buffer", ".", "append", "(", "'('", ")", ";", "String", "[", "]", "parameters", "=", "getParameterTypes", "(", ")", ";", "int", "length", ";", "if", "(", "parameters", "!=", "null", "&&", "(", "length", "=", "parameters", ".", "length", ")", ">", "0", ")", "{", "boolean", "isVarargs", "=", "Flags", ".", "isVarargs", "(", "flags", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "try", "{", "if", "(", "i", "<", "length", "-", "1", ")", "{", "buffer", ".", "append", "(", "Signature", ".", "toString", "(", "parameters", "[", "i", "]", ")", ")", ";", "buffer", ".", "append", "(", "\",", "\"", ")", ";", "}", "else", "if", "(", "isVarargs", ")", "{", "String", "parameter", "=", "parameters", "[", "i", "]", ".", "substring", "(", "1", ")", ";", "buffer", ".", "append", "(", "Signature", ".", "toString", "(", "parameter", ")", ")", ";", "buffer", ".", "append", "(", "\"", "...\"", ")", ";", "}", "else", "{", "buffer", ".", "append", "(", "Signature", ".", "toString", "(", "parameters", "[", "i", "]", ")", ")", ";", "}", "}", "catch", "(", "IllegalArgumentException", "e", ")", "{", "buffer", ".", "append", "(", "\"\"", ")", ";", "buffer", ".", "append", "(", "parameters", "[", "i", "]", ")", ";", "}", "}", "}", "buffer", ".", "append", "(", "')'", ")", ";", "if", "(", "this", ".", "occurrenceCount", ">", "1", ")", "{", "buffer", ".", "append", "(", "\"#\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "occurrenceCount", ")", ";", "}", "}", "}", "</s>" ]
5,513
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "io", ".", "ByteArrayInputStream", ";", "import", "java", ".", "io", ".", "IOException", ";", "import", "java", ".", "io", ".", "InputStream", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "*", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "CoreException", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IStatus", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "NullProgressMonitor", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Path", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "jobs", ".", "ISchedulingRule", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IBuffer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElementDelta", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatus", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatusConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaProject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IPackageFragment", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaConventions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaCore", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Messages", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "CreateCompilationUnitOperation", "extends", "JavaModelOperation", "{", "protected", "String", "name", ";", "protected", "String", "source", "=", "null", ";", "public", "CreateCompilationUnitOperation", "(", "IPackageFragment", "parentElement", ",", "String", "name", ",", "String", "source", ",", "boolean", "force", ")", "{", "super", "(", "null", ",", "new", "IJavaElement", "[", "]", "{", "parentElement", "}", ",", "force", ")", ";", "this", ".", "name", "=", "name", ";", "this", ".", "source", "=", "source", ";", "}", "protected", "void", "executeOperation", "(", ")", "throws", "JavaModelException", "{", "try", "{", "beginTask", "(", "Messages", ".", "operation_createUnitProgress", ",", "2", ")", ";", "JavaElementDelta", "delta", "=", "newJavaElementDelta", "(", ")", ";", "ICompilationUnit", "unit", "=", "getCompilationUnit", "(", ")", ";", "IPackageFragment", "pkg", "=", "(", "IPackageFragment", ")", "getParentElement", "(", ")", ";", "IContainer", "folder", "=", "(", "IContainer", ")", "pkg", ".", "getResource", "(", ")", ";", "worked", "(", "1", ")", ";", "IFile", "compilationUnitFile", "=", "folder", ".", "getFile", "(", "new", "Path", "(", "this", ".", "name", ")", ")", ";", "if", "(", "compilationUnitFile", ".", "exists", "(", ")", ")", "{", "if", "(", "this", ".", "force", ")", "{", "IBuffer", "buffer", "=", "unit", ".", "getBuffer", "(", ")", ";", "if", "(", "buffer", "==", "null", ")", "return", ";", "buffer", ".", "setContents", "(", "this", ".", "source", ")", ";", "unit", ".", "save", "(", "new", "NullProgressMonitor", "(", ")", ",", "false", ")", ";", "this", ".", "resultElements", "=", "new", "IJavaElement", "[", "]", "{", "unit", "}", ";", "if", "(", "!", "Util", ".", "isExcluded", "(", "unit", ")", "&&", "unit", ".", "getParent", "(", ")", ".", "exists", "(", ")", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "resultElements", ".", "length", ";", "i", "++", ")", "{", "delta", ".", "changed", "(", "this", ".", "resultElements", "[", "i", "]", ",", "IJavaElementDelta", ".", "F_CONTENT", ")", ";", "}", "addDelta", "(", "delta", ")", ";", "}", "}", "else", "{", "throw", "new", "JavaModelException", "(", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "NAME_COLLISION", ",", "Messages", ".", "bind", "(", "Messages", ".", "status_nameCollision", ",", "compilationUnitFile", ".", "getFullPath", "(", ")", ".", "toString", "(", ")", ")", ")", ")", ";", "}", "}", "else", "{", "try", "{", "String", "encoding", "=", "null", ";", "try", "{", "encoding", "=", "folder", ".", "getDefaultCharset", "(", ")", ";", "}", "catch", "(", "CoreException", "ce", ")", "{", "}", "InputStream", "stream", "=", "new", "ByteArrayInputStream", "(", "encoding", "==", "null", "?", "this", ".", "source", ".", "getBytes", "(", ")", ":", "this", ".", "source", ".", "getBytes", "(", "encoding", ")", ")", ";", "createFile", "(", "folder", ",", "unit", ".", "getElementName", "(", ")", ",", "stream", ",", "this", ".", "force", ")", ";", "this", ".", "resultElements", "=", "new", "IJavaElement", "[", "]", "{", "unit", "}", ";", "if", "(", "!", "Util", ".", "isExcluded", "(", "unit", ")", "&&", "unit", ".", "getParent", "(", ")", ".", "exists", "(", ")", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "resultElements", ".", "length", ";", "i", "++", ")", "{", "delta", ".", "added", "(", "this", ".", "resultElements", "[", "i", "]", ")", ";", "}", "addDelta", "(", "delta", ")", ";", "}", "}", "catch", "(", "IOException", "e", ")", "{", "throw", "new", "JavaModelException", "(", "e", ",", "IJavaModelStatusConstants", ".", "IO_EXCEPTION", ")", ";", "}", "}", "worked", "(", "1", ")", ";", "}", "finally", "{", "done", "(", ")", ";", "}", "}", "protected", "ICompilationUnit", "getCompilationUnit", "(", ")", "{", "return", "(", "(", "IPackageFragment", ")", "getParentElement", "(", ")", ")", ".", "getCompilationUnit", "(", "this", ".", "name", ")", ";", "}", "protected", "ISchedulingRule", "getSchedulingRule", "(", ")", "{", "IResource", "resource", "=", "getCompilationUnit", "(", ")", ".", "getResource", "(", ")", ";", "IWorkspace", "workspace", "=", "resource", ".", "getWorkspace", "(", ")", ";", "if", "(", "resource", ".", "exists", "(", ")", ")", "{", "return", "workspace", ".", "getRuleFactory", "(", ")", ".", "modifyRule", "(", "resource", ")", ";", "}", "else", "{", "return", "workspace", ".", "getRuleFactory", "(", ")", ".", "createRule", "(", "resource", ")", ";", "}", "}", "public", "IJavaModelStatus", "verify", "(", ")", "{", "if", "(", "getParentElement", "(", ")", "==", "null", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "NO_ELEMENTS_TO_PROCESS", ")", ";", "}", "IJavaProject", "project", "=", "getParentElement", "(", ")", ".", "getJavaProject", "(", ")", ";", "if", "(", "JavaConventions", ".", "validateCompilationUnitName", "(", "this", ".", "name", ",", "project", ".", "getOption", "(", "JavaCore", ".", "COMPILER_SOURCE", ",", "true", ")", ",", "project", ".", "getOption", "(", "JavaCore", ".", "COMPILER_COMPLIANCE", ",", "true", ")", ")", ".", "getSeverity", "(", ")", "==", "IStatus", ".", "ERROR", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_NAME", ",", "this", ".", "name", ")", ";", "}", "if", "(", "this", ".", "source", "==", "null", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CONTENTS", ")", ";", "}", "return", "JavaModelStatus", ".", "VERIFIED_OK", ";", "}", "}", "</s>" ]
5,514
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "io", ".", "ByteArrayInputStream", ";", "import", "java", ".", "io", ".", "UnsupportedEncodingException", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IFile", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IResource", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IWorkspace", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "CoreException", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "jobs", ".", "ISchedulingRule", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IBuffer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatus", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatusConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaProject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaCore", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Messages", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "CommitWorkingCopyOperation", "extends", "JavaModelOperation", "{", "public", "CommitWorkingCopyOperation", "(", "ICompilationUnit", "element", ",", "boolean", "force", ")", "{", "super", "(", "new", "IJavaElement", "[", "]", "{", "element", "}", ",", "force", ")", ";", "}", "protected", "void", "executeOperation", "(", ")", "throws", "JavaModelException", "{", "try", "{", "beginTask", "(", "Messages", ".", "workingCopy_commit", ",", "2", ")", ";", "CompilationUnit", "workingCopy", "=", "getCompilationUnit", "(", ")", ";", "if", "(", "ExternalJavaProject", ".", "EXTERNAL_PROJECT_NAME", ".", "equals", "(", "workingCopy", ".", "getJavaProject", "(", ")", ".", "getElementName", "(", ")", ")", ")", "{", "workingCopy", ".", "getBuffer", "(", ")", ".", "save", "(", "this", ".", "progressMonitor", ",", "this", ".", "force", ")", ";", "return", ";", "}", "ICompilationUnit", "primary", "=", "workingCopy", ".", "getPrimary", "(", ")", ";", "boolean", "isPrimary", "=", "workingCopy", ".", "isPrimary", "(", ")", ";", "JavaElementDeltaBuilder", "deltaBuilder", "=", "null", ";", "PackageFragmentRoot", "root", "=", "(", "PackageFragmentRoot", ")", "workingCopy", ".", "getAncestor", "(", "IJavaElement", ".", "PACKAGE_FRAGMENT_ROOT", ")", ";", "boolean", "isIncluded", "=", "!", "Util", ".", "isExcluded", "(", "workingCopy", ")", ";", "IFile", "resource", "=", "(", "IFile", ")", "workingCopy", ".", "getResource", "(", ")", ";", "IJavaProject", "project", "=", "root", ".", "getJavaProject", "(", ")", ";", "if", "(", "isPrimary", "||", "(", "root", ".", "validateOnClasspath", "(", ")", ".", "isOK", "(", ")", "&&", "isIncluded", "&&", "resource", ".", "isAccessible", "(", ")", "&&", "Util", ".", "isValidCompilationUnitName", "(", "workingCopy", ".", "getElementName", "(", ")", ",", "project", ".", "getOption", "(", "JavaCore", ".", "COMPILER_SOURCE", ",", "true", ")", ",", "project", ".", "getOption", "(", "JavaCore", ".", "COMPILER_COMPLIANCE", ",", "true", ")", ")", ")", ")", "{", "if", "(", "!", "isPrimary", "&&", "!", "primary", ".", "isOpen", "(", ")", ")", "{", "primary", ".", "open", "(", "null", ")", ";", "}", "if", "(", "isIncluded", "&&", "(", "!", "isPrimary", "||", "!", "workingCopy", ".", "isConsistent", "(", ")", ")", ")", "{", "deltaBuilder", "=", "new", "JavaElementDeltaBuilder", "(", "primary", ")", ";", "}", "IBuffer", "primaryBuffer", "=", "primary", ".", "getBuffer", "(", ")", ";", "if", "(", "!", "isPrimary", ")", "{", "if", "(", "primaryBuffer", "==", "null", ")", "return", ";", "char", "[", "]", "primaryContents", "=", "primaryBuffer", ".", "getCharacters", "(", ")", ";", "boolean", "hasSaved", "=", "false", ";", "try", "{", "IBuffer", "workingCopyBuffer", "=", "workingCopy", ".", "getBuffer", "(", ")", ";", "if", "(", "workingCopyBuffer", "==", "null", ")", "return", ";", "primaryBuffer", ".", "setContents", "(", "workingCopyBuffer", ".", "getCharacters", "(", ")", ")", ";", "primaryBuffer", ".", "save", "(", "this", ".", "progressMonitor", ",", "this", ".", "force", ")", ";", "primary", ".", "makeConsistent", "(", "this", ")", ";", "hasSaved", "=", "true", ";", "}", "finally", "{", "if", "(", "!", "hasSaved", ")", "{", "primaryBuffer", ".", "setContents", "(", "primaryContents", ")", ";", "}", "}", "}", "else", "{", "primaryBuffer", ".", "save", "(", "this", ".", "progressMonitor", ",", "this", ".", "force", ")", ";", "primary", ".", "makeConsistent", "(", "this", ")", ";", "}", "}", "else", "{", "String", "encoding", "=", "null", ";", "try", "{", "encoding", "=", "resource", ".", "getCharset", "(", ")", ";", "}", "catch", "(", "CoreException", "ce", ")", "{", "}", "String", "contents", "=", "workingCopy", ".", "getSource", "(", ")", ";", "if", "(", "contents", "==", "null", ")", "return", ";", "try", "{", "byte", "[", "]", "bytes", "=", "encoding", "==", "null", "?", "contents", ".", "getBytes", "(", ")", ":", "contents", ".", "getBytes", "(", "encoding", ")", ";", "ByteArrayInputStream", "stream", "=", "new", "ByteArrayInputStream", "(", "bytes", ")", ";", "if", "(", "resource", ".", "exists", "(", ")", ")", "{", "resource", ".", "setContents", "(", "stream", ",", "this", ".", "force", "?", "IResource", ".", "FORCE", "|", "IResource", ".", "KEEP_HISTORY", ":", "IResource", ".", "KEEP_HISTORY", ",", "null", ")", ";", "}", "else", "{", "resource", ".", "create", "(", "stream", ",", "this", ".", "force", ",", "this", ".", "progressMonitor", ")", ";", "}", "}", "catch", "(", "CoreException", "e", ")", "{", "throw", "new", "JavaModelException", "(", "e", ")", ";", "}", "catch", "(", "UnsupportedEncodingException", "e", ")", "{", "throw", "new", "JavaModelException", "(", "e", ",", "IJavaModelStatusConstants", ".", "IO_EXCEPTION", ")", ";", "}", "}", "setAttribute", "(", "HAS_MODIFIED_RESOURCE_ATTR", ",", "TRUE", ")", ";", "workingCopy", ".", "updateTimeStamp", "(", "(", "CompilationUnit", ")", "primary", ")", ";", "workingCopy", ".", "makeConsistent", "(", "this", ")", ";", "worked", "(", "1", ")", ";", "if", "(", "deltaBuilder", "!=", "null", ")", "{", "deltaBuilder", ".", "buildDeltas", "(", ")", ";", "if", "(", "deltaBuilder", ".", "delta", "!=", "null", ")", "{", "addDelta", "(", "deltaBuilder", ".", "delta", ")", ";", "}", "}", "worked", "(", "1", ")", ";", "}", "finally", "{", "done", "(", ")", ";", "}", "}", "protected", "CompilationUnit", "getCompilationUnit", "(", ")", "{", "return", "(", "CompilationUnit", ")", "getElementToProcess", "(", ")", ";", "}", "protected", "ISchedulingRule", "getSchedulingRule", "(", ")", "{", "IResource", "resource", "=", "getElementToProcess", "(", ")", ".", "getResource", "(", ")", ";", "if", "(", "resource", "==", "null", ")", "return", "null", ";", "IWorkspace", "workspace", "=", "resource", ".", "getWorkspace", "(", ")", ";", "if", "(", "resource", ".", "exists", "(", ")", ")", "{", "return", "workspace", ".", "getRuleFactory", "(", ")", ".", "modifyRule", "(", "resource", ")", ";", "}", "else", "{", "return", "workspace", ".", "getRuleFactory", "(", ")", ".", "createRule", "(", "resource", ")", ";", "}", "}", "public", "IJavaModelStatus", "verify", "(", ")", "{", "CompilationUnit", "cu", "=", "getCompilationUnit", "(", ")", ";", "if", "(", "!", "cu", ".", "isWorkingCopy", "(", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_ELEMENT_TYPES", ",", "cu", ")", ";", "}", "if", "(", "cu", ".", "hasResourceChanged", "(", ")", "&&", "!", "this", ".", "force", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "UPDATE_CONFLICT", ")", ";", "}", "return", "JavaModelStatus", ".", "VERIFIED_OK", ";", "}", "}", "</s>" ]
5,515
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IProject", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IPath", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IClasspathEntry", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatus", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "builder", ".", "JavaBuilder", ";", "public", "class", "ClasspathValidation", "{", "private", "JavaProject", "project", ";", "public", "ClasspathValidation", "(", "JavaProject", "project", ")", "{", "this", ".", "project", "=", "project", ";", "}", "public", "void", "validate", "(", ")", "{", "JavaModelManager", ".", "PerProjectInfo", "perProjectInfo", ";", "try", "{", "perProjectInfo", "=", "this", ".", "project", ".", "getPerProjectInfo", "(", ")", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "IProject", "resource", "=", "this", ".", "project", ".", "getProject", "(", ")", ";", "if", "(", "resource", ".", "isAccessible", "(", ")", ")", "{", "this", ".", "project", ".", "flushClasspathProblemMarkers", "(", "true", ",", "true", ")", ";", "JavaBuilder", ".", "removeProblemsAndTasksFor", "(", "resource", ")", ";", "}", "return", ";", "}", "IClasspathEntry", "[", "]", "rawClasspath", ";", "IPath", "outputLocation", ";", "IJavaModelStatus", "status", ";", "synchronized", "(", "perProjectInfo", ")", "{", "rawClasspath", "=", "perProjectInfo", ".", "rawClasspath", ";", "outputLocation", "=", "perProjectInfo", ".", "outputLocation", ";", "status", "=", "perProjectInfo", ".", "rawClasspathStatus", ";", "}", "this", ".", "project", ".", "flushClasspathProblemMarkers", "(", "false", ",", "true", ")", ";", "if", "(", "!", "status", ".", "isOK", "(", ")", ")", "this", ".", "project", ".", "createClasspathProblemMarker", "(", "status", ")", ";", "this", ".", "project", ".", "flushClasspathProblemMarkers", "(", "false", ",", "false", ")", ";", "if", "(", "rawClasspath", "!=", "JavaProject", ".", "INVALID_CLASSPATH", "&&", "outputLocation", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "rawClasspath", ".", "length", ";", "i", "++", ")", "{", "status", "=", "ClasspathEntry", ".", "validateClasspathEntry", "(", "this", ".", "project", ",", "rawClasspath", "[", "i", "]", ",", "false", ",", "false", ")", ";", "if", "(", "!", "status", ".", "isOK", "(", ")", ")", "{", "this", ".", "project", ".", "createClasspathProblemMarker", "(", "status", ")", ";", "}", "}", "status", "=", "ClasspathEntry", ".", "validateClasspath", "(", "this", ".", "project", ",", "rawClasspath", ",", "outputLocation", ")", ";", "if", "(", "!", "status", ".", "isOK", "(", ")", ")", "this", ".", "project", ".", "createClasspathProblemMarker", "(", "status", ")", ";", "}", "}", "}", "</s>" ]
5,516
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "io", ".", "IOException", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "java", ".", "util", ".", "zip", ".", "ZipEntry", ";", "import", "java", ".", "util", ".", "zip", ".", "ZipFile", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IContainer", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IFile", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IFolder", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IResource", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "CoreException", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IPath", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IProgressMonitor", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IStatus", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Path", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "IProblem", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileReader", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFormatException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "IBinaryType", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "IDependent", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "SuffixConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "MementoTokenizer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "ClassFile", "extends", "Openable", "implements", "IClassFile", ",", "SuffixConstants", "{", "protected", "String", "name", ";", "protected", "BinaryType", "binaryType", "=", "null", ";", "protected", "ClassFile", "(", "PackageFragment", "parent", ",", "String", "nameWithoutExtension", ")", "{", "super", "(", "parent", ")", ";", "this", ".", "name", "=", "nameWithoutExtension", ";", "}", "public", "ICompilationUnit", "becomeWorkingCopy", "(", "IProblemRequestor", "problemRequestor", ",", "WorkingCopyOwner", "owner", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "JavaModelManager", "manager", "=", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ";", "CompilationUnit", "workingCopy", "=", "new", "ClassFileWorkingCopy", "(", "this", ",", "owner", "==", "null", "?", "DefaultWorkingCopyOwner", ".", "PRIMARY", ":", "owner", ")", ";", "JavaModelManager", ".", "PerWorkingCopyInfo", "perWorkingCopyInfo", "=", "manager", ".", "getPerWorkingCopyInfo", "(", "workingCopy", ",", "false", ",", "true", ",", "null", ")", ";", "if", "(", "perWorkingCopyInfo", "==", "null", ")", "{", "close", "(", ")", ";", "BecomeWorkingCopyOperation", "operation", "=", "new", "BecomeWorkingCopyOperation", "(", "workingCopy", ",", "problemRequestor", ")", ";", "operation", ".", "runOperation", "(", "monitor", ")", ";", "return", "workingCopy", ";", "}", "return", "perWorkingCopyInfo", ".", "workingCopy", ";", "}", "protected", "boolean", "buildStructure", "(", "OpenableElementInfo", "info", ",", "IProgressMonitor", "pm", ",", "Map", "newElements", ",", "IResource", "underlyingResource", ")", "throws", "JavaModelException", "{", "IBinaryType", "typeInfo", "=", "getBinaryTypeInfo", "(", "(", "IFile", ")", "underlyingResource", ")", ";", "if", "(", "typeInfo", "==", "null", ")", "{", "info", ".", "setChildren", "(", "new", "IJavaElement", "[", "]", "{", "}", ")", ";", "return", "false", ";", "}", "IType", "type", "=", "getType", "(", ")", ";", "info", ".", "setChildren", "(", "new", "IJavaElement", "[", "]", "{", "type", "}", ")", ";", "newElements", ".", "put", "(", "type", ",", "typeInfo", ")", ";", "(", "(", "ClassFileInfo", ")", "info", ")", ".", "readBinaryChildren", "(", "this", ",", "(", "HashMap", ")", "newElements", ",", "typeInfo", ")", ";", "return", "true", ";", "}", "public", "void", "codeComplete", "(", "int", "offset", ",", "ICompletionRequestor", "requestor", ")", "throws", "JavaModelException", "{", "codeComplete", "(", "offset", ",", "requestor", ",", "DefaultWorkingCopyOwner", ".", "PRIMARY", ")", ";", "}", "public", "void", "codeComplete", "(", "int", "offset", ",", "ICompletionRequestor", "requestor", ",", "WorkingCopyOwner", "owner", ")", "throws", "JavaModelException", "{", "if", "(", "requestor", "==", "null", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"\"", ")", ";", "}", "codeComplete", "(", "offset", ",", "new", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "codeassist", ".", "CompletionRequestorWrapper", "(", "requestor", ")", ",", "owner", ")", ";", "}", "public", "void", "codeComplete", "(", "int", "offset", ",", "CompletionRequestor", "requestor", ")", "throws", "JavaModelException", "{", "codeComplete", "(", "offset", ",", "requestor", ",", "DefaultWorkingCopyOwner", ".", "PRIMARY", ")", ";", "}", "public", "void", "codeComplete", "(", "int", "offset", ",", "CompletionRequestor", "requestor", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "codeComplete", "(", "offset", ",", "requestor", ",", "DefaultWorkingCopyOwner", ".", "PRIMARY", ",", "monitor", ")", ";", "}", "public", "void", "codeComplete", "(", "int", "offset", ",", "CompletionRequestor", "requestor", ",", "WorkingCopyOwner", "owner", ")", "throws", "JavaModelException", "{", "codeComplete", "(", "offset", ",", "requestor", ",", "owner", ",", "null", ")", ";", "}", "public", "void", "codeComplete", "(", "int", "offset", ",", "CompletionRequestor", "requestor", ",", "WorkingCopyOwner", "owner", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "String", "source", "=", "getSource", "(", ")", ";", "if", "(", "source", "!=", "null", ")", "{", "BinaryType", "type", "=", "(", "BinaryType", ")", "getType", "(", ")", ";", "BasicCompilationUnit", "cu", "=", "new", "BasicCompilationUnit", "(", "getSource", "(", ")", ".", "toCharArray", "(", ")", ",", "null", ",", "type", ".", "sourceFileName", "(", "(", "IBinaryType", ")", "type", ".", "getElementInfo", "(", ")", ")", ",", "getJavaProject", "(", ")", ")", ";", "codeComplete", "(", "cu", ",", "cu", ",", "offset", ",", "requestor", ",", "owner", ",", "null", ",", "monitor", ")", ";", "}", "}", "public", "IJavaElement", "[", "]", "codeSelect", "(", "int", "offset", ",", "int", "length", ")", "throws", "JavaModelException", "{", "return", "codeSelect", "(", "offset", ",", "length", ",", "DefaultWorkingCopyOwner", ".", "PRIMARY", ")", ";", "}", "public", "IJavaElement", "[", "]", "codeSelect", "(", "int", "offset", ",", "int", "length", ",", "WorkingCopyOwner", "owner", ")", "throws", "JavaModelException", "{", "IBuffer", "buffer", "=", "getBuffer", "(", ")", ";", "char", "[", "]", "contents", ";", "if", "(", "buffer", "!=", "null", "&&", "(", "contents", "=", "buffer", ".", "getCharacters", "(", ")", ")", "!=", "null", ")", "{", "BinaryType", "type", "=", "(", "BinaryType", ")", "getType", "(", ")", ";", "BasicCompilationUnit", "cu", "=", "new", "BasicCompilationUnit", "(", "contents", ",", "null", ",", "type", ".", "sourceFileName", "(", "(", "IBinaryType", ")", "type", ".", "getElementInfo", "(", ")", ")", ")", ";", "return", "super", ".", "codeSelect", "(", "cu", ",", "offset", ",", "length", ",", "owner", ")", ";", "}", "else", "{", "return", "new", "IJavaElement", "[", "]", "{", "}", ";", "}", "}", "protected", "Object", "createElementInfo", "(", ")", "{", "return", "new", "ClassFileInfo", "(", ")", ";", "}", "public", "boolean", "equals", "(", "Object", "o", ")", "{", "if", "(", "!", "(", "o", "instanceof", "ClassFile", ")", ")", "return", "false", ";", "ClassFile", "other", "=", "(", "ClassFile", ")", "o", ";", "return", "this", ".", "name", ".", "equals", "(", "other", ".", "name", ")", "&&", "this", ".", "parent", ".", "equals", "(", "other", ".", "parent", ")", ";", "}", "public", "boolean", "existsUsingJarTypeCache", "(", ")", "{", "if", "(", "getPackageFragmentRoot", "(", ")", ".", "isArchive", "(", ")", ")", "{", "JavaModelManager", "manager", "=", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ";", "IType", "type", "=", "getType", "(", ")", ";", "Object", "info", "=", "manager", ".", "getInfo", "(", "type", ")", ";", "if", "(", "info", "==", "JavaModelCache", ".", "NON_EXISTING_JAR_TYPE_INFO", ")", "return", "false", ";", "else", "if", "(", "info", "!=", "null", ")", "return", "true", ";", "JavaElementInfo", "parentInfo", "=", "(", "JavaElementInfo", ")", "manager", ".", "getInfo", "(", "getParent", "(", ")", ")", ";", "if", "(", "parentInfo", "!=", "null", ")", "{", "IJavaElement", "[", "]", "children", "=", "parentInfo", ".", "getChildren", "(", ")", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "children", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "this", ".", "name", ".", "equals", "(", "(", "(", "ClassFile", ")", "children", "[", "i", "]", ")", ".", "name", ")", ")", "return", "true", ";", "}", "return", "false", ";", "}", "try", "{", "info", "=", "getJarBinaryTypeInfo", "(", "(", "PackageFragment", ")", "getParent", "(", ")", ",", "true", ")", ";", "}", "catch", "(", "CoreException", "e", ")", "{", "}", "catch", "(", "IOException", "e", ")", "{", "}", "catch", "(", "ClassFormatException", "e", ")", "{", "}", "manager", ".", "putJarTypeInfo", "(", "type", ",", "info", "==", "null", "?", "JavaModelCache", ".", "NON_EXISTING_JAR_TYPE_INFO", ":", "info", ")", ";", "return", "info", "!=", "null", ";", "}", "else", "return", "exists", "(", ")", ";", "}", "protected", "IJavaElement", "findElement", "(", "IJavaElement", "elt", ",", "int", "position", ",", "SourceMapper", "mapper", ")", "{", "SourceRange", "range", "=", "mapper", ".", "getSourceRange", "(", "elt", ")", ";", "if", "(", "range", "==", "null", "||", "position", "<", "range", ".", "getOffset", "(", ")", "||", "range", ".", "getOffset", "(", ")", "+", "range", ".", "getLength", "(", ")", "-", "1", "<", "position", ")", "{", "return", "null", ";", "}", "if", "(", "elt", "instanceof", "IParent", ")", "{", "try", "{", "IJavaElement", "[", "]", "children", "=", "(", "(", "IParent", ")", "elt", ")", ".", "getChildren", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "children", ".", "length", ";", "i", "++", ")", "{", "IJavaElement", "match", "=", "findElement", "(", "children", "[", "i", "]", ",", "position", ",", "mapper", ")", ";", "if", "(", "match", "!=", "null", ")", "{", "return", "match", ";", "}", "}", "}", "catch", "(", "JavaModelException", "npe", ")", "{", "}", "}", "return", "elt", ";", "}", "public", "IType", "findPrimaryType", "(", ")", "{", "IType", "primaryType", "=", "getType", "(", ")", ";", "if", "(", "primaryType", ".", "exists", "(", ")", ")", "{", "return", "primaryType", ";", "}", "return", "null", ";", "}", "public", "String", "getAttachedJavadoc", "(", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "return", "getType", "(", ")", ".", "getAttachedJavadoc", "(", "monitor", ")", ";", "}", "public", "IBinaryType", "getBinaryTypeInfo", "(", "IFile", "file", ")", "throws", "JavaModelException", "{", "return", "getBinaryTypeInfo", "(", "file", ",", "true", ")", ";", "}", "public", "IBinaryType", "getBinaryTypeInfo", "(", "IFile", "file", ",", "boolean", "fullyInitialize", ")", "throws", "JavaModelException", "{", "JavaElement", "pkg", "=", "(", "JavaElement", ")", "getParent", "(", ")", ";", "if", "(", "pkg", "instanceof", "JarPackageFragment", ")", "{", "try", "{", "IBinaryType", "info", "=", "getJarBinaryTypeInfo", "(", "(", "PackageFragment", ")", "pkg", ",", "fullyInitialize", ")", ";", "if", "(", "info", "==", "null", ")", "{", "throw", "newNotPresentException", "(", ")", ";", "}", "return", "info", ";", "}", "catch", "(", "ClassFormatException", "cfe", ")", "{", "if", "(", "JavaCore", ".", "getPlugin", "(", ")", ".", "isDebugging", "(", ")", ")", "{", "cfe", ".", "printStackTrace", "(", "System", ".", "err", ")", ";", "}", "return", "null", ";", "}", "catch", "(", "IOException", "ioe", ")", "{", "throw", "new", "JavaModelException", "(", "ioe", ",", "IJavaModelStatusConstants", ".", "IO_EXCEPTION", ")", ";", "}", "catch", "(", "CoreException", "e", ")", "{", "if", "(", "e", "instanceof", "JavaModelException", ")", "{", "throw", "(", "JavaModelException", ")", "e", ";", "}", "else", "{", "throw", "new", "JavaModelException", "(", "e", ")", ";", "}", "}", "}", "else", "{", "byte", "[", "]", "contents", "=", "Util", ".", "getResourceContentsAsByteArray", "(", "file", ")", ";", "try", "{", "return", "new", "ClassFileReader", "(", "contents", ",", "file", ".", "getFullPath", "(", ")", ".", "toString", "(", ")", ".", "toCharArray", "(", ")", ",", "fullyInitialize", ")", ";", "}", "catch", "(", "ClassFormatException", "cfe", ")", "{", "return", "null", ";", "}", "}", "}", "public", "byte", "[", "]", "getBytes", "(", ")", "throws", "JavaModelException", "{", "JavaElement", "pkg", "=", "(", "JavaElement", ")", "getParent", "(", ")", ";", "if", "(", "pkg", "instanceof", "JarPackageFragment", ")", "{", "JarPackageFragmentRoot", "root", "=", "(", "JarPackageFragmentRoot", ")", "pkg", ".", "getParent", "(", ")", ";", "ZipFile", "zip", "=", "null", ";", "try", "{", "zip", "=", "root", ".", "getJar", "(", ")", ";", "String", "entryName", "=", "Util", ".", "concatWith", "(", "(", "(", "PackageFragment", ")", "pkg", ")", ".", "names", ",", "getElementName", "(", ")", ",", "'/'", ")", ";", "ZipEntry", "ze", "=", "zip", ".", "getEntry", "(", "entryName", ")", ";", "if", "(", "ze", "!=", "null", ")", "{", "return", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "Util", ".", "getZipEntryByteContent", "(", "ze", ",", "zip", ")", ";", "}", "throw", "new", "JavaModelException", "(", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "ELEMENT_DOES_NOT_EXIST", ",", "this", ")", ")", ";", "}", "catch", "(", "IOException", "ioe", ")", "{", "throw", "new", "JavaModelException", "(", "ioe", ",", "IJavaModelStatusConstants", ".", "IO_EXCEPTION", ")", ";", "}", "catch", "(", "CoreException", "e", ")", "{", "if", "(", "e", "instanceof", "JavaModelException", ")", "{", "throw", "(", "JavaModelException", ")", "e", ";", "}", "else", "{", "throw", "new", "JavaModelException", "(", "e", ")", ";", "}", "}", "finally", "{", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "closeZipFile", "(", "zip", ")", ";", "}", "}", "else", "{", "IFile", "file", "=", "(", "IFile", ")", "resource", "(", ")", ";", "return", "Util", ".", "getResourceContentsAsByteArray", "(", "file", ")", ";", "}", "}", "private", "IBinaryType", "getJarBinaryTypeInfo", "(", "PackageFragment", "pkg", ",", "boolean", "fullyInitialize", ")", "throws", "CoreException", ",", "IOException", ",", "ClassFormatException", "{", "JarPackageFragmentRoot", "root", "=", "(", "JarPackageFragmentRoot", ")", "pkg", ".", "getParent", "(", ")", ";", "ZipFile", "zip", "=", "null", ";", "try", "{", "zip", "=", "root", ".", "getJar", "(", ")", ";", "String", "entryName", "=", "Util", ".", "concatWith", "(", "pkg", ".", "names", ",", "getElementName", "(", ")", ",", "'/'", ")", ";", "ZipEntry", "ze", "=", "zip", ".", "getEntry", "(", "entryName", ")", ";", "if", "(", "ze", "!=", "null", ")", "{", "byte", "contents", "[", "]", "=", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "Util", ".", "getZipEntryByteContent", "(", "ze", ",", "zip", ")", ";", "String", "fileName", "=", "root", ".", "getHandleIdentifier", "(", ")", "+", "IDependent", ".", "JAR_FILE_ENTRY_SEPARATOR", "+", "entryName", ";", "return", "new", "ClassFileReader", "(", "contents", ",", "fileName", ".", "toCharArray", "(", ")", ",", "fullyInitialize", ")", ";", "}", "}", "finally", "{", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "closeZipFile", "(", "zip", ")", ";", "}", "return", "null", ";", "}", "public", "IBuffer", "getBuffer", "(", ")", "throws", "JavaModelException", "{", "IStatus", "status", "=", "validateClassFile", "(", ")", ";", "if", "(", "status", ".", "isOK", "(", ")", ")", "{", "return", "super", ".", "getBuffer", "(", ")", ";", "}", "else", "{", "Object", "info", "=", "(", "(", "ClassFile", ")", "getClassFile", "(", ")", ")", ".", "getBinaryTypeInfo", "(", "(", "IFile", ")", "resource", "(", ")", ")", ";", "IBuffer", "buffer", "=", "openBuffer", "(", "null", ",", "info", ")", ";", "if", "(", "buffer", "!=", "null", "&&", "!", "(", "buffer", "instanceof", "NullBuffer", ")", ")", "return", "buffer", ";", "switch", "(", "status", ".", "getCode", "(", ")", ")", "{", "case", "IJavaModelStatusConstants", ".", "ELEMENT_NOT_ON_CLASSPATH", ":", "case", "IJavaModelStatusConstants", ".", "INVALID_ELEMENT_TYPES", ":", "return", "null", ";", "default", ":", "throw", "new", "JavaModelException", "(", "(", "IJavaModelStatus", ")", "status", ")", ";", "}", "}", "}", "public", "IClassFile", "getClassFile", "(", ")", "{", "return", "this", ";", "}", "public", "ITypeRoot", "getTypeRoot", "(", ")", "{", "return", "this", ";", "}", "public", "IResource", "getCorrespondingResource", "(", ")", "throws", "JavaModelException", "{", "IPackageFragmentRoot", "root", "=", "(", "IPackageFragmentRoot", ")", "getParent", "(", ")", ".", "getParent", "(", ")", ";", "if", "(", "root", ".", "isArchive", "(", ")", ")", "{", "return", "null", ";", "}", "else", "{", "return", "getUnderlyingResource", "(", ")", ";", "}", "}", "public", "IJavaElement", "getElementAt", "(", "int", "position", ")", "throws", "JavaModelException", "{", "IJavaElement", "parentElement", "=", "getParent", "(", ")", ";", "while", "(", "parentElement", ".", "getElementType", "(", ")", "!=", "IJavaElement", ".", "PACKAGE_FRAGMENT_ROOT", ")", "{", "parentElement", "=", "parentElement", ".", "getParent", "(", ")", ";", "}", "PackageFragmentRoot", "root", "=", "(", "PackageFragmentRoot", ")", "parentElement", ";", "SourceMapper", "mapper", "=", "root", ".", "getSourceMapper", "(", ")", ";", "if", "(", "mapper", "==", "null", ")", "{", "return", "null", ";", "}", "else", "{", "getBuffer", "(", ")", ";", "IType", "type", "=", "getType", "(", ")", ";", "return", "findElement", "(", "type", ",", "position", ",", "mapper", ")", ";", "}", "}", "public", "IJavaElement", "getElementAtConsideringSibling", "(", "int", "position", ")", "throws", "JavaModelException", "{", "IPackageFragment", "fragment", "=", "(", "IPackageFragment", ")", "getParent", "(", ")", ";", "PackageFragmentRoot", "root", "=", "(", "PackageFragmentRoot", ")", "fragment", ".", "getAncestor", "(", "IJavaElement", ".", "PACKAGE_FRAGMENT_ROOT", ")", ";", "SourceMapper", "mapper", "=", "root", ".", "getSourceMapper", "(", ")", ";", "if", "(", "mapper", "==", "null", ")", "{", "return", "null", ";", "}", "else", "{", "int", "index", "=", "this", ".", "name", ".", "indexOf", "(", "'$'", ")", ";", "int", "prefixLength", "=", "index", "<", "0", "?", "this", ".", "name", ".", "length", "(", ")", ":", "index", ";", "IType", "type", "=", "null", ";", "int", "start", "=", "-", "1", ";", "int", "end", "=", "Integer", ".", "MAX_VALUE", ";", "IJavaElement", "[", "]", "children", "=", "fragment", ".", "getChildren", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "children", ".", "length", ";", "i", "++", ")", "{", "String", "childName", "=", "children", "[", "i", "]", ".", "getElementName", "(", ")", ";", "int", "childIndex", "=", "childName", ".", "indexOf", "(", "'$'", ")", ";", "int", "childPrefixLength", "=", "childIndex", "<", "0", "?", "childName", ".", "indexOf", "(", "'.'", ")", ":", "childIndex", ";", "if", "(", "prefixLength", "==", "childPrefixLength", "&&", "this", ".", "name", ".", "regionMatches", "(", "0", ",", "childName", ",", "0", ",", "prefixLength", ")", ")", "{", "IClassFile", "classFile", "=", "(", "IClassFile", ")", "children", "[", "i", "]", ";", "classFile", ".", "getBuffer", "(", ")", ";", "SourceRange", "range", "=", "mapper", ".", "getSourceRange", "(", "classFile", ".", "getType", "(", ")", ")", ";", "if", "(", "range", "==", "SourceMapper", ".", "UNKNOWN_RANGE", ")", "continue", ";", "int", "newStart", "=", "range", ".", "getOffset", "(", ")", ";", "int", "newEnd", "=", "newStart", "+", "range", ".", "getLength", "(", ")", "-", "1", ";", "if", "(", "newStart", ">", "start", "&&", "newEnd", "<", "end", "&&", "newStart", "<=", "position", "&&", "newEnd", ">=", "position", ")", "{", "type", "=", "classFile", ".", "getType", "(", ")", ";", "start", "=", "newStart", ";", "end", "=", "newEnd", ";", "}", "}", "}", "if", "(", "type", "!=", "null", ")", "{", "return", "findElement", "(", "type", ",", "position", ",", "mapper", ")", ";", "}", "return", "null", ";", "}", "}", "public", "String", "getElementName", "(", ")", "{", "return", "this", ".", "name", "+", "SuffixConstants", ".", "SUFFIX_STRING_class", ";", "}", "public", "int", "getElementType", "(", ")", "{", "return", "CLASS_FILE", ";", "}", "public", "IJavaElement", "getHandleFromMemento", "(", "String", "token", ",", "MementoTokenizer", "memento", ",", "WorkingCopyOwner", "owner", ")", "{", "switch", "(", "token", ".", "charAt", "(", "0", ")", ")", "{", "case", "JEM_TYPE", ":", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "String", "typeName", "=", "memento", ".", "nextToken", "(", ")", ";", "JavaElement", "type", "=", "new", "BinaryType", "(", "this", ",", "typeName", ")", ";", "return", "type", ".", "getHandleFromMemento", "(", "memento", ",", "owner", ")", ";", "}", "return", "null", ";", "}", "protected", "char", "getHandleMementoDelimiter", "(", ")", "{", "return", "JavaElement", ".", "JEM_CLASSFILE", ";", "}", "public", "IPath", "getPath", "(", ")", "{", "PackageFragmentRoot", "root", "=", "getPackageFragmentRoot", "(", ")", ";", "if", "(", "root", ".", "isArchive", "(", ")", ")", "{", "return", "root", ".", "getPath", "(", ")", ";", "}", "else", "{", "return", "getParent", "(", ")", ".", "getPath", "(", ")", ".", "append", "(", "getElementName", "(", ")", ")", ";", "}", "}", "public", "IResource", "resource", "(", "PackageFragmentRoot", "root", ")", "{", "return", "(", "(", "IContainer", ")", "(", "(", "Openable", ")", "this", ".", "parent", ")", ".", "resource", "(", "root", ")", ")", ".", "getFile", "(", "new", "Path", "(", "getElementName", "(", ")", ")", ")", ";", "}", "public", "String", "getSource", "(", ")", "throws", "JavaModelException", "{", "IBuffer", "buffer", "=", "getBuffer", "(", ")", ";", "if", "(", "buffer", "==", "null", ")", "{", "return", "null", ";", "}", "return", "buffer", ".", "getContents", "(", ")", ";", "}", "public", "ISourceRange", "getSourceRange", "(", ")", "throws", "JavaModelException", "{", "IBuffer", "buffer", "=", "getBuffer", "(", ")", ";", "if", "(", "buffer", "!=", "null", ")", "{", "String", "contents", "=", "buffer", ".", "getContents", "(", ")", ";", "if", "(", "contents", "==", "null", ")", "return", "null", ";", "return", "new", "SourceRange", "(", "0", ",", "contents", ".", "length", "(", ")", ")", ";", "}", "else", "{", "return", "null", ";", "}", "}", "public", "String", "getTopLevelTypeName", "(", ")", "{", "String", "topLevelTypeName", "=", "getElementName", "(", ")", ";", "int", "firstDollar", "=", "topLevelTypeName", ".", "indexOf", "(", "'$'", ")", ";", "if", "(", "firstDollar", "!=", "-", "1", ")", "{", "topLevelTypeName", "=", "topLevelTypeName", ".", "substring", "(", "0", ",", "firstDollar", ")", ";", "}", "else", "{", "topLevelTypeName", "=", "topLevelTypeName", ".", "substring", "(", "0", ",", "topLevelTypeName", ".", "length", "(", ")", "-", "SUFFIX_CLASS", ".", "length", ")", ";", "}", "return", "topLevelTypeName", ";", "}", "public", "IType", "getType", "(", ")", "{", "if", "(", "this", ".", "binaryType", "==", "null", ")", "{", "this", ".", "binaryType", "=", "new", "BinaryType", "(", "this", ",", "getTypeName", "(", ")", ")", ";", "}", "return", "this", ".", "binaryType", ";", "}", "public", "String", "getTypeName", "(", ")", "{", "int", "lastDollar", "=", "this", ".", "name", ".", "lastIndexOf", "(", "'$'", ")", ";", "return", "lastDollar", ">", "-", "1", "?", "Util", ".", "localTypeName", "(", "this", ".", "name", ",", "lastDollar", ",", "this", ".", "name", ".", "length", "(", ")", ")", ":", "this", ".", "name", ";", "}", "public", "ICompilationUnit", "getWorkingCopy", "(", "WorkingCopyOwner", "owner", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "CompilationUnit", "workingCopy", "=", "new", "ClassFileWorkingCopy", "(", "this", ",", "owner", "==", "null", "?", "DefaultWorkingCopyOwner", ".", "PRIMARY", ":", "owner", ")", ";", "JavaModelManager", "manager", "=", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ";", "JavaModelManager", ".", "PerWorkingCopyInfo", "perWorkingCopyInfo", "=", "manager", ".", "getPerWorkingCopyInfo", "(", "workingCopy", ",", "false", ",", "true", ",", "null", ")", ";", "if", "(", "perWorkingCopyInfo", "!=", "null", ")", "{", "return", "perWorkingCopyInfo", ".", "getWorkingCopy", "(", ")", ";", "}", "BecomeWorkingCopyOperation", "op", "=", "new", "BecomeWorkingCopyOperation", "(", "workingCopy", ",", "null", ")", ";", "op", ".", "runOperation", "(", "monitor", ")", ";", "return", "workingCopy", ";", "}", "public", "IJavaElement", "getWorkingCopy", "(", "IProgressMonitor", "monitor", ",", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IBufferFactory", "factory", ")", "throws", "JavaModelException", "{", "return", "getWorkingCopy", "(", "BufferFactoryWrapper", ".", "create", "(", "factory", ")", ",", "monitor", ")", ";", "}", "protected", "boolean", "hasBuffer", "(", ")", "{", "return", "true", ";", "}", "public", "int", "hashCode", "(", ")", "{", "return", "Util", ".", "combineHashCodes", "(", "this", ".", "name", ".", "hashCode", "(", ")", ",", "this", ".", "parent", ".", "hashCode", "(", ")", ")", ";", "}", "public", "boolean", "isClass", "(", ")", "throws", "JavaModelException", "{", "return", "getType", "(", ")", ".", "isClass", "(", ")", ";", "}", "public", "boolean", "isInterface", "(", ")", "throws", "JavaModelException", "{", "return", "getType", "(", ")", ".", "isInterface", "(", ")", ";", "}", "public", "boolean", "isReadOnly", "(", ")", "{", "return", "true", ";", "}", "private", "IStatus", "validateClassFile", "(", ")", "{", "IPackageFragmentRoot", "root", "=", "getPackageFragmentRoot", "(", ")", ";", "try", "{", "if", "(", "root", ".", "getKind", "(", ")", "!=", "IPackageFragmentRoot", ".", "K_BINARY", ")", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_ELEMENT_TYPES", ",", "root", ")", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "return", "e", ".", "getJavaModelStatus", "(", ")", ";", "}", "IJavaProject", "project", "=", "getJavaProject", "(", ")", ";", "return", "JavaConventions", ".", "validateClassFileName", "(", "getElementName", "(", ")", ",", "project", ".", "getOption", "(", "JavaCore", ".", "COMPILER_SOURCE", ",", "true", ")", ",", "project", ".", "getOption", "(", "JavaCore", ".", "COMPILER_COMPLIANCE", ",", "true", ")", ")", ";", "}", "protected", "IBuffer", "openBuffer", "(", "IProgressMonitor", "pm", ",", "Object", "info", ")", "throws", "JavaModelException", "{", "IType", "outerMostEnclosingType", "=", "getOuterMostEnclosingType", "(", ")", ";", "IBuffer", "buffer", "=", "getBufferManager", "(", ")", ".", "getBuffer", "(", "outerMostEnclosingType", ".", "getClassFile", "(", ")", ")", ";", "if", "(", "buffer", "==", "null", ")", "{", "SourceMapper", "mapper", "=", "getSourceMapper", "(", ")", ";", "IBinaryType", "typeInfo", "=", "info", "instanceof", "IBinaryType", "?", "(", "IBinaryType", ")", "info", ":", "null", ";", "if", "(", "mapper", "!=", "null", ")", "{", "buffer", "=", "mapSource", "(", "mapper", ",", "typeInfo", ",", "outerMostEnclosingType", ".", "getClassFile", "(", ")", ")", ";", "}", "}", "return", "buffer", ";", "}", "private", "IBuffer", "mapSource", "(", "SourceMapper", "mapper", ",", "IBinaryType", "info", ",", "IClassFile", "bufferOwner", ")", "{", "char", "[", "]", "contents", "=", "mapper", ".", "findSource", "(", "getType", "(", ")", ",", "info", ")", ";", "if", "(", "contents", "!=", "null", ")", "{", "IBuffer", "buffer", "=", "BufferManager", ".", "createBuffer", "(", "bufferOwner", ")", ";", "if", "(", "buffer", "==", "null", ")", "return", "null", ";", "BufferManager", "bufManager", "=", "getBufferManager", "(", ")", ";", "bufManager", ".", "addBuffer", "(", "buffer", ")", ";", "if", "(", "buffer", ".", "getCharacters", "(", ")", "==", "null", ")", "{", "buffer", ".", "setContents", "(", "contents", ")", ";", "}", "buffer", ".", "addBufferChangedListener", "(", "this", ")", ";", "mapper", ".", "mapSource", "(", "getOuterMostEnclosingType", "(", ")", ",", "contents", ",", "info", ")", ";", "return", "buffer", ";", "}", "else", "{", "IBuffer", "buffer", "=", "BufferManager", ".", "createNullBuffer", "(", "bufferOwner", ")", ";", "if", "(", "buffer", "==", "null", ")", "return", "null", ";", "BufferManager", "bufManager", "=", "getBufferManager", "(", ")", ";", "bufManager", ".", "addBuffer", "(", "buffer", ")", ";", "buffer", ".", "addBufferChangedListener", "(", "this", ")", ";", "return", "buffer", ";", "}", "}", "static", "String", "simpleName", "(", "char", "[", "]", "className", ")", "{", "if", "(", "className", "==", "null", ")", "return", "null", ";", "String", "simpleName", "=", "new", "String", "(", "unqualifiedName", "(", "className", ")", ")", ";", "int", "lastDollar", "=", "simpleName", ".", "lastIndexOf", "(", "'$'", ")", ";", "if", "(", "lastDollar", "!=", "-", "1", ")", "return", "Util", ".", "localTypeName", "(", "simpleName", ",", "lastDollar", ",", "simpleName", ".", "length", "(", ")", ")", ";", "else", "return", "simpleName", ";", "}", "private", "IType", "getOuterMostEnclosingType", "(", ")", "{", "IType", "type", "=", "getType", "(", ")", ";", "IType", "enclosingType", "=", "type", ".", "getDeclaringType", "(", ")", ";", "while", "(", "enclosingType", "!=", "null", ")", "{", "type", "=", "enclosingType", ";", "enclosingType", "=", "type", ".", "getDeclaringType", "(", ")", ";", "}", "return", "type", ";", "}", "public", "static", "char", "[", "]", "translatedName", "(", "char", "[", "]", "name", ")", "{", "if", "(", "name", "==", "null", ")", "return", "null", ";", "int", "nameLength", "=", "name", ".", "length", ";", "char", "[", "]", "newName", "=", "new", "char", "[", "nameLength", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "nameLength", ";", "i", "++", ")", "{", "if", "(", "name", "[", "i", "]", "==", "'/'", ")", "{", "newName", "[", "i", "]", "=", "'.'", ";", "}", "else", "{", "newName", "[", "i", "]", "=", "name", "[", "i", "]", ";", "}", "}", "return", "newName", ";", "}", "static", "char", "[", "]", "[", "]", "translatedNames", "(", "char", "[", "]", "[", "]", "names", ")", "{", "if", "(", "names", "==", "null", ")", "return", "null", ";", "int", "length", "=", "names", ".", "length", ";", "char", "[", "]", "[", "]", "newNames", "=", "new", "char", "[", "length", "]", "[", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "newNames", "[", "i", "]", "=", "translatedName", "(", "names", "[", "i", "]", ")", ";", "}", "return", "newNames", ";", "}", "static", "char", "[", "]", "unqualifiedName", "(", "char", "[", "]", "className", ")", "{", "if", "(", "className", "==", "null", ")", "return", "null", ";", "int", "count", "=", "0", ";", "for", "(", "int", "i", "=", "className", ".", "length", "-", "1", ";", "i", ">", "-", "1", ";", "i", "--", ")", "{", "if", "(", "className", "[", "i", "]", "==", "'/'", ")", "{", "char", "[", "]", "name", "=", "new", "char", "[", "count", "]", ";", "System", ".", "arraycopy", "(", "className", ",", "i", "+", "1", ",", "name", ",", "0", ",", "count", ")", ";", "return", "name", ";", "}", "count", "++", ";", "}", "return", "className", ";", "}", "public", "void", "codeComplete", "(", "int", "offset", ",", "final", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ICodeCompletionRequestor", "requestor", ")", "throws", "JavaModelException", "{", "if", "(", "requestor", "==", "null", ")", "{", "codeComplete", "(", "offset", ",", "(", "ICompletionRequestor", ")", "null", ")", ";", "return", ";", "}", "codeComplete", "(", "offset", ",", "new", "ICompletionRequestor", "(", ")", "{", "public", "void", "acceptAnonymousType", "(", "char", "[", "]", "superTypePackageName", ",", "char", "[", "]", "superTypeName", ",", "char", "[", "]", "[", "]", "parameterPackageNames", ",", "char", "[", "]", "[", "]", "parameterTypeNames", ",", "char", "[", "]", "[", "]", "parameterNames", ",", "char", "[", "]", "completionName", ",", "int", "modifiers", ",", "int", "completionStart", ",", "int", "completionEnd", ",", "int", "relevance", ")", "{", "}", "public", "void", "acceptClass", "(", "char", "[", "]", "packageName", ",", "char", "[", "]", "className", ",", "char", "[", "]", "completionName", ",", "int", "modifiers", ",", "int", "completionStart", ",", "int", "completionEnd", ",", "int", "relevance", ")", "{", "requestor", ".", "acceptClass", "(", "packageName", ",", "className", ",", "completionName", ",", "modifiers", ",", "completionStart", ",", "completionEnd", ")", ";", "}", "public", "void", "acceptError", "(", "IProblem", "error", ")", "{", "}", "public", "void", "acceptField", "(", "char", "[", "]", "declaringTypePackageName", ",", "char", "[", "]", "declaringTypeName", ",", "char", "[", "]", "fieldName", ",", "char", "[", "]", "typePackageName", ",", "char", "[", "]", "typeName", ",", "char", "[", "]", "completionName", ",", "int", "modifiers", ",", "int", "completionStart", ",", "int", "completionEnd", ",", "int", "relevance", ")", "{", "requestor", ".", "acceptField", "(", "declaringTypePackageName", ",", "declaringTypeName", ",", "fieldName", ",", "typePackageName", ",", "typeName", ",", "completionName", ",", "modifiers", ",", "completionStart", ",", "completionEnd", ")", ";", "}", "public", "void", "acceptInterface", "(", "char", "[", "]", "packageName", ",", "char", "[", "]", "interfaceName", ",", "char", "[", "]", "completionName", ",", "int", "modifiers", ",", "int", "completionStart", ",", "int", "completionEnd", ",", "int", "relevance", ")", "{", "requestor", ".", "acceptInterface", "(", "packageName", ",", "interfaceName", ",", "completionName", ",", "modifiers", ",", "completionStart", ",", "completionEnd", ")", ";", "}", "public", "void", "acceptKeyword", "(", "char", "[", "]", "keywordName", ",", "int", "completionStart", ",", "int", "completionEnd", ",", "int", "relevance", ")", "{", "requestor", ".", "acceptKeyword", "(", "keywordName", ",", "completionStart", ",", "completionEnd", ")", ";", "}", "public", "void", "acceptLabel", "(", "char", "[", "]", "labelName", ",", "int", "completionStart", ",", "int", "completionEnd", ",", "int", "relevance", ")", "{", "requestor", ".", "acceptLabel", "(", "labelName", ",", "completionStart", ",", "completionEnd", ")", ";", "}", "public", "void", "acceptLocalVariable", "(", "char", "[", "]", "localVarName", ",", "char", "[", "]", "typePackageName", ",", "char", "[", "]", "typeName", ",", "int", "modifiers", ",", "int", "completionStart", ",", "int", "completionEnd", ",", "int", "relevance", ")", "{", "}", "public", "void", "acceptMethod", "(", "char", "[", "]", "declaringTypePackageName", ",", "char", "[", "]", "declaringTypeName", ",", "char", "[", "]", "selector", ",", "char", "[", "]", "[", "]", "parameterPackageNames", ",", "char", "[", "]", "[", "]", "parameterTypeNames", ",", "char", "[", "]", "[", "]", "parameterNames", ",", "char", "[", "]", "returnTypePackageName", ",", "char", "[", "]", "returnTypeName", ",", "char", "[", "]", "completionName", ",", "int", "modifiers", ",", "int", "completionStart", ",", "int", "completionEnd", ",", "int", "relevance", ")", "{", "requestor", ".", "acceptMethod", "(", "declaringTypePackageName", ",", "declaringTypeName", ",", "selector", ",", "parameterPackageNames", ",", "parameterTypeNames", ",", "returnTypePackageName", ",", "returnTypeName", ",", "completionName", ",", "modifiers", ",", "completionStart", ",", "completionEnd", ")", ";", "}", "public", "void", "acceptMethodDeclaration", "(", "char", "[", "]", "declaringTypePackageName", ",", "char", "[", "]", "declaringTypeName", ",", "char", "[", "]", "selector", ",", "char", "[", "]", "[", "]", "parameterPackageNames", ",", "char", "[", "]", "[", "]", "parameterTypeNames", ",", "char", "[", "]", "[", "]", "parameterNames", ",", "char", "[", "]", "returnTypePackageName", ",", "char", "[", "]", "returnTypeName", ",", "char", "[", "]", "completionName", ",", "int", "modifiers", ",", "int", "completionStart", ",", "int", "completionEnd", ",", "int", "relevance", ")", "{", "}", "public", "void", "acceptModifier", "(", "char", "[", "]", "modifierName", ",", "int", "completionStart", ",", "int", "completionEnd", ",", "int", "relevance", ")", "{", "requestor", ".", "acceptModifier", "(", "modifierName", ",", "completionStart", ",", "completionEnd", ")", ";", "}", "public", "void", "acceptPackage", "(", "char", "[", "]", "packageName", ",", "char", "[", "]", "completionName", ",", "int", "completionStart", ",", "int", "completionEnd", ",", "int", "relevance", ")", "{", "requestor", ".", "acceptPackage", "(", "packageName", ",", "completionName", ",", "completionStart", ",", "completionEnd", ")", ";", "}", "public", "void", "acceptType", "(", "char", "[", "]", "packageName", ",", "char", "[", "]", "typeName", ",", "char", "[", "]", "completionName", ",", "int", "completionStart", ",", "int", "completionEnd", ",", "int", "relevance", ")", "{", "requestor", ".", "acceptType", "(", "packageName", ",", "typeName", ",", "completionName", ",", "completionStart", ",", "completionEnd", ")", ";", "}", "public", "void", "acceptVariableName", "(", "char", "[", "]", "typePackageName", ",", "char", "[", "]", "typeName", ",", "char", "[", "]", "varName", ",", "char", "[", "]", "completionName", ",", "int", "completionStart", ",", "int", "completionEnd", ",", "int", "relevance", ")", "{", "}", "}", ")", ";", "}", "protected", "IStatus", "validateExistence", "(", "IResource", "underlyingResource", ")", "{", "IStatus", "status", "=", "validateClassFile", "(", ")", ";", "if", "(", "!", "status", ".", "isOK", "(", ")", ")", "return", "status", ";", "if", "(", "underlyingResource", "!=", "null", ")", "{", "if", "(", "!", "underlyingResource", ".", "isAccessible", "(", ")", ")", "return", "newDoesNotExistStatus", "(", ")", ";", "PackageFragmentRoot", "root", ";", "if", "(", "(", "underlyingResource", "instanceof", "IFolder", ")", "&&", "(", "root", "=", "getPackageFragmentRoot", "(", ")", ")", ".", "isArchive", "(", ")", ")", "{", "return", "root", ".", "newDoesNotExistStatus", "(", ")", ";", "}", "}", "return", "JavaModelStatus", ".", "VERIFIED_OK", ";", "}", "}", "</s>" ]
5,517
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IProgressMonitor", ";", "public", "class", "BatchInitializationMonitor", "implements", "IProgressMonitor", "{", "public", "ThreadLocal", "initializeAfterLoadMonitor", "=", "new", "ThreadLocal", "(", ")", ";", "public", "String", "subTaskName", "=", "\"\"", ";", "public", "int", "worked", "=", "0", ";", "private", "IProgressMonitor", "getMonitor", "(", ")", "{", "return", "(", "IProgressMonitor", ")", "this", ".", "initializeAfterLoadMonitor", ".", "get", "(", ")", ";", "}", "public", "void", "beginTask", "(", "String", "name", ",", "int", "totalWork", ")", "{", "IProgressMonitor", "monitor", "=", "getMonitor", "(", ")", ";", "if", "(", "monitor", "!=", "null", ")", "monitor", ".", "beginTask", "(", "name", ",", "totalWork", ")", ";", "}", "public", "void", "done", "(", ")", "{", "IProgressMonitor", "monitor", "=", "getMonitor", "(", ")", ";", "if", "(", "monitor", "!=", "null", ")", "monitor", ".", "done", "(", ")", ";", "this", ".", "worked", "=", "0", ";", "this", ".", "subTaskName", "=", "\"\"", ";", "}", "public", "void", "internalWorked", "(", "double", "work", ")", "{", "IProgressMonitor", "monitor", "=", "getMonitor", "(", ")", ";", "if", "(", "monitor", "!=", "null", ")", "monitor", ".", "internalWorked", "(", "work", ")", ";", "}", "public", "boolean", "isCanceled", "(", ")", "{", "IProgressMonitor", "monitor", "=", "getMonitor", "(", ")", ";", "if", "(", "monitor", "!=", "null", ")", "return", "monitor", ".", "isCanceled", "(", ")", ";", "return", "false", ";", "}", "public", "void", "setCanceled", "(", "boolean", "value", ")", "{", "IProgressMonitor", "monitor", "=", "getMonitor", "(", ")", ";", "if", "(", "monitor", "!=", "null", ")", "monitor", ".", "setCanceled", "(", "value", ")", ";", "}", "public", "void", "setTaskName", "(", "String", "name", ")", "{", "IProgressMonitor", "monitor", "=", "getMonitor", "(", ")", ";", "if", "(", "monitor", "!=", "null", ")", "monitor", ".", "setTaskName", "(", "name", ")", ";", "}", "public", "void", "subTask", "(", "String", "name", ")", "{", "IProgressMonitor", "monitor", "=", "getMonitor", "(", ")", ";", "if", "(", "monitor", "!=", "null", ")", "monitor", ".", "subTask", "(", "name", ")", ";", "this", ".", "subTaskName", "=", "name", ";", "}", "public", "void", "worked", "(", "int", "work", ")", "{", "IProgressMonitor", "monitor", "=", "getMonitor", "(", ")", ";", "if", "(", "monitor", "!=", "null", ")", "monitor", ".", "worked", "(", "work", ")", ";", "synchronized", "(", "this", ")", "{", "this", ".", "worked", "+=", "work", ";", "}", "}", "public", "synchronized", "int", "getWorked", "(", ")", "{", "int", "result", "=", "this", ".", "worked", ";", "this", ".", "worked", "=", "0", ";", "return", "result", ";", "}", "}", "</s>" ]
5,518
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "IScanner", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "ITerminalSymbols", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "InvalidInputException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "Constant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeIds", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "MementoTokenizer", ";", "public", "abstract", "class", "Member", "extends", "SourceRefElement", "implements", "IMember", "{", "protected", "Member", "(", "JavaElement", "parent", ")", "{", "super", "(", "parent", ")", ";", "}", "protected", "static", "boolean", "areSimilarMethods", "(", "String", "name1", ",", "String", "[", "]", "params1", ",", "String", "name2", ",", "String", "[", "]", "params2", ",", "String", "[", "]", "simpleNames1", ")", "{", "if", "(", "name1", ".", "equals", "(", "name2", ")", ")", "{", "int", "params1Length", "=", "params1", ".", "length", ";", "if", "(", "params1Length", "==", "params2", ".", "length", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "params1Length", ";", "i", "++", ")", "{", "String", "simpleName1", "=", "simpleNames1", "==", "null", "?", "Signature", ".", "getSimpleName", "(", "Signature", ".", "toString", "(", "Signature", ".", "getTypeErasure", "(", "params1", "[", "i", "]", ")", ")", ")", ":", "simpleNames1", "[", "i", "]", ";", "String", "simpleName2", "=", "Signature", ".", "getSimpleName", "(", "Signature", ".", "toString", "(", "Signature", ".", "getTypeErasure", "(", "params2", "[", "i", "]", ")", ")", ")", ";", "if", "(", "!", "simpleName1", ".", "equals", "(", "simpleName2", ")", ")", "{", "return", "false", ";", "}", "}", "return", "true", ";", "}", "}", "return", "false", ";", "}", "protected", "static", "Object", "convertConstant", "(", "Constant", "constant", ")", "{", "if", "(", "constant", "==", "null", ")", "return", "null", ";", "if", "(", "constant", "==", "Constant", ".", "NotAConstant", ")", "{", "return", "null", ";", "}", "switch", "(", "constant", ".", "typeID", "(", ")", ")", "{", "case", "TypeIds", ".", "T_boolean", ":", "return", "constant", ".", "booleanValue", "(", ")", "?", "Boolean", ".", "TRUE", ":", "Boolean", ".", "FALSE", ";", "case", "TypeIds", ".", "T_byte", ":", "return", "new", "Byte", "(", "constant", ".", "byteValue", "(", ")", ")", ";", "case", "TypeIds", ".", "T_char", ":", "return", "new", "Character", "(", "constant", ".", "charValue", "(", ")", ")", ";", "case", "TypeIds", ".", "T_double", ":", "return", "new", "Double", "(", "constant", ".", "doubleValue", "(", ")", ")", ";", "case", "TypeIds", ".", "T_float", ":", "return", "new", "Float", "(", "constant", ".", "floatValue", "(", ")", ")", ";", "case", "TypeIds", ".", "T_int", ":", "return", "new", "Integer", "(", "constant", ".", "intValue", "(", ")", ")", ";", "case", "TypeIds", ".", "T_long", ":", "return", "new", "Long", "(", "constant", ".", "longValue", "(", ")", ")", ";", "case", "TypeIds", ".", "T_short", ":", "return", "new", "Short", "(", "constant", ".", "shortValue", "(", ")", ")", ";", "case", "TypeIds", ".", "T_JavaLangString", ":", "return", "constant", ".", "stringValue", "(", ")", ";", "default", ":", "return", "null", ";", "}", "}", "public", "static", "IMethod", "[", "]", "findMethods", "(", "IMethod", "method", ",", "IMethod", "[", "]", "methods", ")", "{", "String", "elementName", "=", "method", ".", "getElementName", "(", ")", ";", "String", "[", "]", "parameters", "=", "method", ".", "getParameterTypes", "(", ")", ";", "int", "paramLength", "=", "parameters", ".", "length", ";", "String", "[", "]", "simpleNames", "=", "new", "String", "[", "paramLength", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "paramLength", ";", "i", "++", ")", "{", "String", "erasure", "=", "Signature", ".", "getTypeErasure", "(", "parameters", "[", "i", "]", ")", ";", "simpleNames", "[", "i", "]", "=", "Signature", ".", "getSimpleName", "(", "Signature", ".", "toString", "(", "erasure", ")", ")", ";", "}", "ArrayList", "list", "=", "new", "ArrayList", "(", ")", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "methods", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "IMethod", "existingMethod", "=", "methods", "[", "i", "]", ";", "if", "(", "areSimilarMethods", "(", "elementName", ",", "parameters", ",", "existingMethod", ".", "getElementName", "(", ")", ",", "existingMethod", ".", "getParameterTypes", "(", ")", ",", "simpleNames", ")", ")", "{", "list", ".", "add", "(", "existingMethod", ")", ";", "}", "}", "int", "size", "=", "list", ".", "size", "(", ")", ";", "if", "(", "size", "==", "0", ")", "{", "return", "null", ";", "}", "else", "{", "IMethod", "[", "]", "result", "=", "new", "IMethod", "[", "size", "]", ";", "list", ".", "toArray", "(", "result", ")", ";", "return", "result", ";", "}", "}", "public", "String", "[", "]", "getCategories", "(", ")", "throws", "JavaModelException", "{", "IType", "type", "=", "(", "IType", ")", "getAncestor", "(", "IJavaElement", ".", "TYPE", ")", ";", "if", "(", "type", "==", "null", ")", "return", "CharOperation", ".", "NO_STRINGS", ";", "if", "(", "type", ".", "isBinary", "(", ")", ")", "{", "return", "CharOperation", ".", "NO_STRINGS", ";", "}", "else", "{", "SourceTypeElementInfo", "info", "=", "(", "SourceTypeElementInfo", ")", "(", "(", "SourceType", ")", "type", ")", ".", "getElementInfo", "(", ")", ";", "HashMap", "map", "=", "info", ".", "getCategories", "(", ")", ";", "if", "(", "map", "==", "null", ")", "return", "CharOperation", ".", "NO_STRINGS", ";", "String", "[", "]", "categories", "=", "(", "String", "[", "]", ")", "map", ".", "get", "(", "this", ")", ";", "if", "(", "categories", "==", "null", ")", "return", "CharOperation", ".", "NO_STRINGS", ";", "return", "categories", ";", "}", "}", "public", "IClassFile", "getClassFile", "(", ")", "{", "IJavaElement", "element", "=", "getParent", "(", ")", ";", "while", "(", "element", "instanceof", "IMember", ")", "{", "element", "=", "element", ".", "getParent", "(", ")", ";", "}", "if", "(", "element", "instanceof", "IClassFile", ")", "{", "return", "(", "IClassFile", ")", "element", ";", "}", "return", "null", ";", "}", "public", "IType", "getDeclaringType", "(", ")", "{", "JavaElement", "parentElement", "=", "(", "JavaElement", ")", "getParent", "(", ")", ";", "if", "(", "parentElement", ".", "getElementType", "(", ")", "==", "TYPE", ")", "{", "return", "(", "IType", ")", "parentElement", ";", "}", "return", "null", ";", "}", "public", "int", "getFlags", "(", ")", "throws", "JavaModelException", "{", "MemberElementInfo", "info", "=", "(", "MemberElementInfo", ")", "getElementInfo", "(", ")", ";", "return", "info", ".", "getModifiers", "(", ")", ";", "}", "public", "IJavaElement", "getHandleFromMemento", "(", "String", "token", ",", "MementoTokenizer", "memento", ",", "WorkingCopyOwner", "workingCopyOwner", ")", "{", "switch", "(", "token", ".", "charAt", "(", "0", ")", ")", "{", "case", "JEM_COUNT", ":", "return", "getHandleUpdatingCountFromMemento", "(", "memento", ",", "workingCopyOwner", ")", ";", "case", "JEM_TYPE", ":", "String", "typeName", ";", "if", "(", "memento", ".", "hasMoreTokens", "(", ")", ")", "{", "typeName", "=", "memento", ".", "nextToken", "(", ")", ";", "char", "firstChar", "=", "typeName", ".", "charAt", "(", "0", ")", ";", "if", "(", "firstChar", "==", "JEM_FIELD", "||", "firstChar", "==", "JEM_INITIALIZER", "||", "firstChar", "==", "JEM_METHOD", "||", "firstChar", "==", "JEM_TYPE", "||", "firstChar", "==", "JEM_COUNT", ")", "{", "token", "=", "typeName", ";", "typeName", "=", "\"\"", ";", "}", "else", "{", "token", "=", "null", ";", "}", "}", "else", "{", "typeName", "=", "\"\"", ";", "token", "=", "null", ";", "}", "JavaElement", "type", "=", "(", "JavaElement", ")", "getType", "(", "typeName", ",", "1", ")", ";", "if", "(", "token", "==", "null", ")", "{", "return", "type", ".", "getHandleFromMemento", "(", "memento", ",", "workingCopyOwner", ")", ";", "}", "else", "{", "return", "type", ".", "getHandleFromMemento", "(", "token", ",", "memento", ",", "workingCopyOwner", ")", ";", "}", "case", "JEM_LOCALVARIABLE", ":", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "String", "varName", "=", "memento", ".", "nextToken", "(", ")", ";", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "memento", ".", "nextToken", "(", ")", ";", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "int", "declarationStart", "=", "Integer", ".", "parseInt", "(", "memento", ".", "nextToken", "(", ")", ")", ";", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "memento", ".", "nextToken", "(", ")", ";", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "int", "declarationEnd", "=", "Integer", ".", "parseInt", "(", "memento", ".", "nextToken", "(", ")", ")", ";", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "memento", ".", "nextToken", "(", ")", ";", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "int", "nameStart", "=", "Integer", ".", "parseInt", "(", "memento", ".", "nextToken", "(", ")", ")", ";", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "memento", ".", "nextToken", "(", ")", ";", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "int", "nameEnd", "=", "Integer", ".", "parseInt", "(", "memento", ".", "nextToken", "(", ")", ")", ";", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "memento", ".", "nextToken", "(", ")", ";", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "String", "typeSignature", "=", "memento", ".", "nextToken", "(", ")", ";", "return", "new", "LocalVariable", "(", "this", ",", "varName", ",", "declarationStart", ",", "declarationEnd", ",", "nameStart", ",", "nameEnd", ",", "typeSignature", ",", "null", ")", ";", "case", "JEM_TYPE_PARAMETER", ":", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "String", "typeParameterName", "=", "memento", ".", "nextToken", "(", ")", ";", "JavaElement", "typeParameter", "=", "new", "TypeParameter", "(", "this", ",", "typeParameterName", ")", ";", "return", "typeParameter", ".", "getHandleFromMemento", "(", "memento", ",", "workingCopyOwner", ")", ";", "case", "JEM_ANNOTATION", ":", "if", "(", "!", "memento", ".", "hasMoreTokens", "(", ")", ")", "return", "this", ";", "String", "annotationName", "=", "memento", ".", "nextToken", "(", ")", ";", "JavaElement", "annotation", "=", "new", "Annotation", "(", "this", ",", "annotationName", ")", ";", "return", "annotation", ".", "getHandleFromMemento", "(", "memento", ",", "workingCopyOwner", ")", ";", "}", "return", "null", ";", "}", "protected", "char", "getHandleMementoDelimiter", "(", ")", "{", "return", "JavaElement", ".", "JEM_TYPE", ";", "}", "public", "Member", "getOuterMostLocalContext", "(", ")", "{", "IJavaElement", "current", "=", "this", ";", "Member", "lastLocalContext", "=", "null", ";", "parentLoop", ":", "while", "(", "true", ")", "{", "switch", "(", "current", ".", "getElementType", "(", ")", ")", "{", "case", "CLASS_FILE", ":", "case", "COMPILATION_UNIT", ":", "break", "parentLoop", ";", "case", "TYPE", ":", "break", ";", "case", "INITIALIZER", ":", "case", "FIELD", ":", "case", "METHOD", ":", "lastLocalContext", "=", "(", "Member", ")", "current", ";", "break", ";", "}", "current", "=", "current", ".", "getParent", "(", ")", ";", "}", "return", "lastLocalContext", ";", "}", "public", "ISourceRange", "getJavadocRange", "(", ")", "throws", "JavaModelException", "{", "ISourceRange", "range", "=", "getSourceRange", "(", ")", ";", "if", "(", "range", "==", "null", ")", "return", "null", ";", "IBuffer", "buf", "=", "null", ";", "if", "(", "isBinary", "(", ")", ")", "{", "buf", "=", "getClassFile", "(", ")", ".", "getBuffer", "(", ")", ";", "}", "else", "{", "ICompilationUnit", "compilationUnit", "=", "getCompilationUnit", "(", ")", ";", "if", "(", "!", "compilationUnit", ".", "isConsistent", "(", ")", ")", "{", "return", "null", ";", "}", "buf", "=", "compilationUnit", ".", "getBuffer", "(", ")", ";", "}", "final", "int", "start", "=", "range", ".", "getOffset", "(", ")", ";", "final", "int", "length", "=", "range", ".", "getLength", "(", ")", ";", "if", "(", "length", ">", "0", "&&", "buf", ".", "getChar", "(", "start", ")", "==", "'/'", ")", "{", "IScanner", "scanner", "=", "ToolFactory", ".", "createScanner", "(", "true", ",", "false", ",", "false", ",", "false", ")", ";", "try", "{", "scanner", ".", "setSource", "(", "buf", ".", "getText", "(", "start", ",", "length", ")", ".", "toCharArray", "(", ")", ")", ";", "int", "docOffset", "=", "-", "1", ";", "int", "docEnd", "=", "-", "1", ";", "int", "terminal", "=", "scanner", ".", "getNextToken", "(", ")", ";", "loop", ":", "while", "(", "true", ")", "{", "switch", "(", "terminal", ")", "{", "case", "ITerminalSymbols", ".", "TokenNameCOMMENT_JAVADOC", ":", "docOffset", "=", "scanner", ".", "getCurrentTokenStartPosition", "(", ")", ";", "docEnd", "=", "scanner", ".", "getCurrentTokenEndPosition", "(", ")", "+", "1", ";", "terminal", "=", "scanner", ".", "getNextToken", "(", ")", ";", "break", ";", "case", "ITerminalSymbols", ".", "TokenNameCOMMENT_LINE", ":", "case", "ITerminalSymbols", ".", "TokenNameCOMMENT_BLOCK", ":", "terminal", "=", "scanner", ".", "getNextToken", "(", ")", ";", "continue", "loop", ";", "default", ":", "break", "loop", ";", "}", "}", "if", "(", "docOffset", "!=", "-", "1", ")", "{", "return", "new", "SourceRange", "(", "docOffset", "+", "start", ",", "docEnd", "-", "docOffset", ")", ";", "}", "}", "catch", "(", "InvalidInputException", "ex", ")", "{", "}", "catch", "(", "IndexOutOfBoundsException", "e", ")", "{", "}", "}", "return", "null", ";", "}", "public", "ISourceRange", "getNameRange", "(", ")", "throws", "JavaModelException", "{", "MemberElementInfo", "info", "=", "(", "MemberElementInfo", ")", "getElementInfo", "(", ")", ";", "return", "new", "SourceRange", "(", "info", ".", "getNameSourceStart", "(", ")", ",", "info", ".", "getNameSourceEnd", "(", ")", "-", "info", ".", "getNameSourceStart", "(", ")", "+", "1", ")", ";", "}", "public", "IType", "getType", "(", "String", "typeName", ",", "int", "count", ")", "{", "if", "(", "isBinary", "(", ")", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"\"", "+", "toStringWithAncestors", "(", ")", ")", ";", "}", "else", "{", "SourceType", "type", "=", "new", "SourceType", "(", "this", ",", "typeName", ")", ";", "type", ".", "occurrenceCount", "=", "count", ";", "return", "type", ";", "}", "}", "public", "ITypeRoot", "getTypeRoot", "(", ")", "{", "IJavaElement", "element", "=", "getParent", "(", ")", ";", "while", "(", "element", "instanceof", "IMember", ")", "{", "element", "=", "element", ".", "getParent", "(", ")", ";", "}", "return", "(", "ITypeRoot", ")", "element", ";", "}", "public", "boolean", "isBinary", "(", ")", "{", "return", "false", ";", "}", "protected", "boolean", "isMainMethod", "(", "IMethod", "method", ")", "throws", "JavaModelException", "{", "if", "(", "\"main\"", ".", "equals", "(", "method", ".", "getElementName", "(", ")", ")", "&&", "Signature", ".", "SIG_VOID", ".", "equals", "(", "method", ".", "getReturnType", "(", ")", ")", ")", "{", "int", "flags", "=", "method", ".", "getFlags", "(", ")", ";", "if", "(", "Flags", ".", "isStatic", "(", "flags", ")", "&&", "Flags", ".", "isPublic", "(", "flags", ")", ")", "{", "String", "[", "]", "paramTypes", "=", "method", ".", "getParameterTypes", "(", ")", ";", "if", "(", "paramTypes", ".", "length", "==", "1", ")", "{", "String", "typeSignature", "=", "Signature", ".", "toString", "(", "paramTypes", "[", "0", "]", ")", ";", "return", "\"String[]\"", ".", "equals", "(", "Signature", ".", "getSimpleName", "(", "typeSignature", ")", ")", ";", "}", "}", "}", "return", "false", ";", "}", "public", "boolean", "isReadOnly", "(", ")", "{", "return", "getClassFile", "(", ")", "!=", "null", ";", "}", "public", "String", "readableName", "(", ")", "{", "IJavaElement", "declaringType", "=", "getDeclaringType", "(", ")", ";", "if", "(", "declaringType", "!=", "null", ")", "{", "String", "declaringName", "=", "(", "(", "JavaElement", ")", "getDeclaringType", "(", ")", ")", ".", "readableName", "(", ")", ";", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", "declaringName", ")", ";", "buffer", ".", "append", "(", "'.'", ")", ";", "buffer", ".", "append", "(", "getElementName", "(", ")", ")", ";", "return", "buffer", ".", "toString", "(", ")", ";", "}", "else", "{", "return", "super", ".", "readableName", "(", ")", ";", "}", "}", "}", "</s>" ]
5,519
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IParent", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IRegion", ";", "public", "class", "Region", "implements", "IRegion", "{", "protected", "ArrayList", "rootElements", ";", "public", "Region", "(", ")", "{", "this", ".", "rootElements", "=", "new", "ArrayList", "(", "1", ")", ";", "}", "public", "void", "add", "(", "IJavaElement", "element", ")", "{", "if", "(", "!", "contains", "(", "element", ")", ")", "{", "removeAllChildren", "(", "element", ")", ";", "this", ".", "rootElements", ".", "add", "(", "element", ")", ";", "this", ".", "rootElements", ".", "trimToSize", "(", ")", ";", "}", "}", "public", "boolean", "contains", "(", "IJavaElement", "element", ")", "{", "int", "size", "=", "this", ".", "rootElements", ".", "size", "(", ")", ";", "ArrayList", "parents", "=", "getAncestors", "(", "element", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "size", ";", "i", "++", ")", "{", "IJavaElement", "aTop", "=", "(", "IJavaElement", ")", "this", ".", "rootElements", ".", "get", "(", "i", ")", ";", "if", "(", "aTop", ".", "equals", "(", "element", ")", ")", "{", "return", "true", ";", "}", "for", "(", "int", "j", "=", "0", ",", "pSize", "=", "parents", ".", "size", "(", ")", ";", "j", "<", "pSize", ";", "j", "++", ")", "{", "if", "(", "aTop", ".", "equals", "(", "parents", ".", "get", "(", "j", ")", ")", ")", "{", "return", "true", ";", "}", "}", "}", "return", "false", ";", "}", "private", "ArrayList", "getAncestors", "(", "IJavaElement", "element", ")", "{", "ArrayList", "parents", "=", "new", "ArrayList", "(", ")", ";", "IJavaElement", "parent", "=", "element", ".", "getParent", "(", ")", ";", "while", "(", "parent", "!=", "null", ")", "{", "parents", ".", "add", "(", "parent", ")", ";", "parent", "=", "parent", ".", "getParent", "(", ")", ";", "}", "parents", ".", "trimToSize", "(", ")", ";", "return", "parents", ";", "}", "public", "IJavaElement", "[", "]", "getElements", "(", ")", "{", "int", "size", "=", "this", ".", "rootElements", ".", "size", "(", ")", ";", "IJavaElement", "[", "]", "roots", "=", "new", "IJavaElement", "[", "size", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "size", ";", "i", "++", ")", "{", "roots", "[", "i", "]", "=", "(", "IJavaElement", ")", "this", ".", "rootElements", ".", "get", "(", "i", ")", ";", "}", "return", "roots", ";", "}", "public", "boolean", "remove", "(", "IJavaElement", "element", ")", "{", "removeAllChildren", "(", "element", ")", ";", "return", "this", ".", "rootElements", ".", "remove", "(", "element", ")", ";", "}", "protected", "void", "removeAllChildren", "(", "IJavaElement", "element", ")", "{", "if", "(", "element", "instanceof", "IParent", ")", "{", "ArrayList", "newRootElements", "=", "new", "ArrayList", "(", ")", ";", "for", "(", "int", "i", "=", "0", ",", "size", "=", "this", ".", "rootElements", ".", "size", "(", ")", ";", "i", "<", "size", ";", "i", "++", ")", "{", "IJavaElement", "currentRoot", "=", "(", "IJavaElement", ")", "this", ".", "rootElements", ".", "get", "(", "i", ")", ";", "IJavaElement", "parent", "=", "currentRoot", ".", "getParent", "(", ")", ";", "boolean", "isChild", "=", "false", ";", "while", "(", "parent", "!=", "null", ")", "{", "if", "(", "parent", ".", "equals", "(", "element", ")", ")", "{", "isChild", "=", "true", ";", "break", ";", "}", "parent", "=", "parent", ".", "getParent", "(", ")", ";", "}", "if", "(", "!", "isChild", ")", "{", "newRootElements", ".", "add", "(", "currentRoot", ")", ";", "}", "}", "this", ".", "rootElements", "=", "newRootElements", ";", "}", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", ")", ";", "IJavaElement", "[", "]", "roots", "=", "getElements", "(", ")", ";", "buffer", ".", "append", "(", "'['", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "roots", ".", "length", ";", "i", "++", ")", "{", "buffer", ".", "append", "(", "roots", "[", "i", "]", ".", "getElementName", "(", ")", ")", ";", "if", "(", "i", "<", "(", "roots", ".", "length", "-", "1", ")", ")", "{", "buffer", ".", "append", "(", "\",", "\"", ")", ";", "}", "}", "buffer", ".", "append", "(", "']'", ")", ";", "return", "buffer", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
5,520
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "io", ".", "File", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IResource", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IPath", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IPackageFragmentRoot", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "public", "class", "ExternalPackageFragmentRoot", "extends", "PackageFragmentRoot", "{", "protected", "final", "IPath", "externalPath", ";", "protected", "ExternalPackageFragmentRoot", "(", "IPath", "externalPath", ",", "JavaProject", "project", ")", "{", "super", "(", "null", ",", "project", ")", ";", "this", ".", "externalPath", "=", "externalPath", ";", "}", "protected", "ExternalPackageFragmentRoot", "(", "IResource", "linkedFolder", ",", "IPath", "externalPath", ",", "JavaProject", "project", ")", "{", "super", "(", "linkedFolder", ",", "project", ")", ";", "this", ".", "externalPath", "=", "externalPath", "==", "null", "?", "linkedFolder", ".", "getLocation", "(", ")", ":", "externalPath", ";", "}", "protected", "int", "determineKind", "(", "IResource", "underlyingResource", ")", "{", "return", "IPackageFragmentRoot", ".", "K_BINARY", ";", "}", "public", "boolean", "equals", "(", "Object", "o", ")", "{", "if", "(", "this", "==", "o", ")", "return", "true", ";", "if", "(", "o", "instanceof", "ExternalPackageFragmentRoot", ")", "{", "ExternalPackageFragmentRoot", "other", "=", "(", "ExternalPackageFragmentRoot", ")", "o", ";", "return", "this", ".", "externalPath", ".", "equals", "(", "other", ".", "externalPath", ")", ";", "}", "return", "false", ";", "}", "public", "String", "getElementName", "(", ")", "{", "return", "this", ".", "externalPath", ".", "lastSegment", "(", ")", ";", "}", "public", "int", "getKind", "(", ")", "{", "return", "IPackageFragmentRoot", ".", "K_BINARY", ";", "}", "int", "internalKind", "(", ")", "throws", "JavaModelException", "{", "return", "IPackageFragmentRoot", ".", "K_BINARY", ";", "}", "public", "IPath", "getPath", "(", ")", "{", "return", "this", ".", "externalPath", ";", "}", "public", "IResource", "getUnderlyingResource", "(", ")", "throws", "JavaModelException", "{", "return", "null", ";", "}", "public", "int", "hashCode", "(", ")", "{", "return", "this", ".", "externalPath", ".", "hashCode", "(", ")", ";", "}", "public", "boolean", "isExternal", "(", ")", "{", "return", "true", ";", "}", "public", "IResource", "resource", "(", "PackageFragmentRoot", "root", ")", "{", "if", "(", "this", ".", "resource", "==", "null", ")", "return", "this", ".", "resource", "=", "JavaModelManager", ".", "getExternalManager", "(", ")", ".", "getFolder", "(", "this", ".", "externalPath", ")", ";", "return", "super", ".", "resource", "(", "root", ")", ";", "}", "protected", "boolean", "resourceExists", "(", "IResource", "underlyingResource", ")", "{", "if", "(", "underlyingResource", "==", "null", ")", "return", "false", ";", "IPath", "location", "=", "underlyingResource", ".", "getLocation", "(", ")", ";", "if", "(", "location", "==", "null", ")", "return", "false", ";", "File", "file", "=", "location", ".", "toFile", "(", ")", ";", "if", "(", "file", "==", "null", ")", "return", "false", ";", "return", "file", ".", "exists", "(", ")", ";", "}", "protected", "void", "toStringAncestors", "(", "StringBuffer", "buffer", ")", "{", "}", "}", "</s>" ]
5,521
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "io", ".", "File", ";", "import", "java", ".", "io", ".", "IOException", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IFile", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IProject", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "CoreException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaProject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "Util", ";", "public", "class", "BasicCompilationUnit", "implements", "ICompilationUnit", "{", "protected", "char", "[", "]", "contents", ";", "protected", "char", "[", "]", "fileName", ";", "protected", "char", "[", "]", "[", "]", "packageName", ";", "protected", "char", "[", "]", "mainTypeName", ";", "protected", "String", "encoding", ";", "public", "BasicCompilationUnit", "(", "char", "[", "]", "contents", ",", "char", "[", "]", "[", "]", "packageName", ",", "String", "fileName", ")", "{", "this", ".", "contents", "=", "contents", ";", "this", ".", "fileName", "=", "fileName", ".", "toCharArray", "(", ")", ";", "this", ".", "packageName", "=", "packageName", ";", "}", "public", "BasicCompilationUnit", "(", "char", "[", "]", "contents", ",", "char", "[", "]", "[", "]", "packageName", ",", "String", "fileName", ",", "String", "encoding", ")", "{", "this", "(", "contents", ",", "packageName", ",", "fileName", ")", ";", "this", ".", "encoding", "=", "encoding", ";", "}", "public", "BasicCompilationUnit", "(", "char", "[", "]", "contents", ",", "char", "[", "]", "[", "]", "packageName", ",", "String", "fileName", ",", "IJavaElement", "javaElement", ")", "{", "this", "(", "contents", ",", "packageName", ",", "fileName", ")", ";", "initEncoding", "(", "javaElement", ")", ";", "}", "private", "void", "initEncoding", "(", "IJavaElement", "javaElement", ")", "{", "if", "(", "javaElement", "!=", "null", ")", "{", "try", "{", "IJavaProject", "javaProject", "=", "javaElement", ".", "getJavaProject", "(", ")", ";", "switch", "(", "javaElement", ".", "getElementType", "(", ")", ")", "{", "case", "IJavaElement", ".", "COMPILATION_UNIT", ":", "IFile", "file", "=", "(", "IFile", ")", "javaElement", ".", "getResource", "(", ")", ";", "if", "(", "file", "!=", "null", ")", "{", "this", ".", "encoding", "=", "file", ".", "getCharset", "(", ")", ";", "break", ";", "}", "default", ":", "IProject", "project", "=", "(", "IProject", ")", "javaProject", ".", "getResource", "(", ")", ";", "if", "(", "project", "!=", "null", ")", "{", "this", ".", "encoding", "=", "project", ".", "getDefaultCharset", "(", ")", ";", "}", "break", ";", "}", "}", "catch", "(", "CoreException", "e1", ")", "{", "this", ".", "encoding", "=", "null", ";", "}", "}", "else", "{", "this", ".", "encoding", "=", "null", ";", "}", "}", "public", "char", "[", "]", "getContents", "(", ")", "{", "if", "(", "this", ".", "contents", "!=", "null", ")", "return", "this", ".", "contents", ";", "try", "{", "return", "Util", ".", "getFileCharContent", "(", "new", "File", "(", "new", "String", "(", "this", ".", "fileName", ")", ")", ",", "this", ".", "encoding", ")", ";", "}", "catch", "(", "IOException", "e", ")", "{", "}", "return", "CharOperation", ".", "NO_CHAR", ";", "}", "public", "char", "[", "]", "getFileName", "(", ")", "{", "return", "this", ".", "fileName", ";", "}", "public", "char", "[", "]", "getMainTypeName", "(", ")", "{", "if", "(", "this", ".", "mainTypeName", "==", "null", ")", "{", "int", "start", "=", "CharOperation", ".", "lastIndexOf", "(", "'/'", ",", "this", ".", "fileName", ")", "+", "1", ";", "if", "(", "start", "==", "0", "||", "start", "<", "CharOperation", ".", "lastIndexOf", "(", "'\\\\'", ",", "this", ".", "fileName", ")", ")", "start", "=", "CharOperation", ".", "lastIndexOf", "(", "'\\\\'", ",", "this", ".", "fileName", ")", "+", "1", ";", "int", "separator", "=", "CharOperation", ".", "indexOf", "(", "'|'", ",", "this", ".", "fileName", ")", "+", "1", ";", "if", "(", "separator", ">", "start", ")", "start", "=", "separator", ";", "int", "end", "=", "CharOperation", ".", "lastIndexOf", "(", "'$'", ",", "this", ".", "fileName", ")", ";", "if", "(", "end", "==", "-", "1", "||", "!", "Util", ".", "isClassFileName", "(", "this", ".", "fileName", ")", ")", "{", "end", "=", "CharOperation", ".", "lastIndexOf", "(", "'.'", ",", "this", ".", "fileName", ")", ";", "if", "(", "end", "==", "-", "1", ")", "end", "=", "this", ".", "fileName", ".", "length", ";", "}", "this", ".", "mainTypeName", "=", "CharOperation", ".", "subarray", "(", "this", ".", "fileName", ",", "start", ",", "end", ")", ";", "}", "return", "this", ".", "mainTypeName", ";", "}", "public", "char", "[", "]", "[", "]", "getPackageName", "(", ")", "{", "return", "this", ".", "packageName", ";", "}", "public", "String", "toString", "(", ")", "{", "return", "\"\"", "+", "new", "String", "(", "this", ".", "fileName", ")", ";", "}", "}", "</s>" ]
5,522
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "CoreException", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IPath", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IStatus", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Status", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ClasspathContainerInitializer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IClasspathContainer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatus", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatusConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaProject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IPackageFragment", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaCore", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Messages", ";", "public", "class", "JavaModelStatus", "extends", "Status", "implements", "IJavaModelStatus", ",", "IJavaModelStatusConstants", "{", "protected", "IJavaElement", "[", "]", "elements", "=", "new", "IJavaElement", "[", "0", "]", ";", "protected", "IPath", "path", ";", "protected", "String", "string", ";", "protected", "final", "static", "IStatus", "[", "]", "NO_CHILDREN", "=", "new", "IStatus", "[", "]", "{", "}", ";", "protected", "IStatus", "[", "]", "children", "=", "NO_CHILDREN", ";", "public", "static", "final", "IJavaModelStatus", "VERIFIED_OK", "=", "new", "JavaModelStatus", "(", "OK", ",", "OK", ",", "Messages", ".", "status_OK", ")", ";", "public", "JavaModelStatus", "(", ")", "{", "super", "(", "ERROR", ",", "JavaCore", ".", "PLUGIN_ID", ",", "0", ",", "\"\"", ",", "null", ")", ";", "}", "public", "JavaModelStatus", "(", "int", "code", ")", "{", "super", "(", "ERROR", ",", "JavaCore", ".", "PLUGIN_ID", ",", "code", ",", "\"\"", ",", "null", ")", ";", "this", ".", "elements", "=", "JavaElement", ".", "NO_ELEMENTS", ";", "}", "public", "JavaModelStatus", "(", "int", "code", ",", "IJavaElement", "[", "]", "elements", ")", "{", "super", "(", "ERROR", ",", "JavaCore", ".", "PLUGIN_ID", ",", "code", ",", "\"\"", ",", "null", ")", ";", "this", ".", "elements", "=", "elements", ";", "this", ".", "path", "=", "null", ";", "}", "public", "JavaModelStatus", "(", "int", "code", ",", "String", "string", ")", "{", "this", "(", "ERROR", ",", "code", ",", "string", ")", ";", "}", "public", "JavaModelStatus", "(", "int", "severity", ",", "int", "code", ",", "String", "string", ")", "{", "super", "(", "severity", ",", "JavaCore", ".", "PLUGIN_ID", ",", "code", ",", "\"\"", ",", "null", ")", ";", "this", ".", "elements", "=", "JavaElement", ".", "NO_ELEMENTS", ";", "this", ".", "path", "=", "null", ";", "this", ".", "string", "=", "string", ";", "}", "public", "JavaModelStatus", "(", "int", "code", ",", "Throwable", "throwable", ")", "{", "super", "(", "ERROR", ",", "JavaCore", ".", "PLUGIN_ID", ",", "code", ",", "\"\"", ",", "throwable", ")", ";", "this", ".", "elements", "=", "JavaElement", ".", "NO_ELEMENTS", ";", "}", "public", "JavaModelStatus", "(", "int", "code", ",", "IPath", "path", ")", "{", "super", "(", "ERROR", ",", "JavaCore", ".", "PLUGIN_ID", ",", "code", ",", "\"\"", ",", "null", ")", ";", "this", ".", "elements", "=", "JavaElement", ".", "NO_ELEMENTS", ";", "this", ".", "path", "=", "path", ";", "}", "public", "JavaModelStatus", "(", "int", "code", ",", "IJavaElement", "element", ")", "{", "this", "(", "code", ",", "new", "IJavaElement", "[", "]", "{", "element", "}", ")", ";", "}", "public", "JavaModelStatus", "(", "int", "code", ",", "IJavaElement", "element", ",", "String", "string", ")", "{", "this", "(", "code", ",", "new", "IJavaElement", "[", "]", "{", "element", "}", ")", ";", "this", ".", "string", "=", "string", ";", "}", "public", "JavaModelStatus", "(", "int", "code", ",", "IJavaElement", "element", ",", "IPath", "path", ")", "{", "this", "(", "code", ",", "new", "IJavaElement", "[", "]", "{", "element", "}", ")", ";", "this", ".", "path", "=", "path", ";", "}", "public", "JavaModelStatus", "(", "int", "code", ",", "IJavaElement", "element", ",", "IPath", "path", ",", "String", "string", ")", "{", "this", "(", "code", ",", "new", "IJavaElement", "[", "]", "{", "element", "}", ")", ";", "this", ".", "path", "=", "path", ";", "this", ".", "string", "=", "string", ";", "}", "public", "JavaModelStatus", "(", "int", "severity", ",", "int", "code", ",", "IJavaElement", "element", ",", "IPath", "path", ",", "String", "msg", ")", "{", "super", "(", "severity", ",", "JavaCore", ".", "PLUGIN_ID", ",", "code", ",", "\"\"", ",", "null", ")", ";", "this", ".", "elements", "=", "new", "IJavaElement", "[", "]", "{", "element", "}", ";", "this", ".", "path", "=", "path", ";", "this", ".", "string", "=", "msg", ";", "}", "public", "JavaModelStatus", "(", "CoreException", "coreException", ")", "{", "super", "(", "ERROR", ",", "JavaCore", ".", "PLUGIN_ID", ",", "CORE_EXCEPTION", ",", "\"\"", ",", "coreException", ")", ";", "this", ".", "elements", "=", "JavaElement", ".", "NO_ELEMENTS", ";", "}", "protected", "int", "getBits", "(", ")", "{", "int", "severity", "=", "1", "<<", "(", "getCode", "(", ")", "%", "100", "/", "33", ")", ";", "int", "category", "=", "1", "<<", "(", "(", "getCode", "(", ")", "/", "100", ")", "+", "3", ")", ";", "return", "severity", "|", "category", ";", "}", "public", "IStatus", "[", "]", "getChildren", "(", ")", "{", "return", "this", ".", "children", ";", "}", "public", "IJavaElement", "[", "]", "getElements", "(", ")", "{", "return", "this", ".", "elements", ";", "}", "public", "String", "getMessage", "(", ")", "{", "Throwable", "exception", "=", "getException", "(", ")", ";", "if", "(", "exception", "==", "null", ")", "{", "switch", "(", "getCode", "(", ")", ")", "{", "case", "CORE_EXCEPTION", ":", "return", "Messages", ".", "status_coreException", ";", "case", "BUILDER_INITIALIZATION_ERROR", ":", "return", "Messages", ".", "build_initializationError", ";", "case", "BUILDER_SERIALIZATION_ERROR", ":", "return", "Messages", ".", "build_serializationError", ";", "case", "DEVICE_PATH", ":", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_cannotUseDeviceOnPath", ",", "getPath", "(", ")", ".", "toString", "(", ")", ")", ";", "case", "DOM_EXCEPTION", ":", "return", "Messages", ".", "status_JDOMError", ";", "case", "ELEMENT_DOES_NOT_EXIST", ":", "return", "Messages", ".", "bind", "(", "Messages", ".", "element_doesNotExist", ",", "(", "(", "JavaElement", ")", "this", ".", "elements", "[", "0", "]", ")", ".", "toStringWithAncestors", "(", ")", ")", ";", "case", "ELEMENT_NOT_ON_CLASSPATH", ":", "return", "Messages", ".", "bind", "(", "Messages", ".", "element_notOnClasspath", ",", "(", "(", "JavaElement", ")", "this", ".", "elements", "[", "0", "]", ")", ".", "toStringWithAncestors", "(", ")", ")", ";", "case", "EVALUATION_ERROR", ":", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_evaluationError", ",", "this", ".", "string", ")", ";", "case", "INDEX_OUT_OF_BOUNDS", ":", "return", "Messages", ".", "status_indexOutOfBounds", ";", "case", "INVALID_CONTENTS", ":", "return", "Messages", ".", "status_invalidContents", ";", "case", "INVALID_DESTINATION", ":", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_invalidDestination", ",", "(", "(", "JavaElement", ")", "this", ".", "elements", "[", "0", "]", ")", ".", "toStringWithAncestors", "(", ")", ")", ";", "case", "INVALID_ELEMENT_TYPES", ":", "StringBuffer", "buff", "=", "new", "StringBuffer", "(", "Messages", ".", "operation_notSupported", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "elements", ".", "length", ";", "i", "++", ")", "{", "if", "(", "i", ">", "0", ")", "{", "buff", ".", "append", "(", "\",", "\"", ")", ";", "}", "buff", ".", "append", "(", "(", "(", "JavaElement", ")", "this", ".", "elements", "[", "i", "]", ")", ".", "toStringWithAncestors", "(", ")", ")", ";", "}", "return", "buff", ".", "toString", "(", ")", ";", "case", "INVALID_NAME", ":", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_invalidName", ",", "this", ".", "string", ")", ";", "case", "INVALID_PACKAGE", ":", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_invalidPackage", ",", "this", ".", "string", ")", ";", "case", "INVALID_PATH", ":", "if", "(", "this", ".", "string", "!=", "null", ")", "{", "return", "this", ".", "string", ";", "}", "else", "{", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_invalidPath", ",", "new", "String", "[", "]", "{", "getPath", "(", ")", "==", "null", "?", "\"null\"", ":", "getPath", "(", ")", ".", "toString", "(", ")", "}", ")", ";", "}", "case", "INVALID_PROJECT", ":", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_invalidProject", ",", "this", ".", "string", ")", ";", "case", "INVALID_RESOURCE", ":", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_invalidResource", ",", "this", ".", "string", ")", ";", "case", "INVALID_RESOURCE_TYPE", ":", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_invalidResourceType", ",", "this", ".", "string", ")", ";", "case", "INVALID_SIBLING", ":", "if", "(", "this", ".", "string", "!=", "null", ")", "{", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_invalidSibling", ",", "this", ".", "string", ")", ";", "}", "else", "{", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_invalidSibling", ",", "(", "(", "JavaElement", ")", "this", ".", "elements", "[", "0", "]", ")", ".", "toStringWithAncestors", "(", ")", ")", ";", "}", "case", "IO_EXCEPTION", ":", "return", "Messages", ".", "status_IOException", ";", "case", "NAME_COLLISION", ":", "if", "(", "this", ".", "elements", "!=", "null", "&&", "this", ".", "elements", ".", "length", ">", "0", ")", "{", "IJavaElement", "element", "=", "this", ".", "elements", "[", "0", "]", ";", "if", "(", "element", "instanceof", "PackageFragment", "&&", "(", "(", "PackageFragment", ")", "element", ")", ".", "isDefaultPackage", "(", ")", ")", "{", "return", "Messages", ".", "operation_cannotRenameDefaultPackage", ";", "}", "}", "if", "(", "this", ".", "string", "!=", "null", ")", "{", "return", "this", ".", "string", ";", "}", "else", "{", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_nameCollision", ",", "\"\"", ")", ";", "}", "case", "NO_ELEMENTS_TO_PROCESS", ":", "return", "Messages", ".", "operation_needElements", ";", "case", "NULL_NAME", ":", "return", "Messages", ".", "operation_needName", ";", "case", "NULL_PATH", ":", "return", "Messages", ".", "operation_needPath", ";", "case", "NULL_STRING", ":", "return", "Messages", ".", "operation_needString", ";", "case", "PATH_OUTSIDE_PROJECT", ":", "return", "Messages", ".", "bind", "(", "Messages", ".", "operation_pathOutsideProject", ",", "new", "String", "[", "]", "{", "this", ".", "string", ",", "(", "(", "JavaElement", ")", "this", ".", "elements", "[", "0", "]", ")", ".", "toStringWithAncestors", "(", ")", "}", ")", ";", "case", "READ_ONLY", ":", "IJavaElement", "element", "=", "this", ".", "elements", "[", "0", "]", ";", "String", "name", "=", "element", ".", "getElementName", "(", ")", ";", "if", "(", "element", "instanceof", "IPackageFragment", "&&", "name", ".", "equals", "(", "IPackageFragment", ".", "DEFAULT_PACKAGE_NAME", ")", ")", "{", "return", "Messages", ".", "status_defaultPackageReadOnly", ";", "}", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_readOnly", ",", "name", ")", ";", "case", "RELATIVE_PATH", ":", "return", "Messages", ".", "bind", "(", "Messages", ".", "operation_needAbsolutePath", ",", "getPath", "(", ")", ".", "toString", "(", ")", ")", ";", "case", "TARGET_EXCEPTION", ":", "return", "Messages", ".", "status_targetException", ";", "case", "UPDATE_CONFLICT", ":", "return", "Messages", ".", "status_updateConflict", ";", "case", "NO_LOCAL_CONTENTS", ":", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_noLocalContents", ",", "getPath", "(", ")", ".", "toString", "(", ")", ")", ";", "case", "CP_CONTAINER_PATH_UNBOUND", ":", "IJavaProject", "javaProject", "=", "(", "IJavaProject", ")", "this", ".", "elements", "[", "0", "]", ";", "ClasspathContainerInitializer", "initializer", "=", "JavaCore", ".", "getClasspathContainerInitializer", "(", "this", ".", "path", ".", "segment", "(", "0", ")", ")", ";", "String", "description", "=", "null", ";", "if", "(", "initializer", "!=", "null", ")", "description", "=", "initializer", ".", "getDescription", "(", "this", ".", "path", ",", "javaProject", ")", ";", "if", "(", "description", "==", "null", ")", "description", "=", "this", ".", "path", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ";", "return", "Messages", ".", "bind", "(", "Messages", ".", "classpath_unboundContainerPath", ",", "new", "String", "[", "]", "{", "description", ",", "javaProject", ".", "getElementName", "(", ")", "}", ")", ";", "case", "INVALID_CP_CONTAINER_ENTRY", ":", "javaProject", "=", "(", "IJavaProject", ")", "this", ".", "elements", "[", "0", "]", ";", "IClasspathContainer", "container", "=", "null", ";", "description", "=", "null", ";", "try", "{", "container", "=", "JavaCore", ".", "getClasspathContainer", "(", "this", ".", "path", ",", "javaProject", ")", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "}", "if", "(", "container", "==", "null", ")", "{", "initializer", "=", "JavaCore", ".", "getClasspathContainerInitializer", "(", "this", ".", "path", ".", "segment", "(", "0", ")", ")", ";", "if", "(", "initializer", "!=", "null", ")", "description", "=", "initializer", ".", "getDescription", "(", "this", ".", "path", ",", "javaProject", ")", ";", "}", "else", "{", "description", "=", "container", ".", "getDescription", "(", ")", ";", "}", "if", "(", "description", "==", "null", ")", "description", "=", "this", ".", "path", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ";", "return", "Messages", ".", "bind", "(", "Messages", ".", "classpath_invalidContainer", ",", "new", "String", "[", "]", "{", "description", ",", "javaProject", ".", "getElementName", "(", ")", "}", ")", ";", "case", "CP_VARIABLE_PATH_UNBOUND", ":", "javaProject", "=", "(", "IJavaProject", ")", "this", ".", "elements", "[", "0", "]", ";", "return", "Messages", ".", "bind", "(", "Messages", ".", "classpath_unboundVariablePath", ",", "new", "String", "[", "]", "{", "this", ".", "path", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ",", "javaProject", ".", "getElementName", "(", ")", "}", ")", ";", "case", "CLASSPATH_CYCLE", ":", "javaProject", "=", "(", "IJavaProject", ")", "this", ".", "elements", "[", "0", "]", ";", "return", "Messages", ".", "bind", "(", "Messages", ".", "classpath_cycle", ",", "javaProject", ".", "getElementName", "(", ")", ")", ";", "case", "DISABLED_CP_EXCLUSION_PATTERNS", ":", "javaProject", "=", "(", "IJavaProject", ")", "this", ".", "elements", "[", "0", "]", ";", "String", "projectName", "=", "javaProject", ".", "getElementName", "(", ")", ";", "IPath", "newPath", "=", "this", ".", "path", ";", "if", "(", "this", ".", "path", ".", "segment", "(", "0", ")", ".", "toString", "(", ")", ".", "equals", "(", "projectName", ")", ")", "{", "newPath", "=", "this", ".", "path", ".", "removeFirstSegments", "(", "1", ")", ";", "}", "return", "Messages", ".", "bind", "(", "Messages", ".", "classpath_disabledInclusionExclusionPatterns", ",", "new", "String", "[", "]", "{", "newPath", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ",", "projectName", "}", ")", ";", "case", "DISABLED_CP_MULTIPLE_OUTPUT_LOCATIONS", ":", "javaProject", "=", "(", "IJavaProject", ")", "this", ".", "elements", "[", "0", "]", ";", "projectName", "=", "javaProject", ".", "getElementName", "(", ")", ";", "newPath", "=", "this", ".", "path", ";", "if", "(", "this", ".", "path", ".", "segment", "(", "0", ")", ".", "toString", "(", ")", ".", "equals", "(", "projectName", ")", ")", "{", "newPath", "=", "this", ".", "path", ".", "removeFirstSegments", "(", "1", ")", ";", "}", "return", "Messages", ".", "bind", "(", "Messages", ".", "classpath_disabledMultipleOutputLocations", ",", "new", "String", "[", "]", "{", "newPath", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ",", "projectName", "}", ")", ";", "case", "CANNOT_RETRIEVE_ATTACHED_JAVADOC", ":", "if", "(", "this", ".", "elements", "!=", "null", "&&", "this", ".", "elements", ".", "length", "==", "1", ")", "{", "if", "(", "this", ".", "string", "!=", "null", ")", "{", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_cannot_retrieve_attached_javadoc", ",", "(", "(", "JavaElement", ")", "this", ".", "elements", "[", "0", "]", ")", ".", "toStringWithAncestors", "(", ")", ",", "this", ".", "string", ")", ";", "}", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_cannot_retrieve_attached_javadoc", ",", "(", "(", "JavaElement", ")", "this", ".", "elements", "[", "0", "]", ")", ".", "toStringWithAncestors", "(", ")", ",", "\"\"", ")", ";", "}", "if", "(", "this", ".", "string", "!=", "null", ")", "{", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_cannot_retrieve_attached_javadoc", ",", "this", ".", "string", ",", "\"\"", ")", ";", "}", "break", ";", "case", "UNKNOWN_JAVADOC_FORMAT", ":", "return", "Messages", ".", "bind", "(", "Messages", ".", "status_unknown_javadoc_format", ",", "(", "(", "JavaElement", ")", "this", ".", "elements", "[", "0", "]", ")", ".", "toStringWithAncestors", "(", ")", ")", ";", "case", "DEPRECATED_VARIABLE", ":", "javaProject", "=", "(", "IJavaProject", ")", "this", ".", "elements", "[", "0", "]", ";", "return", "Messages", ".", "bind", "(", "Messages", ".", "classpath_deprecated_variable", ",", "new", "String", "[", "]", "{", "this", ".", "path", ".", "segment", "(", "0", ")", ".", "toString", "(", ")", ",", "javaProject", ".", "getElementName", "(", ")", ",", "this", ".", "string", "}", ")", ";", "}", "if", "(", "this", ".", "string", "!=", "null", ")", "{", "return", "this", ".", "string", ";", "}", "else", "{", "return", "\"\"", ";", "}", "}", "else", "{", "String", "message", "=", "exception", ".", "getMessage", "(", ")", ";", "if", "(", "message", "!=", "null", ")", "{", "return", "message", ";", "}", "else", "{", "return", "exception", ".", "toString", "(", ")", ";", "}", "}", "}", "public", "IPath", "getPath", "(", ")", "{", "return", "this", ".", "path", ";", "}", "public", "int", "getSeverity", "(", ")", "{", "if", "(", "this", ".", "children", "==", "NO_CHILDREN", ")", "return", "super", ".", "getSeverity", "(", ")", ";", "int", "severity", "=", "-", "1", ";", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "children", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "int", "childrenSeverity", "=", "this", ".", "children", "[", "i", "]", ".", "getSeverity", "(", ")", ";", "if", "(", "childrenSeverity", ">", "severity", ")", "{", "severity", "=", "childrenSeverity", ";", "}", "}", "return", "severity", ";", "}", "public", "String", "getString", "(", ")", "{", "return", "this", ".", "string", ";", "}", "public", "boolean", "isDoesNotExist", "(", ")", "{", "int", "code", "=", "getCode", "(", ")", ";", "return", "code", "==", "ELEMENT_DOES_NOT_EXIST", "||", "code", "==", "ELEMENT_NOT_ON_CLASSPATH", ";", "}", "public", "boolean", "isMultiStatus", "(", ")", "{", "return", "this", ".", "children", "!=", "NO_CHILDREN", ";", "}", "public", "boolean", "isOK", "(", ")", "{", "return", "getCode", "(", ")", "==", "OK", ";", "}", "public", "boolean", "matches", "(", "int", "mask", ")", "{", "if", "(", "!", "isMultiStatus", "(", ")", ")", "{", "return", "matches", "(", "this", ",", "mask", ")", ";", "}", "else", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "children", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "matches", "(", "(", "JavaModelStatus", ")", "this", ".", "children", "[", "i", "]", ",", "mask", ")", ")", "return", "true", ";", "}", "return", "false", ";", "}", "}", "protected", "boolean", "matches", "(", "JavaModelStatus", "status", ",", "int", "mask", ")", "{", "int", "severityMask", "=", "mask", "&", "0x7", ";", "int", "categoryMask", "=", "mask", "&", "~", "0x7", ";", "int", "bits", "=", "status", ".", "getBits", "(", ")", ";", "return", "(", "(", "severityMask", "==", "0", ")", "||", "(", "bits", "&", "severityMask", ")", "!=", "0", ")", "&&", "(", "(", "categoryMask", "==", "0", ")", "||", "(", "bits", "&", "categoryMask", ")", "!=", "0", ")", ";", "}", "public", "static", "IJavaModelStatus", "newMultiStatus", "(", "IJavaModelStatus", "[", "]", "children", ")", "{", "JavaModelStatus", "jms", "=", "new", "JavaModelStatus", "(", ")", ";", "jms", ".", "children", "=", "children", ";", "return", "jms", ";", "}", "public", "String", "toString", "(", ")", "{", "if", "(", "this", "==", "VERIFIED_OK", ")", "{", "return", "\"\"", ";", "}", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", ")", ";", "buffer", ".", "append", "(", "\"\"", ")", ";", "buffer", ".", "append", "(", "getMessage", "(", ")", ")", ";", "buffer", ".", "append", "(", "\"]\"", ")", ";", "return", "buffer", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
5,523
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IBuffer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "WorkingCopyOwner", ";", "public", "class", "BufferFactoryWrapper", "extends", "WorkingCopyOwner", "{", "public", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IBufferFactory", "factory", ";", "private", "BufferFactoryWrapper", "(", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IBufferFactory", "factory", ")", "{", "this", ".", "factory", "=", "factory", ";", "}", "public", "static", "WorkingCopyOwner", "create", "(", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IBufferFactory", "factory", ")", "{", "return", "new", "BufferFactoryWrapper", "(", "factory", ")", ";", "}", "public", "IBuffer", "createBuffer", "(", "ICompilationUnit", "workingCopy", ")", "{", "if", "(", "this", ".", "factory", "==", "null", ")", "return", "super", ".", "createBuffer", "(", "workingCopy", ")", ";", "return", "this", ".", "factory", ".", "createBuffer", "(", "workingCopy", ")", ";", "}", "public", "boolean", "equals", "(", "Object", "obj", ")", "{", "if", "(", "!", "(", "obj", "instanceof", "BufferFactoryWrapper", ")", ")", "return", "false", ";", "BufferFactoryWrapper", "other", "=", "(", "BufferFactoryWrapper", ")", "obj", ";", "if", "(", "this", ".", "factory", "==", "null", ")", "return", "other", ".", "factory", "==", "null", ";", "return", "this", ".", "factory", ".", "equals", "(", "other", ".", "factory", ")", ";", "}", "public", "int", "hashCode", "(", ")", "{", "if", "(", "this", ".", "factory", "==", "null", ")", "return", "0", ";", "return", "this", ".", "factory", ".", "hashCode", "(", ")", ";", "}", "public", "String", "toString", "(", ")", "{", "return", "\"\"", "+", "this", ".", "factory", ";", "}", "}", "</s>" ]
5,524
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "io", ".", "ByteArrayOutputStream", ";", "import", "java", ".", "io", ".", "File", ";", "import", "java", ".", "io", ".", "IOException", ";", "import", "java", ".", "io", ".", "InputStream", ";", "import", "java", ".", "io", ".", "OutputStreamWriter", ";", "import", "java", ".", "io", ".", "UnsupportedEncodingException", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "HashSet", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "java", ".", "util", ".", "zip", ".", "ZipEntry", ";", "import", "java", ".", "util", ".", "zip", ".", "ZipFile", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IContainer", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IFile", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IProject", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IResource", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IWorkspaceRoot", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "ResourcesPlugin", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "CoreException", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IPath", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IStatus", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Path", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IAccessRule", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IClasspathAttribute", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IClasspathContainer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IClasspathEntry", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatus", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatusConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaProject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IPackageFragmentRoot", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaCore", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "IProblem", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "AccessRestriction", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "AccessRule", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "AccessRuleSet", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CompilerOptions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "ManifestAnalyzer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Messages", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "import", "org", ".", "w3c", ".", "dom", ".", "DOMException", ";", "import", "org", ".", "w3c", ".", "dom", ".", "Element", ";", "import", "org", ".", "w3c", ".", "dom", ".", "NamedNodeMap", ";", "import", "org", ".", "w3c", ".", "dom", ".", "Node", ";", "import", "org", ".", "w3c", ".", "dom", ".", "NodeList", ";", "import", "org", ".", "w3c", ".", "dom", ".", "Text", ";", "public", "class", "ClasspathEntry", "implements", "IClasspathEntry", "{", "public", "static", "class", "AssertionFailedException", "extends", "RuntimeException", "{", "private", "static", "final", "long", "serialVersionUID", "=", "-", "171699380721189572L", ";", "public", "AssertionFailedException", "(", "String", "message", ")", "{", "super", "(", "message", ")", ";", "}", "}", "public", "static", "final", "String", "TAG_CLASSPATH", "=", "\"classpath\"", ";", "public", "static", "final", "String", "TAG_CLASSPATHENTRY", "=", "\"\"", ";", "public", "static", "final", "String", "TAG_REFERENCED_ENTRY", "=", "\"\"", ";", "public", "static", "final", "String", "TAG_OUTPUT", "=", "\"output\"", ";", "public", "static", "final", "String", "TAG_KIND", "=", "\"kind\"", ";", "public", "static", "final", "String", "TAG_PATH", "=", "\"path\"", ";", "public", "static", "final", "String", "TAG_SOURCEPATH", "=", "\"sourcepath\"", ";", "public", "static", "final", "String", "TAG_ROOTPATH", "=", "\"rootpath\"", ";", "public", "static", "final", "String", "TAG_EXPORTED", "=", "\"exported\"", ";", "public", "static", "final", "String", "TAG_INCLUDING", "=", "\"including\"", ";", "public", "static", "final", "String", "TAG_EXCLUDING", "=", "\"excluding\"", ";", "public", "static", "final", "String", "TAG_ATTRIBUTES", "=", "\"attributes\"", ";", "public", "static", "final", "String", "TAG_ATTRIBUTE", "=", "\"attribute\"", ";", "public", "static", "final", "String", "TAG_ATTRIBUTE_NAME", "=", "\"name\"", ";", "public", "static", "final", "String", "TAG_ATTRIBUTE_VALUE", "=", "\"value\"", ";", "public", "static", "final", "String", "TAG_COMBINE_ACCESS_RULES", "=", "\"\"", ";", "public", "static", "final", "String", "TAG_ACCESS_RULES", "=", "\"accessrules\"", ";", "public", "static", "final", "String", "TAG_ACCESS_RULE", "=", "\"accessrule\"", ";", "public", "static", "final", "String", "TAG_PATTERN", "=", "\"pattern\"", ";", "public", "static", "final", "String", "TAG_ACCESSIBLE", "=", "\"accessible\"", ";", "public", "static", "final", "String", "TAG_NON_ACCESSIBLE", "=", "\"\"", ";", "public", "static", "final", "String", "TAG_DISCOURAGED", "=", "\"discouraged\"", ";", "public", "static", "final", "String", "TAG_IGNORE_IF_BETTER", "=", "\"\"", ";", "public", "int", "entryKind", ";", "public", "int", "contentKind", ";", "public", "IPath", "path", ";", "private", "IPath", "[", "]", "inclusionPatterns", ";", "private", "char", "[", "]", "[", "]", "fullInclusionPatternChars", ";", "private", "IPath", "[", "]", "exclusionPatterns", ";", "private", "char", "[", "]", "[", "]", "fullExclusionPatternChars", ";", "private", "final", "static", "char", "[", "]", "[", "]", "UNINIT_PATTERNS", "=", "new", "char", "[", "]", "[", "]", "{", "\"\"", ".", "toCharArray", "(", ")", "}", ";", "public", "final", "static", "ClasspathEntry", "[", "]", "NO_ENTRIES", "=", "new", "ClasspathEntry", "[", "0", "]", ";", "private", "final", "static", "IPath", "[", "]", "NO_PATHS", "=", "new", "IPath", "[", "0", "]", ";", "private", "final", "static", "IWorkspaceRoot", "workspaceRoot", "=", "ResourcesPlugin", ".", "getWorkspace", "(", ")", ".", "getRoot", "(", ")", ";", "private", "boolean", "combineAccessRules", ";", "private", "String", "rootID", ";", "private", "AccessRuleSet", "accessRuleSet", ";", "static", "class", "UnknownXmlElements", "{", "String", "[", "]", "attributes", ";", "ArrayList", "children", ";", "}", "public", "final", "static", "IPath", "[", "]", "INCLUDE_ALL", "=", "{", "}", ";", "public", "final", "static", "IPath", "[", "]", "EXCLUDE_NONE", "=", "{", "}", ";", "public", "final", "static", "IClasspathAttribute", "[", "]", "NO_EXTRA_ATTRIBUTES", "=", "{", "}", ";", "public", "final", "static", "IAccessRule", "[", "]", "NO_ACCESS_RULES", "=", "{", "}", ";", "public", "IPath", "sourceAttachmentPath", ";", "public", "IPath", "sourceAttachmentRootPath", ";", "public", "IClasspathEntry", "referencingEntry", ";", "public", "IPath", "specificOutputLocation", ";", "public", "static", "final", "int", "K_OUTPUT", "=", "10", ";", "public", "static", "final", "String", "DOT_DOT", "=", "\"..\"", ";", "public", "boolean", "isExported", ";", "public", "IClasspathAttribute", "[", "]", "extraAttributes", ";", "public", "ClasspathEntry", "(", "int", "contentKind", ",", "int", "entryKind", ",", "IPath", "path", ",", "IPath", "[", "]", "inclusionPatterns", ",", "IPath", "[", "]", "exclusionPatterns", ",", "IPath", "sourceAttachmentPath", ",", "IPath", "sourceAttachmentRootPath", ",", "IPath", "specificOutputLocation", ",", "boolean", "isExported", ",", "IAccessRule", "[", "]", "accessRules", ",", "boolean", "combineAccessRules", ",", "IClasspathAttribute", "[", "]", "extraAttributes", ")", "{", "this", "(", "contentKind", ",", "entryKind", ",", "path", ",", "inclusionPatterns", ",", "exclusionPatterns", ",", "sourceAttachmentPath", ",", "sourceAttachmentRootPath", ",", "specificOutputLocation", ",", "null", ",", "isExported", ",", "accessRules", ",", "combineAccessRules", ",", "extraAttributes", ")", ";", "}", "public", "ClasspathEntry", "(", "int", "contentKind", ",", "int", "entryKind", ",", "IPath", "path", ",", "IPath", "[", "]", "inclusionPatterns", ",", "IPath", "[", "]", "exclusionPatterns", ",", "IPath", "sourceAttachmentPath", ",", "IPath", "sourceAttachmentRootPath", ",", "IPath", "specificOutputLocation", ",", "IClasspathEntry", "referencingEntry", ",", "boolean", "isExported", ",", "IAccessRule", "[", "]", "accessRules", ",", "boolean", "combineAccessRules", ",", "IClasspathAttribute", "[", "]", "extraAttributes", ")", "{", "this", ".", "contentKind", "=", "contentKind", ";", "this", ".", "entryKind", "=", "entryKind", ";", "this", ".", "path", "=", "path", ";", "this", ".", "inclusionPatterns", "=", "inclusionPatterns", ";", "this", ".", "exclusionPatterns", "=", "exclusionPatterns", ";", "this", ".", "referencingEntry", "=", "referencingEntry", ";", "int", "length", ";", "if", "(", "accessRules", "!=", "null", "&&", "(", "length", "=", "accessRules", ".", "length", ")", ">", "0", ")", "{", "AccessRule", "[", "]", "rules", "=", "new", "AccessRule", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "accessRules", ",", "0", ",", "rules", ",", "0", ",", "length", ")", ";", "byte", "classpathEntryType", ";", "String", "classpathEntryName", ";", "JavaModelManager", "manager", "=", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ";", "if", "(", "this", ".", "entryKind", "==", "CPE_PROJECT", "||", "this", ".", "entryKind", "==", "CPE_SOURCE", ")", "{", "classpathEntryType", "=", "AccessRestriction", ".", "PROJECT", ";", "classpathEntryName", "=", "manager", ".", "intern", "(", "getPath", "(", ")", ".", "segment", "(", "0", ")", ")", ";", "}", "else", "{", "classpathEntryType", "=", "AccessRestriction", ".", "LIBRARY", ";", "Object", "target", "=", "JavaModel", ".", "getWorkspaceTarget", "(", "path", ")", ";", "if", "(", "target", "==", "null", ")", "{", "classpathEntryName", "=", "manager", ".", "intern", "(", "path", ".", "toOSString", "(", ")", ")", ";", "}", "else", "{", "classpathEntryName", "=", "manager", ".", "intern", "(", "path", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ")", ";", "}", "}", "this", ".", "accessRuleSet", "=", "new", "AccessRuleSet", "(", "rules", ",", "classpathEntryType", ",", "classpathEntryName", ")", ";", "}", "this", ".", "combineAccessRules", "=", "combineAccessRules", ";", "this", ".", "extraAttributes", "=", "extraAttributes", ";", "if", "(", "inclusionPatterns", "!=", "INCLUDE_ALL", "&&", "inclusionPatterns", ".", "length", ">", "0", ")", "{", "this", ".", "fullInclusionPatternChars", "=", "UNINIT_PATTERNS", ";", "}", "if", "(", "exclusionPatterns", ".", "length", ">", "0", ")", "{", "this", ".", "fullExclusionPatternChars", "=", "UNINIT_PATTERNS", ";", "}", "this", ".", "sourceAttachmentPath", "=", "sourceAttachmentPath", ";", "this", ".", "sourceAttachmentRootPath", "=", "sourceAttachmentRootPath", ";", "this", ".", "specificOutputLocation", "=", "specificOutputLocation", ";", "this", ".", "isExported", "=", "isExported", ";", "}", "public", "boolean", "combineAccessRules", "(", ")", "{", "return", "this", ".", "combineAccessRules", ";", "}", "public", "ClasspathEntry", "combineWith", "(", "ClasspathEntry", "referringEntry", ")", "{", "if", "(", "referringEntry", "==", "null", ")", "return", "this", ";", "if", "(", "referringEntry", ".", "isExported", "(", ")", "||", "referringEntry", ".", "getAccessRuleSet", "(", ")", "!=", "null", ")", "{", "boolean", "combine", "=", "this", ".", "entryKind", "==", "CPE_SOURCE", "||", "referringEntry", ".", "combineAccessRules", "(", ")", ";", "return", "new", "ClasspathEntry", "(", "getContentKind", "(", ")", ",", "getEntryKind", "(", ")", ",", "getPath", "(", ")", ",", "this", ".", "inclusionPatterns", ",", "this", ".", "exclusionPatterns", ",", "getSourceAttachmentPath", "(", ")", ",", "getSourceAttachmentRootPath", "(", ")", ",", "getOutputLocation", "(", ")", ",", "referringEntry", ".", "isExported", "(", ")", "||", "this", ".", "isExported", ",", "combine", "(", "referringEntry", ".", "getAccessRules", "(", ")", ",", "getAccessRules", "(", ")", ",", "combine", ")", ",", "this", ".", "combineAccessRules", ",", "this", ".", "extraAttributes", ")", ";", "}", "return", "this", ";", "}", "private", "IAccessRule", "[", "]", "combine", "(", "IAccessRule", "[", "]", "referringRules", ",", "IAccessRule", "[", "]", "rules", ",", "boolean", "combine", ")", "{", "if", "(", "!", "combine", ")", "return", "rules", ";", "if", "(", "rules", "==", "null", "||", "rules", ".", "length", "==", "0", ")", "return", "referringRules", ";", "int", "referringRulesLength", "=", "referringRules", ".", "length", ";", "int", "accessRulesLength", "=", "rules", ".", "length", ";", "int", "rulesLength", "=", "referringRulesLength", "+", "accessRulesLength", ";", "IAccessRule", "[", "]", "result", "=", "new", "IAccessRule", "[", "rulesLength", "]", ";", "System", ".", "arraycopy", "(", "referringRules", ",", "0", ",", "result", ",", "0", ",", "referringRulesLength", ")", ";", "System", ".", "arraycopy", "(", "rules", ",", "0", ",", "result", ",", "referringRulesLength", ",", "accessRulesLength", ")", ";", "return", "result", ";", "}", "static", "IClasspathAttribute", "[", "]", "decodeExtraAttributes", "(", "NodeList", "attributes", ")", "{", "if", "(", "attributes", "==", "null", ")", "return", "NO_EXTRA_ATTRIBUTES", ";", "int", "length", "=", "attributes", ".", "getLength", "(", ")", ";", "if", "(", "length", "==", "0", ")", "return", "NO_EXTRA_ATTRIBUTES", ";", "IClasspathAttribute", "[", "]", "result", "=", "new", "IClasspathAttribute", "[", "length", "]", ";", "int", "index", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "++", "i", ")", "{", "Node", "node", "=", "attributes", ".", "item", "(", "i", ")", ";", "if", "(", "node", ".", "getNodeType", "(", ")", "==", "Node", ".", "ELEMENT_NODE", ")", "{", "Element", "attribute", "=", "(", "Element", ")", "node", ";", "String", "name", "=", "attribute", ".", "getAttribute", "(", "TAG_ATTRIBUTE_NAME", ")", ";", "if", "(", "name", "==", "null", ")", "continue", ";", "String", "value", "=", "attribute", ".", "getAttribute", "(", "TAG_ATTRIBUTE_VALUE", ")", ";", "if", "(", "value", "==", "null", ")", "continue", ";", "result", "[", "index", "++", "]", "=", "new", "ClasspathAttribute", "(", "name", ",", "value", ")", ";", "}", "}", "if", "(", "index", "!=", "length", ")", "System", ".", "arraycopy", "(", "result", ",", "0", ",", "result", "=", "new", "IClasspathAttribute", "[", "index", "]", ",", "0", ",", "index", ")", ";", "return", "result", ";", "}", "static", "IAccessRule", "[", "]", "decodeAccessRules", "(", "NodeList", "list", ")", "{", "if", "(", "list", "==", "null", ")", "return", "null", ";", "int", "length", "=", "list", ".", "getLength", "(", ")", ";", "if", "(", "length", "==", "0", ")", "return", "null", ";", "IAccessRule", "[", "]", "result", "=", "new", "IAccessRule", "[", "length", "]", ";", "int", "index", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "Node", "accessRule", "=", "list", ".", "item", "(", "i", ")", ";", "if", "(", "accessRule", ".", "getNodeType", "(", ")", "==", "Node", ".", "ELEMENT_NODE", ")", "{", "Element", "elementAccessRule", "=", "(", "Element", ")", "accessRule", ";", "String", "pattern", "=", "elementAccessRule", ".", "getAttribute", "(", "TAG_PATTERN", ")", ";", "if", "(", "pattern", "==", "null", ")", "continue", ";", "String", "tagKind", "=", "elementAccessRule", ".", "getAttribute", "(", "TAG_KIND", ")", ";", "int", "kind", ";", "if", "(", "TAG_ACCESSIBLE", ".", "equals", "(", "tagKind", ")", ")", "kind", "=", "IAccessRule", ".", "K_ACCESSIBLE", ";", "else", "if", "(", "TAG_NON_ACCESSIBLE", ".", "equals", "(", "tagKind", ")", ")", "kind", "=", "IAccessRule", ".", "K_NON_ACCESSIBLE", ";", "else", "if", "(", "TAG_DISCOURAGED", ".", "equals", "(", "tagKind", ")", ")", "kind", "=", "IAccessRule", ".", "K_DISCOURAGED", ";", "else", "continue", ";", "boolean", "ignoreIfBetter", "=", "\"true\"", ".", "equals", "(", "elementAccessRule", ".", "getAttribute", "(", "TAG_IGNORE_IF_BETTER", ")", ")", ";", "result", "[", "index", "++", "]", "=", "new", "ClasspathAccessRule", "(", "new", "Path", "(", "pattern", ")", ",", "ignoreIfBetter", "?", "kind", "|", "IAccessRule", ".", "IGNORE_IF_BETTER", ":", "kind", ")", ";", "}", "}", "if", "(", "index", "!=", "length", ")", "System", ".", "arraycopy", "(", "result", ",", "0", ",", "result", "=", "new", "IAccessRule", "[", "index", "]", ",", "0", ",", "index", ")", ";", "return", "result", ";", "}", "private", "static", "IPath", "[", "]", "decodePatterns", "(", "NamedNodeMap", "nodeMap", ",", "String", "tag", ")", "{", "String", "sequence", "=", "removeAttribute", "(", "tag", ",", "nodeMap", ")", ";", "if", "(", "!", "sequence", ".", "equals", "(", "\"\"", ")", ")", "{", "char", "[", "]", "[", "]", "patterns", "=", "CharOperation", ".", "splitOn", "(", "'|'", ",", "sequence", ".", "toCharArray", "(", ")", ")", ";", "int", "patternCount", ";", "if", "(", "(", "patternCount", "=", "patterns", ".", "length", ")", ">", "0", ")", "{", "IPath", "[", "]", "paths", "=", "new", "IPath", "[", "patternCount", "]", ";", "int", "index", "=", "0", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "patternCount", ";", "j", "++", ")", "{", "char", "[", "]", "pattern", "=", "patterns", "[", "j", "]", ";", "if", "(", "pattern", ".", "length", "==", "0", ")", "continue", ";", "paths", "[", "index", "++", "]", "=", "new", "Path", "(", "new", "String", "(", "pattern", ")", ")", ";", "}", "if", "(", "index", "<", "patternCount", ")", "System", ".", "arraycopy", "(", "paths", ",", "0", ",", "paths", "=", "new", "IPath", "[", "index", "]", ",", "0", ",", "index", ")", ";", "return", "paths", ";", "}", "}", "return", "null", ";", "}", "private", "static", "void", "decodeUnknownNode", "(", "Node", "node", ",", "StringBuffer", "buffer", ",", "IJavaProject", "project", ")", "{", "ByteArrayOutputStream", "s", "=", "new", "ByteArrayOutputStream", "(", ")", ";", "OutputStreamWriter", "writer", ";", "try", "{", "writer", "=", "new", "OutputStreamWriter", "(", "s", ",", "\"UTF8\"", ")", ";", "XMLWriter", "xmlWriter", "=", "new", "XMLWriter", "(", "writer", ",", "project", ",", "false", ")", ";", "decodeUnknownNode", "(", "node", ",", "xmlWriter", ",", "true", ")", ";", "xmlWriter", ".", "flush", "(", ")", ";", "xmlWriter", ".", "close", "(", ")", ";", "buffer", ".", "append", "(", "s", ".", "toString", "(", "\"UTF8\"", ")", ")", ";", "}", "catch", "(", "UnsupportedEncodingException", "e", ")", "{", "}", "}", "private", "static", "void", "decodeUnknownNode", "(", "Node", "node", ",", "XMLWriter", "xmlWriter", ",", "boolean", "insertNewLine", ")", "{", "switch", "(", "node", ".", "getNodeType", "(", ")", ")", "{", "case", "Node", ".", "ELEMENT_NODE", ":", "NamedNodeMap", "attributes", ";", "HashMap", "parameters", "=", "null", ";", "if", "(", "(", "attributes", "=", "node", ".", "getAttributes", "(", ")", ")", "!=", "null", ")", "{", "int", "length", "=", "attributes", ".", "getLength", "(", ")", ";", "if", "(", "length", ">", "0", ")", "{", "parameters", "=", "new", "HashMap", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "Node", "attribute", "=", "attributes", ".", "item", "(", "i", ")", ";", "parameters", ".", "put", "(", "attribute", ".", "getNodeName", "(", ")", ",", "attribute", ".", "getNodeValue", "(", ")", ")", ";", "}", "}", "}", "NodeList", "children", "=", "node", ".", "getChildNodes", "(", ")", ";", "int", "childrenLength", "=", "children", ".", "getLength", "(", ")", ";", "String", "nodeName", "=", "node", ".", "getNodeName", "(", ")", ";", "xmlWriter", ".", "printTag", "(", "nodeName", ",", "parameters", ",", "false", ",", "false", ",", "childrenLength", "==", "0", ")", ";", "if", "(", "childrenLength", ">", "0", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "childrenLength", ";", "i", "++", ")", "{", "decodeUnknownNode", "(", "children", ".", "item", "(", "i", ")", ",", "xmlWriter", ",", "false", ")", ";", "}", "xmlWriter", ".", "endTag", "(", "nodeName", ",", "false", ",", "insertNewLine", ")", ";", "}", "break", ";", "case", "Node", ".", "TEXT_NODE", ":", "String", "data", "=", "(", "(", "Text", ")", "node", ")", ".", "getData", "(", ")", ";", "xmlWriter", ".", "printString", "(", "data", ",", "false", ",", "false", ")", ";", "break", ";", "}", "}", "public", "char", "[", "]", "[", "]", "fullExclusionPatternChars", "(", ")", "{", "if", "(", "this", ".", "fullExclusionPatternChars", "==", "UNINIT_PATTERNS", ")", "{", "int", "length", "=", "this", ".", "exclusionPatterns", ".", "length", ";", "this", ".", "fullExclusionPatternChars", "=", "new", "char", "[", "length", "]", "[", "]", ";", "IPath", "prefixPath", "=", "this", ".", "path", ".", "removeTrailingSeparator", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "this", ".", "fullExclusionPatternChars", "[", "i", "]", "=", "prefixPath", ".", "append", "(", "this", ".", "exclusionPatterns", "[", "i", "]", ")", ".", "toString", "(", ")", ".", "toCharArray", "(", ")", ";", "}", "}", "return", "this", ".", "fullExclusionPatternChars", ";", "}", "public", "char", "[", "]", "[", "]", "fullInclusionPatternChars", "(", ")", "{", "if", "(", "this", ".", "fullInclusionPatternChars", "==", "UNINIT_PATTERNS", ")", "{", "int", "length", "=", "this", ".", "inclusionPatterns", ".", "length", ";", "this", ".", "fullInclusionPatternChars", "=", "new", "char", "[", "length", "]", "[", "]", ";", "IPath", "prefixPath", "=", "this", ".", "path", ".", "removeTrailingSeparator", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "this", ".", "fullInclusionPatternChars", "[", "i", "]", "=", "prefixPath", ".", "append", "(", "this", ".", "inclusionPatterns", "[", "i", "]", ")", ".", "toString", "(", ")", ".", "toCharArray", "(", ")", ";", "}", "}", "return", "this", ".", "fullInclusionPatternChars", ";", "}", "public", "void", "elementEncode", "(", "XMLWriter", "writer", ",", "IPath", "projectPath", ",", "boolean", "indent", ",", "boolean", "newLine", ",", "Map", "unknownElements", ",", "boolean", "isReferencedEntry", ")", "{", "HashMap", "parameters", "=", "new", "HashMap", "(", ")", ";", "parameters", ".", "put", "(", "TAG_KIND", ",", "ClasspathEntry", ".", "kindToString", "(", "this", ".", "entryKind", ")", ")", ";", "IPath", "xmlPath", "=", "this", ".", "path", ";", "if", "(", "this", ".", "entryKind", "!=", "IClasspathEntry", ".", "CPE_VARIABLE", "&&", "this", ".", "entryKind", "!=", "IClasspathEntry", ".", "CPE_CONTAINER", ")", "{", "if", "(", "xmlPath", ".", "isAbsolute", "(", ")", ")", "{", "if", "(", "projectPath", "!=", "null", "&&", "projectPath", ".", "isPrefixOf", "(", "xmlPath", ")", ")", "{", "if", "(", "xmlPath", ".", "segment", "(", "0", ")", ".", "equals", "(", "projectPath", ".", "segment", "(", "0", ")", ")", ")", "{", "xmlPath", "=", "xmlPath", ".", "removeFirstSegments", "(", "1", ")", ";", "xmlPath", "=", "xmlPath", ".", "makeRelative", "(", ")", ";", "}", "else", "{", "xmlPath", "=", "xmlPath", ".", "makeAbsolute", "(", ")", ";", "}", "}", "}", "}", "parameters", ".", "put", "(", "TAG_PATH", ",", "String", ".", "valueOf", "(", "xmlPath", ")", ")", ";", "if", "(", "this", ".", "sourceAttachmentPath", "!=", "null", ")", "{", "xmlPath", "=", "this", ".", "sourceAttachmentPath", ";", "if", "(", "this", ".", "entryKind", "!=", "IClasspathEntry", ".", "CPE_VARIABLE", "&&", "projectPath", "!=", "null", "&&", "projectPath", ".", "isPrefixOf", "(", "xmlPath", ")", ")", "{", "if", "(", "xmlPath", ".", "segment", "(", "0", ")", ".", "equals", "(", "projectPath", ".", "segment", "(", "0", ")", ")", ")", "{", "xmlPath", "=", "xmlPath", ".", "removeFirstSegments", "(", "1", ")", ";", "xmlPath", "=", "xmlPath", ".", "makeRelative", "(", ")", ";", "}", "}", "parameters", ".", "put", "(", "TAG_SOURCEPATH", ",", "String", ".", "valueOf", "(", "xmlPath", ")", ")", ";", "}", "if", "(", "this", ".", "sourceAttachmentRootPath", "!=", "null", ")", "{", "parameters", ".", "put", "(", "TAG_ROOTPATH", ",", "String", ".", "valueOf", "(", "this", ".", "sourceAttachmentRootPath", ")", ")", ";", "}", "if", "(", "this", ".", "isExported", ")", "{", "parameters", ".", "put", "(", "TAG_EXPORTED", ",", "\"true\"", ")", ";", "}", "encodePatterns", "(", "this", ".", "inclusionPatterns", ",", "TAG_INCLUDING", ",", "parameters", ")", ";", "encodePatterns", "(", "this", ".", "exclusionPatterns", ",", "TAG_EXCLUDING", ",", "parameters", ")", ";", "if", "(", "this", ".", "entryKind", "==", "CPE_PROJECT", "&&", "!", "this", ".", "combineAccessRules", ")", "parameters", ".", "put", "(", "TAG_COMBINE_ACCESS_RULES", ",", "\"false\"", ")", ";", "UnknownXmlElements", "unknownXmlElements", "=", "unknownElements", "==", "null", "?", "null", ":", "(", "UnknownXmlElements", ")", "unknownElements", ".", "get", "(", "this", ".", "path", ")", ";", "String", "[", "]", "unknownAttributes", ";", "if", "(", "unknownXmlElements", "!=", "null", "&&", "(", "unknownAttributes", "=", "unknownXmlElements", ".", "attributes", ")", "!=", "null", ")", "for", "(", "int", "i", "=", "0", ",", "length", "=", "unknownAttributes", ".", "length", ";", "i", "<", "length", ";", "i", "+=", "2", ")", "{", "String", "tagName", "=", "unknownAttributes", "[", "i", "]", ";", "String", "tagValue", "=", "unknownAttributes", "[", "i", "+", "1", "]", ";", "parameters", ".", "put", "(", "tagName", ",", "tagValue", ")", ";", "}", "if", "(", "this", ".", "specificOutputLocation", "!=", "null", ")", "{", "IPath", "outputLocation", "=", "this", ".", "specificOutputLocation", ".", "removeFirstSegments", "(", "1", ")", ";", "outputLocation", "=", "outputLocation", ".", "makeRelative", "(", ")", ";", "parameters", ".", "put", "(", "TAG_OUTPUT", ",", "String", ".", "valueOf", "(", "outputLocation", ")", ")", ";", "}", "boolean", "hasExtraAttributes", "=", "this", ".", "extraAttributes", ".", "length", "!=", "0", ";", "boolean", "hasRestrictions", "=", "getAccessRuleSet", "(", ")", "!=", "null", ";", "ArrayList", "unknownChildren", "=", "unknownXmlElements", "!=", "null", "?", "unknownXmlElements", ".", "children", ":", "null", ";", "boolean", "hasUnknownChildren", "=", "unknownChildren", "!=", "null", ";", "String", "tagName", "=", "isReferencedEntry", "?", "TAG_REFERENCED_ENTRY", ":", "TAG_CLASSPATHENTRY", ";", "writer", ".", "printTag", "(", "tagName", ",", "parameters", ",", "indent", ",", "newLine", ",", "!", "hasExtraAttributes", "&&", "!", "hasRestrictions", "&&", "!", "hasUnknownChildren", ")", ";", "if", "(", "hasExtraAttributes", ")", "encodeExtraAttributes", "(", "writer", ",", "indent", ",", "newLine", ")", ";", "if", "(", "hasRestrictions", ")", "encodeAccessRules", "(", "writer", ",", "indent", ",", "newLine", ")", ";", "if", "(", "hasUnknownChildren", ")", "encodeUnknownChildren", "(", "writer", ",", "indent", ",", "newLine", ",", "unknownChildren", ")", ";", "if", "(", "hasExtraAttributes", "||", "hasRestrictions", "||", "hasUnknownChildren", ")", "writer", ".", "endTag", "(", "tagName", ",", "indent", ",", "true", ")", ";", "}", "void", "encodeExtraAttributes", "(", "XMLWriter", "writer", ",", "boolean", "indent", ",", "boolean", "newLine", ")", "{", "writer", ".", "startTag", "(", "TAG_ATTRIBUTES", ",", "indent", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "extraAttributes", ".", "length", ";", "i", "++", ")", "{", "IClasspathAttribute", "attribute", "=", "this", ".", "extraAttributes", "[", "i", "]", ";", "HashMap", "parameters", "=", "new", "HashMap", "(", ")", ";", "parameters", ".", "put", "(", "TAG_ATTRIBUTE_NAME", ",", "attribute", ".", "getName", "(", ")", ")", ";", "parameters", ".", "put", "(", "TAG_ATTRIBUTE_VALUE", ",", "attribute", ".", "getValue", "(", ")", ")", ";", "writer", ".", "printTag", "(", "TAG_ATTRIBUTE", ",", "parameters", ",", "indent", ",", "newLine", ",", "true", ")", ";", "}", "writer", ".", "endTag", "(", "TAG_ATTRIBUTES", ",", "indent", ",", "true", ")", ";", "}", "void", "encodeAccessRules", "(", "XMLWriter", "writer", ",", "boolean", "indent", ",", "boolean", "newLine", ")", "{", "writer", ".", "startTag", "(", "TAG_ACCESS_RULES", ",", "indent", ")", ";", "AccessRule", "[", "]", "rules", "=", "getAccessRuleSet", "(", ")", ".", "getAccessRules", "(", ")", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "rules", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "encodeAccessRule", "(", "rules", "[", "i", "]", ",", "writer", ",", "indent", ",", "newLine", ")", ";", "}", "writer", ".", "endTag", "(", "TAG_ACCESS_RULES", ",", "indent", ",", "true", ")", ";", "}", "private", "void", "encodeAccessRule", "(", "AccessRule", "accessRule", ",", "XMLWriter", "writer", ",", "boolean", "indent", ",", "boolean", "newLine", ")", "{", "HashMap", "parameters", "=", "new", "HashMap", "(", ")", ";", "parameters", ".", "put", "(", "TAG_PATTERN", ",", "new", "String", "(", "accessRule", ".", "pattern", ")", ")", ";", "switch", "(", "accessRule", ".", "getProblemId", "(", ")", ")", "{", "case", "IProblem", ".", "ForbiddenReference", ":", "parameters", ".", "put", "(", "TAG_KIND", ",", "TAG_NON_ACCESSIBLE", ")", ";", "break", ";", "case", "IProblem", ".", "DiscouragedReference", ":", "parameters", ".", "put", "(", "TAG_KIND", ",", "TAG_DISCOURAGED", ")", ";", "break", ";", "default", ":", "parameters", ".", "put", "(", "TAG_KIND", ",", "TAG_ACCESSIBLE", ")", ";", "break", ";", "}", "if", "(", "accessRule", ".", "ignoreIfBetter", "(", ")", ")", "parameters", ".", "put", "(", "TAG_IGNORE_IF_BETTER", ",", "\"true\"", ")", ";", "writer", ".", "printTag", "(", "TAG_ACCESS_RULE", ",", "parameters", ",", "indent", ",", "newLine", ",", "true", ")", ";", "}", "private", "void", "encodeUnknownChildren", "(", "XMLWriter", "writer", ",", "boolean", "indent", ",", "boolean", "newLine", ",", "ArrayList", "unknownChildren", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "unknownChildren", ".", "size", "(", ")", ";", "i", "<", "length", ";", "i", "++", ")", "{", "String", "child", "=", "(", "String", ")", "unknownChildren", ".", "get", "(", "i", ")", ";", "writer", ".", "printString", "(", "child", ",", "indent", ",", "false", ")", ";", "}", "}", "public", "static", "IClasspathEntry", "elementDecode", "(", "Element", "element", ",", "IJavaProject", "project", ",", "Map", "unknownElements", ")", "{", "IPath", "projectPath", "=", "project", ".", "getProject", "(", ")", ".", "getFullPath", "(", ")", ";", "NamedNodeMap", "attributes", "=", "element", ".", "getAttributes", "(", ")", ";", "NodeList", "children", "=", "element", ".", "getChildNodes", "(", ")", ";", "boolean", "[", "]", "foundChildren", "=", "new", "boolean", "[", "children", ".", "getLength", "(", ")", "]", ";", "String", "kindAttr", "=", "removeAttribute", "(", "TAG_KIND", ",", "attributes", ")", ";", "String", "pathAttr", "=", "removeAttribute", "(", "TAG_PATH", ",", "attributes", ")", ";", "IPath", "path", "=", "new", "Path", "(", "pathAttr", ")", ";", "int", "kind", "=", "kindFromString", "(", "kindAttr", ")", ";", "if", "(", "kind", "!=", "IClasspathEntry", ".", "CPE_VARIABLE", "&&", "kind", "!=", "IClasspathEntry", ".", "CPE_CONTAINER", "&&", "!", "path", ".", "isAbsolute", "(", ")", ")", "{", "if", "(", "!", "(", "path", ".", "segmentCount", "(", ")", ">", "0", "&&", "path", ".", "segment", "(", "0", ")", ".", "equals", "(", "ClasspathEntry", ".", "DOT_DOT", ")", ")", ")", "{", "path", "=", "projectPath", ".", "append", "(", "path", ")", ";", "}", "}", "IPath", "sourceAttachmentPath", "=", "element", ".", "hasAttribute", "(", "TAG_SOURCEPATH", ")", "?", "new", "Path", "(", "removeAttribute", "(", "TAG_SOURCEPATH", ",", "attributes", ")", ")", ":", "null", ";", "if", "(", "kind", "!=", "IClasspathEntry", ".", "CPE_VARIABLE", "&&", "sourceAttachmentPath", "!=", "null", "&&", "!", "sourceAttachmentPath", ".", "isAbsolute", "(", ")", ")", "{", "sourceAttachmentPath", "=", "projectPath", ".", "append", "(", "sourceAttachmentPath", ")", ";", "}", "IPath", "sourceAttachmentRootPath", "=", "element", ".", "hasAttribute", "(", "TAG_ROOTPATH", ")", "?", "new", "Path", "(", "removeAttribute", "(", "TAG_ROOTPATH", ",", "attributes", ")", ")", ":", "null", ";", "boolean", "isExported", "=", "removeAttribute", "(", "TAG_EXPORTED", ",", "attributes", ")", ".", "equals", "(", "\"true\"", ")", ";", "IPath", "[", "]", "inclusionPatterns", "=", "decodePatterns", "(", "attributes", ",", "TAG_INCLUDING", ")", ";", "if", "(", "inclusionPatterns", "==", "null", ")", "inclusionPatterns", "=", "INCLUDE_ALL", ";", "IPath", "[", "]", "exclusionPatterns", "=", "decodePatterns", "(", "attributes", ",", "TAG_EXCLUDING", ")", ";", "if", "(", "exclusionPatterns", "==", "null", ")", "exclusionPatterns", "=", "EXCLUDE_NONE", ";", "NodeList", "attributeList", "=", "getChildAttributes", "(", "TAG_ACCESS_RULES", ",", "children", ",", "foundChildren", ")", ";", "IAccessRule", "[", "]", "accessRules", "=", "decodeAccessRules", "(", "attributeList", ")", ";", "if", "(", "accessRules", "==", "null", ")", "{", "accessRules", "=", "getAccessRules", "(", "inclusionPatterns", ",", "exclusionPatterns", ")", ";", "}", "boolean", "combineAccessRestrictions", "=", "!", "removeAttribute", "(", "TAG_COMBINE_ACCESS_RULES", ",", "attributes", ")", ".", "equals", "(", "\"false\"", ")", ";", "attributeList", "=", "getChildAttributes", "(", "TAG_ATTRIBUTES", ",", "children", ",", "foundChildren", ")", ";", "IClasspathAttribute", "[", "]", "extraAttributes", "=", "decodeExtraAttributes", "(", "attributeList", ")", ";", "IPath", "outputLocation", "=", "element", ".", "hasAttribute", "(", "TAG_OUTPUT", ")", "?", "projectPath", ".", "append", "(", "removeAttribute", "(", "TAG_OUTPUT", ",", "attributes", ")", ")", ":", "null", ";", "String", "[", "]", "unknownAttributes", "=", "null", ";", "ArrayList", "unknownChildren", "=", "null", ";", "if", "(", "unknownElements", "!=", "null", ")", "{", "int", "unknownAttributeLength", "=", "attributes", ".", "getLength", "(", ")", ";", "if", "(", "unknownAttributeLength", "!=", "0", ")", "{", "unknownAttributes", "=", "new", "String", "[", "unknownAttributeLength", "*", "2", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "unknownAttributeLength", ";", "i", "++", ")", "{", "Node", "attribute", "=", "attributes", ".", "item", "(", "i", ")", ";", "unknownAttributes", "[", "i", "*", "2", "]", "=", "attribute", ".", "getNodeName", "(", ")", ";", "unknownAttributes", "[", "i", "*", "2", "+", "1", "]", "=", "attribute", ".", "getNodeValue", "(", ")", ";", "}", "}", "for", "(", "int", "i", "=", "0", ",", "length", "=", "foundChildren", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "!", "foundChildren", "[", "i", "]", ")", "{", "Node", "node", "=", "children", ".", "item", "(", "i", ")", ";", "if", "(", "node", ".", "getNodeType", "(", ")", "!=", "Node", ".", "ELEMENT_NODE", ")", "continue", ";", "if", "(", "unknownChildren", "==", "null", ")", "unknownChildren", "=", "new", "ArrayList", "(", ")", ";", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", ")", ";", "decodeUnknownNode", "(", "node", ",", "buffer", ",", "project", ")", ";", "unknownChildren", ".", "add", "(", "buffer", ".", "toString", "(", ")", ")", ";", "}", "}", "}", "IClasspathEntry", "entry", "=", "null", ";", "switch", "(", "kind", ")", "{", "case", "IClasspathEntry", ".", "CPE_PROJECT", ":", "entry", "=", "new", "ClasspathEntry", "(", "IPackageFragmentRoot", ".", "K_SOURCE", ",", "IClasspathEntry", ".", "CPE_PROJECT", ",", "path", ",", "ClasspathEntry", ".", "INCLUDE_ALL", ",", "ClasspathEntry", ".", "EXCLUDE_NONE", ",", "null", ",", "null", ",", "null", ",", "isExported", ",", "accessRules", ",", "combineAccessRestrictions", ",", "extraAttributes", ")", ";", "break", ";", "case", "IClasspathEntry", ".", "CPE_LIBRARY", ":", "entry", "=", "JavaCore", ".", "newLibraryEntry", "(", "path", ",", "sourceAttachmentPath", ",", "sourceAttachmentRootPath", ",", "accessRules", ",", "extraAttributes", ",", "isExported", ")", ";", "break", ";", "case", "IClasspathEntry", ".", "CPE_SOURCE", ":", "String", "projSegment", "=", "path", ".", "segment", "(", "0", ")", ";", "if", "(", "projSegment", "!=", "null", "&&", "projSegment", ".", "equals", "(", "project", ".", "getElementName", "(", ")", ")", ")", "{", "entry", "=", "JavaCore", ".", "newSourceEntry", "(", "path", ",", "inclusionPatterns", ",", "exclusionPatterns", ",", "outputLocation", ",", "extraAttributes", ")", ";", "}", "else", "{", "if", "(", "path", ".", "segmentCount", "(", ")", "==", "1", ")", "{", "entry", "=", "JavaCore", ".", "newProjectEntry", "(", "path", ",", "accessRules", ",", "combineAccessRestrictions", ",", "extraAttributes", ",", "isExported", ")", ";", "}", "else", "{", "entry", "=", "JavaCore", ".", "newSourceEntry", "(", "path", ",", "inclusionPatterns", ",", "exclusionPatterns", ",", "outputLocation", ",", "extraAttributes", ")", ";", "}", "}", "break", ";", "case", "IClasspathEntry", ".", "CPE_VARIABLE", ":", "entry", "=", "JavaCore", ".", "newVariableEntry", "(", "path", ",", "sourceAttachmentPath", ",", "sourceAttachmentRootPath", ",", "accessRules", ",", "extraAttributes", ",", "isExported", ")", ";", "break", ";", "case", "IClasspathEntry", ".", "CPE_CONTAINER", ":", "entry", "=", "JavaCore", ".", "newContainerEntry", "(", "path", ",", "accessRules", ",", "extraAttributes", ",", "isExported", ")", ";", "break", ";", "case", "ClasspathEntry", ".", "K_OUTPUT", ":", "if", "(", "!", "path", ".", "isAbsolute", "(", ")", ")", "return", "null", ";", "entry", "=", "new", "ClasspathEntry", "(", "ClasspathEntry", ".", "K_OUTPUT", ",", "IClasspathEntry", ".", "CPE_LIBRARY", ",", "path", ",", "INCLUDE_ALL", ",", "EXCLUDE_NONE", ",", "null", ",", "null", ",", "null", ",", "false", ",", "null", ",", "false", ",", "NO_EXTRA_ATTRIBUTES", ")", ";", "break", ";", "default", ":", "throw", "new", "AssertionFailedException", "(", "Messages", ".", "bind", "(", "Messages", ".", "classpath_unknownKind", ",", "kindAttr", ")", ")", ";", "}", "if", "(", "unknownAttributes", "!=", "null", "||", "unknownChildren", "!=", "null", ")", "{", "UnknownXmlElements", "unknownXmlElements", "=", "new", "UnknownXmlElements", "(", ")", ";", "unknownXmlElements", ".", "attributes", "=", "unknownAttributes", ";", "unknownXmlElements", ".", "children", "=", "unknownChildren", ";", "unknownElements", ".", "put", "(", "path", ",", "unknownXmlElements", ")", ";", "}", "return", "entry", ";", "}", "public", "static", "boolean", "hasDotDot", "(", "IPath", "path", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "path", ".", "segmentCount", "(", ")", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "DOT_DOT", ".", "equals", "(", "path", ".", "segment", "(", "i", ")", ")", ")", "return", "true", ";", "}", "return", "false", ";", "}", "public", "static", "NodeList", "getChildAttributes", "(", "String", "childName", ",", "NodeList", "children", ",", "boolean", "[", "]", "foundChildren", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "foundChildren", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "Node", "node", "=", "children", ".", "item", "(", "i", ")", ";", "if", "(", "childName", ".", "equals", "(", "node", ".", "getNodeName", "(", ")", ")", ")", "{", "foundChildren", "[", "i", "]", "=", "true", ";", "return", "node", ".", "getChildNodes", "(", ")", ";", "}", "}", "return", "null", ";", "}", "private", "static", "String", "removeAttribute", "(", "String", "nodeName", ",", "NamedNodeMap", "nodeMap", ")", "{", "Node", "node", "=", "removeNode", "(", "nodeName", ",", "nodeMap", ")", ";", "if", "(", "node", "==", "null", ")", "return", "\"\"", ";", "return", "node", ".", "getNodeValue", "(", ")", ";", "}", "private", "static", "Node", "removeNode", "(", "String", "nodeName", ",", "NamedNodeMap", "nodeMap", ")", "{", "try", "{", "return", "nodeMap", ".", "removeNamedItem", "(", "nodeName", ")", ";", "}", "catch", "(", "DOMException", "e", ")", "{", "if", "(", "e", ".", "code", "!=", "DOMException", ".", "NOT_FOUND_ERR", ")", "throw", "e", ";", "return", "null", ";", "}", "}", "public", "static", "IPath", "[", "]", "resolvedChainedLibraries", "(", "IPath", "jarPath", ")", "{", "ArrayList", "result", "=", "new", "ArrayList", "(", ")", ";", "resolvedChainedLibraries", "(", "jarPath", ",", "new", "HashSet", "(", ")", ",", "result", ")", ";", "if", "(", "result", ".", "size", "(", ")", "==", "0", ")", "return", "NO_PATHS", ";", "return", "(", "IPath", "[", "]", ")", "result", ".", "toArray", "(", "new", "IPath", "[", "result", ".", "size", "(", ")", "]", ")", ";", "}", "private", "static", "void", "resolvedChainedLibraries", "(", "IPath", "jarPath", ",", "HashSet", "visited", ",", "ArrayList", "result", ")", "{", "if", "(", "visited", ".", "contains", "(", "jarPath", ")", ")", "return", ";", "visited", ".", "add", "(", "jarPath", ")", ";", "JavaModelManager", "manager", "=", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ";", "if", "(", "manager", ".", "isNonChainingJar", "(", "jarPath", ")", ")", "return", ";", "List", "calledFileNames", "=", "getCalledFileNames", "(", "jarPath", ")", ";", "if", "(", "calledFileNames", "==", "null", ")", "{", "manager", ".", "addNonChainingJar", "(", "jarPath", ")", ";", "}", "else", "{", "Iterator", "calledFilesIterator", "=", "calledFileNames", ".", "iterator", "(", ")", ";", "IPath", "directoryPath", "=", "jarPath", ".", "removeLastSegments", "(", "1", ")", ";", "while", "(", "calledFilesIterator", ".", "hasNext", "(", ")", ")", "{", "String", "calledFileName", "=", "(", "String", ")", "calledFilesIterator", ".", "next", "(", ")", ";", "if", "(", "!", "directoryPath", ".", "isValidPath", "(", "calledFileName", ")", ")", "{", "if", "(", "JavaModelManager", ".", "CP_RESOLVE_VERBOSE_FAILURE", ")", "{", "Util", ".", "verbose", "(", "\"\"", "+", "calledFileName", "+", "\"\"", "+", "jarPath", ".", "toOSString", "(", ")", ")", ";", "}", "}", "else", "{", "IPath", "calledJar", "=", "directoryPath", ".", "append", "(", "new", "Path", "(", "calledFileName", ")", ")", ";", "if", "(", "calledJar", ".", "segmentCount", "(", ")", "==", "0", ")", "{", "if", "(", "JavaModelManager", ".", "CP_RESOLVE_VERBOSE_FAILURE", ")", "{", "Util", ".", "verbose", "(", "\"\"", "+", "calledFileName", "+", "\"\"", "+", "jarPath", ".", "toOSString", "(", ")", ")", ";", "}", "continue", ";", "}", "resolvedChainedLibraries", "(", "calledJar", ",", "visited", ",", "result", ")", ";", "result", ".", "add", "(", "calledJar", ")", ";", "}", "}", "}", "}", "private", "static", "List", "getCalledFileNames", "(", "IPath", "jarPath", ")", "{", "Object", "target", "=", "JavaModel", ".", "getTarget", "(", "jarPath", ",", "true", ")", ";", "if", "(", "!", "(", "target", "instanceof", "IFile", "||", "target", "instanceof", "File", ")", ")", "return", "null", ";", "JavaModelManager", "manager", "=", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ";", "ZipFile", "zip", "=", "null", ";", "InputStream", "inputStream", "=", "null", ";", "List", "calledFileNames", "=", "null", ";", "try", "{", "zip", "=", "manager", ".", "getZipFile", "(", "jarPath", ")", ";", "ZipEntry", "manifest", "=", "zip", ".", "getEntry", "(", "\"\"", ")", ";", "if", "(", "manifest", "==", "null", ")", "return", "null", ";", "ManifestAnalyzer", "analyzer", "=", "new", "ManifestAnalyzer", "(", ")", ";", "inputStream", "=", "zip", ".", "getInputStream", "(", "manifest", ")", ";", "boolean", "success", "=", "analyzer", ".", "analyzeManifestContents", "(", "inputStream", ")", ";", "calledFileNames", "=", "analyzer", ".", "getCalledFileNames", "(", ")", ";", "if", "(", "!", "success", "||", "analyzer", ".", "getClasspathSectionsCount", "(", ")", "==", "1", "&&", "calledFileNames", "==", "null", ")", "{", "if", "(", "JavaModelManager", ".", "CP_RESOLVE_VERBOSE_FAILURE", ")", "{", "Util", ".", "verbose", "(", "\"\"", "+", "jarPath", ".", "toOSString", "(", ")", ")", ";", "}", "return", "null", ";", "}", "else", "if", "(", "analyzer", ".", "getClasspathSectionsCount", "(", ")", ">", "1", ")", "{", "if", "(", "JavaModelManager", ".", "CP_RESOLVE_VERBOSE_FAILURE", ")", "{", "Util", ".", "verbose", "(", "\"\"", "+", "jarPath", ".", "toOSString", "(", ")", ")", ";", "}", "return", "null", ";", "}", "}", "catch", "(", "CoreException", "e", ")", "{", "if", "(", "JavaModelManager", ".", "CP_RESOLVE_VERBOSE_FAILURE", ")", "{", "Util", ".", "verbose", "(", "\"\"", "+", "jarPath", ".", "toOSString", "(", ")", ")", ";", "e", ".", "printStackTrace", "(", ")", ";", "}", "}", "catch", "(", "IOException", "e", ")", "{", "if", "(", "JavaModelManager", ".", "CP_RESOLVE_VERBOSE_FAILURE", ")", "{", "Util", ".", "verbose", "(", "\"\"", "+", "jarPath", ".", "toOSString", "(", ")", ")", ";", "e", ".", "printStackTrace", "(", ")", ";", "}", "}", "finally", "{", "if", "(", "inputStream", "!=", "null", ")", "{", "try", "{", "inputStream", ".", "close", "(", ")", ";", "}", "catch", "(", "IOException", "e", ")", "{", "}", "}", "manager", ".", "closeZipFile", "(", "zip", ")", ";", "}", "return", "calledFileNames", ";", "}", "public", "static", "IPath", "resolveDotDot", "(", "IPath", "path", ")", "{", "IPath", "newPath", "=", "null", ";", "IPath", "workspaceLocation", "=", "null", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "path", ".", "segmentCount", "(", ")", ";", "i", "<", "length", ";", "i", "++", ")", "{", "String", "segment", "=", "path", ".", "segment", "(", "i", ")", ";", "if", "(", "DOT_DOT", ".", "equals", "(", "segment", ")", ")", "{", "if", "(", "newPath", "==", "null", ")", "{", "if", "(", "i", "==", "0", ")", "{", "workspaceLocation", "=", "workspaceRoot", ".", "getLocation", "(", ")", ";", "newPath", "=", "workspaceLocation", ";", "}", "else", "{", "newPath", "=", "path", ".", "removeFirstSegments", "(", "i", ")", ";", "}", "}", "else", "{", "if", "(", "newPath", ".", "segmentCount", "(", ")", ">", "0", ")", "{", "newPath", "=", "newPath", ".", "removeLastSegments", "(", "1", ")", ";", "}", "else", "{", "workspaceLocation", "=", "workspaceRoot", ".", "getLocation", "(", ")", ";", "newPath", "=", "workspaceLocation", ";", "}", "}", "}", "else", "if", "(", "newPath", "!=", "null", ")", "{", "if", "(", "newPath", ".", "equals", "(", "workspaceLocation", ")", "&&", "workspaceRoot", ".", "getProject", "(", "segment", ")", ".", "isAccessible", "(", ")", ")", "{", "newPath", "=", "new", "Path", "(", "segment", ")", ".", "makeAbsolute", "(", ")", ";", "}", "else", "{", "newPath", "=", "newPath", ".", "append", "(", "segment", ")", ";", "}", "}", "}", "if", "(", "newPath", "==", "null", ")", "return", "path", ";", "return", "newPath", ";", "}", "private", "static", "void", "encodePatterns", "(", "IPath", "[", "]", "patterns", ",", "String", "tag", ",", "Map", "parameters", ")", "{", "if", "(", "patterns", "!=", "null", "&&", "patterns", ".", "length", ">", "0", ")", "{", "StringBuffer", "rule", "=", "new", "StringBuffer", "(", "10", ")", ";", "for", "(", "int", "i", "=", "0", ",", "max", "=", "patterns", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "i", ">", "0", ")", "rule", ".", "append", "(", "'|'", ")", ";", "rule", ".", "append", "(", "patterns", "[", "i", "]", ")", ";", "}", "parameters", ".", "put", "(", "tag", ",", "String", ".", "valueOf", "(", "rule", ")", ")", ";", "}", "}", "public", "boolean", "equals", "(", "Object", "object", ")", "{", "if", "(", "this", "==", "object", ")", "return", "true", ";", "if", "(", "object", "instanceof", "ClasspathEntry", ")", "{", "ClasspathEntry", "otherEntry", "=", "(", "ClasspathEntry", ")", "object", ";", "if", "(", "this", ".", "contentKind", "!=", "otherEntry", ".", "getContentKind", "(", ")", ")", "return", "false", ";", "if", "(", "this", ".", "entryKind", "!=", "otherEntry", ".", "getEntryKind", "(", ")", ")", "return", "false", ";", "if", "(", "this", ".", "isExported", "!=", "otherEntry", ".", "isExported", "(", ")", ")", "return", "false", ";", "if", "(", "!", "this", ".", "path", ".", "equals", "(", "otherEntry", ".", "getPath", "(", ")", ")", ")", "return", "false", ";", "IPath", "otherPath", "=", "otherEntry", ".", "getSourceAttachmentPath", "(", ")", ";", "if", "(", "this", ".", "sourceAttachmentPath", "==", "null", ")", "{", "if", "(", "otherPath", "!=", "null", ")", "return", "false", ";", "}", "else", "{", "if", "(", "!", "this", ".", "sourceAttachmentPath", ".", "equals", "(", "otherPath", ")", ")", "return", "false", ";", "}", "otherPath", "=", "otherEntry", ".", "getSourceAttachmentRootPath", "(", ")", ";", "if", "(", "this", ".", "sourceAttachmentRootPath", "==", "null", ")", "{", "if", "(", "otherPath", "!=", "null", ")", "return", "false", ";", "}", "else", "{", "if", "(", "!", "this", ".", "sourceAttachmentRootPath", ".", "equals", "(", "otherPath", ")", ")", "return", "false", ";", "}", "if", "(", "!", "equalPatterns", "(", "this", ".", "inclusionPatterns", ",", "otherEntry", ".", "getInclusionPatterns", "(", ")", ")", ")", "return", "false", ";", "if", "(", "!", "equalPatterns", "(", "this", ".", "exclusionPatterns", ",", "otherEntry", ".", "getExclusionPatterns", "(", ")", ")", ")", "return", "false", ";", "AccessRuleSet", "otherRuleSet", "=", "otherEntry", ".", "getAccessRuleSet", "(", ")", ";", "if", "(", "getAccessRuleSet", "(", ")", "!=", "null", ")", "{", "if", "(", "!", "getAccessRuleSet", "(", ")", ".", "equals", "(", "otherRuleSet", ")", ")", "return", "false", ";", "}", "else", "if", "(", "otherRuleSet", "!=", "null", ")", "return", "false", ";", "if", "(", "this", ".", "combineAccessRules", "!=", "otherEntry", ".", "combineAccessRules", "(", ")", ")", "return", "false", ";", "otherPath", "=", "otherEntry", ".", "getOutputLocation", "(", ")", ";", "if", "(", "this", ".", "specificOutputLocation", "==", "null", ")", "{", "if", "(", "otherPath", "!=", "null", ")", "return", "false", ";", "}", "else", "{", "if", "(", "!", "this", ".", "specificOutputLocation", ".", "equals", "(", "otherPath", ")", ")", "return", "false", ";", "}", "if", "(", "!", "equalAttributes", "(", "this", ".", "extraAttributes", ",", "otherEntry", ".", "getExtraAttributes", "(", ")", ")", ")", "return", "false", ";", "return", "true", ";", "}", "else", "{", "return", "false", ";", "}", "}", "private", "static", "boolean", "equalAttributes", "(", "IClasspathAttribute", "[", "]", "firstAttributes", ",", "IClasspathAttribute", "[", "]", "secondAttributes", ")", "{", "if", "(", "firstAttributes", "!=", "secondAttributes", ")", "{", "if", "(", "firstAttributes", "==", "null", ")", "return", "false", ";", "int", "length", "=", "firstAttributes", ".", "length", ";", "if", "(", "secondAttributes", "==", "null", "||", "secondAttributes", ".", "length", "!=", "length", ")", "return", "false", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "!", "firstAttributes", "[", "i", "]", ".", "equals", "(", "secondAttributes", "[", "i", "]", ")", ")", "return", "false", ";", "}", "}", "return", "true", ";", "}", "private", "static", "boolean", "equalPatterns", "(", "IPath", "[", "]", "firstPatterns", ",", "IPath", "[", "]", "secondPatterns", ")", "{", "if", "(", "firstPatterns", "!=", "secondPatterns", ")", "{", "if", "(", "firstPatterns", "==", "null", ")", "return", "false", ";", "int", "length", "=", "firstPatterns", ".", "length", ";", "if", "(", "secondPatterns", "==", "null", "||", "secondPatterns", ".", "length", "!=", "length", ")", "return", "false", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "!", "firstPatterns", "[", "i", "]", ".", "toString", "(", ")", ".", "equals", "(", "secondPatterns", "[", "i", "]", ".", "toString", "(", ")", ")", ")", "return", "false", ";", "}", "}", "return", "true", ";", "}", "public", "IAccessRule", "[", "]", "getAccessRules", "(", ")", "{", "if", "(", "this", ".", "accessRuleSet", "==", "null", ")", "return", "NO_ACCESS_RULES", ";", "AccessRule", "[", "]", "rules", "=", "this", ".", "accessRuleSet", ".", "getAccessRules", "(", ")", ";", "int", "length", "=", "rules", ".", "length", ";", "if", "(", "length", "==", "0", ")", "return", "NO_ACCESS_RULES", ";", "IAccessRule", "[", "]", "result", "=", "new", "IAccessRule", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "rules", ",", "0", ",", "result", ",", "0", ",", "length", ")", ";", "return", "result", ";", "}", "public", "AccessRuleSet", "getAccessRuleSet", "(", ")", "{", "return", "this", ".", "accessRuleSet", ";", "}", "public", "int", "getContentKind", "(", ")", "{", "return", "this", ".", "contentKind", ";", "}", "public", "int", "getEntryKind", "(", ")", "{", "return", "this", ".", "entryKind", ";", "}", "public", "IPath", "[", "]", "getExclusionPatterns", "(", ")", "{", "return", "this", ".", "exclusionPatterns", ";", "}", "public", "IClasspathAttribute", "[", "]", "getExtraAttributes", "(", ")", "{", "return", "this", ".", "extraAttributes", ";", "}", "public", "IPath", "[", "]", "getInclusionPatterns", "(", ")", "{", "return", "this", ".", "inclusionPatterns", ";", "}", "public", "IPath", "getOutputLocation", "(", ")", "{", "return", "this", ".", "specificOutputLocation", ";", "}", "public", "IPath", "getPath", "(", ")", "{", "return", "this", ".", "path", ";", "}", "public", "IPath", "getSourceAttachmentPath", "(", ")", "{", "return", "this", ".", "sourceAttachmentPath", ";", "}", "public", "IPath", "getSourceAttachmentRootPath", "(", ")", "{", "return", "this", ".", "sourceAttachmentRootPath", ";", "}", "public", "IClasspathEntry", "getReferencingEntry", "(", ")", "{", "return", "this", ".", "referencingEntry", ";", "}", "public", "int", "hashCode", "(", ")", "{", "return", "this", ".", "path", ".", "hashCode", "(", ")", ";", "}", "public", "boolean", "isExported", "(", ")", "{", "return", "this", ".", "isExported", ";", "}", "public", "boolean", "isOptional", "(", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "this", ".", "extraAttributes", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "IClasspathAttribute", "attribute", "=", "this", ".", "extraAttributes", "[", "i", "]", ";", "if", "(", "IClasspathAttribute", ".", "OPTIONAL", ".", "equals", "(", "attribute", ".", "getName", "(", ")", ")", "&&", "\"true\"", ".", "equals", "(", "attribute", ".", "getValue", "(", ")", ")", ")", "return", "true", ";", "}", "return", "false", ";", "}", "static", "int", "kindFromString", "(", "String", "kindStr", ")", "{", "if", "(", "kindStr", ".", "equalsIgnoreCase", "(", "\"prj\"", ")", ")", "return", "IClasspathEntry", ".", "CPE_PROJECT", ";", "if", "(", "kindStr", ".", "equalsIgnoreCase", "(", "\"var\"", ")", ")", "return", "IClasspathEntry", ".", "CPE_VARIABLE", ";", "if", "(", "kindStr", ".", "equalsIgnoreCase", "(", "\"con\"", ")", ")", "return", "IClasspathEntry", ".", "CPE_CONTAINER", ";", "if", "(", "kindStr", ".", "equalsIgnoreCase", "(", "\"src\"", ")", ")", "return", "IClasspathEntry", ".", "CPE_SOURCE", ";", "if", "(", "kindStr", ".", "equalsIgnoreCase", "(", "\"lib\"", ")", ")", "return", "IClasspathEntry", ".", "CPE_LIBRARY", ";", "if", "(", "kindStr", ".", "equalsIgnoreCase", "(", "\"output\"", ")", ")", "return", "ClasspathEntry", ".", "K_OUTPUT", ";", "return", "-", "1", ";", "}", "static", "String", "kindToString", "(", "int", "kind", ")", "{", "switch", "(", "kind", ")", "{", "case", "IClasspathEntry", ".", "CPE_PROJECT", ":", "return", "\"src\"", ";", "case", "IClasspathEntry", ".", "CPE_SOURCE", ":", "return", "\"src\"", ";", "case", "IClasspathEntry", ".", "CPE_LIBRARY", ":", "return", "\"lib\"", ";", "case", "IClasspathEntry", ".", "CPE_VARIABLE", ":", "return", "\"var\"", ";", "case", "IClasspathEntry", ".", "CPE_CONTAINER", ":", "return", "\"con\"", ";", "case", "ClasspathEntry", ".", "K_OUTPUT", ":", "return", "\"output\"", ";", "default", ":", "return", "\"unknown\"", ";", "}", "}", "public", "static", "IAccessRule", "[", "]", "getAccessRules", "(", "IPath", "[", "]", "accessibleFiles", ",", "IPath", "[", "]", "nonAccessibleFiles", ")", "{", "int", "accessibleFilesLength", "=", "accessibleFiles", "==", "null", "?", "0", ":", "accessibleFiles", ".", "length", ";", "int", "nonAccessibleFilesLength", "=", "nonAccessibleFiles", "==", "null", "?", "0", ":", "nonAccessibleFiles", ".", "length", ";", "int", "length", "=", "accessibleFilesLength", "+", "nonAccessibleFilesLength", ";", "if", "(", "length", "==", "0", ")", "return", "null", ";", "IAccessRule", "[", "]", "accessRules", "=", "new", "IAccessRule", "[", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "accessibleFilesLength", ";", "i", "++", ")", "{", "accessRules", "[", "i", "]", "=", "JavaCore", ".", "newAccessRule", "(", "accessibleFiles", "[", "i", "]", ",", "IAccessRule", ".", "K_ACCESSIBLE", ")", ";", "}", "for", "(", "int", "i", "=", "0", ";", "i", "<", "nonAccessibleFilesLength", ";", "i", "++", ")", "{", "accessRules", "[", "accessibleFilesLength", "+", "i", "]", "=", "JavaCore", ".", "newAccessRule", "(", "nonAccessibleFiles", "[", "i", "]", ",", "IAccessRule", ".", "K_NON_ACCESSIBLE", ")", ";", "}", "return", "accessRules", ";", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", ")", ";", "Object", "target", "=", "JavaModel", ".", "getTarget", "(", "getPath", "(", ")", ",", "true", ")", ";", "if", "(", "target", "instanceof", "File", ")", "buffer", ".", "append", "(", "getPath", "(", ")", ".", "toOSString", "(", ")", ")", ";", "else", "buffer", ".", "append", "(", "String", ".", "valueOf", "(", "getPath", "(", ")", ")", ")", ";", "buffer", ".", "append", "(", "'['", ")", ";", "switch", "(", "getEntryKind", "(", ")", ")", "{", "case", "IClasspathEntry", ".", "CPE_LIBRARY", ":", "buffer", ".", "append", "(", "\"CPE_LIBRARY\"", ")", ";", "break", ";", "case", "IClasspathEntry", ".", "CPE_PROJECT", ":", "buffer", ".", "append", "(", "\"CPE_PROJECT\"", ")", ";", "break", ";", "case", "IClasspathEntry", ".", "CPE_SOURCE", ":", "buffer", ".", "append", "(", "\"CPE_SOURCE\"", ")", ";", "break", ";", "case", "IClasspathEntry", ".", "CPE_VARIABLE", ":", "buffer", ".", "append", "(", "\"CPE_VARIABLE\"", ")", ";", "break", ";", "case", "IClasspathEntry", ".", "CPE_CONTAINER", ":", "buffer", ".", "append", "(", "\"\"", ")", ";", "break", ";", "}", "buffer", ".", "append", "(", "\"][\"", ")", ";", "switch", "(", "getContentKind", "(", ")", ")", "{", "case", "IPackageFragmentRoot", ".", "K_BINARY", ":", "buffer", ".", "append", "(", "\"K_BINARY\"", ")", ";", "break", ";", "case", "IPackageFragmentRoot", ".", "K_SOURCE", ":", "buffer", ".", "append", "(", "\"K_SOURCE\"", ")", ";", "break", ";", "case", "ClasspathEntry", ".", "K_OUTPUT", ":", "buffer", ".", "append", "(", "\"K_OUTPUT\"", ")", ";", "break", ";", "}", "buffer", ".", "append", "(", "']'", ")", ";", "if", "(", "getSourceAttachmentPath", "(", ")", "!=", "null", ")", "{", "buffer", ".", "append", "(", "\"[sourcePath:\"", ")", ";", "buffer", ".", "append", "(", "getSourceAttachmentPath", "(", ")", ")", ";", "buffer", ".", "append", "(", "']'", ")", ";", "}", "if", "(", "getSourceAttachmentRootPath", "(", ")", "!=", "null", ")", "{", "buffer", ".", "append", "(", "\"[rootPath:\"", ")", ";", "buffer", ".", "append", "(", "getSourceAttachmentRootPath", "(", ")", ")", ";", "buffer", ".", "append", "(", "']'", ")", ";", "}", "buffer", ".", "append", "(", "\"[isExported:\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "isExported", ")", ";", "buffer", ".", "append", "(", "']'", ")", ";", "IPath", "[", "]", "patterns", "=", "this", ".", "inclusionPatterns", ";", "int", "length", ";", "if", "(", "(", "length", "=", "patterns", "==", "null", "?", "0", ":", "patterns", ".", "length", ")", ">", "0", ")", "{", "buffer", ".", "append", "(", "\"[including:\"", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "buffer", ".", "append", "(", "patterns", "[", "i", "]", ")", ";", "if", "(", "i", "!=", "length", "-", "1", ")", "{", "buffer", ".", "append", "(", "'|'", ")", ";", "}", "}", "buffer", ".", "append", "(", "']'", ")", ";", "}", "patterns", "=", "this", ".", "exclusionPatterns", ";", "if", "(", "(", "length", "=", "patterns", "==", "null", "?", "0", ":", "patterns", ".", "length", ")", ">", "0", ")", "{", "buffer", ".", "append", "(", "\"[excluding:\"", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "buffer", ".", "append", "(", "patterns", "[", "i", "]", ")", ";", "if", "(", "i", "!=", "length", "-", "1", ")", "{", "buffer", ".", "append", "(", "'|'", ")", ";", "}", "}", "buffer", ".", "append", "(", "']'", ")", ";", "}", "if", "(", "this", ".", "accessRuleSet", "!=", "null", ")", "{", "buffer", ".", "append", "(", "'['", ")", ";", "buffer", ".", "append", "(", "this", ".", "accessRuleSet", ".", "toString", "(", "false", ")", ")", ";", "buffer", ".", "append", "(", "']'", ")", ";", "}", "if", "(", "this", ".", "entryKind", "==", "CPE_PROJECT", ")", "{", "buffer", ".", "append", "(", "\"\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "combineAccessRules", ")", ";", "buffer", ".", "append", "(", "']'", ")", ";", "}", "if", "(", "getOutputLocation", "(", ")", "!=", "null", ")", "{", "buffer", ".", "append", "(", "\"[output:\"", ")", ";", "buffer", ".", "append", "(", "getOutputLocation", "(", ")", ")", ";", "buffer", ".", "append", "(", "']'", ")", ";", "}", "if", "(", "(", "length", "=", "this", ".", "extraAttributes", "==", "null", "?", "0", ":", "this", ".", "extraAttributes", ".", "length", ")", ">", "0", ")", "{", "buffer", ".", "append", "(", "\"[attributes:\"", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "buffer", ".", "append", "(", "this", ".", "extraAttributes", "[", "i", "]", ")", ";", "if", "(", "i", "!=", "length", "-", "1", ")", "{", "buffer", ".", "append", "(", "','", ")", ";", "}", "}", "buffer", ".", "append", "(", "']'", ")", ";", "}", "return", "buffer", ".", "toString", "(", ")", ";", "}", "public", "ClasspathEntry", "resolvedDotDot", "(", ")", "{", "IPath", "resolvedPath", "=", "resolveDotDot", "(", "this", ".", "path", ")", ";", "if", "(", "resolvedPath", "==", "this", ".", "path", ")", "return", "this", ";", "return", "new", "ClasspathEntry", "(", "getContentKind", "(", ")", ",", "getEntryKind", "(", ")", ",", "resolvedPath", ",", "this", ".", "inclusionPatterns", ",", "this", ".", "exclusionPatterns", ",", "getSourceAttachmentPath", "(", ")", ",", "getSourceAttachmentRootPath", "(", ")", ",", "getOutputLocation", "(", ")", ",", "this", ".", "getReferencingEntry", "(", ")", ",", "this", ".", "isExported", ",", "getAccessRules", "(", ")", ",", "this", ".", "combineAccessRules", ",", "this", ".", "extraAttributes", ")", ";", "}", "public", "ClasspathEntry", "[", "]", "resolvedChainedLibraries", "(", ")", "{", "IPath", "[", "]", "paths", "=", "resolvedChainedLibraries", "(", "getPath", "(", ")", ")", ";", "int", "length", "=", "paths", ".", "length", ";", "if", "(", "length", "==", "0", ")", "return", "NO_ENTRIES", ";", "ClasspathEntry", "[", "]", "result", "=", "new", "ClasspathEntry", "[", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "result", "[", "i", "]", "=", "new", "ClasspathEntry", "(", "getContentKind", "(", ")", ",", "getEntryKind", "(", ")", ",", "paths", "[", "i", "]", ",", "this", ".", "inclusionPatterns", ",", "this", ".", "exclusionPatterns", ",", "null", ",", "null", ",", "getOutputLocation", "(", ")", ",", "this", ",", "this", ".", "isExported", ",", "getAccessRules", "(", ")", ",", "this", ".", "combineAccessRules", ",", "NO_EXTRA_ATTRIBUTES", ")", ";", "}", "return", "result", ";", "}", "public", "String", "rootID", "(", ")", "{", "if", "(", "this", ".", "rootID", "==", "null", ")", "{", "switch", "(", "this", ".", "entryKind", ")", "{", "case", "IClasspathEntry", ".", "CPE_LIBRARY", ":", "this", ".", "rootID", "=", "\"[LIB]\"", "+", "this", ".", "path", ";", "break", ";", "case", "IClasspathEntry", ".", "CPE_PROJECT", ":", "this", ".", "rootID", "=", "\"[PRJ]\"", "+", "this", ".", "path", ";", "break", ";", "case", "IClasspathEntry", ".", "CPE_SOURCE", ":", "this", ".", "rootID", "=", "\"[SRC]\"", "+", "this", ".", "path", ";", "break", ";", "case", "IClasspathEntry", ".", "CPE_VARIABLE", ":", "this", ".", "rootID", "=", "\"[VAR]\"", "+", "this", ".", "path", ";", "break", ";", "case", "IClasspathEntry", ".", "CPE_CONTAINER", ":", "this", ".", "rootID", "=", "\"[CON]\"", "+", "this", ".", "path", ";", "break", ";", "default", ":", "this", ".", "rootID", "=", "\"\"", ";", "break", ";", "}", "}", "return", "this", ".", "rootID", ";", "}", "public", "IClasspathEntry", "getResolvedEntry", "(", ")", "{", "return", "JavaCore", ".", "getResolvedClasspathEntry", "(", "this", ")", ";", "}", "public", "static", "IJavaModelStatus", "validateClasspath", "(", "IJavaProject", "javaProject", ",", "IClasspathEntry", "[", "]", "rawClasspath", ",", "IPath", "projectOutputLocation", ")", "{", "IProject", "project", "=", "javaProject", ".", "getProject", "(", ")", ";", "IPath", "projectPath", "=", "project", ".", "getFullPath", "(", ")", ";", "String", "projectName", "=", "javaProject", ".", "getElementName", "(", ")", ";", "if", "(", "projectOutputLocation", "==", "null", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "NULL_PATH", ")", ";", "}", "if", "(", "projectOutputLocation", ".", "isAbsolute", "(", ")", ")", "{", "if", "(", "!", "projectPath", ".", "isPrefixOf", "(", "projectOutputLocation", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "PATH_OUTSIDE_PROJECT", ",", "javaProject", ",", "projectOutputLocation", ".", "toString", "(", ")", ")", ";", "}", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "RELATIVE_PATH", ",", "projectOutputLocation", ")", ";", "}", "boolean", "hasSource", "=", "false", ";", "boolean", "hasLibFolder", "=", "false", ";", "if", "(", "rawClasspath", "==", "null", ")", "return", "JavaModelStatus", ".", "VERIFIED_OK", ";", "int", "rawLength", "=", "rawClasspath", ".", "length", ";", "HashSet", "pathes", "=", "new", "HashSet", "(", "rawLength", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "rawLength", ";", "i", "++", ")", "{", "IPath", "entryPath", "=", "rawClasspath", "[", "i", "]", ".", "getPath", "(", ")", ";", "if", "(", "!", "pathes", ".", "add", "(", "entryPath", ")", ")", "{", "String", "entryPathMsg", "=", "projectName", ".", "equals", "(", "entryPath", ".", "segment", "(", "0", ")", ")", "?", "entryPath", ".", "removeFirstSegments", "(", "1", ")", ".", "toString", "(", ")", ":", "entryPath", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ";", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "NAME_COLLISION", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_duplicateEntryPath", ",", "new", "String", "[", "]", "{", "entryPathMsg", ",", "projectName", "}", ")", ")", ";", "}", "}", "IClasspathEntry", "[", "]", "classpath", ";", "try", "{", "classpath", "=", "(", "(", "JavaProject", ")", "javaProject", ")", ".", "resolveClasspath", "(", "rawClasspath", ",", "false", ",", "false", ")", ".", "resolvedClasspath", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "return", "e", ".", "getJavaModelStatus", "(", ")", ";", "}", "int", "length", "=", "classpath", ".", "length", ";", "int", "outputCount", "=", "1", ";", "IPath", "[", "]", "outputLocations", "=", "new", "IPath", "[", "length", "+", "1", "]", ";", "boolean", "[", "]", "allowNestingInOutputLocations", "=", "new", "boolean", "[", "length", "+", "1", "]", ";", "outputLocations", "[", "0", "]", "=", "projectOutputLocation", ";", "IPath", "potentialNestedOutput", "=", "null", ";", "int", "sourceEntryCount", "=", "0", ";", "boolean", "disableExclusionPatterns", "=", "JavaCore", ".", "DISABLED", ".", "equals", "(", "javaProject", ".", "getOption", "(", "JavaCore", ".", "CORE_ENABLE_CLASSPATH_EXCLUSION_PATTERNS", ",", "true", ")", ")", ";", "boolean", "disableCustomOutputLocations", "=", "JavaCore", ".", "DISABLED", ".", "equals", "(", "javaProject", ".", "getOption", "(", "JavaCore", ".", "CORE_ENABLE_CLASSPATH_MULTIPLE_OUTPUT_LOCATIONS", ",", "true", ")", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "IClasspathEntry", "resolvedEntry", "=", "classpath", "[", "i", "]", ";", "if", "(", "disableExclusionPatterns", "&&", "(", "(", "resolvedEntry", ".", "getInclusionPatterns", "(", ")", "!=", "null", "&&", "resolvedEntry", ".", "getInclusionPatterns", "(", ")", ".", "length", ">", "0", ")", "||", "(", "resolvedEntry", ".", "getExclusionPatterns", "(", ")", "!=", "null", "&&", "resolvedEntry", ".", "getExclusionPatterns", "(", ")", ".", "length", ">", "0", ")", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "DISABLED_CP_EXCLUSION_PATTERNS", ",", "javaProject", ",", "resolvedEntry", ".", "getPath", "(", ")", ")", ";", "}", "switch", "(", "resolvedEntry", ".", "getEntryKind", "(", ")", ")", "{", "case", "IClasspathEntry", ".", "CPE_SOURCE", ":", "sourceEntryCount", "++", ";", "IPath", "customOutput", ";", "if", "(", "(", "customOutput", "=", "resolvedEntry", ".", "getOutputLocation", "(", ")", ")", "!=", "null", ")", "{", "if", "(", "disableCustomOutputLocations", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "DISABLED_CP_MULTIPLE_OUTPUT_LOCATIONS", ",", "javaProject", ",", "resolvedEntry", ".", "getPath", "(", ")", ")", ";", "}", "if", "(", "customOutput", ".", "isAbsolute", "(", ")", ")", "{", "if", "(", "!", "javaProject", ".", "getPath", "(", ")", ".", "isPrefixOf", "(", "customOutput", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "PATH_OUTSIDE_PROJECT", ",", "javaProject", ",", "customOutput", ".", "toString", "(", ")", ")", ";", "}", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "RELATIVE_PATH", ",", "customOutput", ")", ";", "}", "if", "(", "Util", ".", "indexOfMatchingPath", "(", "customOutput", ",", "outputLocations", ",", "outputCount", ")", "!=", "-", "1", ")", "{", "continue", ";", "}", "outputLocations", "[", "outputCount", "++", "]", "=", "customOutput", ";", "}", "}", "}", "for", "(", "int", "i", "=", "1", ";", "i", "<", "outputCount", ";", "i", "++", ")", "{", "IPath", "customOutput", "=", "outputLocations", "[", "i", "]", ";", "int", "index", ";", "if", "(", "(", "index", "=", "Util", ".", "indexOfEnclosingPath", "(", "customOutput", ",", "outputLocations", ",", "outputCount", ")", ")", "!=", "-", "1", "&&", "index", "!=", "i", ")", "{", "if", "(", "index", "==", "0", ")", "{", "if", "(", "potentialNestedOutput", "==", "null", ")", "potentialNestedOutput", "=", "customOutput", ";", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_cannotNestOutputInOutput", ",", "new", "String", "[", "]", "{", "customOutput", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ",", "outputLocations", "[", "index", "]", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", "}", ")", ")", ";", "}", "}", "}", "if", "(", "sourceEntryCount", "<=", "outputCount", "-", "1", ")", "{", "allowNestingInOutputLocations", "[", "0", "]", "=", "true", ";", "}", "else", "if", "(", "potentialNestedOutput", "!=", "null", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_cannotNestOutputInOutput", ",", "new", "String", "[", "]", "{", "potentialNestedOutput", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ",", "outputLocations", "[", "0", "]", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", "}", ")", ")", ";", "}", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "IClasspathEntry", "resolvedEntry", "=", "classpath", "[", "i", "]", ";", "IPath", "path", "=", "resolvedEntry", ".", "getPath", "(", ")", ";", "int", "index", ";", "switch", "(", "resolvedEntry", ".", "getEntryKind", "(", ")", ")", "{", "case", "IClasspathEntry", ".", "CPE_SOURCE", ":", "hasSource", "=", "true", ";", "if", "(", "(", "index", "=", "Util", ".", "indexOfMatchingPath", "(", "path", ",", "outputLocations", ",", "outputCount", ")", ")", "!=", "-", "1", ")", "{", "allowNestingInOutputLocations", "[", "index", "]", "=", "true", ";", "}", "break", ";", "case", "IClasspathEntry", ".", "CPE_LIBRARY", ":", "Object", "target", "=", "JavaModel", ".", "getTarget", "(", "path", ",", "false", ")", ";", "hasLibFolder", "|=", "target", "instanceof", "IContainer", ";", "if", "(", "(", "index", "=", "Util", ".", "indexOfMatchingPath", "(", "path", ",", "outputLocations", ",", "outputCount", ")", ")", "!=", "-", "1", ")", "{", "allowNestingInOutputLocations", "[", "index", "]", "=", "true", ";", "}", "break", ";", "}", "}", "if", "(", "!", "hasSource", "&&", "!", "hasLibFolder", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "outputCount", ";", "i", "++", ")", "allowNestingInOutputLocations", "[", "i", "]", "=", "true", ";", "}", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "IClasspathEntry", "entry", "=", "classpath", "[", "i", "]", ";", "if", "(", "entry", "==", "null", ")", "continue", ";", "IPath", "entryPath", "=", "entry", ".", "getPath", "(", ")", ";", "int", "kind", "=", "entry", ".", "getEntryKind", "(", ")", ";", "if", "(", "entryPath", ".", "equals", "(", "projectPath", ")", ")", "{", "if", "(", "kind", "==", "IClasspathEntry", ".", "CPE_PROJECT", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_PATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_cannotReferToItself", ",", "entryPath", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ")", ")", ";", "}", "continue", ";", "}", "if", "(", "kind", "==", "IClasspathEntry", ".", "CPE_SOURCE", "||", "(", "kind", "==", "IClasspathEntry", ".", "CPE_LIBRARY", "&&", "(", "JavaModel", ".", "getTarget", "(", "entryPath", ",", "false", ")", "instanceof", "IContainer", ")", ")", ")", "{", "for", "(", "int", "j", "=", "0", ";", "j", "<", "classpath", ".", "length", ";", "j", "++", ")", "{", "IClasspathEntry", "otherEntry", "=", "classpath", "[", "j", "]", ";", "if", "(", "otherEntry", "==", "null", ")", "continue", ";", "int", "otherKind", "=", "otherEntry", ".", "getEntryKind", "(", ")", ";", "IPath", "otherPath", "=", "otherEntry", ".", "getPath", "(", ")", ";", "if", "(", "entry", "!=", "otherEntry", "&&", "(", "otherKind", "==", "IClasspathEntry", ".", "CPE_SOURCE", "||", "(", "otherKind", "==", "IClasspathEntry", ".", "CPE_LIBRARY", "&&", "(", "JavaModel", ".", "getTarget", "(", "otherPath", ",", "false", ")", "instanceof", "IContainer", ")", ")", ")", ")", "{", "char", "[", "]", "[", "]", "inclusionPatterns", ",", "exclusionPatterns", ";", "if", "(", "otherPath", ".", "isPrefixOf", "(", "entryPath", ")", "&&", "!", "otherPath", ".", "equals", "(", "entryPath", ")", "&&", "!", "Util", ".", "isExcluded", "(", "entryPath", ".", "append", "(", "\"*\"", ")", ",", "inclusionPatterns", "=", "(", "(", "ClasspathEntry", ")", "otherEntry", ")", ".", "fullInclusionPatternChars", "(", ")", ",", "exclusionPatterns", "=", "(", "(", "ClasspathEntry", ")", "otherEntry", ")", ".", "fullExclusionPatternChars", "(", ")", ",", "false", ")", ")", "{", "String", "exclusionPattern", "=", "entryPath", ".", "removeFirstSegments", "(", "otherPath", ".", "segmentCount", "(", ")", ")", ".", "segment", "(", "0", ")", ";", "if", "(", "Util", ".", "isExcluded", "(", "entryPath", ",", "inclusionPatterns", ",", "exclusionPatterns", ",", "false", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_mustEndWithSlash", ",", "new", "String", "[", "]", "{", "exclusionPattern", ",", "entryPath", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", "}", ")", ")", ";", "}", "else", "{", "if", "(", "otherKind", "==", "IClasspathEntry", ".", "CPE_SOURCE", ")", "{", "exclusionPattern", "+=", "'/'", ";", "if", "(", "!", "disableExclusionPatterns", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_cannotNestEntryInEntry", ",", "new", "String", "[", "]", "{", "entryPath", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ",", "otherEntry", ".", "getPath", "(", ")", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ",", "exclusionPattern", "}", ")", ")", ";", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_cannotNestEntryInEntryNoExclusion", ",", "new", "String", "[", "]", "{", "entryPath", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ",", "otherEntry", ".", "getPath", "(", ")", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ",", "exclusionPattern", "}", ")", ")", ";", "}", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_cannotNestEntryInLibrary", ",", "new", "String", "[", "]", "{", "entryPath", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ",", "otherEntry", ".", "getPath", "(", ")", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", "}", ")", ")", ";", "}", "}", "}", "}", "}", "}", "char", "[", "]", "[", "]", "inclusionPatterns", "=", "(", "(", "ClasspathEntry", ")", "entry", ")", ".", "fullInclusionPatternChars", "(", ")", ";", "char", "[", "]", "[", "]", "exclusionPatterns", "=", "(", "(", "ClasspathEntry", ")", "entry", ")", ".", "fullExclusionPatternChars", "(", ")", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "outputCount", ";", "j", "++", ")", "{", "IPath", "currentOutput", "=", "outputLocations", "[", "j", "]", ";", "if", "(", "entryPath", ".", "equals", "(", "currentOutput", ")", ")", "continue", ";", "if", "(", "entryPath", ".", "isPrefixOf", "(", "currentOutput", ")", ")", "{", "if", "(", "kind", "!=", "IClasspathEntry", ".", "CPE_SOURCE", "||", "!", "Util", ".", "isExcluded", "(", "currentOutput", ",", "inclusionPatterns", ",", "exclusionPatterns", ",", "true", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_cannotNestOutputInEntry", ",", "new", "String", "[", "]", "{", "currentOutput", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ",", "entryPath", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", "}", ")", ")", ";", "}", "}", "}", "for", "(", "int", "j", "=", "0", ";", "j", "<", "outputCount", ";", "j", "++", ")", "{", "if", "(", "allowNestingInOutputLocations", "[", "j", "]", ")", "continue", ";", "IPath", "currentOutput", "=", "outputLocations", "[", "j", "]", ";", "if", "(", "currentOutput", ".", "isPrefixOf", "(", "entryPath", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_cannotNestEntryInOutput", ",", "new", "String", "[", "]", "{", "entryPath", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ",", "currentOutput", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", "}", ")", ")", ";", "}", "}", "}", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "IClasspathEntry", "entry", "=", "classpath", "[", "i", "]", ";", "if", "(", "entry", "==", "null", ")", "continue", ";", "IPath", "entryPath", "=", "entry", ".", "getPath", "(", ")", ";", "int", "kind", "=", "entry", ".", "getEntryKind", "(", ")", ";", "boolean", "isProjectRelative", "=", "projectName", ".", "equals", "(", "entryPath", ".", "segment", "(", "0", ")", ")", ";", "String", "entryPathMsg", "=", "isProjectRelative", "?", "entryPath", ".", "removeFirstSegments", "(", "1", ")", ".", "toString", "(", ")", ":", "entryPath", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ";", "if", "(", "kind", "==", "IClasspathEntry", ".", "CPE_SOURCE", ")", "{", "IPath", "output", "=", "entry", ".", "getOutputLocation", "(", ")", ";", "if", "(", "output", "==", "null", ")", "continue", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "length", ";", "j", "++", ")", "{", "IClasspathEntry", "otherEntry", "=", "classpath", "[", "j", "]", ";", "if", "(", "otherEntry", "==", "entry", ")", "continue", ";", "boolean", "opStartsWithProject", "=", "projectName", ".", "equals", "(", "otherEntry", ".", "getPath", "(", ")", ".", "segment", "(", "0", ")", ")", ";", "String", "otherPathMsg", "=", "opStartsWithProject", "?", "otherEntry", ".", "getPath", "(", ")", ".", "removeFirstSegments", "(", "1", ")", ".", "toString", "(", ")", ":", "otherEntry", ".", "getPath", "(", ")", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ";", "switch", "(", "otherEntry", ".", "getEntryKind", "(", ")", ")", "{", "case", "IClasspathEntry", ".", "CPE_SOURCE", ":", "if", "(", "otherEntry", ".", "getPath", "(", ")", ".", "equals", "(", "output", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_cannotUseDistinctSourceFolderAsOutput", ",", "new", "String", "[", "]", "{", "entryPathMsg", ",", "otherPathMsg", ",", "projectName", "}", ")", ")", ";", "}", "break", ";", "case", "IClasspathEntry", ".", "CPE_LIBRARY", ":", "if", "(", "otherEntry", ".", "getPath", "(", ")", ".", "equals", "(", "output", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_cannotUseLibraryAsOutput", ",", "new", "String", "[", "]", "{", "entryPathMsg", ",", "otherPathMsg", ",", "projectName", "}", ")", ")", ";", "}", "}", "}", "}", "}", "return", "JavaModelStatus", ".", "VERIFIED_OK", ";", "}", "public", "static", "IJavaModelStatus", "validateClasspathEntry", "(", "IJavaProject", "project", ",", "IClasspathEntry", "entry", ",", "boolean", "checkSourceAttachment", ",", "boolean", "referredByContainer", ")", "{", "IJavaModelStatus", "status", "=", "validateClasspathEntry", "(", "project", ",", "entry", ",", "null", ",", "checkSourceAttachment", ",", "referredByContainer", ")", ";", "int", "statusCode", "=", "status", ".", "getCode", "(", ")", ";", "if", "(", "(", "statusCode", "==", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", "||", "statusCode", "==", "IJavaModelStatusConstants", ".", "CP_CONTAINER_PATH_UNBOUND", "||", "statusCode", "==", "IJavaModelStatusConstants", ".", "CP_VARIABLE_PATH_UNBOUND", "||", "statusCode", "==", "IJavaModelStatusConstants", ".", "INVALID_PATH", ")", "&&", "(", "(", "ClasspathEntry", ")", "entry", ")", ".", "isOptional", "(", ")", ")", "return", "JavaModelStatus", ".", "VERIFIED_OK", ";", "return", "status", ";", "}", "private", "static", "IJavaModelStatus", "validateClasspathEntry", "(", "IJavaProject", "project", ",", "IClasspathEntry", "entry", ",", "IClasspathContainer", "entryContainer", ",", "boolean", "checkSourceAttachment", ",", "boolean", "referredByContainer", ")", "{", "IPath", "path", "=", "entry", ".", "getPath", "(", ")", ";", "String", "projectName", "=", "project", ".", "getElementName", "(", ")", ";", "String", "entryPathMsg", "=", "projectName", ".", "equals", "(", "path", ".", "segment", "(", "0", ")", ")", "?", "path", ".", "removeFirstSegments", "(", "1", ")", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ":", "path", ".", "toString", "(", ")", ";", "switch", "(", "entry", ".", "getEntryKind", "(", ")", ")", "{", "case", "IClasspathEntry", ".", "CPE_CONTAINER", ":", "if", "(", "path", ".", "segmentCount", "(", ")", ">=", "1", ")", "{", "try", "{", "IJavaModelStatus", "status", "=", "null", ";", "IClasspathAttribute", "[", "]", "extraAttributes", "=", "entry", ".", "getExtraAttributes", "(", ")", ";", "if", "(", "extraAttributes", "!=", "null", ")", "{", "int", "length", "=", "extraAttributes", ".", "length", ";", "HashSet", "set", "=", "new", "HashSet", "(", "length", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "String", "attName", "=", "extraAttributes", "[", "i", "]", ".", "getName", "(", ")", ";", "if", "(", "!", "set", ".", "add", "(", "attName", ")", ")", "{", "status", "=", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "NAME_COLLISION", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_duplicateEntryExtraAttribute", ",", "new", "String", "[", "]", "{", "attName", ",", "entryPathMsg", ",", "projectName", "}", ")", ")", ";", "break", ";", "}", "}", "}", "IClasspathContainer", "container", "=", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "getClasspathContainer", "(", "path", ",", "project", ")", ";", "if", "(", "container", "==", "null", ")", "{", "if", "(", "status", "!=", "null", ")", "return", "status", ";", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "CP_CONTAINER_PATH_UNBOUND", ",", "project", ",", "path", ")", ";", "}", "else", "if", "(", "container", "==", "JavaModelManager", ".", "CONTAINER_INITIALIZATION_IN_PROGRESS", ")", "{", "return", "JavaModelStatus", ".", "VERIFIED_OK", ";", "}", "IClasspathEntry", "[", "]", "containerEntries", "=", "container", ".", "getClasspathEntries", "(", ")", ";", "if", "(", "containerEntries", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "containerEntries", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "IClasspathEntry", "containerEntry", "=", "containerEntries", "[", "i", "]", ";", "int", "kind", "=", "containerEntry", "==", "null", "?", "0", ":", "containerEntry", ".", "getEntryKind", "(", ")", ";", "if", "(", "containerEntry", "==", "null", "||", "kind", "==", "IClasspathEntry", ".", "CPE_SOURCE", "||", "kind", "==", "IClasspathEntry", ".", "CPE_VARIABLE", "||", "kind", "==", "IClasspathEntry", ".", "CPE_CONTAINER", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CP_CONTAINER_ENTRY", ",", "project", ",", "path", ")", ";", "}", "IJavaModelStatus", "containerEntryStatus", "=", "validateClasspathEntry", "(", "project", ",", "containerEntry", ",", "container", ",", "checkSourceAttachment", ",", "true", ")", ";", "if", "(", "!", "containerEntryStatus", ".", "isOK", "(", ")", ")", "{", "return", "containerEntryStatus", ";", "}", "}", "}", "}", "catch", "(", "JavaModelException", "e", ")", "{", "return", "new", "JavaModelStatus", "(", "e", ")", ";", "}", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_illegalContainerPath", ",", "new", "String", "[", "]", "{", "entryPathMsg", ",", "projectName", "}", ")", ")", ";", "}", "break", ";", "case", "IClasspathEntry", ".", "CPE_VARIABLE", ":", "if", "(", "path", ".", "segmentCount", "(", ")", ">=", "1", ")", "{", "try", "{", "entry", "=", "JavaCore", ".", "getResolvedClasspathEntry", "(", "entry", ")", ";", "}", "catch", "(", "AssertionFailedException", "e", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_PATH", ",", "e", ".", "getMessage", "(", ")", ")", ";", "}", "if", "(", "entry", "==", "null", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "CP_VARIABLE_PATH_UNBOUND", ",", "project", ",", "path", ")", ";", "}", "IJavaModelStatus", "status", "=", "validateClasspathEntry", "(", "project", ",", "entry", ",", "null", ",", "checkSourceAttachment", ",", "false", ")", ";", "if", "(", "!", "status", ".", "isOK", "(", ")", ")", "return", "status", ";", "String", "variableName", "=", "path", ".", "segment", "(", "0", ")", ";", "String", "deprecatedMessage", "=", "JavaCore", ".", "getClasspathVariableDeprecationMessage", "(", "variableName", ")", ";", "if", "(", "deprecatedMessage", "!=", "null", ")", "{", "return", "new", "JavaModelStatus", "(", "IStatus", ".", "WARNING", ",", "IJavaModelStatusConstants", ".", "DEPRECATED_VARIABLE", ",", "project", ",", "path", ",", "deprecatedMessage", ")", ";", "}", "return", "status", ";", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_illegalVariablePath", ",", "new", "String", "[", "]", "{", "entryPathMsg", ",", "projectName", "}", ")", ")", ";", "}", "case", "IClasspathEntry", ".", "CPE_LIBRARY", ":", "path", "=", "ClasspathEntry", ".", "resolveDotDot", "(", "path", ")", ";", "String", "containerInfo", "=", "null", ";", "if", "(", "entryContainer", "!=", "null", ")", "{", "if", "(", "entryContainer", "instanceof", "UserLibraryClasspathContainer", ")", "{", "containerInfo", "=", "Messages", ".", "bind", "(", "Messages", ".", "classpath_userLibraryInfo", ",", "new", "String", "[", "]", "{", "entryContainer", ".", "getDescription", "(", ")", "}", ")", ";", "}", "else", "{", "containerInfo", "=", "Messages", ".", "bind", "(", "Messages", ".", "classpath_containerInfo", ",", "new", "String", "[", "]", "{", "entryContainer", ".", "getDescription", "(", ")", "}", ")", ";", "}", "}", "IJavaModelStatus", "status", "=", "validateLibraryEntry", "(", "path", ",", "project", ",", "containerInfo", ",", "checkSourceAttachment", "?", "entry", ".", "getSourceAttachmentPath", "(", ")", ":", "null", ",", "entryPathMsg", ")", ";", "if", "(", "status", ".", "getCode", "(", ")", "==", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", "&&", "(", "(", "ClasspathEntry", ")", "entry", ")", ".", "isOptional", "(", ")", ")", "status", "=", "JavaModelStatus", ".", "VERIFIED_OK", ";", "if", "(", "!", "status", ".", "isOK", "(", ")", ")", "return", "status", ";", "break", ";", "case", "IClasspathEntry", ".", "CPE_PROJECT", ":", "if", "(", "path", ".", "isAbsolute", "(", ")", "&&", "path", ".", "segmentCount", "(", ")", "==", "1", ")", "{", "IProject", "prereqProjectRsc", "=", "workspaceRoot", ".", "getProject", "(", "path", ".", "segment", "(", "0", ")", ")", ";", "IJavaProject", "prereqProject", "=", "JavaCore", ".", "create", "(", "prereqProjectRsc", ")", ";", "try", "{", "if", "(", "!", "prereqProjectRsc", ".", "exists", "(", ")", "||", "!", "prereqProjectRsc", ".", "hasNature", "(", "JavaCore", ".", "NATURE_ID", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_unboundProject", ",", "new", "String", "[", "]", "{", "path", ".", "segment", "(", "0", ")", ",", "projectName", "}", ")", ")", ";", "}", "if", "(", "!", "prereqProjectRsc", ".", "isOpen", "(", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_closedProject", ",", "new", "String", "[", "]", "{", "path", ".", "segment", "(", "0", ")", "}", ")", ")", ";", "}", "if", "(", "!", "JavaCore", ".", "IGNORE", ".", "equals", "(", "project", ".", "getOption", "(", "JavaCore", ".", "CORE_INCOMPATIBLE_JDK_LEVEL", ",", "true", ")", ")", ")", "{", "long", "projectTargetJDK", "=", "CompilerOptions", ".", "versionToJdkLevel", "(", "project", ".", "getOption", "(", "JavaCore", ".", "COMPILER_CODEGEN_TARGET_PLATFORM", ",", "true", ")", ")", ";", "long", "prereqProjectTargetJDK", "=", "CompilerOptions", ".", "versionToJdkLevel", "(", "prereqProject", ".", "getOption", "(", "JavaCore", ".", "COMPILER_CODEGEN_TARGET_PLATFORM", ",", "true", ")", ")", ";", "if", "(", "prereqProjectTargetJDK", ">", "projectTargetJDK", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INCOMPATIBLE_JDK_LEVEL", ",", "project", ",", "path", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_incompatibleLibraryJDKLevel", ",", "new", "String", "[", "]", "{", "project", ".", "getElementName", "(", ")", ",", "CompilerOptions", ".", "versionFromJdkLevel", "(", "projectTargetJDK", ")", ",", "path", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ",", "CompilerOptions", ".", "versionFromJdkLevel", "(", "prereqProjectTargetJDK", ")", "}", ")", ")", ";", "}", "}", "}", "catch", "(", "CoreException", "e", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_unboundProject", ",", "new", "String", "[", "]", "{", "path", ".", "segment", "(", "0", ")", ",", "projectName", "}", ")", ")", ";", "}", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_illegalProjectPath", ",", "new", "String", "[", "]", "{", "path", ".", "toString", "(", ")", ",", "projectName", "}", ")", ")", ";", "}", "break", ";", "case", "IClasspathEntry", ".", "CPE_SOURCE", ":", "if", "(", "(", "(", "entry", ".", "getInclusionPatterns", "(", ")", "!=", "null", "&&", "entry", ".", "getInclusionPatterns", "(", ")", ".", "length", ">", "0", ")", "||", "(", "entry", ".", "getExclusionPatterns", "(", ")", "!=", "null", "&&", "entry", ".", "getExclusionPatterns", "(", ")", ".", "length", ">", "0", ")", ")", "&&", "JavaCore", ".", "DISABLED", ".", "equals", "(", "project", ".", "getOption", "(", "JavaCore", ".", "CORE_ENABLE_CLASSPATH_EXCLUSION_PATTERNS", ",", "true", ")", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "DISABLED_CP_EXCLUSION_PATTERNS", ",", "project", ",", "path", ")", ";", "}", "if", "(", "entry", ".", "getOutputLocation", "(", ")", "!=", "null", "&&", "JavaCore", ".", "DISABLED", ".", "equals", "(", "project", ".", "getOption", "(", "JavaCore", ".", "CORE_ENABLE_CLASSPATH_MULTIPLE_OUTPUT_LOCATIONS", ",", "true", ")", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "DISABLED_CP_MULTIPLE_OUTPUT_LOCATIONS", ",", "project", ",", "path", ")", ";", "}", "if", "(", "path", ".", "isAbsolute", "(", ")", "&&", "!", "path", ".", "isEmpty", "(", ")", ")", "{", "IPath", "projectPath", "=", "project", ".", "getProject", "(", ")", ".", "getFullPath", "(", ")", ";", "if", "(", "!", "projectPath", ".", "isPrefixOf", "(", "path", ")", "||", "JavaModel", ".", "getTarget", "(", "path", ",", "true", ")", "==", "null", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_unboundSourceFolder", ",", "new", "String", "[", "]", "{", "entryPathMsg", ",", "projectName", "}", ")", ")", ";", "}", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_illegalSourceFolderPath", ",", "new", "String", "[", "]", "{", "entryPathMsg", ",", "projectName", "}", ")", ")", ";", "}", "break", ";", "}", "IClasspathAttribute", "[", "]", "extraAttributes", "=", "entry", ".", "getExtraAttributes", "(", ")", ";", "if", "(", "extraAttributes", "!=", "null", ")", "{", "int", "length", "=", "extraAttributes", ".", "length", ";", "HashSet", "set", "=", "new", "HashSet", "(", "length", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "String", "attName", "=", "extraAttributes", "[", "i", "]", ".", "getName", "(", ")", ";", "if", "(", "!", "set", ".", "add", "(", "attName", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "NAME_COLLISION", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_duplicateEntryExtraAttribute", ",", "new", "String", "[", "]", "{", "attName", ",", "entryPathMsg", ",", "projectName", "}", ")", ")", ";", "}", "}", "}", "return", "JavaModelStatus", ".", "VERIFIED_OK", ";", "}", "private", "static", "IJavaModelStatus", "validateLibraryEntry", "(", "IPath", "path", ",", "IJavaProject", "project", ",", "String", "container", ",", "IPath", "sourceAttachment", ",", "String", "entryPathMsg", ")", "{", "if", "(", "path", ".", "isAbsolute", "(", ")", "&&", "!", "path", ".", "isEmpty", "(", ")", ")", "{", "Object", "target", "=", "JavaModel", ".", "getTarget", "(", "path", ",", "true", ")", ";", "if", "(", "target", "==", "null", ")", "{", "IPath", "workspaceLocation", "=", "workspaceRoot", ".", "getLocation", "(", ")", ";", "if", "(", "workspaceLocation", ".", "isPrefixOf", "(", "path", ")", ")", "{", "target", "=", "JavaModel", ".", "getTarget", "(", "path", ".", "makeRelativeTo", "(", "workspaceLocation", ")", ".", "makeAbsolute", "(", ")", ",", "true", ")", ";", "}", "}", "if", "(", "target", "!=", "null", "&&", "!", "JavaCore", ".", "IGNORE", ".", "equals", "(", "project", ".", "getOption", "(", "JavaCore", ".", "CORE_INCOMPATIBLE_JDK_LEVEL", ",", "true", ")", ")", ")", "{", "long", "projectTargetJDK", "=", "CompilerOptions", ".", "versionToJdkLevel", "(", "project", ".", "getOption", "(", "JavaCore", ".", "COMPILER_CODEGEN_TARGET_PLATFORM", ",", "true", ")", ")", ";", "long", "libraryJDK", "=", "Util", ".", "getJdkLevel", "(", "target", ")", ";", "if", "(", "libraryJDK", "!=", "0", "&&", "libraryJDK", ">", "projectTargetJDK", ")", "{", "if", "(", "container", "!=", "null", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INCOMPATIBLE_JDK_LEVEL", ",", "project", ",", "path", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_incompatibleLibraryJDKLevelInContainer", ",", "new", "String", "[", "]", "{", "project", ".", "getElementName", "(", ")", ",", "CompilerOptions", ".", "versionFromJdkLevel", "(", "projectTargetJDK", ")", ",", "path", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ",", "container", ",", "CompilerOptions", ".", "versionFromJdkLevel", "(", "libraryJDK", ")", "}", ")", ")", ";", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INCOMPATIBLE_JDK_LEVEL", ",", "project", ",", "path", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_incompatibleLibraryJDKLevel", ",", "new", "String", "[", "]", "{", "project", ".", "getElementName", "(", ")", ",", "CompilerOptions", ".", "versionFromJdkLevel", "(", "projectTargetJDK", ")", ",", "path", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ",", "CompilerOptions", ".", "versionFromJdkLevel", "(", "libraryJDK", ")", "}", ")", ")", ";", "}", "}", "}", "if", "(", "target", "instanceof", "IResource", ")", "{", "IResource", "resolvedResource", "=", "(", "IResource", ")", "target", ";", "switch", "(", "resolvedResource", ".", "getType", "(", ")", ")", "{", "case", "IResource", ".", "FILE", ":", "if", "(", "sourceAttachment", "!=", "null", "&&", "!", "sourceAttachment", ".", "isEmpty", "(", ")", "&&", "JavaModel", ".", "getTarget", "(", "sourceAttachment", ",", "true", ")", "==", "null", ")", "{", "if", "(", "container", "!=", "null", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_unboundSourceAttachmentInContainedLibrary", ",", "new", "String", "[", "]", "{", "sourceAttachment", ".", "toString", "(", ")", ",", "path", ".", "toString", "(", ")", ",", "container", "}", ")", ")", ";", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_unboundSourceAttachment", ",", "new", "String", "[", "]", "{", "sourceAttachment", ".", "toString", "(", ")", ",", "path", ".", "toString", "(", ")", ",", "project", ".", "getElementName", "(", ")", "}", ")", ")", ";", "}", "}", "break", ";", "case", "IResource", ".", "FOLDER", ":", "if", "(", "sourceAttachment", "!=", "null", "&&", "!", "sourceAttachment", ".", "isEmpty", "(", ")", "&&", "JavaModel", ".", "getTarget", "(", "sourceAttachment", ",", "true", ")", "==", "null", ")", "{", "if", "(", "container", "!=", "null", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_unboundSourceAttachmentInContainedLibrary", ",", "new", "String", "[", "]", "{", "sourceAttachment", ".", "toString", "(", ")", ",", "path", ".", "toString", "(", ")", ",", "container", "}", ")", ")", ";", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_unboundSourceAttachment", ",", "new", "String", "[", "]", "{", "sourceAttachment", ".", "toString", "(", ")", ",", "path", ".", "toString", "(", ")", ",", "project", ".", "getElementName", "(", ")", "}", ")", ")", ";", "}", "}", "}", "}", "else", "if", "(", "target", "instanceof", "File", ")", "{", "File", "file", "=", "JavaModel", ".", "getFile", "(", "target", ")", ";", "if", "(", "file", "==", "null", ")", "{", "if", "(", "container", "!=", "null", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_illegalExternalFolderInContainer", ",", "new", "String", "[", "]", "{", "path", ".", "toOSString", "(", ")", ",", "container", "}", ")", ")", ";", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_illegalExternalFolder", ",", "new", "String", "[", "]", "{", "path", ".", "toOSString", "(", ")", ",", "project", ".", "getElementName", "(", ")", "}", ")", ")", ";", "}", "}", "else", "if", "(", "sourceAttachment", "!=", "null", "&&", "!", "sourceAttachment", ".", "isEmpty", "(", ")", "&&", "JavaModel", ".", "getTarget", "(", "sourceAttachment", ",", "true", ")", "==", "null", ")", "{", "if", "(", "container", "!=", "null", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_unboundSourceAttachmentInContainedLibrary", ",", "new", "String", "[", "]", "{", "sourceAttachment", ".", "toString", "(", ")", ",", "path", ".", "toOSString", "(", ")", ",", "container", "}", ")", ")", ";", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_unboundSourceAttachment", ",", "new", "String", "[", "]", "{", "sourceAttachment", ".", "toString", "(", ")", ",", "path", ".", "toOSString", "(", ")", ",", "project", ".", "getElementName", "(", ")", "}", ")", ")", ";", "}", "}", "}", "else", "{", "boolean", "isExternal", "=", "path", ".", "getDevice", "(", ")", "!=", "null", "||", "!", "ResourcesPlugin", ".", "getWorkspace", "(", ")", ".", "getRoot", "(", ")", ".", "getProject", "(", "path", ".", "segment", "(", "0", ")", ")", ".", "exists", "(", ")", ";", "if", "(", "isExternal", ")", "{", "if", "(", "container", "!=", "null", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_unboundLibraryInContainer", ",", "new", "String", "[", "]", "{", "path", ".", "toOSString", "(", ")", ",", "container", "}", ")", ")", ";", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_unboundLibrary", ",", "new", "String", "[", "]", "{", "path", ".", "toOSString", "(", ")", ",", "project", ".", "getElementName", "(", ")", "}", ")", ")", ";", "}", "}", "else", "{", "if", "(", "entryPathMsg", "==", "null", ")", "entryPathMsg", "=", "project", ".", "getElementName", "(", ")", ".", "equals", "(", "path", ".", "segment", "(", "0", ")", ")", "?", "path", ".", "removeFirstSegments", "(", "1", ")", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ":", "path", ".", "toString", "(", ")", ";", "if", "(", "container", "!=", "null", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_unboundLibraryInContainer", ",", "new", "String", "[", "]", "{", "entryPathMsg", ",", "container", "}", ")", ")", ";", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_unboundLibrary", ",", "new", "String", "[", "]", "{", "entryPathMsg", ",", "project", ".", "getElementName", "(", ")", "}", ")", ")", ";", "}", "}", "}", "}", "else", "{", "if", "(", "entryPathMsg", "==", "null", ")", "entryPathMsg", "=", "project", ".", "getElementName", "(", ")", ".", "equals", "(", "path", ".", "segment", "(", "0", ")", ")", "?", "path", ".", "removeFirstSegments", "(", "1", ")", ".", "makeRelative", "(", ")", ".", "toString", "(", ")", ":", "path", ".", "toString", "(", ")", ";", "if", "(", "container", "!=", "null", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_illegalLibraryPathInContainer", ",", "new", "String", "[", "]", "{", "entryPathMsg", ",", "container", "}", ")", ")", ";", "}", "else", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_CLASSPATH", ",", "Messages", ".", "bind", "(", "Messages", ".", "classpath_illegalLibraryPath", ",", "new", "String", "[", "]", "{", "entryPathMsg", ",", "project", ".", "getElementName", "(", ")", "}", ")", ")", ";", "}", "}", "return", "JavaModelStatus", ".", "VERIFIED_OK", ";", "}", "}", "</s>" ]
5,525
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IPath", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Path", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IAccessRule", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "IProblem", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "AccessRule", ";", "public", "class", "ClasspathAccessRule", "extends", "AccessRule", "implements", "IAccessRule", "{", "public", "ClasspathAccessRule", "(", "IPath", "pattern", ",", "int", "kind", ")", "{", "this", "(", "pattern", ".", "toString", "(", ")", ".", "toCharArray", "(", ")", ",", "toProblemId", "(", "kind", ")", ")", ";", "}", "public", "ClasspathAccessRule", "(", "char", "[", "]", "pattern", ",", "int", "problemId", ")", "{", "super", "(", "pattern", ",", "problemId", ")", ";", "}", "private", "static", "int", "toProblemId", "(", "int", "kind", ")", "{", "boolean", "ignoreIfBetter", "=", "(", "kind", "&", "IAccessRule", ".", "IGNORE_IF_BETTER", ")", "!=", "0", ";", "switch", "(", "kind", "&", "~", "IAccessRule", ".", "IGNORE_IF_BETTER", ")", "{", "case", "K_NON_ACCESSIBLE", ":", "return", "ignoreIfBetter", "?", "IProblem", ".", "ForbiddenReference", "|", "AccessRule", ".", "IgnoreIfBetter", ":", "IProblem", ".", "ForbiddenReference", ";", "case", "K_DISCOURAGED", ":", "return", "ignoreIfBetter", "?", "IProblem", ".", "DiscouragedReference", "|", "AccessRule", ".", "IgnoreIfBetter", ":", "IProblem", ".", "DiscouragedReference", ";", "default", ":", "return", "ignoreIfBetter", "?", "AccessRule", ".", "IgnoreIfBetter", ":", "0", ";", "}", "}", "public", "IPath", "getPattern", "(", ")", "{", "return", "new", "Path", "(", "new", "String", "(", "this", ".", "pattern", ")", ")", ";", "}", "public", "int", "getKind", "(", ")", "{", "switch", "(", "getProblemId", "(", ")", ")", "{", "case", "IProblem", ".", "ForbiddenReference", ":", "return", "K_NON_ACCESSIBLE", ";", "case", "IProblem", ".", "DiscouragedReference", ":", "return", "K_DISCOURAGED", ";", "default", ":", "return", "K_ACCESSIBLE", ";", "}", "}", "}", "</s>" ]
5,526
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatus", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatusConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaProject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IRegion", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IType", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ITypeHierarchy", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "search", ".", "IJavaSearchScope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "hierarchy", ".", "RegionBasedTypeHierarchy", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "hierarchy", ".", "TypeHierarchy", ";", "public", "class", "CreateTypeHierarchyOperation", "extends", "JavaModelOperation", "{", "protected", "TypeHierarchy", "typeHierarchy", ";", "public", "CreateTypeHierarchyOperation", "(", "IRegion", "region", ",", "ICompilationUnit", "[", "]", "workingCopies", ",", "IType", "element", ",", "boolean", "computeSubtypes", ")", "{", "super", "(", "element", ")", ";", "this", ".", "typeHierarchy", "=", "new", "RegionBasedTypeHierarchy", "(", "region", ",", "workingCopies", ",", "element", ",", "computeSubtypes", ")", ";", "}", "public", "CreateTypeHierarchyOperation", "(", "IType", "element", ",", "ICompilationUnit", "[", "]", "workingCopies", ",", "IJavaSearchScope", "scope", ",", "boolean", "computeSubtypes", ")", "{", "super", "(", "element", ")", ";", "ICompilationUnit", "[", "]", "copies", ";", "if", "(", "workingCopies", "!=", "null", ")", "{", "int", "length", "=", "workingCopies", ".", "length", ";", "copies", "=", "new", "ICompilationUnit", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "workingCopies", ",", "0", ",", "copies", ",", "0", ",", "length", ")", ";", "}", "else", "{", "copies", "=", "null", ";", "}", "this", ".", "typeHierarchy", "=", "new", "TypeHierarchy", "(", "element", ",", "copies", ",", "scope", ",", "computeSubtypes", ")", ";", "}", "public", "CreateTypeHierarchyOperation", "(", "IType", "element", ",", "ICompilationUnit", "[", "]", "workingCopies", ",", "IJavaProject", "project", ",", "boolean", "computeSubtypes", ")", "{", "super", "(", "element", ")", ";", "ICompilationUnit", "[", "]", "copies", ";", "if", "(", "workingCopies", "!=", "null", ")", "{", "int", "length", "=", "workingCopies", ".", "length", ";", "copies", "=", "new", "ICompilationUnit", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "workingCopies", ",", "0", ",", "copies", ",", "0", ",", "length", ")", ";", "}", "else", "{", "copies", "=", "null", ";", "}", "this", ".", "typeHierarchy", "=", "new", "TypeHierarchy", "(", "element", ",", "copies", ",", "project", ",", "computeSubtypes", ")", ";", "}", "protected", "void", "executeOperation", "(", ")", "throws", "JavaModelException", "{", "this", ".", "typeHierarchy", ".", "refresh", "(", "this", ")", ";", "}", "public", "ITypeHierarchy", "getResult", "(", ")", "{", "return", "this", ".", "typeHierarchy", ";", "}", "public", "boolean", "isReadOnly", "(", ")", "{", "return", "true", ";", "}", "public", "IJavaModelStatus", "verify", "(", ")", "{", "IJavaElement", "elementToProcess", "=", "getElementToProcess", "(", ")", ";", "if", "(", "elementToProcess", "==", "null", "&&", "!", "(", "this", ".", "typeHierarchy", "instanceof", "RegionBasedTypeHierarchy", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "NO_ELEMENTS_TO_PROCESS", ")", ";", "}", "if", "(", "elementToProcess", "!=", "null", "&&", "!", "elementToProcess", ".", "exists", "(", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "ELEMENT_DOES_NOT_EXIST", ",", "elementToProcess", ")", ";", "}", "IJavaProject", "project", "=", "this", ".", "typeHierarchy", ".", "javaProject", "(", ")", ";", "if", "(", "project", "!=", "null", "&&", "!", "project", ".", "exists", "(", ")", ")", "{", "return", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "ELEMENT_DOES_NOT_EXIST", ",", "project", ")", ";", "}", "return", "JavaModelStatus", ".", "VERIFIED_OK", ";", "}", "}", "</s>" ]
5,527
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "util", ".", "zip", ".", "ZipFile", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "CoreException", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IPath", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Path", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "PlatformObject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJarEntryResource", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IPackageFragment", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IPackageFragmentRoot", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "abstract", "class", "JarEntryResource", "extends", "PlatformObject", "implements", "IJarEntryResource", "{", "protected", "Object", "parent", ";", "protected", "String", "simpleName", ";", "public", "JarEntryResource", "(", "String", "simpleName", ")", "{", "this", ".", "simpleName", "=", "simpleName", ";", "}", "public", "abstract", "JarEntryResource", "clone", "(", "Object", "newParent", ")", ";", "public", "boolean", "equals", "(", "Object", "obj", ")", "{", "if", "(", "!", "(", "obj", "instanceof", "JarEntryResource", ")", ")", "return", "false", ";", "JarEntryResource", "other", "=", "(", "JarEntryResource", ")", "obj", ";", "return", "this", ".", "parent", ".", "equals", "(", "other", ".", "parent", ")", "&&", "this", ".", "simpleName", ".", "equals", "(", "other", ".", "simpleName", ")", ";", "}", "protected", "String", "getEntryName", "(", ")", "{", "String", "parentEntryName", ";", "if", "(", "this", ".", "parent", "instanceof", "IPackageFragment", ")", "{", "String", "elementName", "=", "(", "(", "IPackageFragment", ")", "this", ".", "parent", ")", ".", "getElementName", "(", ")", ";", "parentEntryName", "=", "elementName", ".", "length", "(", ")", "==", "0", "?", "\"\"", ":", "elementName", ".", "replace", "(", "'.'", ",", "'/'", ")", "+", "'/'", ";", "}", "else", "if", "(", "this", ".", "parent", "instanceof", "IPackageFragmentRoot", ")", "{", "parentEntryName", "=", "\"\"", ";", "}", "else", "{", "parentEntryName", "=", "(", "(", "JarEntryDirectory", ")", "this", ".", "parent", ")", ".", "getEntryName", "(", ")", "+", "'/'", ";", "}", "return", "parentEntryName", "+", "this", ".", "simpleName", ";", "}", "public", "IPath", "getFullPath", "(", ")", "{", "return", "new", "Path", "(", "getEntryName", "(", ")", ")", ".", "makeAbsolute", "(", ")", ";", "}", "public", "String", "getName", "(", ")", "{", "return", "this", ".", "simpleName", ";", "}", "public", "Object", "getParent", "(", ")", "{", "return", "this", ".", "parent", ";", "}", "public", "IPackageFragmentRoot", "getPackageFragmentRoot", "(", ")", "{", "if", "(", "this", ".", "parent", "instanceof", "IPackageFragment", ")", "{", "return", "(", "IPackageFragmentRoot", ")", "(", "(", "IPackageFragment", ")", "this", ".", "parent", ")", ".", "getParent", "(", ")", ";", "}", "else", "if", "(", "this", ".", "parent", "instanceof", "IPackageFragmentRoot", ")", "{", "return", "(", "IPackageFragmentRoot", ")", "this", ".", "parent", ";", "}", "else", "{", "return", "(", "(", "JarEntryDirectory", ")", "this", ".", "parent", ")", ".", "getPackageFragmentRoot", "(", ")", ";", "}", "}", "protected", "ZipFile", "getZipFile", "(", ")", "throws", "CoreException", "{", "if", "(", "this", ".", "parent", "instanceof", "IPackageFragment", ")", "{", "JarPackageFragmentRoot", "root", "=", "(", "JarPackageFragmentRoot", ")", "(", "(", "IPackageFragment", ")", "this", ".", "parent", ")", ".", "getParent", "(", ")", ";", "return", "root", ".", "getJar", "(", ")", ";", "}", "else", "if", "(", "this", ".", "parent", "instanceof", "JarPackageFragmentRoot", ")", "{", "return", "(", "(", "JarPackageFragmentRoot", ")", "this", ".", "parent", ")", ".", "getJar", "(", ")", ";", "}", "else", "return", "(", "(", "JarEntryDirectory", ")", "this", ".", "parent", ")", ".", "getZipFile", "(", ")", ";", "}", "public", "int", "hashCode", "(", ")", "{", "return", "Util", ".", "combineHashCodes", "(", "this", ".", "simpleName", ".", "hashCode", "(", ")", ",", "this", ".", "parent", ".", "hashCode", "(", ")", ")", ";", "}", "public", "boolean", "isReadOnly", "(", ")", "{", "return", "true", ";", "}", "public", "void", "setParent", "(", "Object", "parent", ")", "{", "this", ".", "parent", "=", "parent", ";", "}", "}", "</s>" ]
5,528
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "public", "class", "SourceMethodInfo", "extends", "SourceMethodElementInfo", "{", "protected", "char", "[", "]", "returnType", ";", "public", "boolean", "isAnnotationMethod", "(", ")", "{", "return", "false", ";", "}", "public", "boolean", "isConstructor", "(", ")", "{", "return", "false", ";", "}", "public", "char", "[", "]", "getReturnTypeName", "(", ")", "{", "return", "this", ".", "returnType", ";", "}", "protected", "void", "setReturnType", "(", "char", "[", "]", "type", ")", "{", "this", ".", "returnType", "=", "type", ";", "}", "}", "</s>" ]
5,529
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "io", ".", "BufferedInputStream", ";", "import", "java", ".", "io", ".", "BufferedOutputStream", ";", "import", "java", ".", "io", ".", "DataInputStream", ";", "import", "java", ".", "io", ".", "DataOutputStream", ";", "import", "java", ".", "io", ".", "File", ";", "import", "java", ".", "io", ".", "FileInputStream", ";", "import", "java", ".", "io", ".", "FileOutputStream", ";", "import", "java", ".", "io", ".", "IOException", ";", "import", "java", ".", "util", ".", "*", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "*", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "JavaModelManager", ".", "PerProjectInfo", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "DeltaProcessingState", "implements", "IResourceChangeListener", "{", "public", "IElementChangedListener", "[", "]", "elementChangedListeners", "=", "new", "IElementChangedListener", "[", "5", "]", ";", "public", "int", "[", "]", "elementChangedListenerMasks", "=", "new", "int", "[", "5", "]", ";", "public", "int", "elementChangedListenerCount", "=", "0", ";", "public", "IResourceChangeListener", "[", "]", "preResourceChangeListeners", "=", "new", "IResourceChangeListener", "[", "1", "]", ";", "public", "int", "[", "]", "preResourceChangeEventMasks", "=", "new", "int", "[", "1", "]", ";", "public", "int", "preResourceChangeListenerCount", "=", "0", ";", "private", "ThreadLocal", "deltaProcessors", "=", "new", "ThreadLocal", "(", ")", ";", "public", "void", "doNotUse", "(", ")", "{", "this", ".", "deltaProcessors", ".", "set", "(", "null", ")", ";", "}", "public", "HashMap", "roots", "=", "new", "HashMap", "(", ")", ";", "public", "HashMap", "otherRoots", "=", "new", "HashMap", "(", ")", ";", "public", "HashMap", "oldRoots", "=", "new", "HashMap", "(", ")", ";", "public", "HashMap", "oldOtherRoots", "=", "new", "HashMap", "(", ")", ";", "public", "HashMap", "sourceAttachments", "=", "new", "HashMap", "(", ")", ";", "public", "HashMap", "projectDependencies", "=", "new", "HashMap", "(", ")", ";", "public", "boolean", "rootsAreStale", "=", "true", ";", "private", "Set", "initializingThreads", "=", "Collections", ".", "synchronizedSet", "(", "new", "HashSet", "(", ")", ")", ";", "public", "Hashtable", "externalTimeStamps", ";", "private", "HashMap", "classpathChanges", "=", "new", "HashMap", "(", ")", ";", "private", "HashMap", "classpathValidations", "=", "new", "HashMap", "(", ")", ";", "private", "HashMap", "projectReferenceChanges", "=", "new", "HashMap", "(", ")", ";", "private", "HashMap", "externalFolderChanges", "=", "new", "HashMap", "(", ")", ";", "private", "HashSet", "javaProjectNamesCache", ";", "private", "HashSet", "externalElementsToRefresh", ";", "public", "synchronized", "void", "addElementChangedListener", "(", "IElementChangedListener", "listener", ",", "int", "eventMask", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "elementChangedListenerCount", ";", "i", "++", ")", "{", "if", "(", "this", ".", "elementChangedListeners", "[", "i", "]", "==", "listener", ")", "{", "int", "cloneLength", "=", "this", ".", "elementChangedListenerMasks", ".", "length", ";", "System", ".", "arraycopy", "(", "this", ".", "elementChangedListenerMasks", ",", "0", ",", "this", ".", "elementChangedListenerMasks", "=", "new", "int", "[", "cloneLength", "]", ",", "0", ",", "cloneLength", ")", ";", "this", ".", "elementChangedListenerMasks", "[", "i", "]", "|=", "eventMask", ";", "return", ";", "}", "}", "int", "length", ";", "if", "(", "(", "length", "=", "this", ".", "elementChangedListeners", ".", "length", ")", "==", "this", ".", "elementChangedListenerCount", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "elementChangedListeners", ",", "0", ",", "this", ".", "elementChangedListeners", "=", "new", "IElementChangedListener", "[", "length", "*", "2", "]", ",", "0", ",", "length", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "elementChangedListenerMasks", ",", "0", ",", "this", ".", "elementChangedListenerMasks", "=", "new", "int", "[", "length", "*", "2", "]", ",", "0", ",", "length", ")", ";", "}", "this", ".", "elementChangedListeners", "[", "this", ".", "elementChangedListenerCount", "]", "=", "listener", ";", "this", ".", "elementChangedListenerMasks", "[", "this", ".", "elementChangedListenerCount", "]", "=", "eventMask", ";", "this", ".", "elementChangedListenerCount", "++", ";", "}", "public", "synchronized", "void", "addForRefresh", "(", "IJavaElement", "externalElement", ")", "{", "if", "(", "this", ".", "externalElementsToRefresh", "==", "null", ")", "{", "this", ".", "externalElementsToRefresh", "=", "new", "HashSet", "(", ")", ";", "}", "this", ".", "externalElementsToRefresh", ".", "add", "(", "externalElement", ")", ";", "}", "public", "synchronized", "void", "addPreResourceChangedListener", "(", "IResourceChangeListener", "listener", ",", "int", "eventMask", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "preResourceChangeListenerCount", ";", "i", "++", ")", "{", "if", "(", "this", ".", "preResourceChangeListeners", "[", "i", "]", "==", "listener", ")", "{", "this", ".", "preResourceChangeEventMasks", "[", "i", "]", "|=", "eventMask", ";", "return", ";", "}", "}", "int", "length", ";", "if", "(", "(", "length", "=", "this", ".", "preResourceChangeListeners", ".", "length", ")", "==", "this", ".", "preResourceChangeListenerCount", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "preResourceChangeListeners", ",", "0", ",", "this", ".", "preResourceChangeListeners", "=", "new", "IResourceChangeListener", "[", "length", "*", "2", "]", ",", "0", ",", "length", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "preResourceChangeEventMasks", ",", "0", ",", "this", ".", "preResourceChangeEventMasks", "=", "new", "int", "[", "length", "*", "2", "]", ",", "0", ",", "length", ")", ";", "}", "this", ".", "preResourceChangeListeners", "[", "this", ".", "preResourceChangeListenerCount", "]", "=", "listener", ";", "this", ".", "preResourceChangeEventMasks", "[", "this", ".", "preResourceChangeListenerCount", "]", "=", "eventMask", ";", "this", ".", "preResourceChangeListenerCount", "++", ";", "}", "public", "DeltaProcessor", "getDeltaProcessor", "(", ")", "{", "DeltaProcessor", "deltaProcessor", "=", "(", "DeltaProcessor", ")", "this", ".", "deltaProcessors", ".", "get", "(", ")", ";", "if", "(", "deltaProcessor", "!=", "null", ")", "return", "deltaProcessor", ";", "deltaProcessor", "=", "new", "DeltaProcessor", "(", "this", ",", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ")", ";", "this", ".", "deltaProcessors", ".", "set", "(", "deltaProcessor", ")", ";", "return", "deltaProcessor", ";", "}", "public", "synchronized", "ClasspathChange", "addClasspathChange", "(", "IProject", "project", ",", "IClasspathEntry", "[", "]", "oldRawClasspath", ",", "IPath", "oldOutputLocation", ",", "IClasspathEntry", "[", "]", "oldResolvedClasspath", ")", "{", "ClasspathChange", "change", "=", "(", "ClasspathChange", ")", "this", ".", "classpathChanges", ".", "get", "(", "project", ")", ";", "if", "(", "change", "==", "null", ")", "{", "change", "=", "new", "ClasspathChange", "(", "(", "JavaProject", ")", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "getJavaModel", "(", ")", ".", "getJavaProject", "(", "project", ")", ",", "oldRawClasspath", ",", "oldOutputLocation", ",", "oldResolvedClasspath", ")", ";", "this", ".", "classpathChanges", ".", "put", "(", "project", ",", "change", ")", ";", "}", "else", "{", "if", "(", "change", ".", "oldRawClasspath", "==", "null", ")", "change", ".", "oldRawClasspath", "=", "oldRawClasspath", ";", "if", "(", "change", ".", "oldOutputLocation", "==", "null", ")", "change", ".", "oldOutputLocation", "=", "oldOutputLocation", ";", "if", "(", "change", ".", "oldResolvedClasspath", "==", "null", ")", "change", ".", "oldResolvedClasspath", "=", "oldResolvedClasspath", ";", "}", "return", "change", ";", "}", "public", "synchronized", "ClasspathChange", "getClasspathChange", "(", "IProject", "project", ")", "{", "return", "(", "ClasspathChange", ")", "this", ".", "classpathChanges", ".", "get", "(", "project", ")", ";", "}", "public", "synchronized", "HashMap", "removeAllClasspathChanges", "(", ")", "{", "HashMap", "result", "=", "this", ".", "classpathChanges", ";", "this", ".", "classpathChanges", "=", "new", "HashMap", "(", "result", ".", "size", "(", ")", ")", ";", "return", "result", ";", "}", "public", "synchronized", "ClasspathValidation", "addClasspathValidation", "(", "JavaProject", "project", ")", "{", "ClasspathValidation", "validation", "=", "(", "ClasspathValidation", ")", "this", ".", "classpathValidations", ".", "get", "(", "project", ")", ";", "if", "(", "validation", "==", "null", ")", "{", "validation", "=", "new", "ClasspathValidation", "(", "project", ")", ";", "this", ".", "classpathValidations", ".", "put", "(", "project", ",", "validation", ")", ";", "}", "return", "validation", ";", "}", "public", "synchronized", "void", "addExternalFolderChange", "(", "JavaProject", "project", ",", "IClasspathEntry", "[", "]", "oldResolvedClasspath", ")", "{", "ExternalFolderChange", "change", "=", "(", "ExternalFolderChange", ")", "this", ".", "externalFolderChanges", ".", "get", "(", "project", ")", ";", "if", "(", "change", "==", "null", ")", "{", "change", "=", "new", "ExternalFolderChange", "(", "project", ",", "oldResolvedClasspath", ")", ";", "this", ".", "externalFolderChanges", ".", "put", "(", "project", ",", "change", ")", ";", "}", "}", "public", "synchronized", "void", "addProjectReferenceChange", "(", "JavaProject", "project", ",", "IClasspathEntry", "[", "]", "oldResolvedClasspath", ")", "{", "ProjectReferenceChange", "change", "=", "(", "ProjectReferenceChange", ")", "this", ".", "projectReferenceChanges", ".", "get", "(", "project", ")", ";", "if", "(", "change", "==", "null", ")", "{", "change", "=", "new", "ProjectReferenceChange", "(", "project", ",", "oldResolvedClasspath", ")", ";", "this", ".", "projectReferenceChanges", ".", "put", "(", "project", ",", "change", ")", ";", "}", "}", "public", "void", "initializeRoots", "(", "boolean", "initAfterLoad", ")", "{", "HashMap", "[", "]", "rootInfos", "=", "null", ";", "if", "(", "this", ".", "rootsAreStale", ")", "{", "Thread", "currentThread", "=", "Thread", ".", "currentThread", "(", ")", ";", "boolean", "addedCurrentThread", "=", "false", ";", "try", "{", "if", "(", "!", "this", ".", "initializingThreads", ".", "add", "(", "currentThread", ")", ")", "return", ";", "addedCurrentThread", "=", "true", ";", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "forceBatchInitializations", "(", "initAfterLoad", ")", ";", "rootInfos", "=", "getRootInfos", "(", "false", ")", ";", "}", "finally", "{", "if", "(", "addedCurrentThread", ")", "{", "this", ".", "initializingThreads", ".", "remove", "(", "currentThread", ")", ";", "}", "}", "}", "synchronized", "(", "this", ")", "{", "this", ".", "oldRoots", "=", "this", ".", "roots", ";", "this", ".", "oldOtherRoots", "=", "this", ".", "otherRoots", ";", "if", "(", "this", ".", "rootsAreStale", "&&", "rootInfos", "!=", "null", ")", "{", "this", ".", "roots", "=", "rootInfos", "[", "0", "]", ";", "this", ".", "otherRoots", "=", "rootInfos", "[", "1", "]", ";", "this", ".", "sourceAttachments", "=", "rootInfos", "[", "2", "]", ";", "this", ".", "projectDependencies", "=", "rootInfos", "[", "3", "]", ";", "this", ".", "rootsAreStale", "=", "false", ";", "}", "}", "}", "synchronized", "void", "initializeRootsWithPreviousSession", "(", ")", "{", "HashMap", "[", "]", "rootInfos", "=", "getRootInfos", "(", "true", ")", ";", "if", "(", "rootInfos", "!=", "null", ")", "{", "this", ".", "roots", "=", "rootInfos", "[", "0", "]", ";", "this", ".", "otherRoots", "=", "rootInfos", "[", "1", "]", ";", "this", ".", "sourceAttachments", "=", "rootInfos", "[", "2", "]", ";", "this", ".", "projectDependencies", "=", "rootInfos", "[", "3", "]", ";", "this", ".", "rootsAreStale", "=", "false", ";", "}", "}", "private", "HashMap", "[", "]", "getRootInfos", "(", "boolean", "usePreviousSession", ")", "{", "HashMap", "newRoots", "=", "new", "HashMap", "(", ")", ";", "HashMap", "newOtherRoots", "=", "new", "HashMap", "(", ")", ";", "HashMap", "newSourceAttachments", "=", "new", "HashMap", "(", ")", ";", "HashMap", "newProjectDependencies", "=", "new", "HashMap", "(", ")", ";", "IJavaModel", "model", "=", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "getJavaModel", "(", ")", ";", "IJavaProject", "[", "]", "projects", ";", "try", "{", "projects", "=", "model", ".", "getJavaProjects", "(", ")", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "return", "null", ";", "}", "for", "(", "int", "i", "=", "0", ",", "length", "=", "projects", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "JavaProject", "project", "=", "(", "JavaProject", ")", "projects", "[", "i", "]", ";", "IClasspathEntry", "[", "]", "classpath", ";", "try", "{", "if", "(", "usePreviousSession", ")", "{", "PerProjectInfo", "perProjectInfo", "=", "project", ".", "getPerProjectInfo", "(", ")", ";", "project", ".", "resolveClasspath", "(", "perProjectInfo", ",", "true", ",", "false", ")", ";", "classpath", "=", "perProjectInfo", ".", "resolvedClasspath", ";", "}", "else", "{", "classpath", "=", "project", ".", "getResolvedClasspath", "(", ")", ";", "}", "}", "catch", "(", "JavaModelException", "e", ")", "{", "continue", ";", "}", "for", "(", "int", "j", "=", "0", ",", "classpathLength", "=", "classpath", ".", "length", ";", "j", "<", "classpathLength", ";", "j", "++", ")", "{", "IClasspathEntry", "entry", "=", "classpath", "[", "j", "]", ";", "if", "(", "entry", ".", "getEntryKind", "(", ")", "==", "IClasspathEntry", ".", "CPE_PROJECT", ")", "{", "IJavaProject", "key", "=", "model", ".", "getJavaProject", "(", "entry", ".", "getPath", "(", ")", ".", "segment", "(", "0", ")", ")", ";", "IJavaProject", "[", "]", "dependents", "=", "(", "IJavaProject", "[", "]", ")", "newProjectDependencies", ".", "get", "(", "key", ")", ";", "if", "(", "dependents", "==", "null", ")", "{", "dependents", "=", "new", "IJavaProject", "[", "]", "{", "project", "}", ";", "}", "else", "{", "int", "dependentsLength", "=", "dependents", ".", "length", ";", "System", ".", "arraycopy", "(", "dependents", ",", "0", ",", "dependents", "=", "new", "IJavaProject", "[", "dependentsLength", "+", "1", "]", ",", "0", ",", "dependentsLength", ")", ";", "dependents", "[", "dependentsLength", "]", "=", "project", ";", "}", "newProjectDependencies", ".", "put", "(", "key", ",", "dependents", ")", ";", "continue", ";", "}", "IPath", "path", "=", "entry", ".", "getPath", "(", ")", ";", "if", "(", "newRoots", ".", "get", "(", "path", ")", "==", "null", ")", "{", "newRoots", ".", "put", "(", "path", ",", "new", "DeltaProcessor", ".", "RootInfo", "(", "project", ",", "path", ",", "(", "(", "ClasspathEntry", ")", "entry", ")", ".", "fullInclusionPatternChars", "(", ")", ",", "(", "(", "ClasspathEntry", ")", "entry", ")", ".", "fullExclusionPatternChars", "(", ")", ",", "entry", ".", "getEntryKind", "(", ")", ")", ")", ";", "}", "else", "{", "ArrayList", "rootList", "=", "(", "ArrayList", ")", "newOtherRoots", ".", "get", "(", "path", ")", ";", "if", "(", "rootList", "==", "null", ")", "{", "rootList", "=", "new", "ArrayList", "(", ")", ";", "newOtherRoots", ".", "put", "(", "path", ",", "rootList", ")", ";", "}", "rootList", ".", "add", "(", "new", "DeltaProcessor", ".", "RootInfo", "(", "project", ",", "path", ",", "(", "(", "ClasspathEntry", ")", "entry", ")", ".", "fullInclusionPatternChars", "(", ")", ",", "(", "(", "ClasspathEntry", ")", "entry", ")", ".", "fullExclusionPatternChars", "(", ")", ",", "entry", ".", "getEntryKind", "(", ")", ")", ")", ";", "}", "if", "(", "entry", ".", "getEntryKind", "(", ")", "!=", "IClasspathEntry", ".", "CPE_LIBRARY", ")", "continue", ";", "String", "propertyString", "=", "null", ";", "try", "{", "propertyString", "=", "Util", ".", "getSourceAttachmentProperty", "(", "path", ")", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "e", ".", "printStackTrace", "(", ")", ";", "}", "IPath", "sourceAttachmentPath", ";", "if", "(", "propertyString", "!=", "null", ")", "{", "int", "index", "=", "propertyString", ".", "lastIndexOf", "(", "PackageFragmentRoot", ".", "ATTACHMENT_PROPERTY_DELIMITER", ")", ";", "sourceAttachmentPath", "=", "(", "index", "<", "0", ")", "?", "new", "Path", "(", "propertyString", ")", ":", "new", "Path", "(", "propertyString", ".", "substring", "(", "0", ",", "index", ")", ")", ";", "}", "else", "{", "sourceAttachmentPath", "=", "entry", ".", "getSourceAttachmentPath", "(", ")", ";", "}", "if", "(", "sourceAttachmentPath", "!=", "null", ")", "{", "newSourceAttachments", ".", "put", "(", "sourceAttachmentPath", ",", "path", ")", ";", "}", "}", "}", "return", "new", "HashMap", "[", "]", "{", "newRoots", ",", "newOtherRoots", ",", "newSourceAttachments", ",", "newProjectDependencies", "}", ";", "}", "public", "synchronized", "ClasspathValidation", "[", "]", "removeClasspathValidations", "(", ")", "{", "int", "length", "=", "this", ".", "classpathValidations", ".", "size", "(", ")", ";", "if", "(", "length", "==", "0", ")", "return", "null", ";", "ClasspathValidation", "[", "]", "validations", "=", "new", "ClasspathValidation", "[", "length", "]", ";", "this", ".", "classpathValidations", ".", "values", "(", ")", ".", "toArray", "(", "validations", ")", ";", "this", ".", "classpathValidations", ".", "clear", "(", ")", ";", "return", "validations", ";", "}", "public", "synchronized", "ExternalFolderChange", "[", "]", "removeExternalFolderChanges", "(", ")", "{", "int", "length", "=", "this", ".", "externalFolderChanges", ".", "size", "(", ")", ";", "if", "(", "length", "==", "0", ")", "return", "null", ";", "ExternalFolderChange", "[", "]", "updates", "=", "new", "ExternalFolderChange", "[", "length", "]", ";", "this", ".", "externalFolderChanges", ".", "values", "(", ")", ".", "toArray", "(", "updates", ")", ";", "this", ".", "externalFolderChanges", ".", "clear", "(", ")", ";", "return", "updates", ";", "}", "public", "synchronized", "ProjectReferenceChange", "[", "]", "removeProjectReferenceChanges", "(", ")", "{", "int", "length", "=", "this", ".", "projectReferenceChanges", ".", "size", "(", ")", ";", "if", "(", "length", "==", "0", ")", "return", "null", ";", "ProjectReferenceChange", "[", "]", "updates", "=", "new", "ProjectReferenceChange", "[", "length", "]", ";", "this", ".", "projectReferenceChanges", ".", "values", "(", ")", ".", "toArray", "(", "updates", ")", ";", "this", ".", "projectReferenceChanges", ".", "clear", "(", ")", ";", "return", "updates", ";", "}", "public", "synchronized", "HashSet", "removeExternalElementsToRefresh", "(", ")", "{", "HashSet", "result", "=", "this", ".", "externalElementsToRefresh", ";", "this", ".", "externalElementsToRefresh", "=", "null", ";", "return", "result", ";", "}", "public", "synchronized", "void", "removeElementChangedListener", "(", "IElementChangedListener", "listener", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "elementChangedListenerCount", ";", "i", "++", ")", "{", "if", "(", "this", ".", "elementChangedListeners", "[", "i", "]", "==", "listener", ")", "{", "int", "length", "=", "this", ".", "elementChangedListeners", ".", "length", ";", "IElementChangedListener", "[", "]", "newListeners", "=", "new", "IElementChangedListener", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "this", ".", "elementChangedListeners", ",", "0", ",", "newListeners", ",", "0", ",", "i", ")", ";", "int", "[", "]", "newMasks", "=", "new", "int", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "this", ".", "elementChangedListenerMasks", ",", "0", ",", "newMasks", ",", "0", ",", "i", ")", ";", "int", "trailingLength", "=", "this", ".", "elementChangedListenerCount", "-", "i", "-", "1", ";", "if", "(", "trailingLength", ">", "0", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "elementChangedListeners", ",", "i", "+", "1", ",", "newListeners", ",", "i", ",", "trailingLength", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "elementChangedListenerMasks", ",", "i", "+", "1", ",", "newMasks", ",", "i", ",", "trailingLength", ")", ";", "}", "this", ".", "elementChangedListeners", "=", "newListeners", ";", "this", ".", "elementChangedListenerMasks", "=", "newMasks", ";", "this", ".", "elementChangedListenerCount", "--", ";", "return", ";", "}", "}", "}", "public", "synchronized", "void", "removePreResourceChangedListener", "(", "IResourceChangeListener", "listener", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "preResourceChangeListenerCount", ";", "i", "++", ")", "{", "if", "(", "this", ".", "preResourceChangeListeners", "[", "i", "]", "==", "listener", ")", "{", "int", "length", "=", "this", ".", "preResourceChangeListeners", ".", "length", ";", "IResourceChangeListener", "[", "]", "newListeners", "=", "new", "IResourceChangeListener", "[", "length", "]", ";", "int", "[", "]", "newEventMasks", "=", "new", "int", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "this", ".", "preResourceChangeListeners", ",", "0", ",", "newListeners", ",", "0", ",", "i", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "preResourceChangeEventMasks", ",", "0", ",", "newEventMasks", ",", "0", ",", "i", ")", ";", "int", "trailingLength", "=", "this", ".", "preResourceChangeListenerCount", "-", "i", "-", "1", ";", "if", "(", "trailingLength", ">", "0", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "preResourceChangeListeners", ",", "i", "+", "1", ",", "newListeners", ",", "i", ",", "trailingLength", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "preResourceChangeEventMasks", ",", "i", "+", "1", ",", "newEventMasks", ",", "i", ",", "trailingLength", ")", ";", "}", "this", ".", "preResourceChangeListeners", "=", "newListeners", ";", "this", ".", "preResourceChangeEventMasks", "=", "newEventMasks", ";", "this", ".", "preResourceChangeListenerCount", "--", ";", "return", ";", "}", "}", "}", "public", "void", "resourceChanged", "(", "final", "IResourceChangeEvent", "event", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "preResourceChangeListenerCount", ";", "i", "++", ")", "{", "final", "IResourceChangeListener", "listener", "=", "this", ".", "preResourceChangeListeners", "[", "i", "]", ";", "if", "(", "(", "this", ".", "preResourceChangeEventMasks", "[", "i", "]", "&", "event", ".", "getType", "(", ")", ")", "!=", "0", ")", "SafeRunner", ".", "run", "(", "new", "ISafeRunnable", "(", ")", "{", "public", "void", "handleException", "(", "Throwable", "exception", ")", "{", "Util", ".", "log", "(", "exception", ",", "\"\"", ")", ";", "}", "public", "void", "run", "(", ")", "throws", "Exception", "{", "listener", ".", "resourceChanged", "(", "event", ")", ";", "}", "}", ")", ";", "}", "try", "{", "getDeltaProcessor", "(", ")", ".", "resourceChanged", "(", "event", ")", ";", "}", "finally", "{", "if", "(", "event", ".", "getType", "(", ")", "==", "IResourceChangeEvent", ".", "POST_CHANGE", ")", "{", "this", ".", "deltaProcessors", ".", "set", "(", "null", ")", ";", "}", "else", "{", "getDeltaProcessor", "(", ")", ".", "overridenEventType", "=", "-", "1", ";", "}", "}", "}", "public", "Hashtable", "getExternalLibTimeStamps", "(", ")", "{", "if", "(", "this", ".", "externalTimeStamps", "==", "null", ")", "{", "Hashtable", "timeStamps", "=", "new", "Hashtable", "(", ")", ";", "File", "timestampsFile", "=", "getTimeStampsFile", "(", ")", ";", "DataInputStream", "in", "=", "null", ";", "try", "{", "in", "=", "new", "DataInputStream", "(", "new", "BufferedInputStream", "(", "new", "FileInputStream", "(", "timestampsFile", ")", ")", ")", ";", "int", "size", "=", "in", ".", "readInt", "(", ")", ";", "while", "(", "size", "--", ">", "0", ")", "{", "String", "key", "=", "in", ".", "readUTF", "(", ")", ";", "long", "timestamp", "=", "in", ".", "readLong", "(", ")", ";", "timeStamps", ".", "put", "(", "Path", ".", "fromPortableString", "(", "key", ")", ",", "new", "Long", "(", "timestamp", ")", ")", ";", "}", "}", "catch", "(", "IOException", "e", ")", "{", "if", "(", "timestampsFile", ".", "exists", "(", ")", ")", "Util", ".", "log", "(", "e", ",", "\"\"", ")", ";", "}", "finally", "{", "if", "(", "in", "!=", "null", ")", "{", "try", "{", "in", ".", "close", "(", ")", ";", "}", "catch", "(", "IOException", "e", ")", "{", "}", "}", "}", "this", ".", "externalTimeStamps", "=", "timeStamps", ";", "}", "return", "this", ".", "externalTimeStamps", ";", "}", "public", "IJavaProject", "findJavaProject", "(", "String", "name", ")", "{", "if", "(", "getOldJavaProjecNames", "(", ")", ".", "contains", "(", "name", ")", ")", "return", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "getJavaModel", "(", ")", ".", "getJavaProject", "(", "name", ")", ";", "return", "null", ";", "}", "public", "synchronized", "HashSet", "getOldJavaProjecNames", "(", ")", "{", "if", "(", "this", ".", "javaProjectNamesCache", "==", "null", ")", "{", "HashSet", "result", "=", "new", "HashSet", "(", ")", ";", "IJavaProject", "[", "]", "projects", ";", "try", "{", "projects", "=", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "getJavaModel", "(", ")", ".", "getJavaProjects", "(", ")", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "return", "this", ".", "javaProjectNamesCache", ";", "}", "for", "(", "int", "i", "=", "0", ",", "length", "=", "projects", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "IJavaProject", "project", "=", "projects", "[", "i", "]", ";", "result", ".", "add", "(", "project", ".", "getElementName", "(", ")", ")", ";", "}", "return", "this", ".", "javaProjectNamesCache", "=", "result", ";", "}", "return", "this", ".", "javaProjectNamesCache", ";", "}", "public", "synchronized", "void", "resetOldJavaProjectNames", "(", ")", "{", "this", ".", "javaProjectNamesCache", "=", "null", ";", "}", "private", "File", "getTimeStampsFile", "(", ")", "{", "return", "JavaCore", ".", "getPlugin", "(", ")", ".", "getStateLocation", "(", ")", ".", "append", "(", "\"\"", ")", ".", "toFile", "(", ")", ";", "}", "public", "void", "saveExternalLibTimeStamps", "(", ")", "throws", "CoreException", "{", "if", "(", "this", ".", "externalTimeStamps", "==", "null", ")", "return", ";", "HashSet", "toRemove", "=", "new", "HashSet", "(", ")", ";", "if", "(", "this", ".", "roots", "!=", "null", ")", "{", "Enumeration", "keys", "=", "this", ".", "externalTimeStamps", ".", "keys", "(", ")", ";", "while", "(", "keys", ".", "hasMoreElements", "(", ")", ")", "{", "Object", "key", "=", "keys", ".", "nextElement", "(", ")", ";", "if", "(", "this", ".", "roots", ".", "get", "(", "key", ")", "==", "null", ")", "{", "toRemove", ".", "add", "(", "key", ")", ";", "}", "}", "}", "File", "timestamps", "=", "getTimeStampsFile", "(", ")", ";", "DataOutputStream", "out", "=", "null", ";", "try", "{", "out", "=", "new", "DataOutputStream", "(", "new", "BufferedOutputStream", "(", "new", "FileOutputStream", "(", "timestamps", ")", ")", ")", ";", "out", ".", "writeInt", "(", "this", ".", "externalTimeStamps", ".", "size", "(", ")", "-", "toRemove", ".", "size", "(", ")", ")", ";", "Iterator", "entries", "=", "this", ".", "externalTimeStamps", ".", "entrySet", "(", ")", ".", "iterator", "(", ")", ";", "while", "(", "entries", ".", "hasNext", "(", ")", ")", "{", "Map", ".", "Entry", "entry", "=", "(", "Map", ".", "Entry", ")", "entries", ".", "next", "(", ")", ";", "IPath", "key", "=", "(", "IPath", ")", "entry", ".", "getKey", "(", ")", ";", "if", "(", "!", "toRemove", ".", "contains", "(", "key", ")", ")", "{", "out", ".", "writeUTF", "(", "key", ".", "toPortableString", "(", ")", ")", ";", "Long", "timestamp", "=", "(", "Long", ")", "entry", ".", "getValue", "(", ")", ";", "out", ".", "writeLong", "(", "timestamp", ".", "longValue", "(", ")", ")", ";", "}", "}", "}", "catch", "(", "IOException", "e", ")", "{", "IStatus", "status", "=", "new", "Status", "(", "IStatus", ".", "ERROR", ",", "JavaCore", ".", "PLUGIN_ID", ",", "IStatus", ".", "ERROR", ",", "\"\"", ",", "e", ")", ";", "throw", "new", "CoreException", "(", "status", ")", ";", "}", "finally", "{", "if", "(", "out", "!=", "null", ")", "{", "try", "{", "out", ".", "close", "(", ")", ";", "}", "catch", "(", "IOException", "e", ")", "{", "}", "}", "}", "}", "public", "synchronized", "void", "updateRoots", "(", "IPath", "containerPath", ",", "IResourceDelta", "containerDelta", ",", "DeltaProcessor", "deltaProcessor", ")", "{", "Map", "updatedRoots", ";", "Map", "otherUpdatedRoots", ";", "if", "(", "containerDelta", ".", "getKind", "(", ")", "==", "IResourceDelta", ".", "REMOVED", ")", "{", "updatedRoots", "=", "this", ".", "oldRoots", ";", "otherUpdatedRoots", "=", "this", ".", "oldOtherRoots", ";", "}", "else", "{", "updatedRoots", "=", "this", ".", "roots", ";", "otherUpdatedRoots", "=", "this", ".", "otherRoots", ";", "}", "int", "containerSegmentCount", "=", "containerPath", ".", "segmentCount", "(", ")", ";", "boolean", "containerIsProject", "=", "containerSegmentCount", "==", "1", ";", "Iterator", "iterator", "=", "updatedRoots", ".", "entrySet", "(", ")", ".", "iterator", "(", ")", ";", "while", "(", "iterator", ".", "hasNext", "(", ")", ")", "{", "Map", ".", "Entry", "entry", "=", "(", "Map", ".", "Entry", ")", "iterator", ".", "next", "(", ")", ";", "IPath", "path", "=", "(", "IPath", ")", "entry", ".", "getKey", "(", ")", ";", "if", "(", "containerPath", ".", "isPrefixOf", "(", "path", ")", "&&", "!", "containerPath", ".", "equals", "(", "path", ")", ")", "{", "IResourceDelta", "rootDelta", "=", "containerDelta", ".", "findMember", "(", "path", ".", "removeFirstSegments", "(", "containerSegmentCount", ")", ")", ";", "if", "(", "rootDelta", "==", "null", ")", "continue", ";", "DeltaProcessor", ".", "RootInfo", "rootInfo", "=", "(", "DeltaProcessor", ".", "RootInfo", ")", "entry", ".", "getValue", "(", ")", ";", "if", "(", "!", "containerIsProject", "||", "!", "rootInfo", ".", "project", ".", "getPath", "(", ")", ".", "isPrefixOf", "(", "path", ")", ")", "{", "deltaProcessor", ".", "updateCurrentDeltaAndIndex", "(", "rootDelta", ",", "IJavaElement", ".", "PACKAGE_FRAGMENT_ROOT", ",", "rootInfo", ")", ";", "}", "ArrayList", "rootList", "=", "(", "ArrayList", ")", "otherUpdatedRoots", ".", "get", "(", "path", ")", ";", "if", "(", "rootList", "!=", "null", ")", "{", "Iterator", "otherProjects", "=", "rootList", ".", "iterator", "(", ")", ";", "while", "(", "otherProjects", ".", "hasNext", "(", ")", ")", "{", "rootInfo", "=", "(", "DeltaProcessor", ".", "RootInfo", ")", "otherProjects", ".", "next", "(", ")", ";", "if", "(", "!", "containerIsProject", "||", "!", "rootInfo", ".", "project", ".", "getPath", "(", ")", ".", "isPrefixOf", "(", "path", ")", ")", "{", "deltaProcessor", ".", "updateCurrentDeltaAndIndex", "(", "rootDelta", ",", "IJavaElement", ".", "PACKAGE_FRAGMENT_ROOT", ",", "rootInfo", ")", ";", "}", "}", "}", "}", "}", "}", "}", "</s>" ]
5,530
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IResourceRuleFactory", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "ResourcesPlugin", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IPath", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "jobs", ".", "ISchedulingRule", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "jobs", ".", "MultiRule", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IClasspathEntry", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatus", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaProject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "JavaModelManager", ".", "PerProjectInfo", ";", "public", "class", "SetClasspathOperation", "extends", "ChangeClasspathOperation", "{", "IClasspathEntry", "[", "]", "newRawClasspath", ";", "IClasspathEntry", "[", "]", "referencedEntries", ";", "IPath", "newOutputLocation", ";", "JavaProject", "project", ";", "public", "SetClasspathOperation", "(", "JavaProject", "project", ",", "IClasspathEntry", "[", "]", "newRawClasspath", ",", "IPath", "newOutputLocation", ",", "boolean", "canChangeResource", ")", "{", "this", "(", "project", ",", "newRawClasspath", ",", "null", ",", "newOutputLocation", ",", "canChangeResource", ")", ";", "}", "public", "SetClasspathOperation", "(", "JavaProject", "project", ",", "IClasspathEntry", "[", "]", "newRawClasspath", ",", "IClasspathEntry", "[", "]", "referencedEntries", ",", "IPath", "newOutputLocation", ",", "boolean", "canChangeResource", ")", "{", "super", "(", "new", "IJavaElement", "[", "]", "{", "project", "}", ",", "canChangeResource", ")", ";", "this", ".", "project", "=", "project", ";", "this", ".", "newRawClasspath", "=", "newRawClasspath", ";", "this", ".", "referencedEntries", "=", "referencedEntries", ";", "this", ".", "newOutputLocation", "=", "newOutputLocation", ";", "}", "protected", "void", "executeOperation", "(", ")", "throws", "JavaModelException", "{", "checkCanceled", "(", ")", ";", "try", "{", "PerProjectInfo", "perProjectInfo", "=", "this", ".", "project", ".", "getPerProjectInfo", "(", ")", ";", "ClasspathChange", "classpathChange", "=", "perProjectInfo", ".", "setRawClasspath", "(", "this", ".", "newRawClasspath", ",", "this", ".", "referencedEntries", ",", "this", ".", "newOutputLocation", ",", "JavaModelStatus", ".", "VERIFIED_OK", ")", ";", "classpathChanged", "(", "classpathChange", ",", "true", ")", ";", "if", "(", "this", ".", "canChangeResources", "&&", "perProjectInfo", ".", "writeAndCacheClasspath", "(", "this", ".", "project", ",", "this", ".", "newRawClasspath", ",", "this", ".", "newOutputLocation", ")", ")", "setAttribute", "(", "HAS_MODIFIED_RESOURCE_ATTR", ",", "TRUE", ")", ";", "}", "finally", "{", "done", "(", ")", ";", "}", "}", "protected", "ISchedulingRule", "getSchedulingRule", "(", ")", "{", "if", "(", "this", ".", "canChangeResources", ")", "{", "IResourceRuleFactory", "ruleFactory", "=", "ResourcesPlugin", ".", "getWorkspace", "(", ")", ".", "getRuleFactory", "(", ")", ";", "return", "new", "MultiRule", "(", "new", "ISchedulingRule", "[", "]", "{", "ruleFactory", ".", "modifyRule", "(", "this", ".", "project", ".", "getProject", "(", ")", ")", ",", "ruleFactory", ".", "modifyRule", "(", "JavaModelManager", ".", "getExternalManager", "(", ")", ".", "getExternalFoldersProject", "(", ")", ")", "}", ")", ";", "}", "return", "super", ".", "getSchedulingRule", "(", ")", ";", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", "20", ")", ";", "buffer", ".", "append", "(", "\"\"", ")", ";", "buffer", ".", "append", "(", "\"\"", ")", ";", "buffer", ".", "append", "(", "\"{\"", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "newRawClasspath", ".", "length", ";", "i", "++", ")", "{", "if", "(", "i", ">", "0", ")", "buffer", ".", "append", "(", "\",\"", ")", ";", "IClasspathEntry", "element", "=", "this", ".", "newRawClasspath", "[", "i", "]", ";", "buffer", ".", "append", "(", "\"", "\"", ")", ".", "append", "(", "element", ".", "toString", "(", ")", ")", ";", "}", "buffer", ".", "append", "(", "\"\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "newOutputLocation", ".", "toString", "(", ")", ")", ";", "return", "buffer", ".", "toString", "(", ")", ";", "}", "public", "IJavaModelStatus", "verify", "(", ")", "{", "IJavaModelStatus", "status", "=", "super", ".", "verify", "(", ")", ";", "if", "(", "!", "status", ".", "isOK", "(", ")", ")", "return", "status", ";", "return", "ClasspathEntry", ".", "validateClasspath", "(", "this", ".", "project", ",", "this", ".", "newRawClasspath", ",", "this", ".", "newOutputLocation", ")", ";", "}", "}", "</s>" ]
5,531
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ISourceImport", ";", "public", "class", "ImportDeclarationElementInfo", "extends", "MemberElementInfo", "implements", "ISourceImport", "{", "}", "</s>" ]
5,532
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaProject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaCore", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "InvalidInputException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "codeassist", ".", "impl", ".", "AssistOptions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CompilerOptions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "parser", ".", "Scanner", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "parser", ".", "ScannerHelper", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "parser", ".", "TerminalTokens", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "SimpleSetOfCharArray", ";", "public", "class", "InternalNamingConventions", "{", "private", "static", "final", "char", "[", "]", "DEFAULT_NAME", "=", "\"name\"", ".", "toCharArray", "(", ")", ";", "private", "static", "Scanner", "getNameScanner", "(", "CompilerOptions", "compilerOptions", ")", "{", "return", "new", "Scanner", "(", "false", ",", "false", ",", "false", ",", "compilerOptions", ".", "sourceLevel", ",", "null", ",", "null", ",", "true", ")", ";", "}", "private", "static", "void", "acceptName", "(", "char", "[", "]", "name", ",", "char", "[", "]", "prefix", ",", "char", "[", "]", "suffix", ",", "boolean", "isFirstPrefix", ",", "boolean", "isFirstSuffix", ",", "int", "reusedCharacters", ",", "INamingRequestor", "requestor", ")", "{", "if", "(", "prefix", ".", "length", ">", "0", "&&", "suffix", ".", "length", ">", "0", ")", "{", "requestor", ".", "acceptNameWithPrefixAndSuffix", "(", "name", ",", "isFirstPrefix", ",", "isFirstSuffix", ",", "reusedCharacters", ")", ";", "}", "else", "if", "(", "prefix", ".", "length", ">", "0", ")", "{", "requestor", ".", "acceptNameWithPrefix", "(", "name", ",", "isFirstPrefix", ",", "reusedCharacters", ")", ";", "}", "else", "if", "(", "suffix", ".", "length", ">", "0", ")", "{", "requestor", ".", "acceptNameWithSuffix", "(", "name", ",", "isFirstSuffix", ",", "reusedCharacters", ")", ";", "}", "else", "{", "requestor", ".", "acceptNameWithoutPrefixAndSuffix", "(", "name", ",", "reusedCharacters", ")", ";", "}", "}", "private", "static", "char", "[", "]", "[", "]", "computeBaseTypeNames", "(", "char", "[", "]", "typeName", ",", "boolean", "isConstantField", ",", "char", "[", "]", "[", "]", "excludedNames", ")", "{", "if", "(", "isConstantField", ")", "{", "return", "computeNonBaseTypeNames", "(", "typeName", ",", "isConstantField", ",", "false", ")", ";", "}", "else", "{", "char", "[", "]", "name", "=", "computeBaseTypeNames", "(", "typeName", "[", "0", "]", ",", "excludedNames", ")", ";", "if", "(", "name", "!=", "null", ")", "{", "return", "new", "char", "[", "]", "[", "]", "{", "name", "}", ";", "}", "else", "{", "return", "computeNonBaseTypeNames", "(", "typeName", ",", "isConstantField", ",", "false", ")", ";", "}", "}", "}", "private", "static", "char", "[", "]", "computeBaseTypeNames", "(", "char", "firstName", ",", "char", "[", "]", "[", "]", "excludedNames", ")", "{", "char", "[", "]", "name", "=", "new", "char", "[", "]", "{", "firstName", "}", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "excludedNames", ".", "length", ";", "i", "++", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "name", ",", "excludedNames", "[", "i", "]", ",", "false", ")", ")", "{", "name", "[", "0", "]", "++", ";", "if", "(", "name", "[", "0", "]", ">", "'z'", ")", "name", "[", "0", "]", "=", "'a'", ";", "if", "(", "name", "[", "0", "]", "==", "firstName", ")", "return", "null", ";", "i", "=", "0", ";", "}", "}", "return", "name", ";", "}", "private", "static", "char", "[", "]", "[", "]", "computeNonBaseTypeNames", "(", "char", "[", "]", "sourceName", ",", "boolean", "isConstantField", ",", "boolean", "onlyLongest", ")", "{", "int", "length", "=", "sourceName", ".", "length", ";", "if", "(", "length", "==", "0", ")", "{", "return", "CharOperation", ".", "NO_CHAR_CHAR", ";", "}", "if", "(", "length", "==", "1", ")", "{", "if", "(", "isConstantField", ")", "{", "return", "generateConstantName", "(", "new", "char", "[", "]", "[", "]", "{", "CharOperation", ".", "toLowerCase", "(", "sourceName", ")", "}", ",", "0", ",", "onlyLongest", ")", ";", "}", "else", "{", "return", "generateNonConstantName", "(", "new", "char", "[", "]", "[", "]", "{", "CharOperation", ".", "toLowerCase", "(", "sourceName", ")", "}", ",", "0", ",", "onlyLongest", ")", ";", "}", "}", "char", "[", "]", "[", "]", "nameParts", "=", "new", "char", "[", "length", "]", "[", "]", ";", "int", "namePartsPtr", "=", "-", "1", ";", "int", "endIndex", "=", "length", ";", "char", "c", "=", "sourceName", "[", "length", "-", "1", "]", ";", "final", "int", "IS_LOWER_CASE", "=", "1", ";", "final", "int", "IS_UPPER_CASE", "=", "2", ";", "final", "int", "IS_UNDERSCORE", "=", "3", ";", "final", "int", "IS_OTHER", "=", "4", ";", "int", "previousCharKind", "=", "ScannerHelper", ".", "isLowerCase", "(", "c", ")", "?", "IS_LOWER_CASE", ":", "ScannerHelper", ".", "isUpperCase", "(", "c", ")", "?", "IS_UPPER_CASE", ":", "c", "==", "'_'", "?", "IS_UNDERSCORE", ":", "IS_OTHER", ";", "for", "(", "int", "i", "=", "length", "-", "1", ";", "i", ">=", "0", ";", "i", "--", ")", "{", "c", "=", "sourceName", "[", "i", "]", ";", "int", "charKind", "=", "ScannerHelper", ".", "isLowerCase", "(", "c", ")", "?", "IS_LOWER_CASE", ":", "ScannerHelper", ".", "isUpperCase", "(", "c", ")", "?", "IS_UPPER_CASE", ":", "c", "==", "'_'", "?", "IS_UNDERSCORE", ":", "IS_OTHER", ";", "switch", "(", "charKind", ")", "{", "case", "IS_LOWER_CASE", ":", "if", "(", "previousCharKind", "==", "IS_UPPER_CASE", ")", "{", "nameParts", "[", "++", "namePartsPtr", "]", "=", "CharOperation", ".", "subarray", "(", "sourceName", ",", "i", "+", "1", ",", "endIndex", ")", ";", "endIndex", "=", "i", "+", "1", ";", "}", "previousCharKind", "=", "IS_LOWER_CASE", ";", "break", ";", "case", "IS_UPPER_CASE", ":", "if", "(", "previousCharKind", "==", "IS_LOWER_CASE", ")", "{", "nameParts", "[", "++", "namePartsPtr", "]", "=", "CharOperation", ".", "subarray", "(", "sourceName", ",", "i", ",", "endIndex", ")", ";", "if", "(", "i", ">", "0", ")", "{", "char", "pc", "=", "sourceName", "[", "i", "-", "1", "]", ";", "previousCharKind", "=", "ScannerHelper", ".", "isLowerCase", "(", "pc", ")", "?", "IS_LOWER_CASE", ":", "ScannerHelper", ".", "isUpperCase", "(", "pc", ")", "?", "IS_UPPER_CASE", ":", "pc", "==", "'_'", "?", "IS_UNDERSCORE", ":", "IS_OTHER", ";", "}", "endIndex", "=", "i", ";", "}", "else", "{", "previousCharKind", "=", "IS_UPPER_CASE", ";", "}", "break", ";", "case", "IS_UNDERSCORE", ":", "switch", "(", "previousCharKind", ")", "{", "case", "IS_UNDERSCORE", ":", "if", "(", "isConstantField", ")", "{", "if", "(", "i", ">", "0", ")", "{", "char", "pc", "=", "sourceName", "[", "i", "-", "1", "]", ";", "previousCharKind", "=", "ScannerHelper", ".", "isLowerCase", "(", "pc", ")", "?", "IS_LOWER_CASE", ":", "ScannerHelper", ".", "isUpperCase", "(", "pc", ")", "?", "IS_UPPER_CASE", ":", "pc", "==", "'_'", "?", "IS_UNDERSCORE", ":", "IS_OTHER", ";", "}", "endIndex", "=", "i", ";", "}", "break", ";", "case", "IS_LOWER_CASE", ":", "case", "IS_UPPER_CASE", ":", "nameParts", "[", "++", "namePartsPtr", "]", "=", "CharOperation", ".", "subarray", "(", "sourceName", ",", "i", "+", "1", ",", "endIndex", ")", ";", "if", "(", "i", ">", "0", ")", "{", "char", "pc", "=", "sourceName", "[", "i", "-", "1", "]", ";", "previousCharKind", "=", "ScannerHelper", ".", "isLowerCase", "(", "pc", ")", "?", "IS_LOWER_CASE", ":", "ScannerHelper", ".", "isUpperCase", "(", "pc", ")", "?", "IS_UPPER_CASE", ":", "pc", "==", "'_'", "?", "IS_UNDERSCORE", ":", "IS_OTHER", ";", "}", "endIndex", "=", "i", "+", "1", ";", "break", ";", "default", ":", "previousCharKind", "=", "IS_UNDERSCORE", ";", "break", ";", "}", "break", ";", "default", ":", "previousCharKind", "=", "IS_OTHER", ";", "break", ";", "}", "}", "if", "(", "endIndex", ">", "0", ")", "{", "nameParts", "[", "++", "namePartsPtr", "]", "=", "CharOperation", ".", "subarray", "(", "sourceName", ",", "0", ",", "endIndex", ")", ";", "}", "if", "(", "namePartsPtr", "==", "-", "1", ")", "{", "return", "new", "char", "[", "]", "[", "]", "{", "sourceName", "}", ";", "}", "if", "(", "isConstantField", ")", "{", "return", "generateConstantName", "(", "nameParts", ",", "namePartsPtr", ",", "onlyLongest", ")", ";", "}", "else", "{", "return", "generateNonConstantName", "(", "nameParts", ",", "namePartsPtr", ",", "onlyLongest", ")", ";", "}", "}", "private", "static", "char", "[", "]", "excludeNames", "(", "char", "[", "]", "suffixName", ",", "char", "[", "]", "prefixName", ",", "char", "[", "]", "suffix", ",", "char", "[", "]", "[", "]", "excludedNames", ")", "{", "int", "count", "=", "2", ";", "int", "m", "=", "0", ";", "while", "(", "m", "<", "excludedNames", ".", "length", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "suffixName", ",", "excludedNames", "[", "m", "]", ",", "false", ")", ")", "{", "suffixName", "=", "CharOperation", ".", "concat", "(", "prefixName", ",", "String", ".", "valueOf", "(", "count", "++", ")", ".", "toCharArray", "(", ")", ",", "suffix", ")", ";", "m", "=", "0", ";", "}", "else", "{", "m", "++", ";", "}", "}", "return", "suffixName", ";", "}", "private", "static", "char", "[", "]", "[", "]", "generateNonConstantName", "(", "char", "[", "]", "[", "]", "nameParts", ",", "int", "namePartsPtr", ",", "boolean", "onlyLongest", ")", "{", "char", "[", "]", "[", "]", "names", ";", "if", "(", "onlyLongest", ")", "{", "names", "=", "new", "char", "[", "1", "]", "[", "]", ";", "}", "else", "{", "names", "=", "new", "char", "[", "namePartsPtr", "+", "1", "]", "[", "]", ";", "}", "char", "[", "]", "namePart", "=", "nameParts", "[", "0", "]", ";", "char", "[", "]", "name", "=", "CharOperation", ".", "toLowerCase", "(", "namePart", ")", ";", "if", "(", "!", "onlyLongest", ")", "{", "names", "[", "namePartsPtr", "]", "=", "name", ";", "}", "char", "[", "]", "nameSuffix", "=", "namePart", ";", "for", "(", "int", "i", "=", "1", ";", "i", "<=", "namePartsPtr", ";", "i", "++", ")", "{", "namePart", "=", "nameParts", "[", "i", "]", ";", "name", "=", "CharOperation", ".", "concat", "(", "CharOperation", ".", "toLowerCase", "(", "namePart", ")", ",", "nameSuffix", ")", ";", "if", "(", "!", "onlyLongest", ")", "{", "names", "[", "namePartsPtr", "-", "i", "]", "=", "name", ";", "}", "nameSuffix", "=", "CharOperation", ".", "concat", "(", "namePart", ",", "nameSuffix", ")", ";", "}", "if", "(", "onlyLongest", ")", "{", "names", "[", "0", "]", "=", "name", ";", "}", "return", "names", ";", "}", "private", "static", "char", "[", "]", "[", "]", "generateConstantName", "(", "char", "[", "]", "[", "]", "nameParts", ",", "int", "namePartsPtr", ",", "boolean", "onlyLongest", ")", "{", "char", "[", "]", "[", "]", "names", ";", "if", "(", "onlyLongest", ")", "{", "names", "=", "new", "char", "[", "1", "]", "[", "]", ";", "}", "else", "{", "names", "=", "new", "char", "[", "namePartsPtr", "+", "1", "]", "[", "]", ";", "}", "char", "[", "]", "namePart", "=", "CharOperation", ".", "toUpperCase", "(", "nameParts", "[", "0", "]", ")", ";", "int", "namePartLength", "=", "namePart", ".", "length", ";", "System", ".", "arraycopy", "(", "namePart", ",", "0", ",", "namePart", ",", "0", ",", "namePartLength", ")", ";", "char", "[", "]", "name", "=", "namePart", ";", "if", "(", "!", "onlyLongest", ")", "{", "names", "[", "namePartsPtr", "]", "=", "name", ";", "}", "for", "(", "int", "i", "=", "1", ";", "i", "<=", "namePartsPtr", ";", "i", "++", ")", "{", "namePart", "=", "CharOperation", ".", "toUpperCase", "(", "nameParts", "[", "i", "]", ")", ";", "namePartLength", "=", "namePart", ".", "length", ";", "if", "(", "namePart", "[", "namePartLength", "-", "1", "]", "!=", "'_'", ")", "{", "name", "=", "CharOperation", ".", "concat", "(", "namePart", ",", "name", ",", "'_'", ")", ";", "}", "else", "{", "name", "=", "CharOperation", ".", "concat", "(", "namePart", ",", "name", ")", ";", "}", "if", "(", "!", "onlyLongest", ")", "{", "names", "[", "namePartsPtr", "-", "i", "]", "=", "name", ";", "}", "}", "if", "(", "onlyLongest", ")", "{", "names", "[", "0", "]", "=", "name", ";", "}", "return", "names", ";", "}", "public", "static", "char", "[", "]", "getBaseName", "(", "int", "variableKind", ",", "IJavaProject", "javaProject", ",", "char", "[", "]", "name", ",", "boolean", "updateFirstCharacter", ")", "{", "AssistOptions", "assistOptions", ";", "if", "(", "javaProject", "!=", "null", ")", "{", "assistOptions", "=", "new", "AssistOptions", "(", "javaProject", ".", "getOptions", "(", "true", ")", ")", ";", "}", "else", "{", "assistOptions", "=", "new", "AssistOptions", "(", "JavaCore", ".", "getOptions", "(", ")", ")", ";", "}", "char", "[", "]", "[", "]", "prefixes", "=", "null", ";", "char", "[", "]", "[", "]", "suffixes", "=", "null", ";", "switch", "(", "variableKind", ")", "{", "case", "VK_INSTANCE_FIELD", ":", "prefixes", "=", "assistOptions", ".", "fieldPrefixes", ";", "suffixes", "=", "assistOptions", ".", "fieldSuffixes", ";", "break", ";", "case", "VK_STATIC_FIELD", ":", "prefixes", "=", "assistOptions", ".", "staticFieldPrefixes", ";", "suffixes", "=", "assistOptions", ".", "staticFieldSuffixes", ";", "break", ";", "case", "VK_STATIC_FINAL_FIELD", ":", "prefixes", "=", "assistOptions", ".", "staticFinalFieldPrefixes", ";", "suffixes", "=", "assistOptions", ".", "staticFinalFieldSuffixes", ";", "break", ";", "case", "VK_LOCAL", ":", "prefixes", "=", "assistOptions", ".", "localPrefixes", ";", "suffixes", "=", "assistOptions", ".", "localSuffixes", ";", "break", ";", "case", "VK_PARAMETER", ":", "prefixes", "=", "assistOptions", ".", "argumentPrefixes", ";", "suffixes", "=", "assistOptions", ".", "argumentSuffixes", ";", "break", ";", "}", "return", "getBaseName", "(", "name", ",", "prefixes", ",", "suffixes", ",", "variableKind", "==", "VK_STATIC_FINAL_FIELD", ",", "updateFirstCharacter", ")", ";", "}", "private", "static", "char", "[", "]", "getBaseName", "(", "char", "[", "]", "name", ",", "char", "[", "]", "[", "]", "prefixes", ",", "char", "[", "]", "[", "]", "suffixes", ",", "boolean", "isConstant", ",", "boolean", "updateFirstCharacter", ")", "{", "char", "[", "]", "nameWithoutPrefixAndSiffix", "=", "removeVariablePrefixAndSuffix", "(", "name", ",", "prefixes", ",", "suffixes", ",", "updateFirstCharacter", ")", ";", "char", "[", "]", "baseName", ";", "if", "(", "isConstant", ")", "{", "int", "length", "=", "nameWithoutPrefixAndSiffix", ".", "length", ";", "baseName", "=", "new", "char", "[", "length", "]", ";", "int", "baseNamePtr", "=", "-", "1", ";", "boolean", "previousIsUnderscore", "=", "false", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "char", "c", "=", "nameWithoutPrefixAndSiffix", "[", "i", "]", ";", "if", "(", "c", "!=", "'_'", ")", "{", "if", "(", "previousIsUnderscore", ")", "{", "baseName", "[", "++", "baseNamePtr", "]", "=", "ScannerHelper", ".", "toUpperCase", "(", "c", ")", ";", "previousIsUnderscore", "=", "false", ";", "}", "else", "{", "baseName", "[", "++", "baseNamePtr", "]", "=", "ScannerHelper", ".", "toLowerCase", "(", "c", ")", ";", "}", "}", "else", "{", "previousIsUnderscore", "=", "true", ";", "}", "}", "System", ".", "arraycopy", "(", "baseName", ",", "0", ",", "baseName", "=", "new", "char", "[", "baseNamePtr", "+", "1", "]", ",", "0", ",", "baseNamePtr", "+", "1", ")", ";", "}", "else", "{", "baseName", "=", "nameWithoutPrefixAndSiffix", ";", "}", "return", "baseName", ";", "}", "public", "static", "char", "[", "]", "removeVariablePrefixAndSuffix", "(", "int", "variableKind", ",", "IJavaProject", "javaProject", ",", "char", "[", "]", "name", ")", "{", "AssistOptions", "assistOptions", ";", "if", "(", "javaProject", "!=", "null", ")", "{", "assistOptions", "=", "new", "AssistOptions", "(", "javaProject", ".", "getOptions", "(", "true", ")", ")", ";", "}", "else", "{", "assistOptions", "=", "new", "AssistOptions", "(", "JavaCore", ".", "getOptions", "(", ")", ")", ";", "}", "char", "[", "]", "[", "]", "prefixes", "=", "null", ";", "char", "[", "]", "[", "]", "suffixes", "=", "null", ";", "switch", "(", "variableKind", ")", "{", "case", "VK_INSTANCE_FIELD", ":", "prefixes", "=", "assistOptions", ".", "fieldPrefixes", ";", "suffixes", "=", "assistOptions", ".", "fieldSuffixes", ";", "break", ";", "case", "VK_STATIC_FIELD", ":", "prefixes", "=", "assistOptions", ".", "staticFieldPrefixes", ";", "suffixes", "=", "assistOptions", ".", "staticFieldSuffixes", ";", "break", ";", "case", "VK_STATIC_FINAL_FIELD", ":", "prefixes", "=", "assistOptions", ".", "staticFinalFieldPrefixes", ";", "suffixes", "=", "assistOptions", ".", "staticFinalFieldSuffixes", ";", "break", ";", "case", "VK_LOCAL", ":", "prefixes", "=", "assistOptions", ".", "localPrefixes", ";", "suffixes", "=", "assistOptions", ".", "localSuffixes", ";", "break", ";", "case", "VK_PARAMETER", ":", "prefixes", "=", "assistOptions", ".", "argumentPrefixes", ";", "suffixes", "=", "assistOptions", ".", "argumentSuffixes", ";", "break", ";", "}", "return", "InternalNamingConventions", ".", "removeVariablePrefixAndSuffix", "(", "name", ",", "prefixes", ",", "suffixes", ",", "true", ")", ";", "}", "private", "static", "char", "[", "]", "removeVariablePrefixAndSuffix", "(", "char", "[", "]", "name", ",", "char", "[", "]", "[", "]", "prefixes", ",", "char", "[", "]", "[", "]", "suffixes", ",", "boolean", "updateFirstCharacter", ")", "{", "char", "[", "]", "withoutPrefixName", "=", "name", ";", "if", "(", "prefixes", "!=", "null", ")", "{", "int", "bestLength", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "prefixes", ".", "length", ";", "i", "++", ")", "{", "char", "[", "]", "prefix", "=", "prefixes", "[", "i", "]", ";", "if", "(", "CharOperation", ".", "prefixEquals", "(", "prefix", ",", "name", ")", ")", "{", "int", "currLen", "=", "prefix", ".", "length", ";", "boolean", "lastCharIsLetter", "=", "ScannerHelper", ".", "isLetter", "(", "prefix", "[", "currLen", "-", "1", "]", ")", ";", "if", "(", "!", "lastCharIsLetter", "||", "(", "lastCharIsLetter", "&&", "name", ".", "length", ">", "currLen", "&&", "ScannerHelper", ".", "isUpperCase", "(", "name", "[", "currLen", "]", ")", ")", ")", "{", "if", "(", "bestLength", "<", "currLen", "&&", "name", ".", "length", "!=", "currLen", ")", "{", "withoutPrefixName", "=", "CharOperation", ".", "subarray", "(", "name", ",", "currLen", ",", "name", ".", "length", ")", ";", "bestLength", "=", "currLen", ";", "}", "}", "}", "}", "}", "char", "[", "]", "withoutSuffixName", "=", "withoutPrefixName", ";", "if", "(", "suffixes", "!=", "null", ")", "{", "int", "bestLength", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "suffixes", ".", "length", ";", "i", "++", ")", "{", "char", "[", "]", "suffix", "=", "suffixes", "[", "i", "]", ";", "if", "(", "CharOperation", ".", "endsWith", "(", "withoutPrefixName", ",", "suffix", ")", ")", "{", "int", "currLen", "=", "suffix", ".", "length", ";", "if", "(", "bestLength", "<", "currLen", "&&", "withoutPrefixName", ".", "length", "!=", "currLen", ")", "{", "withoutSuffixName", "=", "CharOperation", ".", "subarray", "(", "withoutPrefixName", ",", "0", ",", "withoutPrefixName", ".", "length", "-", "currLen", ")", ";", "bestLength", "=", "currLen", ";", "}", "}", "}", "}", "if", "(", "updateFirstCharacter", ")", "withoutSuffixName", "[", "0", "]", "=", "ScannerHelper", ".", "toLowerCase", "(", "withoutSuffixName", "[", "0", "]", ")", ";", "return", "withoutSuffixName", ";", "}", "private", "static", "char", "[", "]", "removePrefix", "(", "char", "[", "]", "name", ",", "char", "[", "]", "[", "]", "prefixes", ")", "{", "char", "[", "]", "withoutPrefixName", "=", "name", ";", "if", "(", "prefixes", "!=", "null", ")", "{", "int", "bestLength", "=", "0", ";", "int", "nameLength", "=", "name", ".", "length", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "prefixes", ".", "length", ";", "i", "++", ")", "{", "char", "[", "]", "prefix", "=", "prefixes", "[", "i", "]", ";", "int", "prefixLength", "=", "prefix", ".", "length", ";", "if", "(", "prefixLength", "<=", "nameLength", ")", "{", "if", "(", "CharOperation", ".", "prefixEquals", "(", "prefix", ",", "name", ",", "false", ")", ")", "{", "if", "(", "prefixLength", ">", "bestLength", ")", "{", "bestLength", "=", "prefixLength", ";", "}", "}", "}", "else", "{", "int", "currLen", "=", "0", ";", "for", "(", ";", "currLen", "<", "nameLength", ";", "currLen", "++", ")", "{", "if", "(", "ScannerHelper", ".", "toLowerCase", "(", "prefix", "[", "currLen", "]", ")", "!=", "ScannerHelper", ".", "toLowerCase", "(", "name", "[", "currLen", "]", ")", ")", "{", "if", "(", "currLen", ">", "bestLength", ")", "{", "bestLength", "=", "currLen", ";", "}", "break", ";", "}", "}", "if", "(", "currLen", "==", "nameLength", "&&", "currLen", ">", "bestLength", ")", "{", "bestLength", "=", "currLen", ";", "}", "}", "}", "if", "(", "bestLength", ">", "0", ")", "{", "if", "(", "bestLength", "==", "nameLength", ")", "{", "withoutPrefixName", "=", "CharOperation", ".", "NO_CHAR", ";", "}", "else", "{", "withoutPrefixName", "=", "CharOperation", ".", "subarray", "(", "name", ",", "bestLength", ",", "nameLength", ")", ";", "}", "}", "}", "return", "withoutPrefixName", ";", "}", "public", "static", "final", "int", "VK_STATIC_FIELD", "=", "1", ";", "public", "static", "final", "int", "VK_INSTANCE_FIELD", "=", "2", ";", "public", "static", "final", "int", "VK_STATIC_FINAL_FIELD", "=", "3", ";", "public", "static", "final", "int", "VK_PARAMETER", "=", "4", ";", "public", "static", "final", "int", "VK_LOCAL", "=", "5", ";", "public", "static", "final", "int", "BK_SIMPLE_NAME", "=", "1", ";", "public", "static", "final", "int", "BK_SIMPLE_TYPE_NAME", "=", "2", ";", "public", "static", "void", "suggestVariableNames", "(", "int", "variableKind", ",", "int", "baseNameKind", ",", "char", "[", "]", "baseName", ",", "IJavaProject", "javaProject", ",", "int", "dim", ",", "char", "[", "]", "internalPrefix", ",", "char", "[", "]", "[", "]", "excluded", ",", "boolean", "evaluateDefault", ",", "INamingRequestor", "requestor", ")", "{", "if", "(", "baseName", "==", "null", "||", "baseName", ".", "length", "==", "0", ")", "return", ";", "Map", "options", ";", "if", "(", "javaProject", "!=", "null", ")", "{", "options", "=", "javaProject", ".", "getOptions", "(", "true", ")", ";", "}", "else", "{", "options", "=", "JavaCore", ".", "getOptions", "(", ")", ";", "}", "CompilerOptions", "compilerOptions", "=", "new", "CompilerOptions", "(", "options", ")", ";", "AssistOptions", "assistOptions", "=", "new", "AssistOptions", "(", "options", ")", ";", "boolean", "isConstantField", "=", "false", ";", "char", "[", "]", "[", "]", "prefixes", "=", "null", ";", "char", "[", "]", "[", "]", "suffixes", "=", "null", ";", "switch", "(", "variableKind", ")", "{", "case", "VK_INSTANCE_FIELD", ":", "prefixes", "=", "assistOptions", ".", "fieldPrefixes", ";", "suffixes", "=", "assistOptions", ".", "fieldSuffixes", ";", "break", ";", "case", "VK_STATIC_FIELD", ":", "prefixes", "=", "assistOptions", ".", "staticFieldPrefixes", ";", "suffixes", "=", "assistOptions", ".", "staticFieldSuffixes", ";", "break", ";", "case", "VK_STATIC_FINAL_FIELD", ":", "isConstantField", "=", "true", ";", "prefixes", "=", "assistOptions", ".", "staticFinalFieldPrefixes", ";", "suffixes", "=", "assistOptions", ".", "staticFinalFieldSuffixes", ";", "break", ";", "case", "VK_LOCAL", ":", "prefixes", "=", "assistOptions", ".", "localPrefixes", ";", "suffixes", "=", "assistOptions", ".", "localSuffixes", ";", "break", ";", "case", "VK_PARAMETER", ":", "prefixes", "=", "assistOptions", ".", "argumentPrefixes", ";", "suffixes", "=", "assistOptions", ".", "argumentSuffixes", ";", "break", ";", "}", "if", "(", "prefixes", "==", "null", "||", "prefixes", ".", "length", "==", "0", ")", "{", "prefixes", "=", "new", "char", "[", "1", "]", "[", "0", "]", ";", "}", "else", "{", "int", "length", "=", "prefixes", ".", "length", ";", "System", ".", "arraycopy", "(", "prefixes", ",", "0", ",", "prefixes", "=", "new", "char", "[", "length", "+", "1", "]", "[", "]", ",", "0", ",", "length", ")", ";", "prefixes", "[", "length", "]", "=", "CharOperation", ".", "NO_CHAR", ";", "}", "if", "(", "suffixes", "==", "null", "||", "suffixes", ".", "length", "==", "0", ")", "{", "suffixes", "=", "new", "char", "[", "1", "]", "[", "0", "]", ";", "}", "else", "{", "int", "length", "=", "suffixes", ".", "length", ";", "System", ".", "arraycopy", "(", "suffixes", ",", "0", ",", "suffixes", "=", "new", "char", "[", "length", "+", "1", "]", "[", "]", ",", "0", ",", "length", ")", ";", "suffixes", "[", "length", "]", "=", "CharOperation", ".", "NO_CHAR", ";", "}", "if", "(", "internalPrefix", "==", "null", ")", "{", "internalPrefix", "=", "CharOperation", ".", "NO_CHAR", ";", "}", "else", "{", "internalPrefix", "=", "removePrefix", "(", "internalPrefix", ",", "prefixes", ")", ";", "}", "char", "[", "]", "[", "]", "tempNames", "=", "null", ";", "Scanner", "nameScanner", "=", "getNameScanner", "(", "compilerOptions", ")", ";", "if", "(", "baseNameKind", "==", "BK_SIMPLE_TYPE_NAME", ")", "{", "boolean", "isBaseType", "=", "false", ";", "try", "{", "nameScanner", ".", "setSource", "(", "baseName", ")", ";", "switch", "(", "nameScanner", ".", "getNextToken", "(", ")", ")", "{", "case", "TerminalTokens", ".", "TokenNameint", ":", "case", "TerminalTokens", ".", "TokenNamebyte", ":", "case", "TerminalTokens", ".", "TokenNameshort", ":", "case", "TerminalTokens", ".", "TokenNamechar", ":", "case", "TerminalTokens", ".", "TokenNamelong", ":", "case", "TerminalTokens", ".", "TokenNamefloat", ":", "case", "TerminalTokens", ".", "TokenNamedouble", ":", "case", "TerminalTokens", ".", "TokenNameboolean", ":", "isBaseType", "=", "true", ";", "break", ";", "}", "}", "catch", "(", "InvalidInputException", "e", ")", "{", "}", "if", "(", "isBaseType", ")", "{", "if", "(", "internalPrefix", ".", "length", ">", "0", ")", "return", ";", "tempNames", "=", "computeBaseTypeNames", "(", "baseName", ",", "isConstantField", ",", "excluded", ")", ";", "}", "else", "{", "tempNames", "=", "computeNonBaseTypeNames", "(", "baseName", ",", "isConstantField", ",", "false", ")", ";", "}", "}", "else", "{", "tempNames", "=", "computeNonBaseTypeNames", "(", "baseName", ",", "isConstantField", ",", "true", ")", ";", "}", "boolean", "acceptDefaultName", "=", "true", ";", "SimpleSetOfCharArray", "foundNames", "=", "new", "SimpleSetOfCharArray", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "tempNames", ".", "length", ";", "i", "++", ")", "{", "char", "[", "]", "tempName", "=", "tempNames", "[", "i", "]", ";", "if", "(", "dim", ">", "0", ")", "{", "int", "length", "=", "tempName", ".", "length", ";", "if", "(", "isConstantField", ")", "{", "if", "(", "tempName", "[", "length", "-", "1", "]", "==", "'S'", ")", "{", "if", "(", "tempName", ".", "length", ">", "1", "&&", "tempName", "[", "length", "-", "2", "]", "==", "'S'", ")", "{", "System", ".", "arraycopy", "(", "tempName", ",", "0", ",", "tempName", "=", "new", "char", "[", "length", "+", "2", "]", ",", "0", ",", "length", ")", ";", "tempName", "[", "length", "]", "=", "'E'", ";", "tempName", "[", "length", "+", "1", "]", "=", "'S'", ";", "}", "}", "else", "if", "(", "tempName", "[", "length", "-", "1", "]", "==", "'Y'", ")", "{", "boolean", "precededByAVowel", "=", "false", ";", "if", "(", "tempName", ".", "length", ">", "1", ")", "{", "switch", "(", "tempName", "[", "length", "-", "2", "]", ")", "{", "case", "'A'", ":", "case", "'E'", ":", "case", "'I'", ":", "case", "'O'", ":", "case", "'U'", ":", "precededByAVowel", "=", "true", ";", "break", ";", "}", "}", "if", "(", "precededByAVowel", ")", "{", "System", ".", "arraycopy", "(", "tempName", ",", "0", ",", "tempName", "=", "new", "char", "[", "length", "+", "1", "]", ",", "0", ",", "length", ")", ";", "tempName", "[", "length", "]", "=", "'S'", ";", "}", "else", "{", "System", ".", "arraycopy", "(", "tempName", ",", "0", ",", "tempName", "=", "new", "char", "[", "length", "+", "2", "]", ",", "0", ",", "length", ")", ";", "tempName", "[", "length", "-", "1", "]", "=", "'I'", ";", "tempName", "[", "length", "]", "=", "'E'", ";", "tempName", "[", "length", "+", "1", "]", "=", "'S'", ";", "}", "}", "else", "{", "System", ".", "arraycopy", "(", "tempName", ",", "0", ",", "tempName", "=", "new", "char", "[", "length", "+", "1", "]", ",", "0", ",", "length", ")", ";", "tempName", "[", "length", "]", "=", "'S'", ";", "}", "}", "else", "{", "if", "(", "tempName", "[", "length", "-", "1", "]", "==", "'s'", ")", "{", "if", "(", "tempName", ".", "length", ">", "1", "&&", "tempName", "[", "length", "-", "2", "]", "==", "'s'", ")", "{", "System", ".", "arraycopy", "(", "tempName", ",", "0", ",", "tempName", "=", "new", "char", "[", "length", "+", "2", "]", ",", "0", ",", "length", ")", ";", "tempName", "[", "length", "]", "=", "'e'", ";", "tempName", "[", "length", "+", "1", "]", "=", "'s'", ";", "}", "}", "else", "if", "(", "tempName", "[", "length", "-", "1", "]", "==", "'y'", ")", "{", "boolean", "precededByAVowel", "=", "false", ";", "if", "(", "tempName", ".", "length", ">", "1", ")", "{", "switch", "(", "tempName", "[", "length", "-", "2", "]", ")", "{", "case", "'a'", ":", "case", "'e'", ":", "case", "'i'", ":", "case", "'o'", ":", "case", "'u'", ":", "precededByAVowel", "=", "true", ";", "break", ";", "}", "}", "if", "(", "precededByAVowel", ")", "{", "System", ".", "arraycopy", "(", "tempName", ",", "0", ",", "tempName", "=", "new", "char", "[", "length", "+", "1", "]", ",", "0", ",", "length", ")", ";", "tempName", "[", "length", "]", "=", "'s'", ";", "}", "else", "{", "System", ".", "arraycopy", "(", "tempName", ",", "0", ",", "tempName", "=", "new", "char", "[", "length", "+", "2", "]", ",", "0", ",", "length", ")", ";", "tempName", "[", "length", "-", "1", "]", "=", "'i'", ";", "tempName", "[", "length", "]", "=", "'e'", ";", "tempName", "[", "length", "+", "1", "]", "=", "'s'", ";", "}", "}", "else", "{", "System", ".", "arraycopy", "(", "tempName", ",", "0", ",", "tempName", "=", "new", "char", "[", "length", "+", "1", "]", ",", "0", ",", "length", ")", ";", "tempName", "[", "length", "]", "=", "'s'", ";", "}", "}", "}", "char", "[", "]", "unprefixedName", "=", "tempName", ";", "int", "matchingIndex", "=", "-", "1", ";", "if", "(", "!", "isConstantField", ")", "{", "unprefixedName", "[", "0", "]", "=", "ScannerHelper", ".", "toUpperCase", "(", "unprefixedName", "[", "0", "]", ")", ";", "done", ":", "for", "(", "int", "j", "=", "0", ";", "j", "<=", "internalPrefix", ".", "length", ";", "j", "++", ")", "{", "if", "(", "j", "==", "internalPrefix", ".", "length", "||", "CharOperation", ".", "prefixEquals", "(", "CharOperation", ".", "subarray", "(", "internalPrefix", ",", "j", ",", "-", "1", ")", ",", "unprefixedName", ",", "j", "!=", "0", ")", ")", "{", "matchingIndex", "=", "j", ";", "break", "done", ";", "}", "}", "}", "else", "{", "done", ":", "for", "(", "int", "j", "=", "0", ";", "j", "<=", "internalPrefix", ".", "length", ";", "j", "++", ")", "{", "if", "(", "j", "==", "internalPrefix", ".", "length", ")", "{", "matchingIndex", "=", "j", ";", "break", "done", ";", "}", "else", "if", "(", "CharOperation", ".", "prefixEquals", "(", "CharOperation", ".", "subarray", "(", "internalPrefix", ",", "j", ",", "-", "1", ")", ",", "unprefixedName", ",", "j", "!=", "0", ")", ")", "{", "if", "(", "j", "==", "0", "||", "internalPrefix", "[", "j", "-", "1", "]", "==", "'_'", ")", "{", "matchingIndex", "=", "j", ";", "break", "done", ";", "}", "}", "}", "}", "if", "(", "matchingIndex", ">", "-", "1", ")", "{", "if", "(", "!", "isConstantField", ")", "{", "tempName", "=", "CharOperation", ".", "concat", "(", "CharOperation", ".", "subarray", "(", "internalPrefix", ",", "0", ",", "matchingIndex", ")", ",", "unprefixedName", ")", ";", "if", "(", "matchingIndex", "==", "0", ")", "tempName", "[", "0", "]", "=", "ScannerHelper", ".", "toLowerCase", "(", "tempName", "[", "0", "]", ")", ";", "}", "else", "{", "if", "(", "matchingIndex", "!=", "0", "&&", "tempName", "[", "0", "]", "!=", "'_'", "&&", "internalPrefix", "[", "matchingIndex", "-", "1", "]", "!=", "'_'", ")", "{", "tempName", "=", "CharOperation", ".", "concat", "(", "CharOperation", ".", "subarray", "(", "CharOperation", ".", "toUpperCase", "(", "internalPrefix", ")", ",", "0", ",", "matchingIndex", ")", ",", "unprefixedName", ",", "'_'", ")", ";", "}", "else", "{", "tempName", "=", "CharOperation", ".", "concat", "(", "CharOperation", ".", "subarray", "(", "CharOperation", ".", "toUpperCase", "(", "internalPrefix", ")", ",", "0", ",", "matchingIndex", ")", ",", "unprefixedName", ")", ";", "}", "}", "for", "(", "int", "k", "=", "0", ";", "k", "<", "prefixes", ".", "length", ";", "k", "++", ")", "{", "if", "(", "!", "isConstantField", ")", "{", "if", "(", "prefixes", "[", "k", "]", ".", "length", ">", "0", "&&", "ScannerHelper", ".", "isLetterOrDigit", "(", "prefixes", "[", "k", "]", "[", "prefixes", "[", "k", "]", ".", "length", "-", "1", "]", ")", ")", "{", "tempName", "[", "0", "]", "=", "ScannerHelper", ".", "toUpperCase", "(", "tempName", "[", "0", "]", ")", ";", "}", "else", "{", "tempName", "[", "0", "]", "=", "ScannerHelper", ".", "toLowerCase", "(", "tempName", "[", "0", "]", ")", ";", "}", "}", "char", "[", "]", "prefixName", "=", "CharOperation", ".", "concat", "(", "prefixes", "[", "k", "]", ",", "tempName", ")", ";", "for", "(", "int", "l", "=", "0", ";", "l", "<", "suffixes", ".", "length", ";", "l", "++", ")", "{", "char", "[", "]", "suffixName", "=", "CharOperation", ".", "concat", "(", "prefixName", ",", "suffixes", "[", "l", "]", ")", ";", "suffixName", "=", "excludeNames", "(", "suffixName", ",", "prefixName", ",", "suffixes", "[", "l", "]", ",", "excluded", ")", ";", "try", "{", "nameScanner", ".", "setSource", "(", "suffixName", ")", ";", "switch", "(", "nameScanner", ".", "getNextToken", "(", ")", ")", "{", "case", "TerminalTokens", ".", "TokenNameIdentifier", ":", "int", "token", "=", "nameScanner", ".", "getNextToken", "(", ")", ";", "if", "(", "token", "==", "TerminalTokens", ".", "TokenNameEOF", "&&", "nameScanner", ".", "startPosition", "==", "suffixName", ".", "length", ")", "{", "if", "(", "!", "foundNames", ".", "includes", "(", "suffixName", ")", ")", "{", "acceptName", "(", "suffixName", ",", "prefixes", "[", "k", "]", ",", "suffixes", "[", "l", "]", ",", "k", "==", "0", ",", "l", "==", "0", ",", "internalPrefix", ".", "length", "-", "matchingIndex", ",", "requestor", ")", ";", "foundNames", ".", "add", "(", "suffixName", ")", ";", "acceptDefaultName", "=", "false", ";", "}", "}", "break", ";", "default", ":", "suffixName", "=", "CharOperation", ".", "concat", "(", "prefixName", ",", "String", ".", "valueOf", "(", "1", ")", ".", "toCharArray", "(", ")", ",", "suffixes", "[", "l", "]", ")", ";", "suffixName", "=", "excludeNames", "(", "suffixName", ",", "prefixName", ",", "suffixes", "[", "l", "]", ",", "excluded", ")", ";", "nameScanner", ".", "setSource", "(", "suffixName", ")", ";", "switch", "(", "nameScanner", ".", "getNextToken", "(", ")", ")", "{", "case", "TerminalTokens", ".", "TokenNameIdentifier", ":", "token", "=", "nameScanner", ".", "getNextToken", "(", ")", ";", "if", "(", "token", "==", "TerminalTokens", ".", "TokenNameEOF", "&&", "nameScanner", ".", "startPosition", "==", "suffixName", ".", "length", ")", "{", "if", "(", "!", "foundNames", ".", "includes", "(", "suffixName", ")", ")", "{", "acceptName", "(", "suffixName", ",", "prefixes", "[", "k", "]", ",", "suffixes", "[", "l", "]", ",", "k", "==", "0", ",", "l", "==", "0", ",", "internalPrefix", ".", "length", "-", "matchingIndex", ",", "requestor", ")", ";", "foundNames", ".", "add", "(", "suffixName", ")", ";", "acceptDefaultName", "=", "false", ";", "}", "}", "}", "}", "}", "catch", "(", "InvalidInputException", "e", ")", "{", "}", "}", "}", "}", "}", "if", "(", "evaluateDefault", "&&", "acceptDefaultName", ")", "{", "char", "[", "]", "name", "=", "excludeNames", "(", "DEFAULT_NAME", ",", "DEFAULT_NAME", ",", "CharOperation", ".", "NO_CHAR", ",", "excluded", ")", ";", "requestor", ".", "acceptNameWithoutPrefixAndSuffix", "(", "name", ",", "0", ")", ";", "}", "}", "}", "</s>" ]
5,533
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "*", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "CoreException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatusConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IOpenable", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IPackageFragment", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Messages", ";", "public", "class", "DeleteResourceElementsOperation", "extends", "MultiOperation", "{", "protected", "DeleteResourceElementsOperation", "(", "IJavaElement", "[", "]", "elementsToProcess", ",", "boolean", "force", ")", "{", "super", "(", "elementsToProcess", ",", "force", ")", ";", "}", "private", "void", "deletePackageFragment", "(", "IPackageFragment", "frag", ")", "throws", "JavaModelException", "{", "IResource", "res", "=", "(", "(", "JavaElement", ")", "frag", ")", ".", "resource", "(", ")", ";", "if", "(", "res", "!=", "null", ")", "{", "IJavaElement", "[", "]", "childrenOfInterest", "=", "frag", ".", "getChildren", "(", ")", ";", "if", "(", "childrenOfInterest", ".", "length", ">", "0", ")", "{", "IResource", "[", "]", "resources", "=", "new", "IResource", "[", "childrenOfInterest", ".", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "childrenOfInterest", ".", "length", ";", "i", "++", ")", "{", "resources", "[", "i", "]", "=", "(", "(", "JavaElement", ")", "childrenOfInterest", "[", "i", "]", ")", ".", "resource", "(", ")", ";", "}", "deleteResources", "(", "resources", ",", "this", ".", "force", ")", ";", "}", "Object", "[", "]", "nonJavaResources", "=", "frag", ".", "getNonJavaResources", "(", ")", ";", "int", "actualResourceCount", "=", "0", ";", "for", "(", "int", "i", "=", "0", ",", "max", "=", "nonJavaResources", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "nonJavaResources", "[", "i", "]", "instanceof", "IResource", ")", "actualResourceCount", "++", ";", "}", "IResource", "[", "]", "actualNonJavaResources", "=", "new", "IResource", "[", "actualResourceCount", "]", ";", "for", "(", "int", "i", "=", "0", ",", "max", "=", "nonJavaResources", ".", "length", ",", "index", "=", "0", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "nonJavaResources", "[", "i", "]", "instanceof", "IResource", ")", "actualNonJavaResources", "[", "index", "++", "]", "=", "(", "IResource", ")", "nonJavaResources", "[", "i", "]", ";", "}", "deleteResources", "(", "actualNonJavaResources", ",", "this", ".", "force", ")", ";", "IResource", "[", "]", "remainingFiles", ";", "try", "{", "remainingFiles", "=", "(", "(", "IContainer", ")", "res", ")", ".", "members", "(", ")", ";", "}", "catch", "(", "CoreException", "ce", ")", "{", "throw", "new", "JavaModelException", "(", "ce", ")", ";", "}", "boolean", "isEmpty", "=", "true", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "remainingFiles", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "IResource", "file", "=", "remainingFiles", "[", "i", "]", ";", "if", "(", "file", "instanceof", "IFile", "&&", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "Util", ".", "isClassFileName", "(", "file", ".", "getName", "(", ")", ")", ")", "{", "deleteResource", "(", "file", ",", "IResource", ".", "FORCE", "|", "IResource", ".", "KEEP_HISTORY", ")", ";", "}", "else", "{", "isEmpty", "=", "false", ";", "}", "}", "if", "(", "isEmpty", "&&", "!", "frag", ".", "isDefaultPackage", "(", ")", ")", "{", "IResource", "fragResource", "=", "(", "(", "JavaElement", ")", "frag", ")", ".", "resource", "(", ")", ";", "if", "(", "fragResource", "!=", "null", ")", "{", "deleteEmptyPackageFragment", "(", "frag", ",", "false", ",", "fragResource", ".", "getParent", "(", ")", ")", ";", "}", "}", "}", "}", "protected", "String", "getMainTaskName", "(", ")", "{", "return", "Messages", ".", "operation_deleteResourceProgress", ";", "}", "protected", "void", "processElement", "(", "IJavaElement", "element", ")", "throws", "JavaModelException", "{", "switch", "(", "element", ".", "getElementType", "(", ")", ")", "{", "case", "IJavaElement", ".", "CLASS_FILE", ":", "case", "IJavaElement", ".", "COMPILATION_UNIT", ":", "deleteResource", "(", "element", ".", "getResource", "(", ")", ",", "this", ".", "force", "?", "IResource", ".", "FORCE", "|", "IResource", ".", "KEEP_HISTORY", ":", "IResource", ".", "KEEP_HISTORY", ")", ";", "break", ";", "case", "IJavaElement", ".", "PACKAGE_FRAGMENT", ":", "deletePackageFragment", "(", "(", "IPackageFragment", ")", "element", ")", ";", "break", ";", "default", ":", "throw", "new", "JavaModelException", "(", "new", "JavaModelStatus", "(", "IJavaModelStatusConstants", ".", "INVALID_ELEMENT_TYPES", ",", "element", ")", ")", ";", "}", "if", "(", "element", "instanceof", "IOpenable", ")", "{", "(", "(", "IOpenable", ")", "element", ")", ".", "close", "(", ")", ";", "}", "}", "protected", "void", "verify", "(", "IJavaElement", "element", ")", "throws", "JavaModelException", "{", "if", "(", "element", "==", "null", "||", "!", "element", ".", "exists", "(", ")", ")", "error", "(", "IJavaModelStatusConstants", ".", "ELEMENT_DOES_NOT_EXIST", ",", "element", ")", ";", "int", "type", "=", "element", ".", "getElementType", "(", ")", ";", "if", "(", "type", "<=", "IJavaElement", ".", "PACKAGE_FRAGMENT_ROOT", "||", "type", ">", "IJavaElement", ".", "COMPILATION_UNIT", ")", "error", "(", "IJavaModelStatusConstants", ".", "INVALID_ELEMENT_TYPES", ",", "element", ")", ";", "else", "if", "(", "type", "==", "IJavaElement", ".", "PACKAGE_FRAGMENT", "&&", "element", "instanceof", "JarPackageFragment", ")", "error", "(", "IJavaModelStatusConstants", ".", "INVALID_ELEMENT_TYPES", ",", "element", ")", ";", "IResource", "resource", "=", "(", "(", "JavaElement", ")", "element", ")", ".", "resource", "(", ")", ";", "if", "(", "resource", "instanceof", "IFolder", ")", "{", "if", "(", "resource", ".", "isLinked", "(", ")", ")", "{", "error", "(", "IJavaModelStatusConstants", ".", "INVALID_RESOURCE", ",", "element", ")", ";", "}", "}", "}", "}", "</s>" ]
5,534
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CategorizedProblem", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AbstractMethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Annotation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Expression", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "FieldDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ImportReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "public", "interface", "ISourceElementRequestor", "{", "public", "static", "class", "TypeInfo", "{", "public", "int", "declarationStart", ";", "public", "int", "modifiers", ";", "public", "char", "[", "]", "name", ";", "public", "int", "nameSourceStart", ";", "public", "int", "nameSourceEnd", ";", "public", "char", "[", "]", "superclass", ";", "public", "char", "[", "]", "[", "]", "superinterfaces", ";", "public", "TypeParameterInfo", "[", "]", "typeParameters", ";", "public", "char", "[", "]", "[", "]", "categories", ";", "public", "boolean", "secondary", ";", "public", "boolean", "anonymousMember", ";", "public", "Annotation", "[", "]", "annotations", ";", "public", "int", "extraFlags", ";", "public", "TypeDeclaration", "node", ";", "public", "HashMap", "childrenCategories", "=", "new", "HashMap", "(", ")", ";", "}", "public", "static", "class", "TypeParameterInfo", "{", "public", "int", "declarationStart", ";", "public", "int", "declarationEnd", ";", "public", "char", "[", "]", "name", ";", "public", "int", "nameSourceStart", ";", "public", "int", "nameSourceEnd", ";", "public", "char", "[", "]", "[", "]", "bounds", ";", "}", "public", "static", "class", "MethodInfo", "{", "public", "boolean", "isConstructor", ";", "public", "boolean", "isAnnotation", ";", "public", "int", "declarationStart", ";", "public", "int", "modifiers", ";", "public", "char", "[", "]", "returnType", ";", "public", "char", "[", "]", "name", ";", "public", "int", "nameSourceStart", ";", "public", "int", "nameSourceEnd", ";", "public", "char", "[", "]", "[", "]", "parameterTypes", ";", "public", "char", "[", "]", "[", "]", "parameterNames", ";", "public", "char", "[", "]", "[", "]", "exceptionTypes", ";", "public", "TypeParameterInfo", "[", "]", "typeParameters", ";", "public", "char", "[", "]", "[", "]", "categories", ";", "public", "Annotation", "[", "]", "annotations", ";", "public", "char", "[", "]", "declaringPackageName", ";", "public", "int", "declaringTypeModifiers", ";", "public", "int", "extraFlags", ";", "public", "AbstractMethodDeclaration", "node", ";", "}", "public", "static", "class", "FieldInfo", "{", "public", "int", "declarationStart", ";", "public", "int", "modifiers", ";", "public", "char", "[", "]", "type", ";", "public", "char", "[", "]", "name", ";", "public", "int", "nameSourceStart", ";", "public", "int", "nameSourceEnd", ";", "public", "char", "[", "]", "[", "]", "categories", ";", "public", "Annotation", "[", "]", "annotations", ";", "public", "FieldDeclaration", "node", ";", "}", "void", "acceptAnnotationTypeReference", "(", "char", "[", "]", "[", "]", "annotation", ",", "int", "sourceStart", ",", "int", "sourceEnd", ")", ";", "void", "acceptAnnotationTypeReference", "(", "char", "[", "]", "annotation", ",", "int", "sourcePosition", ")", ";", "void", "acceptConstructorReference", "(", "char", "[", "]", "typeName", ",", "int", "argCount", ",", "int", "sourcePosition", ")", ";", "void", "acceptFieldReference", "(", "char", "[", "]", "fieldName", ",", "int", "sourcePosition", ")", ";", "void", "acceptImport", "(", "int", "declarationStart", ",", "int", "declarationEnd", ",", "char", "[", "]", "[", "]", "tokens", ",", "boolean", "onDemand", ",", "int", "modifiers", ")", ";", "void", "acceptLineSeparatorPositions", "(", "int", "[", "]", "positions", ")", ";", "void", "acceptMethodReference", "(", "char", "[", "]", "methodName", ",", "int", "argCount", ",", "int", "sourcePosition", ")", ";", "void", "acceptPackage", "(", "ImportReference", "importReference", ")", ";", "void", "acceptProblem", "(", "CategorizedProblem", "problem", ")", ";", "void", "acceptTypeReference", "(", "char", "[", "]", "[", "]", "typeName", ",", "int", "sourceStart", ",", "int", "sourceEnd", ")", ";", "void", "acceptTypeReference", "(", "char", "[", "]", "typeName", ",", "int", "sourcePosition", ")", ";", "void", "acceptUnknownReference", "(", "char", "[", "]", "[", "]", "name", ",", "int", "sourceStart", ",", "int", "sourceEnd", ")", ";", "void", "acceptUnknownReference", "(", "char", "[", "]", "name", ",", "int", "sourcePosition", ")", ";", "void", "enterCompilationUnit", "(", ")", ";", "void", "enterConstructor", "(", "MethodInfo", "methodInfo", ")", ";", "void", "enterField", "(", "FieldInfo", "fieldInfo", ")", ";", "void", "enterInitializer", "(", "int", "declarationStart", ",", "int", "modifiers", ")", ";", "void", "enterMethod", "(", "MethodInfo", "methodInfo", ")", ";", "void", "enterType", "(", "TypeInfo", "typeInfo", ")", ";", "void", "exitCompilationUnit", "(", "int", "declarationEnd", ")", ";", "void", "exitConstructor", "(", "int", "declarationEnd", ")", ";", "void", "exitField", "(", "int", "initializationStart", ",", "int", "declarationEnd", ",", "int", "declarationSourceEnd", ")", ";", "void", "exitInitializer", "(", "int", "declarationEnd", ")", ";", "void", "exitMethod", "(", "int", "declarationEnd", ",", "Expression", "defaultValue", ")", ";", "void", "exitType", "(", "int", "declarationEnd", ")", ";", "}", "</s>" ]
5,535
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CategorizedProblem", ";", "public", "interface", "IDocumentElementRequestor", "{", "void", "acceptImport", "(", "int", "declarationStart", ",", "int", "declarationEnd", ",", "int", "[", "]", "javaDocPositions", ",", "char", "[", "]", "name", ",", "int", "nameStartPosition", ",", "boolean", "onDemand", ",", "int", "modifiers", ")", ";", "void", "acceptInitializer", "(", "int", "declarationStart", ",", "int", "declarationEnd", ",", "int", "[", "]", "javaDocPositions", ",", "int", "modifiers", ",", "int", "modifiersStart", ",", "int", "bodyStart", ",", "int", "bodyEnd", ")", ";", "void", "acceptLineSeparatorPositions", "(", "int", "[", "]", "positions", ")", ";", "void", "acceptPackage", "(", "int", "declarationStart", ",", "int", "declarationEnd", ",", "int", "[", "]", "javaDocPositions", ",", "char", "[", "]", "name", ",", "int", "nameStartPosition", ")", ";", "void", "acceptProblem", "(", "CategorizedProblem", "problem", ")", ";", "void", "enterClass", "(", "int", "declarationStart", ",", "int", "[", "]", "javaDocPositions", ",", "int", "modifiers", ",", "int", "modifiersStart", ",", "int", "classStart", ",", "char", "[", "]", "name", ",", "int", "nameStart", ",", "int", "nameEnd", ",", "char", "[", "]", "superclass", ",", "int", "superclassStart", ",", "int", "superclassEnd", ",", "char", "[", "]", "[", "]", "superinterfaces", ",", "int", "[", "]", "superinterfaceStarts", ",", "int", "[", "]", "superinterfaceEnds", ",", "int", "bodyStart", ")", ";", "void", "enterCompilationUnit", "(", ")", ";", "void", "enterConstructor", "(", "int", "declarationStart", ",", "int", "[", "]", "javaDocPositions", ",", "int", "modifiers", ",", "int", "modifiersStart", ",", "char", "[", "]", "name", ",", "int", "nameStart", ",", "int", "nameEnd", ",", "char", "[", "]", "[", "]", "parameterTypes", ",", "int", "[", "]", "parameterTypeStarts", ",", "int", "[", "]", "parameterTypeEnds", ",", "char", "[", "]", "[", "]", "parameterNames", ",", "int", "[", "]", "parameterNameStarts", ",", "int", "[", "]", "parameterNameEnds", ",", "int", "parametersEnd", ",", "char", "[", "]", "[", "]", "exceptionTypes", ",", "int", "[", "]", "exceptionTypeStarts", ",", "int", "[", "]", "exceptionTypeEnds", ",", "int", "bodyStart", ")", ";", "void", "enterField", "(", "int", "declarationStart", ",", "int", "[", "]", "javaDocPositions", ",", "int", "modifiers", ",", "int", "modifiersStart", ",", "char", "[", "]", "type", ",", "int", "typeStart", ",", "int", "typeEnd", ",", "int", "typeDimensionCount", ",", "char", "[", "]", "name", ",", "int", "nameStart", ",", "int", "nameEnd", ",", "int", "extendedTypeDimensionCount", ",", "int", "extendedTypeDimensionEnd", ")", ";", "void", "enterInterface", "(", "int", "declarationStart", ",", "int", "[", "]", "javaDocPositions", ",", "int", "modifiers", ",", "int", "modifiersStart", ",", "int", "interfaceStart", ",", "char", "[", "]", "name", ",", "int", "nameStart", ",", "int", "nameEnd", ",", "char", "[", "]", "[", "]", "superinterfaces", ",", "int", "[", "]", "superinterfaceStarts", ",", "int", "[", "]", "superinterfaceEnds", ",", "int", "bodyStart", ")", ";", "void", "enterMethod", "(", "int", "declarationStart", ",", "int", "[", "]", "javaDocPositions", ",", "int", "modifiers", ",", "int", "modifiersStart", ",", "char", "[", "]", "returnType", ",", "int", "returnTypeStart", ",", "int", "returnTypeEnd", ",", "int", "returnTypeDimensionCount", ",", "char", "[", "]", "name", ",", "int", "nameStart", ",", "int", "nameEnd", ",", "char", "[", "]", "[", "]", "parameterTypes", ",", "int", "[", "]", "parameterTypeStarts", ",", "int", "[", "]", "parameterTypeEnds", ",", "char", "[", "]", "[", "]", "parameterNames", ",", "int", "[", "]", "parameterNameStarts", ",", "int", "[", "]", "parameterNameEnds", ",", "int", "parametersEnd", ",", "int", "extendedReturnTypeDimensionCount", ",", "int", "extendedReturnTypeDimensionEnd", ",", "char", "[", "]", "[", "]", "exceptionTypes", ",", "int", "[", "]", "exceptionTypeStarts", ",", "int", "[", "]", "exceptionTypeEnds", ",", "int", "bodyStart", ")", ";", "void", "exitClass", "(", "int", "bodyEnd", ",", "int", "declarationEnd", ")", ";", "void", "exitCompilationUnit", "(", "int", "declarationEnd", ")", ";", "void", "exitConstructor", "(", "int", "bodyEnd", ",", "int", "declarationEnd", ")", ";", "void", "exitField", "(", "int", "bodyEnd", ",", "int", "declarationEnd", ")", ";", "void", "exitInterface", "(", "int", "bodyEnd", ",", "int", "declarationEnd", ")", ";", "void", "exitMethod", "(", "int", "bodyEnd", ",", "int", "declarationEnd", ")", ";", "}", "</s>" ]
5,536
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "parser", ".", "JavadocParser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "parser", ".", "Parser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "parser", ".", "ScannerHelper", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "parser", ".", "TerminalTokens", ";", "public", "class", "SourceJavadocParser", "extends", "JavadocParser", "{", "int", "categoriesPtr", "=", "-", "1", ";", "char", "[", "]", "[", "]", "categories", "=", "CharOperation", ".", "NO_CHAR_CHAR", ";", "public", "SourceJavadocParser", "(", "Parser", "sourceParser", ")", "{", "super", "(", "sourceParser", ")", ";", "this", ".", "kind", "=", "SOURCE_PARSER", "|", "TEXT_VERIF", ";", "}", "public", "boolean", "checkDeprecation", "(", "int", "commentPtr", ")", "{", "this", ".", "categoriesPtr", "=", "-", "1", ";", "boolean", "result", "=", "super", ".", "checkDeprecation", "(", "commentPtr", ")", ";", "if", "(", "this", ".", "categoriesPtr", ">", "-", "1", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "categories", ",", "0", ",", "this", ".", "categories", "=", "new", "char", "[", "this", ".", "categoriesPtr", "+", "1", "]", "[", "]", ",", "0", ",", "this", ".", "categoriesPtr", "+", "1", ")", ";", "}", "else", "{", "this", ".", "categories", "=", "CharOperation", ".", "NO_CHAR_CHAR", ";", "}", "return", "result", ";", "}", "protected", "boolean", "parseIdentifierTag", "(", "boolean", "report", ")", "{", "int", "end", "=", "this", ".", "lineEnd", "+", "1", ";", "if", "(", "super", ".", "parseIdentifierTag", "(", "report", ")", "&&", "this", ".", "index", "<=", "end", ")", "{", "if", "(", "this", ".", "tagValue", "==", "TAG_CATEGORY_VALUE", ")", "{", "int", "length", "=", "this", ".", "categories", ".", "length", ";", "if", "(", "++", "this", ".", "categoriesPtr", ">=", "length", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "categories", ",", "0", ",", "this", ".", "categories", "=", "new", "char", "[", "length", "+", "5", "]", "[", "]", ",", "0", ",", "length", ")", ";", "length", "+=", "5", ";", "}", "this", ".", "categories", "[", "this", ".", "categoriesPtr", "]", "=", "this", ".", "identifierStack", "[", "this", ".", "identifierPtr", "--", "]", ";", "consumeToken", "(", ")", ";", "while", "(", "this", ".", "index", "<", "end", ")", "{", "if", "(", "readTokenSafely", "(", ")", "==", "TerminalTokens", ".", "TokenNameIdentifier", "&&", "(", "this", ".", "scanner", ".", "currentCharacter", "==", "'", "'", "||", "ScannerHelper", ".", "isWhitespace", "(", "this", ".", "scanner", ".", "currentCharacter", ")", ")", ")", "{", "if", "(", "this", ".", "index", ">", "(", "this", ".", "lineEnd", "+", "1", ")", ")", "break", ";", "if", "(", "++", "this", ".", "categoriesPtr", ">=", "length", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "categories", ",", "0", ",", "this", ".", "categories", "=", "new", "char", "[", "length", "+", "5", "]", "[", "]", ",", "0", ",", "length", ")", ";", "length", "+=", "5", ";", "}", "this", ".", "categories", "[", "this", ".", "categoriesPtr", "]", "=", "this", ".", "scanner", ".", "getCurrentIdentifierSource", "(", ")", ";", "consumeToken", "(", ")", ";", "}", "else", "{", "break", ";", "}", "}", "this", ".", "index", "=", "end", ";", "this", ".", "scanner", ".", "currentPosition", "=", "end", ";", "consumeToken", "(", ")", ";", "}", "return", "true", ";", "}", "return", "false", ";", "}", "protected", "void", "parseSimpleTag", "(", ")", "{", "char", "first", "=", "this", ".", "source", "[", "this", ".", "index", "++", "]", ";", "if", "(", "first", "==", "'\\\\'", "&&", "this", ".", "source", "[", "this", ".", "index", "]", "==", "'u'", ")", "{", "int", "c1", ",", "c2", ",", "c3", ",", "c4", ";", "int", "pos", "=", "this", ".", "index", ";", "this", ".", "index", "++", ";", "while", "(", "this", ".", "source", "[", "this", ".", "index", "]", "==", "'u'", ")", "this", ".", "index", "++", ";", "if", "(", "!", "(", "(", "(", "c1", "=", "ScannerHelper", ".", "getNumericValue", "(", "this", ".", "source", "[", "this", ".", "index", "++", "]", ")", ")", ">", "15", "||", "c1", "<", "0", ")", "||", "(", "(", "c2", "=", "ScannerHelper", ".", "getNumericValue", "(", "this", ".", "source", "[", "this", ".", "index", "++", "]", ")", ")", ">", "15", "||", "c2", "<", "0", ")", "||", "(", "(", "c3", "=", "ScannerHelper", ".", "getNumericValue", "(", "this", ".", "source", "[", "this", ".", "index", "++", "]", ")", ")", ">", "15", "||", "c3", "<", "0", ")", "||", "(", "(", "c4", "=", "ScannerHelper", ".", "getNumericValue", "(", "this", ".", "source", "[", "this", ".", "index", "++", "]", ")", ")", ">", "15", "||", "c4", "<", "0", ")", ")", ")", "{", "first", "=", "(", "char", ")", "(", "(", "(", "c1", "*", "16", "+", "c2", ")", "*", "16", "+", "c3", ")", "*", "16", "+", "c4", ")", ";", "}", "else", "{", "this", ".", "index", "=", "pos", ";", "}", "}", "switch", "(", "first", ")", "{", "case", "'d'", ":", "if", "(", "(", "readChar", "(", ")", "==", "'e'", ")", "&&", "(", "readChar", "(", ")", "==", "'p'", ")", "&&", "(", "readChar", "(", ")", "==", "'r'", ")", "&&", "(", "readChar", "(", ")", "==", "'e'", ")", "&&", "(", "readChar", "(", ")", "==", "'c'", ")", "&&", "(", "readChar", "(", ")", "==", "'a'", ")", "&&", "(", "readChar", "(", ")", "==", "'t'", ")", "&&", "(", "readChar", "(", ")", "==", "'e'", ")", "&&", "(", "readChar", "(", ")", "==", "'d'", ")", ")", "{", "char", "c", "=", "readChar", "(", ")", ";", "if", "(", "ScannerHelper", ".", "isWhitespace", "(", "c", ")", "||", "c", "==", "'*'", ")", "{", "this", ".", "tagValue", "=", "TAG_DEPRECATED_VALUE", ";", "this", ".", "deprecated", "=", "true", ";", "}", "}", "break", ";", "case", "'c'", ":", "if", "(", "(", "readChar", "(", ")", "==", "'a'", ")", "&&", "(", "readChar", "(", ")", "==", "'t'", ")", "&&", "(", "readChar", "(", ")", "==", "'e'", ")", "&&", "(", "readChar", "(", ")", "==", "'g'", ")", "&&", "(", "readChar", "(", ")", "==", "'o'", ")", "&&", "(", "readChar", "(", ")", "==", "'r'", ")", "&&", "(", "readChar", "(", ")", "==", "'y'", ")", ")", "{", "char", "c", "=", "readChar", "(", ")", ";", "if", "(", "ScannerHelper", ".", "isWhitespace", "(", "c", ")", "||", "c", "==", "'*'", ")", "{", "this", ".", "tagValue", "=", "TAG_CATEGORY_VALUE", ";", "if", "(", "this", ".", "scanner", ".", "source", "==", "null", ")", "{", "this", ".", "scanner", ".", "setSource", "(", "this", ".", "source", ")", ";", "}", "this", ".", "scanner", ".", "resetTo", "(", "this", ".", "index", ",", "this", ".", "scanner", ".", "eofPosition", ")", ";", "parseIdentifierTag", "(", "false", ")", ";", "}", "}", "break", ";", "}", "}", "}", "</s>" ]
5,537
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IProgressMonitor", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "OperationCanceledException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "HashtableOfObjectToInt", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "CommentRecorderParser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Messages", ";", "public", "class", "SourceElementParser", "extends", "CommentRecorderParser", "{", "ISourceElementRequestor", "requestor", ";", "boolean", "reportReferenceInfo", ";", "boolean", "reportLocalDeclarations", ";", "HashtableOfObjectToInt", "sourceEnds", "=", "new", "HashtableOfObjectToInt", "(", ")", ";", "HashMap", "nodesToCategories", "=", "new", "HashMap", "(", ")", ";", "boolean", "useSourceJavadocParser", "=", "true", ";", "SourceElementNotifier", "notifier", ";", "public", "SourceElementParser", "(", "final", "ISourceElementRequestor", "requestor", ",", "IProblemFactory", "problemFactory", ",", "CompilerOptions", "options", ",", "boolean", "reportLocalDeclarations", ",", "boolean", "optimizeStringLiterals", ")", "{", "this", "(", "requestor", ",", "problemFactory", ",", "options", ",", "reportLocalDeclarations", ",", "optimizeStringLiterals", ",", "true", ")", ";", "}", "public", "SourceElementParser", "(", "ISourceElementRequestor", "requestor", ",", "IProblemFactory", "problemFactory", ",", "CompilerOptions", "options", ",", "boolean", "reportLocalDeclarations", ",", "boolean", "optimizeStringLiterals", ",", "boolean", "useSourceJavadocParser", ")", "{", "super", "(", "new", "ProblemReporter", "(", "DefaultErrorHandlingPolicies", ".", "exitAfterAllProblems", "(", ")", ",", "options", ",", "problemFactory", ")", ",", "optimizeStringLiterals", ")", ";", "this", ".", "reportLocalDeclarations", "=", "reportLocalDeclarations", ";", "this", ".", "problemReporter", "=", "new", "ProblemReporter", "(", "DefaultErrorHandlingPolicies", ".", "exitAfterAllProblems", "(", ")", ",", "options", ",", "problemFactory", ")", "{", "public", "void", "record", "(", "CategorizedProblem", "problem", ",", "CompilationResult", "unitResult", ",", "ReferenceContext", "context", ")", "{", "unitResult", ".", "record", "(", "problem", ",", "context", ")", ";", "SourceElementParser", ".", "this", ".", "requestor", ".", "acceptProblem", "(", "problem", ")", ";", "}", "}", ";", "this", ".", "requestor", "=", "requestor", ";", "this", ".", "options", "=", "options", ";", "this", ".", "notifier", "=", "new", "SourceElementNotifier", "(", "this", ".", "requestor", ",", "reportLocalDeclarations", ")", ";", "this", ".", "useSourceJavadocParser", "=", "useSourceJavadocParser", ";", "if", "(", "useSourceJavadocParser", ")", "{", "this", ".", "javadocParser", "=", "new", "SourceJavadocParser", "(", "this", ")", ";", "}", "}", "private", "void", "acceptJavadocTypeReference", "(", "Expression", "expression", ")", "{", "if", "(", "expression", "instanceof", "JavadocSingleTypeReference", ")", "{", "JavadocSingleTypeReference", "singleRef", "=", "(", "JavadocSingleTypeReference", ")", "expression", ";", "this", ".", "requestor", ".", "acceptTypeReference", "(", "singleRef", ".", "token", ",", "singleRef", ".", "sourceStart", ")", ";", "}", "else", "if", "(", "expression", "instanceof", "JavadocQualifiedTypeReference", ")", "{", "JavadocQualifiedTypeReference", "qualifiedRef", "=", "(", "JavadocQualifiedTypeReference", ")", "expression", ";", "this", ".", "requestor", ".", "acceptTypeReference", "(", "qualifiedRef", ".", "tokens", ",", "qualifiedRef", ".", "sourceStart", ",", "qualifiedRef", ".", "sourceEnd", ")", ";", "}", "}", "public", "void", "addUnknownRef", "(", "NameReference", "nameRef", ")", "{", "if", "(", "nameRef", "instanceof", "SingleNameReference", ")", "{", "this", ".", "requestor", ".", "acceptUnknownReference", "(", "(", "(", "SingleNameReference", ")", "nameRef", ")", ".", "token", ",", "nameRef", ".", "sourceStart", ")", ";", "}", "else", "{", "this", ".", "requestor", ".", "acceptUnknownReference", "(", "(", "(", "QualifiedNameReference", ")", "nameRef", ")", ".", "tokens", ",", "nameRef", ".", "sourceStart", ",", "nameRef", ".", "sourceEnd", ")", ";", "}", "}", "public", "void", "checkComment", "(", ")", "{", "if", "(", "!", "(", "this", ".", "diet", "&&", "this", ".", "dietInt", "==", "0", ")", "&&", "this", ".", "scanner", ".", "commentPtr", ">=", "0", ")", "{", "flushCommentsDefinedPriorTo", "(", "this", ".", "endStatementPosition", ")", ";", "}", "int", "lastComment", "=", "this", ".", "scanner", ".", "commentPtr", ";", "if", "(", "this", ".", "modifiersSourceStart", ">=", "0", ")", "{", "while", "(", "lastComment", ">=", "0", ")", "{", "int", "commentSourceStart", "=", "this", ".", "scanner", ".", "commentStarts", "[", "lastComment", "]", ";", "if", "(", "commentSourceStart", "<", "0", ")", "commentSourceStart", "=", "-", "commentSourceStart", ";", "if", "(", "commentSourceStart", "<=", "this", ".", "modifiersSourceStart", ")", "break", ";", "lastComment", "--", ";", "}", "}", "if", "(", "lastComment", ">=", "0", ")", "{", "this", ".", "modifiersSourceStart", "=", "this", ".", "scanner", ".", "commentStarts", "[", "0", "]", ";", "if", "(", "this", ".", "modifiersSourceStart", "<", "0", ")", "this", ".", "modifiersSourceStart", "=", "-", "this", ".", "modifiersSourceStart", ";", "while", "(", "lastComment", ">=", "0", "&&", "this", ".", "scanner", ".", "commentStops", "[", "lastComment", "]", "<", "0", ")", "lastComment", "--", ";", "if", "(", "lastComment", ">=", "0", "&&", "this", ".", "javadocParser", "!=", "null", ")", "{", "int", "commentEnd", "=", "this", ".", "scanner", ".", "commentStops", "[", "lastComment", "]", "-", "1", ";", "if", "(", "this", ".", "javadocParser", ".", "shouldReportProblems", ")", "{", "this", ".", "javadocParser", ".", "reportProblems", "=", "this", ".", "currentElement", "==", "null", "||", "commentEnd", ">", "this", ".", "lastJavadocEnd", ";", "}", "else", "{", "this", ".", "javadocParser", ".", "reportProblems", "=", "false", ";", "}", "if", "(", "this", ".", "javadocParser", ".", "checkDeprecation", "(", "lastComment", ")", ")", "{", "checkAndSetModifiers", "(", "ClassFileConstants", ".", "AccDeprecated", ")", ";", "}", "this", ".", "javadoc", "=", "this", ".", "javadocParser", ".", "docComment", ";", "if", "(", "this", ".", "currentElement", "==", "null", ")", "this", ".", "lastJavadocEnd", "=", "commentEnd", ";", "}", "}", "if", "(", "this", ".", "reportReferenceInfo", "&&", "this", ".", "javadocParser", ".", "checkDocComment", "&&", "this", ".", "javadoc", "!=", "null", ")", "{", "TypeReference", "[", "]", "thrownExceptions", "=", "this", ".", "javadoc", ".", "exceptionReferences", ";", "if", "(", "thrownExceptions", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "thrownExceptions", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "TypeReference", "typeRef", "=", "thrownExceptions", "[", "i", "]", ";", "if", "(", "typeRef", "instanceof", "JavadocSingleTypeReference", ")", "{", "JavadocSingleTypeReference", "singleRef", "=", "(", "JavadocSingleTypeReference", ")", "typeRef", ";", "this", ".", "requestor", ".", "acceptTypeReference", "(", "singleRef", ".", "token", ",", "singleRef", ".", "sourceStart", ")", ";", "}", "else", "if", "(", "typeRef", "instanceof", "JavadocQualifiedTypeReference", ")", "{", "JavadocQualifiedTypeReference", "qualifiedRef", "=", "(", "JavadocQualifiedTypeReference", ")", "typeRef", ";", "this", ".", "requestor", ".", "acceptTypeReference", "(", "qualifiedRef", ".", "tokens", ",", "qualifiedRef", ".", "sourceStart", ",", "qualifiedRef", ".", "sourceEnd", ")", ";", "}", "}", "}", "Expression", "[", "]", "references", "=", "this", ".", "javadoc", ".", "seeReferences", ";", "if", "(", "references", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "references", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "Expression", "reference", "=", "references", "[", "i", "]", ";", "acceptJavadocTypeReference", "(", "reference", ")", ";", "if", "(", "reference", "instanceof", "JavadocFieldReference", ")", "{", "JavadocFieldReference", "fieldRef", "=", "(", "JavadocFieldReference", ")", "reference", ";", "this", ".", "requestor", ".", "acceptFieldReference", "(", "fieldRef", ".", "token", ",", "fieldRef", ".", "sourceStart", ")", ";", "if", "(", "fieldRef", ".", "receiver", "!=", "null", "&&", "!", "fieldRef", ".", "receiver", ".", "isThis", "(", ")", ")", "{", "acceptJavadocTypeReference", "(", "fieldRef", ".", "receiver", ")", ";", "}", "}", "else", "if", "(", "reference", "instanceof", "JavadocMessageSend", ")", "{", "JavadocMessageSend", "messageSend", "=", "(", "JavadocMessageSend", ")", "reference", ";", "int", "argCount", "=", "messageSend", ".", "arguments", "==", "null", "?", "0", ":", "messageSend", ".", "arguments", ".", "length", ";", "this", ".", "requestor", ".", "acceptMethodReference", "(", "messageSend", ".", "selector", ",", "argCount", ",", "messageSend", ".", "sourceStart", ")", ";", "this", ".", "requestor", ".", "acceptConstructorReference", "(", "messageSend", ".", "selector", ",", "argCount", ",", "messageSend", ".", "sourceStart", ")", ";", "if", "(", "messageSend", ".", "receiver", "!=", "null", "&&", "!", "messageSend", ".", "receiver", ".", "isThis", "(", ")", ")", "{", "acceptJavadocTypeReference", "(", "messageSend", ".", "receiver", ")", ";", "}", "}", "else", "if", "(", "reference", "instanceof", "JavadocAllocationExpression", ")", "{", "JavadocAllocationExpression", "constructor", "=", "(", "JavadocAllocationExpression", ")", "reference", ";", "int", "argCount", "=", "constructor", ".", "arguments", "==", "null", "?", "0", ":", "constructor", ".", "arguments", ".", "length", ";", "if", "(", "constructor", ".", "type", "!=", "null", ")", "{", "char", "[", "]", "[", "]", "compoundName", "=", "constructor", ".", "type", ".", "getParameterizedTypeName", "(", ")", ";", "this", ".", "requestor", ".", "acceptConstructorReference", "(", "compoundName", "[", "compoundName", ".", "length", "-", "1", "]", ",", "argCount", ",", "constructor", ".", "sourceStart", ")", ";", "if", "(", "!", "constructor", ".", "type", ".", "isThis", "(", ")", ")", "{", "acceptJavadocTypeReference", "(", "constructor", ".", "type", ")", ";", "}", "}", "}", "}", "}", "}", "}", "protected", "void", "classInstanceCreation", "(", "boolean", "alwaysQualified", ")", "{", "boolean", "previousFlag", "=", "this", ".", "reportReferenceInfo", ";", "this", ".", "reportReferenceInfo", "=", "false", ";", "super", ".", "classInstanceCreation", "(", "alwaysQualified", ")", ";", "this", ".", "reportReferenceInfo", "=", "previousFlag", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "AllocationExpression", "alloc", "=", "(", "AllocationExpression", ")", "this", ".", "expressionStack", "[", "this", ".", "expressionPtr", "]", ";", "TypeReference", "typeRef", "=", "alloc", ".", "type", ";", "this", ".", "requestor", ".", "acceptConstructorReference", "(", "typeRef", "instanceof", "SingleTypeReference", "?", "(", "(", "SingleTypeReference", ")", "typeRef", ")", ".", "token", ":", "CharOperation", ".", "concatWith", "(", "alloc", ".", "type", ".", "getParameterizedTypeName", "(", ")", ",", "'.'", ")", ",", "alloc", ".", "arguments", "==", "null", "?", "0", ":", "alloc", ".", "arguments", ".", "length", ",", "alloc", ".", "sourceStart", ")", ";", "}", "}", "protected", "void", "consumeAnnotationAsModifier", "(", ")", "{", "super", ".", "consumeAnnotationAsModifier", "(", ")", ";", "Annotation", "annotation", "=", "(", "Annotation", ")", "this", ".", "expressionStack", "[", "this", ".", "expressionPtr", "]", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptAnnotationTypeReference", "(", "annotation", ".", "type", ".", "getTypeName", "(", ")", ",", "annotation", ".", "sourceStart", ",", "annotation", ".", "sourceEnd", ")", ";", "}", "}", "protected", "void", "consumeClassInstanceCreationExpressionQualifiedWithTypeArguments", "(", ")", "{", "boolean", "previousFlag", "=", "this", ".", "reportReferenceInfo", ";", "this", ".", "reportReferenceInfo", "=", "false", ";", "super", ".", "consumeClassInstanceCreationExpressionQualifiedWithTypeArguments", "(", ")", ";", "this", ".", "reportReferenceInfo", "=", "previousFlag", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "AllocationExpression", "alloc", "=", "(", "AllocationExpression", ")", "this", ".", "expressionStack", "[", "this", ".", "expressionPtr", "]", ";", "TypeReference", "typeRef", "=", "alloc", ".", "type", ";", "this", ".", "requestor", ".", "acceptConstructorReference", "(", "typeRef", "instanceof", "SingleTypeReference", "?", "(", "(", "SingleTypeReference", ")", "typeRef", ")", ".", "token", ":", "CharOperation", ".", "concatWith", "(", "alloc", ".", "type", ".", "getParameterizedTypeName", "(", ")", ",", "'.'", ")", ",", "alloc", ".", "arguments", "==", "null", "?", "0", ":", "alloc", ".", "arguments", ".", "length", ",", "alloc", ".", "sourceStart", ")", ";", "}", "}", "protected", "void", "consumeAnnotationTypeDeclarationHeaderName", "(", ")", "{", "int", "currentAstPtr", "=", "this", ".", "astPtr", ";", "super", ".", "consumeAnnotationTypeDeclarationHeaderName", "(", ")", ";", "if", "(", "this", ".", "astPtr", ">", "currentAstPtr", ")", "rememberCategories", "(", ")", ";", "}", "protected", "void", "consumeAnnotationTypeDeclarationHeaderNameWithTypeParameters", "(", ")", "{", "int", "currentAstPtr", "=", "this", ".", "astPtr", ";", "super", ".", "consumeAnnotationTypeDeclarationHeaderNameWithTypeParameters", "(", ")", ";", "if", "(", "this", ".", "astPtr", ">", "currentAstPtr", ")", "rememberCategories", "(", ")", ";", "}", "protected", "void", "consumeClassHeaderName1", "(", ")", "{", "int", "currentAstPtr", "=", "this", ".", "astPtr", ";", "super", ".", "consumeClassHeaderName1", "(", ")", ";", "if", "(", "this", ".", "astPtr", ">", "currentAstPtr", ")", "rememberCategories", "(", ")", ";", "}", "protected", "void", "consumeClassInstanceCreationExpressionWithTypeArguments", "(", ")", "{", "boolean", "previousFlag", "=", "this", ".", "reportReferenceInfo", ";", "this", ".", "reportReferenceInfo", "=", "false", ";", "super", ".", "consumeClassInstanceCreationExpressionWithTypeArguments", "(", ")", ";", "this", ".", "reportReferenceInfo", "=", "previousFlag", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "AllocationExpression", "alloc", "=", "(", "AllocationExpression", ")", "this", ".", "expressionStack", "[", "this", ".", "expressionPtr", "]", ";", "TypeReference", "typeRef", "=", "alloc", ".", "type", ";", "this", ".", "requestor", ".", "acceptConstructorReference", "(", "typeRef", "instanceof", "SingleTypeReference", "?", "(", "(", "SingleTypeReference", ")", "typeRef", ")", ".", "token", ":", "CharOperation", ".", "concatWith", "(", "alloc", ".", "type", ".", "getParameterizedTypeName", "(", ")", ",", "'.'", ")", ",", "alloc", ".", "arguments", "==", "null", "?", "0", ":", "alloc", ".", "arguments", ".", "length", ",", "alloc", ".", "sourceStart", ")", ";", "}", "}", "protected", "void", "consumeConstructorHeaderName", "(", ")", "{", "long", "selectorSourcePositions", "=", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "]", ";", "int", "selectorSourceEnd", "=", "(", "int", ")", "selectorSourcePositions", ";", "int", "currentAstPtr", "=", "this", ".", "astPtr", ";", "super", ".", "consumeConstructorHeaderName", "(", ")", ";", "if", "(", "this", ".", "astPtr", ">", "currentAstPtr", ")", "{", "this", ".", "sourceEnds", ".", "put", "(", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ",", "selectorSourceEnd", ")", ";", "rememberCategories", "(", ")", ";", "}", "}", "protected", "void", "consumeConstructorHeaderNameWithTypeParameters", "(", ")", "{", "long", "selectorSourcePositions", "=", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "]", ";", "int", "selectorSourceEnd", "=", "(", "int", ")", "selectorSourcePositions", ";", "int", "currentAstPtr", "=", "this", ".", "astPtr", ";", "super", ".", "consumeConstructorHeaderNameWithTypeParameters", "(", ")", ";", "if", "(", "this", ".", "astPtr", ">", "currentAstPtr", ")", "{", "this", ".", "sourceEnds", ".", "put", "(", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ",", "selectorSourceEnd", ")", ";", "rememberCategories", "(", ")", ";", "}", "}", "protected", "void", "consumeEnumConstantWithClassBody", "(", ")", "{", "super", ".", "consumeEnumConstantWithClassBody", "(", ")", ";", "if", "(", "(", "this", ".", "currentToken", "==", "TokenNameCOMMA", "||", "this", ".", "currentToken", "==", "TokenNameSEMICOLON", ")", "&&", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", "instanceof", "FieldDeclaration", ")", "{", "this", ".", "sourceEnds", ".", "put", "(", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ",", "this", ".", "scanner", ".", "currentPosition", "-", "1", ")", ";", "rememberCategories", "(", ")", ";", "}", "}", "protected", "void", "consumeEnumConstantNoClassBody", "(", ")", "{", "super", ".", "consumeEnumConstantNoClassBody", "(", ")", ";", "if", "(", "(", "this", ".", "currentToken", "==", "TokenNameCOMMA", "||", "this", ".", "currentToken", "==", "TokenNameSEMICOLON", ")", "&&", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", "instanceof", "FieldDeclaration", ")", "{", "this", ".", "sourceEnds", ".", "put", "(", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ",", "this", ".", "scanner", ".", "currentPosition", "-", "1", ")", ";", "rememberCategories", "(", ")", ";", "}", "}", "protected", "void", "consumeEnumHeaderName", "(", ")", "{", "int", "currentAstPtr", "=", "this", ".", "astPtr", ";", "super", ".", "consumeEnumHeaderName", "(", ")", ";", "if", "(", "this", ".", "astPtr", ">", "currentAstPtr", ")", "rememberCategories", "(", ")", ";", "}", "protected", "void", "consumeEnumHeaderNameWithTypeParameters", "(", ")", "{", "int", "currentAstPtr", "=", "this", ".", "astPtr", ";", "super", ".", "consumeEnumHeaderNameWithTypeParameters", "(", ")", ";", "if", "(", "this", ".", "astPtr", ">", "currentAstPtr", ")", "rememberCategories", "(", ")", ";", "}", "protected", "void", "consumeExitVariableWithInitialization", "(", ")", "{", "super", ".", "consumeExitVariableWithInitialization", "(", ")", ";", "if", "(", "(", "this", ".", "currentToken", "==", "TokenNameCOMMA", "||", "this", ".", "currentToken", "==", "TokenNameSEMICOLON", ")", "&&", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", "instanceof", "FieldDeclaration", ")", "{", "this", ".", "sourceEnds", ".", "put", "(", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ",", "this", ".", "scanner", ".", "currentPosition", "-", "1", ")", ";", "rememberCategories", "(", ")", ";", "}", "}", "protected", "void", "consumeExitVariableWithoutInitialization", "(", ")", "{", "super", ".", "consumeExitVariableWithoutInitialization", "(", ")", ";", "if", "(", "(", "this", ".", "currentToken", "==", "TokenNameCOMMA", "||", "this", ".", "currentToken", "==", "TokenNameSEMICOLON", ")", "&&", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", "instanceof", "FieldDeclaration", ")", "{", "this", ".", "sourceEnds", ".", "put", "(", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ",", "this", ".", "scanner", ".", "currentPosition", "-", "1", ")", ";", "rememberCategories", "(", ")", ";", "}", "}", "protected", "void", "consumeFieldAccess", "(", "boolean", "isSuperAccess", ")", "{", "super", ".", "consumeFieldAccess", "(", "isSuperAccess", ")", ";", "FieldReference", "fr", "=", "(", "FieldReference", ")", "this", ".", "expressionStack", "[", "this", ".", "expressionPtr", "]", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptFieldReference", "(", "fr", ".", "token", ",", "fr", ".", "sourceStart", ")", ";", "}", "}", "protected", "void", "consumeFormalParameter", "(", "boolean", "isVarArgs", ")", "{", "super", ".", "consumeFormalParameter", "(", "isVarArgs", ")", ";", "flushCommentsDefinedPriorTo", "(", "this", ".", "scanner", ".", "currentPosition", ")", ";", "}", "protected", "void", "consumeInterfaceHeaderName1", "(", ")", "{", "int", "currentAstPtr", "=", "this", ".", "astPtr", ";", "super", ".", "consumeInterfaceHeaderName1", "(", ")", ";", "if", "(", "this", ".", "astPtr", ">", "currentAstPtr", ")", "rememberCategories", "(", ")", ";", "}", "protected", "void", "consumeMemberValuePair", "(", ")", "{", "super", ".", "consumeMemberValuePair", "(", ")", ";", "MemberValuePair", "memberValuepair", "=", "(", "MemberValuePair", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptMethodReference", "(", "memberValuepair", ".", "name", ",", "0", ",", "memberValuepair", ".", "sourceStart", ")", ";", "}", "}", "protected", "void", "consumeMarkerAnnotation", "(", ")", "{", "super", ".", "consumeMarkerAnnotation", "(", ")", ";", "Annotation", "annotation", "=", "(", "Annotation", ")", "this", ".", "expressionStack", "[", "this", ".", "expressionPtr", "]", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptAnnotationTypeReference", "(", "annotation", ".", "type", ".", "getTypeName", "(", ")", ",", "annotation", ".", "sourceStart", ",", "annotation", ".", "sourceEnd", ")", ";", "}", "}", "protected", "void", "consumeMethodHeaderName", "(", "boolean", "isAnnotationMethod", ")", "{", "long", "selectorSourcePositions", "=", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "]", ";", "int", "selectorSourceEnd", "=", "(", "int", ")", "selectorSourcePositions", ";", "int", "currentAstPtr", "=", "this", ".", "astPtr", ";", "super", ".", "consumeMethodHeaderName", "(", "isAnnotationMethod", ")", ";", "if", "(", "this", ".", "astPtr", ">", "currentAstPtr", ")", "{", "this", ".", "sourceEnds", ".", "put", "(", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ",", "selectorSourceEnd", ")", ";", "rememberCategories", "(", ")", ";", "}", "}", "protected", "void", "consumeMethodHeaderNameWithTypeParameters", "(", "boolean", "isAnnotationMethod", ")", "{", "long", "selectorSourcePositions", "=", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "]", ";", "int", "selectorSourceEnd", "=", "(", "int", ")", "selectorSourcePositions", ";", "int", "currentAstPtr", "=", "this", ".", "astPtr", ";", "super", ".", "consumeMethodHeaderNameWithTypeParameters", "(", "isAnnotationMethod", ")", ";", "if", "(", "this", ".", "astPtr", ">", "currentAstPtr", ")", "this", ".", "sourceEnds", ".", "put", "(", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ",", "selectorSourceEnd", ")", ";", "rememberCategories", "(", ")", ";", "}", "protected", "void", "consumeMethodInvocationName", "(", ")", "{", "super", ".", "consumeMethodInvocationName", "(", ")", ";", "MessageSend", "messageSend", "=", "(", "MessageSend", ")", "this", ".", "expressionStack", "[", "this", ".", "expressionPtr", "]", ";", "Expression", "[", "]", "args", "=", "messageSend", ".", "arguments", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptMethodReference", "(", "messageSend", ".", "selector", ",", "args", "==", "null", "?", "0", ":", "args", ".", "length", ",", "(", "int", ")", "(", "messageSend", ".", "nameSourcePosition", ">>>", "32", ")", ")", ";", "}", "}", "protected", "void", "consumeMethodInvocationNameWithTypeArguments", "(", ")", "{", "super", ".", "consumeMethodInvocationNameWithTypeArguments", "(", ")", ";", "MessageSend", "messageSend", "=", "(", "MessageSend", ")", "this", ".", "expressionStack", "[", "this", ".", "expressionPtr", "]", ";", "Expression", "[", "]", "args", "=", "messageSend", ".", "arguments", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptMethodReference", "(", "messageSend", ".", "selector", ",", "args", "==", "null", "?", "0", ":", "args", ".", "length", ",", "(", "int", ")", "(", "messageSend", ".", "nameSourcePosition", ">>>", "32", ")", ")", ";", "}", "}", "protected", "void", "consumeMethodInvocationPrimary", "(", ")", "{", "super", ".", "consumeMethodInvocationPrimary", "(", ")", ";", "MessageSend", "messageSend", "=", "(", "MessageSend", ")", "this", ".", "expressionStack", "[", "this", ".", "expressionPtr", "]", ";", "Expression", "[", "]", "args", "=", "messageSend", ".", "arguments", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptMethodReference", "(", "messageSend", ".", "selector", ",", "args", "==", "null", "?", "0", ":", "args", ".", "length", ",", "(", "int", ")", "(", "messageSend", ".", "nameSourcePosition", ">>>", "32", ")", ")", ";", "}", "}", "protected", "void", "consumeMethodInvocationPrimaryWithTypeArguments", "(", ")", "{", "super", ".", "consumeMethodInvocationPrimaryWithTypeArguments", "(", ")", ";", "MessageSend", "messageSend", "=", "(", "MessageSend", ")", "this", ".", "expressionStack", "[", "this", ".", "expressionPtr", "]", ";", "Expression", "[", "]", "args", "=", "messageSend", ".", "arguments", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptMethodReference", "(", "messageSend", ".", "selector", ",", "args", "==", "null", "?", "0", ":", "args", ".", "length", ",", "(", "int", ")", "(", "messageSend", ".", "nameSourcePosition", ">>>", "32", ")", ")", ";", "}", "}", "protected", "void", "consumeMethodInvocationSuper", "(", ")", "{", "super", ".", "consumeMethodInvocationSuper", "(", ")", ";", "MessageSend", "messageSend", "=", "(", "MessageSend", ")", "this", ".", "expressionStack", "[", "this", ".", "expressionPtr", "]", ";", "Expression", "[", "]", "args", "=", "messageSend", ".", "arguments", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptMethodReference", "(", "messageSend", ".", "selector", ",", "args", "==", "null", "?", "0", ":", "args", ".", "length", ",", "(", "int", ")", "(", "messageSend", ".", "nameSourcePosition", ">>>", "32", ")", ")", ";", "}", "}", "protected", "void", "consumeMethodInvocationSuperWithTypeArguments", "(", ")", "{", "super", ".", "consumeMethodInvocationSuperWithTypeArguments", "(", ")", ";", "MessageSend", "messageSend", "=", "(", "MessageSend", ")", "this", ".", "expressionStack", "[", "this", ".", "expressionPtr", "]", ";", "Expression", "[", "]", "args", "=", "messageSend", ".", "arguments", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptMethodReference", "(", "messageSend", ".", "selector", ",", "args", "==", "null", "?", "0", ":", "args", ".", "length", ",", "(", "int", ")", "(", "messageSend", ".", "nameSourcePosition", ">>>", "32", ")", ")", ";", "}", "}", "protected", "void", "consumeNormalAnnotation", "(", ")", "{", "super", ".", "consumeNormalAnnotation", "(", ")", ";", "Annotation", "annotation", "=", "(", "Annotation", ")", "this", ".", "expressionStack", "[", "this", ".", "expressionPtr", "]", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptAnnotationTypeReference", "(", "annotation", ".", "type", ".", "getTypeName", "(", ")", ",", "annotation", ".", "sourceStart", ",", "annotation", ".", "sourceEnd", ")", ";", "}", "}", "protected", "void", "consumeSingleMemberAnnotation", "(", ")", "{", "super", ".", "consumeSingleMemberAnnotation", "(", ")", ";", "SingleMemberAnnotation", "member", "=", "(", "SingleMemberAnnotation", ")", "this", ".", "expressionStack", "[", "this", ".", "expressionPtr", "]", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptMethodReference", "(", "TypeConstants", ".", "VALUE", ",", "0", ",", "member", ".", "sourceStart", ")", ";", "}", "}", "protected", "void", "consumeSingleStaticImportDeclarationName", "(", ")", "{", "ImportReference", "impt", ";", "int", "length", ";", "char", "[", "]", "[", "]", "tokens", "=", "new", "char", "[", "length", "=", "this", ".", "identifierLengthStack", "[", "this", ".", "identifierLengthPtr", "--", "]", "]", "[", "]", ";", "this", ".", "identifierPtr", "-=", "length", ";", "long", "[", "]", "positions", "=", "new", "long", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "this", ".", "identifierStack", ",", "this", ".", "identifierPtr", "+", "1", ",", "tokens", ",", "0", ",", "length", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "identifierPositionStack", ",", "this", ".", "identifierPtr", "+", "1", ",", "positions", ",", "0", ",", "length", ")", ";", "pushOnAstStack", "(", "impt", "=", "newImportReference", "(", "tokens", ",", "positions", ",", "false", ",", "ClassFileConstants", ".", "AccStatic", ")", ")", ";", "this", ".", "modifiers", "=", "ClassFileConstants", ".", "AccDefault", ";", "this", ".", "modifiersSourceStart", "=", "-", "1", ";", "if", "(", "this", ".", "currentToken", "==", "TokenNameSEMICOLON", ")", "{", "impt", ".", "declarationSourceEnd", "=", "this", ".", "scanner", ".", "currentPosition", "-", "1", ";", "}", "else", "{", "impt", ".", "declarationSourceEnd", "=", "impt", ".", "sourceEnd", ";", "}", "impt", ".", "declarationEnd", "=", "impt", ".", "declarationSourceEnd", ";", "impt", ".", "declarationSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "if", "(", "!", "this", ".", "statementRecoveryActivated", "&&", "this", ".", "options", ".", "sourceLevel", "<", "ClassFileConstants", ".", "JDK1_5", "&&", "this", ".", "lastErrorEndPositionBeforeRecovery", "<", "this", ".", "scanner", ".", "currentPosition", ")", "{", "impt", ".", "modifiers", "=", "ClassFileConstants", ".", "AccDefault", ";", "problemReporter", "(", ")", ".", "invalidUsageOfStaticImports", "(", "impt", ")", ";", "}", "if", "(", "this", ".", "currentElement", "!=", "null", ")", "{", "this", ".", "lastCheckPoint", "=", "impt", ".", "declarationSourceEnd", "+", "1", ";", "this", ".", "currentElement", "=", "this", ".", "currentElement", ".", "add", "(", "impt", ",", "0", ")", ";", "this", ".", "lastIgnoredToken", "=", "-", "1", ";", "this", ".", "restartRecovery", "=", "true", ";", "}", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "int", "tokensLength", "=", "impt", ".", "tokens", ".", "length", "-", "1", ";", "int", "start", "=", "(", "int", ")", "(", "impt", ".", "sourcePositions", "[", "tokensLength", "]", ">>>", "32", ")", ";", "char", "[", "]", "last", "=", "impt", ".", "tokens", "[", "tokensLength", "]", ";", "this", ".", "requestor", ".", "acceptFieldReference", "(", "last", ",", "start", ")", ";", "this", ".", "requestor", ".", "acceptMethodReference", "(", "last", ",", "0", ",", "start", ")", ";", "this", ".", "requestor", ".", "acceptTypeReference", "(", "last", ",", "start", ")", ";", "if", "(", "tokensLength", ">", "0", ")", "{", "char", "[", "]", "[", "]", "compoundName", "=", "new", "char", "[", "tokensLength", "]", "[", "]", ";", "System", ".", "arraycopy", "(", "impt", ".", "tokens", ",", "0", ",", "compoundName", ",", "0", ",", "tokensLength", ")", ";", "int", "end", "=", "(", "int", ")", "impt", ".", "sourcePositions", "[", "tokensLength", "-", "1", "]", ";", "this", ".", "requestor", ".", "acceptTypeReference", "(", "compoundName", ",", "impt", ".", "sourceStart", ",", "end", ")", ";", "}", "}", "}", "protected", "void", "consumeSingleTypeImportDeclarationName", "(", ")", "{", "ImportReference", "impt", ";", "int", "length", ";", "char", "[", "]", "[", "]", "tokens", "=", "new", "char", "[", "length", "=", "this", ".", "identifierLengthStack", "[", "this", ".", "identifierLengthPtr", "--", "]", "]", "[", "]", ";", "this", ".", "identifierPtr", "-=", "length", ";", "long", "[", "]", "positions", "=", "new", "long", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "this", ".", "identifierStack", ",", "this", ".", "identifierPtr", "+", "1", ",", "tokens", ",", "0", ",", "length", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "identifierPositionStack", ",", "this", ".", "identifierPtr", "+", "1", ",", "positions", ",", "0", ",", "length", ")", ";", "pushOnAstStack", "(", "impt", "=", "newImportReference", "(", "tokens", ",", "positions", ",", "false", ",", "ClassFileConstants", ".", "AccDefault", ")", ")", ";", "if", "(", "this", ".", "currentToken", "==", "TokenNameSEMICOLON", ")", "{", "impt", ".", "declarationSourceEnd", "=", "this", ".", "scanner", ".", "currentPosition", "-", "1", ";", "}", "else", "{", "impt", ".", "declarationSourceEnd", "=", "impt", ".", "sourceEnd", ";", "}", "impt", ".", "declarationEnd", "=", "impt", ".", "declarationSourceEnd", ";", "impt", ".", "declarationSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "if", "(", "this", ".", "currentElement", "!=", "null", ")", "{", "this", ".", "lastCheckPoint", "=", "impt", ".", "declarationSourceEnd", "+", "1", ";", "this", ".", "currentElement", "=", "this", ".", "currentElement", ".", "add", "(", "impt", ",", "0", ")", ";", "this", ".", "lastIgnoredToken", "=", "-", "1", ";", "this", ".", "restartRecovery", "=", "true", ";", "}", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptTypeReference", "(", "impt", ".", "tokens", ",", "impt", ".", "sourceStart", ",", "impt", ".", "sourceEnd", ")", ";", "}", "}", "protected", "void", "consumeStaticImportOnDemandDeclarationName", "(", ")", "{", "ImportReference", "impt", ";", "int", "length", ";", "char", "[", "]", "[", "]", "tokens", "=", "new", "char", "[", "length", "=", "this", ".", "identifierLengthStack", "[", "this", ".", "identifierLengthPtr", "--", "]", "]", "[", "]", ";", "this", ".", "identifierPtr", "-=", "length", ";", "long", "[", "]", "positions", "=", "new", "long", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "this", ".", "identifierStack", ",", "this", ".", "identifierPtr", "+", "1", ",", "tokens", ",", "0", ",", "length", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "identifierPositionStack", ",", "this", ".", "identifierPtr", "+", "1", ",", "positions", ",", "0", ",", "length", ")", ";", "pushOnAstStack", "(", "impt", "=", "new", "ImportReference", "(", "tokens", ",", "positions", ",", "true", ",", "ClassFileConstants", ".", "AccStatic", ")", ")", ";", "this", ".", "modifiers", "=", "ClassFileConstants", ".", "AccDefault", ";", "this", ".", "modifiersSourceStart", "=", "-", "1", ";", "if", "(", "this", ".", "currentToken", "==", "TokenNameSEMICOLON", ")", "{", "impt", ".", "declarationSourceEnd", "=", "this", ".", "scanner", ".", "currentPosition", "-", "1", ";", "}", "else", "{", "impt", ".", "declarationSourceEnd", "=", "impt", ".", "sourceEnd", ";", "}", "impt", ".", "declarationEnd", "=", "impt", ".", "declarationSourceEnd", ";", "impt", ".", "declarationSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "if", "(", "!", "this", ".", "statementRecoveryActivated", "&&", "this", ".", "options", ".", "sourceLevel", "<", "ClassFileConstants", ".", "JDK1_5", "&&", "this", ".", "lastErrorEndPositionBeforeRecovery", "<", "this", ".", "scanner", ".", "currentPosition", ")", "{", "impt", ".", "modifiers", "=", "ClassFileConstants", ".", "AccDefault", ";", "problemReporter", "(", ")", ".", "invalidUsageOfStaticImports", "(", "impt", ")", ";", "}", "if", "(", "this", ".", "currentElement", "!=", "null", ")", "{", "this", ".", "lastCheckPoint", "=", "impt", ".", "declarationSourceEnd", "+", "1", ";", "this", ".", "currentElement", "=", "this", ".", "currentElement", ".", "add", "(", "impt", ",", "0", ")", ";", "this", ".", "lastIgnoredToken", "=", "-", "1", ";", "this", ".", "restartRecovery", "=", "true", ";", "}", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptTypeReference", "(", "impt", ".", "tokens", ",", "impt", ".", "sourceStart", ",", "impt", ".", "sourceEnd", ")", ";", "}", "}", "protected", "void", "consumeTypeImportOnDemandDeclarationName", "(", ")", "{", "ImportReference", "impt", ";", "int", "length", ";", "char", "[", "]", "[", "]", "tokens", "=", "new", "char", "[", "length", "=", "this", ".", "identifierLengthStack", "[", "this", ".", "identifierLengthPtr", "--", "]", "]", "[", "]", ";", "this", ".", "identifierPtr", "-=", "length", ";", "long", "[", "]", "positions", "=", "new", "long", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "this", ".", "identifierStack", ",", "this", ".", "identifierPtr", "+", "1", ",", "tokens", ",", "0", ",", "length", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "identifierPositionStack", ",", "this", ".", "identifierPtr", "+", "1", ",", "positions", ",", "0", ",", "length", ")", ";", "pushOnAstStack", "(", "impt", "=", "new", "ImportReference", "(", "tokens", ",", "positions", ",", "true", ",", "ClassFileConstants", ".", "AccDefault", ")", ")", ";", "if", "(", "this", ".", "currentToken", "==", "TokenNameSEMICOLON", ")", "{", "impt", ".", "declarationSourceEnd", "=", "this", ".", "scanner", ".", "currentPosition", "-", "1", ";", "}", "else", "{", "impt", ".", "declarationSourceEnd", "=", "impt", ".", "sourceEnd", ";", "}", "impt", ".", "declarationEnd", "=", "impt", ".", "declarationSourceEnd", ";", "impt", ".", "declarationSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "if", "(", "this", ".", "currentElement", "!=", "null", ")", "{", "this", ".", "lastCheckPoint", "=", "impt", ".", "declarationSourceEnd", "+", "1", ";", "this", ".", "currentElement", "=", "this", ".", "currentElement", ".", "add", "(", "impt", ",", "0", ")", ";", "this", ".", "lastIgnoredToken", "=", "-", "1", ";", "this", ".", "restartRecovery", "=", "true", ";", "}", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptUnknownReference", "(", "impt", ".", "tokens", ",", "impt", ".", "sourceStart", ",", "impt", ".", "sourceEnd", ")", ";", "}", "}", "public", "MethodDeclaration", "convertToMethodDeclaration", "(", "ConstructorDeclaration", "c", ",", "CompilationResult", "compilationResult", ")", "{", "MethodDeclaration", "methodDeclaration", "=", "super", ".", "convertToMethodDeclaration", "(", "c", ",", "compilationResult", ")", ";", "int", "selectorSourceEnd", "=", "this", ".", "sourceEnds", ".", "removeKey", "(", "c", ")", ";", "if", "(", "selectorSourceEnd", "!=", "-", "1", ")", "this", ".", "sourceEnds", ".", "put", "(", "methodDeclaration", ",", "selectorSourceEnd", ")", ";", "char", "[", "]", "[", "]", "categories", "=", "(", "char", "[", "]", "[", "]", ")", "this", ".", "nodesToCategories", ".", "remove", "(", "c", ")", ";", "if", "(", "categories", "!=", "null", ")", "this", ".", "nodesToCategories", ".", "put", "(", "methodDeclaration", ",", "categories", ")", ";", "return", "methodDeclaration", ";", "}", "protected", "CompilationUnitDeclaration", "endParse", "(", "int", "act", ")", "{", "if", "(", "this", ".", "scanner", ".", "recordLineSeparator", ")", "{", "this", ".", "requestor", ".", "acceptLineSeparatorPositions", "(", "this", ".", "scanner", ".", "getLineEnds", "(", ")", ")", ";", "}", "if", "(", "this", ".", "compilationUnit", "!=", "null", ")", "{", "CompilationUnitDeclaration", "result", "=", "super", ".", "endParse", "(", "act", ")", ";", "return", "result", ";", "}", "else", "{", "return", "null", ";", "}", "}", "public", "TypeReference", "getTypeReference", "(", "int", "dim", ")", "{", "int", "length", "=", "this", ".", "identifierLengthStack", "[", "this", ".", "identifierLengthPtr", "--", "]", ";", "if", "(", "length", "<", "0", ")", "{", "TypeReference", "ref", "=", "TypeReference", ".", "baseTypeReference", "(", "-", "length", ",", "dim", ")", ";", "ref", ".", "sourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "if", "(", "dim", "==", "0", ")", "{", "ref", ".", "sourceEnd", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "}", "else", "{", "this", ".", "intPtr", "--", ";", "ref", ".", "sourceEnd", "=", "this", ".", "endPosition", ";", "}", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptTypeReference", "(", "ref", ".", "getParameterizedTypeName", "(", ")", ",", "ref", ".", "sourceStart", ",", "ref", ".", "sourceEnd", ")", ";", "}", "return", "ref", ";", "}", "else", "{", "int", "numberOfIdentifiers", "=", "this", ".", "genericsIdentifiersLengthStack", "[", "this", ".", "genericsIdentifiersLengthPtr", "--", "]", ";", "if", "(", "length", "!=", "numberOfIdentifiers", "||", "this", ".", "genericsLengthStack", "[", "this", ".", "genericsLengthPtr", "]", "!=", "0", ")", "{", "TypeReference", "ref", "=", "getTypeReferenceForGenericType", "(", "dim", ",", "length", ",", "numberOfIdentifiers", ")", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "if", "(", "length", "==", "1", "&&", "numberOfIdentifiers", "==", "1", ")", "{", "ParameterizedSingleTypeReference", "parameterizedSingleTypeReference", "=", "(", "ParameterizedSingleTypeReference", ")", "ref", ";", "this", ".", "requestor", ".", "acceptTypeReference", "(", "parameterizedSingleTypeReference", ".", "token", ",", "parameterizedSingleTypeReference", ".", "sourceStart", ")", ";", "}", "else", "{", "ParameterizedQualifiedTypeReference", "parameterizedQualifiedTypeReference", "=", "(", "ParameterizedQualifiedTypeReference", ")", "ref", ";", "this", ".", "requestor", ".", "acceptTypeReference", "(", "parameterizedQualifiedTypeReference", ".", "tokens", ",", "parameterizedQualifiedTypeReference", ".", "sourceStart", ",", "parameterizedQualifiedTypeReference", ".", "sourceEnd", ")", ";", "}", "}", "return", "ref", ";", "}", "else", "if", "(", "length", "==", "1", ")", "{", "this", ".", "genericsLengthPtr", "--", ";", "if", "(", "dim", "==", "0", ")", "{", "SingleTypeReference", "ref", "=", "new", "SingleTypeReference", "(", "this", ".", "identifierStack", "[", "this", ".", "identifierPtr", "]", ",", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "--", "]", ")", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptTypeReference", "(", "ref", ".", "token", ",", "ref", ".", "sourceStart", ")", ";", "}", "return", "ref", ";", "}", "else", "{", "ArrayTypeReference", "ref", "=", "new", "ArrayTypeReference", "(", "this", ".", "identifierStack", "[", "this", ".", "identifierPtr", "]", ",", "dim", ",", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "--", "]", ")", ";", "ref", ".", "sourceEnd", "=", "this", ".", "endPosition", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptTypeReference", "(", "ref", ".", "token", ",", "ref", ".", "sourceStart", ")", ";", "}", "return", "ref", ";", "}", "}", "else", "{", "this", ".", "genericsLengthPtr", "--", ";", "char", "[", "]", "[", "]", "tokens", "=", "new", "char", "[", "length", "]", "[", "]", ";", "this", ".", "identifierPtr", "-=", "length", ";", "long", "[", "]", "positions", "=", "new", "long", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "this", ".", "identifierStack", ",", "this", ".", "identifierPtr", "+", "1", ",", "tokens", ",", "0", ",", "length", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "identifierPositionStack", ",", "this", ".", "identifierPtr", "+", "1", ",", "positions", ",", "0", ",", "length", ")", ";", "if", "(", "dim", "==", "0", ")", "{", "QualifiedTypeReference", "ref", "=", "new", "QualifiedTypeReference", "(", "tokens", ",", "positions", ")", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptTypeReference", "(", "ref", ".", "tokens", ",", "ref", ".", "sourceStart", ",", "ref", ".", "sourceEnd", ")", ";", "}", "return", "ref", ";", "}", "else", "{", "ArrayQualifiedTypeReference", "ref", "=", "new", "ArrayQualifiedTypeReference", "(", "tokens", ",", "dim", ",", "positions", ")", ";", "ref", ".", "sourceEnd", "=", "this", ".", "endPosition", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "this", ".", "requestor", ".", "acceptTypeReference", "(", "ref", ".", "tokens", ",", "ref", ".", "sourceStart", ",", "ref", ".", "sourceEnd", ")", ";", "}", "return", "ref", ";", "}", "}", "}", "}", "public", "NameReference", "getUnspecifiedReference", "(", ")", "{", "int", "length", ";", "if", "(", "(", "length", "=", "this", ".", "identifierLengthStack", "[", "this", ".", "identifierLengthPtr", "--", "]", ")", "==", "1", ")", "{", "SingleNameReference", "ref", "=", "newSingleNameReference", "(", "this", ".", "identifierStack", "[", "this", ".", "identifierPtr", "]", ",", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "--", "]", ")", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "addUnknownRef", "(", "ref", ")", ";", "}", "return", "ref", ";", "}", "else", "{", "char", "[", "]", "[", "]", "tokens", "=", "new", "char", "[", "length", "]", "[", "]", ";", "this", ".", "identifierPtr", "-=", "length", ";", "System", ".", "arraycopy", "(", "this", ".", "identifierStack", ",", "this", ".", "identifierPtr", "+", "1", ",", "tokens", ",", "0", ",", "length", ")", ";", "long", "[", "]", "positions", "=", "new", "long", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "this", ".", "identifierPositionStack", ",", "this", ".", "identifierPtr", "+", "1", ",", "positions", ",", "0", ",", "length", ")", ";", "QualifiedNameReference", "ref", "=", "newQualifiedNameReference", "(", "tokens", ",", "positions", ",", "(", "int", ")", "(", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "+", "1", "]", ">>", "32", ")", ",", "(", "int", ")", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "+", "length", "]", ")", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "addUnknownRef", "(", "ref", ")", ";", "}", "return", "ref", ";", "}", "}", "public", "NameReference", "getUnspecifiedReferenceOptimized", "(", ")", "{", "int", "length", ";", "if", "(", "(", "length", "=", "this", ".", "identifierLengthStack", "[", "this", ".", "identifierLengthPtr", "--", "]", ")", "==", "1", ")", "{", "SingleNameReference", "ref", "=", "newSingleNameReference", "(", "this", ".", "identifierStack", "[", "this", ".", "identifierPtr", "]", ",", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "--", "]", ")", ";", "ref", ".", "bits", "&=", "~", "ASTNode", ".", "RestrictiveFlagMASK", ";", "ref", ".", "bits", "|=", "Binding", ".", "LOCAL", "|", "Binding", ".", "FIELD", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "addUnknownRef", "(", "ref", ")", ";", "}", "return", "ref", ";", "}", "char", "[", "]", "[", "]", "tokens", "=", "new", "char", "[", "length", "]", "[", "]", ";", "this", ".", "identifierPtr", "-=", "length", ";", "System", ".", "arraycopy", "(", "this", ".", "identifierStack", ",", "this", ".", "identifierPtr", "+", "1", ",", "tokens", ",", "0", ",", "length", ")", ";", "long", "[", "]", "positions", "=", "new", "long", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "this", ".", "identifierPositionStack", ",", "this", ".", "identifierPtr", "+", "1", ",", "positions", ",", "0", ",", "length", ")", ";", "QualifiedNameReference", "ref", "=", "newQualifiedNameReference", "(", "tokens", ",", "positions", ",", "(", "int", ")", "(", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "+", "1", "]", ">>", "32", ")", ",", "(", "int", ")", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "+", "length", "]", ")", ";", "ref", ".", "bits", "&=", "~", "ASTNode", ".", "RestrictiveFlagMASK", ";", "ref", ".", "bits", "|=", "Binding", ".", "LOCAL", "|", "Binding", ".", "FIELD", ";", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "addUnknownRef", "(", "ref", ")", ";", "}", "return", "ref", ";", "}", "protected", "ImportReference", "newImportReference", "(", "char", "[", "]", "[", "]", "tokens", ",", "long", "[", "]", "positions", ",", "boolean", "onDemand", ",", "int", "mod", ")", "{", "return", "new", "ImportReference", "(", "tokens", ",", "positions", ",", "onDemand", ",", "mod", ")", ";", "}", "protected", "QualifiedNameReference", "newQualifiedNameReference", "(", "char", "[", "]", "[", "]", "tokens", ",", "long", "[", "]", "positions", ",", "int", "sourceStart", ",", "int", "sourceEnd", ")", "{", "return", "new", "QualifiedNameReference", "(", "tokens", ",", "positions", ",", "sourceStart", ",", "sourceEnd", ")", ";", "}", "protected", "SingleNameReference", "newSingleNameReference", "(", "char", "[", "]", "source", ",", "long", "positions", ")", "{", "return", "new", "SingleNameReference", "(", "source", ",", "positions", ")", ";", "}", "public", "CompilationUnitDeclaration", "parseCompilationUnit", "(", "ICompilationUnit", "unit", ",", "boolean", "fullParse", ",", "IProgressMonitor", "pm", ")", "{", "boolean", "old", "=", "this", ".", "diet", ";", "CompilationUnitDeclaration", "parsedUnit", "=", "null", ";", "try", "{", "this", ".", "diet", "=", "true", ";", "this", ".", "reportReferenceInfo", "=", "fullParse", ";", "CompilationResult", "compilationUnitResult", "=", "new", "CompilationResult", "(", "unit", ",", "0", ",", "0", ",", "this", ".", "options", ".", "maxProblemsPerUnit", ")", ";", "parsedUnit", "=", "parse", "(", "unit", ",", "compilationUnitResult", ")", ";", "if", "(", "pm", "!=", "null", "&&", "pm", ".", "isCanceled", "(", ")", ")", "throw", "new", "OperationCanceledException", "(", "Messages", ".", "operation_cancelled", ")", ";", "if", "(", "this", ".", "scanner", ".", "recordLineSeparator", ")", "{", "this", ".", "requestor", ".", "acceptLineSeparatorPositions", "(", "compilationUnitResult", ".", "getLineSeparatorPositions", "(", ")", ")", ";", "}", "int", "initialStart", "=", "this", ".", "scanner", ".", "initialPosition", ";", "int", "initialEnd", "=", "this", ".", "scanner", ".", "eofPosition", ";", "if", "(", "this", ".", "reportLocalDeclarations", "||", "fullParse", ")", "{", "this", ".", "diet", "=", "false", ";", "getMethodBodies", "(", "parsedUnit", ")", ";", "}", "this", ".", "scanner", ".", "resetTo", "(", "initialStart", ",", "initialEnd", ")", ";", "this", ".", "notifier", ".", "notifySourceElementRequestor", "(", "parsedUnit", ",", "this", ".", "scanner", ".", "initialPosition", ",", "this", ".", "scanner", ".", "eofPosition", ",", "this", ".", "reportReferenceInfo", ",", "this", ".", "sourceEnds", ",", "this", ".", "nodesToCategories", ")", ";", "return", "parsedUnit", ";", "}", "catch", "(", "AbortCompilation", "e", ")", "{", "}", "finally", "{", "this", ".", "diet", "=", "old", ";", "reset", "(", ")", ";", "}", "return", "parsedUnit", ";", "}", "private", "void", "rememberCategories", "(", ")", "{", "if", "(", "this", ".", "useSourceJavadocParser", ")", "{", "SourceJavadocParser", "sourceJavadocParser", "=", "(", "SourceJavadocParser", ")", "this", ".", "javadocParser", ";", "char", "[", "]", "[", "]", "categories", "=", "sourceJavadocParser", ".", "categories", ";", "if", "(", "categories", ".", "length", ">", "0", ")", "{", "this", ".", "nodesToCategories", ".", "put", "(", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ",", "categories", ")", ";", "sourceJavadocParser", ".", "categories", "=", "CharOperation", ".", "NO_CHAR_CHAR", ";", "}", "}", "}", "public", "void", "reset", "(", ")", "{", "this", ".", "sourceEnds", "=", "new", "HashtableOfObjectToInt", "(", ")", ";", "this", ".", "nodesToCategories", "=", "new", "HashMap", "(", ")", ";", "}", "public", "void", "setRequestor", "(", "ISourceElementRequestor", "requestor", ")", "{", "this", ".", "requestor", "=", "requestor", ";", "this", ".", "notifier", ".", "requestor", "=", "requestor", ";", "}", "}", "</s>" ]
5,538
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "parser", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "*", ";", "public", "class", "DocumentElementParser", "extends", "Parser", "{", "IDocumentElementRequestor", "requestor", ";", "private", "int", "localIntPtr", ";", "private", "int", "lastFieldEndPosition", ";", "private", "int", "lastFieldBodyEndPosition", ";", "private", "int", "typeStartPosition", ";", "private", "long", "selectorSourcePositions", ";", "private", "int", "typeDims", ";", "private", "int", "extendsDim", ";", "private", "int", "declarationSourceStart", ";", "int", "[", "]", "[", "]", "intArrayStack", ";", "int", "intArrayPtr", ";", "public", "DocumentElementParser", "(", "final", "IDocumentElementRequestor", "requestor", ",", "IProblemFactory", "problemFactory", ",", "CompilerOptions", "options", ")", "{", "super", "(", "new", "ProblemReporter", "(", "DefaultErrorHandlingPolicies", ".", "exitAfterAllProblems", "(", ")", ",", "options", ",", "problemFactory", ")", ",", "false", ")", ";", "this", ".", "requestor", "=", "requestor", ";", "this", ".", "intArrayStack", "=", "new", "int", "[", "30", "]", "[", "]", ";", "this", ".", "options", "=", "options", ";", "this", ".", "javadocParser", ".", "checkDocComment", "=", "false", ";", "setMethodsFullRecovery", "(", "false", ")", ";", "setStatementsRecovery", "(", "false", ")", ";", "}", "public", "void", "checkComment", "(", ")", "{", "pushOnIntArrayStack", "(", "getJavaDocPositions", "(", ")", ")", ";", "boolean", "deprecated", "=", "false", ";", "int", "lastCommentIndex", "=", "-", "1", ";", "int", "commentPtr", "=", "this", ".", "scanner", ".", "commentPtr", ";", "nextComment", ":", "for", "(", "lastCommentIndex", "=", "this", ".", "scanner", ".", "commentPtr", ";", "lastCommentIndex", ">=", "0", ";", "lastCommentIndex", "--", ")", "{", "int", "commentSourceStart", "=", "this", ".", "scanner", ".", "commentStarts", "[", "lastCommentIndex", "]", ";", "if", "(", "commentSourceStart", "<", "0", "||", "this", ".", "scanner", ".", "commentStops", "[", "lastCommentIndex", "]", "<", "0", "||", "(", "this", ".", "modifiersSourceStart", "!=", "-", "1", "&&", "this", ".", "modifiersSourceStart", "<", "commentSourceStart", ")", ")", "{", "continue", "nextComment", ";", "}", "deprecated", "=", "this", ".", "javadocParser", ".", "checkDeprecation", "(", "lastCommentIndex", ")", ";", "break", "nextComment", ";", "}", "if", "(", "deprecated", ")", "{", "checkAndSetModifiers", "(", "ClassFileConstants", ".", "AccDeprecated", ")", ";", "}", "if", "(", "commentPtr", ">=", "0", ")", "{", "this", ".", "declarationSourceStart", "=", "this", ".", "scanner", ".", "commentStarts", "[", "0", "]", ";", "if", "(", "this", ".", "declarationSourceStart", "<", "0", ")", "this", ".", "declarationSourceStart", "=", "-", "this", ".", "declarationSourceStart", ";", "}", "}", "protected", "void", "consumeClassBodyDeclaration", "(", ")", "{", "super", ".", "consumeClassBodyDeclaration", "(", ")", ";", "Initializer", "initializer", "=", "(", "Initializer", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ";", "this", ".", "requestor", ".", "acceptInitializer", "(", "initializer", ".", "declarationSourceStart", ",", "initializer", ".", "declarationSourceEnd", ",", "this", ".", "intArrayStack", "[", "this", ".", "intArrayPtr", "--", "]", ",", "0", ",", "this", ".", "modifiersSourceStart", ",", "initializer", ".", "block", ".", "sourceStart", ",", "initializer", ".", "block", ".", "sourceEnd", ")", ";", "}", "protected", "void", "consumeClassDeclaration", "(", ")", "{", "super", ".", "consumeClassDeclaration", "(", ")", ";", "if", "(", "isLocalDeclaration", "(", ")", ")", "{", "return", ";", "}", "this", ".", "requestor", ".", "exitClass", "(", "this", ".", "endStatementPosition", ",", "(", "(", "TypeDeclaration", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ")", ".", "declarationSourceEnd", ")", ";", "}", "protected", "void", "consumeClassHeader", "(", ")", "{", "super", ".", "consumeClassHeader", "(", ")", ";", "if", "(", "isLocalDeclaration", "(", ")", ")", "{", "this", ".", "intArrayPtr", "--", ";", "return", ";", "}", "TypeDeclaration", "typeDecl", "=", "(", "TypeDeclaration", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ";", "TypeReference", "[", "]", "superInterfaces", "=", "typeDecl", ".", "superInterfaces", ";", "char", "[", "]", "[", "]", "interfaceNames", "=", "null", ";", "int", "[", "]", "interfaceNameStarts", "=", "null", ";", "int", "[", "]", "interfaceNameEnds", "=", "null", ";", "if", "(", "superInterfaces", "!=", "null", ")", "{", "int", "superInterfacesLength", "=", "superInterfaces", ".", "length", ";", "interfaceNames", "=", "new", "char", "[", "superInterfacesLength", "]", "[", "]", ";", "interfaceNameStarts", "=", "new", "int", "[", "superInterfacesLength", "]", ";", "interfaceNameEnds", "=", "new", "int", "[", "superInterfacesLength", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "superInterfacesLength", ";", "i", "++", ")", "{", "TypeReference", "superInterface", "=", "superInterfaces", "[", "i", "]", ";", "interfaceNames", "[", "i", "]", "=", "CharOperation", ".", "concatWith", "(", "superInterface", ".", "getTypeName", "(", ")", ",", "'.'", ")", ";", "interfaceNameStarts", "[", "i", "]", "=", "superInterface", ".", "sourceStart", ";", "interfaceNameEnds", "[", "i", "]", "=", "superInterface", ".", "sourceEnd", ";", "}", "}", "this", ".", "scanner", ".", "commentPtr", "=", "-", "1", ";", "TypeReference", "superclass", "=", "typeDecl", ".", "superclass", ";", "if", "(", "superclass", "==", "null", ")", "{", "this", ".", "requestor", ".", "enterClass", "(", "typeDecl", ".", "declarationSourceStart", ",", "this", ".", "intArrayStack", "[", "this", ".", "intArrayPtr", "--", "]", ",", "typeDecl", ".", "modifiers", ",", "typeDecl", ".", "modifiersSourceStart", ",", "this", ".", "typeStartPosition", ",", "typeDecl", ".", "name", ",", "typeDecl", ".", "sourceStart", ",", "typeDecl", ".", "sourceEnd", ",", "null", ",", "-", "1", ",", "-", "1", ",", "interfaceNames", ",", "interfaceNameStarts", ",", "interfaceNameEnds", ",", "this", ".", "scanner", ".", "currentPosition", "-", "1", ")", ";", "}", "else", "{", "this", ".", "requestor", ".", "enterClass", "(", "typeDecl", ".", "declarationSourceStart", ",", "this", ".", "intArrayStack", "[", "this", ".", "intArrayPtr", "--", "]", ",", "typeDecl", ".", "modifiers", ",", "typeDecl", ".", "modifiersSourceStart", ",", "this", ".", "typeStartPosition", ",", "typeDecl", ".", "name", ",", "typeDecl", ".", "sourceStart", ",", "typeDecl", ".", "sourceEnd", ",", "CharOperation", ".", "concatWith", "(", "superclass", ".", "getTypeName", "(", ")", ",", "'.'", ")", ",", "superclass", ".", "sourceStart", ",", "superclass", ".", "sourceEnd", ",", "interfaceNames", ",", "interfaceNameStarts", ",", "interfaceNameEnds", ",", "this", ".", "scanner", ".", "currentPosition", "-", "1", ")", ";", "}", "}", "protected", "void", "consumeClassHeaderName1", "(", ")", "{", "TypeDeclaration", "typeDecl", "=", "new", "TypeDeclaration", "(", "this", ".", "compilationUnit", ".", "compilationResult", ")", ";", "if", "(", "this", ".", "nestedMethod", "[", "this", ".", "nestedType", "]", "==", "0", ")", "{", "if", "(", "this", ".", "nestedType", "!=", "0", ")", "{", "typeDecl", ".", "bits", "|=", "ASTNode", ".", "IsMemberType", ";", "}", "}", "else", "{", "typeDecl", ".", "bits", "|=", "ASTNode", ".", "IsLocalType", ";", "markEnclosingMemberWithLocalType", "(", ")", ";", "blockReal", "(", ")", ";", "}", "long", "pos", "=", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "]", ";", "typeDecl", ".", "sourceEnd", "=", "(", "int", ")", "pos", ";", "typeDecl", ".", "sourceStart", "=", "(", "int", ")", "(", "pos", ">>>", "32", ")", ";", "typeDecl", ".", "name", "=", "this", ".", "identifierStack", "[", "this", ".", "identifierPtr", "--", "]", ";", "this", ".", "identifierLengthPtr", "--", ";", "this", ".", "typeStartPosition", "=", "typeDecl", ".", "declarationSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "this", ".", "intPtr", "--", ";", "int", "declSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "typeDecl", ".", "modifiersSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "typeDecl", ".", "modifiers", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "if", "(", "typeDecl", ".", "declarationSourceStart", ">", "declSourceStart", ")", "{", "typeDecl", ".", "declarationSourceStart", "=", "declSourceStart", ";", "}", "int", "length", ";", "if", "(", "(", "length", "=", "this", ".", "expressionLengthStack", "[", "this", ".", "expressionLengthPtr", "--", "]", ")", "!=", "0", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "expressionStack", ",", "(", "this", ".", "expressionPtr", "-=", "length", ")", "+", "1", ",", "typeDecl", ".", "annotations", "=", "new", "Annotation", "[", "length", "]", ",", "0", ",", "length", ")", ";", "}", "typeDecl", ".", "bodyStart", "=", "typeDecl", ".", "sourceEnd", "+", "1", ";", "pushOnAstStack", "(", "typeDecl", ")", ";", "typeDecl", ".", "javadoc", "=", "this", ".", "javadoc", ";", "this", ".", "javadoc", "=", "null", ";", "}", "protected", "void", "consumeCompilationUnit", "(", ")", "{", "this", ".", "requestor", ".", "exitCompilationUnit", "(", "this", ".", "scanner", ".", "source", ".", "length", "-", "1", ")", ";", "}", "protected", "void", "consumeConstructorDeclaration", "(", ")", "{", "super", ".", "consumeConstructorDeclaration", "(", ")", ";", "if", "(", "isLocalDeclaration", "(", ")", ")", "{", "return", ";", "}", "ConstructorDeclaration", "cd", "=", "(", "ConstructorDeclaration", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ";", "this", ".", "requestor", ".", "exitConstructor", "(", "this", ".", "endStatementPosition", ",", "cd", ".", "declarationSourceEnd", ")", ";", "}", "protected", "void", "consumeConstructorHeader", "(", ")", "{", "super", ".", "consumeConstructorHeader", "(", ")", ";", "if", "(", "isLocalDeclaration", "(", ")", ")", "{", "this", ".", "intArrayPtr", "--", ";", "return", ";", "}", "ConstructorDeclaration", "cd", "=", "(", "ConstructorDeclaration", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ";", "Argument", "[", "]", "arguments", "=", "cd", ".", "arguments", ";", "char", "[", "]", "[", "]", "argumentTypes", "=", "null", ";", "char", "[", "]", "[", "]", "argumentNames", "=", "null", ";", "int", "[", "]", "argumentTypeStarts", "=", "null", ";", "int", "[", "]", "argumentTypeEnds", "=", "null", ";", "int", "[", "]", "argumentNameStarts", "=", "null", ";", "int", "[", "]", "argumentNameEnds", "=", "null", ";", "if", "(", "arguments", "!=", "null", ")", "{", "int", "argumentLength", "=", "arguments", ".", "length", ";", "argumentTypes", "=", "new", "char", "[", "argumentLength", "]", "[", "]", ";", "argumentNames", "=", "new", "char", "[", "argumentLength", "]", "[", "]", ";", "argumentNameStarts", "=", "new", "int", "[", "argumentLength", "]", ";", "argumentNameEnds", "=", "new", "int", "[", "argumentLength", "]", ";", "argumentTypeStarts", "=", "new", "int", "[", "argumentLength", "]", ";", "argumentTypeEnds", "=", "new", "int", "[", "argumentLength", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "argumentLength", ";", "i", "++", ")", "{", "Argument", "argument", "=", "arguments", "[", "i", "]", ";", "TypeReference", "argumentType", "=", "argument", ".", "type", ";", "argumentTypes", "[", "i", "]", "=", "returnTypeName", "(", "argumentType", ")", ";", "argumentNames", "[", "i", "]", "=", "argument", ".", "name", ";", "argumentNameStarts", "[", "i", "]", "=", "argument", ".", "sourceStart", ";", "argumentNameEnds", "[", "i", "]", "=", "argument", ".", "sourceEnd", ";", "argumentTypeStarts", "[", "i", "]", "=", "argumentType", ".", "sourceStart", ";", "argumentTypeEnds", "[", "i", "]", "=", "argumentType", ".", "sourceEnd", ";", "}", "}", "TypeReference", "[", "]", "thrownExceptions", "=", "cd", ".", "thrownExceptions", ";", "char", "[", "]", "[", "]", "exceptionTypes", "=", "null", ";", "int", "[", "]", "exceptionTypeStarts", "=", "null", ";", "int", "[", "]", "exceptionTypeEnds", "=", "null", ";", "if", "(", "thrownExceptions", "!=", "null", ")", "{", "int", "thrownExceptionLength", "=", "thrownExceptions", ".", "length", ";", "exceptionTypes", "=", "new", "char", "[", "thrownExceptionLength", "]", "[", "]", ";", "exceptionTypeStarts", "=", "new", "int", "[", "thrownExceptionLength", "]", ";", "exceptionTypeEnds", "=", "new", "int", "[", "thrownExceptionLength", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "thrownExceptionLength", ";", "i", "++", ")", "{", "TypeReference", "exception", "=", "thrownExceptions", "[", "i", "]", ";", "exceptionTypes", "[", "i", "]", "=", "CharOperation", ".", "concatWith", "(", "exception", ".", "getTypeName", "(", ")", ",", "'.'", ")", ";", "exceptionTypeStarts", "[", "i", "]", "=", "exception", ".", "sourceStart", ";", "exceptionTypeEnds", "[", "i", "]", "=", "exception", ".", "sourceEnd", ";", "}", "}", "this", ".", "requestor", ".", "enterConstructor", "(", "cd", ".", "declarationSourceStart", ",", "this", ".", "intArrayStack", "[", "this", ".", "intArrayPtr", "--", "]", ",", "cd", ".", "modifiers", ",", "cd", ".", "modifiersSourceStart", ",", "cd", ".", "selector", ",", "cd", ".", "sourceStart", ",", "(", "int", ")", "(", "this", ".", "selectorSourcePositions", "&", "0xFFFFFFFFL", ")", ",", "argumentTypes", ",", "argumentTypeStarts", ",", "argumentTypeEnds", ",", "argumentNames", ",", "argumentNameStarts", ",", "argumentNameEnds", ",", "this", ".", "rParenPos", ",", "exceptionTypes", ",", "exceptionTypeStarts", ",", "exceptionTypeEnds", ",", "this", ".", "scanner", ".", "currentPosition", "-", "1", ")", ";", "}", "protected", "void", "consumeConstructorHeaderName", "(", ")", "{", "ConstructorDeclaration", "cd", "=", "new", "ConstructorDeclaration", "(", "this", ".", "compilationUnit", ".", "compilationResult", ")", ";", "cd", ".", "selector", "=", "this", ".", "identifierStack", "[", "this", ".", "identifierPtr", "]", ";", "this", ".", "selectorSourcePositions", "=", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "--", "]", ";", "this", ".", "identifierLengthPtr", "--", ";", "cd", ".", "declarationSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "cd", ".", "modifiersSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "cd", ".", "modifiers", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "int", "length", ";", "if", "(", "(", "length", "=", "this", ".", "expressionLengthStack", "[", "this", ".", "expressionLengthPtr", "--", "]", ")", "!=", "0", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "expressionStack", ",", "(", "this", ".", "expressionPtr", "-=", "length", ")", "+", "1", ",", "cd", ".", "annotations", "=", "new", "Annotation", "[", "length", "]", ",", "0", ",", "length", ")", ";", "}", "cd", ".", "javadoc", "=", "this", ".", "javadoc", ";", "this", ".", "javadoc", "=", "null", ";", "cd", ".", "sourceStart", "=", "(", "int", ")", "(", "this", ".", "selectorSourcePositions", ">>>", "32", ")", ";", "pushOnAstStack", "(", "cd", ")", ";", "cd", ".", "sourceEnd", "=", "this", ".", "lParenPos", ";", "cd", ".", "bodyStart", "=", "this", ".", "lParenPos", "+", "1", ";", "}", "protected", "void", "consumeDefaultModifiers", "(", ")", "{", "checkComment", "(", ")", ";", "pushOnIntStack", "(", "this", ".", "modifiers", ")", ";", "pushOnIntStack", "(", "-", "1", ")", ";", "pushOnIntStack", "(", "this", ".", "declarationSourceStart", ">=", "0", "?", "this", ".", "declarationSourceStart", ":", "this", ".", "scanner", ".", "startPosition", ")", ";", "resetModifiers", "(", ")", ";", "pushOnExpressionStackLengthStack", "(", "0", ")", ";", "}", "protected", "void", "consumeDiet", "(", ")", "{", "super", ".", "consumeDiet", "(", ")", ";", "pushOnIntArrayStack", "(", "getJavaDocPositions", "(", ")", ")", ";", "}", "protected", "void", "consumeEnterCompilationUnit", "(", ")", "{", "this", ".", "requestor", ".", "enterCompilationUnit", "(", ")", ";", "}", "protected", "void", "consumeEnterVariable", "(", ")", "{", "boolean", "isLocalDeclaration", "=", "isLocalDeclaration", "(", ")", ";", "if", "(", "!", "isLocalDeclaration", "&&", "(", "this", ".", "variablesCounter", "[", "this", ".", "nestedType", "]", "!=", "0", ")", ")", "{", "this", ".", "requestor", ".", "exitField", "(", "this", ".", "lastFieldBodyEndPosition", ",", "this", ".", "lastFieldEndPosition", ")", ";", "}", "char", "[", "]", "varName", "=", "this", ".", "identifierStack", "[", "this", ".", "identifierPtr", "]", ";", "long", "namePosition", "=", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "--", "]", ";", "int", "extendedTypeDimension", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "AbstractVariableDeclaration", "declaration", ";", "if", "(", "this", ".", "nestedMethod", "[", "this", ".", "nestedType", "]", "!=", "0", ")", "{", "declaration", "=", "new", "LocalDeclaration", "(", "varName", ",", "(", "int", ")", "(", "namePosition", ">>>", "32", ")", ",", "(", "int", ")", "namePosition", ")", ";", "}", "else", "{", "declaration", "=", "new", "FieldDeclaration", "(", "varName", ",", "(", "int", ")", "(", "namePosition", ">>>", "32", ")", ",", "(", "int", ")", "namePosition", ")", ";", "}", "this", ".", "identifierLengthPtr", "--", ";", "TypeReference", "type", ";", "int", "variableIndex", "=", "this", ".", "variablesCounter", "[", "this", ".", "nestedType", "]", ";", "int", "typeDim", "=", "0", ";", "if", "(", "variableIndex", "==", "0", ")", "{", "if", "(", "this", ".", "nestedMethod", "[", "this", ".", "nestedType", "]", "!=", "0", ")", "{", "declaration", ".", "declarationSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "declaration", ".", "modifiersSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "declaration", ".", "modifiers", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "type", "=", "getTypeReference", "(", "typeDim", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ")", ";", "pushOnAstStack", "(", "type", ")", ";", "}", "else", "{", "type", "=", "getTypeReference", "(", "typeDim", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ")", ";", "pushOnAstStack", "(", "type", ")", ";", "declaration", ".", "declarationSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "declaration", ".", "modifiersSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "declaration", ".", "modifiers", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "}", "int", "length", ";", "if", "(", "(", "length", "=", "this", ".", "expressionLengthStack", "[", "this", ".", "expressionLengthPtr", "--", "]", ")", "!=", "0", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "expressionStack", ",", "(", "this", ".", "expressionPtr", "-=", "length", ")", "+", "1", ",", "declaration", ".", "annotations", "=", "new", "Annotation", "[", "length", "]", ",", "0", ",", "length", ")", ";", "}", "}", "else", "{", "type", "=", "(", "TypeReference", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "-", "variableIndex", "]", ";", "typeDim", "=", "type", ".", "dimensions", "(", ")", ";", "AbstractVariableDeclaration", "previousVariable", "=", "(", "AbstractVariableDeclaration", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ";", "declaration", ".", "declarationSourceStart", "=", "previousVariable", ".", "declarationSourceStart", ";", "declaration", ".", "modifiers", "=", "previousVariable", ".", "modifiers", ";", "declaration", ".", "modifiersSourceStart", "=", "previousVariable", ".", "modifiersSourceStart", ";", "final", "Annotation", "[", "]", "annotations", "=", "previousVariable", ".", "annotations", ";", "if", "(", "annotations", "!=", "null", ")", "{", "final", "int", "annotationsLength", "=", "annotations", ".", "length", ";", "System", ".", "arraycopy", "(", "annotations", ",", "0", ",", "declaration", ".", "annotations", "=", "new", "Annotation", "[", "annotationsLength", "]", ",", "0", ",", "annotationsLength", ")", ";", "}", "}", "this", ".", "localIntPtr", "=", "this", ".", "intPtr", ";", "if", "(", "extendedTypeDimension", "==", "0", ")", "{", "declaration", ".", "type", "=", "type", ";", "}", "else", "{", "int", "dimension", "=", "typeDim", "+", "extendedTypeDimension", ";", "declaration", ".", "type", "=", "copyDims", "(", "type", ",", "dimension", ")", ";", "}", "this", ".", "variablesCounter", "[", "this", ".", "nestedType", "]", "++", ";", "this", ".", "nestedMethod", "[", "this", ".", "nestedType", "]", "++", ";", "pushOnAstStack", "(", "declaration", ")", ";", "int", "[", "]", "javadocPositions", "=", "this", ".", "intArrayStack", "[", "this", ".", "intArrayPtr", "]", ";", "if", "(", "!", "isLocalDeclaration", ")", "{", "this", ".", "requestor", ".", "enterField", "(", "declaration", ".", "declarationSourceStart", ",", "javadocPositions", ",", "declaration", ".", "modifiers", ",", "declaration", ".", "modifiersSourceStart", ",", "returnTypeName", "(", "declaration", ".", "type", ")", ",", "type", ".", "sourceStart", ",", "type", ".", "sourceEnd", ",", "this", ".", "typeDims", ",", "varName", ",", "(", "int", ")", "(", "namePosition", ">>>", "32", ")", ",", "(", "int", ")", "namePosition", ",", "extendedTypeDimension", ",", "extendedTypeDimension", "==", "0", "?", "-", "1", ":", "this", ".", "endPosition", ")", ";", "}", "}", "protected", "void", "consumeExitVariableWithInitialization", "(", ")", "{", "super", ".", "consumeExitVariableWithInitialization", "(", ")", ";", "this", ".", "nestedMethod", "[", "this", ".", "nestedType", "]", "--", ";", "this", ".", "lastFieldEndPosition", "=", "this", ".", "scanner", ".", "currentPosition", "-", "1", ";", "this", ".", "lastFieldBodyEndPosition", "=", "(", "(", "AbstractVariableDeclaration", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ")", ".", "initialization", ".", "sourceEnd", ";", "}", "protected", "void", "consumeExitVariableWithoutInitialization", "(", ")", "{", "super", ".", "consumeExitVariableWithoutInitialization", "(", ")", ";", "this", ".", "nestedMethod", "[", "this", ".", "nestedType", "]", "--", ";", "this", ".", "lastFieldEndPosition", "=", "this", ".", "scanner", ".", "currentPosition", "-", "1", ";", "this", ".", "lastFieldBodyEndPosition", "=", "this", ".", "scanner", ".", "startPosition", "-", "1", ";", "}", "protected", "void", "consumeFieldDeclaration", "(", ")", "{", "int", "variableIndex", "=", "this", ".", "variablesCounter", "[", "this", ".", "nestedType", "]", ";", "super", ".", "consumeFieldDeclaration", "(", ")", ";", "this", ".", "intArrayPtr", "--", ";", "if", "(", "isLocalDeclaration", "(", ")", ")", "return", ";", "if", "(", "variableIndex", "!=", "0", ")", "{", "this", ".", "requestor", ".", "exitField", "(", "this", ".", "lastFieldBodyEndPosition", ",", "this", ".", "lastFieldEndPosition", ")", ";", "}", "}", "protected", "void", "consumeFormalParameter", "(", "boolean", "isVarArgs", ")", "{", "this", ".", "identifierLengthPtr", "--", ";", "char", "[", "]", "parameterName", "=", "this", ".", "identifierStack", "[", "this", ".", "identifierPtr", "]", ";", "long", "namePositions", "=", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "--", "]", ";", "int", "extendedDimensions", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "int", "endOfEllipsis", "=", "0", ";", "if", "(", "isVarArgs", ")", "{", "endOfEllipsis", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "}", "int", "firstDimensions", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "final", "int", "typeDimensions", "=", "firstDimensions", "+", "extendedDimensions", ";", "TypeReference", "type", "=", "getTypeReference", "(", "typeDimensions", ")", ";", "if", "(", "isVarArgs", ")", "{", "type", "=", "copyDims", "(", "type", ",", "typeDimensions", "+", "1", ")", ";", "if", "(", "extendedDimensions", "==", "0", ")", "{", "type", ".", "sourceEnd", "=", "endOfEllipsis", ";", "}", "type", ".", "bits", "|=", "ASTNode", ".", "IsVarArgs", ";", "}", "this", ".", "intPtr", "-=", "3", ";", "Argument", "arg", "=", "new", "Argument", "(", "parameterName", ",", "namePositions", ",", "type", ",", "this", ".", "intStack", "[", "this", ".", "intPtr", "+", "1", "]", ")", ";", "int", "length", ";", "if", "(", "(", "length", "=", "this", ".", "expressionLengthStack", "[", "this", ".", "expressionLengthPtr", "--", "]", ")", "!=", "0", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "expressionStack", ",", "(", "this", ".", "expressionPtr", "-=", "length", ")", "+", "1", ",", "arg", ".", "annotations", "=", "new", "Annotation", "[", "length", "]", ",", "0", ",", "length", ")", ";", "}", "pushOnAstStack", "(", "arg", ")", ";", "this", ".", "intArrayPtr", "--", ";", "}", "protected", "void", "consumeInterfaceDeclaration", "(", ")", "{", "super", ".", "consumeInterfaceDeclaration", "(", ")", ";", "if", "(", "isLocalDeclaration", "(", ")", ")", "{", "return", ";", "}", "this", ".", "requestor", ".", "exitInterface", "(", "this", ".", "endStatementPosition", ",", "(", "(", "TypeDeclaration", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ")", ".", "declarationSourceEnd", ")", ";", "}", "protected", "void", "consumeInterfaceHeader", "(", ")", "{", "super", ".", "consumeInterfaceHeader", "(", ")", ";", "if", "(", "isLocalDeclaration", "(", ")", ")", "{", "this", ".", "intArrayPtr", "--", ";", "return", ";", "}", "TypeDeclaration", "typeDecl", "=", "(", "TypeDeclaration", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ";", "TypeReference", "[", "]", "superInterfaces", "=", "typeDecl", ".", "superInterfaces", ";", "char", "[", "]", "[", "]", "interfaceNames", "=", "null", ";", "int", "[", "]", "interfaceNameStarts", "=", "null", ";", "int", "[", "]", "interfacenameEnds", "=", "null", ";", "int", "superInterfacesLength", "=", "0", ";", "if", "(", "superInterfaces", "!=", "null", ")", "{", "superInterfacesLength", "=", "superInterfaces", ".", "length", ";", "interfaceNames", "=", "new", "char", "[", "superInterfacesLength", "]", "[", "]", ";", "interfaceNameStarts", "=", "new", "int", "[", "superInterfacesLength", "]", ";", "interfacenameEnds", "=", "new", "int", "[", "superInterfacesLength", "]", ";", "}", "if", "(", "superInterfaces", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "superInterfacesLength", ";", "i", "++", ")", "{", "TypeReference", "superInterface", "=", "superInterfaces", "[", "i", "]", ";", "interfaceNames", "[", "i", "]", "=", "CharOperation", ".", "concatWith", "(", "superInterface", ".", "getTypeName", "(", ")", ",", "'.'", ")", ";", "interfaceNameStarts", "[", "i", "]", "=", "superInterface", ".", "sourceStart", ";", "interfacenameEnds", "[", "i", "]", "=", "superInterface", ".", "sourceEnd", ";", "}", "}", "this", ".", "scanner", ".", "commentPtr", "=", "-", "1", ";", "this", ".", "requestor", ".", "enterInterface", "(", "typeDecl", ".", "declarationSourceStart", ",", "this", ".", "intArrayStack", "[", "this", ".", "intArrayPtr", "--", "]", ",", "typeDecl", ".", "modifiers", ",", "typeDecl", ".", "modifiersSourceStart", ",", "this", ".", "typeStartPosition", ",", "typeDecl", ".", "name", ",", "typeDecl", ".", "sourceStart", ",", "typeDecl", ".", "sourceEnd", ",", "interfaceNames", ",", "interfaceNameStarts", ",", "interfacenameEnds", ",", "this", ".", "scanner", ".", "currentPosition", "-", "1", ")", ";", "}", "protected", "void", "consumeInterfaceHeaderName1", "(", ")", "{", "TypeDeclaration", "typeDecl", "=", "new", "TypeDeclaration", "(", "this", ".", "compilationUnit", ".", "compilationResult", ")", ";", "if", "(", "this", ".", "nestedMethod", "[", "this", ".", "nestedType", "]", "==", "0", ")", "{", "if", "(", "this", ".", "nestedType", "!=", "0", ")", "{", "typeDecl", ".", "bits", "|=", "ASTNode", ".", "IsMemberType", ";", "}", "}", "else", "{", "typeDecl", ".", "bits", "|=", "ASTNode", ".", "IsLocalType", ";", "markEnclosingMemberWithLocalType", "(", ")", ";", "blockReal", "(", ")", ";", "}", "long", "pos", "=", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "]", ";", "typeDecl", ".", "sourceEnd", "=", "(", "int", ")", "pos", ";", "typeDecl", ".", "sourceStart", "=", "(", "int", ")", "(", "pos", ">>>", "32", ")", ";", "typeDecl", ".", "name", "=", "this", ".", "identifierStack", "[", "this", ".", "identifierPtr", "--", "]", ";", "this", ".", "identifierLengthPtr", "--", ";", "this", ".", "typeStartPosition", "=", "typeDecl", ".", "declarationSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "this", ".", "intPtr", "--", ";", "int", "declSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "typeDecl", ".", "modifiersSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "typeDecl", ".", "modifiers", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", "|", "ClassFileConstants", ".", "AccInterface", ";", "if", "(", "typeDecl", ".", "declarationSourceStart", ">", "declSourceStart", ")", "{", "typeDecl", ".", "declarationSourceStart", "=", "declSourceStart", ";", "}", "int", "length", ";", "if", "(", "(", "length", "=", "this", ".", "expressionLengthStack", "[", "this", ".", "expressionLengthPtr", "--", "]", ")", "!=", "0", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "expressionStack", ",", "(", "this", ".", "expressionPtr", "-=", "length", ")", "+", "1", ",", "typeDecl", ".", "annotations", "=", "new", "Annotation", "[", "length", "]", ",", "0", ",", "length", ")", ";", "}", "typeDecl", ".", "bodyStart", "=", "typeDecl", ".", "sourceEnd", "+", "1", ";", "pushOnAstStack", "(", "typeDecl", ")", ";", "typeDecl", ".", "javadoc", "=", "this", ".", "javadoc", ";", "this", ".", "javadoc", "=", "null", ";", "}", "protected", "void", "consumeInternalCompilationUnit", "(", ")", "{", "}", "protected", "void", "consumeInternalCompilationUnitWithTypes", "(", ")", "{", "int", "length", ";", "if", "(", "(", "length", "=", "this", ".", "astLengthStack", "[", "this", ".", "astLengthPtr", "--", "]", ")", "!=", "0", ")", "{", "this", ".", "compilationUnit", ".", "types", "=", "new", "TypeDeclaration", "[", "length", "]", ";", "this", ".", "astPtr", "-=", "length", ";", "System", ".", "arraycopy", "(", "this", ".", "astStack", ",", "this", ".", "astPtr", "+", "1", ",", "this", ".", "compilationUnit", ".", "types", ",", "0", ",", "length", ")", ";", "}", "}", "protected", "void", "consumeLocalVariableDeclaration", "(", ")", "{", "super", ".", "consumeLocalVariableDeclaration", "(", ")", ";", "this", ".", "intArrayPtr", "--", ";", "}", "protected", "void", "consumeMethodDeclaration", "(", "boolean", "isNotAbstract", ")", "{", "super", ".", "consumeMethodDeclaration", "(", "isNotAbstract", ")", ";", "if", "(", "isLocalDeclaration", "(", ")", ")", "{", "return", ";", "}", "MethodDeclaration", "md", "=", "(", "MethodDeclaration", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ";", "this", ".", "requestor", ".", "exitMethod", "(", "this", ".", "endStatementPosition", ",", "md", ".", "declarationSourceEnd", ")", ";", "}", "protected", "void", "consumeMethodHeader", "(", ")", "{", "super", ".", "consumeMethodHeader", "(", ")", ";", "if", "(", "isLocalDeclaration", "(", ")", ")", "{", "this", ".", "intArrayPtr", "--", ";", "return", ";", "}", "MethodDeclaration", "md", "=", "(", "MethodDeclaration", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ";", "TypeReference", "returnType", "=", "md", ".", "returnType", ";", "char", "[", "]", "returnTypeName", "=", "returnTypeName", "(", "returnType", ")", ";", "Argument", "[", "]", "arguments", "=", "md", ".", "arguments", ";", "char", "[", "]", "[", "]", "argumentTypes", "=", "null", ";", "char", "[", "]", "[", "]", "argumentNames", "=", "null", ";", "int", "[", "]", "argumentTypeStarts", "=", "null", ";", "int", "[", "]", "argumentTypeEnds", "=", "null", ";", "int", "[", "]", "argumentNameStarts", "=", "null", ";", "int", "[", "]", "argumentNameEnds", "=", "null", ";", "if", "(", "arguments", "!=", "null", ")", "{", "int", "argumentLength", "=", "arguments", ".", "length", ";", "argumentTypes", "=", "new", "char", "[", "argumentLength", "]", "[", "]", ";", "argumentNames", "=", "new", "char", "[", "argumentLength", "]", "[", "]", ";", "argumentNameStarts", "=", "new", "int", "[", "argumentLength", "]", ";", "argumentNameEnds", "=", "new", "int", "[", "argumentLength", "]", ";", "argumentTypeStarts", "=", "new", "int", "[", "argumentLength", "]", ";", "argumentTypeEnds", "=", "new", "int", "[", "argumentLength", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "argumentLength", ";", "i", "++", ")", "{", "Argument", "argument", "=", "arguments", "[", "i", "]", ";", "TypeReference", "argumentType", "=", "argument", ".", "type", ";", "argumentTypes", "[", "i", "]", "=", "returnTypeName", "(", "argumentType", ")", ";", "argumentNames", "[", "i", "]", "=", "argument", ".", "name", ";", "argumentNameStarts", "[", "i", "]", "=", "argument", ".", "sourceStart", ";", "argumentNameEnds", "[", "i", "]", "=", "argument", ".", "sourceEnd", ";", "argumentTypeStarts", "[", "i", "]", "=", "argumentType", ".", "sourceStart", ";", "argumentTypeEnds", "[", "i", "]", "=", "argumentType", ".", "sourceEnd", ";", "}", "}", "TypeReference", "[", "]", "thrownExceptions", "=", "md", ".", "thrownExceptions", ";", "char", "[", "]", "[", "]", "exceptionTypes", "=", "null", ";", "int", "[", "]", "exceptionTypeStarts", "=", "null", ";", "int", "[", "]", "exceptionTypeEnds", "=", "null", ";", "if", "(", "thrownExceptions", "!=", "null", ")", "{", "int", "thrownExceptionLength", "=", "thrownExceptions", ".", "length", ";", "exceptionTypeStarts", "=", "new", "int", "[", "thrownExceptionLength", "]", ";", "exceptionTypeEnds", "=", "new", "int", "[", "thrownExceptionLength", "]", ";", "exceptionTypes", "=", "new", "char", "[", "thrownExceptionLength", "]", "[", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "thrownExceptionLength", ";", "i", "++", ")", "{", "TypeReference", "exception", "=", "thrownExceptions", "[", "i", "]", ";", "exceptionTypes", "[", "i", "]", "=", "CharOperation", ".", "concatWith", "(", "exception", ".", "getTypeName", "(", ")", ",", "'.'", ")", ";", "exceptionTypeStarts", "[", "i", "]", "=", "exception", ".", "sourceStart", ";", "exceptionTypeEnds", "[", "i", "]", "=", "exception", ".", "sourceEnd", ";", "}", "}", "this", ".", "requestor", ".", "enterMethod", "(", "md", ".", "declarationSourceStart", ",", "this", ".", "intArrayStack", "[", "this", ".", "intArrayPtr", "--", "]", ",", "md", ".", "modifiers", ",", "md", ".", "modifiersSourceStart", ",", "returnTypeName", ",", "returnType", ".", "sourceStart", ",", "returnType", ".", "sourceEnd", ",", "this", ".", "typeDims", ",", "md", ".", "selector", ",", "md", ".", "sourceStart", ",", "(", "int", ")", "(", "this", ".", "selectorSourcePositions", "&", "0xFFFFFFFFL", ")", ",", "argumentTypes", ",", "argumentTypeStarts", ",", "argumentTypeEnds", ",", "argumentNames", ",", "argumentNameStarts", ",", "argumentNameEnds", ",", "this", ".", "rParenPos", ",", "this", ".", "extendsDim", ",", "this", ".", "extendsDim", "==", "0", "?", "-", "1", ":", "this", ".", "endPosition", ",", "exceptionTypes", ",", "exceptionTypeStarts", ",", "exceptionTypeEnds", ",", "this", ".", "scanner", ".", "currentPosition", "-", "1", ")", ";", "}", "protected", "void", "consumeMethodHeaderExtendedDims", "(", ")", "{", "MethodDeclaration", "md", "=", "(", "MethodDeclaration", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ";", "int", "extendedDims", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "this", ".", "extendsDim", "=", "extendedDims", ";", "if", "(", "extendedDims", "!=", "0", ")", "{", "TypeReference", "returnType", "=", "md", ".", "returnType", ";", "md", ".", "sourceEnd", "=", "this", ".", "endPosition", ";", "int", "dims", "=", "returnType", ".", "dimensions", "(", ")", "+", "extendedDims", ";", "md", ".", "returnType", "=", "copyDims", "(", "returnType", ",", "dims", ")", ";", "if", "(", "this", ".", "currentToken", "==", "TokenNameLBRACE", ")", "{", "md", ".", "bodyStart", "=", "this", ".", "endPosition", "+", "1", ";", "}", "}", "}", "protected", "void", "consumeMethodHeaderName", "(", "boolean", "isAnnotationMethod", ")", "{", "MethodDeclaration", "md", "=", "null", ";", "if", "(", "isAnnotationMethod", ")", "{", "md", "=", "new", "AnnotationMethodDeclaration", "(", "this", ".", "compilationUnit", ".", "compilationResult", ")", ";", "}", "else", "{", "md", "=", "new", "MethodDeclaration", "(", "this", ".", "compilationUnit", ".", "compilationResult", ")", ";", "}", "md", ".", "selector", "=", "this", ".", "identifierStack", "[", "this", ".", "identifierPtr", "]", ";", "this", ".", "selectorSourcePositions", "=", "this", ".", "identifierPositionStack", "[", "this", ".", "identifierPtr", "--", "]", ";", "this", ".", "identifierLengthPtr", "--", ";", "md", ".", "returnType", "=", "getTypeReference", "(", "this", ".", "typeDims", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ")", ";", "md", ".", "declarationSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "md", ".", "modifiersSourceStart", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "md", ".", "modifiers", "=", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ";", "int", "length", ";", "if", "(", "(", "length", "=", "this", ".", "expressionLengthStack", "[", "this", ".", "expressionLengthPtr", "--", "]", ")", "!=", "0", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "expressionStack", ",", "(", "this", ".", "expressionPtr", "-=", "length", ")", "+", "1", ",", "md", ".", "annotations", "=", "new", "Annotation", "[", "length", "]", ",", "0", ",", "length", ")", ";", "}", "md", ".", "javadoc", "=", "this", ".", "javadoc", ";", "this", ".", "javadoc", "=", "null", ";", "md", ".", "sourceStart", "=", "(", "int", ")", "(", "this", ".", "selectorSourcePositions", ">>>", "32", ")", ";", "pushOnAstStack", "(", "md", ")", ";", "md", ".", "bodyStart", "=", "this", ".", "scanner", ".", "currentPosition", "-", "1", ";", "}", "protected", "void", "consumeModifiers", "(", ")", "{", "checkComment", "(", ")", ";", "pushOnIntStack", "(", "this", ".", "modifiers", ")", ";", "pushOnIntStack", "(", "this", ".", "modifiersSourceStart", ")", ";", "pushOnIntStack", "(", "this", ".", "declarationSourceStart", ">=", "0", "?", "this", ".", "declarationSourceStart", ":", "this", ".", "modifiersSourceStart", ")", ";", "resetModifiers", "(", ")", ";", "}", "protected", "void", "consumePackageComment", "(", ")", "{", "if", "(", "this", ".", "options", ".", "sourceLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "checkComment", "(", ")", ";", "}", "else", "{", "pushOnIntArrayStack", "(", "getJavaDocPositions", "(", ")", ")", ";", "}", "resetModifiers", "(", ")", ";", "}", "protected", "void", "consumePackageDeclarationName", "(", ")", "{", "super", ".", "consumePackageDeclarationName", "(", ")", ";", "ImportReference", "importReference", "=", "this", ".", "compilationUnit", ".", "currentPackage", ";", "this", ".", "requestor", ".", "acceptPackage", "(", "importReference", ".", "declarationSourceStart", ",", "importReference", ".", "declarationSourceEnd", ",", "this", ".", "intArrayStack", "[", "this", ".", "intArrayPtr", "--", "]", ",", "CharOperation", ".", "concatWith", "(", "importReference", ".", "getImportName", "(", ")", ",", "'.'", ")", ",", "importReference", ".", "sourceStart", ")", ";", "}", "protected", "void", "consumePackageDeclarationNameWithModifiers", "(", ")", "{", "super", ".", "consumePackageDeclarationNameWithModifiers", "(", ")", ";", "ImportReference", "importReference", "=", "this", ".", "compilationUnit", ".", "currentPackage", ";", "this", ".", "requestor", ".", "acceptPackage", "(", "importReference", ".", "declarationSourceStart", ",", "importReference", ".", "declarationSourceEnd", ",", "this", ".", "intArrayStack", "[", "this", ".", "intArrayPtr", "--", "]", ",", "CharOperation", ".", "concatWith", "(", "importReference", ".", "getImportName", "(", ")", ",", "'.'", ")", ",", "importReference", ".", "sourceStart", ")", ";", "}", "protected", "void", "consumePushModifiers", "(", ")", "{", "checkComment", "(", ")", ";", "pushOnIntStack", "(", "this", ".", "modifiers", ")", ";", "if", "(", "this", ".", "modifiersSourceStart", "<", "0", ")", "{", "pushOnIntStack", "(", "-", "1", ")", ";", "pushOnIntStack", "(", "this", ".", "declarationSourceStart", ">=", "0", "?", "this", ".", "declarationSourceStart", ":", "this", ".", "scanner", ".", "startPosition", ")", ";", "}", "else", "{", "pushOnIntStack", "(", "this", ".", "modifiersSourceStart", ")", ";", "pushOnIntStack", "(", "this", ".", "declarationSourceStart", ">=", "0", "?", "this", ".", "declarationSourceStart", ":", "this", ".", "modifiersSourceStart", ")", ";", "}", "resetModifiers", "(", ")", ";", "pushOnExpressionStackLengthStack", "(", "0", ")", ";", "}", "protected", "void", "consumePushRealModifiers", "(", ")", "{", "checkComment", "(", ")", ";", "pushOnIntStack", "(", "this", ".", "modifiers", ")", ";", "if", "(", "this", ".", "modifiersSourceStart", "<", "0", ")", "{", "pushOnIntStack", "(", "-", "1", ")", ";", "pushOnIntStack", "(", "this", ".", "declarationSourceStart", ">=", "0", "?", "this", ".", "declarationSourceStart", ":", "this", ".", "scanner", ".", "startPosition", ")", ";", "}", "else", "{", "pushOnIntStack", "(", "this", ".", "modifiersSourceStart", ")", ";", "pushOnIntStack", "(", "this", ".", "declarationSourceStart", ">=", "0", "?", "this", ".", "declarationSourceStart", ":", "this", ".", "modifiersSourceStart", ")", ";", "}", "resetModifiers", "(", ")", ";", "}", "protected", "void", "consumeSingleStaticImportDeclarationName", "(", ")", "{", "pushOnIntArrayStack", "(", "getJavaDocPositions", "(", ")", ")", ";", "super", ".", "consumeSingleStaticImportDeclarationName", "(", ")", ";", "ImportReference", "importReference", "=", "(", "ImportReference", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ";", "this", ".", "requestor", ".", "acceptImport", "(", "importReference", ".", "declarationSourceStart", ",", "importReference", ".", "declarationSourceEnd", ",", "this", ".", "intArrayStack", "[", "this", ".", "intArrayPtr", "--", "]", ",", "CharOperation", ".", "concatWith", "(", "importReference", ".", "getImportName", "(", ")", ",", "'.'", ")", ",", "importReference", ".", "sourceStart", ",", "false", ",", "ClassFileConstants", ".", "AccStatic", ")", ";", "}", "protected", "void", "consumeSingleTypeImportDeclarationName", "(", ")", "{", "pushOnIntArrayStack", "(", "getJavaDocPositions", "(", ")", ")", ";", "super", ".", "consumeSingleTypeImportDeclarationName", "(", ")", ";", "ImportReference", "importReference", "=", "(", "ImportReference", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ";", "this", ".", "requestor", ".", "acceptImport", "(", "importReference", ".", "declarationSourceStart", ",", "importReference", ".", "declarationSourceEnd", ",", "this", ".", "intArrayStack", "[", "this", ".", "intArrayPtr", "--", "]", ",", "CharOperation", ".", "concatWith", "(", "importReference", ".", "getImportName", "(", ")", ",", "'.'", ")", ",", "importReference", ".", "sourceStart", ",", "false", ",", "ClassFileConstants", ".", "AccDefault", ")", ";", "}", "protected", "void", "consumeStaticImportOnDemandDeclarationName", "(", ")", "{", "pushOnIntArrayStack", "(", "getJavaDocPositions", "(", ")", ")", ";", "super", ".", "consumeStaticImportOnDemandDeclarationName", "(", ")", ";", "ImportReference", "importReference", "=", "(", "ImportReference", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ";", "this", ".", "requestor", ".", "acceptImport", "(", "importReference", ".", "declarationSourceStart", ",", "importReference", ".", "declarationSourceEnd", ",", "this", ".", "intArrayStack", "[", "this", ".", "intArrayPtr", "--", "]", ",", "CharOperation", ".", "concatWith", "(", "importReference", ".", "getImportName", "(", ")", ",", "'.'", ")", ",", "importReference", ".", "sourceStart", ",", "true", ",", "ClassFileConstants", ".", "AccStatic", ")", ";", "}", "protected", "void", "consumeStaticInitializer", "(", ")", "{", "super", ".", "consumeStaticInitializer", "(", ")", ";", "Initializer", "initializer", "=", "(", "Initializer", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ";", "this", ".", "requestor", ".", "acceptInitializer", "(", "initializer", ".", "declarationSourceStart", ",", "initializer", ".", "declarationSourceEnd", ",", "this", ".", "intArrayStack", "[", "this", ".", "intArrayPtr", "--", "]", ",", "ClassFileConstants", ".", "AccStatic", ",", "this", ".", "intStack", "[", "this", ".", "intPtr", "--", "]", ",", "initializer", ".", "block", ".", "sourceStart", ",", "initializer", ".", "declarationSourceEnd", ")", ";", "}", "protected", "void", "consumeStaticOnly", "(", ")", "{", "checkComment", "(", ")", ";", "pushOnIntStack", "(", "this", ".", "modifiersSourceStart", ")", ";", "pushOnIntStack", "(", "this", ".", "scanner", ".", "currentPosition", ")", ";", "pushOnIntStack", "(", "this", ".", "declarationSourceStart", ">=", "0", "?", "this", ".", "declarationSourceStart", ":", "this", ".", "modifiersSourceStart", ")", ";", "jumpOverMethodBody", "(", ")", ";", "this", ".", "nestedMethod", "[", "this", ".", "nestedType", "]", "++", ";", "resetModifiers", "(", ")", ";", "}", "protected", "void", "consumeTypeImportOnDemandDeclarationName", "(", ")", "{", "pushOnIntArrayStack", "(", "getJavaDocPositions", "(", ")", ")", ";", "super", ".", "consumeTypeImportOnDemandDeclarationName", "(", ")", ";", "ImportReference", "importReference", "=", "(", "ImportReference", ")", "this", ".", "astStack", "[", "this", ".", "astPtr", "]", ";", "this", ".", "requestor", ".", "acceptImport", "(", "importReference", ".", "declarationSourceStart", ",", "importReference", ".", "declarationSourceEnd", ",", "this", ".", "intArrayStack", "[", "this", ".", "intArrayPtr", "--", "]", ",", "CharOperation", ".", "concatWith", "(", "importReference", ".", "getImportName", "(", ")", ",", "'.'", ")", ",", "importReference", ".", "sourceStart", ",", "true", ",", "ClassFileConstants", ".", "AccDefault", ")", ";", "}", "public", "int", "flushCommentsDefinedPriorTo", "(", "int", "position", ")", "{", "return", "this", ".", "lastFieldEndPosition", "=", "super", ".", "flushCommentsDefinedPriorTo", "(", "position", ")", ";", "}", "public", "CompilationUnitDeclaration", "endParse", "(", "int", "act", ")", "{", "if", "(", "this", ".", "scanner", ".", "recordLineSeparator", ")", "{", "this", ".", "requestor", ".", "acceptLineSeparatorPositions", "(", "this", ".", "scanner", ".", "getLineEnds", "(", ")", ")", ";", "}", "return", "super", ".", "endParse", "(", "act", ")", ";", "}", "public", "void", "initialize", "(", "boolean", "initializeNLS", ")", "{", "super", ".", "initialize", "(", "initializeNLS", ")", ";", "this", ".", "intArrayPtr", "=", "-", "1", ";", "}", "public", "void", "initialize", "(", ")", "{", "super", ".", "initialize", "(", ")", ";", "this", ".", "intArrayPtr", "=", "-", "1", ";", "}", "private", "boolean", "isLocalDeclaration", "(", ")", "{", "int", "nestedDepth", "=", "this", ".", "nestedType", ";", "while", "(", "nestedDepth", ">=", "0", ")", "{", "if", "(", "this", ".", "nestedMethod", "[", "nestedDepth", "]", "!=", "0", ")", "{", "return", "true", ";", "}", "nestedDepth", "--", ";", "}", "return", "false", ";", "}", "protected", "void", "parse", "(", ")", "{", "this", ".", "diet", "=", "true", ";", "super", ".", "parse", "(", ")", ";", "}", "public", "void", "parseCompilationUnit", "(", "ICompilationUnit", "unit", ")", "{", "char", "[", "]", "regionSource", "=", "unit", ".", "getContents", "(", ")", ";", "try", "{", "initialize", "(", "true", ")", ";", "goForCompilationUnit", "(", ")", ";", "this", ".", "referenceContext", "=", "this", ".", "compilationUnit", "=", "new", "CompilationUnitDeclaration", "(", "problemReporter", "(", ")", ",", "new", "CompilationResult", "(", "unit", ",", "0", ",", "0", ",", "this", ".", "options", ".", "maxProblemsPerUnit", ")", ",", "regionSource", ".", "length", ")", ";", "this", ".", "scanner", ".", "resetTo", "(", "0", ",", "regionSource", ".", "length", ")", ";", "this", ".", "scanner", ".", "setSource", "(", "regionSource", ")", ";", "parse", "(", ")", ";", "}", "catch", "(", "AbortCompilation", "ex", ")", "{", "}", "}", "public", "void", "parseConstructor", "(", "char", "[", "]", "regionSource", ")", "{", "try", "{", "initialize", "(", ")", ";", "goForClassBodyDeclarations", "(", ")", ";", "this", ".", "referenceContext", "=", "this", ".", "compilationUnit", "=", "new", "CompilationUnitDeclaration", "(", "problemReporter", "(", ")", ",", "new", "CompilationResult", "(", "regionSource", ",", "0", ",", "0", ",", "this", ".", "options", ".", "maxProblemsPerUnit", ")", ",", "regionSource", ".", "length", ")", ";", "this", ".", "scanner", ".", "resetTo", "(", "0", ",", "regionSource", ".", "length", ")", ";", "this", ".", "scanner", ".", "setSource", "(", "regionSource", ")", ";", "parse", "(", ")", ";", "}", "catch", "(", "AbortCompilation", "ex", ")", "{", "}", "}", "public", "void", "parseField", "(", "char", "[", "]", "regionSource", ")", "{", "try", "{", "initialize", "(", ")", ";", "goForFieldDeclaration", "(", ")", ";", "this", ".", "referenceContext", "=", "this", ".", "compilationUnit", "=", "new", "CompilationUnitDeclaration", "(", "problemReporter", "(", ")", ",", "new", "CompilationResult", "(", "regionSource", ",", "0", ",", "0", ",", "this", ".", "options", ".", "maxProblemsPerUnit", ")", ",", "regionSource", ".", "length", ")", ";", "this", ".", "scanner", ".", "resetTo", "(", "0", ",", "regionSource", ".", "length", ")", ";", "this", ".", "scanner", ".", "setSource", "(", "regionSource", ")", ";", "parse", "(", ")", ";", "}", "catch", "(", "AbortCompilation", "ex", ")", "{", "}", "}", "public", "void", "parseImport", "(", "char", "[", "]", "regionSource", ")", "{", "try", "{", "initialize", "(", ")", ";", "goForImportDeclaration", "(", ")", ";", "this", ".", "referenceContext", "=", "this", ".", "compilationUnit", "=", "new", "CompilationUnitDeclaration", "(", "problemReporter", "(", ")", ",", "new", "CompilationResult", "(", "regionSource", ",", "0", ",", "0", ",", "this", ".", "options", ".", "maxProblemsPerUnit", ")", ",", "regionSource", ".", "length", ")", ";", "this", ".", "scanner", ".", "resetTo", "(", "0", ",", "regionSource", ".", "length", ")", ";", "this", ".", "scanner", ".", "setSource", "(", "regionSource", ")", ";", "parse", "(", ")", ";", "}", "catch", "(", "AbortCompilation", "ex", ")", "{", "}", "}", "public", "void", "parseInitializer", "(", "char", "[", "]", "regionSource", ")", "{", "try", "{", "initialize", "(", ")", ";", "goForInitializer", "(", ")", ";", "this", ".", "referenceContext", "=", "this", ".", "compilationUnit", "=", "new", "CompilationUnitDeclaration", "(", "problemReporter", "(", ")", ",", "new", "CompilationResult", "(", "regionSource", ",", "0", ",", "0", ",", "this", ".", "options", ".", "maxProblemsPerUnit", ")", ",", "regionSource", ".", "length", ")", ";", "this", ".", "scanner", ".", "resetTo", "(", "0", ",", "regionSource", ".", "length", ")", ";", "this", ".", "scanner", ".", "setSource", "(", "regionSource", ")", ";", "parse", "(", ")", ";", "}", "catch", "(", "AbortCompilation", "ex", ")", "{", "}", "}", "public", "void", "parseMethod", "(", "char", "[", "]", "regionSource", ")", "{", "try", "{", "initialize", "(", ")", ";", "goForGenericMethodDeclaration", "(", ")", ";", "this", ".", "referenceContext", "=", "this", ".", "compilationUnit", "=", "new", "CompilationUnitDeclaration", "(", "problemReporter", "(", ")", ",", "new", "CompilationResult", "(", "regionSource", ",", "0", ",", "0", ",", "this", ".", "options", ".", "maxProblemsPerUnit", ")", ",", "regionSource", ".", "length", ")", ";", "this", ".", "scanner", ".", "resetTo", "(", "0", ",", "regionSource", ".", "length", ")", ";", "this", ".", "scanner", ".", "setSource", "(", "regionSource", ")", ";", "parse", "(", ")", ";", "}", "catch", "(", "AbortCompilation", "ex", ")", "{", "}", "}", "public", "void", "parsePackage", "(", "char", "[", "]", "regionSource", ")", "{", "try", "{", "initialize", "(", ")", ";", "goForPackageDeclaration", "(", ")", ";", "this", ".", "referenceContext", "=", "this", ".", "compilationUnit", "=", "new", "CompilationUnitDeclaration", "(", "problemReporter", "(", ")", ",", "new", "CompilationResult", "(", "regionSource", ",", "0", ",", "0", ",", "this", ".", "options", ".", "maxProblemsPerUnit", ")", ",", "regionSource", ".", "length", ")", ";", "this", ".", "scanner", ".", "resetTo", "(", "0", ",", "regionSource", ".", "length", ")", ";", "this", ".", "scanner", ".", "setSource", "(", "regionSource", ")", ";", "parse", "(", ")", ";", "}", "catch", "(", "AbortCompilation", "ex", ")", "{", "}", "}", "public", "void", "parseType", "(", "char", "[", "]", "regionSource", ")", "{", "try", "{", "initialize", "(", ")", ";", "goForTypeDeclaration", "(", ")", ";", "this", ".", "referenceContext", "=", "this", ".", "compilationUnit", "=", "new", "CompilationUnitDeclaration", "(", "problemReporter", "(", ")", ",", "new", "CompilationResult", "(", "regionSource", ",", "0", ",", "0", ",", "this", ".", "options", ".", "maxProblemsPerUnit", ")", ",", "regionSource", ".", "length", ")", ";", "this", ".", "scanner", ".", "resetTo", "(", "0", ",", "regionSource", ".", "length", ")", ";", "this", ".", "scanner", ".", "setSource", "(", "regionSource", ")", ";", "parse", "(", ")", ";", "}", "catch", "(", "AbortCompilation", "ex", ")", "{", "}", "}", "public", "ProblemReporter", "problemReporter", "(", ")", "{", "this", ".", "problemReporter", ".", "referenceContext", "=", "this", ".", "referenceContext", ";", "return", "this", ".", "problemReporter", ";", "}", "protected", "void", "pushOnIntArrayStack", "(", "int", "[", "]", "positions", ")", "{", "int", "stackLength", "=", "this", ".", "intArrayStack", ".", "length", ";", "if", "(", "++", "this", ".", "intArrayPtr", ">=", "stackLength", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "intArrayStack", ",", "0", ",", "this", ".", "intArrayStack", "=", "new", "int", "[", "stackLength", "+", "StackIncrement", "]", "[", "]", ",", "0", ",", "stackLength", ")", ";", "}", "this", ".", "intArrayStack", "[", "this", ".", "intArrayPtr", "]", "=", "positions", ";", "}", "protected", "void", "resetModifiers", "(", ")", "{", "super", ".", "resetModifiers", "(", ")", ";", "this", ".", "declarationSourceStart", "=", "-", "1", ";", "}", "protected", "boolean", "resumeOnSyntaxError", "(", ")", "{", "return", "false", ";", "}", "private", "char", "[", "]", "returnTypeName", "(", "TypeReference", "type", ")", "{", "int", "dimension", "=", "type", ".", "dimensions", "(", ")", ";", "if", "(", "dimension", "!=", "0", ")", "{", "char", "[", "]", "dimensionsArray", "=", "new", "char", "[", "dimension", "*", "2", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "dimension", ";", "i", "++", ")", "{", "dimensionsArray", "[", "i", "*", "2", "]", "=", "'['", ";", "dimensionsArray", "[", "(", "i", "*", "2", ")", "+", "1", "]", "=", "']'", ";", "}", "return", "CharOperation", ".", "concat", "(", "CharOperation", ".", "concatWith", "(", "type", ".", "getTypeName", "(", ")", ",", "'.'", ")", ",", "dimensionsArray", ")", ";", "}", "return", "CharOperation", ".", "concatWith", "(", "type", ".", "getTypeName", "(", ")", ",", "'.'", ")", ";", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", ")", ";", "buffer", ".", "append", "(", "\"\"", "+", "this", ".", "intArrayPtr", "+", "\"n\"", ")", ";", "buffer", ".", "append", "(", "super", ".", "toString", "(", ")", ")", ";", "return", "buffer", ".", "toString", "(", ")", ";", "}", "protected", "TypeReference", "typeReference", "(", "int", "dim", ",", "int", "localIdentifierPtr", ",", "int", "localIdentifierLengthPtr", ")", "{", "int", "length", ";", "TypeReference", "ref", ";", "if", "(", "(", "length", "=", "this", ".", "identifierLengthStack", "[", "localIdentifierLengthPtr", "]", ")", "==", "1", ")", "{", "if", "(", "dim", "==", "0", ")", "{", "ref", "=", "new", "SingleTypeReference", "(", "this", ".", "identifierStack", "[", "localIdentifierPtr", "]", ",", "this", ".", "identifierPositionStack", "[", "localIdentifierPtr", "--", "]", ")", ";", "}", "else", "{", "ref", "=", "new", "ArrayTypeReference", "(", "this", ".", "identifierStack", "[", "localIdentifierPtr", "]", ",", "dim", ",", "this", ".", "identifierPositionStack", "[", "localIdentifierPtr", "--", "]", ")", ";", "ref", ".", "sourceEnd", "=", "this", ".", "endPosition", ";", "}", "}", "else", "{", "if", "(", "length", "<", "0", ")", "{", "ref", "=", "TypeReference", ".", "baseTypeReference", "(", "-", "length", ",", "dim", ")", ";", "ref", ".", "sourceStart", "=", "this", ".", "intStack", "[", "this", ".", "localIntPtr", "--", "]", ";", "if", "(", "dim", "==", "0", ")", "{", "ref", ".", "sourceEnd", "=", "this", ".", "intStack", "[", "this", ".", "localIntPtr", "--", "]", ";", "}", "else", "{", "this", ".", "localIntPtr", "--", ";", "ref", ".", "sourceEnd", "=", "this", ".", "endPosition", ";", "}", "}", "else", "{", "char", "[", "]", "[", "]", "tokens", "=", "new", "char", "[", "length", "]", "[", "]", ";", "localIdentifierPtr", "-=", "length", ";", "long", "[", "]", "positions", "=", "new", "long", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "this", ".", "identifierStack", ",", "localIdentifierPtr", "+", "1", ",", "tokens", ",", "0", ",", "length", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "identifierPositionStack", ",", "localIdentifierPtr", "+", "1", ",", "positions", ",", "0", ",", "length", ")", ";", "if", "(", "dim", "==", "0", ")", "ref", "=", "new", "QualifiedTypeReference", "(", "tokens", ",", "positions", ")", ";", "else", "ref", "=", "new", "ArrayQualifiedTypeReference", "(", "tokens", ",", "dim", ",", "positions", ")", ";", "}", "}", "return", "ref", ";", "}", "}", "</s>" ]
5,539
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CategorizedProblem", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Expression", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ImportReference", ";", "public", "class", "SourceElementRequestorAdapter", "implements", "ISourceElementRequestor", "{", "public", "void", "acceptAnnotationTypeReference", "(", "char", "[", "]", "[", "]", "typeName", ",", "int", "sourceStart", ",", "int", "sourceEnd", ")", "{", "}", "public", "void", "acceptAnnotationTypeReference", "(", "char", "[", "]", "typeName", ",", "int", "sourcePosition", ")", "{", "}", "public", "void", "acceptConstructorReference", "(", "char", "[", "]", "typeName", ",", "int", "argCount", ",", "int", "sourcePosition", ")", "{", "}", "public", "void", "acceptFieldReference", "(", "char", "[", "]", "fieldName", ",", "int", "sourcePosition", ")", "{", "}", "public", "void", "acceptImport", "(", "int", "declarationStart", ",", "int", "declarationEnd", ",", "char", "[", "]", "[", "]", "tokens", ",", "boolean", "onDemand", ",", "int", "modifiers", ")", "{", "}", "public", "void", "acceptLineSeparatorPositions", "(", "int", "[", "]", "positions", ")", "{", "}", "public", "void", "acceptMethodReference", "(", "char", "[", "]", "methodName", ",", "int", "argCount", ",", "int", "sourcePosition", ")", "{", "}", "public", "void", "acceptPackage", "(", "ImportReference", "importReference", ")", "{", "}", "public", "void", "acceptProblem", "(", "CategorizedProblem", "problem", ")", "{", "}", "public", "void", "acceptTypeReference", "(", "char", "[", "]", "[", "]", "typeName", ",", "int", "sourceStart", ",", "int", "sourceEnd", ")", "{", "}", "public", "void", "acceptTypeReference", "(", "char", "[", "]", "typeName", ",", "int", "sourcePosition", ")", "{", "}", "public", "void", "acceptUnknownReference", "(", "char", "[", "]", "[", "]", "name", ",", "int", "sourceStart", ",", "int", "sourceEnd", ")", "{", "}", "public", "void", "acceptUnknownReference", "(", "char", "[", "]", "name", ",", "int", "sourcePosition", ")", "{", "}", "public", "void", "enterCompilationUnit", "(", ")", "{", "}", "public", "void", "enterConstructor", "(", "MethodInfo", "methodInfo", ")", "{", "}", "public", "void", "enterField", "(", "FieldInfo", "fieldInfo", ")", "{", "}", "public", "void", "enterInitializer", "(", "int", "declarationStart", ",", "int", "modifiers", ")", "{", "}", "public", "void", "enterMethod", "(", "MethodInfo", "methodInfo", ")", "{", "}", "public", "void", "enterType", "(", "TypeInfo", "typeInfo", ")", "{", "}", "public", "void", "exitCompilationUnit", "(", "int", "declarationEnd", ")", "{", "}", "public", "void", "exitConstructor", "(", "int", "declarationEnd", ")", "{", "}", "public", "void", "exitField", "(", "int", "initializationStart", ",", "int", "declarationEnd", ",", "int", "declarationSourceEnd", ")", "{", "}", "public", "void", "exitInitializer", "(", "int", "declarationEnd", ")", "{", "}", "public", "void", "exitMethod", "(", "int", "declarationEnd", ",", "Expression", "defaultValue", ")", "{", "}", "public", "void", "exitType", "(", "int", "declarationEnd", ")", "{", "}", "}", "</s>" ]
5,540
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "parser", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "Signature", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ASTNode", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ArrayQualifiedTypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ArrayTypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ImportReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ParameterizedQualifiedTypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ParameterizedSingleTypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "QualifiedTypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "SingleTypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeParameter", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Wildcard", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemReporter", ";", "public", "abstract", "class", "TypeConverter", "{", "int", "namePos", ";", "protected", "ProblemReporter", "problemReporter", ";", "protected", "boolean", "has1_5Compliance", ";", "private", "char", "memberTypeSeparator", ";", "protected", "TypeConverter", "(", "ProblemReporter", "problemReporter", ",", "char", "memberTypeSeparator", ")", "{", "this", ".", "problemReporter", "=", "problemReporter", ";", "this", ".", "has1_5Compliance", "=", "problemReporter", ".", "options", ".", "complianceLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ";", "this", ".", "memberTypeSeparator", "=", "memberTypeSeparator", ";", "}", "private", "void", "addIdentifiers", "(", "String", "typeSignature", ",", "int", "start", ",", "int", "endExclusive", ",", "int", "identCount", ",", "ArrayList", "fragments", ")", "{", "if", "(", "identCount", "==", "1", ")", "{", "char", "[", "]", "identifier", ";", "typeSignature", ".", "getChars", "(", "start", ",", "endExclusive", ",", "identifier", "=", "new", "char", "[", "endExclusive", "-", "start", "]", ",", "0", ")", ";", "fragments", ".", "add", "(", "identifier", ")", ";", "}", "else", "fragments", ".", "add", "(", "extractIdentifiers", "(", "typeSignature", ",", "start", ",", "endExclusive", "-", "1", ",", "identCount", ")", ")", ";", "}", "protected", "ImportReference", "createImportReference", "(", "String", "[", "]", "importName", ",", "int", "start", ",", "int", "end", ",", "boolean", "onDemand", ",", "int", "modifiers", ")", "{", "int", "length", "=", "importName", ".", "length", ";", "long", "[", "]", "positions", "=", "new", "long", "[", "length", "]", ";", "long", "position", "=", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ";", "char", "[", "]", "[", "]", "qImportName", "=", "new", "char", "[", "length", "]", "[", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "qImportName", "[", "i", "]", "=", "importName", "[", "i", "]", ".", "toCharArray", "(", ")", ";", "positions", "[", "i", "]", "=", "position", ";", "}", "return", "new", "ImportReference", "(", "qImportName", ",", "positions", ",", "onDemand", ",", "modifiers", ")", ";", "}", "protected", "TypeParameter", "createTypeParameter", "(", "char", "[", "]", "typeParameterName", ",", "char", "[", "]", "[", "]", "typeParameterBounds", ",", "int", "start", ",", "int", "end", ")", "{", "TypeParameter", "parameter", "=", "new", "TypeParameter", "(", ")", ";", "parameter", ".", "name", "=", "typeParameterName", ";", "parameter", ".", "sourceStart", "=", "start", ";", "parameter", ".", "sourceEnd", "=", "end", ";", "if", "(", "typeParameterBounds", "!=", "null", ")", "{", "int", "length", "=", "typeParameterBounds", ".", "length", ";", "if", "(", "length", ">", "0", ")", "{", "parameter", ".", "type", "=", "createTypeReference", "(", "typeParameterBounds", "[", "0", "]", ",", "start", ",", "end", ")", ";", "if", "(", "length", ">", "1", ")", "{", "parameter", ".", "bounds", "=", "new", "TypeReference", "[", "length", "-", "1", "]", ";", "for", "(", "int", "i", "=", "1", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeReference", "bound", "=", "createTypeReference", "(", "typeParameterBounds", "[", "i", "]", ",", "start", ",", "end", ")", ";", "bound", ".", "bits", "|=", "ASTNode", ".", "IsSuperType", ";", "parameter", ".", "bounds", "[", "i", "-", "1", "]", "=", "bound", ";", "}", "}", "}", "}", "return", "parameter", ";", "}", "protected", "TypeReference", "createTypeReference", "(", "char", "[", "]", "typeName", ",", "int", "start", ",", "int", "end", ")", "{", "int", "length", "=", "typeName", ".", "length", ";", "this", ".", "namePos", "=", "0", ";", "return", "decodeType", "(", "typeName", ",", "length", ",", "start", ",", "end", ")", ";", "}", "protected", "TypeReference", "createTypeReference", "(", "String", "typeSignature", ",", "int", "start", ",", "int", "end", ")", "{", "int", "length", "=", "typeSignature", ".", "length", "(", ")", ";", "this", ".", "namePos", "=", "0", ";", "return", "decodeType", "(", "typeSignature", ",", "length", ",", "start", ",", "end", ")", ";", "}", "private", "TypeReference", "decodeType", "(", "String", "typeSignature", ",", "int", "length", ",", "int", "start", ",", "int", "end", ")", "{", "int", "identCount", "=", "1", ";", "int", "dim", "=", "0", ";", "int", "nameFragmentStart", "=", "this", ".", "namePos", ",", "nameFragmentEnd", "=", "-", "1", ";", "boolean", "nameStarted", "=", "false", ";", "ArrayList", "fragments", "=", "null", ";", "typeLoop", ":", "while", "(", "this", ".", "namePos", "<", "length", ")", "{", "char", "currentChar", "=", "typeSignature", ".", "charAt", "(", "this", ".", "namePos", ")", ";", "switch", "(", "currentChar", ")", "{", "case", "Signature", ".", "C_BOOLEAN", ":", "if", "(", "!", "nameStarted", ")", "{", "this", ".", "namePos", "++", ";", "if", "(", "dim", "==", "0", ")", "return", "new", "SingleTypeReference", "(", "TypeBinding", ".", "BOOLEAN", ".", "simpleName", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "else", "return", "new", "ArrayTypeReference", "(", "TypeBinding", ".", "BOOLEAN", ".", "simpleName", ",", "dim", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "}", "break", ";", "case", "Signature", ".", "C_BYTE", ":", "if", "(", "!", "nameStarted", ")", "{", "this", ".", "namePos", "++", ";", "if", "(", "dim", "==", "0", ")", "return", "new", "SingleTypeReference", "(", "TypeBinding", ".", "BYTE", ".", "simpleName", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "else", "return", "new", "ArrayTypeReference", "(", "TypeBinding", ".", "BYTE", ".", "simpleName", ",", "dim", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "}", "break", ";", "case", "Signature", ".", "C_CHAR", ":", "if", "(", "!", "nameStarted", ")", "{", "this", ".", "namePos", "++", ";", "if", "(", "dim", "==", "0", ")", "return", "new", "SingleTypeReference", "(", "TypeBinding", ".", "CHAR", ".", "simpleName", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "else", "return", "new", "ArrayTypeReference", "(", "TypeBinding", ".", "CHAR", ".", "simpleName", ",", "dim", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "}", "break", ";", "case", "Signature", ".", "C_DOUBLE", ":", "if", "(", "!", "nameStarted", ")", "{", "this", ".", "namePos", "++", ";", "if", "(", "dim", "==", "0", ")", "return", "new", "SingleTypeReference", "(", "TypeBinding", ".", "DOUBLE", ".", "simpleName", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "else", "return", "new", "ArrayTypeReference", "(", "TypeBinding", ".", "DOUBLE", ".", "simpleName", ",", "dim", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "}", "break", ";", "case", "Signature", ".", "C_FLOAT", ":", "if", "(", "!", "nameStarted", ")", "{", "this", ".", "namePos", "++", ";", "if", "(", "dim", "==", "0", ")", "return", "new", "SingleTypeReference", "(", "TypeBinding", ".", "FLOAT", ".", "simpleName", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "else", "return", "new", "ArrayTypeReference", "(", "TypeBinding", ".", "FLOAT", ".", "simpleName", ",", "dim", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "}", "break", ";", "case", "Signature", ".", "C_INT", ":", "if", "(", "!", "nameStarted", ")", "{", "this", ".", "namePos", "++", ";", "if", "(", "dim", "==", "0", ")", "return", "new", "SingleTypeReference", "(", "TypeBinding", ".", "INT", ".", "simpleName", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "else", "return", "new", "ArrayTypeReference", "(", "TypeBinding", ".", "INT", ".", "simpleName", ",", "dim", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "}", "break", ";", "case", "Signature", ".", "C_LONG", ":", "if", "(", "!", "nameStarted", ")", "{", "this", ".", "namePos", "++", ";", "if", "(", "dim", "==", "0", ")", "return", "new", "SingleTypeReference", "(", "TypeBinding", ".", "LONG", ".", "simpleName", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "else", "return", "new", "ArrayTypeReference", "(", "TypeBinding", ".", "LONG", ".", "simpleName", ",", "dim", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "}", "break", ";", "case", "Signature", ".", "C_SHORT", ":", "if", "(", "!", "nameStarted", ")", "{", "this", ".", "namePos", "++", ";", "if", "(", "dim", "==", "0", ")", "return", "new", "SingleTypeReference", "(", "TypeBinding", ".", "SHORT", ".", "simpleName", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "else", "return", "new", "ArrayTypeReference", "(", "TypeBinding", ".", "SHORT", ".", "simpleName", ",", "dim", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "}", "break", ";", "case", "Signature", ".", "C_VOID", ":", "if", "(", "!", "nameStarted", ")", "{", "this", ".", "namePos", "++", ";", "return", "new", "SingleTypeReference", "(", "TypeBinding", ".", "VOID", ".", "simpleName", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "}", "break", ";", "case", "Signature", ".", "C_RESOLVED", ":", "case", "Signature", ".", "C_UNRESOLVED", ":", "case", "Signature", ".", "C_TYPE_VARIABLE", ":", "if", "(", "!", "nameStarted", ")", "{", "nameFragmentStart", "=", "this", ".", "namePos", "+", "1", ";", "nameStarted", "=", "true", ";", "}", "break", ";", "case", "Signature", ".", "C_STAR", ":", "this", ".", "namePos", "++", ";", "Wildcard", "result", "=", "new", "Wildcard", "(", "Wildcard", ".", "UNBOUND", ")", ";", "result", ".", "sourceStart", "=", "start", ";", "result", ".", "sourceEnd", "=", "end", ";", "return", "result", ";", "case", "Signature", ".", "C_EXTENDS", ":", "this", ".", "namePos", "++", ";", "result", "=", "new", "Wildcard", "(", "Wildcard", ".", "EXTENDS", ")", ";", "result", ".", "bound", "=", "decodeType", "(", "typeSignature", ",", "length", ",", "start", ",", "end", ")", ";", "result", ".", "sourceStart", "=", "start", ";", "result", ".", "sourceEnd", "=", "end", ";", "return", "result", ";", "case", "Signature", ".", "C_SUPER", ":", "this", ".", "namePos", "++", ";", "result", "=", "new", "Wildcard", "(", "Wildcard", ".", "SUPER", ")", ";", "result", ".", "bound", "=", "decodeType", "(", "typeSignature", ",", "length", ",", "start", ",", "end", ")", ";", "result", ".", "sourceStart", "=", "start", ";", "result", ".", "sourceEnd", "=", "end", ";", "return", "result", ";", "case", "Signature", ".", "C_ARRAY", ":", "dim", "++", ";", "break", ";", "case", "Signature", ".", "C_GENERIC_END", ":", "case", "Signature", ".", "C_SEMICOLON", ":", "nameFragmentEnd", "=", "this", ".", "namePos", "-", "1", ";", "this", ".", "namePos", "++", ";", "break", "typeLoop", ";", "case", "Signature", ".", "C_DOLLAR", ":", "if", "(", "this", ".", "memberTypeSeparator", "!=", "Signature", ".", "C_DOLLAR", ")", "break", ";", "case", "Signature", ".", "C_DOT", ":", "if", "(", "!", "nameStarted", ")", "{", "nameFragmentStart", "=", "this", ".", "namePos", "+", "1", ";", "nameStarted", "=", "true", ";", "}", "else", "if", "(", "this", ".", "namePos", ">", "nameFragmentStart", ")", "identCount", "++", ";", "break", ";", "case", "Signature", ".", "C_GENERIC_START", ":", "nameFragmentEnd", "=", "this", ".", "namePos", "-", "1", ";", "if", "(", "!", "this", ".", "has1_5Compliance", ")", "break", "typeLoop", ";", "if", "(", "fragments", "==", "null", ")", "fragments", "=", "new", "ArrayList", "(", "2", ")", ";", "addIdentifiers", "(", "typeSignature", ",", "nameFragmentStart", ",", "nameFragmentEnd", "+", "1", ",", "identCount", ",", "fragments", ")", ";", "this", ".", "namePos", "++", ";", "TypeReference", "[", "]", "arguments", "=", "decodeTypeArguments", "(", "typeSignature", ",", "length", ",", "start", ",", "end", ")", ";", "fragments", ".", "add", "(", "arguments", ")", ";", "identCount", "=", "1", ";", "nameStarted", "=", "false", ";", "break", ";", "}", "this", ".", "namePos", "++", ";", "}", "if", "(", "fragments", "==", "null", ")", "{", "if", "(", "identCount", "==", "1", ")", "{", "if", "(", "dim", "==", "0", ")", "{", "char", "[", "]", "nameFragment", "=", "new", "char", "[", "nameFragmentEnd", "-", "nameFragmentStart", "+", "1", "]", ";", "typeSignature", ".", "getChars", "(", "nameFragmentStart", ",", "nameFragmentEnd", "+", "1", ",", "nameFragment", ",", "0", ")", ";", "return", "new", "SingleTypeReference", "(", "nameFragment", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "}", "else", "{", "char", "[", "]", "nameFragment", "=", "new", "char", "[", "nameFragmentEnd", "-", "nameFragmentStart", "+", "1", "]", ";", "typeSignature", ".", "getChars", "(", "nameFragmentStart", ",", "nameFragmentEnd", "+", "1", ",", "nameFragment", ",", "0", ")", ";", "return", "new", "ArrayTypeReference", "(", "nameFragment", ",", "dim", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "}", "}", "else", "{", "long", "[", "]", "positions", "=", "new", "long", "[", "identCount", "]", ";", "long", "pos", "=", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "identCount", ";", "i", "++", ")", "{", "positions", "[", "i", "]", "=", "pos", ";", "}", "char", "[", "]", "[", "]", "identifiers", "=", "extractIdentifiers", "(", "typeSignature", ",", "nameFragmentStart", ",", "nameFragmentEnd", ",", "identCount", ")", ";", "if", "(", "dim", "==", "0", ")", "{", "return", "new", "QualifiedTypeReference", "(", "identifiers", ",", "positions", ")", ";", "}", "else", "{", "return", "new", "ArrayQualifiedTypeReference", "(", "identifiers", ",", "dim", ",", "positions", ")", ";", "}", "}", "}", "else", "{", "if", "(", "nameStarted", ")", "{", "addIdentifiers", "(", "typeSignature", ",", "nameFragmentStart", ",", "nameFragmentEnd", "+", "1", ",", "identCount", ",", "fragments", ")", ";", "}", "int", "fragmentLength", "=", "fragments", ".", "size", "(", ")", ";", "if", "(", "fragmentLength", "==", "2", ")", "{", "Object", "firstFragment", "=", "fragments", ".", "get", "(", "0", ")", ";", "if", "(", "firstFragment", "instanceof", "char", "[", "]", ")", "{", "return", "new", "ParameterizedSingleTypeReference", "(", "(", "char", "[", "]", ")", "firstFragment", ",", "(", "TypeReference", "[", "]", ")", "fragments", ".", "get", "(", "1", ")", ",", "dim", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "}", "}", "identCount", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "fragmentLength", ";", "i", "++", ")", "{", "Object", "element", "=", "fragments", ".", "get", "(", "i", ")", ";", "if", "(", "element", "instanceof", "char", "[", "]", "[", "]", ")", "{", "identCount", "+=", "(", "(", "char", "[", "]", "[", "]", ")", "element", ")", ".", "length", ";", "}", "else", "if", "(", "element", "instanceof", "char", "[", "]", ")", "identCount", "++", ";", "}", "char", "[", "]", "[", "]", "tokens", "=", "new", "char", "[", "identCount", "]", "[", "]", ";", "TypeReference", "[", "]", "[", "]", "arguments", "=", "new", "TypeReference", "[", "identCount", "]", "[", "]", ";", "int", "index", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "fragmentLength", ";", "i", "++", ")", "{", "Object", "element", "=", "fragments", ".", "get", "(", "i", ")", ";", "if", "(", "element", "instanceof", "char", "[", "]", "[", "]", ")", "{", "char", "[", "]", "[", "]", "fragmentTokens", "=", "(", "char", "[", "]", "[", "]", ")", "element", ";", "int", "fragmentTokenLength", "=", "fragmentTokens", ".", "length", ";", "System", ".", "arraycopy", "(", "fragmentTokens", ",", "0", ",", "tokens", ",", "index", ",", "fragmentTokenLength", ")", ";", "index", "+=", "fragmentTokenLength", ";", "}", "else", "if", "(", "element", "instanceof", "char", "[", "]", ")", "{", "tokens", "[", "index", "++", "]", "=", "(", "char", "[", "]", ")", "element", ";", "}", "else", "{", "arguments", "[", "index", "-", "1", "]", "=", "(", "TypeReference", "[", "]", ")", "element", ";", "}", "}", "long", "[", "]", "positions", "=", "new", "long", "[", "identCount", "]", ";", "long", "pos", "=", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "identCount", ";", "i", "++", ")", "{", "positions", "[", "i", "]", "=", "pos", ";", "}", "return", "new", "ParameterizedQualifiedTypeReference", "(", "tokens", ",", "arguments", ",", "dim", ",", "positions", ")", ";", "}", "}", "private", "TypeReference", "decodeType", "(", "char", "[", "]", "typeName", ",", "int", "length", ",", "int", "start", ",", "int", "end", ")", "{", "int", "identCount", "=", "1", ";", "int", "dim", "=", "0", ";", "int", "nameFragmentStart", "=", "this", ".", "namePos", ",", "nameFragmentEnd", "=", "-", "1", ";", "ArrayList", "fragments", "=", "null", ";", "typeLoop", ":", "while", "(", "this", ".", "namePos", "<", "length", ")", "{", "char", "currentChar", "=", "typeName", "[", "this", ".", "namePos", "]", ";", "switch", "(", "currentChar", ")", "{", "case", "'?'", ":", "this", ".", "namePos", "++", ";", "while", "(", "typeName", "[", "this", ".", "namePos", "]", "==", "'", "'", ")", "this", ".", "namePos", "++", ";", "switch", "(", "typeName", "[", "this", ".", "namePos", "]", ")", "{", "case", "'s'", ":", "checkSuper", ":", "{", "int", "max", "=", "TypeConstants", ".", "WILDCARD_SUPER", ".", "length", "-", "1", ";", "for", "(", "int", "ahead", "=", "1", ";", "ahead", "<", "max", ";", "ahead", "++", ")", "{", "if", "(", "typeName", "[", "this", ".", "namePos", "+", "ahead", "]", "!=", "TypeConstants", ".", "WILDCARD_SUPER", "[", "ahead", "+", "1", "]", ")", "{", "break", "checkSuper", ";", "}", "}", "this", ".", "namePos", "+=", "max", ";", "Wildcard", "result", "=", "new", "Wildcard", "(", "Wildcard", ".", "SUPER", ")", ";", "result", ".", "bound", "=", "decodeType", "(", "typeName", ",", "length", ",", "start", ",", "end", ")", ";", "result", ".", "sourceStart", "=", "start", ";", "result", ".", "sourceEnd", "=", "end", ";", "return", "result", ";", "}", "break", ";", "case", "'e'", ":", "checkExtends", ":", "{", "int", "max", "=", "TypeConstants", ".", "WILDCARD_EXTENDS", ".", "length", "-", "1", ";", "for", "(", "int", "ahead", "=", "1", ";", "ahead", "<", "max", ";", "ahead", "++", ")", "{", "if", "(", "typeName", "[", "this", ".", "namePos", "+", "ahead", "]", "!=", "TypeConstants", ".", "WILDCARD_EXTENDS", "[", "ahead", "+", "1", "]", ")", "{", "break", "checkExtends", ";", "}", "}", "this", ".", "namePos", "+=", "max", ";", "Wildcard", "result", "=", "new", "Wildcard", "(", "Wildcard", ".", "EXTENDS", ")", ";", "result", ".", "bound", "=", "decodeType", "(", "typeName", ",", "length", ",", "start", ",", "end", ")", ";", "result", ".", "sourceStart", "=", "start", ";", "result", ".", "sourceEnd", "=", "end", ";", "return", "result", ";", "}", "break", ";", "}", "Wildcard", "result", "=", "new", "Wildcard", "(", "Wildcard", ".", "UNBOUND", ")", ";", "result", ".", "sourceStart", "=", "start", ";", "result", ".", "sourceEnd", "=", "end", ";", "return", "result", ";", "case", "'['", ":", "if", "(", "dim", "==", "0", ")", "nameFragmentEnd", "=", "this", ".", "namePos", "-", "1", ";", "dim", "++", ";", "break", ";", "case", "']'", ":", "break", ";", "case", "'>'", ":", "case", "','", ":", "break", "typeLoop", ";", "case", "'.'", ":", "if", "(", "nameFragmentStart", "<", "0", ")", "nameFragmentStart", "=", "this", ".", "namePos", "+", "1", ";", "identCount", "++", ";", "break", ";", "case", "'<'", ":", "if", "(", "!", "this", ".", "has1_5Compliance", ")", "break", "typeLoop", ";", "if", "(", "fragments", "==", "null", ")", "fragments", "=", "new", "ArrayList", "(", "2", ")", ";", "nameFragmentEnd", "=", "this", ".", "namePos", "-", "1", ";", "char", "[", "]", "[", "]", "identifiers", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "typeName", ",", "nameFragmentStart", ",", "this", ".", "namePos", ")", ";", "fragments", ".", "add", "(", "identifiers", ")", ";", "this", ".", "namePos", "++", ";", "TypeReference", "[", "]", "arguments", "=", "decodeTypeArguments", "(", "typeName", ",", "length", ",", "start", ",", "end", ")", ";", "fragments", ".", "add", "(", "arguments", ")", ";", "identCount", "=", "0", ";", "nameFragmentStart", "=", "-", "1", ";", "nameFragmentEnd", "=", "-", "1", ";", "break", ";", "}", "this", ".", "namePos", "++", ";", "}", "if", "(", "nameFragmentEnd", "<", "0", ")", "nameFragmentEnd", "=", "this", ".", "namePos", "-", "1", ";", "if", "(", "fragments", "==", "null", ")", "{", "if", "(", "identCount", "==", "1", ")", "{", "if", "(", "dim", "==", "0", ")", "{", "char", "[", "]", "nameFragment", ";", "if", "(", "nameFragmentStart", "!=", "0", "||", "nameFragmentEnd", ">=", "0", ")", "{", "int", "nameFragmentLength", "=", "nameFragmentEnd", "-", "nameFragmentStart", "+", "1", ";", "System", ".", "arraycopy", "(", "typeName", ",", "nameFragmentStart", ",", "nameFragment", "=", "new", "char", "[", "nameFragmentLength", "]", ",", "0", ",", "nameFragmentLength", ")", ";", "}", "else", "{", "nameFragment", "=", "typeName", ";", "}", "return", "new", "SingleTypeReference", "(", "nameFragment", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "}", "else", "{", "int", "nameFragmentLength", "=", "nameFragmentEnd", "-", "nameFragmentStart", "+", "1", ";", "char", "[", "]", "nameFragment", "=", "new", "char", "[", "nameFragmentLength", "]", ";", "System", ".", "arraycopy", "(", "typeName", ",", "nameFragmentStart", ",", "nameFragment", ",", "0", ",", "nameFragmentLength", ")", ";", "return", "new", "ArrayTypeReference", "(", "nameFragment", ",", "dim", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "}", "}", "else", "{", "long", "[", "]", "positions", "=", "new", "long", "[", "identCount", "]", ";", "long", "pos", "=", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "identCount", ";", "i", "++", ")", "{", "positions", "[", "i", "]", "=", "pos", ";", "}", "char", "[", "]", "[", "]", "identifiers", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "typeName", ",", "nameFragmentStart", ",", "nameFragmentEnd", "+", "1", ")", ";", "if", "(", "dim", "==", "0", ")", "{", "return", "new", "QualifiedTypeReference", "(", "identifiers", ",", "positions", ")", ";", "}", "else", "{", "return", "new", "ArrayQualifiedTypeReference", "(", "identifiers", ",", "dim", ",", "positions", ")", ";", "}", "}", "}", "else", "{", "if", "(", "nameFragmentStart", ">", "0", "&&", "nameFragmentStart", "<", "length", ")", "{", "char", "[", "]", "[", "]", "identifiers", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "typeName", ",", "nameFragmentStart", ",", "nameFragmentEnd", "+", "1", ")", ";", "fragments", ".", "add", "(", "identifiers", ")", ";", "}", "int", "fragmentLength", "=", "fragments", ".", "size", "(", ")", ";", "if", "(", "fragmentLength", "==", "2", ")", "{", "char", "[", "]", "[", "]", "firstFragment", "=", "(", "char", "[", "]", "[", "]", ")", "fragments", ".", "get", "(", "0", ")", ";", "if", "(", "firstFragment", ".", "length", "==", "1", ")", "{", "return", "new", "ParameterizedSingleTypeReference", "(", "firstFragment", "[", "0", "]", ",", "(", "TypeReference", "[", "]", ")", "fragments", ".", "get", "(", "1", ")", ",", "dim", ",", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ")", ";", "}", "}", "identCount", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "fragmentLength", ";", "i", "++", ")", "{", "Object", "element", "=", "fragments", ".", "get", "(", "i", ")", ";", "if", "(", "element", "instanceof", "char", "[", "]", "[", "]", ")", "{", "identCount", "+=", "(", "(", "char", "[", "]", "[", "]", ")", "element", ")", ".", "length", ";", "}", "}", "char", "[", "]", "[", "]", "tokens", "=", "new", "char", "[", "identCount", "]", "[", "]", ";", "TypeReference", "[", "]", "[", "]", "arguments", "=", "new", "TypeReference", "[", "identCount", "]", "[", "]", ";", "int", "index", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "fragmentLength", ";", "i", "++", ")", "{", "Object", "element", "=", "fragments", ".", "get", "(", "i", ")", ";", "if", "(", "element", "instanceof", "char", "[", "]", "[", "]", ")", "{", "char", "[", "]", "[", "]", "fragmentTokens", "=", "(", "char", "[", "]", "[", "]", ")", "element", ";", "int", "fragmentTokenLength", "=", "fragmentTokens", ".", "length", ";", "System", ".", "arraycopy", "(", "fragmentTokens", ",", "0", ",", "tokens", ",", "index", ",", "fragmentTokenLength", ")", ";", "index", "+=", "fragmentTokenLength", ";", "}", "else", "{", "arguments", "[", "index", "-", "1", "]", "=", "(", "TypeReference", "[", "]", ")", "element", ";", "}", "}", "long", "[", "]", "positions", "=", "new", "long", "[", "identCount", "]", ";", "long", "pos", "=", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "identCount", ";", "i", "++", ")", "{", "positions", "[", "i", "]", "=", "pos", ";", "}", "return", "new", "ParameterizedQualifiedTypeReference", "(", "tokens", ",", "arguments", ",", "dim", ",", "positions", ")", ";", "}", "}", "private", "TypeReference", "[", "]", "decodeTypeArguments", "(", "char", "[", "]", "typeName", ",", "int", "length", ",", "int", "start", ",", "int", "end", ")", "{", "ArrayList", "argumentList", "=", "new", "ArrayList", "(", "1", ")", ";", "int", "count", "=", "0", ";", "argumentsLoop", ":", "while", "(", "this", ".", "namePos", "<", "length", ")", "{", "TypeReference", "argument", "=", "decodeType", "(", "typeName", ",", "length", ",", "start", ",", "end", ")", ";", "count", "++", ";", "argumentList", ".", "add", "(", "argument", ")", ";", "if", "(", "this", ".", "namePos", ">=", "length", ")", "break", "argumentsLoop", ";", "if", "(", "typeName", "[", "this", ".", "namePos", "]", "==", "'>'", ")", "{", "break", "argumentsLoop", ";", "}", "this", ".", "namePos", "++", ";", "}", "TypeReference", "[", "]", "typeArguments", "=", "new", "TypeReference", "[", "count", "]", ";", "argumentList", ".", "toArray", "(", "typeArguments", ")", ";", "return", "typeArguments", ";", "}", "private", "TypeReference", "[", "]", "decodeTypeArguments", "(", "String", "typeSignature", ",", "int", "length", ",", "int", "start", ",", "int", "end", ")", "{", "ArrayList", "argumentList", "=", "new", "ArrayList", "(", "1", ")", ";", "int", "count", "=", "0", ";", "argumentsLoop", ":", "while", "(", "this", ".", "namePos", "<", "length", ")", "{", "TypeReference", "argument", "=", "decodeType", "(", "typeSignature", ",", "length", ",", "start", ",", "end", ")", ";", "count", "++", ";", "argumentList", ".", "add", "(", "argument", ")", ";", "if", "(", "this", ".", "namePos", ">=", "length", ")", "break", "argumentsLoop", ";", "if", "(", "typeSignature", ".", "charAt", "(", "this", ".", "namePos", ")", "==", "Signature", ".", "C_GENERIC_END", ")", "{", "break", "argumentsLoop", ";", "}", "}", "TypeReference", "[", "]", "typeArguments", "=", "new", "TypeReference", "[", "count", "]", ";", "argumentList", ".", "toArray", "(", "typeArguments", ")", ";", "return", "typeArguments", ";", "}", "private", "char", "[", "]", "[", "]", "extractIdentifiers", "(", "String", "typeSignature", ",", "int", "start", ",", "int", "endInclusive", ",", "int", "identCount", ")", "{", "char", "[", "]", "[", "]", "result", "=", "new", "char", "[", "identCount", "]", "[", "]", ";", "int", "charIndex", "=", "start", ";", "int", "i", "=", "0", ";", "while", "(", "charIndex", "<", "endInclusive", ")", "{", "char", "currentChar", ";", "if", "(", "(", "currentChar", "=", "typeSignature", ".", "charAt", "(", "charIndex", ")", ")", "==", "this", ".", "memberTypeSeparator", "||", "currentChar", "==", "Signature", ".", "C_DOT", ")", "{", "typeSignature", ".", "getChars", "(", "start", ",", "charIndex", ",", "result", "[", "i", "++", "]", "=", "new", "char", "[", "charIndex", "-", "start", "]", ",", "0", ")", ";", "start", "=", "++", "charIndex", ";", "}", "else", "charIndex", "++", ";", "}", "typeSignature", ".", "getChars", "(", "start", ",", "charIndex", "+", "1", ",", "result", "[", "i", "++", "]", "=", "new", "char", "[", "charIndex", "-", "start", "+", "1", "]", ",", "0", ")", ";", "return", "result", ";", "}", "}", "</s>" ]
5,541
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "parser", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "LanguageSupportFactory", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IAnnotatable", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IAnnotation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IImportDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ISourceRange", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "Signature", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "CompilationResult", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ASTNode", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AbstractMethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Annotation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AnnotationMethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Argument", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ArrayInitializer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Block", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "CompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ConstructorDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Expression", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "FieldDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ImportReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Initializer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "MethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "QualifiedAllocationExpression", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Statement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeParameter", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ISourceImport", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ISourceType", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ExtraCompilerModifiers", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemReporter", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "CompilationUnitElementInfo", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "ImportDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "InitializerElementInfo", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "JavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "PackageFragment", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "SourceAnnotationMethodInfo", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "SourceField", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "SourceFieldElementInfo", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "SourceMethod", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "SourceMethodElementInfo", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "SourceType", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "SourceTypeElementInfo", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "SourceTypeConverter", "extends", "TypeConverter", "{", "static", "class", "AnonymousMemberFound", "extends", "RuntimeException", "{", "private", "static", "final", "long", "serialVersionUID", "=", "1L", ";", "}", "public", "static", "final", "int", "FIELD", "=", "0x01", ";", "public", "static", "final", "int", "CONSTRUCTOR", "=", "0x02", ";", "public", "static", "final", "int", "METHOD", "=", "0x04", ";", "public", "static", "final", "int", "MEMBER_TYPE", "=", "0x08", ";", "public", "static", "final", "int", "FIELD_INITIALIZATION", "=", "0x10", ";", "public", "static", "final", "int", "FIELD_AND_METHOD", "=", "FIELD", "|", "CONSTRUCTOR", "|", "METHOD", ";", "public", "static", "final", "int", "LOCAL_TYPE", "=", "0x20", ";", "public", "static", "final", "int", "NONE", "=", "0", ";", "private", "int", "flags", ";", "private", "CompilationUnitDeclaration", "unit", ";", "private", "Parser", "parser", ";", "private", "ICompilationUnit", "cu", ";", "private", "char", "[", "]", "source", ";", "private", "SourceTypeConverter", "(", "int", "flags", ",", "ProblemReporter", "problemReporter", ")", "{", "super", "(", "problemReporter", ",", "Signature", ".", "C_DOT", ")", ";", "this", ".", "flags", "=", "flags", ";", "}", "public", "static", "CompilationUnitDeclaration", "buildCompilationUnit", "(", "ISourceType", "[", "]", "sourceTypes", ",", "int", "flags", ",", "ProblemReporter", "problemReporter", ",", "CompilationResult", "compilationResult", ")", "{", "SourceTypeConverter", "converter", "=", "new", "SourceTypeConverter", "(", "flags", ",", "problemReporter", ")", ";", "try", "{", "return", "converter", ".", "convert", "(", "sourceTypes", ",", "compilationResult", ")", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "return", "null", ";", "}", "}", "private", "CompilationUnitDeclaration", "convert", "(", "ISourceType", "[", "]", "sourceTypes", ",", "CompilationResult", "compilationResult", ")", "throws", "JavaModelException", "{", "this", ".", "unit", "=", "LanguageSupportFactory", ".", "newCompilationUnitDeclaration", "(", "(", "ICompilationUnit", ")", "(", "(", "SourceTypeElementInfo", ")", "sourceTypes", "[", "0", "]", ")", ".", "getHandle", "(", ")", ".", "getCompilationUnit", "(", ")", ",", "this", ".", "problemReporter", ",", "compilationResult", ",", "0", ")", ";", "if", "(", "sourceTypes", ".", "length", "==", "0", ")", "return", "this", ".", "unit", ";", "SourceTypeElementInfo", "topLevelTypeInfo", "=", "(", "SourceTypeElementInfo", ")", "sourceTypes", "[", "0", "]", ";", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ICompilationUnit", "cuHandle", "=", "topLevelTypeInfo", ".", "getHandle", "(", ")", ".", "getCompilationUnit", "(", ")", ";", "this", ".", "cu", "=", "(", "ICompilationUnit", ")", "cuHandle", ";", "if", "(", "LanguageSupportFactory", ".", "isInterestingSourceFile", "(", "new", "String", "(", "compilationResult", ".", "getFileName", "(", ")", ")", ")", ")", "{", "try", "{", "return", "LanguageSupportFactory", ".", "getParser", "(", "this", ",", "problemReporter", ".", "options", ",", "problemReporter", ",", "true", ",", "3", ")", ".", "dietParse", "(", "this", ".", "cu", ",", "compilationResult", ")", ";", "}", "catch", "(", "Throwable", "t", ")", "{", "t", ".", "printStackTrace", "(", ")", ";", "}", "}", "if", "(", "this", ".", "has1_5Compliance", "&&", "(", "(", "CompilationUnitElementInfo", ")", "(", "(", "JavaElement", ")", "this", ".", "cu", ")", ".", "getElementInfo", "(", ")", ")", ".", "annotationNumber", ">", "10", ")", "{", "if", "(", "(", "this", ".", "flags", "&", "LOCAL_TYPE", ")", "==", "0", ")", "{", "return", "new", "Parser", "(", "this", ".", "problemReporter", ",", "true", ")", ".", "dietParse", "(", "this", ".", "cu", ",", "compilationResult", ")", ";", "}", "}", "int", "start", "=", "topLevelTypeInfo", ".", "getNameSourceStart", "(", ")", ";", "int", "end", "=", "topLevelTypeInfo", ".", "getNameSourceEnd", "(", ")", ";", "String", "[", "]", "packageName", "=", "(", "(", "PackageFragment", ")", "cuHandle", ".", "getParent", "(", ")", ")", ".", "names", ";", "if", "(", "packageName", ".", "length", ">", "0", ")", "this", ".", "unit", ".", "currentPackage", "=", "createImportReference", "(", "packageName", ",", "start", ",", "end", ",", "false", ",", "ClassFileConstants", ".", "AccDefault", ")", ";", "IImportDeclaration", "[", "]", "importDeclarations", "=", "topLevelTypeInfo", ".", "getHandle", "(", ")", ".", "getCompilationUnit", "(", ")", ".", "getImports", "(", ")", ";", "int", "importCount", "=", "importDeclarations", ".", "length", ";", "this", ".", "unit", ".", "imports", "=", "new", "ImportReference", "[", "importCount", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "importCount", ";", "i", "++", ")", "{", "ImportDeclaration", "importDeclaration", "=", "(", "ImportDeclaration", ")", "importDeclarations", "[", "i", "]", ";", "ISourceImport", "sourceImport", "=", "(", "ISourceImport", ")", "importDeclaration", ".", "getElementInfo", "(", ")", ";", "String", "nameWithoutStar", "=", "importDeclaration", ".", "getNameWithoutStar", "(", ")", ";", "this", ".", "unit", ".", "imports", "[", "i", "]", "=", "createImportReference", "(", "Util", ".", "splitOn", "(", "'.'", ",", "nameWithoutStar", ",", "0", ",", "nameWithoutStar", ".", "length", "(", ")", ")", ",", "sourceImport", ".", "getDeclarationSourceStart", "(", ")", ",", "sourceImport", ".", "getDeclarationSourceEnd", "(", ")", ",", "importDeclaration", ".", "isOnDemand", "(", ")", ",", "sourceImport", ".", "getModifiers", "(", ")", ")", ";", "}", "try", "{", "int", "typeCount", "=", "sourceTypes", ".", "length", ";", "final", "TypeDeclaration", "[", "]", "types", "=", "new", "TypeDeclaration", "[", "typeCount", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "typeCount", ";", "i", "++", ")", "{", "SourceTypeElementInfo", "typeInfo", "=", "(", "SourceTypeElementInfo", ")", "sourceTypes", "[", "i", "]", ";", "types", "[", "i", "]", "=", "convert", "(", "(", "SourceType", ")", "typeInfo", ".", "getHandle", "(", ")", ",", "compilationResult", ")", ";", "}", "this", ".", "unit", ".", "types", "=", "types", ";", "return", "this", ".", "unit", ";", "}", "catch", "(", "AnonymousMemberFound", "e", ")", "{", "return", "new", "Parser", "(", "this", ".", "problemReporter", ",", "true", ")", ".", "parse", "(", "this", ".", "cu", ",", "compilationResult", ")", ";", "}", "}", "private", "Initializer", "convert", "(", "InitializerElementInfo", "initializerInfo", ",", "CompilationResult", "compilationResult", ")", "throws", "JavaModelException", "{", "Block", "block", "=", "new", "Block", "(", "0", ")", ";", "Initializer", "initializer", "=", "new", "Initializer", "(", "block", ",", "ClassFileConstants", ".", "AccDefault", ")", ";", "int", "start", "=", "initializerInfo", ".", "getDeclarationSourceStart", "(", ")", ";", "int", "end", "=", "initializerInfo", ".", "getDeclarationSourceEnd", "(", ")", ";", "initializer", ".", "sourceStart", "=", "initializer", ".", "declarationSourceStart", "=", "start", ";", "initializer", ".", "sourceEnd", "=", "initializer", ".", "declarationSourceEnd", "=", "end", ";", "initializer", ".", "modifiers", "=", "initializerInfo", ".", "getModifiers", "(", ")", ";", "IJavaElement", "[", "]", "children", "=", "initializerInfo", ".", "getChildren", "(", ")", ";", "int", "typesLength", "=", "children", ".", "length", ";", "if", "(", "typesLength", ">", "0", ")", "{", "Statement", "[", "]", "statements", "=", "new", "Statement", "[", "typesLength", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "typesLength", ";", "i", "++", ")", "{", "SourceType", "type", "=", "(", "SourceType", ")", "children", "[", "i", "]", ";", "TypeDeclaration", "localType", "=", "convert", "(", "type", ",", "compilationResult", ")", ";", "if", "(", "(", "localType", ".", "bits", "&", "ASTNode", ".", "IsAnonymousType", ")", "!=", "0", ")", "{", "QualifiedAllocationExpression", "expression", "=", "new", "QualifiedAllocationExpression", "(", "localType", ")", ";", "expression", ".", "type", "=", "localType", ".", "superclass", ";", "localType", ".", "superclass", "=", "null", ";", "localType", ".", "superInterfaces", "=", "null", ";", "localType", ".", "allocation", "=", "expression", ";", "statements", "[", "i", "]", "=", "expression", ";", "}", "else", "{", "statements", "[", "i", "]", "=", "localType", ";", "}", "}", "block", ".", "statements", "=", "statements", ";", "}", "return", "initializer", ";", "}", "private", "FieldDeclaration", "convert", "(", "SourceField", "fieldHandle", ",", "TypeDeclaration", "type", ",", "CompilationResult", "compilationResult", ")", "throws", "JavaModelException", "{", "SourceFieldElementInfo", "fieldInfo", "=", "(", "SourceFieldElementInfo", ")", "fieldHandle", ".", "getElementInfo", "(", ")", ";", "FieldDeclaration", "field", "=", "new", "FieldDeclaration", "(", ")", ";", "int", "start", "=", "fieldInfo", ".", "getNameSourceStart", "(", ")", ";", "int", "end", "=", "fieldInfo", ".", "getNameSourceEnd", "(", ")", ";", "field", ".", "name", "=", "fieldHandle", ".", "getElementName", "(", ")", ".", "toCharArray", "(", ")", ";", "field", ".", "sourceStart", "=", "start", ";", "field", ".", "sourceEnd", "=", "end", ";", "field", ".", "declarationSourceStart", "=", "fieldInfo", ".", "getDeclarationSourceStart", "(", ")", ";", "field", ".", "declarationSourceEnd", "=", "fieldInfo", ".", "getDeclarationSourceEnd", "(", ")", ";", "int", "modifiers", "=", "fieldInfo", ".", "getModifiers", "(", ")", ";", "boolean", "isEnumConstant", "=", "(", "modifiers", "&", "ClassFileConstants", ".", "AccEnum", ")", "!=", "0", ";", "if", "(", "isEnumConstant", ")", "{", "field", ".", "modifiers", "=", "modifiers", "&", "~", "ClassFileConstants", ".", "AccEnum", ";", "}", "else", "{", "field", ".", "modifiers", "=", "modifiers", ";", "field", ".", "type", "=", "createTypeReference", "(", "fieldInfo", ".", "getTypeName", "(", ")", ",", "start", ",", "end", ")", ";", "}", "if", "(", "this", ".", "has1_5Compliance", ")", "{", "field", ".", "annotations", "=", "convertAnnotations", "(", "fieldHandle", ")", ";", "}", "if", "(", "(", "this", ".", "flags", "&", "FIELD_INITIALIZATION", ")", "!=", "0", ")", "{", "char", "[", "]", "initializationSource", "=", "fieldInfo", ".", "getInitializationSource", "(", ")", ";", "if", "(", "initializationSource", "!=", "null", ")", "{", "if", "(", "this", ".", "parser", "==", "null", ")", "{", "this", ".", "parser", "=", "new", "Parser", "(", "this", ".", "problemReporter", ",", "true", ")", ";", "}", "this", ".", "parser", ".", "parse", "(", "field", ",", "type", ",", "this", ".", "unit", ",", "initializationSource", ")", ";", "}", "}", "if", "(", "(", "this", ".", "flags", "&", "LOCAL_TYPE", ")", "!=", "0", ")", "{", "IJavaElement", "[", "]", "children", "=", "fieldInfo", ".", "getChildren", "(", ")", ";", "int", "childrenLength", "=", "children", ".", "length", ";", "if", "(", "childrenLength", "==", "1", ")", "{", "field", ".", "initialization", "=", "convert", "(", "children", "[", "0", "]", ",", "isEnumConstant", "?", "field", ":", "null", ",", "compilationResult", ")", ";", "}", "else", "if", "(", "childrenLength", ">", "1", ")", "{", "ArrayInitializer", "initializer", "=", "new", "ArrayInitializer", "(", ")", ";", "field", ".", "initialization", "=", "initializer", ";", "Expression", "[", "]", "expressions", "=", "new", "Expression", "[", "childrenLength", "]", ";", "initializer", ".", "expressions", "=", "expressions", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "childrenLength", ";", "i", "++", ")", "{", "expressions", "[", "i", "]", "=", "convert", "(", "children", "[", "i", "]", ",", "isEnumConstant", "?", "field", ":", "null", ",", "compilationResult", ")", ";", "}", "}", "}", "return", "field", ";", "}", "private", "QualifiedAllocationExpression", "convert", "(", "IJavaElement", "localType", ",", "FieldDeclaration", "enumConstant", ",", "CompilationResult", "compilationResult", ")", "throws", "JavaModelException", "{", "TypeDeclaration", "anonymousLocalTypeDeclaration", "=", "convert", "(", "(", "SourceType", ")", "localType", ",", "compilationResult", ")", ";", "QualifiedAllocationExpression", "expression", "=", "new", "QualifiedAllocationExpression", "(", "anonymousLocalTypeDeclaration", ")", ";", "expression", ".", "type", "=", "anonymousLocalTypeDeclaration", ".", "superclass", ";", "anonymousLocalTypeDeclaration", ".", "superclass", "=", "null", ";", "anonymousLocalTypeDeclaration", ".", "superInterfaces", "=", "null", ";", "anonymousLocalTypeDeclaration", ".", "allocation", "=", "expression", ";", "if", "(", "enumConstant", "!=", "null", ")", "{", "anonymousLocalTypeDeclaration", ".", "modifiers", "&=", "~", "ClassFileConstants", ".", "AccEnum", ";", "expression", ".", "enumConstant", "=", "enumConstant", ";", "expression", ".", "type", "=", "null", ";", "}", "return", "expression", ";", "}", "private", "AbstractMethodDeclaration", "convert", "(", "SourceMethod", "methodHandle", ",", "SourceMethodElementInfo", "methodInfo", ",", "CompilationResult", "compilationResult", ")", "throws", "JavaModelException", "{", "AbstractMethodDeclaration", "method", ";", "int", "start", "=", "methodInfo", ".", "getNameSourceStart", "(", ")", ";", "int", "end", "=", "methodInfo", ".", "getNameSourceEnd", "(", ")", ";", "TypeParameter", "[", "]", "typeParams", "=", "null", ";", "if", "(", "this", ".", "has1_5Compliance", ")", "{", "char", "[", "]", "[", "]", "typeParameterNames", "=", "methodInfo", ".", "getTypeParameterNames", "(", ")", ";", "if", "(", "typeParameterNames", "!=", "null", ")", "{", "int", "parameterCount", "=", "typeParameterNames", ".", "length", ";", "if", "(", "parameterCount", ">", "0", ")", "{", "char", "[", "]", "[", "]", "[", "]", "typeParameterBounds", "=", "methodInfo", ".", "getTypeParameterBounds", "(", ")", ";", "typeParams", "=", "new", "TypeParameter", "[", "parameterCount", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "parameterCount", ";", "i", "++", ")", "{", "typeParams", "[", "i", "]", "=", "createTypeParameter", "(", "typeParameterNames", "[", "i", "]", ",", "typeParameterBounds", "[", "i", "]", ",", "start", ",", "end", ")", ";", "}", "}", "}", "}", "int", "modifiers", "=", "methodInfo", ".", "getModifiers", "(", ")", ";", "if", "(", "methodInfo", ".", "isConstructor", "(", ")", ")", "{", "ConstructorDeclaration", "decl", "=", "new", "ConstructorDeclaration", "(", "compilationResult", ")", ";", "decl", ".", "bits", "&=", "~", "ASTNode", ".", "IsDefaultConstructor", ";", "method", "=", "decl", ";", "decl", ".", "typeParameters", "=", "typeParams", ";", "}", "else", "{", "MethodDeclaration", "decl", ";", "if", "(", "methodInfo", ".", "isAnnotationMethod", "(", ")", ")", "{", "AnnotationMethodDeclaration", "annotationMethodDeclaration", "=", "new", "AnnotationMethodDeclaration", "(", "compilationResult", ")", ";", "SourceAnnotationMethodInfo", "annotationMethodInfo", "=", "(", "SourceAnnotationMethodInfo", ")", "methodInfo", ";", "boolean", "hasDefaultValue", "=", "annotationMethodInfo", ".", "defaultValueStart", "!=", "-", "1", "||", "annotationMethodInfo", ".", "defaultValueEnd", "!=", "-", "1", ";", "if", "(", "(", "this", ".", "flags", "&", "FIELD_INITIALIZATION", ")", "!=", "0", ")", "{", "if", "(", "hasDefaultValue", ")", "{", "char", "[", "]", "defaultValueSource", "=", "CharOperation", ".", "subarray", "(", "getSource", "(", ")", ",", "annotationMethodInfo", ".", "defaultValueStart", ",", "annotationMethodInfo", ".", "defaultValueEnd", "+", "1", ")", ";", "if", "(", "defaultValueSource", "!=", "null", ")", "{", "Expression", "expression", "=", "parseMemberValue", "(", "defaultValueSource", ")", ";", "if", "(", "expression", "!=", "null", ")", "{", "annotationMethodDeclaration", ".", "defaultValue", "=", "expression", ";", "}", "}", "else", "{", "hasDefaultValue", "=", "false", ";", "}", "}", "}", "if", "(", "hasDefaultValue", ")", "modifiers", "|=", "ClassFileConstants", ".", "AccAnnotationDefault", ";", "decl", "=", "annotationMethodDeclaration", ";", "}", "else", "{", "decl", "=", "new", "MethodDeclaration", "(", "compilationResult", ")", ";", "}", "decl", ".", "returnType", "=", "createTypeReference", "(", "methodInfo", ".", "getReturnTypeName", "(", ")", ",", "start", ",", "end", ")", ";", "decl", ".", "typeParameters", "=", "typeParams", ";", "method", "=", "decl", ";", "}", "method", ".", "selector", "=", "methodHandle", ".", "getElementName", "(", ")", ".", "toCharArray", "(", ")", ";", "boolean", "isVarargs", "=", "(", "modifiers", "&", "ClassFileConstants", ".", "AccVarargs", ")", "!=", "0", ";", "method", ".", "modifiers", "=", "modifiers", "&", "~", "ClassFileConstants", ".", "AccVarargs", ";", "method", ".", "sourceStart", "=", "start", ";", "method", ".", "sourceEnd", "=", "end", ";", "method", ".", "declarationSourceStart", "=", "methodInfo", ".", "getDeclarationSourceStart", "(", ")", ";", "method", ".", "declarationSourceEnd", "=", "methodInfo", ".", "getDeclarationSourceEnd", "(", ")", ";", "if", "(", "this", ".", "has1_5Compliance", ")", "{", "method", ".", "annotations", "=", "convertAnnotations", "(", "methodHandle", ")", ";", "}", "String", "[", "]", "argumentTypeSignatures", "=", "methodHandle", ".", "getParameterTypes", "(", ")", ";", "char", "[", "]", "[", "]", "argumentNames", "=", "methodInfo", ".", "getArgumentNames", "(", ")", ";", "int", "argumentCount", "=", "argumentTypeSignatures", "==", "null", "?", "0", ":", "argumentTypeSignatures", ".", "length", ";", "if", "(", "argumentCount", ">", "0", ")", "{", "long", "position", "=", "(", "(", "long", ")", "start", "<<", "32", ")", "+", "end", ";", "method", ".", "arguments", "=", "new", "Argument", "[", "argumentCount", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "argumentCount", ";", "i", "++", ")", "{", "TypeReference", "typeReference", "=", "createTypeReference", "(", "argumentTypeSignatures", "[", "i", "]", ",", "start", ",", "end", ")", ";", "if", "(", "isVarargs", "&&", "i", "==", "argumentCount", "-", "1", ")", "{", "typeReference", ".", "bits", "|=", "ASTNode", ".", "IsVarArgs", ";", "}", "method", ".", "arguments", "[", "i", "]", "=", "new", "Argument", "(", "argumentNames", "[", "i", "]", ",", "position", ",", "typeReference", ",", "ClassFileConstants", ".", "AccDefault", ")", ";", "}", "}", "char", "[", "]", "[", "]", "exceptionTypeNames", "=", "methodInfo", ".", "getExceptionTypeNames", "(", ")", ";", "int", "exceptionCount", "=", "exceptionTypeNames", "==", "null", "?", "0", ":", "exceptionTypeNames", ".", "length", ";", "if", "(", "exceptionCount", ">", "0", ")", "{", "method", ".", "thrownExceptions", "=", "new", "TypeReference", "[", "exceptionCount", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "exceptionCount", ";", "i", "++", ")", "{", "method", ".", "thrownExceptions", "[", "i", "]", "=", "createTypeReference", "(", "exceptionTypeNames", "[", "i", "]", ",", "start", ",", "end", ")", ";", "}", "}", "if", "(", "(", "this", ".", "flags", "&", "LOCAL_TYPE", ")", "!=", "0", ")", "{", "IJavaElement", "[", "]", "children", "=", "methodInfo", ".", "getChildren", "(", ")", ";", "int", "typesLength", "=", "children", ".", "length", ";", "if", "(", "typesLength", "!=", "0", ")", "{", "Statement", "[", "]", "statements", "=", "new", "Statement", "[", "typesLength", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "typesLength", ";", "i", "++", ")", "{", "SourceType", "type", "=", "(", "SourceType", ")", "children", "[", "i", "]", ";", "TypeDeclaration", "localType", "=", "convert", "(", "type", ",", "compilationResult", ")", ";", "if", "(", "(", "localType", ".", "bits", "&", "ASTNode", ".", "IsAnonymousType", ")", "!=", "0", ")", "{", "QualifiedAllocationExpression", "expression", "=", "new", "QualifiedAllocationExpression", "(", "localType", ")", ";", "expression", ".", "type", "=", "localType", ".", "superclass", ";", "localType", ".", "superclass", "=", "null", ";", "localType", ".", "superInterfaces", "=", "null", ";", "localType", ".", "allocation", "=", "expression", ";", "statements", "[", "i", "]", "=", "expression", ";", "}", "else", "{", "statements", "[", "i", "]", "=", "localType", ";", "}", "}", "method", ".", "statements", "=", "statements", ";", "}", "}", "return", "method", ";", "}", "private", "TypeDeclaration", "convert", "(", "SourceType", "typeHandle", ",", "CompilationResult", "compilationResult", ")", "throws", "JavaModelException", "{", "SourceTypeElementInfo", "typeInfo", "=", "(", "SourceTypeElementInfo", ")", "typeHandle", ".", "getElementInfo", "(", ")", ";", "if", "(", "typeInfo", ".", "isAnonymousMember", "(", ")", ")", "throw", "new", "AnonymousMemberFound", "(", ")", ";", "TypeDeclaration", "type", "=", "new", "TypeDeclaration", "(", "compilationResult", ")", ";", "if", "(", "typeInfo", ".", "getEnclosingType", "(", ")", "==", "null", ")", "{", "if", "(", "typeHandle", ".", "isAnonymous", "(", ")", ")", "{", "type", ".", "name", "=", "CharOperation", ".", "NO_CHAR", ";", "type", ".", "bits", "|=", "(", "ASTNode", ".", "IsAnonymousType", "|", "ASTNode", ".", "IsLocalType", ")", ";", "}", "else", "{", "if", "(", "typeHandle", ".", "isLocal", "(", ")", ")", "{", "type", ".", "bits", "|=", "ASTNode", ".", "IsLocalType", ";", "}", "}", "}", "else", "{", "type", ".", "bits", "|=", "ASTNode", ".", "IsMemberType", ";", "}", "if", "(", "(", "type", ".", "bits", "&", "ASTNode", ".", "IsAnonymousType", ")", "==", "0", ")", "{", "type", ".", "name", "=", "typeInfo", ".", "getName", "(", ")", ";", "}", "type", ".", "name", "=", "typeInfo", ".", "getName", "(", ")", ";", "int", "start", ",", "end", ";", "type", ".", "sourceStart", "=", "start", "=", "typeInfo", ".", "getNameSourceStart", "(", ")", ";", "type", ".", "sourceEnd", "=", "end", "=", "typeInfo", ".", "getNameSourceEnd", "(", ")", ";", "type", ".", "modifiers", "=", "typeInfo", ".", "getModifiers", "(", ")", ";", "type", ".", "declarationSourceStart", "=", "typeInfo", ".", "getDeclarationSourceStart", "(", ")", ";", "type", ".", "declarationSourceEnd", "=", "typeInfo", ".", "getDeclarationSourceEnd", "(", ")", ";", "type", ".", "bodyEnd", "=", "type", ".", "declarationSourceEnd", ";", "if", "(", "this", ".", "has1_5Compliance", ")", "{", "type", ".", "annotations", "=", "convertAnnotations", "(", "typeHandle", ")", ";", "char", "[", "]", "[", "]", "typeParameterNames", "=", "typeInfo", ".", "getTypeParameterNames", "(", ")", ";", "if", "(", "typeParameterNames", ".", "length", ">", "0", ")", "{", "int", "parameterCount", "=", "typeParameterNames", ".", "length", ";", "char", "[", "]", "[", "]", "[", "]", "typeParameterBounds", "=", "typeInfo", ".", "getTypeParameterBounds", "(", ")", ";", "type", ".", "typeParameters", "=", "new", "TypeParameter", "[", "parameterCount", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "parameterCount", ";", "i", "++", ")", "{", "type", ".", "typeParameters", "[", "i", "]", "=", "createTypeParameter", "(", "typeParameterNames", "[", "i", "]", ",", "typeParameterBounds", "[", "i", "]", ",", "start", ",", "end", ")", ";", "}", "}", "}", "if", "(", "typeInfo", ".", "getSuperclassName", "(", ")", "!=", "null", ")", "{", "type", ".", "superclass", "=", "createTypeReference", "(", "typeInfo", ".", "getSuperclassName", "(", ")", ",", "start", ",", "end", ")", ";", "type", ".", "superclass", ".", "bits", "|=", "ASTNode", ".", "IsSuperType", ";", "}", "char", "[", "]", "[", "]", "interfaceNames", "=", "typeInfo", ".", "getInterfaceNames", "(", ")", ";", "int", "interfaceCount", "=", "interfaceNames", "==", "null", "?", "0", ":", "interfaceNames", ".", "length", ";", "if", "(", "interfaceCount", ">", "0", ")", "{", "type", ".", "superInterfaces", "=", "new", "TypeReference", "[", "interfaceCount", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "interfaceCount", ";", "i", "++", ")", "{", "type", ".", "superInterfaces", "[", "i", "]", "=", "createTypeReference", "(", "interfaceNames", "[", "i", "]", ",", "start", ",", "end", ")", ";", "type", ".", "superInterfaces", "[", "i", "]", ".", "bits", "|=", "ASTNode", ".", "IsSuperType", ";", "}", "}", "if", "(", "(", "this", ".", "flags", "&", "MEMBER_TYPE", ")", "!=", "0", ")", "{", "SourceType", "[", "]", "sourceMemberTypes", "=", "typeInfo", ".", "getMemberTypeHandles", "(", ")", ";", "int", "sourceMemberTypeCount", "=", "sourceMemberTypes", ".", "length", ";", "type", ".", "memberTypes", "=", "new", "TypeDeclaration", "[", "sourceMemberTypeCount", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "sourceMemberTypeCount", ";", "i", "++", ")", "{", "type", ".", "memberTypes", "[", "i", "]", "=", "convert", "(", "sourceMemberTypes", "[", "i", "]", ",", "compilationResult", ")", ";", "}", "}", "InitializerElementInfo", "[", "]", "initializers", "=", "null", ";", "int", "initializerCount", "=", "0", ";", "if", "(", "(", "this", ".", "flags", "&", "LOCAL_TYPE", ")", "!=", "0", ")", "{", "initializers", "=", "typeInfo", ".", "getInitializers", "(", ")", ";", "initializerCount", "=", "initializers", ".", "length", ";", "}", "SourceField", "[", "]", "sourceFields", "=", "null", ";", "int", "sourceFieldCount", "=", "0", ";", "if", "(", "(", "this", ".", "flags", "&", "FIELD", ")", "!=", "0", ")", "{", "sourceFields", "=", "typeInfo", ".", "getFieldHandles", "(", ")", ";", "sourceFieldCount", "=", "sourceFields", ".", "length", ";", "}", "int", "length", "=", "initializerCount", "+", "sourceFieldCount", ";", "if", "(", "length", ">", "0", ")", "{", "type", ".", "fields", "=", "new", "FieldDeclaration", "[", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "initializerCount", ";", "i", "++", ")", "{", "type", ".", "fields", "[", "i", "]", "=", "convert", "(", "initializers", "[", "i", "]", ",", "compilationResult", ")", ";", "}", "int", "index", "=", "0", ";", "for", "(", "int", "i", "=", "initializerCount", ";", "i", "<", "length", ";", "i", "++", ")", "{", "type", ".", "fields", "[", "i", "]", "=", "convert", "(", "sourceFields", "[", "index", "++", "]", ",", "type", ",", "compilationResult", ")", ";", "}", "}", "boolean", "needConstructor", "=", "(", "this", ".", "flags", "&", "CONSTRUCTOR", ")", "!=", "0", ";", "boolean", "needMethod", "=", "(", "this", ".", "flags", "&", "METHOD", ")", "!=", "0", ";", "if", "(", "needConstructor", "||", "needMethod", ")", "{", "SourceMethod", "[", "]", "sourceMethods", "=", "typeInfo", ".", "getMethodHandles", "(", ")", ";", "int", "sourceMethodCount", "=", "sourceMethods", ".", "length", ";", "int", "extraConstructor", "=", "0", ";", "int", "methodCount", "=", "0", ";", "int", "kind", "=", "TypeDeclaration", ".", "kind", "(", "type", ".", "modifiers", ")", ";", "boolean", "isAbstract", "=", "kind", "==", "TypeDeclaration", ".", "INTERFACE_DECL", "||", "kind", "==", "TypeDeclaration", ".", "ANNOTATION_TYPE_DECL", ";", "if", "(", "!", "isAbstract", ")", "{", "extraConstructor", "=", "needConstructor", "?", "1", ":", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "sourceMethodCount", ";", "i", "++", ")", "{", "if", "(", "sourceMethods", "[", "i", "]", ".", "isConstructor", "(", ")", ")", "{", "if", "(", "needConstructor", ")", "{", "extraConstructor", "=", "0", ";", "methodCount", "++", ";", "}", "}", "else", "if", "(", "needMethod", ")", "{", "methodCount", "++", ";", "}", "}", "}", "else", "{", "methodCount", "=", "needMethod", "?", "sourceMethodCount", ":", "0", ";", "}", "type", ".", "methods", "=", "new", "AbstractMethodDeclaration", "[", "methodCount", "+", "extraConstructor", "]", ";", "if", "(", "extraConstructor", "!=", "0", ")", "{", "type", ".", "methods", "[", "0", "]", "=", "type", ".", "createDefaultConstructor", "(", "false", ",", "false", ")", ";", "}", "int", "index", "=", "0", ";", "boolean", "hasAbstractMethods", "=", "false", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "sourceMethodCount", ";", "i", "++", ")", "{", "SourceMethod", "sourceMethod", "=", "sourceMethods", "[", "i", "]", ";", "SourceMethodElementInfo", "methodInfo", "=", "(", "SourceMethodElementInfo", ")", "sourceMethod", ".", "getElementInfo", "(", ")", ";", "boolean", "isConstructor", "=", "methodInfo", ".", "isConstructor", "(", ")", ";", "if", "(", "(", "methodInfo", ".", "getModifiers", "(", ")", "&", "ClassFileConstants", ".", "AccAbstract", ")", "!=", "0", ")", "{", "hasAbstractMethods", "=", "true", ";", "}", "if", "(", "(", "isConstructor", "&&", "needConstructor", ")", "||", "(", "!", "isConstructor", "&&", "needMethod", ")", ")", "{", "AbstractMethodDeclaration", "method", "=", "convert", "(", "sourceMethod", ",", "methodInfo", ",", "compilationResult", ")", ";", "if", "(", "isAbstract", "||", "method", ".", "isAbstract", "(", ")", ")", "{", "method", ".", "modifiers", "|=", "ExtraCompilerModifiers", ".", "AccSemicolonBody", ";", "}", "type", ".", "methods", "[", "extraConstructor", "+", "index", "++", "]", "=", "method", ";", "}", "}", "if", "(", "hasAbstractMethods", ")", "type", ".", "bits", "|=", "ASTNode", ".", "HasAbstractMethods", ";", "}", "return", "type", ";", "}", "private", "Annotation", "[", "]", "convertAnnotations", "(", "IAnnotatable", "element", ")", "throws", "JavaModelException", "{", "IAnnotation", "[", "]", "annotations", "=", "element", ".", "getAnnotations", "(", ")", ";", "int", "length", "=", "annotations", ".", "length", ";", "Annotation", "[", "]", "astAnnotations", "=", "new", "Annotation", "[", "length", "]", ";", "if", "(", "length", ">", "0", ")", "{", "char", "[", "]", "cuSource", "=", "getSource", "(", ")", ";", "int", "recordedAnnotations", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "ISourceRange", "positions", "=", "annotations", "[", "i", "]", ".", "getSourceRange", "(", ")", ";", "int", "start", "=", "positions", ".", "getOffset", "(", ")", ";", "int", "end", "=", "start", "+", "positions", ".", "getLength", "(", ")", ";", "char", "[", "]", "annotationSource", "=", "CharOperation", ".", "subarray", "(", "cuSource", ",", "start", ",", "end", ")", ";", "if", "(", "annotationSource", "!=", "null", ")", "{", "Expression", "expression", "=", "parseMemberValue", "(", "annotationSource", ")", ";", "if", "(", "expression", "instanceof", "Annotation", ")", "{", "astAnnotations", "[", "recordedAnnotations", "++", "]", "=", "(", "Annotation", ")", "expression", ";", "}", "}", "}", "if", "(", "length", "!=", "recordedAnnotations", ")", "{", "System", ".", "arraycopy", "(", "astAnnotations", ",", "0", ",", "(", "astAnnotations", "=", "new", "Annotation", "[", "recordedAnnotations", "]", ")", ",", "0", ",", "recordedAnnotations", ")", ";", "}", "}", "return", "astAnnotations", ";", "}", "private", "char", "[", "]", "getSource", "(", ")", "{", "if", "(", "this", ".", "source", "==", "null", ")", "this", ".", "source", "=", "this", ".", "cu", ".", "getContents", "(", ")", ";", "return", "this", ".", "source", ";", "}", "private", "Expression", "parseMemberValue", "(", "char", "[", "]", "memberValue", ")", "{", "if", "(", "this", ".", "parser", "==", "null", ")", "{", "this", ".", "parser", "=", "new", "Parser", "(", "this", ".", "problemReporter", ",", "true", ")", ";", "}", "return", "this", ".", "parser", ".", "parseMemberValue", "(", "memberValue", ",", "0", ",", "memberValue", ".", "length", ",", "this", ".", "unit", ")", ";", "}", "}", "</s>" ]
5,542
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IType", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileReader", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "IBinaryNestedType", ";", "public", "final", "class", "ExtraFlags", "{", "public", "final", "static", "int", "HasNonPrivateStaticMemberTypes", "=", "0x0001", ";", "public", "final", "static", "int", "IsMemberType", "=", "0x0002", ";", "public", "final", "static", "int", "IsLocalType", "=", "0x0004", ";", "public", "final", "static", "int", "ParameterTypesStoredAsSignature", "=", "0x0010", ";", "public", "static", "int", "getExtraFlags", "(", "ClassFileReader", "reader", ")", "{", "int", "extraFlags", "=", "0", ";", "if", "(", "reader", ".", "isNestedType", "(", ")", ")", "{", "extraFlags", "|=", "ExtraFlags", ".", "IsMemberType", ";", "}", "if", "(", "reader", ".", "isLocal", "(", ")", ")", "{", "extraFlags", "|=", "ExtraFlags", ".", "IsLocalType", ";", "}", "IBinaryNestedType", "[", "]", "memberTypes", "=", "reader", ".", "getMemberTypes", "(", ")", ";", "int", "memberTypeCounter", "=", "memberTypes", "==", "null", "?", "0", ":", "memberTypes", ".", "length", ";", "if", "(", "memberTypeCounter", ">", "0", ")", "{", "done", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "memberTypeCounter", ";", "i", "++", ")", "{", "int", "modifiers", "=", "memberTypes", "[", "i", "]", ".", "getModifiers", "(", ")", ";", "if", "(", "(", "modifiers", "&", "ClassFileConstants", ".", "AccStatic", ")", "!=", "0", "&&", "(", "modifiers", "&", "ClassFileConstants", ".", "AccPrivate", ")", "==", "0", ")", "{", "extraFlags", "|=", "ExtraFlags", ".", "HasNonPrivateStaticMemberTypes", ";", "break", "done", ";", "}", "}", "}", "return", "extraFlags", ";", "}", "public", "static", "int", "getExtraFlags", "(", "IType", "type", ")", "throws", "JavaModelException", "{", "int", "extraFlags", "=", "0", ";", "if", "(", "type", ".", "isMember", "(", ")", ")", "{", "extraFlags", "|=", "ExtraFlags", ".", "IsMemberType", ";", "}", "if", "(", "type", ".", "isLocal", "(", ")", ")", "{", "extraFlags", "|=", "ExtraFlags", ".", "IsLocalType", ";", "}", "IType", "[", "]", "memberTypes", "=", "type", ".", "getTypes", "(", ")", ";", "int", "memberTypeCounter", "=", "memberTypes", "==", "null", "?", "0", ":", "memberTypes", ".", "length", ";", "if", "(", "memberTypeCounter", ">", "0", ")", "{", "done", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "memberTypeCounter", ";", "i", "++", ")", "{", "int", "flags", "=", "memberTypes", "[", "i", "]", ".", "getFlags", "(", ")", ";", "if", "(", "(", "flags", "&", "ClassFileConstants", ".", "AccStatic", ")", "!=", "0", "&&", "(", "flags", "&", "ClassFileConstants", ".", "AccPrivate", ")", "==", "0", ")", "{", "extraFlags", "|=", "ExtraFlags", ".", "HasNonPrivateStaticMemberTypes", ";", "break", "done", ";", "}", "}", "}", "return", "extraFlags", ";", "}", "public", "static", "int", "getExtraFlags", "(", "TypeDeclaration", "typeDeclaration", ")", "{", "int", "extraFlags", "=", "0", ";", "if", "(", "typeDeclaration", ".", "enclosingType", "!=", "null", ")", "{", "extraFlags", "|=", "ExtraFlags", ".", "IsMemberType", ";", "}", "TypeDeclaration", "[", "]", "memberTypes", "=", "typeDeclaration", ".", "memberTypes", ";", "int", "memberTypeCounter", "=", "memberTypes", "==", "null", "?", "0", ":", "memberTypes", ".", "length", ";", "if", "(", "memberTypeCounter", ">", "0", ")", "{", "done", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "memberTypeCounter", ";", "i", "++", ")", "{", "int", "modifiers", "=", "memberTypes", "[", "i", "]", ".", "modifiers", ";", "if", "(", "(", "modifiers", "&", "ClassFileConstants", ".", "AccStatic", ")", "!=", "0", "&&", "(", "modifiers", "&", "ClassFileConstants", ".", "AccPrivate", ")", "==", "0", ")", "{", "extraFlags", "|=", "ExtraFlags", ".", "HasNonPrivateStaticMemberTypes", ";", "break", "done", ";", "}", "}", "}", "return", "extraFlags", ";", "}", "}", "</s>" ]
5,543
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ISourceElementRequestor", ".", "TypeParameterInfo", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ASTNode", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AbstractMethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AbstractVariableDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AllocationExpression", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Annotation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AnnotationMethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Argument", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ArrayAllocationExpression", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ArrayInitializer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ArrayReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Assignment", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ClassLiteralAccess", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "CompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ConstructorDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ExplicitConstructorCall", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Expression", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "FieldDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ImportReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Initializer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "MessageSend", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "MethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "QualifiedAllocationExpression", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ThisReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeParameter", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "BlockScope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ClassScope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ExtraCompilerModifiers", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "MethodScope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "HashtableOfObjectToInt", ";", "public", "class", "SourceElementNotifier", "{", "public", "class", "LocalDeclarationVisitor", "extends", "ASTVisitor", "{", "public", "ImportReference", "currentPackage", ";", "ArrayList", "declaringTypes", ";", "public", "void", "pushDeclaringType", "(", "TypeDeclaration", "declaringType", ")", "{", "if", "(", "this", ".", "declaringTypes", "==", "null", ")", "{", "this", ".", "declaringTypes", "=", "new", "ArrayList", "(", ")", ";", "}", "this", ".", "declaringTypes", ".", "add", "(", "declaringType", ")", ";", "}", "public", "void", "popDeclaringType", "(", ")", "{", "this", ".", "declaringTypes", ".", "remove", "(", "this", ".", "declaringTypes", ".", "size", "(", ")", "-", "1", ")", ";", "}", "public", "TypeDeclaration", "peekDeclaringType", "(", ")", "{", "if", "(", "this", ".", "declaringTypes", "==", "null", ")", "return", "null", ";", "int", "size", "=", "this", ".", "declaringTypes", ".", "size", "(", ")", ";", "if", "(", "size", "==", "0", ")", "return", "null", ";", "return", "(", "TypeDeclaration", ")", "this", ".", "declaringTypes", ".", "get", "(", "size", "-", "1", ")", ";", "}", "public", "boolean", "visit", "(", "TypeDeclaration", "typeDeclaration", ",", "BlockScope", "scope", ")", "{", "notifySourceElementRequestor", "(", "typeDeclaration", ",", "true", ",", "peekDeclaringType", "(", ")", ",", "this", ".", "currentPackage", ")", ";", "return", "false", ";", "}", "public", "boolean", "visit", "(", "TypeDeclaration", "typeDeclaration", ",", "ClassScope", "scope", ")", "{", "notifySourceElementRequestor", "(", "typeDeclaration", ",", "true", ",", "peekDeclaringType", "(", ")", ",", "this", ".", "currentPackage", ")", ";", "return", "false", ";", "}", "}", "ISourceElementRequestor", "requestor", ";", "boolean", "reportReferenceInfo", ";", "char", "[", "]", "[", "]", "typeNames", ";", "char", "[", "]", "[", "]", "superTypeNames", ";", "int", "nestedTypeIndex", ";", "LocalDeclarationVisitor", "localDeclarationVisitor", "=", "null", ";", "HashtableOfObjectToInt", "sourceEnds", ";", "Map", "nodesToCategories", ";", "int", "initialPosition", ";", "int", "eofPosition", ";", "public", "SourceElementNotifier", "(", "ISourceElementRequestor", "requestor", ",", "boolean", "reportLocalDeclarations", ")", "{", "this", ".", "requestor", "=", "requestor", ";", "if", "(", "reportLocalDeclarations", ")", "{", "this", ".", "localDeclarationVisitor", "=", "new", "LocalDeclarationVisitor", "(", ")", ";", "}", "this", ".", "typeNames", "=", "new", "char", "[", "4", "]", "[", "]", ";", "this", ".", "superTypeNames", "=", "new", "char", "[", "4", "]", "[", "]", ";", "this", ".", "nestedTypeIndex", "=", "0", ";", "}", "protected", "char", "[", "]", "[", "]", "[", "]", "getArguments", "(", "Argument", "[", "]", "arguments", ")", "{", "int", "argumentLength", "=", "arguments", ".", "length", ";", "char", "[", "]", "[", "]", "argumentTypes", "=", "new", "char", "[", "argumentLength", "]", "[", "]", ";", "char", "[", "]", "[", "]", "argumentNames", "=", "new", "char", "[", "argumentLength", "]", "[", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "argumentLength", ";", "i", "++", ")", "{", "argumentTypes", "[", "i", "]", "=", "CharOperation", ".", "concatWith", "(", "arguments", "[", "i", "]", ".", "type", ".", "getParameterizedTypeName", "(", ")", ",", "'.'", ")", ";", "argumentNames", "[", "i", "]", "=", "arguments", "[", "i", "]", ".", "name", ";", "}", "return", "new", "char", "[", "]", "[", "]", "[", "]", "{", "argumentTypes", ",", "argumentNames", "}", ";", "}", "protected", "char", "[", "]", "[", "]", "getInterfaceNames", "(", "TypeDeclaration", "typeDeclaration", ")", "{", "char", "[", "]", "[", "]", "interfaceNames", "=", "null", ";", "int", "superInterfacesLength", "=", "0", ";", "TypeReference", "[", "]", "superInterfaces", "=", "typeDeclaration", ".", "superInterfaces", ";", "if", "(", "superInterfaces", "!=", "null", ")", "{", "superInterfacesLength", "=", "superInterfaces", ".", "length", ";", "interfaceNames", "=", "new", "char", "[", "superInterfacesLength", "]", "[", "]", ";", "}", "else", "{", "if", "(", "(", "typeDeclaration", ".", "bits", "&", "ASTNode", ".", "IsAnonymousType", ")", "!=", "0", ")", "{", "QualifiedAllocationExpression", "alloc", "=", "typeDeclaration", ".", "allocation", ";", "if", "(", "alloc", "!=", "null", "&&", "alloc", ".", "type", "!=", "null", ")", "{", "superInterfaces", "=", "new", "TypeReference", "[", "]", "{", "alloc", ".", "type", "}", ";", "superInterfacesLength", "=", "1", ";", "interfaceNames", "=", "new", "char", "[", "1", "]", "[", "]", ";", "}", "}", "}", "if", "(", "superInterfaces", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "superInterfacesLength", ";", "i", "++", ")", "{", "interfaceNames", "[", "i", "]", "=", "CharOperation", ".", "concatWith", "(", "superInterfaces", "[", "i", "]", ".", "getParameterizedTypeName", "(", ")", ",", "'.'", ")", ";", "}", "}", "return", "interfaceNames", ";", "}", "protected", "char", "[", "]", "getSuperclassName", "(", "TypeDeclaration", "typeDeclaration", ")", "{", "TypeReference", "superclass", "=", "typeDeclaration", ".", "superclass", ";", "return", "superclass", "!=", "null", "?", "CharOperation", ".", "concatWith", "(", "superclass", ".", "getParameterizedTypeName", "(", ")", ",", "'.'", ")", ":", "null", ";", "}", "protected", "char", "[", "]", "[", "]", "getThrownExceptions", "(", "AbstractMethodDeclaration", "methodDeclaration", ")", "{", "char", "[", "]", "[", "]", "thrownExceptionTypes", "=", "null", ";", "TypeReference", "[", "]", "thrownExceptions", "=", "methodDeclaration", ".", "thrownExceptions", ";", "if", "(", "thrownExceptions", "!=", "null", ")", "{", "int", "thrownExceptionLength", "=", "thrownExceptions", ".", "length", ";", "thrownExceptionTypes", "=", "new", "char", "[", "thrownExceptionLength", "]", "[", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "thrownExceptionLength", ";", "i", "++", ")", "{", "thrownExceptionTypes", "[", "i", "]", "=", "CharOperation", ".", "concatWith", "(", "thrownExceptions", "[", "i", "]", ".", "getParameterizedTypeName", "(", ")", ",", "'.'", ")", ";", "}", "}", "return", "thrownExceptionTypes", ";", "}", "protected", "char", "[", "]", "[", "]", "getTypeParameterBounds", "(", "TypeParameter", "typeParameter", ")", "{", "TypeReference", "firstBound", "=", "typeParameter", ".", "type", ";", "TypeReference", "[", "]", "otherBounds", "=", "typeParameter", ".", "bounds", ";", "char", "[", "]", "[", "]", "typeParameterBounds", "=", "null", ";", "if", "(", "firstBound", "!=", "null", ")", "{", "if", "(", "otherBounds", "!=", "null", ")", "{", "int", "otherBoundsLength", "=", "otherBounds", ".", "length", ";", "char", "[", "]", "[", "]", "boundNames", "=", "new", "char", "[", "otherBoundsLength", "+", "1", "]", "[", "]", ";", "boundNames", "[", "0", "]", "=", "CharOperation", ".", "concatWith", "(", "firstBound", ".", "getParameterizedTypeName", "(", ")", ",", "'.'", ")", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "otherBoundsLength", ";", "j", "++", ")", "{", "boundNames", "[", "j", "+", "1", "]", "=", "CharOperation", ".", "concatWith", "(", "otherBounds", "[", "j", "]", ".", "getParameterizedTypeName", "(", ")", ",", "'.'", ")", ";", "}", "typeParameterBounds", "=", "boundNames", ";", "}", "else", "{", "typeParameterBounds", "=", "new", "char", "[", "]", "[", "]", "{", "CharOperation", ".", "concatWith", "(", "firstBound", ".", "getParameterizedTypeName", "(", ")", ",", "'.'", ")", "}", ";", "}", "}", "else", "{", "typeParameterBounds", "=", "CharOperation", ".", "NO_CHAR_CHAR", ";", "}", "return", "typeParameterBounds", ";", "}", "private", "TypeParameterInfo", "[", "]", "getTypeParameterInfos", "(", "TypeParameter", "[", "]", "typeParameters", ")", "{", "if", "(", "typeParameters", "==", "null", ")", "return", "null", ";", "int", "typeParametersLength", "=", "typeParameters", ".", "length", ";", "TypeParameterInfo", "[", "]", "result", "=", "new", "TypeParameterInfo", "[", "typeParametersLength", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "typeParametersLength", ";", "i", "++", ")", "{", "TypeParameter", "typeParameter", "=", "typeParameters", "[", "i", "]", ";", "char", "[", "]", "[", "]", "typeParameterBounds", "=", "getTypeParameterBounds", "(", "typeParameter", ")", ";", "ISourceElementRequestor", ".", "TypeParameterInfo", "typeParameterInfo", "=", "new", "ISourceElementRequestor", ".", "TypeParameterInfo", "(", ")", ";", "typeParameterInfo", ".", "declarationStart", "=", "typeParameter", ".", "declarationSourceStart", ";", "typeParameterInfo", ".", "declarationEnd", "=", "typeParameter", ".", "declarationSourceEnd", ";", "typeParameterInfo", ".", "name", "=", "typeParameter", ".", "name", ";", "typeParameterInfo", ".", "nameSourceStart", "=", "typeParameter", ".", "sourceStart", ";", "typeParameterInfo", ".", "nameSourceEnd", "=", "typeParameter", ".", "sourceEnd", ";", "typeParameterInfo", ".", "bounds", "=", "typeParameterBounds", ";", "result", "[", "i", "]", "=", "typeParameterInfo", ";", "}", "return", "result", ";", "}", "private", "boolean", "hasDeprecatedAnnotation", "(", "Annotation", "[", "]", "annotations", ")", "{", "if", "(", "annotations", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "annotations", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "Annotation", "annotation", "=", "annotations", "[", "i", "]", ";", "if", "(", "CharOperation", ".", "equals", "(", "annotation", ".", "type", ".", "getLastToken", "(", ")", ",", "TypeConstants", ".", "JAVA_LANG_DEPRECATED", "[", "2", "]", ")", ")", "{", "return", "true", ";", "}", "}", "}", "return", "false", ";", "}", "protected", "void", "notifySourceElementRequestor", "(", "AbstractMethodDeclaration", "methodDeclaration", ",", "TypeDeclaration", "declaringType", ",", "ImportReference", "currentPackage", ")", "{", "boolean", "isInRange", "=", "this", ".", "initialPosition", "<=", "methodDeclaration", ".", "declarationSourceStart", "&&", "this", ".", "eofPosition", ">=", "methodDeclaration", ".", "declarationSourceEnd", ";", "if", "(", "methodDeclaration", ".", "isClinit", "(", ")", ")", "{", "this", ".", "visitIfNeeded", "(", "methodDeclaration", ")", ";", "return", ";", "}", "if", "(", "methodDeclaration", ".", "isDefaultConstructor", "(", ")", ")", "{", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "ConstructorDeclaration", "constructorDeclaration", "=", "(", "ConstructorDeclaration", ")", "methodDeclaration", ";", "ExplicitConstructorCall", "constructorCall", "=", "constructorDeclaration", ".", "constructorCall", ";", "if", "(", "constructorCall", "!=", "null", ")", "{", "switch", "(", "constructorCall", ".", "accessMode", ")", "{", "case", "ExplicitConstructorCall", ".", "This", ":", "this", ".", "requestor", ".", "acceptConstructorReference", "(", "this", ".", "typeNames", "[", "this", ".", "nestedTypeIndex", "-", "1", "]", ",", "constructorCall", ".", "arguments", "==", "null", "?", "0", ":", "constructorCall", ".", "arguments", ".", "length", ",", "constructorCall", ".", "sourceStart", ")", ";", "break", ";", "case", "ExplicitConstructorCall", ".", "Super", ":", "case", "ExplicitConstructorCall", ".", "ImplicitSuper", ":", "this", ".", "requestor", ".", "acceptConstructorReference", "(", "this", ".", "superTypeNames", "[", "this", ".", "nestedTypeIndex", "-", "1", "]", ",", "constructorCall", ".", "arguments", "==", "null", "?", "0", ":", "constructorCall", ".", "arguments", ".", "length", ",", "constructorCall", ".", "sourceStart", ")", ";", "break", ";", "}", "}", "}", "return", ";", "}", "char", "[", "]", "[", "]", "argumentTypes", "=", "null", ";", "char", "[", "]", "[", "]", "argumentNames", "=", "null", ";", "boolean", "isVarArgs", "=", "false", ";", "Argument", "[", "]", "arguments", "=", "methodDeclaration", ".", "arguments", ";", "if", "(", "arguments", "!=", "null", ")", "{", "char", "[", "]", "[", "]", "[", "]", "argumentTypesAndNames", "=", "getArguments", "(", "arguments", ")", ";", "argumentTypes", "=", "argumentTypesAndNames", "[", "0", "]", ";", "argumentNames", "=", "argumentTypesAndNames", "[", "1", "]", ";", "isVarArgs", "=", "arguments", "[", "arguments", ".", "length", "-", "1", "]", ".", "isVarArgs", "(", ")", ";", "}", "char", "[", "]", "[", "]", "thrownExceptionTypes", "=", "getThrownExceptions", "(", "methodDeclaration", ")", ";", "int", "selectorSourceEnd", "=", "-", "1", ";", "if", "(", "methodDeclaration", ".", "isConstructor", "(", ")", ")", "{", "selectorSourceEnd", "=", "this", ".", "sourceEnds", ".", "get", "(", "methodDeclaration", ")", ";", "if", "(", "isInRange", ")", "{", "int", "currentModifiers", "=", "methodDeclaration", ".", "modifiers", ";", "if", "(", "isVarArgs", ")", "currentModifiers", "|=", "ClassFileConstants", ".", "AccVarargs", ";", "boolean", "deprecated", "=", "(", "currentModifiers", "&", "ClassFileConstants", ".", "AccDeprecated", ")", "!=", "0", "||", "hasDeprecatedAnnotation", "(", "methodDeclaration", ".", "annotations", ")", ";", "ISourceElementRequestor", ".", "MethodInfo", "methodInfo", "=", "new", "ISourceElementRequestor", ".", "MethodInfo", "(", ")", ";", "methodInfo", ".", "isConstructor", "=", "true", ";", "methodInfo", ".", "declarationStart", "=", "methodDeclaration", ".", "declarationSourceStart", ";", "methodInfo", ".", "modifiers", "=", "deprecated", "?", "(", "currentModifiers", "&", "ExtraCompilerModifiers", ".", "AccJustFlag", ")", "|", "ClassFileConstants", ".", "AccDeprecated", ":", "currentModifiers", "&", "ExtraCompilerModifiers", ".", "AccJustFlag", ";", "methodInfo", ".", "name", "=", "methodDeclaration", ".", "selector", ";", "methodInfo", ".", "nameSourceStart", "=", "methodDeclaration", ".", "sourceStart", ";", "methodInfo", ".", "nameSourceEnd", "=", "selectorSourceEnd", ";", "methodInfo", ".", "parameterTypes", "=", "argumentTypes", ";", "methodInfo", ".", "parameterNames", "=", "argumentNames", ";", "methodInfo", ".", "exceptionTypes", "=", "thrownExceptionTypes", ";", "methodInfo", ".", "typeParameters", "=", "getTypeParameterInfos", "(", "methodDeclaration", ".", "typeParameters", "(", ")", ")", ";", "methodInfo", ".", "categories", "=", "(", "char", "[", "]", "[", "]", ")", "this", ".", "nodesToCategories", ".", "get", "(", "methodDeclaration", ")", ";", "methodInfo", ".", "annotations", "=", "methodDeclaration", ".", "annotations", ";", "methodInfo", ".", "declaringPackageName", "=", "currentPackage", "==", "null", "?", "CharOperation", ".", "NO_CHAR", ":", "CharOperation", ".", "concatWith", "(", "currentPackage", ".", "tokens", ",", "'.'", ")", ";", "methodInfo", ".", "declaringTypeModifiers", "=", "declaringType", ".", "modifiers", ";", "methodInfo", ".", "extraFlags", "=", "ExtraFlags", ".", "getExtraFlags", "(", "declaringType", ")", ";", "methodInfo", ".", "node", "=", "methodDeclaration", ";", "this", ".", "requestor", ".", "enterConstructor", "(", "methodInfo", ")", ";", "}", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "ConstructorDeclaration", "constructorDeclaration", "=", "(", "ConstructorDeclaration", ")", "methodDeclaration", ";", "ExplicitConstructorCall", "constructorCall", "=", "constructorDeclaration", ".", "constructorCall", ";", "if", "(", "constructorCall", "!=", "null", ")", "{", "switch", "(", "constructorCall", ".", "accessMode", ")", "{", "case", "ExplicitConstructorCall", ".", "This", ":", "this", ".", "requestor", ".", "acceptConstructorReference", "(", "this", ".", "typeNames", "[", "this", ".", "nestedTypeIndex", "-", "1", "]", ",", "constructorCall", ".", "arguments", "==", "null", "?", "0", ":", "constructorCall", ".", "arguments", ".", "length", ",", "constructorCall", ".", "sourceStart", ")", ";", "break", ";", "case", "ExplicitConstructorCall", ".", "Super", ":", "case", "ExplicitConstructorCall", ".", "ImplicitSuper", ":", "this", ".", "requestor", ".", "acceptConstructorReference", "(", "this", ".", "superTypeNames", "[", "this", ".", "nestedTypeIndex", "-", "1", "]", ",", "constructorCall", ".", "arguments", "==", "null", "?", "0", ":", "constructorCall", ".", "arguments", ".", "length", ",", "constructorCall", ".", "sourceStart", ")", ";", "break", ";", "}", "}", "}", "this", ".", "visitIfNeeded", "(", "methodDeclaration", ")", ";", "if", "(", "isInRange", ")", "{", "this", ".", "requestor", ".", "exitConstructor", "(", "methodDeclaration", ".", "declarationSourceEnd", ")", ";", "}", "return", ";", "}", "selectorSourceEnd", "=", "this", ".", "sourceEnds", ".", "get", "(", "methodDeclaration", ")", ";", "if", "(", "isInRange", ")", "{", "int", "currentModifiers", "=", "methodDeclaration", ".", "modifiers", ";", "if", "(", "isVarArgs", ")", "currentModifiers", "|=", "ClassFileConstants", ".", "AccVarargs", ";", "boolean", "deprecated", "=", "(", "currentModifiers", "&", "ClassFileConstants", ".", "AccDeprecated", ")", "!=", "0", "||", "hasDeprecatedAnnotation", "(", "methodDeclaration", ".", "annotations", ")", ";", "TypeReference", "returnType", "=", "methodDeclaration", "instanceof", "MethodDeclaration", "?", "(", "(", "MethodDeclaration", ")", "methodDeclaration", ")", ".", "returnType", ":", "null", ";", "ISourceElementRequestor", ".", "MethodInfo", "methodInfo", "=", "new", "ISourceElementRequestor", ".", "MethodInfo", "(", ")", ";", "methodInfo", ".", "isAnnotation", "=", "methodDeclaration", "instanceof", "AnnotationMethodDeclaration", ";", "methodInfo", ".", "declarationStart", "=", "methodDeclaration", ".", "declarationSourceStart", ";", "methodInfo", ".", "modifiers", "=", "deprecated", "?", "(", "currentModifiers", "&", "ExtraCompilerModifiers", ".", "AccJustFlag", ")", "|", "ClassFileConstants", ".", "AccDeprecated", ":", "currentModifiers", "&", "ExtraCompilerModifiers", ".", "AccJustFlag", ";", "methodInfo", ".", "returnType", "=", "returnType", "==", "null", "?", "null", ":", "CharOperation", ".", "concatWith", "(", "returnType", ".", "getParameterizedTypeName", "(", ")", ",", "'.'", ")", ";", "methodInfo", ".", "name", "=", "methodDeclaration", ".", "selector", ";", "methodInfo", ".", "nameSourceStart", "=", "methodDeclaration", ".", "sourceStart", ";", "methodInfo", ".", "nameSourceEnd", "=", "selectorSourceEnd", ";", "methodInfo", ".", "parameterTypes", "=", "argumentTypes", ";", "methodInfo", ".", "parameterNames", "=", "argumentNames", ";", "methodInfo", ".", "exceptionTypes", "=", "thrownExceptionTypes", ";", "methodInfo", ".", "typeParameters", "=", "getTypeParameterInfos", "(", "methodDeclaration", ".", "typeParameters", "(", ")", ")", ";", "methodInfo", ".", "categories", "=", "(", "char", "[", "]", "[", "]", ")", "this", ".", "nodesToCategories", ".", "get", "(", "methodDeclaration", ")", ";", "methodInfo", ".", "annotations", "=", "methodDeclaration", ".", "annotations", ";", "methodInfo", ".", "node", "=", "methodDeclaration", ";", "this", ".", "requestor", ".", "enterMethod", "(", "methodInfo", ")", ";", "}", "this", ".", "visitIfNeeded", "(", "methodDeclaration", ")", ";", "if", "(", "isInRange", ")", "{", "if", "(", "methodDeclaration", "instanceof", "AnnotationMethodDeclaration", ")", "{", "AnnotationMethodDeclaration", "annotationMethodDeclaration", "=", "(", "AnnotationMethodDeclaration", ")", "methodDeclaration", ";", "Expression", "expression", "=", "annotationMethodDeclaration", ".", "defaultValue", ";", "if", "(", "expression", "!=", "null", ")", "{", "this", ".", "requestor", ".", "exitMethod", "(", "methodDeclaration", ".", "declarationSourceEnd", ",", "expression", ")", ";", "return", ";", "}", "}", "this", ".", "requestor", ".", "exitMethod", "(", "methodDeclaration", ".", "declarationSourceEnd", ",", "null", ")", ";", "}", "}", "public", "void", "notifySourceElementRequestor", "(", "CompilationUnitDeclaration", "parsedUnit", ",", "int", "sourceStart", ",", "int", "sourceEnd", ",", "boolean", "reportReference", ",", "HashtableOfObjectToInt", "sourceEndsMap", ",", "Map", "nodesToCategoriesMap", ")", "{", "this", ".", "initialPosition", "=", "sourceStart", ";", "this", ".", "eofPosition", "=", "sourceEnd", ";", "this", ".", "reportReferenceInfo", "=", "reportReference", ";", "this", ".", "sourceEnds", "=", "sourceEndsMap", ";", "this", ".", "nodesToCategories", "=", "nodesToCategoriesMap", ";", "try", "{", "boolean", "isInRange", "=", "this", ".", "initialPosition", "<=", "parsedUnit", ".", "sourceStart", "&&", "this", ".", "eofPosition", ">=", "parsedUnit", ".", "sourceEnd", ";", "int", "length", "=", "0", ";", "ASTNode", "[", "]", "nodes", "=", "null", ";", "if", "(", "isInRange", ")", "{", "this", ".", "requestor", ".", "enterCompilationUnit", "(", ")", ";", "}", "ImportReference", "currentPackage", "=", "parsedUnit", ".", "currentPackage", ";", "if", "(", "this", ".", "localDeclarationVisitor", "!=", "null", ")", "{", "this", ".", "localDeclarationVisitor", ".", "currentPackage", "=", "currentPackage", ";", "}", "ImportReference", "[", "]", "imports", "=", "parsedUnit", ".", "imports", ";", "TypeDeclaration", "[", "]", "types", "=", "parsedUnit", ".", "types", ";", "length", "=", "(", "currentPackage", "==", "null", "?", "0", ":", "1", ")", "+", "(", "imports", "==", "null", "?", "0", ":", "imports", ".", "length", ")", "+", "(", "types", "==", "null", "?", "0", ":", "types", ".", "length", ")", ";", "nodes", "=", "new", "ASTNode", "[", "length", "]", ";", "int", "index", "=", "0", ";", "if", "(", "currentPackage", "!=", "null", ")", "{", "nodes", "[", "index", "++", "]", "=", "currentPackage", ";", "}", "if", "(", "imports", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "imports", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "nodes", "[", "index", "++", "]", "=", "imports", "[", "i", "]", ";", "}", "}", "if", "(", "types", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "types", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "nodes", "[", "index", "++", "]", "=", "types", "[", "i", "]", ";", "}", "}", "if", "(", "length", ">", "0", ")", "{", "quickSort", "(", "nodes", ",", "0", ",", "length", "-", "1", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "ASTNode", "node", "=", "nodes", "[", "i", "]", ";", "if", "(", "node", "instanceof", "ImportReference", ")", "{", "ImportReference", "importRef", "=", "(", "ImportReference", ")", "node", ";", "if", "(", "node", "==", "parsedUnit", ".", "currentPackage", ")", "{", "notifySourceElementRequestor", "(", "importRef", ",", "true", ")", ";", "}", "else", "{", "notifySourceElementRequestor", "(", "importRef", ",", "false", ")", ";", "}", "}", "else", "{", "notifySourceElementRequestor", "(", "(", "TypeDeclaration", ")", "node", ",", "true", ",", "null", ",", "currentPackage", ")", ";", "}", "}", "}", "if", "(", "isInRange", ")", "{", "this", ".", "requestor", ".", "exitCompilationUnit", "(", "parsedUnit", ".", "sourceEnd", ")", ";", "}", "}", "finally", "{", "reset", "(", ")", ";", "}", "}", "protected", "void", "notifySourceElementRequestor", "(", "FieldDeclaration", "fieldDeclaration", ",", "TypeDeclaration", "declaringType", ")", "{", "boolean", "isInRange", "=", "this", ".", "initialPosition", "<=", "fieldDeclaration", ".", "declarationSourceStart", "&&", "this", ".", "eofPosition", ">=", "fieldDeclaration", ".", "declarationSourceEnd", ";", "switch", "(", "fieldDeclaration", ".", "getKind", "(", ")", ")", "{", "case", "AbstractVariableDeclaration", ".", "ENUM_CONSTANT", ":", "if", "(", "this", ".", "reportReferenceInfo", ")", "{", "if", "(", "fieldDeclaration", ".", "initialization", "instanceof", "AllocationExpression", ")", "{", "AllocationExpression", "alloc", "=", "(", "AllocationExpression", ")", "fieldDeclaration", ".", "initialization", ";", "this", ".", "requestor", ".", "acceptConstructorReference", "(", "declaringType", ".", "name", ",", "alloc", ".", "arguments", "==", "null", "?", "0", ":", "alloc", ".", "arguments", ".", "length", ",", "alloc", ".", "sourceStart", ")", ";", "}", "}", "case", "AbstractVariableDeclaration", ".", "FIELD", ":", "int", "fieldEndPosition", "=", "this", ".", "sourceEnds", ".", "get", "(", "fieldDeclaration", ")", ";", "if", "(", "fieldEndPosition", "==", "-", "1", ")", "{", "fieldEndPosition", "=", "fieldDeclaration", ".", "declarationSourceEnd", ";", "}", "if", "(", "isInRange", ")", "{", "int", "currentModifiers", "=", "fieldDeclaration", ".", "modifiers", ";", "boolean", "deprecated", "=", "(", "currentModifiers", "&", "ClassFileConstants", ".", "AccDeprecated", ")", "!=", "0", "||", "hasDeprecatedAnnotation", "(", "fieldDeclaration", ".", "annotations", ")", ";", "char", "[", "]", "typeName", "=", "null", ";", "if", "(", "fieldDeclaration", ".", "type", "==", "null", ")", "{", "typeName", "=", "declaringType", ".", "name", ";", "currentModifiers", "|=", "ClassFileConstants", ".", "AccEnum", ";", "}", "else", "{", "typeName", "=", "CharOperation", ".", "concatWith", "(", "fieldDeclaration", ".", "type", ".", "getParameterizedTypeName", "(", ")", ",", "'.'", ")", ";", "}", "ISourceElementRequestor", ".", "FieldInfo", "fieldInfo", "=", "new", "ISourceElementRequestor", ".", "FieldInfo", "(", ")", ";", "fieldInfo", ".", "declarationStart", "=", "fieldDeclaration", ".", "declarationSourceStart", ";", "fieldInfo", ".", "name", "=", "fieldDeclaration", ".", "name", ";", "fieldInfo", ".", "modifiers", "=", "deprecated", "?", "(", "currentModifiers", "&", "ExtraCompilerModifiers", ".", "AccJustFlag", ")", "|", "ClassFileConstants", ".", "AccDeprecated", ":", "currentModifiers", "&", "ExtraCompilerModifiers", ".", "AccJustFlag", ";", "fieldInfo", ".", "type", "=", "typeName", ";", "fieldInfo", ".", "nameSourceStart", "=", "fieldDeclaration", ".", "sourceStart", ";", "fieldInfo", ".", "nameSourceEnd", "=", "fieldDeclaration", ".", "sourceEnd", ";", "fieldInfo", ".", "categories", "=", "(", "char", "[", "]", "[", "]", ")", "this", ".", "nodesToCategories", ".", "get", "(", "fieldDeclaration", ")", ";", "fieldInfo", ".", "annotations", "=", "fieldDeclaration", ".", "annotations", ";", "fieldInfo", ".", "node", "=", "fieldDeclaration", ";", "this", ".", "requestor", ".", "enterField", "(", "fieldInfo", ")", ";", "}", "this", ".", "visitIfNeeded", "(", "fieldDeclaration", ",", "declaringType", ")", ";", "if", "(", "isInRange", ")", "{", "this", ".", "requestor", ".", "exitField", "(", "(", "fieldDeclaration", ".", "initialization", "==", "null", "||", "fieldDeclaration", ".", "initialization", "instanceof", "ArrayInitializer", "||", "fieldDeclaration", ".", "initialization", "instanceof", "AllocationExpression", "||", "fieldDeclaration", ".", "initialization", "instanceof", "ArrayAllocationExpression", "||", "fieldDeclaration", ".", "initialization", "instanceof", "Assignment", "||", "fieldDeclaration", ".", "initialization", "instanceof", "ClassLiteralAccess", "||", "fieldDeclaration", ".", "initialization", "instanceof", "MessageSend", "||", "fieldDeclaration", ".", "initialization", "instanceof", "ArrayReference", "||", "fieldDeclaration", ".", "initialization", "instanceof", "ThisReference", ")", "?", "-", "1", ":", "fieldDeclaration", ".", "initialization", ".", "sourceStart", ",", "fieldEndPosition", ",", "fieldDeclaration", ".", "declarationSourceEnd", ")", ";", "}", "break", ";", "case", "AbstractVariableDeclaration", ".", "INITIALIZER", ":", "if", "(", "isInRange", ")", "{", "this", ".", "requestor", ".", "enterInitializer", "(", "fieldDeclaration", ".", "declarationSourceStart", ",", "fieldDeclaration", ".", "modifiers", ")", ";", "}", "this", ".", "visitIfNeeded", "(", "(", "Initializer", ")", "fieldDeclaration", ")", ";", "if", "(", "isInRange", ")", "{", "this", ".", "requestor", ".", "exitInitializer", "(", "fieldDeclaration", ".", "declarationSourceEnd", ")", ";", "}", "break", ";", "}", "}", "protected", "void", "notifySourceElementRequestor", "(", "ImportReference", "importReference", ",", "boolean", "isPackage", ")", "{", "if", "(", "isPackage", ")", "{", "this", ".", "requestor", ".", "acceptPackage", "(", "importReference", ")", ";", "}", "else", "{", "this", ".", "requestor", ".", "acceptImport", "(", "importReference", ".", "declarationSourceStart", ",", "importReference", ".", "declarationSourceEnd", ",", "importReference", ".", "tokens", ",", "(", "importReference", ".", "bits", "&", "ASTNode", ".", "OnDemand", ")", "!=", "0", ",", "importReference", ".", "modifiers", ")", ";", "}", "}", "protected", "void", "notifySourceElementRequestor", "(", "TypeDeclaration", "typeDeclaration", ",", "boolean", "notifyTypePresence", ",", "TypeDeclaration", "declaringType", ",", "ImportReference", "currentPackage", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "TypeConstants", ".", "PACKAGE_INFO_NAME", ",", "typeDeclaration", ".", "name", ")", ")", "return", ";", "boolean", "isInRange", "=", "this", ".", "initialPosition", "<=", "typeDeclaration", ".", "declarationSourceStart", "&&", "this", ".", "eofPosition", ">=", "typeDeclaration", ".", "declarationSourceEnd", ";", "FieldDeclaration", "[", "]", "fields", "=", "typeDeclaration", ".", "fields", ";", "AbstractMethodDeclaration", "[", "]", "methods", "=", "typeDeclaration", ".", "methods", ";", "TypeDeclaration", "[", "]", "memberTypes", "=", "typeDeclaration", ".", "memberTypes", ";", "int", "fieldCounter", "=", "fields", "==", "null", "?", "0", ":", "fields", ".", "length", ";", "int", "methodCounter", "=", "methods", "==", "null", "?", "0", ":", "methods", ".", "length", ";", "int", "memberTypeCounter", "=", "memberTypes", "==", "null", "?", "0", ":", "memberTypes", ".", "length", ";", "int", "fieldIndex", "=", "0", ";", "int", "methodIndex", "=", "0", ";", "int", "memberTypeIndex", "=", "0", ";", "if", "(", "notifyTypePresence", ")", "{", "char", "[", "]", "[", "]", "interfaceNames", "=", "getInterfaceNames", "(", "typeDeclaration", ")", ";", "int", "kind", "=", "TypeDeclaration", ".", "kind", "(", "typeDeclaration", ".", "modifiers", ")", ";", "char", "[", "]", "implicitSuperclassName", "=", "TypeConstants", ".", "CharArray_JAVA_LANG_OBJECT", ";", "if", "(", "isInRange", ")", "{", "int", "currentModifiers", "=", "typeDeclaration", ".", "modifiers", ";", "boolean", "deprecated", "=", "(", "currentModifiers", "&", "ClassFileConstants", ".", "AccDeprecated", ")", "!=", "0", "||", "hasDeprecatedAnnotation", "(", "typeDeclaration", ".", "annotations", ")", ";", "boolean", "isEnumInit", "=", "typeDeclaration", ".", "allocation", "!=", "null", "&&", "typeDeclaration", ".", "allocation", ".", "enumConstant", "!=", "null", ";", "char", "[", "]", "superclassName", ";", "if", "(", "isEnumInit", ")", "{", "currentModifiers", "|=", "ClassFileConstants", ".", "AccEnum", ";", "superclassName", "=", "declaringType", ".", "name", ";", "}", "else", "{", "superclassName", "=", "getSuperclassName", "(", "typeDeclaration", ")", ";", "}", "ISourceElementRequestor", ".", "TypeInfo", "typeInfo", "=", "new", "ISourceElementRequestor", ".", "TypeInfo", "(", ")", ";", "if", "(", "typeDeclaration", ".", "allocation", "==", "null", ")", "{", "typeInfo", ".", "declarationStart", "=", "typeDeclaration", ".", "declarationSourceStart", ";", "}", "else", "if", "(", "isEnumInit", ")", "{", "typeInfo", ".", "declarationStart", "=", "typeDeclaration", ".", "allocation", ".", "enumConstant", ".", "sourceStart", ";", "}", "else", "{", "typeInfo", ".", "declarationStart", "=", "typeDeclaration", ".", "allocation", ".", "sourceStart", ";", "}", "typeInfo", ".", "modifiers", "=", "deprecated", "?", "(", "currentModifiers", "&", "ExtraCompilerModifiers", ".", "AccJustFlag", ")", "|", "ClassFileConstants", ".", "AccDeprecated", ":", "currentModifiers", "&", "ExtraCompilerModifiers", ".", "AccJustFlag", ";", "typeInfo", ".", "name", "=", "typeDeclaration", ".", "name", ";", "typeInfo", ".", "nameSourceStart", "=", "isEnumInit", "?", "typeDeclaration", ".", "allocation", ".", "enumConstant", ".", "sourceStart", ":", "typeDeclaration", ".", "sourceStart", ";", "typeInfo", ".", "nameSourceEnd", "=", "sourceEnd", "(", "typeDeclaration", ")", ";", "typeInfo", ".", "superclass", "=", "superclassName", ";", "typeInfo", ".", "superinterfaces", "=", "interfaceNames", ";", "typeInfo", ".", "typeParameters", "=", "getTypeParameterInfos", "(", "typeDeclaration", ".", "typeParameters", ")", ";", "typeInfo", ".", "categories", "=", "(", "char", "[", "]", "[", "]", ")", "this", ".", "nodesToCategories", ".", "get", "(", "typeDeclaration", ")", ";", "typeInfo", ".", "secondary", "=", "typeDeclaration", ".", "isSecondary", "(", ")", ";", "typeInfo", ".", "anonymousMember", "=", "typeDeclaration", ".", "allocation", "!=", "null", "&&", "typeDeclaration", ".", "allocation", ".", "enclosingInstance", "!=", "null", ";", "typeInfo", ".", "annotations", "=", "typeDeclaration", ".", "annotations", ";", "typeInfo", ".", "extraFlags", "=", "ExtraFlags", ".", "getExtraFlags", "(", "typeDeclaration", ")", ";", "typeInfo", ".", "node", "=", "typeDeclaration", ";", "this", ".", "requestor", ".", "enterType", "(", "typeInfo", ")", ";", "switch", "(", "kind", ")", "{", "case", "TypeDeclaration", ".", "CLASS_DECL", ":", "if", "(", "superclassName", "!=", "null", ")", "implicitSuperclassName", "=", "superclassName", ";", "break", ";", "case", "TypeDeclaration", ".", "INTERFACE_DECL", ":", "implicitSuperclassName", "=", "TypeConstants", ".", "CharArray_JAVA_LANG_OBJECT", ";", "break", ";", "case", "TypeDeclaration", ".", "ENUM_DECL", ":", "implicitSuperclassName", "=", "TypeConstants", ".", "CharArray_JAVA_LANG_ENUM", ";", "break", ";", "case", "TypeDeclaration", ".", "ANNOTATION_TYPE_DECL", ":", "implicitSuperclassName", "=", "TypeConstants", ".", "CharArray_JAVA_LANG_ANNOTATION_ANNOTATION", ";", "break", ";", "}", "}", "if", "(", "this", ".", "nestedTypeIndex", "==", "this", ".", "typeNames", ".", "length", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "typeNames", ",", "0", ",", "(", "this", ".", "typeNames", "=", "new", "char", "[", "this", ".", "nestedTypeIndex", "*", "2", "]", "[", "]", ")", ",", "0", ",", "this", ".", "nestedTypeIndex", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "superTypeNames", ",", "0", ",", "(", "this", ".", "superTypeNames", "=", "new", "char", "[", "this", ".", "nestedTypeIndex", "*", "2", "]", "[", "]", ")", ",", "0", ",", "this", ".", "nestedTypeIndex", ")", ";", "}", "this", ".", "typeNames", "[", "this", ".", "nestedTypeIndex", "]", "=", "typeDeclaration", ".", "name", ";", "this", ".", "superTypeNames", "[", "this", ".", "nestedTypeIndex", "++", "]", "=", "implicitSuperclassName", ";", "}", "while", "(", "(", "fieldIndex", "<", "fieldCounter", ")", "||", "(", "memberTypeIndex", "<", "memberTypeCounter", ")", "||", "(", "methodIndex", "<", "methodCounter", ")", ")", "{", "FieldDeclaration", "nextFieldDeclaration", "=", "null", ";", "AbstractMethodDeclaration", "nextMethodDeclaration", "=", "null", ";", "TypeDeclaration", "nextMemberDeclaration", "=", "null", ";", "int", "position", "=", "Integer", ".", "MAX_VALUE", ";", "int", "nextDeclarationType", "=", "-", "1", ";", "if", "(", "fieldIndex", "<", "fieldCounter", ")", "{", "nextFieldDeclaration", "=", "fields", "[", "fieldIndex", "]", ";", "if", "(", "nextFieldDeclaration", ".", "declarationSourceStart", "<", "position", ")", "{", "position", "=", "nextFieldDeclaration", ".", "declarationSourceStart", ";", "nextDeclarationType", "=", "0", ";", "}", "}", "if", "(", "methodIndex", "<", "methodCounter", ")", "{", "nextMethodDeclaration", "=", "methods", "[", "methodIndex", "]", ";", "if", "(", "nextMethodDeclaration", ".", "declarationSourceStart", "<", "position", ")", "{", "position", "=", "nextMethodDeclaration", ".", "declarationSourceStart", ";", "nextDeclarationType", "=", "1", ";", "}", "}", "if", "(", "memberTypeIndex", "<", "memberTypeCounter", ")", "{", "nextMemberDeclaration", "=", "memberTypes", "[", "memberTypeIndex", "]", ";", "if", "(", "nextMemberDeclaration", ".", "declarationSourceStart", "<", "position", ")", "{", "position", "=", "nextMemberDeclaration", ".", "declarationSourceStart", ";", "nextDeclarationType", "=", "2", ";", "}", "}", "switch", "(", "nextDeclarationType", ")", "{", "case", "0", ":", "fieldIndex", "++", ";", "notifySourceElementRequestor", "(", "nextFieldDeclaration", ",", "typeDeclaration", ")", ";", "break", ";", "case", "1", ":", "methodIndex", "++", ";", "notifySourceElementRequestor", "(", "nextMethodDeclaration", ",", "typeDeclaration", ",", "currentPackage", ")", ";", "break", ";", "case", "2", ":", "memberTypeIndex", "++", ";", "notifySourceElementRequestor", "(", "nextMemberDeclaration", ",", "true", ",", "null", ",", "currentPackage", ")", ";", "}", "}", "if", "(", "notifyTypePresence", ")", "{", "if", "(", "isInRange", ")", "{", "this", ".", "requestor", ".", "exitType", "(", "typeDeclaration", ".", "declarationSourceEnd", ")", ";", "}", "this", ".", "nestedTypeIndex", "--", ";", "}", "}", "private", "static", "void", "quickSort", "(", "ASTNode", "[", "]", "sortedCollection", ",", "int", "left", ",", "int", "right", ")", "{", "int", "original_left", "=", "left", ";", "int", "original_right", "=", "right", ";", "ASTNode", "mid", "=", "sortedCollection", "[", "left", "+", "(", "right", "-", "left", ")", "/", "2", "]", ";", "do", "{", "while", "(", "sortedCollection", "[", "left", "]", ".", "sourceStart", "<", "mid", ".", "sourceStart", ")", "{", "left", "++", ";", "}", "while", "(", "mid", ".", "sourceStart", "<", "sortedCollection", "[", "right", "]", ".", "sourceStart", ")", "{", "right", "--", ";", "}", "if", "(", "left", "<=", "right", ")", "{", "ASTNode", "tmp", "=", "sortedCollection", "[", "left", "]", ";", "sortedCollection", "[", "left", "]", "=", "sortedCollection", "[", "right", "]", ";", "sortedCollection", "[", "right", "]", "=", "tmp", ";", "left", "++", ";", "right", "--", ";", "}", "}", "while", "(", "left", "<=", "right", ")", ";", "if", "(", "original_left", "<", "right", ")", "{", "quickSort", "(", "sortedCollection", ",", "original_left", ",", "right", ")", ";", "}", "if", "(", "left", "<", "original_right", ")", "{", "quickSort", "(", "sortedCollection", ",", "left", ",", "original_right", ")", ";", "}", "}", "private", "void", "reset", "(", ")", "{", "this", ".", "typeNames", "=", "new", "char", "[", "4", "]", "[", "]", ";", "this", ".", "superTypeNames", "=", "new", "char", "[", "4", "]", "[", "]", ";", "this", ".", "nestedTypeIndex", "=", "0", ";", "this", ".", "sourceEnds", "=", "null", ";", "}", "private", "int", "sourceEnd", "(", "TypeDeclaration", "typeDeclaration", ")", "{", "if", "(", "(", "typeDeclaration", ".", "bits", "&", "ASTNode", ".", "IsAnonymousType", ")", "!=", "0", ")", "{", "QualifiedAllocationExpression", "allocation", "=", "typeDeclaration", ".", "allocation", ";", "if", "(", "allocation", ".", "enumConstant", "!=", "null", ")", "return", "allocation", ".", "enumConstant", ".", "sourceEnd", ";", "return", "allocation", ".", "type", ".", "sourceEnd", ";", "}", "else", "{", "return", "typeDeclaration", ".", "sourceEnd", ";", "}", "}", "private", "void", "visitIfNeeded", "(", "AbstractMethodDeclaration", "method", ")", "{", "if", "(", "this", ".", "localDeclarationVisitor", "!=", "null", "&&", "(", "method", ".", "bits", "&", "ASTNode", ".", "HasLocalType", ")", "!=", "0", ")", "{", "if", "(", "method", "instanceof", "ConstructorDeclaration", ")", "{", "ConstructorDeclaration", "constructorDeclaration", "=", "(", "ConstructorDeclaration", ")", "method", ";", "if", "(", "constructorDeclaration", ".", "constructorCall", "!=", "null", ")", "{", "constructorDeclaration", ".", "constructorCall", ".", "traverse", "(", "this", ".", "localDeclarationVisitor", ",", "method", ".", "scope", ")", ";", "}", "}", "if", "(", "method", ".", "statements", "!=", "null", ")", "{", "int", "statementsLength", "=", "method", ".", "statements", ".", "length", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "statementsLength", ";", "i", "++", ")", "method", ".", "statements", "[", "i", "]", ".", "traverse", "(", "this", ".", "localDeclarationVisitor", ",", "method", ".", "scope", ")", ";", "}", "}", "}", "private", "void", "visitIfNeeded", "(", "FieldDeclaration", "field", ",", "TypeDeclaration", "declaringType", ")", "{", "if", "(", "this", ".", "localDeclarationVisitor", "!=", "null", "&&", "(", "field", ".", "bits", "&", "ASTNode", ".", "HasLocalType", ")", "!=", "0", ")", "{", "if", "(", "field", ".", "initialization", "!=", "null", ")", "{", "try", "{", "this", ".", "localDeclarationVisitor", ".", "pushDeclaringType", "(", "declaringType", ")", ";", "field", ".", "initialization", ".", "traverse", "(", "this", ".", "localDeclarationVisitor", ",", "(", "MethodScope", ")", "null", ")", ";", "}", "finally", "{", "this", ".", "localDeclarationVisitor", ".", "popDeclaringType", "(", ")", ";", "}", "}", "}", "}", "private", "void", "visitIfNeeded", "(", "Initializer", "initializer", ")", "{", "if", "(", "this", ".", "localDeclarationVisitor", "!=", "null", "&&", "(", "initializer", ".", "bits", "&", "ASTNode", ".", "HasLocalType", ")", "!=", "0", ")", "{", "if", "(", "initializer", ".", "block", "!=", "null", ")", "{", "initializer", ".", "block", ".", "traverse", "(", "this", ".", "localDeclarationVisitor", ",", "null", ")", ";", "}", "}", "}", "}", "</s>" ]
5,544
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "parser", ".", "ScannerHelper", ";", "public", "final", "class", "CharOperation", "{", "public", "static", "final", "char", "[", "]", "NO_CHAR", "=", "new", "char", "[", "0", "]", ";", "public", "static", "final", "char", "[", "]", "[", "]", "NO_CHAR_CHAR", "=", "new", "char", "[", "0", "]", "[", "]", ";", "public", "static", "final", "String", "[", "]", "NO_STRINGS", "=", "new", "String", "[", "0", "]", ";", "public", "static", "final", "char", "[", "]", "append", "(", "char", "[", "]", "array", ",", "char", "suffix", ")", "{", "if", "(", "array", "==", "null", ")", "return", "new", "char", "[", "]", "{", "suffix", "}", ";", "int", "length", "=", "array", ".", "length", ";", "System", ".", "arraycopy", "(", "array", ",", "0", ",", "array", "=", "new", "char", "[", "length", "+", "1", "]", ",", "0", ",", "length", ")", ";", "array", "[", "length", "]", "=", "suffix", ";", "return", "array", ";", "}", "public", "static", "final", "char", "[", "]", "append", "(", "char", "[", "]", "target", ",", "int", "index", ",", "char", "[", "]", "array", ",", "int", "start", ",", "int", "end", ")", "{", "int", "targetLength", "=", "target", ".", "length", ";", "int", "subLength", "=", "end", "-", "start", ";", "int", "newTargetLength", "=", "subLength", "+", "index", ";", "if", "(", "newTargetLength", ">", "targetLength", ")", "{", "System", ".", "arraycopy", "(", "target", ",", "0", ",", "target", "=", "new", "char", "[", "newTargetLength", "*", "2", "]", ",", "0", ",", "index", ")", ";", "}", "System", ".", "arraycopy", "(", "array", ",", "start", ",", "target", ",", "index", ",", "subLength", ")", ";", "return", "target", ";", "}", "public", "static", "final", "char", "[", "]", "[", "]", "arrayConcat", "(", "char", "[", "]", "[", "]", "first", ",", "char", "[", "]", "[", "]", "second", ")", "{", "if", "(", "first", "==", "null", ")", "return", "second", ";", "if", "(", "second", "==", "null", ")", "return", "first", ";", "int", "length1", "=", "first", ".", "length", ";", "int", "length2", "=", "second", ".", "length", ";", "char", "[", "]", "[", "]", "result", "=", "new", "char", "[", "length1", "+", "length2", "]", "[", "]", ";", "System", ".", "arraycopy", "(", "first", ",", "0", ",", "result", ",", "0", ",", "length1", ")", ";", "System", ".", "arraycopy", "(", "second", ",", "0", ",", "result", ",", "length1", ",", "length2", ")", ";", "return", "result", ";", "}", "public", "static", "final", "boolean", "camelCaseMatch", "(", "char", "[", "]", "pattern", ",", "char", "[", "]", "name", ")", "{", "if", "(", "pattern", "==", "null", ")", "return", "true", ";", "if", "(", "name", "==", "null", ")", "return", "false", ";", "return", "camelCaseMatch", "(", "pattern", ",", "0", ",", "pattern", ".", "length", ",", "name", ",", "0", ",", "name", ".", "length", ",", "false", ")", ";", "}", "public", "static", "final", "boolean", "camelCaseMatch", "(", "char", "[", "]", "pattern", ",", "char", "[", "]", "name", ",", "boolean", "samePartCount", ")", "{", "if", "(", "pattern", "==", "null", ")", "return", "true", ";", "if", "(", "name", "==", "null", ")", "return", "false", ";", "return", "camelCaseMatch", "(", "pattern", ",", "0", ",", "pattern", ".", "length", ",", "name", ",", "0", ",", "name", ".", "length", ",", "samePartCount", ")", ";", "}", "public", "static", "final", "boolean", "camelCaseMatch", "(", "char", "[", "]", "pattern", ",", "int", "patternStart", ",", "int", "patternEnd", ",", "char", "[", "]", "name", ",", "int", "nameStart", ",", "int", "nameEnd", ")", "{", "return", "camelCaseMatch", "(", "pattern", ",", "patternStart", ",", "patternEnd", ",", "name", ",", "nameStart", ",", "nameEnd", ",", "false", ")", ";", "}", "public", "static", "final", "boolean", "camelCaseMatch", "(", "char", "[", "]", "pattern", ",", "int", "patternStart", ",", "int", "patternEnd", ",", "char", "[", "]", "name", ",", "int", "nameStart", ",", "int", "nameEnd", ",", "boolean", "samePartCount", ")", "{", "if", "(", "name", "==", "null", ")", "return", "false", ";", "if", "(", "pattern", "==", "null", ")", "return", "true", ";", "if", "(", "patternEnd", "<", "0", ")", "patternEnd", "=", "pattern", ".", "length", ";", "if", "(", "nameEnd", "<", "0", ")", "nameEnd", "=", "name", ".", "length", ";", "if", "(", "patternEnd", "<=", "patternStart", ")", "return", "nameEnd", "<=", "nameStart", ";", "if", "(", "nameEnd", "<=", "nameStart", ")", "return", "false", ";", "if", "(", "name", "[", "nameStart", "]", "!=", "pattern", "[", "patternStart", "]", ")", "{", "return", "false", ";", "}", "char", "patternChar", ",", "nameChar", ";", "int", "iPattern", "=", "patternStart", ";", "int", "iName", "=", "nameStart", ";", "while", "(", "true", ")", "{", "iPattern", "++", ";", "iName", "++", ";", "if", "(", "iPattern", "==", "patternEnd", ")", "{", "if", "(", "!", "samePartCount", "||", "iName", "==", "nameEnd", ")", "return", "true", ";", "while", "(", "true", ")", "{", "if", "(", "iName", "==", "nameEnd", ")", "{", "return", "true", ";", "}", "nameChar", "=", "name", "[", "iName", "]", ";", "if", "(", "nameChar", "<", "ScannerHelper", ".", "MAX_OBVIOUS", ")", "{", "if", "(", "(", "ScannerHelper", ".", "OBVIOUS_IDENT_CHAR_NATURES", "[", "nameChar", "]", "&", "ScannerHelper", ".", "C_UPPER_LETTER", ")", "!=", "0", ")", "{", "return", "false", ";", "}", "}", "else", "if", "(", "!", "Character", ".", "isJavaIdentifierPart", "(", "nameChar", ")", "||", "Character", ".", "isUpperCase", "(", "nameChar", ")", ")", "{", "return", "false", ";", "}", "iName", "++", ";", "}", "}", "if", "(", "iName", "==", "nameEnd", ")", "{", "return", "false", ";", "}", "if", "(", "(", "patternChar", "=", "pattern", "[", "iPattern", "]", ")", "==", "name", "[", "iName", "]", ")", "{", "continue", ";", "}", "if", "(", "patternChar", "<", "ScannerHelper", ".", "MAX_OBVIOUS", ")", "{", "if", "(", "(", "ScannerHelper", ".", "OBVIOUS_IDENT_CHAR_NATURES", "[", "patternChar", "]", "&", "(", "ScannerHelper", ".", "C_UPPER_LETTER", "|", "ScannerHelper", ".", "C_DIGIT", ")", ")", "==", "0", ")", "{", "return", "false", ";", "}", "}", "else", "if", "(", "Character", ".", "isJavaIdentifierPart", "(", "patternChar", ")", "&&", "!", "Character", ".", "isUpperCase", "(", "patternChar", ")", "&&", "!", "Character", ".", "isDigit", "(", "patternChar", ")", ")", "{", "return", "false", ";", "}", "while", "(", "true", ")", "{", "if", "(", "iName", "==", "nameEnd", ")", "{", "return", "false", ";", "}", "nameChar", "=", "name", "[", "iName", "]", ";", "if", "(", "nameChar", "<", "ScannerHelper", ".", "MAX_OBVIOUS", ")", "{", "int", "charNature", "=", "ScannerHelper", ".", "OBVIOUS_IDENT_CHAR_NATURES", "[", "nameChar", "]", ";", "if", "(", "(", "charNature", "&", "(", "ScannerHelper", ".", "C_LOWER_LETTER", "|", "ScannerHelper", ".", "C_SPECIAL", ")", ")", "!=", "0", ")", "{", "iName", "++", ";", "}", "else", "if", "(", "(", "charNature", "&", "ScannerHelper", ".", "C_DIGIT", ")", "!=", "0", ")", "{", "if", "(", "patternChar", "==", "nameChar", ")", "break", ";", "iName", "++", ";", "}", "else", "if", "(", "patternChar", "!=", "nameChar", ")", "{", "return", "false", ";", "}", "else", "{", "break", ";", "}", "}", "else", "if", "(", "Character", ".", "isJavaIdentifierPart", "(", "nameChar", ")", "&&", "!", "Character", ".", "isUpperCase", "(", "nameChar", ")", ")", "{", "iName", "++", ";", "}", "else", "if", "(", "Character", ".", "isDigit", "(", "nameChar", ")", ")", "{", "if", "(", "patternChar", "==", "nameChar", ")", "break", ";", "iName", "++", ";", "}", "else", "if", "(", "patternChar", "!=", "nameChar", ")", "{", "return", "false", ";", "}", "else", "{", "break", ";", "}", "}", "}", "}", "public", "static", "String", "[", "]", "charArrayToStringArray", "(", "char", "[", "]", "[", "]", "charArrays", ")", "{", "if", "(", "charArrays", "==", "null", ")", "return", "null", ";", "int", "length", "=", "charArrays", ".", "length", ";", "if", "(", "length", "==", "0", ")", "return", "NO_STRINGS", ";", "String", "[", "]", "strings", "=", "new", "String", "[", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "strings", "[", "i", "]", "=", "new", "String", "(", "charArrays", "[", "i", "]", ")", ";", "return", "strings", ";", "}", "public", "static", "String", "charToString", "(", "char", "[", "]", "charArray", ")", "{", "if", "(", "charArray", "==", "null", ")", "return", "null", ";", "return", "new", "String", "(", "charArray", ")", ";", "}", "public", "static", "final", "char", "[", "]", "[", "]", "arrayConcat", "(", "char", "[", "]", "[", "]", "first", ",", "char", "[", "]", "second", ")", "{", "if", "(", "second", "==", "null", ")", "return", "first", ";", "if", "(", "first", "==", "null", ")", "return", "new", "char", "[", "]", "[", "]", "{", "second", "}", ";", "int", "length", "=", "first", ".", "length", ";", "char", "[", "]", "[", "]", "result", "=", "new", "char", "[", "length", "+", "1", "]", "[", "]", ";", "System", ".", "arraycopy", "(", "first", ",", "0", ",", "result", ",", "0", ",", "length", ")", ";", "result", "[", "length", "]", "=", "second", ";", "return", "result", ";", "}", "public", "static", "final", "int", "compareTo", "(", "char", "[", "]", "array1", ",", "char", "[", "]", "array2", ")", "{", "int", "length1", "=", "array1", ".", "length", ";", "int", "length2", "=", "array2", ".", "length", ";", "int", "min", "=", "Math", ".", "min", "(", "length1", ",", "length2", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "min", ";", "i", "++", ")", "{", "if", "(", "array1", "[", "i", "]", "!=", "array2", "[", "i", "]", ")", "{", "return", "array1", "[", "i", "]", "-", "array2", "[", "i", "]", ";", "}", "}", "return", "length1", "-", "length2", ";", "}", "public", "static", "final", "int", "compareWith", "(", "char", "[", "]", "array", ",", "char", "[", "]", "prefix", ")", "{", "int", "arrayLength", "=", "array", ".", "length", ";", "int", "prefixLength", "=", "prefix", ".", "length", ";", "int", "min", "=", "Math", ".", "min", "(", "arrayLength", ",", "prefixLength", ")", ";", "int", "i", "=", "0", ";", "while", "(", "min", "--", "!=", "0", ")", "{", "char", "c1", "=", "array", "[", "i", "]", ";", "char", "c2", "=", "prefix", "[", "i", "++", "]", ";", "if", "(", "c1", "!=", "c2", ")", "return", "c1", "-", "c2", ";", "}", "if", "(", "prefixLength", "==", "i", ")", "return", "0", ";", "return", "-", "1", ";", "}", "public", "static", "final", "char", "[", "]", "concat", "(", "char", "[", "]", "first", ",", "char", "[", "]", "second", ")", "{", "if", "(", "first", "==", "null", ")", "return", "second", ";", "if", "(", "second", "==", "null", ")", "return", "first", ";", "int", "length1", "=", "first", ".", "length", ";", "int", "length2", "=", "second", ".", "length", ";", "char", "[", "]", "result", "=", "new", "char", "[", "length1", "+", "length2", "]", ";", "System", ".", "arraycopy", "(", "first", ",", "0", ",", "result", ",", "0", ",", "length1", ")", ";", "System", ".", "arraycopy", "(", "second", ",", "0", ",", "result", ",", "length1", ",", "length2", ")", ";", "return", "result", ";", "}", "public", "static", "final", "char", "[", "]", "concat", "(", "char", "[", "]", "first", ",", "char", "[", "]", "second", ",", "char", "[", "]", "third", ")", "{", "if", "(", "first", "==", "null", ")", "return", "concat", "(", "second", ",", "third", ")", ";", "if", "(", "second", "==", "null", ")", "return", "concat", "(", "first", ",", "third", ")", ";", "if", "(", "third", "==", "null", ")", "return", "concat", "(", "first", ",", "second", ")", ";", "int", "length1", "=", "first", ".", "length", ";", "int", "length2", "=", "second", ".", "length", ";", "int", "length3", "=", "third", ".", "length", ";", "char", "[", "]", "result", "=", "new", "char", "[", "length1", "+", "length2", "+", "length3", "]", ";", "System", ".", "arraycopy", "(", "first", ",", "0", ",", "result", ",", "0", ",", "length1", ")", ";", "System", ".", "arraycopy", "(", "second", ",", "0", ",", "result", ",", "length1", ",", "length2", ")", ";", "System", ".", "arraycopy", "(", "third", ",", "0", ",", "result", ",", "length1", "+", "length2", ",", "length3", ")", ";", "return", "result", ";", "}", "public", "static", "final", "char", "[", "]", "concat", "(", "char", "[", "]", "first", ",", "char", "[", "]", "second", ",", "char", "separator", ")", "{", "if", "(", "first", "==", "null", ")", "return", "second", ";", "if", "(", "second", "==", "null", ")", "return", "first", ";", "int", "length1", "=", "first", ".", "length", ";", "if", "(", "length1", "==", "0", ")", "return", "second", ";", "int", "length2", "=", "second", ".", "length", ";", "if", "(", "length2", "==", "0", ")", "return", "first", ";", "char", "[", "]", "result", "=", "new", "char", "[", "length1", "+", "length2", "+", "1", "]", ";", "System", ".", "arraycopy", "(", "first", ",", "0", ",", "result", ",", "0", ",", "length1", ")", ";", "result", "[", "length1", "]", "=", "separator", ";", "System", ".", "arraycopy", "(", "second", ",", "0", ",", "result", ",", "length1", "+", "1", ",", "length2", ")", ";", "return", "result", ";", "}", "public", "static", "final", "char", "[", "]", "concat", "(", "char", "[", "]", "first", ",", "char", "sep1", ",", "char", "[", "]", "second", ",", "char", "sep2", ",", "char", "[", "]", "third", ")", "{", "if", "(", "first", "==", "null", ")", "return", "concat", "(", "second", ",", "third", ",", "sep2", ")", ";", "if", "(", "second", "==", "null", ")", "return", "concat", "(", "first", ",", "third", ",", "sep1", ")", ";", "if", "(", "third", "==", "null", ")", "return", "concat", "(", "first", ",", "second", ",", "sep1", ")", ";", "int", "length1", "=", "first", ".", "length", ";", "int", "length2", "=", "second", ".", "length", ";", "int", "length3", "=", "third", ".", "length", ";", "char", "[", "]", "result", "=", "new", "char", "[", "length1", "+", "length2", "+", "length3", "+", "2", "]", ";", "System", ".", "arraycopy", "(", "first", ",", "0", ",", "result", ",", "0", ",", "length1", ")", ";", "result", "[", "length1", "]", "=", "sep1", ";", "System", ".", "arraycopy", "(", "second", ",", "0", ",", "result", ",", "length1", "+", "1", ",", "length2", ")", ";", "result", "[", "length1", "+", "length2", "+", "1", "]", "=", "sep2", ";", "System", ".", "arraycopy", "(", "third", ",", "0", ",", "result", ",", "length1", "+", "length2", "+", "2", ",", "length3", ")", ";", "return", "result", ";", "}", "public", "static", "final", "char", "[", "]", "concat", "(", "char", "prefix", ",", "char", "[", "]", "array", ",", "char", "suffix", ")", "{", "if", "(", "array", "==", "null", ")", "return", "new", "char", "[", "]", "{", "prefix", ",", "suffix", "}", ";", "int", "length", "=", "array", ".", "length", ";", "char", "[", "]", "result", "=", "new", "char", "[", "length", "+", "2", "]", ";", "result", "[", "0", "]", "=", "prefix", ";", "System", ".", "arraycopy", "(", "array", ",", "0", ",", "result", ",", "1", ",", "length", ")", ";", "result", "[", "length", "+", "1", "]", "=", "suffix", ";", "return", "result", ";", "}", "public", "static", "final", "char", "[", "]", "concatWith", "(", "char", "[", "]", "name", ",", "char", "[", "]", "[", "]", "array", ",", "char", "separator", ")", "{", "int", "nameLength", "=", "name", "==", "null", "?", "0", ":", "name", ".", "length", ";", "if", "(", "nameLength", "==", "0", ")", "return", "concatWith", "(", "array", ",", "separator", ")", ";", "int", "length", "=", "array", "==", "null", "?", "0", ":", "array", ".", "length", ";", "if", "(", "length", "==", "0", ")", "return", "name", ";", "int", "size", "=", "nameLength", ";", "int", "index", "=", "length", ";", "while", "(", "--", "index", ">=", "0", ")", "if", "(", "array", "[", "index", "]", ".", "length", ">", "0", ")", "size", "+=", "array", "[", "index", "]", ".", "length", "+", "1", ";", "char", "[", "]", "result", "=", "new", "char", "[", "size", "]", ";", "index", "=", "size", ";", "for", "(", "int", "i", "=", "length", "-", "1", ";", "i", ">=", "0", ";", "i", "--", ")", "{", "int", "subLength", "=", "array", "[", "i", "]", ".", "length", ";", "if", "(", "subLength", ">", "0", ")", "{", "index", "-=", "subLength", ";", "System", ".", "arraycopy", "(", "array", "[", "i", "]", ",", "0", ",", "result", ",", "index", ",", "subLength", ")", ";", "result", "[", "--", "index", "]", "=", "separator", ";", "}", "}", "System", ".", "arraycopy", "(", "name", ",", "0", ",", "result", ",", "0", ",", "nameLength", ")", ";", "return", "result", ";", "}", "public", "static", "final", "char", "[", "]", "concatWith", "(", "char", "[", "]", "[", "]", "array", ",", "char", "[", "]", "name", ",", "char", "separator", ")", "{", "int", "nameLength", "=", "name", "==", "null", "?", "0", ":", "name", ".", "length", ";", "if", "(", "nameLength", "==", "0", ")", "return", "concatWith", "(", "array", ",", "separator", ")", ";", "int", "length", "=", "array", "==", "null", "?", "0", ":", "array", ".", "length", ";", "if", "(", "length", "==", "0", ")", "return", "name", ";", "int", "size", "=", "nameLength", ";", "int", "index", "=", "length", ";", "while", "(", "--", "index", ">=", "0", ")", "if", "(", "array", "[", "index", "]", ".", "length", ">", "0", ")", "size", "+=", "array", "[", "index", "]", ".", "length", "+", "1", ";", "char", "[", "]", "result", "=", "new", "char", "[", "size", "]", ";", "index", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "int", "subLength", "=", "array", "[", "i", "]", ".", "length", ";", "if", "(", "subLength", ">", "0", ")", "{", "System", ".", "arraycopy", "(", "array", "[", "i", "]", ",", "0", ",", "result", ",", "index", ",", "subLength", ")", ";", "index", "+=", "subLength", ";", "result", "[", "index", "++", "]", "=", "separator", ";", "}", "}", "System", ".", "arraycopy", "(", "name", ",", "0", ",", "result", ",", "index", ",", "nameLength", ")", ";", "return", "result", ";", "}", "public", "static", "final", "char", "[", "]", "concatWith", "(", "char", "[", "]", "[", "]", "array", ",", "char", "separator", ")", "{", "int", "length", "=", "array", "==", "null", "?", "0", ":", "array", ".", "length", ";", "if", "(", "length", "==", "0", ")", "return", "CharOperation", ".", "NO_CHAR", ";", "int", "size", "=", "length", "-", "1", ";", "int", "index", "=", "length", ";", "while", "(", "--", "index", ">=", "0", ")", "{", "if", "(", "array", "[", "index", "]", ".", "length", "==", "0", ")", "size", "--", ";", "else", "size", "+=", "array", "[", "index", "]", ".", "length", ";", "}", "if", "(", "size", "<=", "0", ")", "return", "CharOperation", ".", "NO_CHAR", ";", "char", "[", "]", "result", "=", "new", "char", "[", "size", "]", ";", "index", "=", "length", ";", "while", "(", "--", "index", ">=", "0", ")", "{", "length", "=", "array", "[", "index", "]", ".", "length", ";", "if", "(", "length", ">", "0", ")", "{", "System", ".", "arraycopy", "(", "array", "[", "index", "]", ",", "0", ",", "result", ",", "(", "size", "-=", "length", ")", ",", "length", ")", ";", "if", "(", "--", "size", ">=", "0", ")", "result", "[", "size", "]", "=", "separator", ";", "}", "}", "return", "result", ";", "}", "public", "static", "final", "boolean", "contains", "(", "char", "character", ",", "char", "[", "]", "[", "]", "array", ")", "{", "for", "(", "int", "i", "=", "array", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "{", "char", "[", "]", "subarray", "=", "array", "[", "i", "]", ";", "for", "(", "int", "j", "=", "subarray", ".", "length", ";", "--", "j", ">=", "0", ";", ")", "if", "(", "subarray", "[", "j", "]", "==", "character", ")", "return", "true", ";", "}", "return", "false", ";", "}", "public", "static", "final", "boolean", "contains", "(", "char", "character", ",", "char", "[", "]", "array", ")", "{", "for", "(", "int", "i", "=", "array", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "array", "[", "i", "]", "==", "character", ")", "return", "true", ";", "return", "false", ";", "}", "public", "static", "final", "boolean", "contains", "(", "char", "[", "]", "characters", ",", "char", "[", "]", "array", ")", "{", "for", "(", "int", "i", "=", "array", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "for", "(", "int", "j", "=", "characters", ".", "length", ";", "--", "j", ">=", "0", ";", ")", "if", "(", "array", "[", "i", "]", "==", "characters", "[", "j", "]", ")", "return", "true", ";", "return", "false", ";", "}", "public", "static", "final", "char", "[", "]", "[", "]", "deepCopy", "(", "char", "[", "]", "[", "]", "toCopy", ")", "{", "int", "toCopyLength", "=", "toCopy", ".", "length", ";", "char", "[", "]", "[", "]", "result", "=", "new", "char", "[", "toCopyLength", "]", "[", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "toCopyLength", ";", "i", "++", ")", "{", "char", "[", "]", "toElement", "=", "toCopy", "[", "i", "]", ";", "int", "toElementLength", "=", "toElement", ".", "length", ";", "char", "[", "]", "resultElement", "=", "new", "char", "[", "toElementLength", "]", ";", "System", ".", "arraycopy", "(", "toElement", ",", "0", ",", "resultElement", ",", "0", ",", "toElementLength", ")", ";", "result", "[", "i", "]", "=", "resultElement", ";", "}", "return", "result", ";", "}", "public", "static", "final", "boolean", "endsWith", "(", "char", "[", "]", "array", ",", "char", "[", "]", "toBeFound", ")", "{", "int", "i", "=", "toBeFound", ".", "length", ";", "int", "j", "=", "array", ".", "length", "-", "i", ";", "if", "(", "j", "<", "0", ")", "return", "false", ";", "while", "(", "--", "i", ">=", "0", ")", "if", "(", "toBeFound", "[", "i", "]", "!=", "array", "[", "i", "+", "j", "]", ")", "return", "false", ";", "return", "true", ";", "}", "public", "static", "final", "boolean", "equals", "(", "char", "[", "]", "[", "]", "first", ",", "char", "[", "]", "[", "]", "second", ")", "{", "if", "(", "first", "==", "second", ")", "return", "true", ";", "if", "(", "first", "==", "null", "||", "second", "==", "null", ")", "return", "false", ";", "if", "(", "first", ".", "length", "!=", "second", ".", "length", ")", "return", "false", ";", "for", "(", "int", "i", "=", "first", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "!", "equals", "(", "first", "[", "i", "]", ",", "second", "[", "i", "]", ")", ")", "return", "false", ";", "return", "true", ";", "}", "public", "static", "final", "boolean", "equals", "(", "char", "[", "]", "[", "]", "first", ",", "char", "[", "]", "[", "]", "second", ",", "boolean", "isCaseSensitive", ")", "{", "if", "(", "isCaseSensitive", ")", "{", "return", "equals", "(", "first", ",", "second", ")", ";", "}", "if", "(", "first", "==", "second", ")", "return", "true", ";", "if", "(", "first", "==", "null", "||", "second", "==", "null", ")", "return", "false", ";", "if", "(", "first", ".", "length", "!=", "second", ".", "length", ")", "return", "false", ";", "for", "(", "int", "i", "=", "first", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "!", "equals", "(", "first", "[", "i", "]", ",", "second", "[", "i", "]", ",", "false", ")", ")", "return", "false", ";", "return", "true", ";", "}", "public", "static", "final", "boolean", "equals", "(", "char", "[", "]", "first", ",", "char", "[", "]", "second", ")", "{", "if", "(", "first", "==", "second", ")", "return", "true", ";", "if", "(", "first", "==", "null", "||", "second", "==", "null", ")", "return", "false", ";", "if", "(", "first", ".", "length", "!=", "second", ".", "length", ")", "return", "false", ";", "for", "(", "int", "i", "=", "first", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "first", "[", "i", "]", "!=", "second", "[", "i", "]", ")", "return", "false", ";", "return", "true", ";", "}", "public", "static", "final", "boolean", "equals", "(", "char", "[", "]", "first", ",", "char", "[", "]", "second", ",", "int", "secondStart", ",", "int", "secondEnd", ")", "{", "return", "equals", "(", "first", ",", "second", ",", "secondStart", ",", "secondEnd", ",", "true", ")", ";", "}", "public", "static", "final", "boolean", "equals", "(", "char", "[", "]", "first", ",", "char", "[", "]", "second", ",", "int", "secondStart", ",", "int", "secondEnd", ",", "boolean", "isCaseSensitive", ")", "{", "if", "(", "first", "==", "second", ")", "return", "true", ";", "if", "(", "first", "==", "null", "||", "second", "==", "null", ")", "return", "false", ";", "if", "(", "first", ".", "length", "!=", "secondEnd", "-", "secondStart", ")", "return", "false", ";", "if", "(", "isCaseSensitive", ")", "{", "for", "(", "int", "i", "=", "first", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "first", "[", "i", "]", "!=", "second", "[", "i", "+", "secondStart", "]", ")", "return", "false", ";", "}", "else", "{", "for", "(", "int", "i", "=", "first", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "ScannerHelper", ".", "toLowerCase", "(", "first", "[", "i", "]", ")", "!=", "ScannerHelper", ".", "toLowerCase", "(", "second", "[", "i", "+", "secondStart", "]", ")", ")", "return", "false", ";", "}", "return", "true", ";", "}", "public", "static", "final", "boolean", "equals", "(", "char", "[", "]", "first", ",", "char", "[", "]", "second", ",", "boolean", "isCaseSensitive", ")", "{", "if", "(", "isCaseSensitive", ")", "{", "return", "equals", "(", "first", ",", "second", ")", ";", "}", "if", "(", "first", "==", "second", ")", "return", "true", ";", "if", "(", "first", "==", "null", "||", "second", "==", "null", ")", "return", "false", ";", "if", "(", "first", ".", "length", "!=", "second", ".", "length", ")", "return", "false", ";", "for", "(", "int", "i", "=", "first", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "ScannerHelper", ".", "toLowerCase", "(", "first", "[", "i", "]", ")", "!=", "ScannerHelper", ".", "toLowerCase", "(", "second", "[", "i", "]", ")", ")", "return", "false", ";", "return", "true", ";", "}", "public", "static", "final", "boolean", "fragmentEquals", "(", "char", "[", "]", "fragment", ",", "char", "[", "]", "name", ",", "int", "startIndex", ",", "boolean", "isCaseSensitive", ")", "{", "int", "max", "=", "fragment", ".", "length", ";", "if", "(", "name", ".", "length", "<", "max", "+", "startIndex", ")", "return", "false", ";", "if", "(", "isCaseSensitive", ")", "{", "for", "(", "int", "i", "=", "max", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "fragment", "[", "i", "]", "!=", "name", "[", "i", "+", "startIndex", "]", ")", "return", "false", ";", "return", "true", ";", "}", "for", "(", "int", "i", "=", "max", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "ScannerHelper", ".", "toLowerCase", "(", "fragment", "[", "i", "]", ")", "!=", "ScannerHelper", ".", "toLowerCase", "(", "name", "[", "i", "+", "startIndex", "]", ")", ")", "return", "false", ";", "return", "true", ";", "}", "public", "static", "final", "int", "hashCode", "(", "char", "[", "]", "array", ")", "{", "int", "length", "=", "array", ".", "length", ";", "int", "hash", "=", "length", "==", "0", "?", "31", ":", "array", "[", "0", "]", ";", "if", "(", "length", "<", "8", ")", "{", "for", "(", "int", "i", "=", "length", ";", "--", "i", ">", "0", ";", ")", "hash", "=", "(", "hash", "*", "31", ")", "+", "array", "[", "i", "]", ";", "}", "else", "{", "for", "(", "int", "i", "=", "length", "-", "1", ",", "last", "=", "i", ">", "16", "?", "i", "-", "16", ":", "0", ";", "i", ">", "last", ";", "i", "-=", "2", ")", "hash", "=", "(", "hash", "*", "31", ")", "+", "array", "[", "i", "]", ";", "}", "return", "hash", "&", "0x7FFFFFFF", ";", "}", "public", "static", "boolean", "isWhitespace", "(", "char", "c", ")", "{", "return", "c", "<", "ScannerHelper", ".", "MAX_OBVIOUS", "&&", "(", "(", "ScannerHelper", ".", "OBVIOUS_IDENT_CHAR_NATURES", "[", "c", "]", "&", "ScannerHelper", ".", "C_JLS_SPACE", ")", "!=", "0", ")", ";", "}", "public", "static", "final", "int", "indexOf", "(", "char", "toBeFound", ",", "char", "[", "]", "array", ")", "{", "return", "indexOf", "(", "toBeFound", ",", "array", ",", "0", ")", ";", "}", "public", "static", "final", "int", "indexOf", "(", "char", "[", "]", "toBeFound", ",", "char", "[", "]", "array", ",", "boolean", "isCaseSensitive", ")", "{", "return", "indexOf", "(", "toBeFound", ",", "array", ",", "isCaseSensitive", ",", "0", ")", ";", "}", "public", "static", "final", "int", "indexOf", "(", "final", "char", "[", "]", "toBeFound", ",", "final", "char", "[", "]", "array", ",", "final", "boolean", "isCaseSensitive", ",", "final", "int", "start", ")", "{", "return", "indexOf", "(", "toBeFound", ",", "array", ",", "isCaseSensitive", ",", "start", ",", "array", ".", "length", ")", ";", "}", "public", "static", "final", "int", "indexOf", "(", "final", "char", "[", "]", "toBeFound", ",", "final", "char", "[", "]", "array", ",", "final", "boolean", "isCaseSensitive", ",", "final", "int", "start", ",", "final", "int", "end", ")", "{", "final", "int", "arrayLength", "=", "end", ";", "final", "int", "toBeFoundLength", "=", "toBeFound", ".", "length", ";", "if", "(", "toBeFoundLength", ">", "arrayLength", "||", "start", "<", "0", ")", "return", "-", "1", ";", "if", "(", "toBeFoundLength", "==", "0", ")", "return", "0", ";", "if", "(", "toBeFoundLength", "==", "arrayLength", ")", "{", "if", "(", "isCaseSensitive", ")", "{", "for", "(", "int", "i", "=", "start", ";", "i", "<", "arrayLength", ";", "i", "++", ")", "{", "if", "(", "array", "[", "i", "]", "!=", "toBeFound", "[", "i", "]", ")", "return", "-", "1", ";", "}", "return", "0", ";", "}", "else", "{", "for", "(", "int", "i", "=", "start", ";", "i", "<", "arrayLength", ";", "i", "++", ")", "{", "if", "(", "ScannerHelper", ".", "toLowerCase", "(", "array", "[", "i", "]", ")", "!=", "ScannerHelper", ".", "toLowerCase", "(", "toBeFound", "[", "i", "]", ")", ")", "return", "-", "1", ";", "}", "return", "0", ";", "}", "}", "if", "(", "isCaseSensitive", ")", "{", "arrayLoop", ":", "for", "(", "int", "i", "=", "start", ",", "max", "=", "arrayLength", "-", "toBeFoundLength", "+", "1", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "array", "[", "i", "]", "==", "toBeFound", "[", "0", "]", ")", "{", "for", "(", "int", "j", "=", "1", ";", "j", "<", "toBeFoundLength", ";", "j", "++", ")", "{", "if", "(", "array", "[", "i", "+", "j", "]", "!=", "toBeFound", "[", "j", "]", ")", "continue", "arrayLoop", ";", "}", "return", "i", ";", "}", "}", "}", "else", "{", "arrayLoop", ":", "for", "(", "int", "i", "=", "start", ",", "max", "=", "arrayLength", "-", "toBeFoundLength", "+", "1", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "ScannerHelper", ".", "toLowerCase", "(", "array", "[", "i", "]", ")", "==", "ScannerHelper", ".", "toLowerCase", "(", "toBeFound", "[", "0", "]", ")", ")", "{", "for", "(", "int", "j", "=", "1", ";", "j", "<", "toBeFoundLength", ";", "j", "++", ")", "{", "if", "(", "ScannerHelper", ".", "toLowerCase", "(", "array", "[", "i", "+", "j", "]", ")", "!=", "ScannerHelper", ".", "toLowerCase", "(", "toBeFound", "[", "j", "]", ")", ")", "continue", "arrayLoop", ";", "}", "return", "i", ";", "}", "}", "}", "return", "-", "1", ";", "}", "public", "static", "final", "int", "indexOf", "(", "char", "toBeFound", ",", "char", "[", "]", "array", ",", "int", "start", ")", "{", "for", "(", "int", "i", "=", "start", ";", "i", "<", "array", ".", "length", ";", "i", "++", ")", "if", "(", "toBeFound", "==", "array", "[", "i", "]", ")", "return", "i", ";", "return", "-", "1", ";", "}", "public", "static", "final", "int", "indexOf", "(", "char", "toBeFound", ",", "char", "[", "]", "array", ",", "int", "start", ",", "int", "end", ")", "{", "for", "(", "int", "i", "=", "start", ";", "i", "<", "end", ";", "i", "++", ")", "if", "(", "toBeFound", "==", "array", "[", "i", "]", ")", "return", "i", ";", "return", "-", "1", ";", "}", "public", "static", "final", "int", "lastIndexOf", "(", "char", "toBeFound", ",", "char", "[", "]", "array", ")", "{", "for", "(", "int", "i", "=", "array", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "toBeFound", "==", "array", "[", "i", "]", ")", "return", "i", ";", "return", "-", "1", ";", "}", "public", "static", "final", "int", "lastIndexOf", "(", "char", "toBeFound", ",", "char", "[", "]", "array", ",", "int", "startIndex", ")", "{", "for", "(", "int", "i", "=", "array", ".", "length", ";", "--", "i", ">=", "startIndex", ";", ")", "if", "(", "toBeFound", "==", "array", "[", "i", "]", ")", "return", "i", ";", "return", "-", "1", ";", "}", "public", "static", "final", "int", "lastIndexOf", "(", "char", "toBeFound", ",", "char", "[", "]", "array", ",", "int", "startIndex", ",", "int", "endIndex", ")", "{", "for", "(", "int", "i", "=", "endIndex", ";", "--", "i", ">=", "startIndex", ";", ")", "if", "(", "toBeFound", "==", "array", "[", "i", "]", ")", "return", "i", ";", "return", "-", "1", ";", "}", "final", "static", "public", "char", "[", "]", "lastSegment", "(", "char", "[", "]", "array", ",", "char", "separator", ")", "{", "int", "pos", "=", "lastIndexOf", "(", "separator", ",", "array", ")", ";", "if", "(", "pos", "<", "0", ")", "return", "array", ";", "return", "subarray", "(", "array", ",", "pos", "+", "1", ",", "array", ".", "length", ")", ";", "}", "public", "static", "final", "boolean", "match", "(", "char", "[", "]", "pattern", ",", "char", "[", "]", "name", ",", "boolean", "isCaseSensitive", ")", "{", "if", "(", "name", "==", "null", ")", "return", "false", ";", "if", "(", "pattern", "==", "null", ")", "return", "true", ";", "return", "match", "(", "pattern", ",", "0", ",", "pattern", ".", "length", ",", "name", ",", "0", ",", "name", ".", "length", ",", "isCaseSensitive", ")", ";", "}", "public", "static", "final", "boolean", "match", "(", "char", "[", "]", "pattern", ",", "int", "patternStart", ",", "int", "patternEnd", ",", "char", "[", "]", "name", ",", "int", "nameStart", ",", "int", "nameEnd", ",", "boolean", "isCaseSensitive", ")", "{", "if", "(", "name", "==", "null", ")", "return", "false", ";", "if", "(", "pattern", "==", "null", ")", "return", "true", ";", "int", "iPattern", "=", "patternStart", ";", "int", "iName", "=", "nameStart", ";", "if", "(", "patternEnd", "<", "0", ")", "patternEnd", "=", "pattern", ".", "length", ";", "if", "(", "nameEnd", "<", "0", ")", "nameEnd", "=", "name", ".", "length", ";", "char", "patternChar", "=", "0", ";", "while", "(", "(", "iPattern", "<", "patternEnd", ")", "&&", "(", "patternChar", "=", "pattern", "[", "iPattern", "]", ")", "!=", "'*'", ")", "{", "if", "(", "iName", "==", "nameEnd", ")", "return", "false", ";", "if", "(", "patternChar", "!=", "(", "isCaseSensitive", "?", "name", "[", "iName", "]", ":", "ScannerHelper", ".", "toLowerCase", "(", "name", "[", "iName", "]", ")", ")", "&&", "patternChar", "!=", "'?'", ")", "{", "return", "false", ";", "}", "iName", "++", ";", "iPattern", "++", ";", "}", "int", "segmentStart", ";", "if", "(", "patternChar", "==", "'*'", ")", "{", "segmentStart", "=", "++", "iPattern", ";", "}", "else", "{", "segmentStart", "=", "0", ";", "}", "int", "prefixStart", "=", "iName", ";", "checkSegment", ":", "while", "(", "iName", "<", "nameEnd", ")", "{", "if", "(", "iPattern", "==", "patternEnd", ")", "{", "iPattern", "=", "segmentStart", ";", "iName", "=", "++", "prefixStart", ";", "continue", "checkSegment", ";", "}", "if", "(", "(", "patternChar", "=", "pattern", "[", "iPattern", "]", ")", "==", "'*'", ")", "{", "segmentStart", "=", "++", "iPattern", ";", "if", "(", "segmentStart", "==", "patternEnd", ")", "{", "return", "true", ";", "}", "prefixStart", "=", "iName", ";", "continue", "checkSegment", ";", "}", "if", "(", "(", "isCaseSensitive", "?", "name", "[", "iName", "]", ":", "ScannerHelper", ".", "toLowerCase", "(", "name", "[", "iName", "]", ")", ")", "!=", "patternChar", "&&", "patternChar", "!=", "'?'", ")", "{", "iPattern", "=", "segmentStart", ";", "iName", "=", "++", "prefixStart", ";", "continue", "checkSegment", ";", "}", "iName", "++", ";", "iPattern", "++", ";", "}", "return", "(", "segmentStart", "==", "patternEnd", ")", "||", "(", "iName", "==", "nameEnd", "&&", "iPattern", "==", "patternEnd", ")", "||", "(", "iPattern", "==", "patternEnd", "-", "1", "&&", "pattern", "[", "iPattern", "]", "==", "'*'", ")", ";", "}", "public", "static", "final", "boolean", "pathMatch", "(", "char", "[", "]", "pattern", ",", "char", "[", "]", "filepath", ",", "boolean", "isCaseSensitive", ",", "char", "pathSeparator", ")", "{", "if", "(", "filepath", "==", "null", ")", "return", "false", ";", "if", "(", "pattern", "==", "null", ")", "return", "true", ";", "int", "pSegmentStart", "=", "pattern", "[", "0", "]", "==", "pathSeparator", "?", "1", ":", "0", ";", "int", "pLength", "=", "pattern", ".", "length", ";", "int", "pSegmentEnd", "=", "CharOperation", ".", "indexOf", "(", "pathSeparator", ",", "pattern", ",", "pSegmentStart", "+", "1", ")", ";", "if", "(", "pSegmentEnd", "<", "0", ")", "pSegmentEnd", "=", "pLength", ";", "boolean", "freeTrailingDoubleStar", "=", "pattern", "[", "pLength", "-", "1", "]", "==", "pathSeparator", ";", "int", "fSegmentStart", ",", "fLength", "=", "filepath", ".", "length", ";", "if", "(", "filepath", "[", "0", "]", "!=", "pathSeparator", ")", "{", "fSegmentStart", "=", "0", ";", "}", "else", "{", "fSegmentStart", "=", "1", ";", "}", "if", "(", "fSegmentStart", "!=", "pSegmentStart", ")", "{", "return", "false", ";", "}", "int", "fSegmentEnd", "=", "CharOperation", ".", "indexOf", "(", "pathSeparator", ",", "filepath", ",", "fSegmentStart", "+", "1", ")", ";", "if", "(", "fSegmentEnd", "<", "0", ")", "fSegmentEnd", "=", "fLength", ";", "while", "(", "pSegmentStart", "<", "pLength", "&&", "!", "(", "pSegmentEnd", "==", "pLength", "&&", "freeTrailingDoubleStar", "||", "(", "pSegmentEnd", "==", "pSegmentStart", "+", "2", "&&", "pattern", "[", "pSegmentStart", "]", "==", "'*'", "&&", "pattern", "[", "pSegmentStart", "+", "1", "]", "==", "'*'", ")", ")", ")", "{", "if", "(", "fSegmentStart", ">=", "fLength", ")", "return", "false", ";", "if", "(", "!", "CharOperation", ".", "match", "(", "pattern", ",", "pSegmentStart", ",", "pSegmentEnd", ",", "filepath", ",", "fSegmentStart", ",", "fSegmentEnd", ",", "isCaseSensitive", ")", ")", "{", "return", "false", ";", "}", "pSegmentEnd", "=", "CharOperation", ".", "indexOf", "(", "pathSeparator", ",", "pattern", ",", "pSegmentStart", "=", "pSegmentEnd", "+", "1", ")", ";", "if", "(", "pSegmentEnd", "<", "0", ")", "pSegmentEnd", "=", "pLength", ";", "fSegmentEnd", "=", "CharOperation", ".", "indexOf", "(", "pathSeparator", ",", "filepath", ",", "fSegmentStart", "=", "fSegmentEnd", "+", "1", ")", ";", "if", "(", "fSegmentEnd", "<", "0", ")", "fSegmentEnd", "=", "fLength", ";", "}", "int", "pSegmentRestart", ";", "if", "(", "(", "pSegmentStart", ">=", "pLength", "&&", "freeTrailingDoubleStar", ")", "||", "(", "pSegmentEnd", "==", "pSegmentStart", "+", "2", "&&", "pattern", "[", "pSegmentStart", "]", "==", "'*'", "&&", "pattern", "[", "pSegmentStart", "+", "1", "]", "==", "'*'", ")", ")", "{", "pSegmentEnd", "=", "CharOperation", ".", "indexOf", "(", "pathSeparator", ",", "pattern", ",", "pSegmentStart", "=", "pSegmentEnd", "+", "1", ")", ";", "if", "(", "pSegmentEnd", "<", "0", ")", "pSegmentEnd", "=", "pLength", ";", "pSegmentRestart", "=", "pSegmentStart", ";", "}", "else", "{", "if", "(", "pSegmentStart", ">=", "pLength", ")", "return", "fSegmentStart", ">=", "fLength", ";", "pSegmentRestart", "=", "0", ";", "}", "int", "fSegmentRestart", "=", "fSegmentStart", ";", "checkSegment", ":", "while", "(", "fSegmentStart", "<", "fLength", ")", "{", "if", "(", "pSegmentStart", ">=", "pLength", ")", "{", "if", "(", "freeTrailingDoubleStar", ")", "return", "true", ";", "pSegmentEnd", "=", "CharOperation", ".", "indexOf", "(", "pathSeparator", ",", "pattern", ",", "pSegmentStart", "=", "pSegmentRestart", ")", ";", "if", "(", "pSegmentEnd", "<", "0", ")", "pSegmentEnd", "=", "pLength", ";", "fSegmentRestart", "=", "CharOperation", ".", "indexOf", "(", "pathSeparator", ",", "filepath", ",", "fSegmentRestart", "+", "1", ")", ";", "if", "(", "fSegmentRestart", "<", "0", ")", "{", "fSegmentRestart", "=", "fLength", ";", "}", "else", "{", "fSegmentRestart", "++", ";", "}", "fSegmentEnd", "=", "CharOperation", ".", "indexOf", "(", "pathSeparator", ",", "filepath", ",", "fSegmentStart", "=", "fSegmentRestart", ")", ";", "if", "(", "fSegmentEnd", "<", "0", ")", "fSegmentEnd", "=", "fLength", ";", "continue", "checkSegment", ";", "}", "if", "(", "pSegmentEnd", "==", "pSegmentStart", "+", "2", "&&", "pattern", "[", "pSegmentStart", "]", "==", "'*'", "&&", "pattern", "[", "pSegmentStart", "+", "1", "]", "==", "'*'", ")", "{", "pSegmentEnd", "=", "CharOperation", ".", "indexOf", "(", "pathSeparator", ",", "pattern", ",", "pSegmentStart", "=", "pSegmentEnd", "+", "1", ")", ";", "if", "(", "pSegmentEnd", "<", "0", ")", "pSegmentEnd", "=", "pLength", ";", "pSegmentRestart", "=", "pSegmentStart", ";", "fSegmentRestart", "=", "fSegmentStart", ";", "if", "(", "pSegmentStart", ">=", "pLength", ")", "return", "true", ";", "continue", "checkSegment", ";", "}", "if", "(", "!", "CharOperation", ".", "match", "(", "pattern", ",", "pSegmentStart", ",", "pSegmentEnd", ",", "filepath", ",", "fSegmentStart", ",", "fSegmentEnd", ",", "isCaseSensitive", ")", ")", "{", "pSegmentEnd", "=", "CharOperation", ".", "indexOf", "(", "pathSeparator", ",", "pattern", ",", "pSegmentStart", "=", "pSegmentRestart", ")", ";", "if", "(", "pSegmentEnd", "<", "0", ")", "pSegmentEnd", "=", "pLength", ";", "fSegmentRestart", "=", "CharOperation", ".", "indexOf", "(", "pathSeparator", ",", "filepath", ",", "fSegmentRestart", "+", "1", ")", ";", "if", "(", "fSegmentRestart", "<", "0", ")", "{", "fSegmentRestart", "=", "fLength", ";", "}", "else", "{", "fSegmentRestart", "++", ";", "}", "fSegmentEnd", "=", "CharOperation", ".", "indexOf", "(", "pathSeparator", ",", "filepath", ",", "fSegmentStart", "=", "fSegmentRestart", ")", ";", "if", "(", "fSegmentEnd", "<", "0", ")", "fSegmentEnd", "=", "fLength", ";", "continue", "checkSegment", ";", "}", "pSegmentEnd", "=", "CharOperation", ".", "indexOf", "(", "pathSeparator", ",", "pattern", ",", "pSegmentStart", "=", "pSegmentEnd", "+", "1", ")", ";", "if", "(", "pSegmentEnd", "<", "0", ")", "pSegmentEnd", "=", "pLength", ";", "fSegmentEnd", "=", "CharOperation", ".", "indexOf", "(", "pathSeparator", ",", "filepath", ",", "fSegmentStart", "=", "fSegmentEnd", "+", "1", ")", ";", "if", "(", "fSegmentEnd", "<", "0", ")", "fSegmentEnd", "=", "fLength", ";", "}", "return", "(", "pSegmentRestart", ">=", "pSegmentEnd", ")", "||", "(", "fSegmentStart", ">=", "fLength", "&&", "pSegmentStart", ">=", "pLength", ")", "||", "(", "pSegmentStart", "==", "pLength", "-", "2", "&&", "pattern", "[", "pSegmentStart", "]", "==", "'*'", "&&", "pattern", "[", "pSegmentStart", "+", "1", "]", "==", "'*'", ")", "||", "(", "pSegmentStart", "==", "pLength", "&&", "freeTrailingDoubleStar", ")", ";", "}", "public", "static", "final", "int", "occurencesOf", "(", "char", "toBeFound", ",", "char", "[", "]", "array", ")", "{", "int", "count", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "array", ".", "length", ";", "i", "++", ")", "if", "(", "toBeFound", "==", "array", "[", "i", "]", ")", "count", "++", ";", "return", "count", ";", "}", "public", "static", "final", "int", "occurencesOf", "(", "char", "toBeFound", ",", "char", "[", "]", "array", ",", "int", "start", ")", "{", "int", "count", "=", "0", ";", "for", "(", "int", "i", "=", "start", ";", "i", "<", "array", ".", "length", ";", "i", "++", ")", "if", "(", "toBeFound", "==", "array", "[", "i", "]", ")", "count", "++", ";", "return", "count", ";", "}", "public", "static", "final", "int", "parseInt", "(", "char", "[", "]", "array", ",", "int", "start", ",", "int", "length", ")", "throws", "NumberFormatException", "{", "if", "(", "length", "==", "1", ")", "{", "int", "result", "=", "array", "[", "start", "]", "-", "'0'", ";", "if", "(", "result", "<", "0", "||", "result", ">", "9", ")", "{", "throw", "new", "NumberFormatException", "(", "\"\"", ")", ";", "}", "return", "result", ";", "}", "else", "{", "return", "Integer", ".", "parseInt", "(", "new", "String", "(", "array", ",", "start", ",", "length", ")", ")", ";", "}", "}", "public", "static", "final", "boolean", "prefixEquals", "(", "char", "[", "]", "prefix", ",", "char", "[", "]", "name", ")", "{", "int", "max", "=", "prefix", ".", "length", ";", "if", "(", "name", ".", "length", "<", "max", ")", "return", "false", ";", "for", "(", "int", "i", "=", "max", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "prefix", "[", "i", "]", "!=", "name", "[", "i", "]", ")", "return", "false", ";", "return", "true", ";", "}", "public", "static", "final", "boolean", "prefixEquals", "(", "char", "[", "]", "prefix", ",", "char", "[", "]", "name", ",", "boolean", "isCaseSensitive", ")", "{", "int", "max", "=", "prefix", ".", "length", ";", "if", "(", "name", ".", "length", "<", "max", ")", "return", "false", ";", "if", "(", "isCaseSensitive", ")", "{", "for", "(", "int", "i", "=", "max", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "prefix", "[", "i", "]", "!=", "name", "[", "i", "]", ")", "return", "false", ";", "return", "true", ";", "}", "for", "(", "int", "i", "=", "max", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "ScannerHelper", ".", "toLowerCase", "(", "prefix", "[", "i", "]", ")", "!=", "ScannerHelper", ".", "toLowerCase", "(", "name", "[", "i", "]", ")", ")", "return", "false", ";", "return", "true", ";", "}", "public", "static", "final", "char", "[", "]", "remove", "(", "char", "[", "]", "array", ",", "char", "toBeRemoved", ")", "{", "if", "(", "array", "==", "null", ")", "return", "null", ";", "int", "length", "=", "array", ".", "length", ";", "if", "(", "length", "==", "0", ")", "return", "array", ";", "char", "[", "]", "result", "=", "null", ";", "int", "count", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "char", "c", "=", "array", "[", "i", "]", ";", "if", "(", "c", "==", "toBeRemoved", ")", "{", "if", "(", "result", "==", "null", ")", "{", "result", "=", "new", "char", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "array", ",", "0", ",", "result", ",", "0", ",", "i", ")", ";", "count", "=", "i", ";", "}", "}", "else", "if", "(", "result", "!=", "null", ")", "{", "result", "[", "count", "++", "]", "=", "c", ";", "}", "}", "if", "(", "result", "==", "null", ")", "return", "array", ";", "System", ".", "arraycopy", "(", "result", ",", "0", ",", "result", "=", "new", "char", "[", "count", "]", ",", "0", ",", "count", ")", ";", "return", "result", ";", "}", "public", "static", "final", "void", "replace", "(", "char", "[", "]", "array", ",", "char", "toBeReplaced", ",", "char", "replacementChar", ")", "{", "if", "(", "toBeReplaced", "!=", "replacementChar", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "array", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "array", "[", "i", "]", "==", "toBeReplaced", ")", "array", "[", "i", "]", "=", "replacementChar", ";", "}", "}", "}", "public", "static", "final", "void", "replace", "(", "char", "[", "]", "array", ",", "char", "[", "]", "toBeReplaced", ",", "char", "replacementChar", ")", "{", "replace", "(", "array", ",", "toBeReplaced", ",", "replacementChar", ",", "0", ",", "array", ".", "length", ")", ";", "}", "public", "static", "final", "void", "replace", "(", "char", "[", "]", "array", ",", "char", "[", "]", "toBeReplaced", ",", "char", "replacementChar", ",", "int", "start", ",", "int", "end", ")", "{", "for", "(", "int", "i", "=", "end", ";", "--", "i", ">=", "start", ";", ")", "for", "(", "int", "j", "=", "toBeReplaced", ".", "length", ";", "--", "j", ">=", "0", ";", ")", "if", "(", "array", "[", "i", "]", "==", "toBeReplaced", "[", "j", "]", ")", "array", "[", "i", "]", "=", "replacementChar", ";", "}", "public", "static", "final", "char", "[", "]", "replace", "(", "char", "[", "]", "array", ",", "char", "[", "]", "toBeReplaced", ",", "char", "[", "]", "replacementChars", ")", "{", "int", "max", "=", "array", ".", "length", ";", "int", "replacedLength", "=", "toBeReplaced", ".", "length", ";", "int", "replacementLength", "=", "replacementChars", ".", "length", ";", "int", "[", "]", "starts", "=", "new", "int", "[", "5", "]", ";", "int", "occurrenceCount", "=", "0", ";", "if", "(", "!", "equals", "(", "toBeReplaced", ",", "replacementChars", ")", ")", "{", "next", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "max", ";", ")", "{", "int", "index", "=", "indexOf", "(", "toBeReplaced", ",", "array", ",", "true", ",", "i", ")", ";", "if", "(", "index", "==", "-", "1", ")", "{", "i", "++", ";", "continue", "next", ";", "}", "if", "(", "occurrenceCount", "==", "starts", ".", "length", ")", "{", "System", ".", "arraycopy", "(", "starts", ",", "0", ",", "starts", "=", "new", "int", "[", "occurrenceCount", "*", "2", "]", ",", "0", ",", "occurrenceCount", ")", ";", "}", "starts", "[", "occurrenceCount", "++", "]", "=", "index", ";", "i", "=", "index", "+", "replacedLength", ";", "}", "}", "if", "(", "occurrenceCount", "==", "0", ")", "return", "array", ";", "char", "[", "]", "result", "=", "new", "char", "[", "max", "+", "occurrenceCount", "*", "(", "replacementLength", "-", "replacedLength", ")", "]", ";", "int", "inStart", "=", "0", ",", "outStart", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "occurrenceCount", ";", "i", "++", ")", "{", "int", "offset", "=", "starts", "[", "i", "]", "-", "inStart", ";", "System", ".", "arraycopy", "(", "array", ",", "inStart", ",", "result", ",", "outStart", ",", "offset", ")", ";", "inStart", "+=", "offset", ";", "outStart", "+=", "offset", ";", "System", ".", "arraycopy", "(", "replacementChars", ",", "0", ",", "result", ",", "outStart", ",", "replacementLength", ")", ";", "inStart", "+=", "replacedLength", ";", "outStart", "+=", "replacementLength", ";", "}", "System", ".", "arraycopy", "(", "array", ",", "inStart", ",", "result", ",", "outStart", ",", "max", "-", "inStart", ")", ";", "return", "result", ";", "}", "public", "static", "final", "char", "[", "]", "replaceOnCopy", "(", "char", "[", "]", "array", ",", "char", "toBeReplaced", ",", "char", "replacementChar", ")", "{", "char", "[", "]", "result", "=", "null", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "array", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "char", "c", "=", "array", "[", "i", "]", ";", "if", "(", "c", "==", "toBeReplaced", ")", "{", "if", "(", "result", "==", "null", ")", "{", "result", "=", "new", "char", "[", "length", "]", ";", "System", ".", "arraycopy", "(", "array", ",", "0", ",", "result", ",", "0", ",", "i", ")", ";", "}", "result", "[", "i", "]", "=", "replacementChar", ";", "}", "else", "if", "(", "result", "!=", "null", ")", "{", "result", "[", "i", "]", "=", "c", ";", "}", "}", "if", "(", "result", "==", "null", ")", "return", "array", ";", "return", "result", ";", "}", "public", "static", "final", "char", "[", "]", "[", "]", "splitAndTrimOn", "(", "char", "divider", ",", "char", "[", "]", "array", ")", "{", "int", "length", "=", "array", "==", "null", "?", "0", ":", "array", ".", "length", ";", "if", "(", "length", "==", "0", ")", "return", "NO_CHAR_CHAR", ";", "int", "wordCount", "=", "1", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "if", "(", "array", "[", "i", "]", "==", "divider", ")", "wordCount", "++", ";", "char", "[", "]", "[", "]", "split", "=", "new", "char", "[", "wordCount", "]", "[", "]", ";", "int", "last", "=", "0", ",", "currentWord", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "array", "[", "i", "]", "==", "divider", ")", "{", "int", "start", "=", "last", ",", "end", "=", "i", "-", "1", ";", "while", "(", "start", "<", "i", "&&", "array", "[", "start", "]", "==", "'", "'", ")", "start", "++", ";", "while", "(", "end", ">", "start", "&&", "array", "[", "end", "]", "==", "'", "'", ")", "end", "--", ";", "split", "[", "currentWord", "]", "=", "new", "char", "[", "end", "-", "start", "+", "1", "]", ";", "System", ".", "arraycopy", "(", "array", ",", "start", ",", "split", "[", "currentWord", "++", "]", ",", "0", ",", "end", "-", "start", "+", "1", ")", ";", "last", "=", "i", "+", "1", ";", "}", "}", "int", "start", "=", "last", ",", "end", "=", "length", "-", "1", ";", "while", "(", "start", "<", "length", "&&", "array", "[", "start", "]", "==", "'", "'", ")", "start", "++", ";", "while", "(", "end", ">", "start", "&&", "array", "[", "end", "]", "==", "'", "'", ")", "end", "--", ";", "split", "[", "currentWord", "]", "=", "new", "char", "[", "end", "-", "start", "+", "1", "]", ";", "System", ".", "arraycopy", "(", "array", ",", "start", ",", "split", "[", "currentWord", "++", "]", ",", "0", ",", "end", "-", "start", "+", "1", ")", ";", "return", "split", ";", "}", "public", "static", "final", "char", "[", "]", "[", "]", "splitOn", "(", "char", "divider", ",", "char", "[", "]", "array", ")", "{", "int", "length", "=", "array", "==", "null", "?", "0", ":", "array", ".", "length", ";", "if", "(", "length", "==", "0", ")", "return", "NO_CHAR_CHAR", ";", "int", "wordCount", "=", "1", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "if", "(", "array", "[", "i", "]", "==", "divider", ")", "wordCount", "++", ";", "char", "[", "]", "[", "]", "split", "=", "new", "char", "[", "wordCount", "]", "[", "]", ";", "int", "last", "=", "0", ",", "currentWord", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "array", "[", "i", "]", "==", "divider", ")", "{", "split", "[", "currentWord", "]", "=", "new", "char", "[", "i", "-", "last", "]", ";", "System", ".", "arraycopy", "(", "array", ",", "last", ",", "split", "[", "currentWord", "++", "]", ",", "0", ",", "i", "-", "last", ")", ";", "last", "=", "i", "+", "1", ";", "}", "}", "split", "[", "currentWord", "]", "=", "new", "char", "[", "length", "-", "last", "]", ";", "System", ".", "arraycopy", "(", "array", ",", "last", ",", "split", "[", "currentWord", "]", ",", "0", ",", "length", "-", "last", ")", ";", "return", "split", ";", "}", "public", "static", "final", "char", "[", "]", "[", "]", "splitOn", "(", "char", "divider", ",", "char", "[", "]", "array", ",", "int", "start", ",", "int", "end", ")", "{", "int", "length", "=", "array", "==", "null", "?", "0", ":", "array", ".", "length", ";", "if", "(", "length", "==", "0", "||", "start", ">", "end", ")", "return", "NO_CHAR_CHAR", ";", "int", "wordCount", "=", "1", ";", "for", "(", "int", "i", "=", "start", ";", "i", "<", "end", ";", "i", "++", ")", "if", "(", "array", "[", "i", "]", "==", "divider", ")", "wordCount", "++", ";", "char", "[", "]", "[", "]", "split", "=", "new", "char", "[", "wordCount", "]", "[", "]", ";", "int", "last", "=", "start", ",", "currentWord", "=", "0", ";", "for", "(", "int", "i", "=", "start", ";", "i", "<", "end", ";", "i", "++", ")", "{", "if", "(", "array", "[", "i", "]", "==", "divider", ")", "{", "split", "[", "currentWord", "]", "=", "new", "char", "[", "i", "-", "last", "]", ";", "System", ".", "arraycopy", "(", "array", ",", "last", ",", "split", "[", "currentWord", "++", "]", ",", "0", ",", "i", "-", "last", ")", ";", "last", "=", "i", "+", "1", ";", "}", "}", "split", "[", "currentWord", "]", "=", "new", "char", "[", "end", "-", "last", "]", ";", "System", ".", "arraycopy", "(", "array", ",", "last", ",", "split", "[", "currentWord", "]", ",", "0", ",", "end", "-", "last", ")", ";", "return", "split", ";", "}", "public", "static", "final", "char", "[", "]", "[", "]", "subarray", "(", "char", "[", "]", "[", "]", "array", ",", "int", "start", ",", "int", "end", ")", "{", "if", "(", "end", "==", "-", "1", ")", "end", "=", "array", ".", "length", ";", "if", "(", "start", ">", "end", ")", "return", "null", ";", "if", "(", "start", "<", "0", ")", "return", "null", ";", "if", "(", "end", ">", "array", ".", "length", ")", "return", "null", ";", "char", "[", "]", "[", "]", "result", "=", "new", "char", "[", "end", "-", "start", "]", "[", "]", ";", "System", ".", "arraycopy", "(", "array", ",", "start", ",", "result", ",", "0", ",", "end", "-", "start", ")", ";", "return", "result", ";", "}", "public", "static", "final", "char", "[", "]", "subarray", "(", "char", "[", "]", "array", ",", "int", "start", ",", "int", "end", ")", "{", "if", "(", "end", "==", "-", "1", ")", "end", "=", "array", ".", "length", ";", "if", "(", "start", ">", "end", ")", "return", "null", ";", "if", "(", "start", "<", "0", ")", "return", "null", ";", "if", "(", "end", ">", "array", ".", "length", ")", "return", "null", ";", "char", "[", "]", "result", "=", "new", "char", "[", "end", "-", "start", "]", ";", "System", ".", "arraycopy", "(", "array", ",", "start", ",", "result", ",", "0", ",", "end", "-", "start", ")", ";", "return", "result", ";", "}", "final", "static", "public", "char", "[", "]", "toLowerCase", "(", "char", "[", "]", "chars", ")", "{", "if", "(", "chars", "==", "null", ")", "return", "null", ";", "int", "length", "=", "chars", ".", "length", ";", "char", "[", "]", "lowerChars", "=", "null", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "char", "c", "=", "chars", "[", "i", "]", ";", "char", "lc", "=", "ScannerHelper", ".", "toLowerCase", "(", "c", ")", ";", "if", "(", "(", "c", "!=", "lc", ")", "||", "(", "lowerChars", "!=", "null", ")", ")", "{", "if", "(", "lowerChars", "==", "null", ")", "{", "System", ".", "arraycopy", "(", "chars", ",", "0", ",", "lowerChars", "=", "new", "char", "[", "length", "]", ",", "0", ",", "i", ")", ";", "}", "lowerChars", "[", "i", "]", "=", "lc", ";", "}", "}", "return", "lowerChars", "==", "null", "?", "chars", ":", "lowerChars", ";", "}", "final", "static", "public", "char", "[", "]", "toUpperCase", "(", "char", "[", "]", "chars", ")", "{", "if", "(", "chars", "==", "null", ")", "return", "null", ";", "int", "length", "=", "chars", ".", "length", ";", "char", "[", "]", "upperChars", "=", "null", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "char", "c", "=", "chars", "[", "i", "]", ";", "char", "lc", "=", "ScannerHelper", ".", "toUpperCase", "(", "c", ")", ";", "if", "(", "(", "c", "!=", "lc", ")", "||", "(", "upperChars", "!=", "null", ")", ")", "{", "if", "(", "upperChars", "==", "null", ")", "{", "System", ".", "arraycopy", "(", "chars", ",", "0", ",", "upperChars", "=", "new", "char", "[", "length", "]", ",", "0", ",", "i", ")", ";", "}", "upperChars", "[", "i", "]", "=", "lc", ";", "}", "}", "return", "upperChars", "==", "null", "?", "chars", ":", "upperChars", ";", "}", "final", "static", "public", "char", "[", "]", "trim", "(", "char", "[", "]", "chars", ")", "{", "if", "(", "chars", "==", "null", ")", "return", "null", ";", "int", "start", "=", "0", ",", "length", "=", "chars", ".", "length", ",", "end", "=", "length", "-", "1", ";", "while", "(", "start", "<", "length", "&&", "chars", "[", "start", "]", "==", "'", "'", ")", "{", "start", "++", ";", "}", "while", "(", "end", ">", "start", "&&", "chars", "[", "end", "]", "==", "'", "'", ")", "{", "end", "--", ";", "}", "if", "(", "start", "!=", "0", "||", "end", "!=", "length", "-", "1", ")", "{", "return", "subarray", "(", "chars", ",", "start", ",", "end", "+", "1", ")", ";", "}", "return", "chars", ";", "}", "final", "static", "public", "String", "toString", "(", "char", "[", "]", "[", "]", "array", ")", "{", "char", "[", "]", "result", "=", "concatWith", "(", "array", ",", "'.'", ")", ";", "return", "new", "String", "(", "result", ")", ";", "}", "final", "static", "public", "String", "[", "]", "toStrings", "(", "char", "[", "]", "[", "]", "array", ")", "{", "if", "(", "array", "==", "null", ")", "return", "NO_STRINGS", ";", "int", "length", "=", "array", ".", "length", ";", "if", "(", "length", "==", "0", ")", "return", "NO_STRINGS", ";", "String", "[", "]", "result", "=", "new", "String", "[", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "result", "[", "i", "]", "=", "new", "String", "(", "array", "[", "i", "]", ")", ";", "return", "result", ";", "}", "}", "</s>" ]
5,545
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ProblemReasons", ";", "public", "interface", "IProblem", "{", "String", "[", "]", "getArguments", "(", ")", ";", "int", "getID", "(", ")", ";", "String", "getMessage", "(", ")", ";", "char", "[", "]", "getOriginatingFileName", "(", ")", ";", "int", "getSourceEnd", "(", ")", ";", "int", "getSourceLineNumber", "(", ")", ";", "int", "getSourceStart", "(", ")", ";", "boolean", "isError", "(", ")", ";", "boolean", "isWarning", "(", ")", ";", "void", "setSourceEnd", "(", "int", "sourceEnd", ")", ";", "void", "setSourceLineNumber", "(", "int", "lineNumber", ")", ";", "void", "setSourceStart", "(", "int", "sourceStart", ")", ";", "int", "TypeRelated", "=", "0x01000000", ";", "int", "FieldRelated", "=", "0x02000000", ";", "int", "MethodRelated", "=", "0x04000000", ";", "int", "ConstructorRelated", "=", "0x08000000", ";", "int", "ImportRelated", "=", "0x10000000", ";", "int", "Internal", "=", "0x20000000", ";", "int", "Syntax", "=", "0x40000000", ";", "int", "Javadoc", "=", "0x80000000", ";", "int", "IgnoreCategoriesMask", "=", "0xFFFFFF", ";", "int", "Unclassified", "=", "0", ";", "int", "ObjectHasNoSuperclass", "=", "TypeRelated", "+", "1", ";", "int", "UndefinedType", "=", "TypeRelated", "+", "2", ";", "int", "NotVisibleType", "=", "TypeRelated", "+", "3", ";", "int", "AmbiguousType", "=", "TypeRelated", "+", "4", ";", "int", "UsingDeprecatedType", "=", "TypeRelated", "+", "5", ";", "int", "InternalTypeNameProvided", "=", "TypeRelated", "+", "6", ";", "int", "UnusedPrivateType", "=", "Internal", "+", "TypeRelated", "+", "7", ";", "int", "IncompatibleTypesInEqualityOperator", "=", "TypeRelated", "+", "15", ";", "int", "IncompatibleTypesInConditionalOperator", "=", "TypeRelated", "+", "16", ";", "int", "TypeMismatch", "=", "TypeRelated", "+", "17", ";", "int", "IndirectAccessToStaticType", "=", "Internal", "+", "TypeRelated", "+", "18", ";", "int", "MissingEnclosingInstanceForConstructorCall", "=", "TypeRelated", "+", "20", ";", "int", "MissingEnclosingInstance", "=", "TypeRelated", "+", "21", ";", "int", "IncorrectEnclosingInstanceReference", "=", "TypeRelated", "+", "22", ";", "int", "IllegalEnclosingInstanceSpecification", "=", "TypeRelated", "+", "23", ";", "int", "CannotDefineStaticInitializerInLocalType", "=", "Internal", "+", "24", ";", "int", "OuterLocalMustBeFinal", "=", "Internal", "+", "25", ";", "int", "CannotDefineInterfaceInLocalType", "=", "Internal", "+", "26", ";", "int", "IllegalPrimitiveOrArrayTypeForEnclosingInstance", "=", "TypeRelated", "+", "27", ";", "int", "EnclosingInstanceInConstructorCall", "=", "Internal", "+", "28", ";", "int", "AnonymousClassCannotExtendFinalClass", "=", "TypeRelated", "+", "29", ";", "int", "CannotDefineAnnotationInLocalType", "=", "Internal", "+", "30", ";", "int", "CannotDefineEnumInLocalType", "=", "Internal", "+", "31", ";", "int", "NonStaticContextForEnumMemberType", "=", "Internal", "+", "32", ";", "int", "TypeHidingType", "=", "TypeRelated", "+", "33", ";", "int", "UndefinedName", "=", "Internal", "+", "FieldRelated", "+", "50", ";", "int", "UninitializedLocalVariable", "=", "Internal", "+", "51", ";", "int", "VariableTypeCannotBeVoid", "=", "Internal", "+", "52", ";", "int", "VariableTypeCannotBeVoidArray", "=", "Internal", "+", "53", ";", "int", "CannotAllocateVoidArray", "=", "Internal", "+", "54", ";", "int", "RedefinedLocal", "=", "Internal", "+", "55", ";", "int", "RedefinedArgument", "=", "Internal", "+", "56", ";", "int", "DuplicateFinalLocalInitialization", "=", "Internal", "+", "57", ";", "int", "NonBlankFinalLocalAssignment", "=", "Internal", "+", "58", ";", "int", "ParameterAssignment", "=", "Internal", "+", "59", ";", "int", "FinalOuterLocalAssignment", "=", "Internal", "+", "60", ";", "int", "LocalVariableIsNeverUsed", "=", "Internal", "+", "61", ";", "int", "ArgumentIsNeverUsed", "=", "Internal", "+", "62", ";", "int", "BytecodeExceeds64KLimit", "=", "Internal", "+", "63", ";", "int", "BytecodeExceeds64KLimitForClinit", "=", "Internal", "+", "64", ";", "int", "TooManyArgumentSlots", "=", "Internal", "+", "65", ";", "int", "TooManyLocalVariableSlots", "=", "Internal", "+", "66", ";", "int", "TooManySyntheticArgumentSlots", "=", "Internal", "+", "67", ";", "int", "TooManyArrayDimensions", "=", "Internal", "+", "68", ";", "int", "BytecodeExceeds64KLimitForConstructor", "=", "Internal", "+", "69", ";", "int", "UndefinedField", "=", "FieldRelated", "+", "70", ";", "int", "NotVisibleField", "=", "FieldRelated", "+", "71", ";", "int", "AmbiguousField", "=", "FieldRelated", "+", "72", ";", "int", "UsingDeprecatedField", "=", "FieldRelated", "+", "73", ";", "int", "NonStaticFieldFromStaticInvocation", "=", "FieldRelated", "+", "74", ";", "int", "ReferenceToForwardField", "=", "FieldRelated", "+", "Internal", "+", "75", ";", "int", "NonStaticAccessToStaticField", "=", "Internal", "+", "FieldRelated", "+", "76", ";", "int", "UnusedPrivateField", "=", "Internal", "+", "FieldRelated", "+", "77", ";", "int", "IndirectAccessToStaticField", "=", "Internal", "+", "FieldRelated", "+", "78", ";", "int", "UnqualifiedFieldAccess", "=", "Internal", "+", "FieldRelated", "+", "79", ";", "int", "FinalFieldAssignment", "=", "FieldRelated", "+", "80", ";", "int", "UninitializedBlankFinalField", "=", "FieldRelated", "+", "81", ";", "int", "DuplicateBlankFinalFieldInitialization", "=", "FieldRelated", "+", "82", ";", "int", "UnresolvedVariable", "=", "FieldRelated", "+", "83", ";", "int", "LocalVariableHidingLocalVariable", "=", "Internal", "+", "90", ";", "int", "LocalVariableHidingField", "=", "Internal", "+", "FieldRelated", "+", "91", ";", "int", "FieldHidingLocalVariable", "=", "Internal", "+", "FieldRelated", "+", "92", ";", "int", "FieldHidingField", "=", "Internal", "+", "FieldRelated", "+", "93", ";", "int", "ArgumentHidingLocalVariable", "=", "Internal", "+", "94", ";", "int", "ArgumentHidingField", "=", "Internal", "+", "95", ";", "int", "MissingSerialVersion", "=", "Internal", "+", "96", ";", "int", "UndefinedMethod", "=", "MethodRelated", "+", "100", ";", "int", "NotVisibleMethod", "=", "MethodRelated", "+", "101", ";", "int", "AmbiguousMethod", "=", "MethodRelated", "+", "102", ";", "int", "UsingDeprecatedMethod", "=", "MethodRelated", "+", "103", ";", "int", "DirectInvocationOfAbstractMethod", "=", "MethodRelated", "+", "104", ";", "int", "VoidMethodReturnsValue", "=", "MethodRelated", "+", "105", ";", "int", "MethodReturnsVoid", "=", "MethodRelated", "+", "106", ";", "int", "MethodRequiresBody", "=", "Internal", "+", "MethodRelated", "+", "107", ";", "int", "ShouldReturnValue", "=", "Internal", "+", "MethodRelated", "+", "108", ";", "int", "MethodButWithConstructorName", "=", "MethodRelated", "+", "110", ";", "int", "MissingReturnType", "=", "TypeRelated", "+", "111", ";", "int", "BodyForNativeMethod", "=", "Internal", "+", "MethodRelated", "+", "112", ";", "int", "BodyForAbstractMethod", "=", "Internal", "+", "MethodRelated", "+", "113", ";", "int", "NoMessageSendOnBaseType", "=", "MethodRelated", "+", "114", ";", "int", "ParameterMismatch", "=", "MethodRelated", "+", "115", ";", "int", "NoMessageSendOnArrayType", "=", "MethodRelated", "+", "116", ";", "int", "NonStaticAccessToStaticMethod", "=", "Internal", "+", "MethodRelated", "+", "117", ";", "int", "UnusedPrivateMethod", "=", "Internal", "+", "MethodRelated", "+", "118", ";", "int", "IndirectAccessToStaticMethod", "=", "Internal", "+", "MethodRelated", "+", "119", ";", "int", "MissingTypeInMethod", "=", "MethodRelated", "+", "120", ";", "int", "MissingTypeInConstructor", "=", "ConstructorRelated", "+", "129", ";", "int", "UndefinedConstructor", "=", "ConstructorRelated", "+", "130", ";", "int", "NotVisibleConstructor", "=", "ConstructorRelated", "+", "131", ";", "int", "AmbiguousConstructor", "=", "ConstructorRelated", "+", "132", ";", "int", "UsingDeprecatedConstructor", "=", "ConstructorRelated", "+", "133", ";", "int", "UnusedPrivateConstructor", "=", "Internal", "+", "MethodRelated", "+", "134", ";", "int", "InstanceFieldDuringConstructorInvocation", "=", "ConstructorRelated", "+", "135", ";", "int", "InstanceMethodDuringConstructorInvocation", "=", "ConstructorRelated", "+", "136", ";", "int", "RecursiveConstructorInvocation", "=", "ConstructorRelated", "+", "137", ";", "int", "ThisSuperDuringConstructorInvocation", "=", "ConstructorRelated", "+", "138", ";", "int", "InvalidExplicitConstructorCall", "=", "ConstructorRelated", "+", "Syntax", "+", "139", ";", "int", "UndefinedConstructorInDefaultConstructor", "=", "ConstructorRelated", "+", "140", ";", "int", "NotVisibleConstructorInDefaultConstructor", "=", "ConstructorRelated", "+", "141", ";", "int", "AmbiguousConstructorInDefaultConstructor", "=", "ConstructorRelated", "+", "142", ";", "int", "UndefinedConstructorInImplicitConstructorCall", "=", "ConstructorRelated", "+", "143", ";", "int", "NotVisibleConstructorInImplicitConstructorCall", "=", "ConstructorRelated", "+", "144", ";", "int", "AmbiguousConstructorInImplicitConstructorCall", "=", "ConstructorRelated", "+", "145", ";", "int", "UnhandledExceptionInDefaultConstructor", "=", "TypeRelated", "+", "146", ";", "int", "UnhandledExceptionInImplicitConstructorCall", "=", "TypeRelated", "+", "147", ";", "int", "UnusedObjectAllocation", "=", "Internal", "+", "148", ";", "int", "DeadCode", "=", "Internal", "+", "149", ";", "int", "ArrayReferenceRequired", "=", "Internal", "+", "150", ";", "int", "NoImplicitStringConversionForCharArrayExpression", "=", "Internal", "+", "151", ";", "int", "StringConstantIsExceedingUtf8Limit", "=", "Internal", "+", "152", ";", "int", "NonConstantExpression", "=", "Internal", "+", "153", ";", "int", "NumericValueOutOfRange", "=", "Internal", "+", "154", ";", "int", "IllegalCast", "=", "TypeRelated", "+", "156", ";", "int", "InvalidClassInstantiation", "=", "TypeRelated", "+", "157", ";", "int", "CannotDefineDimensionExpressionsWithInit", "=", "Internal", "+", "158", ";", "int", "MustDefineEitherDimensionExpressionsOrInitializer", "=", "Internal", "+", "159", ";", "int", "InvalidOperator", "=", "Internal", "+", "160", ";", "int", "CodeCannotBeReached", "=", "Internal", "+", "161", ";", "int", "CannotReturnInInitializer", "=", "Internal", "+", "162", ";", "int", "InitializerMustCompleteNormally", "=", "Internal", "+", "163", ";", "int", "InvalidVoidExpression", "=", "Internal", "+", "164", ";", "int", "MaskedCatch", "=", "TypeRelated", "+", "165", ";", "int", "DuplicateDefaultCase", "=", "Internal", "+", "166", ";", "int", "UnreachableCatch", "=", "TypeRelated", "+", "MethodRelated", "+", "167", ";", "int", "UnhandledException", "=", "TypeRelated", "+", "168", ";", "int", "IncorrectSwitchType", "=", "TypeRelated", "+", "169", ";", "int", "DuplicateCase", "=", "FieldRelated", "+", "170", ";", "int", "DuplicateLabel", "=", "Internal", "+", "171", ";", "int", "InvalidBreak", "=", "Internal", "+", "172", ";", "int", "InvalidContinue", "=", "Internal", "+", "173", ";", "int", "UndefinedLabel", "=", "Internal", "+", "174", ";", "int", "InvalidTypeToSynchronized", "=", "Internal", "+", "175", ";", "int", "InvalidNullToSynchronized", "=", "Internal", "+", "176", ";", "int", "CannotThrowNull", "=", "Internal", "+", "177", ";", "int", "AssignmentHasNoEffect", "=", "Internal", "+", "178", ";", "int", "PossibleAccidentalBooleanAssignment", "=", "Internal", "+", "179", ";", "int", "SuperfluousSemicolon", "=", "Internal", "+", "180", ";", "int", "UnnecessaryCast", "=", "Internal", "+", "TypeRelated", "+", "181", ";", "int", "UnnecessaryArgumentCast", "=", "Internal", "+", "TypeRelated", "+", "182", ";", "int", "UnnecessaryInstanceof", "=", "Internal", "+", "TypeRelated", "+", "183", ";", "int", "FinallyMustCompleteNormally", "=", "Internal", "+", "184", ";", "int", "UnusedMethodDeclaredThrownException", "=", "Internal", "+", "185", ";", "int", "UnusedConstructorDeclaredThrownException", "=", "Internal", "+", "186", ";", "int", "InvalidCatchBlockSequence", "=", "Internal", "+", "TypeRelated", "+", "187", ";", "int", "EmptyControlFlowStatement", "=", "Internal", "+", "TypeRelated", "+", "188", ";", "int", "UnnecessaryElse", "=", "Internal", "+", "189", ";", "int", "NeedToEmulateFieldReadAccess", "=", "FieldRelated", "+", "190", ";", "int", "NeedToEmulateFieldWriteAccess", "=", "FieldRelated", "+", "191", ";", "int", "NeedToEmulateMethodAccess", "=", "MethodRelated", "+", "192", ";", "int", "NeedToEmulateConstructorAccess", "=", "MethodRelated", "+", "193", ";", "int", "FallthroughCase", "=", "Internal", "+", "194", ";", "int", "InheritedMethodHidesEnclosingName", "=", "MethodRelated", "+", "195", ";", "int", "InheritedFieldHidesEnclosingName", "=", "FieldRelated", "+", "196", ";", "int", "InheritedTypeHidesEnclosingName", "=", "TypeRelated", "+", "197", ";", "int", "IllegalUsageOfQualifiedTypeReference", "=", "Internal", "+", "Syntax", "+", "198", ";", "int", "UnusedLabel", "=", "Internal", "+", "199", ";", "int", "ThisInStaticContext", "=", "Internal", "+", "200", ";", "int", "StaticMethodRequested", "=", "Internal", "+", "MethodRelated", "+", "201", ";", "int", "IllegalDimension", "=", "Internal", "+", "202", ";", "int", "InvalidTypeExpression", "=", "Internal", "+", "203", ";", "int", "ParsingError", "=", "Syntax", "+", "Internal", "+", "204", ";", "int", "ParsingErrorNoSuggestion", "=", "Syntax", "+", "Internal", "+", "205", ";", "int", "InvalidUnaryExpression", "=", "Syntax", "+", "Internal", "+", "206", ";", "int", "InterfaceCannotHaveConstructors", "=", "Syntax", "+", "Internal", "+", "207", ";", "int", "ArrayConstantsOnlyInArrayInitializers", "=", "Syntax", "+", "Internal", "+", "208", ";", "int", "ParsingErrorOnKeyword", "=", "Syntax", "+", "Internal", "+", "209", ";", "int", "ParsingErrorOnKeywordNoSuggestion", "=", "Syntax", "+", "Internal", "+", "210", ";", "int", "ComparingIdentical", "=", "Internal", "+", "211", ";", "int", "UnmatchedBracket", "=", "Syntax", "+", "Internal", "+", "220", ";", "int", "NoFieldOnBaseType", "=", "FieldRelated", "+", "221", ";", "int", "InvalidExpressionAsStatement", "=", "Syntax", "+", "Internal", "+", "222", ";", "int", "ExpressionShouldBeAVariable", "=", "Syntax", "+", "Internal", "+", "223", ";", "int", "MissingSemiColon", "=", "Syntax", "+", "Internal", "+", "224", ";", "int", "InvalidParenthesizedExpression", "=", "Syntax", "+", "Internal", "+", "225", ";", "int", "ParsingErrorInsertTokenBefore", "=", "Syntax", "+", "Internal", "+", "230", ";", "int", "ParsingErrorInsertTokenAfter", "=", "Syntax", "+", "Internal", "+", "231", ";", "int", "ParsingErrorDeleteToken", "=", "Syntax", "+", "Internal", "+", "232", ";", "int", "ParsingErrorDeleteTokens", "=", "Syntax", "+", "Internal", "+", "233", ";", "int", "ParsingErrorMergeTokens", "=", "Syntax", "+", "Internal", "+", "234", ";", "int", "ParsingErrorInvalidToken", "=", "Syntax", "+", "Internal", "+", "235", ";", "int", "ParsingErrorMisplacedConstruct", "=", "Syntax", "+", "Internal", "+", "236", ";", "int", "ParsingErrorReplaceTokens", "=", "Syntax", "+", "Internal", "+", "237", ";", "int", "ParsingErrorNoSuggestionForTokens", "=", "Syntax", "+", "Internal", "+", "238", ";", "int", "ParsingErrorUnexpectedEOF", "=", "Syntax", "+", "Internal", "+", "239", ";", "int", "ParsingErrorInsertToComplete", "=", "Syntax", "+", "Internal", "+", "240", ";", "int", "ParsingErrorInsertToCompleteScope", "=", "Syntax", "+", "Internal", "+", "241", ";", "int", "ParsingErrorInsertToCompletePhrase", "=", "Syntax", "+", "Internal", "+", "242", ";", "int", "EndOfSource", "=", "Syntax", "+", "Internal", "+", "250", ";", "int", "InvalidHexa", "=", "Syntax", "+", "Internal", "+", "251", ";", "int", "InvalidOctal", "=", "Syntax", "+", "Internal", "+", "252", ";", "int", "InvalidCharacterConstant", "=", "Syntax", "+", "Internal", "+", "253", ";", "int", "InvalidEscape", "=", "Syntax", "+", "Internal", "+", "254", ";", "int", "InvalidInput", "=", "Syntax", "+", "Internal", "+", "255", ";", "int", "InvalidUnicodeEscape", "=", "Syntax", "+", "Internal", "+", "256", ";", "int", "InvalidFloat", "=", "Syntax", "+", "Internal", "+", "257", ";", "int", "NullSourceString", "=", "Syntax", "+", "Internal", "+", "258", ";", "int", "UnterminatedString", "=", "Syntax", "+", "Internal", "+", "259", ";", "int", "UnterminatedComment", "=", "Syntax", "+", "Internal", "+", "260", ";", "int", "NonExternalizedStringLiteral", "=", "Internal", "+", "261", ";", "int", "InvalidDigit", "=", "Syntax", "+", "Internal", "+", "262", ";", "int", "InvalidLowSurrogate", "=", "Syntax", "+", "Internal", "+", "263", ";", "int", "InvalidHighSurrogate", "=", "Syntax", "+", "Internal", "+", "264", ";", "int", "UnnecessaryNLSTag", "=", "Internal", "+", "265", ";", "int", "DiscouragedReference", "=", "TypeRelated", "+", "280", ";", "int", "InterfaceCannotHaveInitializers", "=", "TypeRelated", "+", "300", ";", "int", "DuplicateModifierForType", "=", "TypeRelated", "+", "301", ";", "int", "IllegalModifierForClass", "=", "TypeRelated", "+", "302", ";", "int", "IllegalModifierForInterface", "=", "TypeRelated", "+", "303", ";", "int", "IllegalModifierForMemberClass", "=", "TypeRelated", "+", "304", ";", "int", "IllegalModifierForMemberInterface", "=", "TypeRelated", "+", "305", ";", "int", "IllegalModifierForLocalClass", "=", "TypeRelated", "+", "306", ";", "int", "ForbiddenReference", "=", "TypeRelated", "+", "307", ";", "int", "IllegalModifierCombinationFinalAbstractForClass", "=", "TypeRelated", "+", "308", ";", "int", "IllegalVisibilityModifierForInterfaceMemberType", "=", "TypeRelated", "+", "309", ";", "int", "IllegalVisibilityModifierCombinationForMemberType", "=", "TypeRelated", "+", "310", ";", "int", "IllegalStaticModifierForMemberType", "=", "TypeRelated", "+", "311", ";", "int", "SuperclassMustBeAClass", "=", "TypeRelated", "+", "312", ";", "int", "ClassExtendFinalClass", "=", "TypeRelated", "+", "313", ";", "int", "DuplicateSuperInterface", "=", "TypeRelated", "+", "314", ";", "int", "SuperInterfaceMustBeAnInterface", "=", "TypeRelated", "+", "315", ";", "int", "HierarchyCircularitySelfReference", "=", "TypeRelated", "+", "316", ";", "int", "HierarchyCircularity", "=", "TypeRelated", "+", "317", ";", "int", "HidingEnclosingType", "=", "TypeRelated", "+", "318", ";", "int", "DuplicateNestedType", "=", "TypeRelated", "+", "319", ";", "int", "CannotThrowType", "=", "TypeRelated", "+", "320", ";", "int", "PackageCollidesWithType", "=", "TypeRelated", "+", "321", ";", "int", "TypeCollidesWithPackage", "=", "TypeRelated", "+", "322", ";", "int", "DuplicateTypes", "=", "TypeRelated", "+", "323", ";", "int", "IsClassPathCorrect", "=", "TypeRelated", "+", "324", ";", "int", "PublicClassMustMatchFileName", "=", "TypeRelated", "+", "325", ";", "int", "MustSpecifyPackage", "=", "Internal", "+", "326", ";", "int", "HierarchyHasProblems", "=", "TypeRelated", "+", "327", ";", "int", "PackageIsNotExpectedPackage", "=", "Internal", "+", "328", ";", "int", "ObjectCannotHaveSuperTypes", "=", "Internal", "+", "329", ";", "int", "ObjectMustBeClass", "=", "Internal", "+", "330", ";", "int", "RedundantSuperinterface", "=", "TypeRelated", "+", "331", ";", "int", "ShouldImplementHashcode", "=", "TypeRelated", "+", "332", ";", "int", "AbstractMethodsInConcreteClass", "=", "TypeRelated", "+", "333", ";", "int", "SuperclassNotFound", "=", "TypeRelated", "+", "329", "+", "ProblemReasons", ".", "NotFound", ";", "int", "SuperclassNotVisible", "=", "TypeRelated", "+", "329", "+", "ProblemReasons", ".", "NotVisible", ";", "int", "SuperclassAmbiguous", "=", "TypeRelated", "+", "329", "+", "ProblemReasons", ".", "Ambiguous", ";", "int", "SuperclassInternalNameProvided", "=", "TypeRelated", "+", "329", "+", "ProblemReasons", ".", "InternalNameProvided", ";", "int", "SuperclassInheritedNameHidesEnclosingName", "=", "TypeRelated", "+", "329", "+", "ProblemReasons", ".", "InheritedNameHidesEnclosingName", ";", "int", "InterfaceNotFound", "=", "TypeRelated", "+", "334", "+", "ProblemReasons", ".", "NotFound", ";", "int", "InterfaceNotVisible", "=", "TypeRelated", "+", "334", "+", "ProblemReasons", ".", "NotVisible", ";", "int", "InterfaceAmbiguous", "=", "TypeRelated", "+", "334", "+", "ProblemReasons", ".", "Ambiguous", ";", "int", "InterfaceInternalNameProvided", "=", "TypeRelated", "+", "334", "+", "ProblemReasons", ".", "InternalNameProvided", ";", "int", "InterfaceInheritedNameHidesEnclosingName", "=", "TypeRelated", "+", "334", "+", "ProblemReasons", ".", "InheritedNameHidesEnclosingName", ";", "int", "DuplicateField", "=", "FieldRelated", "+", "340", ";", "int", "DuplicateModifierForField", "=", "FieldRelated", "+", "341", ";", "int", "IllegalModifierForField", "=", "FieldRelated", "+", "342", ";", "int", "IllegalModifierForInterfaceField", "=", "FieldRelated", "+", "343", ";", "int", "IllegalVisibilityModifierCombinationForField", "=", "FieldRelated", "+", "344", ";", "int", "IllegalModifierCombinationFinalVolatileForField", "=", "FieldRelated", "+", "345", ";", "int", "UnexpectedStaticModifierForField", "=", "FieldRelated", "+", "346", ";", "int", "FieldTypeNotFound", "=", "FieldRelated", "+", "349", "+", "ProblemReasons", ".", "NotFound", ";", "int", "FieldTypeNotVisible", "=", "FieldRelated", "+", "349", "+", "ProblemReasons", ".", "NotVisible", ";", "int", "FieldTypeAmbiguous", "=", "FieldRelated", "+", "349", "+", "ProblemReasons", ".", "Ambiguous", ";", "int", "FieldTypeInternalNameProvided", "=", "FieldRelated", "+", "349", "+", "ProblemReasons", ".", "InternalNameProvided", ";", "int", "FieldTypeInheritedNameHidesEnclosingName", "=", "FieldRelated", "+", "349", "+", "ProblemReasons", ".", "InheritedNameHidesEnclosingName", ";", "int", "DuplicateMethod", "=", "MethodRelated", "+", "355", ";", "int", "IllegalModifierForArgument", "=", "MethodRelated", "+", "356", ";", "int", "DuplicateModifierForMethod", "=", "MethodRelated", "+", "357", ";", "int", "IllegalModifierForMethod", "=", "MethodRelated", "+", "358", ";", "int", "IllegalModifierForInterfaceMethod", "=", "MethodRelated", "+", "359", ";", "int", "IllegalVisibilityModifierCombinationForMethod", "=", "MethodRelated", "+", "360", ";", "int", "UnexpectedStaticModifierForMethod", "=", "MethodRelated", "+", "361", ";", "int", "IllegalAbstractModifierCombinationForMethod", "=", "MethodRelated", "+", "362", ";", "int", "AbstractMethodInAbstractClass", "=", "MethodRelated", "+", "363", ";", "int", "ArgumentTypeCannotBeVoid", "=", "MethodRelated", "+", "364", ";", "int", "ArgumentTypeCannotBeVoidArray", "=", "MethodRelated", "+", "365", ";", "int", "ReturnTypeCannotBeVoidArray", "=", "MethodRelated", "+", "366", ";", "int", "NativeMethodsCannotBeStrictfp", "=", "MethodRelated", "+", "367", ";", "int", "DuplicateModifierForArgument", "=", "MethodRelated", "+", "368", ";", "int", "IllegalModifierForConstructor", "=", "MethodRelated", "+", "369", ";", "int", "ArgumentTypeNotFound", "=", "MethodRelated", "+", "369", "+", "ProblemReasons", ".", "NotFound", ";", "int", "ArgumentTypeNotVisible", "=", "MethodRelated", "+", "369", "+", "ProblemReasons", ".", "NotVisible", ";", "int", "ArgumentTypeAmbiguous", "=", "MethodRelated", "+", "369", "+", "ProblemReasons", ".", "Ambiguous", ";", "int", "ArgumentTypeInternalNameProvided", "=", "MethodRelated", "+", "369", "+", "ProblemReasons", ".", "InternalNameProvided", ";", "int", "ArgumentTypeInheritedNameHidesEnclosingName", "=", "MethodRelated", "+", "369", "+", "ProblemReasons", ".", "InheritedNameHidesEnclosingName", ";", "int", "ExceptionTypeNotFound", "=", "MethodRelated", "+", "374", "+", "ProblemReasons", ".", "NotFound", ";", "int", "ExceptionTypeNotVisible", "=", "MethodRelated", "+", "374", "+", "ProblemReasons", ".", "NotVisible", ";", "int", "ExceptionTypeAmbiguous", "=", "MethodRelated", "+", "374", "+", "ProblemReasons", ".", "Ambiguous", ";", "int", "ExceptionTypeInternalNameProvided", "=", "MethodRelated", "+", "374", "+", "ProblemReasons", ".", "InternalNameProvided", ";", "int", "ExceptionTypeInheritedNameHidesEnclosingName", "=", "MethodRelated", "+", "374", "+", "ProblemReasons", ".", "InheritedNameHidesEnclosingName", ";", "int", "ReturnTypeNotFound", "=", "MethodRelated", "+", "379", "+", "ProblemReasons", ".", "NotFound", ";", "int", "ReturnTypeNotVisible", "=", "MethodRelated", "+", "379", "+", "ProblemReasons", ".", "NotVisible", ";", "int", "ReturnTypeAmbiguous", "=", "MethodRelated", "+", "379", "+", "ProblemReasons", ".", "Ambiguous", ";", "int", "ReturnTypeInternalNameProvided", "=", "MethodRelated", "+", "379", "+", "ProblemReasons", ".", "InternalNameProvided", ";", "int", "ReturnTypeInheritedNameHidesEnclosingName", "=", "MethodRelated", "+", "379", "+", "ProblemReasons", ".", "InheritedNameHidesEnclosingName", ";", "int", "ConflictingImport", "=", "ImportRelated", "+", "385", ";", "int", "DuplicateImport", "=", "ImportRelated", "+", "386", ";", "int", "CannotImportPackage", "=", "ImportRelated", "+", "387", ";", "int", "UnusedImport", "=", "ImportRelated", "+", "388", ";", "int", "ImportNotFound", "=", "ImportRelated", "+", "389", "+", "ProblemReasons", ".", "NotFound", ";", "int", "ImportNotVisible", "=", "ImportRelated", "+", "389", "+", "ProblemReasons", ".", "NotVisible", ";", "int", "ImportAmbiguous", "=", "ImportRelated", "+", "389", "+", "ProblemReasons", ".", "Ambiguous", ";", "int", "ImportInternalNameProvided", "=", "ImportRelated", "+", "389", "+", "ProblemReasons", ".", "InternalNameProvided", ";", "int", "ImportInheritedNameHidesEnclosingName", "=", "ImportRelated", "+", "389", "+", "ProblemReasons", ".", "InheritedNameHidesEnclosingName", ";", "int", "InvalidTypeForStaticImport", "=", "ImportRelated", "+", "391", ";", "int", "DuplicateModifierForVariable", "=", "MethodRelated", "+", "395", ";", "int", "IllegalModifierForVariable", "=", "MethodRelated", "+", "396", ";", "int", "LocalVariableCannotBeNull", "=", "Internal", "+", "397", ";", "int", "LocalVariableCanOnlyBeNull", "=", "Internal", "+", "398", ";", "int", "LocalVariableMayBeNull", "=", "Internal", "+", "399", ";", "int", "AbstractMethodMustBeImplemented", "=", "MethodRelated", "+", "400", ";", "int", "FinalMethodCannotBeOverridden", "=", "MethodRelated", "+", "401", ";", "int", "IncompatibleExceptionInThrowsClause", "=", "MethodRelated", "+", "402", ";", "int", "IncompatibleExceptionInInheritedMethodThrowsClause", "=", "MethodRelated", "+", "403", ";", "int", "IncompatibleReturnType", "=", "MethodRelated", "+", "404", ";", "int", "InheritedMethodReducesVisibility", "=", "MethodRelated", "+", "405", ";", "int", "CannotOverrideAStaticMethodWithAnInstanceMethod", "=", "MethodRelated", "+", "406", ";", "int", "CannotHideAnInstanceMethodWithAStaticMethod", "=", "MethodRelated", "+", "407", ";", "int", "StaticInheritedMethodConflicts", "=", "MethodRelated", "+", "408", ";", "int", "MethodReducesVisibility", "=", "MethodRelated", "+", "409", ";", "int", "OverridingNonVisibleMethod", "=", "MethodRelated", "+", "410", ";", "int", "AbstractMethodCannotBeOverridden", "=", "MethodRelated", "+", "411", ";", "int", "OverridingDeprecatedMethod", "=", "MethodRelated", "+", "412", ";", "int", "IncompatibleReturnTypeForNonInheritedInterfaceMethod", "=", "MethodRelated", "+", "413", ";", "int", "IncompatibleExceptionInThrowsClauseForNonInheritedInterfaceMethod", "=", "MethodRelated", "+", "414", ";", "int", "IllegalVararg", "=", "MethodRelated", "+", "415", ";", "int", "OverridingMethodWithoutSuperInvocation", "=", "MethodRelated", "+", "416", ";", "int", "MissingSynchronizedModifierInInheritedMethod", "=", "MethodRelated", "+", "417", ";", "int", "AbstractMethodMustBeImplementedOverConcreteMethod", "=", "MethodRelated", "+", "418", ";", "int", "InheritedIncompatibleReturnType", "=", "MethodRelated", "+", "419", ";", "int", "CodeSnippetMissingClass", "=", "Internal", "+", "420", ";", "int", "CodeSnippetMissingMethod", "=", "Internal", "+", "421", ";", "int", "CannotUseSuperInCodeSnippet", "=", "Internal", "+", "422", ";", "int", "TooManyConstantsInConstantPool", "=", "Internal", "+", "430", ";", "int", "TooManyBytesForStringConstant", "=", "Internal", "+", "431", ";", "int", "TooManyFields", "=", "Internal", "+", "432", ";", "int", "TooManyMethods", "=", "Internal", "+", "433", ";", "int", "UseAssertAsAnIdentifier", "=", "Internal", "+", "440", ";", "int", "UseEnumAsAnIdentifier", "=", "Internal", "+", "441", ";", "int", "EnumConstantsCannotBeSurroundedByParenthesis", "=", "Syntax", "+", "Internal", "+", "442", ";", "int", "Task", "=", "Internal", "+", "450", ";", "int", "NullLocalVariableReference", "=", "Internal", "+", "451", ";", "int", "PotentialNullLocalVariableReference", "=", "Internal", "+", "452", ";", "int", "RedundantNullCheckOnNullLocalVariable", "=", "Internal", "+", "453", ";", "int", "NullLocalVariableComparisonYieldsFalse", "=", "Internal", "+", "454", ";", "int", "RedundantLocalVariableNullAssignment", "=", "Internal", "+", "455", ";", "int", "NullLocalVariableInstanceofYieldsFalse", "=", "Internal", "+", "456", ";", "int", "RedundantNullCheckOnNonNullLocalVariable", "=", "Internal", "+", "457", ";", "int", "NonNullLocalVariableComparisonYieldsFalse", "=", "Internal", "+", "458", ";", "int", "UndocumentedEmptyBlock", "=", "Internal", "+", "460", ";", "int", "JavadocInvalidSeeUrlReference", "=", "Javadoc", "+", "Internal", "+", "462", ";", "int", "JavadocMissingTagDescription", "=", "Javadoc", "+", "Internal", "+", "463", ";", "int", "JavadocDuplicateTag", "=", "Javadoc", "+", "Internal", "+", "464", ";", "int", "JavadocHiddenReference", "=", "Javadoc", "+", "Internal", "+", "465", ";", "int", "JavadocInvalidMemberTypeQualification", "=", "Javadoc", "+", "Internal", "+", "466", ";", "int", "JavadocMissingIdentifier", "=", "Javadoc", "+", "Internal", "+", "467", ";", "int", "JavadocNonStaticTypeFromStaticInvocation", "=", "Javadoc", "+", "Internal", "+", "468", ";", "int", "JavadocInvalidParamTagTypeParameter", "=", "Javadoc", "+", "Internal", "+", "469", ";", "int", "JavadocUnexpectedTag", "=", "Javadoc", "+", "Internal", "+", "470", ";", "int", "JavadocMissingParamTag", "=", "Javadoc", "+", "Internal", "+", "471", ";", "int", "JavadocMissingParamName", "=", "Javadoc", "+", "Internal", "+", "472", ";", "int", "JavadocDuplicateParamName", "=", "Javadoc", "+", "Internal", "+", "473", ";", "int", "JavadocInvalidParamName", "=", "Javadoc", "+", "Internal", "+", "474", ";", "int", "JavadocMissingReturnTag", "=", "Javadoc", "+", "Internal", "+", "475", ";", "int", "JavadocDuplicateReturnTag", "=", "Javadoc", "+", "Internal", "+", "476", ";", "int", "JavadocMissingThrowsTag", "=", "Javadoc", "+", "Internal", "+", "477", ";", "int", "JavadocMissingThrowsClassName", "=", "Javadoc", "+", "Internal", "+", "478", ";", "int", "JavadocInvalidThrowsClass", "=", "Javadoc", "+", "Internal", "+", "479", ";", "int", "JavadocDuplicateThrowsClassName", "=", "Javadoc", "+", "Internal", "+", "480", ";", "int", "JavadocInvalidThrowsClassName", "=", "Javadoc", "+", "Internal", "+", "481", ";", "int", "JavadocMissingSeeReference", "=", "Javadoc", "+", "Internal", "+", "482", ";", "int", "JavadocInvalidSeeReference", "=", "Javadoc", "+", "Internal", "+", "483", ";", "int", "JavadocInvalidSeeHref", "=", "Javadoc", "+", "Internal", "+", "484", ";", "int", "JavadocInvalidSeeArgs", "=", "Javadoc", "+", "Internal", "+", "485", ";", "int", "JavadocMissing", "=", "Javadoc", "+", "Internal", "+", "486", ";", "int", "JavadocInvalidTag", "=", "Javadoc", "+", "Internal", "+", "487", ";", "int", "JavadocUndefinedField", "=", "Javadoc", "+", "Internal", "+", "488", ";", "int", "JavadocNotVisibleField", "=", "Javadoc", "+", "Internal", "+", "489", ";", "int", "JavadocAmbiguousField", "=", "Javadoc", "+", "Internal", "+", "490", ";", "int", "JavadocUsingDeprecatedField", "=", "Javadoc", "+", "Internal", "+", "491", ";", "int", "JavadocUndefinedConstructor", "=", "Javadoc", "+", "Internal", "+", "492", ";", "int", "JavadocNotVisibleConstructor", "=", "Javadoc", "+", "Internal", "+", "493", ";", "int", "JavadocAmbiguousConstructor", "=", "Javadoc", "+", "Internal", "+", "494", ";", "int", "JavadocUsingDeprecatedConstructor", "=", "Javadoc", "+", "Internal", "+", "495", ";", "int", "JavadocUndefinedMethod", "=", "Javadoc", "+", "Internal", "+", "496", ";", "int", "JavadocNotVisibleMethod", "=", "Javadoc", "+", "Internal", "+", "497", ";", "int", "JavadocAmbiguousMethod", "=", "Javadoc", "+", "Internal", "+", "498", ";", "int", "JavadocUsingDeprecatedMethod", "=", "Javadoc", "+", "Internal", "+", "499", ";", "int", "JavadocNoMessageSendOnBaseType", "=", "Javadoc", "+", "Internal", "+", "500", ";", "int", "JavadocParameterMismatch", "=", "Javadoc", "+", "Internal", "+", "501", ";", "int", "JavadocNoMessageSendOnArrayType", "=", "Javadoc", "+", "Internal", "+", "502", ";", "int", "JavadocUndefinedType", "=", "Javadoc", "+", "Internal", "+", "503", ";", "int", "JavadocNotVisibleType", "=", "Javadoc", "+", "Internal", "+", "504", ";", "int", "JavadocAmbiguousType", "=", "Javadoc", "+", "Internal", "+", "505", ";", "int", "JavadocUsingDeprecatedType", "=", "Javadoc", "+", "Internal", "+", "506", ";", "int", "JavadocInternalTypeNameProvided", "=", "Javadoc", "+", "Internal", "+", "507", ";", "int", "JavadocInheritedMethodHidesEnclosingName", "=", "Javadoc", "+", "Internal", "+", "508", ";", "int", "JavadocInheritedFieldHidesEnclosingName", "=", "Javadoc", "+", "Internal", "+", "509", ";", "int", "JavadocInheritedNameHidesEnclosingTypeName", "=", "Javadoc", "+", "Internal", "+", "510", ";", "int", "JavadocAmbiguousMethodReference", "=", "Javadoc", "+", "Internal", "+", "511", ";", "int", "JavadocUnterminatedInlineTag", "=", "Javadoc", "+", "Internal", "+", "512", ";", "int", "JavadocMalformedSeeReference", "=", "Javadoc", "+", "Internal", "+", "513", ";", "int", "JavadocMessagePrefix", "=", "Internal", "+", "514", ";", "int", "JavadocMissingHashCharacter", "=", "Javadoc", "+", "Internal", "+", "515", ";", "int", "JavadocEmptyReturnTag", "=", "Javadoc", "+", "Internal", "+", "516", ";", "int", "JavadocInvalidValueReference", "=", "Javadoc", "+", "Internal", "+", "517", ";", "int", "JavadocUnexpectedText", "=", "Javadoc", "+", "Internal", "+", "518", ";", "int", "JavadocInvalidParamTagName", "=", "Javadoc", "+", "Internal", "+", "519", ";", "int", "DuplicateTypeVariable", "=", "Internal", "+", "520", ";", "int", "IllegalTypeVariableSuperReference", "=", "Internal", "+", "521", ";", "int", "NonStaticTypeFromStaticInvocation", "=", "Internal", "+", "522", ";", "int", "ObjectCannotBeGeneric", "=", "Internal", "+", "523", ";", "int", "NonGenericType", "=", "TypeRelated", "+", "524", ";", "int", "IncorrectArityForParameterizedType", "=", "TypeRelated", "+", "525", ";", "int", "TypeArgumentMismatch", "=", "TypeRelated", "+", "526", ";", "int", "DuplicateMethodErasure", "=", "TypeRelated", "+", "527", ";", "int", "ReferenceToForwardTypeVariable", "=", "TypeRelated", "+", "528", ";", "int", "BoundMustBeAnInterface", "=", "TypeRelated", "+", "529", ";", "int", "UnsafeRawConstructorInvocation", "=", "TypeRelated", "+", "530", ";", "int", "UnsafeRawMethodInvocation", "=", "TypeRelated", "+", "531", ";", "int", "UnsafeTypeConversion", "=", "TypeRelated", "+", "532", ";", "int", "InvalidTypeVariableExceptionType", "=", "TypeRelated", "+", "533", ";", "int", "InvalidParameterizedExceptionType", "=", "TypeRelated", "+", "534", ";", "int", "IllegalGenericArray", "=", "TypeRelated", "+", "535", ";", "int", "UnsafeRawFieldAssignment", "=", "TypeRelated", "+", "536", ";", "int", "FinalBoundForTypeVariable", "=", "TypeRelated", "+", "537", ";", "int", "UndefinedTypeVariable", "=", "Internal", "+", "538", ";", "int", "SuperInterfacesCollide", "=", "TypeRelated", "+", "539", ";", "int", "WildcardConstructorInvocation", "=", "TypeRelated", "+", "540", ";", "int", "WildcardMethodInvocation", "=", "TypeRelated", "+", "541", ";", "int", "WildcardFieldAssignment", "=", "TypeRelated", "+", "542", ";", "int", "GenericMethodTypeArgumentMismatch", "=", "TypeRelated", "+", "543", ";", "int", "GenericConstructorTypeArgumentMismatch", "=", "TypeRelated", "+", "544", ";", "int", "UnsafeGenericCast", "=", "TypeRelated", "+", "545", ";", "int", "IllegalInstanceofParameterizedType", "=", "Internal", "+", "546", ";", "int", "IllegalInstanceofTypeParameter", "=", "Internal", "+", "547", ";", "int", "NonGenericMethod", "=", "TypeRelated", "+", "548", ";", "int", "IncorrectArityForParameterizedMethod", "=", "TypeRelated", "+", "549", ";", "int", "ParameterizedMethodArgumentTypeMismatch", "=", "TypeRelated", "+", "550", ";", "int", "NonGenericConstructor", "=", "TypeRelated", "+", "551", ";", "int", "IncorrectArityForParameterizedConstructor", "=", "TypeRelated", "+", "552", ";", "int", "ParameterizedConstructorArgumentTypeMismatch", "=", "TypeRelated", "+", "553", ";", "int", "TypeArgumentsForRawGenericMethod", "=", "TypeRelated", "+", "554", ";", "int", "TypeArgumentsForRawGenericConstructor", "=", "TypeRelated", "+", "555", ";", "int", "SuperTypeUsingWildcard", "=", "TypeRelated", "+", "556", ";", "int", "GenericTypeCannotExtendThrowable", "=", "TypeRelated", "+", "557", ";", "int", "IllegalClassLiteralForTypeVariable", "=", "TypeRelated", "+", "558", ";", "int", "UnsafeReturnTypeOverride", "=", "MethodRelated", "+", "559", ";", "int", "MethodNameClash", "=", "MethodRelated", "+", "560", ";", "int", "RawMemberTypeCannotBeParameterized", "=", "TypeRelated", "+", "561", ";", "int", "MissingArgumentsForParameterizedMemberType", "=", "TypeRelated", "+", "562", ";", "int", "StaticMemberOfParameterizedType", "=", "TypeRelated", "+", "563", ";", "int", "BoundHasConflictingArguments", "=", "TypeRelated", "+", "564", ";", "int", "DuplicateParameterizedMethods", "=", "MethodRelated", "+", "565", ";", "int", "IllegalQualifiedParameterizedTypeAllocation", "=", "TypeRelated", "+", "566", ";", "int", "DuplicateBounds", "=", "TypeRelated", "+", "567", ";", "int", "BoundCannotBeArray", "=", "TypeRelated", "+", "568", ";", "int", "UnsafeRawGenericConstructorInvocation", "=", "TypeRelated", "+", "569", ";", "int", "UnsafeRawGenericMethodInvocation", "=", "TypeRelated", "+", "570", ";", "int", "TypeParameterHidingType", "=", "TypeRelated", "+", "571", ";", "int", "RawTypeReference", "=", "TypeRelated", "+", "572", ";", "int", "NoAdditionalBoundAfterTypeVariable", "=", "TypeRelated", "+", "573", ";", "int", "UnsafeGenericArrayForVarargs", "=", "MethodRelated", "+", "574", ";", "int", "IllegalAccessFromTypeVariable", "=", "TypeRelated", "+", "575", ";", "int", "TypeHidingTypeParameterFromType", "=", "TypeRelated", "+", "576", ";", "int", "TypeHidingTypeParameterFromMethod", "=", "TypeRelated", "+", "577", ";", "int", "InvalidUsageOfWildcard", "=", "Syntax", "+", "Internal", "+", "578", ";", "int", "UnusedTypeArgumentsForMethodInvocation", "=", "MethodRelated", "+", "579", ";", "int", "IncompatibleTypesInForeach", "=", "TypeRelated", "+", "580", ";", "int", "InvalidTypeForCollection", "=", "Internal", "+", "581", ";", "int", "InvalidTypeForCollectionTarget14", "=", "Internal", "+", "582", ";", "int", "InvalidUsageOfTypeParameters", "=", "Syntax", "+", "Internal", "+", "590", ";", "int", "InvalidUsageOfStaticImports", "=", "Syntax", "+", "Internal", "+", "591", ";", "int", "InvalidUsageOfForeachStatements", "=", "Syntax", "+", "Internal", "+", "592", ";", "int", "InvalidUsageOfTypeArguments", "=", "Syntax", "+", "Internal", "+", "593", ";", "int", "InvalidUsageOfEnumDeclarations", "=", "Syntax", "+", "Internal", "+", "594", ";", "int", "InvalidUsageOfVarargs", "=", "Syntax", "+", "Internal", "+", "595", ";", "int", "InvalidUsageOfAnnotations", "=", "Syntax", "+", "Internal", "+", "596", ";", "int", "InvalidUsageOfAnnotationDeclarations", "=", "Syntax", "+", "Internal", "+", "597", ";", "int", "InvalidUsageOfTypeParametersForAnnotationDeclaration", "=", "Syntax", "+", "Internal", "+", "598", ";", "int", "InvalidUsageOfTypeParametersForEnumDeclaration", "=", "Syntax", "+", "Internal", "+", "599", ";", "int", "IllegalModifierForAnnotationMethod", "=", "MethodRelated", "+", "600", ";", "int", "IllegalExtendedDimensions", "=", "MethodRelated", "+", "601", ";", "int", "InvalidFileNameForPackageAnnotations", "=", "Syntax", "+", "Internal", "+", "602", ";", "int", "IllegalModifierForAnnotationType", "=", "TypeRelated", "+", "603", ";", "int", "IllegalModifierForAnnotationMemberType", "=", "TypeRelated", "+", "604", ";", "int", "InvalidAnnotationMemberType", "=", "TypeRelated", "+", "605", ";", "int", "AnnotationCircularitySelfReference", "=", "TypeRelated", "+", "606", ";", "int", "AnnotationCircularity", "=", "TypeRelated", "+", "607", ";", "int", "DuplicateAnnotation", "=", "TypeRelated", "+", "608", ";", "int", "MissingValueForAnnotationMember", "=", "TypeRelated", "+", "609", ";", "int", "DuplicateAnnotationMember", "=", "Internal", "+", "610", ";", "int", "UndefinedAnnotationMember", "=", "MethodRelated", "+", "611", ";", "int", "AnnotationValueMustBeClassLiteral", "=", "Internal", "+", "612", ";", "int", "AnnotationValueMustBeConstant", "=", "Internal", "+", "613", ";", "int", "AnnotationFieldNeedConstantInitialization", "=", "Internal", "+", "614", ";", "int", "IllegalModifierForAnnotationField", "=", "Internal", "+", "615", ";", "int", "AnnotationCannotOverrideMethod", "=", "MethodRelated", "+", "616", ";", "int", "AnnotationMembersCannotHaveParameters", "=", "Syntax", "+", "Internal", "+", "617", ";", "int", "AnnotationMembersCannotHaveTypeParameters", "=", "Syntax", "+", "Internal", "+", "618", ";", "int", "AnnotationTypeDeclarationCannotHaveSuperclass", "=", "Syntax", "+", "Internal", "+", "619", ";", "int", "AnnotationTypeDeclarationCannotHaveSuperinterfaces", "=", "Syntax", "+", "Internal", "+", "620", ";", "int", "DuplicateTargetInTargetAnnotation", "=", "Internal", "+", "621", ";", "int", "DisallowedTargetForAnnotation", "=", "TypeRelated", "+", "622", ";", "int", "MethodMustOverride", "=", "MethodRelated", "+", "623", ";", "int", "AnnotationTypeDeclarationCannotHaveConstructor", "=", "Syntax", "+", "Internal", "+", "624", ";", "int", "AnnotationValueMustBeAnnotation", "=", "Internal", "+", "625", ";", "int", "AnnotationTypeUsedAsSuperInterface", "=", "TypeRelated", "+", "626", ";", "int", "MissingOverrideAnnotation", "=", "MethodRelated", "+", "627", ";", "int", "FieldMissingDeprecatedAnnotation", "=", "Internal", "+", "628", ";", "int", "MethodMissingDeprecatedAnnotation", "=", "Internal", "+", "629", ";", "int", "TypeMissingDeprecatedAnnotation", "=", "Internal", "+", "630", ";", "int", "UnhandledWarningToken", "=", "Internal", "+", "631", ";", "int", "AnnotationValueMustBeArrayInitializer", "=", "Internal", "+", "632", ";", "int", "AnnotationValueMustBeAnEnumConstant", "=", "Internal", "+", "633", ";", "int", "MethodMustOverrideOrImplement", "=", "MethodRelated", "+", "634", ";", "int", "UnusedWarningToken", "=", "Internal", "+", "635", ";", "int", "MissingOverrideAnnotationForInterfaceMethodImplementation", "=", "MethodRelated", "+", "636", ";", "int", "UnusedTypeArgumentsForConstructorInvocation", "=", "MethodRelated", "+", "660", ";", "int", "CorruptedSignature", "=", "Internal", "+", "700", ";", "int", "InvalidEncoding", "=", "Internal", "+", "701", ";", "int", "CannotReadSource", "=", "Internal", "+", "702", ";", "int", "BoxingConversion", "=", "Internal", "+", "720", ";", "int", "UnboxingConversion", "=", "Internal", "+", "721", ";", "int", "IllegalModifierForEnum", "=", "TypeRelated", "+", "750", ";", "int", "IllegalModifierForEnumConstant", "=", "FieldRelated", "+", "751", ";", "int", "IllegalModifierForLocalEnum", "=", "TypeRelated", "+", "752", ";", "int", "IllegalModifierForMemberEnum", "=", "TypeRelated", "+", "753", ";", "int", "CannotDeclareEnumSpecialMethod", "=", "MethodRelated", "+", "754", ";", "int", "IllegalQualifiedEnumConstantLabel", "=", "FieldRelated", "+", "755", ";", "int", "CannotExtendEnum", "=", "TypeRelated", "+", "756", ";", "int", "CannotInvokeSuperConstructorInEnum", "=", "MethodRelated", "+", "757", ";", "int", "EnumAbstractMethodMustBeImplemented", "=", "MethodRelated", "+", "758", ";", "int", "EnumSwitchCannotTargetField", "=", "FieldRelated", "+", "759", ";", "int", "IllegalModifierForEnumConstructor", "=", "MethodRelated", "+", "760", ";", "int", "MissingEnumConstantCase", "=", "FieldRelated", "+", "761", ";", "int", "EnumStaticFieldInInInitializerContext", "=", "FieldRelated", "+", "762", ";", "int", "EnumConstantMustImplementAbstractMethod", "=", "MethodRelated", "+", "763", ";", "int", "EnumConstantCannotDefineAbstractMethod", "=", "MethodRelated", "+", "764", ";", "int", "AbstractMethodInEnum", "=", "MethodRelated", "+", "765", ";", "int", "IllegalExtendedDimensionsForVarArgs", "=", "Syntax", "+", "Internal", "+", "800", ";", "int", "MethodVarargsArgumentNeedCast", "=", "MethodRelated", "+", "801", ";", "int", "ConstructorVarargsArgumentNeedCast", "=", "ConstructorRelated", "+", "802", ";", "int", "VarargsConflict", "=", "MethodRelated", "+", "803", ";", "int", "JavadocGenericMethodTypeArgumentMismatch", "=", "Javadoc", "+", "Internal", "+", "850", ";", "int", "JavadocNonGenericMethod", "=", "Javadoc", "+", "Internal", "+", "851", ";", "int", "JavadocIncorrectArityForParameterizedMethod", "=", "Javadoc", "+", "Internal", "+", "852", ";", "int", "JavadocParameterizedMethodArgumentTypeMismatch", "=", "Javadoc", "+", "Internal", "+", "853", ";", "int", "JavadocTypeArgumentsForRawGenericMethod", "=", "Javadoc", "+", "Internal", "+", "854", ";", "int", "JavadocGenericConstructorTypeArgumentMismatch", "=", "Javadoc", "+", "Internal", "+", "855", ";", "int", "JavadocNonGenericConstructor", "=", "Javadoc", "+", "Internal", "+", "856", ";", "int", "JavadocIncorrectArityForParameterizedConstructor", "=", "Javadoc", "+", "Internal", "+", "857", ";", "int", "JavadocParameterizedConstructorArgumentTypeMismatch", "=", "Javadoc", "+", "Internal", "+", "858", ";", "int", "JavadocTypeArgumentsForRawGenericConstructor", "=", "Javadoc", "+", "Internal", "+", "859", ";", "int", "ExternalProblemNotFixable", "=", "900", ";", "int", "ExternalProblemFixable", "=", "901", ";", "}", "</s>" ]
5,546
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ";", "public", "class", "InvalidInputException", "extends", "Exception", "{", "private", "static", "final", "long", "serialVersionUID", "=", "2909732853499731592L", ";", "public", "InvalidInputException", "(", ")", "{", "super", "(", ")", ";", "}", "public", "InvalidInputException", "(", "String", "message", ")", "{", "super", "(", "message", ")", ";", "}", "}", "</s>" ]
5,547
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "batch", ".", "BatchCompiler", ";", "public", "abstract", "class", "CompilationProgress", "{", "public", "abstract", "void", "begin", "(", "int", "remainingWork", ")", ";", "public", "abstract", "void", "done", "(", ")", ";", "public", "abstract", "boolean", "isCanceled", "(", ")", ";", "public", "abstract", "void", "setTaskName", "(", "String", "name", ")", ";", "public", "abstract", "void", "worked", "(", "int", "workIncrement", ",", "int", "remainingWork", ")", ";", "}", "</s>" ]
5,548
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "DefaultProblem", ";", "public", "abstract", "class", "CategorizedProblem", "implements", "IProblem", "{", "public", "static", "final", "int", "CAT_UNSPECIFIED", "=", "0", ";", "public", "static", "final", "int", "CAT_BUILDPATH", "=", "10", ";", "public", "static", "final", "int", "CAT_SYNTAX", "=", "20", ";", "public", "static", "final", "int", "CAT_IMPORT", "=", "30", ";", "public", "static", "final", "int", "CAT_TYPE", "=", "40", ";", "public", "static", "final", "int", "CAT_MEMBER", "=", "50", ";", "public", "static", "final", "int", "CAT_INTERNAL", "=", "60", ";", "public", "static", "final", "int", "CAT_JAVADOC", "=", "70", ";", "public", "static", "final", "int", "CAT_CODE_STYLE", "=", "80", ";", "public", "static", "final", "int", "CAT_POTENTIAL_PROGRAMMING_PROBLEM", "=", "90", ";", "public", "static", "final", "int", "CAT_NAME_SHADOWING_CONFLICT", "=", "100", ";", "public", "static", "final", "int", "CAT_DEPRECATION", "=", "110", ";", "public", "static", "final", "int", "CAT_UNNECESSARY_CODE", "=", "120", ";", "public", "static", "final", "int", "CAT_UNCHECKED_RAW", "=", "130", ";", "public", "static", "final", "int", "CAT_NLS", "=", "140", ";", "public", "static", "final", "int", "CAT_RESTRICTION", "=", "150", ";", "public", "abstract", "int", "getCategoryID", "(", ")", ";", "public", "abstract", "String", "getMarkerType", "(", ")", ";", "public", "String", "[", "]", "getExtraMarkerAttributeNames", "(", ")", "{", "return", "CharOperation", ".", "NO_STRINGS", ";", "}", "public", "Object", "[", "]", "getExtraMarkerAttributeValues", "(", ")", "{", "return", "DefaultProblem", ".", "EMPTY_VALUES", ";", "}", "}", "</s>" ]
5,549
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ClassFile", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TagBits", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeIds", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "HashtableOfObject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "Util", ";", "public", "class", "ConstantPool", "implements", "ClassFileConstants", ",", "TypeIds", "{", "public", "static", "final", "int", "DOUBLE_INITIAL_SIZE", "=", "5", ";", "public", "static", "final", "int", "FLOAT_INITIAL_SIZE", "=", "3", ";", "public", "static", "final", "int", "INT_INITIAL_SIZE", "=", "248", ";", "public", "static", "final", "int", "LONG_INITIAL_SIZE", "=", "5", ";", "public", "static", "final", "int", "UTF8_INITIAL_SIZE", "=", "778", ";", "public", "static", "final", "int", "STRING_INITIAL_SIZE", "=", "761", ";", "public", "static", "final", "int", "METHODS_AND_FIELDS_INITIAL_SIZE", "=", "450", ";", "public", "static", "final", "int", "CLASS_INITIAL_SIZE", "=", "86", ";", "public", "static", "final", "int", "NAMEANDTYPE_INITIAL_SIZE", "=", "272", ";", "public", "static", "final", "int", "CONSTANTPOOL_INITIAL_SIZE", "=", "2000", ";", "public", "static", "final", "int", "CONSTANTPOOL_GROW_SIZE", "=", "6000", ";", "protected", "DoubleCache", "doubleCache", ";", "protected", "FloatCache", "floatCache", ";", "protected", "IntegerCache", "intCache", ";", "protected", "LongCache", "longCache", ";", "public", "CharArrayCache", "UTF8Cache", ";", "protected", "CharArrayCache", "stringCache", ";", "protected", "HashtableOfObject", "methodsAndFieldsCache", ";", "protected", "CharArrayCache", "classCache", ";", "protected", "HashtableOfObject", "nameAndTypeCacheForFieldsAndMethods", ";", "public", "byte", "[", "]", "poolContent", ";", "public", "int", "currentIndex", "=", "1", ";", "public", "int", "currentOffset", ";", "public", "int", "[", "]", "offsets", ";", "public", "ClassFile", "classFile", ";", "public", "static", "final", "char", "[", "]", "Append", "=", "\"append\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ARRAY_NEWINSTANCE_NAME", "=", "\"newInstance\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ARRAY_NEWINSTANCE_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ArrayCopy", "=", "\"arraycopy\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ArrayCopySignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ArrayJavaLangClassConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ArrayJavaLangObjectConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "booleanBooleanSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "BooleanConstrSignature", "=", "\"(Z)V\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "BOOLEANVALUE_BOOLEAN_METHOD_NAME", "=", "\"booleanValue\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "BOOLEANVALUE_BOOLEAN_METHOD_SIGNATURE", "=", "\"()Z\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "byteByteSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ByteConstrSignature", "=", "\"(B)V\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "BYTEVALUE_BYTE_METHOD_NAME", "=", "\"byteValue\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "BYTEVALUE_BYTE_METHOD_SIGNATURE", "=", "\"()B\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "charCharacterSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "CharConstrSignature", "=", "\"(C)V\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "CHARVALUE_CHARACTER_METHOD_NAME", "=", "\"charValue\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "CHARVALUE_CHARACTER_METHOD_SIGNATURE", "=", "\"()C\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "Clinit", "=", "\"<clinit>\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "DefaultConstructorSignature", "=", "\"()V\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ClinitSignature", "=", "DefaultConstructorSignature", ";", "public", "static", "final", "char", "[", "]", "DesiredAssertionStatus", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "DesiredAssertionStatusSignature", "=", "\"()Z\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "DoubleConstrSignature", "=", "\"(D)V\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "doubleDoubleSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "DOUBLEVALUE_DOUBLE_METHOD_NAME", "=", "\"doubleValue\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "DOUBLEVALUE_DOUBLE_METHOD_SIGNATURE", "=", "\"()D\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "Exit", "=", "\"exit\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ExitIntSignature", "=", "\"(I)V\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "FloatConstrSignature", "=", "\"(F)V\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "floatFloatSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "FLOATVALUE_FLOAT_METHOD_NAME", "=", "\"floatValue\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "FLOATVALUE_FLOAT_METHOD_SIGNATURE", "=", "\"()F\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ForName", "=", "\"forName\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ForNameSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_BOOLEAN_METHOD_NAME", "=", "\"getBoolean\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_BOOLEAN_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_BYTE_METHOD_NAME", "=", "\"getByte\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_BYTE_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_CHAR_METHOD_NAME", "=", "\"getChar\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_CHAR_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_DOUBLE_METHOD_NAME", "=", "\"getDouble\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_DOUBLE_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_FLOAT_METHOD_NAME", "=", "\"getFloat\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_FLOAT_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_INT_METHOD_NAME", "=", "\"getInt\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_INT_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_LONG_METHOD_NAME", "=", "\"getLong\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_LONG_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_OBJECT_METHOD_NAME", "=", "\"get\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_OBJECT_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_SHORT_METHOD_NAME", "=", "\"getShort\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GET_SHORT_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GetClass", "=", "\"getClass\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GetClassSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GetComponentType", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GetComponentTypeSignature", "=", "GetClassSignature", ";", "public", "static", "final", "char", "[", "]", "GetConstructor", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GetConstructorSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GETDECLAREDCONSTRUCTOR_NAME", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GETDECLAREDCONSTRUCTOR_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GETDECLAREDFIELD_NAME", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GETDECLAREDFIELD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GETDECLAREDMETHOD_NAME", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GETDECLAREDMETHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GetMessage", "=", "\"getMessage\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "GetMessageSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "HasNext", "=", "\"hasNext\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "HasNextSignature", "=", "\"()Z\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "Init", "=", "\"<init>\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "IntConstrSignature", "=", "\"(I)V\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ITERATOR_NAME", "=", "\"iterator\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ITERATOR_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "Intern", "=", "\"intern\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "InternSignature", "=", "GetMessageSignature", ";", "public", "static", "final", "char", "[", "]", "IntIntegerSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "INTVALUE_INTEGER_METHOD_NAME", "=", "\"intValue\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "INTVALUE_INTEGER_METHOD_SIGNATURE", "=", "\"()I\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "INVOKE_METHOD_METHOD_NAME", "=", "\"invoke\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "INVOKE_METHOD_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "[", "]", "JAVA_LANG_REFLECT_ACCESSIBLEOBJECT", "=", "new", "char", "[", "]", "[", "]", "{", "TypeConstants", ".", "JAVA", ",", "TypeConstants", ".", "LANG", ",", "TypeConstants", ".", "REFLECT", ",", "\"\"", ".", "toCharArray", "(", ")", "}", ";", "public", "static", "final", "char", "[", "]", "[", "]", "JAVA_LANG_REFLECT_ARRAY", "=", "new", "char", "[", "]", "[", "]", "{", "TypeConstants", ".", "JAVA", ",", "TypeConstants", ".", "LANG", ",", "TypeConstants", ".", "REFLECT", ",", "\"Array\"", ".", "toCharArray", "(", ")", "}", ";", "public", "static", "final", "char", "[", "]", "JavaIoPrintStreamSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangAssertionErrorConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangBooleanConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangByteConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangCharacterConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangClassConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangClassNotFoundExceptionConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangClassSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangDoubleConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangEnumConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangErrorConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangExceptionConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangFloatConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangIntegerConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangLongConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangNoClassDefFoundErrorConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangNoSuchFieldErrorConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangObjectConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JAVALANGREFLECTACCESSIBLEOBJECT_CONSTANTPOOLNAME", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JAVALANGREFLECTARRAY_CONSTANTPOOLNAME", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangReflectConstructorConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangReflectConstructorNewInstanceSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JAVALANGREFLECTFIELD_CONSTANTPOOLNAME", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JAVALANGREFLECTMETHOD_CONSTANTPOOLNAME", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangShortConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangStringBufferConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangStringBuilderConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangStringConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangStringSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangObjectSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangSystemConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangThrowableConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaLangVoidConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JavaUtilIteratorConstantPoolName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "LongConstrSignature", "=", "\"(J)V\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "longLongSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "LONGVALUE_LONG_METHOD_NAME", "=", "\"longValue\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "LONGVALUE_LONG_METHOD_SIGNATURE", "=", "\"()J\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "NewInstance", "=", "\"newInstance\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "NewInstanceSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "Next", "=", "\"next\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "NextSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ObjectConstrSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ObjectSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "Ordinal", "=", "\"ordinal\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "OrdinalSignature", "=", "\"()I\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "Out", "=", "\"out\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_BOOLEAN_METHOD_NAME", "=", "\"setBoolean\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_BOOLEAN_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_BYTE_METHOD_NAME", "=", "\"setByte\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_BYTE_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_CHAR_METHOD_NAME", "=", "\"setChar\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_CHAR_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_DOUBLE_METHOD_NAME", "=", "\"setDouble\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_DOUBLE_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_FLOAT_METHOD_NAME", "=", "\"setFloat\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_FLOAT_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_INT_METHOD_NAME", "=", "\"setInt\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_INT_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_LONG_METHOD_NAME", "=", "\"setLong\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_LONG_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_OBJECT_METHOD_NAME", "=", "\"set\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_OBJECT_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_SHORT_METHOD_NAME", "=", "\"setShort\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SET_SHORT_METHOD_SIGNATURE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SETACCESSIBLE_NAME", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SETACCESSIBLE_SIGNATURE", "=", "\"(Z)V\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ShortConstrSignature", "=", "\"(S)V\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "shortShortSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SHORTVALUE_SHORT_METHOD_NAME", "=", "\"shortValue\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "SHORTVALUE_SHORT_METHOD_SIGNATURE", "=", "\"()S\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringBufferAppendBooleanSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringBufferAppendCharSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringBufferAppendDoubleSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringBufferAppendFloatSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringBufferAppendIntSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringBufferAppendLongSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringBufferAppendObjectSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringBufferAppendStringSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringBuilderAppendBooleanSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringBuilderAppendCharSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringBuilderAppendDoubleSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringBuilderAppendFloatSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringBuilderAppendIntSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringBuilderAppendLongSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringBuilderAppendObjectSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringBuilderAppendStringSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "StringConstructorSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "This", "=", "\"this\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ToString", "=", "\"toString\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ToStringSignature", "=", "GetMessageSignature", ";", "public", "static", "final", "char", "[", "]", "TYPE", "=", "\"TYPE\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ValueOf", "=", "\"valueOf\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ValueOfBooleanSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ValueOfCharSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ValueOfDoubleSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ValueOfFloatSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ValueOfIntSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ValueOfLongSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ValueOfObjectSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "ValueOfStringClassSignature", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JAVA_LANG_ANNOTATION_DOCUMENTED", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JAVA_LANG_ANNOTATION_ELEMENTTYPE", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JAVA_LANG_ANNOTATION_RETENTION", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JAVA_LANG_ANNOTATION_RETENTIONPOLICY", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JAVA_LANG_ANNOTATION_TARGET", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JAVA_LANG_DEPRECATED", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "static", "final", "char", "[", "]", "JAVA_LANG_ANNOTATION_INHERITED", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "public", "ConstantPool", "(", "ClassFile", "classFile", ")", "{", "this", ".", "UTF8Cache", "=", "new", "CharArrayCache", "(", "UTF8_INITIAL_SIZE", ")", ";", "this", ".", "stringCache", "=", "new", "CharArrayCache", "(", "STRING_INITIAL_SIZE", ")", ";", "this", ".", "methodsAndFieldsCache", "=", "new", "HashtableOfObject", "(", "METHODS_AND_FIELDS_INITIAL_SIZE", ")", ";", "this", ".", "classCache", "=", "new", "CharArrayCache", "(", "CLASS_INITIAL_SIZE", ")", ";", "this", ".", "nameAndTypeCacheForFieldsAndMethods", "=", "new", "HashtableOfObject", "(", "NAMEANDTYPE_INITIAL_SIZE", ")", ";", "this", ".", "offsets", "=", "new", "int", "[", "5", "]", ";", "initialize", "(", "classFile", ")", ";", "}", "public", "void", "initialize", "(", "ClassFile", "givenClassFile", ")", "{", "this", ".", "poolContent", "=", "givenClassFile", ".", "header", ";", "this", ".", "currentOffset", "=", "givenClassFile", ".", "headerOffset", ";", "this", ".", "currentIndex", "=", "1", ";", "this", ".", "classFile", "=", "givenClassFile", ";", "}", "public", "byte", "[", "]", "dumpBytes", "(", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "poolContent", ",", "0", ",", "(", "this", ".", "poolContent", "=", "new", "byte", "[", "this", ".", "currentOffset", "]", ")", ",", "0", ",", "this", ".", "currentOffset", ")", ";", "return", "this", ".", "poolContent", ";", "}", "public", "int", "literalIndex", "(", "byte", "[", "]", "utf8encoding", ",", "char", "[", "]", "stringCharArray", ")", "{", "int", "index", ";", "if", "(", "(", "index", "=", "this", ".", "UTF8Cache", ".", "putIfAbsent", "(", "stringCharArray", ",", "this", ".", "currentIndex", ")", ")", "<", "0", ")", "{", "if", "(", "(", "index", "=", "-", "index", ")", ">", "0xFFFF", ")", "{", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceInConstantPool", "(", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "referenceType", "(", ")", ")", ";", "}", "this", ".", "currentIndex", "++", ";", "int", "length", "=", "this", ".", "offsets", ".", "length", ";", "if", "(", "length", "<=", "index", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "offsets", ",", "0", ",", "(", "this", ".", "offsets", "=", "new", "int", "[", "index", "*", "2", "]", ")", ",", "0", ",", "length", ")", ";", "}", "this", ".", "offsets", "[", "index", "]", "=", "this", ".", "currentOffset", ";", "writeU1", "(", "Utf8Tag", ")", ";", "int", "utf8encodingLength", "=", "utf8encoding", ".", "length", ";", "if", "(", "this", ".", "currentOffset", "+", "2", "+", "utf8encodingLength", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "2", "+", "utf8encodingLength", ")", ";", "}", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "utf8encodingLength", ">>", "8", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "utf8encodingLength", ";", "System", ".", "arraycopy", "(", "utf8encoding", ",", "0", ",", "this", ".", "poolContent", ",", "this", ".", "currentOffset", ",", "utf8encodingLength", ")", ";", "this", ".", "currentOffset", "+=", "utf8encodingLength", ";", "}", "return", "index", ";", "}", "public", "int", "literalIndex", "(", "TypeBinding", "binding", ")", "{", "TypeBinding", "typeBinding", "=", "binding", ".", "leafComponentType", "(", ")", ";", "if", "(", "(", "typeBinding", ".", "tagBits", "&", "TagBits", ".", "ContainsNestedTypeReferences", ")", "!=", "0", ")", "{", "Util", ".", "recordNestedType", "(", "this", ".", "classFile", ",", "typeBinding", ")", ";", "}", "return", "literalIndex", "(", "binding", ".", "signature", "(", ")", ")", ";", "}", "public", "int", "literalIndex", "(", "char", "[", "]", "utf8Constant", ")", "{", "int", "index", ";", "if", "(", "(", "index", "=", "this", ".", "UTF8Cache", ".", "putIfAbsent", "(", "utf8Constant", ",", "this", ".", "currentIndex", ")", ")", "<", "0", ")", "{", "if", "(", "(", "index", "=", "-", "index", ")", ">", "0xFFFF", ")", "{", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceInConstantPool", "(", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "referenceType", "(", ")", ")", ";", "}", "int", "length", "=", "this", ".", "offsets", ".", "length", ";", "if", "(", "length", "<=", "index", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "offsets", ",", "0", ",", "(", "this", ".", "offsets", "=", "new", "int", "[", "index", "*", "2", "]", ")", ",", "0", ",", "length", ")", ";", "}", "this", ".", "offsets", "[", "index", "]", "=", "this", ".", "currentOffset", ";", "writeU1", "(", "Utf8Tag", ")", ";", "int", "savedCurrentOffset", "=", "this", ".", "currentOffset", ";", "if", "(", "this", ".", "currentOffset", "+", "2", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "2", ")", ";", "}", "this", ".", "currentOffset", "+=", "2", ";", "length", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "utf8Constant", ".", "length", ";", "i", "++", ")", "{", "char", "current", "=", "utf8Constant", "[", "i", "]", ";", "if", "(", "(", "current", ">=", "0x0001", ")", "&&", "(", "current", "<=", "0x007F", ")", ")", "{", "writeU1", "(", "current", ")", ";", "length", "++", ";", "}", "else", "{", "if", "(", "current", ">", "0x07FF", ")", "{", "length", "+=", "3", ";", "writeU1", "(", "0xE0", "|", "(", "(", "current", ">>", "12", ")", "&", "0x0F", ")", ")", ";", "writeU1", "(", "0x80", "|", "(", "(", "current", ">>", "6", ")", "&", "0x3F", ")", ")", ";", "writeU1", "(", "0x80", "|", "(", "current", "&", "0x3F", ")", ")", ";", "}", "else", "{", "length", "+=", "2", ";", "writeU1", "(", "0xC0", "|", "(", "(", "current", ">>", "6", ")", "&", "0x1F", ")", ")", ";", "writeU1", "(", "0x80", "|", "(", "current", "&", "0x3F", ")", ")", ";", "}", "}", "}", "if", "(", "length", ">=", "65535", ")", "{", "this", ".", "currentOffset", "=", "savedCurrentOffset", "-", "1", ";", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceForConstant", "(", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "referenceType", "(", ")", ")", ";", "}", "if", "(", "index", ">", "0xFFFF", ")", "{", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceInConstantPool", "(", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "referenceType", "(", ")", ")", ";", "}", "this", ".", "currentIndex", "++", ";", "this", ".", "poolContent", "[", "savedCurrentOffset", "]", "=", "(", "byte", ")", "(", "length", ">>", "8", ")", ";", "this", ".", "poolContent", "[", "savedCurrentOffset", "+", "1", "]", "=", "(", "byte", ")", "length", ";", "}", "return", "index", ";", "}", "public", "int", "literalIndex", "(", "char", "[", "]", "stringCharArray", ",", "byte", "[", "]", "utf8encoding", ")", "{", "int", "index", ";", "if", "(", "(", "index", "=", "this", ".", "stringCache", ".", "putIfAbsent", "(", "stringCharArray", ",", "this", ".", "currentIndex", ")", ")", "<", "0", ")", "{", "this", ".", "currentIndex", "++", ";", "if", "(", "(", "index", "=", "-", "index", ")", ">", "0xFFFF", ")", "{", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceInConstantPool", "(", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "referenceType", "(", ")", ")", ";", "}", "int", "length", "=", "this", ".", "offsets", ".", "length", ";", "if", "(", "length", "<=", "index", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "offsets", ",", "0", ",", "(", "this", ".", "offsets", "=", "new", "int", "[", "index", "*", "2", "]", ")", ",", "0", ",", "length", ")", ";", "}", "this", ".", "offsets", "[", "index", "]", "=", "this", ".", "currentOffset", ";", "writeU1", "(", "StringTag", ")", ";", "int", "stringIndexOffset", "=", "this", ".", "currentOffset", ";", "if", "(", "this", ".", "currentOffset", "+", "2", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "2", ")", ";", "}", "this", ".", "currentOffset", "+=", "2", ";", "final", "int", "stringIndex", "=", "literalIndex", "(", "utf8encoding", ",", "stringCharArray", ")", ";", "this", ".", "poolContent", "[", "stringIndexOffset", "++", "]", "=", "(", "byte", ")", "(", "stringIndex", ">>", "8", ")", ";", "this", ".", "poolContent", "[", "stringIndexOffset", "]", "=", "(", "byte", ")", "stringIndex", ";", "}", "return", "index", ";", "}", "public", "int", "literalIndex", "(", "double", "key", ")", "{", "int", "index", ";", "if", "(", "this", ".", "doubleCache", "==", "null", ")", "{", "this", ".", "doubleCache", "=", "new", "DoubleCache", "(", "DOUBLE_INITIAL_SIZE", ")", ";", "}", "if", "(", "(", "index", "=", "this", ".", "doubleCache", ".", "putIfAbsent", "(", "key", ",", "this", ".", "currentIndex", ")", ")", "<", "0", ")", "{", "if", "(", "(", "index", "=", "-", "index", ")", ">", "0xFFFF", ")", "{", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceInConstantPool", "(", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "referenceType", "(", ")", ")", ";", "}", "this", ".", "currentIndex", "+=", "2", ";", "int", "length", "=", "this", ".", "offsets", ".", "length", ";", "if", "(", "length", "<=", "index", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "offsets", ",", "0", ",", "(", "this", ".", "offsets", "=", "new", "int", "[", "index", "*", "2", "]", ")", ",", "0", ",", "length", ")", ";", "}", "this", ".", "offsets", "[", "index", "]", "=", "this", ".", "currentOffset", ";", "writeU1", "(", "DoubleTag", ")", ";", "long", "temp", "=", "java", ".", "lang", ".", "Double", ".", "doubleToLongBits", "(", "key", ")", ";", "length", "=", "this", ".", "poolContent", ".", "length", ";", "if", "(", "this", ".", "currentOffset", "+", "8", ">=", "length", ")", "{", "resizePoolContents", "(", "8", ")", ";", "}", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "temp", ">>>", "56", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "temp", ">>>", "48", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "temp", ">>>", "40", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "temp", ">>>", "32", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "temp", ">>>", "24", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "temp", ">>>", "16", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "temp", ">>>", "8", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "temp", ";", "}", "return", "index", ";", "}", "public", "int", "literalIndex", "(", "float", "key", ")", "{", "int", "index", ";", "if", "(", "this", ".", "floatCache", "==", "null", ")", "{", "this", ".", "floatCache", "=", "new", "FloatCache", "(", "FLOAT_INITIAL_SIZE", ")", ";", "}", "if", "(", "(", "index", "=", "this", ".", "floatCache", ".", "putIfAbsent", "(", "key", ",", "this", ".", "currentIndex", ")", ")", "<", "0", ")", "{", "if", "(", "(", "index", "=", "-", "index", ")", ">", "0xFFFF", ")", "{", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceInConstantPool", "(", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "referenceType", "(", ")", ")", ";", "}", "this", ".", "currentIndex", "++", ";", "int", "length", "=", "this", ".", "offsets", ".", "length", ";", "if", "(", "length", "<=", "index", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "offsets", ",", "0", ",", "(", "this", ".", "offsets", "=", "new", "int", "[", "index", "*", "2", "]", ")", ",", "0", ",", "length", ")", ";", "}", "this", ".", "offsets", "[", "index", "]", "=", "this", ".", "currentOffset", ";", "writeU1", "(", "FloatTag", ")", ";", "int", "temp", "=", "java", ".", "lang", ".", "Float", ".", "floatToIntBits", "(", "key", ")", ";", "if", "(", "this", ".", "currentOffset", "+", "4", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "4", ")", ";", "}", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "temp", ">>>", "24", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "temp", ">>>", "16", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "temp", ">>>", "8", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "temp", ";", "}", "return", "index", ";", "}", "public", "int", "literalIndex", "(", "int", "key", ")", "{", "int", "index", ";", "if", "(", "this", ".", "intCache", "==", "null", ")", "{", "this", ".", "intCache", "=", "new", "IntegerCache", "(", "INT_INITIAL_SIZE", ")", ";", "}", "if", "(", "(", "index", "=", "this", ".", "intCache", ".", "putIfAbsent", "(", "key", ",", "this", ".", "currentIndex", ")", ")", "<", "0", ")", "{", "this", ".", "currentIndex", "++", ";", "if", "(", "(", "index", "=", "-", "index", ")", ">", "0xFFFF", ")", "{", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceInConstantPool", "(", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "referenceType", "(", ")", ")", ";", "}", "int", "length", "=", "this", ".", "offsets", ".", "length", ";", "if", "(", "length", "<=", "index", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "offsets", ",", "0", ",", "(", "this", ".", "offsets", "=", "new", "int", "[", "index", "*", "2", "]", ")", ",", "0", ",", "length", ")", ";", "}", "this", ".", "offsets", "[", "index", "]", "=", "this", ".", "currentOffset", ";", "writeU1", "(", "IntegerTag", ")", ";", "if", "(", "this", ".", "currentOffset", "+", "4", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "4", ")", ";", "}", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "key", ">>>", "24", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "key", ">>>", "16", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "key", ">>>", "8", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "key", ";", "}", "return", "index", ";", "}", "public", "int", "literalIndex", "(", "long", "key", ")", "{", "int", "index", ";", "if", "(", "this", ".", "longCache", "==", "null", ")", "{", "this", ".", "longCache", "=", "new", "LongCache", "(", "LONG_INITIAL_SIZE", ")", ";", "}", "if", "(", "(", "index", "=", "this", ".", "longCache", ".", "putIfAbsent", "(", "key", ",", "this", ".", "currentIndex", ")", ")", "<", "0", ")", "{", "if", "(", "(", "index", "=", "-", "index", ")", ">", "0xFFFF", ")", "{", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceInConstantPool", "(", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "referenceType", "(", ")", ")", ";", "}", "this", ".", "currentIndex", "+=", "2", ";", "int", "length", "=", "this", ".", "offsets", ".", "length", ";", "if", "(", "length", "<=", "index", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "offsets", ",", "0", ",", "(", "this", ".", "offsets", "=", "new", "int", "[", "index", "*", "2", "]", ")", ",", "0", ",", "length", ")", ";", "}", "this", ".", "offsets", "[", "index", "]", "=", "this", ".", "currentOffset", ";", "writeU1", "(", "LongTag", ")", ";", "if", "(", "this", ".", "currentOffset", "+", "8", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "8", ")", ";", "}", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "key", ">>>", "56", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "key", ">>>", "48", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "key", ">>>", "40", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "key", ">>>", "32", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "key", ">>>", "24", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "key", ">>>", "16", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "key", ">>>", "8", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "key", ";", "}", "return", "index", ";", "}", "public", "int", "literalIndex", "(", "String", "stringConstant", ")", "{", "int", "index", ";", "char", "[", "]", "stringCharArray", "=", "stringConstant", ".", "toCharArray", "(", ")", ";", "if", "(", "(", "index", "=", "this", ".", "stringCache", ".", "putIfAbsent", "(", "stringCharArray", ",", "this", ".", "currentIndex", ")", ")", "<", "0", ")", "{", "this", ".", "currentIndex", "++", ";", "if", "(", "(", "index", "=", "-", "index", ")", ">", "0xFFFF", ")", "{", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceInConstantPool", "(", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "referenceType", "(", ")", ")", ";", "}", "int", "length", "=", "this", ".", "offsets", ".", "length", ";", "if", "(", "length", "<=", "index", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "offsets", ",", "0", ",", "(", "this", ".", "offsets", "=", "new", "int", "[", "index", "*", "2", "]", ")", ",", "0", ",", "length", ")", ";", "}", "this", ".", "offsets", "[", "index", "]", "=", "this", ".", "currentOffset", ";", "writeU1", "(", "StringTag", ")", ";", "int", "stringIndexOffset", "=", "this", ".", "currentOffset", ";", "if", "(", "this", ".", "currentOffset", "+", "2", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "2", ")", ";", "}", "this", ".", "currentOffset", "+=", "2", ";", "final", "int", "stringIndex", "=", "literalIndex", "(", "stringCharArray", ")", ";", "this", ".", "poolContent", "[", "stringIndexOffset", "++", "]", "=", "(", "byte", ")", "(", "stringIndex", ">>", "8", ")", ";", "this", ".", "poolContent", "[", "stringIndexOffset", "]", "=", "(", "byte", ")", "stringIndex", ";", "}", "return", "index", ";", "}", "public", "int", "literalIndexForType", "(", "final", "char", "[", "]", "constantPoolName", ")", "{", "int", "index", ";", "if", "(", "(", "index", "=", "this", ".", "classCache", ".", "putIfAbsent", "(", "constantPoolName", ",", "this", ".", "currentIndex", ")", ")", "<", "0", ")", "{", "this", ".", "currentIndex", "++", ";", "if", "(", "(", "index", "=", "-", "index", ")", ">", "0xFFFF", ")", "{", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceInConstantPool", "(", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "referenceType", "(", ")", ")", ";", "}", "int", "length", "=", "this", ".", "offsets", ".", "length", ";", "if", "(", "length", "<=", "index", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "offsets", ",", "0", ",", "(", "this", ".", "offsets", "=", "new", "int", "[", "index", "*", "2", "]", ")", ",", "0", ",", "length", ")", ";", "}", "this", ".", "offsets", "[", "index", "]", "=", "this", ".", "currentOffset", ";", "writeU1", "(", "ClassTag", ")", ";", "int", "nameIndexOffset", "=", "this", ".", "currentOffset", ";", "if", "(", "this", ".", "currentOffset", "+", "2", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "2", ")", ";", "}", "this", ".", "currentOffset", "+=", "2", ";", "final", "int", "nameIndex", "=", "literalIndex", "(", "constantPoolName", ")", ";", "this", ".", "poolContent", "[", "nameIndexOffset", "++", "]", "=", "(", "byte", ")", "(", "nameIndex", ">>", "8", ")", ";", "this", ".", "poolContent", "[", "nameIndexOffset", "]", "=", "(", "byte", ")", "nameIndex", ";", "}", "return", "index", ";", "}", "public", "int", "literalIndexForType", "(", "final", "TypeBinding", "binding", ")", "{", "TypeBinding", "typeBinding", "=", "binding", ".", "leafComponentType", "(", ")", ";", "if", "(", "(", "typeBinding", ".", "tagBits", "&", "TagBits", ".", "ContainsNestedTypeReferences", ")", "!=", "0", ")", "{", "Util", ".", "recordNestedType", "(", "this", ".", "classFile", ",", "typeBinding", ")", ";", "}", "return", "this", ".", "literalIndexForType", "(", "binding", ".", "constantPoolName", "(", ")", ")", ";", "}", "public", "int", "literalIndexForMethod", "(", "char", "[", "]", "declaringClass", ",", "char", "[", "]", "selector", ",", "char", "[", "]", "signature", ",", "boolean", "isInterface", ")", "{", "int", "index", ";", "if", "(", "(", "index", "=", "putInCacheIfAbsent", "(", "declaringClass", ",", "selector", ",", "signature", ",", "this", ".", "currentIndex", ")", ")", "<", "0", ")", "{", "this", ".", "currentIndex", "++", ";", "if", "(", "(", "index", "=", "-", "index", ")", ">", "0xFFFF", ")", "{", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceInConstantPool", "(", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "referenceType", "(", ")", ")", ";", "}", "int", "length", "=", "this", ".", "offsets", ".", "length", ";", "if", "(", "length", "<=", "index", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "offsets", ",", "0", ",", "(", "this", ".", "offsets", "=", "new", "int", "[", "index", "*", "2", "]", ")", ",", "0", ",", "length", ")", ";", "}", "this", ".", "offsets", "[", "index", "]", "=", "this", ".", "currentOffset", ";", "writeU1", "(", "isInterface", "?", "InterfaceMethodRefTag", ":", "MethodRefTag", ")", ";", "int", "classIndexOffset", "=", "this", ".", "currentOffset", ";", "if", "(", "this", ".", "currentOffset", "+", "4", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "4", ")", ";", "}", "this", ".", "currentOffset", "+=", "4", ";", "final", "int", "classIndex", "=", "literalIndexForType", "(", "declaringClass", ")", ";", "final", "int", "nameAndTypeIndex", "=", "literalIndexForNameAndType", "(", "selector", ",", "signature", ")", ";", "this", ".", "poolContent", "[", "classIndexOffset", "++", "]", "=", "(", "byte", ")", "(", "classIndex", ">>", "8", ")", ";", "this", ".", "poolContent", "[", "classIndexOffset", "++", "]", "=", "(", "byte", ")", "classIndex", ";", "this", ".", "poolContent", "[", "classIndexOffset", "++", "]", "=", "(", "byte", ")", "(", "nameAndTypeIndex", ">>", "8", ")", ";", "this", ".", "poolContent", "[", "classIndexOffset", "]", "=", "(", "byte", ")", "nameAndTypeIndex", ";", "}", "return", "index", ";", "}", "public", "int", "literalIndexForMethod", "(", "TypeBinding", "declaringClass", ",", "char", "[", "]", "selector", ",", "char", "[", "]", "signature", ",", "boolean", "isInterface", ")", "{", "if", "(", "(", "declaringClass", ".", "tagBits", "&", "TagBits", ".", "ContainsNestedTypeReferences", ")", "!=", "0", ")", "{", "Util", ".", "recordNestedType", "(", "this", ".", "classFile", ",", "declaringClass", ")", ";", "}", "return", "this", ".", "literalIndexForMethod", "(", "declaringClass", ".", "constantPoolName", "(", ")", ",", "selector", ",", "signature", ",", "isInterface", ")", ";", "}", "public", "int", "literalIndexForNameAndType", "(", "char", "[", "]", "name", ",", "char", "[", "]", "signature", ")", "{", "int", "index", ";", "if", "(", "(", "index", "=", "putInNameAndTypeCacheIfAbsent", "(", "name", ",", "signature", ",", "this", ".", "currentIndex", ")", ")", "<", "0", ")", "{", "this", ".", "currentIndex", "++", ";", "if", "(", "(", "index", "=", "-", "index", ")", ">", "0xFFFF", ")", "{", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceInConstantPool", "(", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "referenceType", "(", ")", ")", ";", "}", "int", "length", "=", "this", ".", "offsets", ".", "length", ";", "if", "(", "length", "<=", "index", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "offsets", ",", "0", ",", "(", "this", ".", "offsets", "=", "new", "int", "[", "index", "*", "2", "]", ")", ",", "0", ",", "length", ")", ";", "}", "this", ".", "offsets", "[", "index", "]", "=", "this", ".", "currentOffset", ";", "writeU1", "(", "NameAndTypeTag", ")", ";", "int", "nameIndexOffset", "=", "this", ".", "currentOffset", ";", "if", "(", "this", ".", "currentOffset", "+", "4", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "4", ")", ";", "}", "this", ".", "currentOffset", "+=", "4", ";", "final", "int", "nameIndex", "=", "literalIndex", "(", "name", ")", ";", "final", "int", "typeIndex", "=", "literalIndex", "(", "signature", ")", ";", "this", ".", "poolContent", "[", "nameIndexOffset", "++", "]", "=", "(", "byte", ")", "(", "nameIndex", ">>", "8", ")", ";", "this", ".", "poolContent", "[", "nameIndexOffset", "++", "]", "=", "(", "byte", ")", "nameIndex", ";", "this", ".", "poolContent", "[", "nameIndexOffset", "++", "]", "=", "(", "byte", ")", "(", "typeIndex", ">>", "8", ")", ";", "this", ".", "poolContent", "[", "nameIndexOffset", "]", "=", "(", "byte", ")", "typeIndex", ";", "}", "return", "index", ";", "}", "public", "int", "literalIndexForField", "(", "char", "[", "]", "declaringClass", ",", "char", "[", "]", "name", ",", "char", "[", "]", "signature", ")", "{", "int", "index", ";", "if", "(", "(", "index", "=", "putInCacheIfAbsent", "(", "declaringClass", ",", "name", ",", "signature", ",", "this", ".", "currentIndex", ")", ")", "<", "0", ")", "{", "this", ".", "currentIndex", "++", ";", "if", "(", "(", "index", "=", "-", "index", ")", ">", "0xFFFF", ")", "{", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceInConstantPool", "(", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "referenceType", "(", ")", ")", ";", "}", "int", "length", "=", "this", ".", "offsets", ".", "length", ";", "if", "(", "length", "<=", "index", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "offsets", ",", "0", ",", "(", "this", ".", "offsets", "=", "new", "int", "[", "index", "*", "2", "]", ")", ",", "0", ",", "length", ")", ";", "}", "this", ".", "offsets", "[", "index", "]", "=", "this", ".", "currentOffset", ";", "writeU1", "(", "FieldRefTag", ")", ";", "int", "classIndexOffset", "=", "this", ".", "currentOffset", ";", "if", "(", "this", ".", "currentOffset", "+", "4", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "4", ")", ";", "}", "this", ".", "currentOffset", "+=", "4", ";", "final", "int", "classIndex", "=", "literalIndexForType", "(", "declaringClass", ")", ";", "final", "int", "nameAndTypeIndex", "=", "literalIndexForNameAndType", "(", "name", ",", "signature", ")", ";", "this", ".", "poolContent", "[", "classIndexOffset", "++", "]", "=", "(", "byte", ")", "(", "classIndex", ">>", "8", ")", ";", "this", ".", "poolContent", "[", "classIndexOffset", "++", "]", "=", "(", "byte", ")", "classIndex", ";", "this", ".", "poolContent", "[", "classIndexOffset", "++", "]", "=", "(", "byte", ")", "(", "nameAndTypeIndex", ">>", "8", ")", ";", "this", ".", "poolContent", "[", "classIndexOffset", "]", "=", "(", "byte", ")", "nameAndTypeIndex", ";", "}", "return", "index", ";", "}", "public", "int", "literalIndexForLdc", "(", "char", "[", "]", "stringCharArray", ")", "{", "int", "savedCurrentIndex", "=", "this", ".", "currentIndex", ";", "int", "savedCurrentOffset", "=", "this", ".", "currentOffset", ";", "int", "index", ";", "if", "(", "(", "index", "=", "this", ".", "stringCache", ".", "putIfAbsent", "(", "stringCharArray", ",", "this", ".", "currentIndex", ")", ")", "<", "0", ")", "{", "if", "(", "(", "index", "=", "-", "index", ")", ">", "0xFFFF", ")", "{", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceInConstantPool", "(", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "referenceType", "(", ")", ")", ";", "}", "this", ".", "currentIndex", "++", ";", "int", "length", "=", "this", ".", "offsets", ".", "length", ";", "if", "(", "length", "<=", "index", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "offsets", ",", "0", ",", "(", "this", ".", "offsets", "=", "new", "int", "[", "index", "*", "2", "]", ")", ",", "0", ",", "length", ")", ";", "}", "this", ".", "offsets", "[", "index", "]", "=", "this", ".", "currentOffset", ";", "writeU1", "(", "StringTag", ")", ";", "int", "stringIndexOffset", "=", "this", ".", "currentOffset", ";", "if", "(", "this", ".", "currentOffset", "+", "2", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "2", ")", ";", "}", "this", ".", "currentOffset", "+=", "2", ";", "int", "stringIndex", ";", "if", "(", "(", "stringIndex", "=", "this", ".", "UTF8Cache", ".", "putIfAbsent", "(", "stringCharArray", ",", "this", ".", "currentIndex", ")", ")", "<", "0", ")", "{", "if", "(", "(", "stringIndex", "=", "-", "stringIndex", ")", ">", "0xFFFF", ")", "{", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceInConstantPool", "(", "this", ".", "classFile", ".", "referenceBinding", ".", "scope", ".", "referenceType", "(", ")", ")", ";", "}", "this", ".", "currentIndex", "++", ";", "length", "=", "this", ".", "offsets", ".", "length", ";", "if", "(", "length", "<=", "stringIndex", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "offsets", ",", "0", ",", "(", "this", ".", "offsets", "=", "new", "int", "[", "stringIndex", "*", "2", "]", ")", ",", "0", ",", "length", ")", ";", "}", "this", ".", "offsets", "[", "stringIndex", "]", "=", "this", ".", "currentOffset", ";", "writeU1", "(", "Utf8Tag", ")", ";", "int", "lengthOffset", "=", "this", ".", "currentOffset", ";", "if", "(", "this", ".", "currentOffset", "+", "2", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "2", ")", ";", "}", "this", ".", "currentOffset", "+=", "2", ";", "length", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "stringCharArray", ".", "length", ";", "i", "++", ")", "{", "char", "current", "=", "stringCharArray", "[", "i", "]", ";", "if", "(", "(", "current", ">=", "0x0001", ")", "&&", "(", "current", "<=", "0x007F", ")", ")", "{", "length", "++", ";", "if", "(", "this", ".", "currentOffset", "+", "1", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "1", ")", ";", "}", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "current", ")", ";", "}", "else", "if", "(", "current", ">", "0x07FF", ")", "{", "length", "+=", "3", ";", "if", "(", "this", ".", "currentOffset", "+", "3", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "3", ")", ";", "}", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "0xE0", "|", "(", "(", "current", ">>", "12", ")", "&", "0x0F", ")", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "0x80", "|", "(", "(", "current", ">>", "6", ")", "&", "0x3F", ")", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "0x80", "|", "(", "current", "&", "0x3F", ")", ")", ";", "}", "else", "{", "if", "(", "this", ".", "currentOffset", "+", "2", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "2", ")", ";", "}", "length", "+=", "2", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "0xC0", "|", "(", "(", "current", ">>", "6", ")", "&", "0x1F", ")", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "0x80", "|", "(", "current", "&", "0x3F", ")", ")", ";", "}", "}", "if", "(", "length", ">=", "65535", ")", "{", "this", ".", "currentOffset", "=", "savedCurrentOffset", ";", "this", ".", "currentIndex", "=", "savedCurrentIndex", ";", "this", ".", "stringCache", ".", "remove", "(", "stringCharArray", ")", ";", "this", ".", "UTF8Cache", ".", "remove", "(", "stringCharArray", ")", ";", "return", "0", ";", "}", "this", ".", "poolContent", "[", "lengthOffset", "++", "]", "=", "(", "byte", ")", "(", "length", ">>", "8", ")", ";", "this", ".", "poolContent", "[", "lengthOffset", "]", "=", "(", "byte", ")", "length", ";", "}", "this", ".", "poolContent", "[", "stringIndexOffset", "++", "]", "=", "(", "byte", ")", "(", "stringIndex", ">>", "8", ")", ";", "this", ".", "poolContent", "[", "stringIndexOffset", "]", "=", "(", "byte", ")", "stringIndex", ";", "}", "return", "index", ";", "}", "private", "int", "putInNameAndTypeCacheIfAbsent", "(", "final", "char", "[", "]", "key1", ",", "final", "char", "[", "]", "key2", ",", "int", "value", ")", "{", "int", "index", ";", "Object", "key1Value", "=", "this", ".", "nameAndTypeCacheForFieldsAndMethods", ".", "get", "(", "key1", ")", ";", "if", "(", "key1Value", "==", "null", ")", "{", "CachedIndexEntry", "cachedIndexEntry", "=", "new", "CachedIndexEntry", "(", "key2", ",", "value", ")", ";", "index", "=", "-", "value", ";", "this", ".", "nameAndTypeCacheForFieldsAndMethods", ".", "put", "(", "key1", ",", "cachedIndexEntry", ")", ";", "}", "else", "if", "(", "key1Value", "instanceof", "CachedIndexEntry", ")", "{", "CachedIndexEntry", "entry", "=", "(", "CachedIndexEntry", ")", "key1Value", ";", "if", "(", "CharOperation", ".", "equals", "(", "key2", ",", "entry", ".", "signature", ")", ")", "{", "index", "=", "entry", ".", "index", ";", "}", "else", "{", "CharArrayCache", "charArrayCache", "=", "new", "CharArrayCache", "(", ")", ";", "charArrayCache", ".", "putIfAbsent", "(", "entry", ".", "signature", ",", "entry", ".", "index", ")", ";", "index", "=", "charArrayCache", ".", "putIfAbsent", "(", "key2", ",", "value", ")", ";", "this", ".", "nameAndTypeCacheForFieldsAndMethods", ".", "put", "(", "key1", ",", "charArrayCache", ")", ";", "}", "}", "else", "{", "CharArrayCache", "charArrayCache", "=", "(", "CharArrayCache", ")", "key1Value", ";", "index", "=", "charArrayCache", ".", "putIfAbsent", "(", "key2", ",", "value", ")", ";", "}", "return", "index", ";", "}", "private", "int", "putInCacheIfAbsent", "(", "final", "char", "[", "]", "key1", ",", "final", "char", "[", "]", "key2", ",", "final", "char", "[", "]", "key3", ",", "int", "value", ")", "{", "int", "index", ";", "HashtableOfObject", "key1Value", "=", "(", "HashtableOfObject", ")", "this", ".", "methodsAndFieldsCache", ".", "get", "(", "key1", ")", ";", "if", "(", "key1Value", "==", "null", ")", "{", "key1Value", "=", "new", "HashtableOfObject", "(", ")", ";", "this", ".", "methodsAndFieldsCache", ".", "put", "(", "key1", ",", "key1Value", ")", ";", "CachedIndexEntry", "cachedIndexEntry", "=", "new", "CachedIndexEntry", "(", "key3", ",", "value", ")", ";", "index", "=", "-", "value", ";", "key1Value", ".", "put", "(", "key2", ",", "cachedIndexEntry", ")", ";", "}", "else", "{", "Object", "key2Value", "=", "key1Value", ".", "get", "(", "key2", ")", ";", "if", "(", "key2Value", "==", "null", ")", "{", "CachedIndexEntry", "cachedIndexEntry", "=", "new", "CachedIndexEntry", "(", "key3", ",", "value", ")", ";", "index", "=", "-", "value", ";", "key1Value", ".", "put", "(", "key2", ",", "cachedIndexEntry", ")", ";", "}", "else", "if", "(", "key2Value", "instanceof", "CachedIndexEntry", ")", "{", "CachedIndexEntry", "entry", "=", "(", "CachedIndexEntry", ")", "key2Value", ";", "if", "(", "CharOperation", ".", "equals", "(", "key3", ",", "entry", ".", "signature", ")", ")", "{", "index", "=", "entry", ".", "index", ";", "}", "else", "{", "CharArrayCache", "charArrayCache", "=", "new", "CharArrayCache", "(", ")", ";", "charArrayCache", ".", "putIfAbsent", "(", "entry", ".", "signature", ",", "entry", ".", "index", ")", ";", "index", "=", "charArrayCache", ".", "putIfAbsent", "(", "key3", ",", "value", ")", ";", "key1Value", ".", "put", "(", "key2", ",", "charArrayCache", ")", ";", "}", "}", "else", "{", "CharArrayCache", "charArrayCache", "=", "(", "CharArrayCache", ")", "key2Value", ";", "index", "=", "charArrayCache", ".", "putIfAbsent", "(", "key3", ",", "value", ")", ";", "}", "}", "return", "index", ";", "}", "public", "void", "resetForClinit", "(", "int", "constantPoolIndex", ",", "int", "constantPoolOffset", ")", "{", "this", ".", "currentIndex", "=", "constantPoolIndex", ";", "this", ".", "currentOffset", "=", "constantPoolOffset", ";", "if", "(", "this", ".", "UTF8Cache", ".", "get", "(", "AttributeNamesConstants", ".", "CodeName", ")", ">=", "constantPoolIndex", ")", "{", "this", ".", "UTF8Cache", ".", "remove", "(", "AttributeNamesConstants", ".", "CodeName", ")", ";", "}", "if", "(", "this", ".", "UTF8Cache", ".", "get", "(", "ConstantPool", ".", "ClinitSignature", ")", ">=", "constantPoolIndex", ")", "{", "this", ".", "UTF8Cache", ".", "remove", "(", "ConstantPool", ".", "ClinitSignature", ")", ";", "}", "if", "(", "this", ".", "UTF8Cache", ".", "get", "(", "ConstantPool", ".", "Clinit", ")", ">=", "constantPoolIndex", ")", "{", "this", ".", "UTF8Cache", ".", "remove", "(", "ConstantPool", ".", "Clinit", ")", ";", "}", "}", "private", "final", "void", "resizePoolContents", "(", "int", "minimalSize", ")", "{", "int", "length", "=", "this", ".", "poolContent", ".", "length", ";", "int", "toAdd", "=", "length", ";", "if", "(", "toAdd", "<", "minimalSize", ")", "toAdd", "=", "minimalSize", ";", "System", ".", "arraycopy", "(", "this", ".", "poolContent", ",", "0", ",", "this", ".", "poolContent", "=", "new", "byte", "[", "length", "+", "toAdd", "]", ",", "0", ",", "length", ")", ";", "}", "protected", "final", "void", "writeU1", "(", "int", "value", ")", "{", "if", "(", "this", ".", "currentOffset", "+", "1", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "1", ")", ";", "}", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "value", ";", "}", "protected", "final", "void", "writeU2", "(", "int", "value", ")", "{", "if", "(", "this", ".", "currentOffset", "+", "2", ">=", "this", ".", "poolContent", ".", "length", ")", "{", "resizePoolContents", "(", "2", ")", ";", "}", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "value", ">>>", "8", ")", ";", "this", ".", "poolContent", "[", "this", ".", "currentOffset", "++", "]", "=", "(", "byte", ")", "value", ";", "}", "public", "void", "reset", "(", ")", "{", "if", "(", "this", ".", "doubleCache", "!=", "null", ")", "this", ".", "doubleCache", ".", "clear", "(", ")", ";", "if", "(", "this", ".", "floatCache", "!=", "null", ")", "this", ".", "floatCache", ".", "clear", "(", ")", ";", "if", "(", "this", ".", "intCache", "!=", "null", ")", "this", ".", "intCache", ".", "clear", "(", ")", ";", "if", "(", "this", ".", "longCache", "!=", "null", ")", "this", ".", "longCache", ".", "clear", "(", ")", ";", "this", ".", "UTF8Cache", ".", "clear", "(", ")", ";", "this", ".", "stringCache", ".", "clear", "(", ")", ";", "this", ".", "methodsAndFieldsCache", ".", "clear", "(", ")", ";", "this", ".", "classCache", ".", "clear", "(", ")", ";", "this", ".", "nameAndTypeCacheForFieldsAndMethods", ".", "clear", "(", ")", ";", "this", ".", "currentIndex", "=", "1", ";", "this", ".", "currentOffset", "=", "0", ";", "}", "public", "void", "resetForAttributeName", "(", "char", "[", "]", "attributeName", ",", "int", "constantPoolIndex", ",", "int", "constantPoolOffset", ")", "{", "this", ".", "currentIndex", "=", "constantPoolIndex", ";", "this", ".", "currentOffset", "=", "constantPoolOffset", ";", "if", "(", "this", ".", "UTF8Cache", ".", "get", "(", "attributeName", ")", ">=", "constantPoolIndex", ")", "{", "this", ".", "UTF8Cache", ".", "remove", "(", "attributeName", ")", ";", "}", "}", "}", "</s>" ]
5,550
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "public", "class", "DoubleCache", "{", "private", "double", "keyTable", "[", "]", ";", "private", "int", "valueTable", "[", "]", ";", "private", "int", "elementSize", ";", "public", "DoubleCache", "(", ")", "{", "this", "(", "13", ")", ";", "}", "public", "DoubleCache", "(", "int", "initialCapacity", ")", "{", "this", ".", "elementSize", "=", "0", ";", "this", ".", "keyTable", "=", "new", "double", "[", "initialCapacity", "]", ";", "this", ".", "valueTable", "=", "new", "int", "[", "initialCapacity", "]", ";", "}", "public", "void", "clear", "(", ")", "{", "for", "(", "int", "i", "=", "this", ".", "keyTable", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "{", "this", ".", "keyTable", "[", "i", "]", "=", "0.0", ";", "this", ".", "valueTable", "[", "i", "]", "=", "0", ";", "}", "this", ".", "elementSize", "=", "0", ";", "}", "public", "boolean", "containsKey", "(", "double", "key", ")", "{", "if", "(", "key", "==", "0.0", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "elementSize", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "this", ".", "keyTable", "[", "i", "]", "==", "0.0", ")", "{", "long", "value1", "=", "Double", ".", "doubleToLongBits", "(", "key", ")", ";", "long", "value2", "=", "Double", ".", "doubleToLongBits", "(", "this", ".", "keyTable", "[", "i", "]", ")", ";", "if", "(", "value1", "==", "-", "9223372036854775808L", "&&", "value2", "==", "-", "9223372036854775808L", ")", "return", "true", ";", "if", "(", "value1", "==", "0", "&&", "value2", "==", "0", ")", "return", "true", ";", "}", "}", "}", "else", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "elementSize", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "this", ".", "keyTable", "[", "i", "]", "==", "key", ")", "{", "return", "true", ";", "}", "}", "}", "return", "false", ";", "}", "public", "int", "put", "(", "double", "key", ",", "int", "value", ")", "{", "if", "(", "this", ".", "elementSize", "==", "this", ".", "keyTable", ".", "length", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "keyTable", ",", "0", ",", "(", "this", ".", "keyTable", "=", "new", "double", "[", "this", ".", "elementSize", "*", "2", "]", ")", ",", "0", ",", "this", ".", "elementSize", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "valueTable", ",", "0", ",", "(", "this", ".", "valueTable", "=", "new", "int", "[", "this", ".", "elementSize", "*", "2", "]", ")", ",", "0", ",", "this", ".", "elementSize", ")", ";", "}", "this", ".", "keyTable", "[", "this", ".", "elementSize", "]", "=", "key", ";", "this", ".", "valueTable", "[", "this", ".", "elementSize", "]", "=", "value", ";", "this", ".", "elementSize", "++", ";", "return", "value", ";", "}", "public", "int", "putIfAbsent", "(", "double", "key", ",", "int", "value", ")", "{", "if", "(", "key", "==", "0.0", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "elementSize", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "this", ".", "keyTable", "[", "i", "]", "==", "0.0", ")", "{", "long", "value1", "=", "Double", ".", "doubleToLongBits", "(", "key", ")", ";", "long", "value2", "=", "Double", ".", "doubleToLongBits", "(", "this", ".", "keyTable", "[", "i", "]", ")", ";", "if", "(", "value1", "==", "-", "9223372036854775808L", "&&", "value2", "==", "-", "9223372036854775808L", ")", "return", "this", ".", "valueTable", "[", "i", "]", ";", "if", "(", "value1", "==", "0", "&&", "value2", "==", "0", ")", "return", "this", ".", "valueTable", "[", "i", "]", ";", "}", "}", "}", "else", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "elementSize", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "this", ".", "keyTable", "[", "i", "]", "==", "key", ")", "{", "return", "this", ".", "valueTable", "[", "i", "]", ";", "}", "}", "}", "if", "(", "this", ".", "elementSize", "==", "this", ".", "keyTable", ".", "length", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "keyTable", ",", "0", ",", "(", "this", ".", "keyTable", "=", "new", "double", "[", "this", ".", "elementSize", "*", "2", "]", ")", ",", "0", ",", "this", ".", "elementSize", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "valueTable", ",", "0", ",", "(", "this", ".", "valueTable", "=", "new", "int", "[", "this", ".", "elementSize", "*", "2", "]", ")", ",", "0", ",", "this", ".", "elementSize", ")", ";", "}", "this", ".", "keyTable", "[", "this", ".", "elementSize", "]", "=", "key", ";", "this", ".", "valueTable", "[", "this", ".", "elementSize", "]", "=", "value", ";", "this", ".", "elementSize", "++", ";", "return", "-", "value", ";", "}", "public", "String", "toString", "(", ")", "{", "int", "max", "=", "this", ".", "elementSize", ";", "StringBuffer", "buf", "=", "new", "StringBuffer", "(", ")", ";", "buf", ".", "append", "(", "\"{\"", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "max", ";", "++", "i", ")", "{", "if", "(", "(", "this", ".", "keyTable", "[", "i", "]", "!=", "0", ")", "||", "(", "(", "this", ".", "keyTable", "[", "i", "]", "==", "0", ")", "&&", "(", "this", ".", "valueTable", "[", "i", "]", "!=", "0", ")", ")", ")", "{", "buf", ".", "append", "(", "this", ".", "keyTable", "[", "i", "]", ")", ".", "append", "(", "\"->\"", ")", ".", "append", "(", "this", ".", "valueTable", "[", "i", "]", ")", ";", "}", "if", "(", "i", "<", "max", ")", "{", "buf", ".", "append", "(", "\",", "\"", ")", ";", "}", "}", "buf", ".", "append", "(", "\"}\"", ")", ";", "return", "buf", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
5,551
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "public", "class", "IntegerCache", "{", "public", "int", "keyTable", "[", "]", ";", "public", "int", "valueTable", "[", "]", ";", "int", "elementSize", ";", "int", "threshold", ";", "public", "IntegerCache", "(", ")", "{", "this", "(", "13", ")", ";", "}", "public", "IntegerCache", "(", "int", "initialCapacity", ")", "{", "this", ".", "elementSize", "=", "0", ";", "this", ".", "threshold", "=", "(", "int", ")", "(", "initialCapacity", "*", "0.66", ")", ";", "this", ".", "keyTable", "=", "new", "int", "[", "initialCapacity", "]", ";", "this", ".", "valueTable", "=", "new", "int", "[", "initialCapacity", "]", ";", "}", "public", "void", "clear", "(", ")", "{", "for", "(", "int", "i", "=", "this", ".", "keyTable", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "{", "this", ".", "keyTable", "[", "i", "]", "=", "0", ";", "this", ".", "valueTable", "[", "i", "]", "=", "0", ";", "}", "this", ".", "elementSize", "=", "0", ";", "}", "public", "boolean", "containsKey", "(", "int", "key", ")", "{", "int", "index", "=", "hash", "(", "key", ")", ",", "length", "=", "this", ".", "keyTable", ".", "length", ";", "while", "(", "(", "this", ".", "keyTable", "[", "index", "]", "!=", "0", ")", "||", "(", "(", "this", ".", "keyTable", "[", "index", "]", "==", "0", ")", "&&", "(", "this", ".", "valueTable", "[", "index", "]", "!=", "0", ")", ")", ")", "{", "if", "(", "this", ".", "keyTable", "[", "index", "]", "==", "key", ")", "return", "true", ";", "if", "(", "++", "index", "==", "length", ")", "{", "index", "=", "0", ";", "}", "}", "return", "false", ";", "}", "public", "int", "hash", "(", "int", "key", ")", "{", "return", "(", "key", "&", "0x7FFFFFFF", ")", "%", "this", ".", "keyTable", ".", "length", ";", "}", "public", "int", "put", "(", "int", "key", ",", "int", "value", ")", "{", "int", "index", "=", "hash", "(", "key", ")", ",", "length", "=", "this", ".", "keyTable", ".", "length", ";", "while", "(", "(", "this", ".", "keyTable", "[", "index", "]", "!=", "0", ")", "||", "(", "(", "this", ".", "keyTable", "[", "index", "]", "==", "0", ")", "&&", "(", "this", ".", "valueTable", "[", "index", "]", "!=", "0", ")", ")", ")", "{", "if", "(", "this", ".", "keyTable", "[", "index", "]", "==", "key", ")", "return", "this", ".", "valueTable", "[", "index", "]", "=", "value", ";", "if", "(", "++", "index", "==", "length", ")", "{", "index", "=", "0", ";", "}", "}", "this", ".", "keyTable", "[", "index", "]", "=", "key", ";", "this", ".", "valueTable", "[", "index", "]", "=", "value", ";", "if", "(", "++", "this", ".", "elementSize", ">", "this", ".", "threshold", ")", "{", "rehash", "(", ")", ";", "}", "return", "value", ";", "}", "public", "int", "putIfAbsent", "(", "int", "key", ",", "int", "value", ")", "{", "int", "index", "=", "hash", "(", "key", ")", ",", "length", "=", "this", ".", "keyTable", ".", "length", ";", "while", "(", "(", "this", ".", "keyTable", "[", "index", "]", "!=", "0", ")", "||", "(", "(", "this", ".", "keyTable", "[", "index", "]", "==", "0", ")", "&&", "(", "this", ".", "valueTable", "[", "index", "]", "!=", "0", ")", ")", ")", "{", "if", "(", "this", ".", "keyTable", "[", "index", "]", "==", "key", ")", "return", "this", ".", "valueTable", "[", "index", "]", ";", "if", "(", "++", "index", "==", "length", ")", "{", "index", "=", "0", ";", "}", "}", "this", ".", "keyTable", "[", "index", "]", "=", "key", ";", "this", ".", "valueTable", "[", "index", "]", "=", "value", ";", "if", "(", "++", "this", ".", "elementSize", ">", "this", ".", "threshold", ")", "{", "rehash", "(", ")", ";", "}", "return", "-", "value", ";", "}", "private", "void", "rehash", "(", ")", "{", "IntegerCache", "newHashtable", "=", "new", "IntegerCache", "(", "this", ".", "keyTable", ".", "length", "*", "2", ")", ";", "for", "(", "int", "i", "=", "this", ".", "keyTable", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "{", "int", "key", "=", "this", ".", "keyTable", "[", "i", "]", ";", "int", "value", "=", "this", ".", "valueTable", "[", "i", "]", ";", "if", "(", "(", "key", "!=", "0", ")", "||", "(", "(", "key", "==", "0", ")", "&&", "(", "value", "!=", "0", ")", ")", ")", "{", "newHashtable", ".", "put", "(", "key", ",", "value", ")", ";", "}", "}", "this", ".", "keyTable", "=", "newHashtable", ".", "keyTable", ";", "this", ".", "valueTable", "=", "newHashtable", ".", "valueTable", ";", "this", ".", "threshold", "=", "newHashtable", ".", "threshold", ";", "}", "public", "int", "size", "(", ")", "{", "return", "this", ".", "elementSize", ";", "}", "public", "String", "toString", "(", ")", "{", "int", "max", "=", "size", "(", ")", ";", "StringBuffer", "buf", "=", "new", "StringBuffer", "(", ")", ";", "buf", ".", "append", "(", "\"{\"", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "max", ";", "++", "i", ")", "{", "if", "(", "(", "this", ".", "keyTable", "[", "i", "]", "!=", "0", ")", "||", "(", "(", "this", ".", "keyTable", "[", "i", "]", "==", "0", ")", "&&", "(", "this", ".", "valueTable", "[", "i", "]", "!=", "0", ")", ")", ")", "{", "buf", ".", "append", "(", "this", ".", "keyTable", "[", "i", "]", ")", ".", "append", "(", "\"->\"", ")", ".", "append", "(", "this", ".", "valueTable", "[", "i", "]", ")", ";", "}", "if", "(", "i", "<", "max", ")", "{", "buf", ".", "append", "(", "\",", "\"", ")", ";", "}", "}", "buf", ".", "append", "(", "\"}\"", ")", ";", "return", "buf", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
5,552
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "import", "java", ".", "text", ".", "MessageFormat", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeIds", ";", "public", "class", "StackMapFrame", "{", "public", "static", "final", "int", "USED", "=", "1", ";", "public", "static", "final", "int", "SAME_FRAME", "=", "0", ";", "public", "static", "final", "int", "CHOP_FRAME", "=", "1", ";", "public", "static", "final", "int", "APPEND_FRAME", "=", "2", ";", "public", "static", "final", "int", "SAME_FRAME_EXTENDED", "=", "3", ";", "public", "static", "final", "int", "FULL_FRAME", "=", "4", ";", "public", "static", "final", "int", "SAME_LOCALS_1_STACK_ITEMS", "=", "5", ";", "public", "static", "final", "int", "SAME_LOCALS_1_STACK_ITEMS_EXTENDED", "=", "6", ";", "public", "int", "pc", ";", "public", "int", "numberOfStackItems", ";", "private", "int", "numberOfLocals", ";", "public", "int", "localIndex", ";", "public", "VerificationTypeInfo", "[", "]", "locals", ";", "public", "VerificationTypeInfo", "[", "]", "stackItems", ";", "private", "int", "numberOfDifferentLocals", "=", "-", "1", ";", "public", "int", "tagBits", ";", "public", "StackMapFrame", "(", "int", "initialLocalSize", ")", "{", "this", ".", "locals", "=", "new", "VerificationTypeInfo", "[", "initialLocalSize", "]", ";", "this", ".", "numberOfLocals", "=", "-", "1", ";", "this", ".", "numberOfDifferentLocals", "=", "-", "1", ";", "}", "public", "int", "getFrameType", "(", "StackMapFrame", "prevFrame", ")", "{", "final", "int", "offsetDelta", "=", "getOffsetDelta", "(", "prevFrame", ")", ";", "switch", "(", "this", ".", "numberOfStackItems", ")", "{", "case", "0", ":", "switch", "(", "numberOfDifferentLocals", "(", "prevFrame", ")", ")", "{", "case", "0", ":", "return", "offsetDelta", "<=", "63", "?", "SAME_FRAME", ":", "SAME_FRAME_EXTENDED", ";", "case", "1", ":", "case", "2", ":", "case", "3", ":", "return", "APPEND_FRAME", ";", "case", "-", "1", ":", "case", "-", "2", ":", "case", "-", "3", ":", "return", "CHOP_FRAME", ";", "}", "break", ";", "case", "1", ":", "switch", "(", "numberOfDifferentLocals", "(", "prevFrame", ")", ")", "{", "case", "0", ":", "return", "offsetDelta", "<=", "63", "?", "SAME_LOCALS_1_STACK_ITEMS", ":", "SAME_LOCALS_1_STACK_ITEMS_EXTENDED", ";", "}", "}", "return", "FULL_FRAME", ";", "}", "public", "void", "addLocal", "(", "int", "resolvedPosition", ",", "VerificationTypeInfo", "info", ")", "{", "if", "(", "this", ".", "locals", "==", "null", ")", "{", "this", ".", "locals", "=", "new", "VerificationTypeInfo", "[", "resolvedPosition", "+", "1", "]", ";", "this", ".", "locals", "[", "resolvedPosition", "]", "=", "info", ";", "}", "else", "{", "final", "int", "length", "=", "this", ".", "locals", ".", "length", ";", "if", "(", "resolvedPosition", ">=", "length", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "locals", ",", "0", ",", "this", ".", "locals", "=", "new", "VerificationTypeInfo", "[", "resolvedPosition", "+", "1", "]", ",", "0", ",", "length", ")", ";", "}", "this", ".", "locals", "[", "resolvedPosition", "]", "=", "info", ";", "}", "}", "public", "void", "addStackItem", "(", "VerificationTypeInfo", "info", ")", "{", "if", "(", "info", "==", "null", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"\"", ")", ";", "}", "if", "(", "this", ".", "stackItems", "==", "null", ")", "{", "this", ".", "stackItems", "=", "new", "VerificationTypeInfo", "[", "1", "]", ";", "this", ".", "stackItems", "[", "0", "]", "=", "info", ";", "this", ".", "numberOfStackItems", "=", "1", ";", "}", "else", "{", "final", "int", "length", "=", "this", ".", "stackItems", ".", "length", ";", "if", "(", "this", ".", "numberOfStackItems", "==", "length", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "stackItems", ",", "0", ",", "this", ".", "stackItems", "=", "new", "VerificationTypeInfo", "[", "length", "+", "1", "]", ",", "0", ",", "length", ")", ";", "}", "this", ".", "stackItems", "[", "this", ".", "numberOfStackItems", "++", "]", "=", "info", ";", "}", "}", "public", "void", "addStackItem", "(", "TypeBinding", "binding", ")", "{", "if", "(", "this", ".", "stackItems", "==", "null", ")", "{", "this", ".", "stackItems", "=", "new", "VerificationTypeInfo", "[", "1", "]", ";", "this", ".", "stackItems", "[", "0", "]", "=", "new", "VerificationTypeInfo", "(", "binding", ")", ";", "this", ".", "numberOfStackItems", "=", "1", ";", "}", "else", "{", "final", "int", "length", "=", "this", ".", "stackItems", ".", "length", ";", "if", "(", "this", ".", "numberOfStackItems", "==", "length", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "stackItems", ",", "0", ",", "this", ".", "stackItems", "=", "new", "VerificationTypeInfo", "[", "length", "+", "1", "]", ",", "0", ",", "length", ")", ";", "}", "this", ".", "stackItems", "[", "this", ".", "numberOfStackItems", "++", "]", "=", "new", "VerificationTypeInfo", "(", "binding", ")", ";", "}", "}", "public", "StackMapFrame", "duplicate", "(", ")", "{", "int", "length", "=", "this", ".", "locals", ".", "length", ";", "StackMapFrame", "result", "=", "new", "StackMapFrame", "(", "length", ")", ";", "result", ".", "numberOfLocals", "=", "-", "1", ";", "result", ".", "numberOfDifferentLocals", "=", "-", "1", ";", "result", ".", "pc", "=", "this", ".", "pc", ";", "result", ".", "numberOfStackItems", "=", "this", ".", "numberOfStackItems", ";", "if", "(", "length", "!=", "0", ")", "{", "result", ".", "locals", "=", "new", "VerificationTypeInfo", "[", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "final", "VerificationTypeInfo", "verificationTypeInfo", "=", "this", ".", "locals", "[", "i", "]", ";", "if", "(", "verificationTypeInfo", "!=", "null", ")", "{", "result", ".", "locals", "[", "i", "]", "=", "verificationTypeInfo", ".", "duplicate", "(", ")", ";", "}", "}", "}", "length", "=", "this", ".", "numberOfStackItems", ";", "if", "(", "length", "!=", "0", ")", "{", "result", ".", "stackItems", "=", "new", "VerificationTypeInfo", "[", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "result", ".", "stackItems", "[", "i", "]", "=", "this", ".", "stackItems", "[", "i", "]", ".", "duplicate", "(", ")", ";", "}", "}", "return", "result", ";", "}", "public", "int", "numberOfDifferentLocals", "(", "StackMapFrame", "prevFrame", ")", "{", "if", "(", "this", ".", "numberOfDifferentLocals", "!=", "-", "1", ")", "return", "this", ".", "numberOfDifferentLocals", ";", "if", "(", "prevFrame", "==", "null", ")", "{", "this", ".", "numberOfDifferentLocals", "=", "0", ";", "return", "0", ";", "}", "VerificationTypeInfo", "[", "]", "prevLocals", "=", "prevFrame", ".", "locals", ";", "VerificationTypeInfo", "[", "]", "currentLocals", "=", "this", ".", "locals", ";", "int", "prevLocalsLength", "=", "prevLocals", "==", "null", "?", "0", ":", "prevLocals", ".", "length", ";", "int", "currentLocalsLength", "=", "currentLocals", "==", "null", "?", "0", ":", "currentLocals", ".", "length", ";", "int", "prevNumberOfLocals", "=", "prevFrame", ".", "getNumberOfLocals", "(", ")", ";", "int", "currentNumberOfLocals", "=", "getNumberOfLocals", "(", ")", ";", "int", "result", "=", "0", ";", "if", "(", "prevNumberOfLocals", "==", "0", ")", "{", "if", "(", "currentNumberOfLocals", "!=", "0", ")", "{", "result", "=", "currentNumberOfLocals", ";", "int", "counter", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "currentLocalsLength", "&&", "counter", "<", "currentNumberOfLocals", ";", "i", "++", ")", "{", "if", "(", "currentLocals", "[", "i", "]", "!=", "null", ")", "{", "switch", "(", "currentLocals", "[", "i", "]", ".", "id", "(", ")", ")", "{", "case", "TypeIds", ".", "T_double", ":", "case", "TypeIds", ".", "T_long", ":", "i", "++", ";", "}", "counter", "++", ";", "}", "else", "{", "result", "=", "Integer", ".", "MAX_VALUE", ";", "this", ".", "numberOfDifferentLocals", "=", "result", ";", "return", "result", ";", "}", "}", "}", "}", "else", "if", "(", "currentNumberOfLocals", "==", "0", ")", "{", "int", "counter", "=", "0", ";", "result", "=", "-", "prevNumberOfLocals", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "prevLocalsLength", "&&", "counter", "<", "prevNumberOfLocals", ";", "i", "++", ")", "{", "if", "(", "prevLocals", "[", "i", "]", "!=", "null", ")", "{", "switch", "(", "prevLocals", "[", "i", "]", ".", "id", "(", ")", ")", "{", "case", "TypeIds", ".", "T_double", ":", "case", "TypeIds", ".", "T_long", ":", "i", "++", ";", "}", "counter", "++", ";", "}", "else", "{", "result", "=", "Integer", ".", "MAX_VALUE", ";", "this", ".", "numberOfDifferentLocals", "=", "result", ";", "return", "result", ";", "}", "}", "}", "else", "{", "int", "indexInPrevLocals", "=", "0", ";", "int", "indexInCurrentLocals", "=", "0", ";", "int", "currentLocalsCounter", "=", "0", ";", "int", "prevLocalsCounter", "=", "0", ";", "currentLocalsLoop", ":", "for", "(", ";", "indexInCurrentLocals", "<", "currentLocalsLength", "&&", "currentLocalsCounter", "<", "currentNumberOfLocals", ";", "indexInCurrentLocals", "++", ")", "{", "VerificationTypeInfo", "currentLocal", "=", "currentLocals", "[", "indexInCurrentLocals", "]", ";", "if", "(", "currentLocal", "!=", "null", ")", "{", "currentLocalsCounter", "++", ";", "switch", "(", "currentLocal", ".", "id", "(", ")", ")", "{", "case", "TypeIds", ".", "T_double", ":", "case", "TypeIds", ".", "T_long", ":", "indexInCurrentLocals", "++", ";", "}", "}", "if", "(", "indexInPrevLocals", "<", "prevLocalsLength", "&&", "prevLocalsCounter", "<", "prevNumberOfLocals", ")", "{", "VerificationTypeInfo", "prevLocal", "=", "prevLocals", "[", "indexInPrevLocals", "]", ";", "if", "(", "prevLocal", "!=", "null", ")", "{", "prevLocalsCounter", "++", ";", "switch", "(", "prevLocal", ".", "id", "(", ")", ")", "{", "case", "TypeIds", ".", "T_double", ":", "case", "TypeIds", ".", "T_long", ":", "indexInPrevLocals", "++", ";", "}", "}", "if", "(", "equals", "(", "prevLocal", ",", "currentLocal", ")", "&&", "indexInPrevLocals", "==", "indexInCurrentLocals", ")", "{", "if", "(", "result", "!=", "0", ")", "{", "result", "=", "Integer", ".", "MAX_VALUE", ";", "this", ".", "numberOfDifferentLocals", "=", "result", ";", "return", "result", ";", "}", "}", "else", "{", "result", "=", "Integer", ".", "MAX_VALUE", ";", "this", ".", "numberOfDifferentLocals", "=", "result", ";", "return", "result", ";", "}", "indexInPrevLocals", "++", ";", "continue", "currentLocalsLoop", ";", "}", "if", "(", "currentLocal", "!=", "null", ")", "{", "result", "++", ";", "}", "else", "{", "result", "=", "Integer", ".", "MAX_VALUE", ";", "this", ".", "numberOfDifferentLocals", "=", "result", ";", "return", "result", ";", "}", "indexInCurrentLocals", "++", ";", "break", "currentLocalsLoop", ";", "}", "if", "(", "currentLocalsCounter", "<", "currentNumberOfLocals", ")", "{", "for", "(", ";", "indexInCurrentLocals", "<", "currentLocalsLength", "&&", "currentLocalsCounter", "<", "currentNumberOfLocals", ";", "indexInCurrentLocals", "++", ")", "{", "VerificationTypeInfo", "currentLocal", "=", "currentLocals", "[", "indexInCurrentLocals", "]", ";", "if", "(", "currentLocal", "==", "null", ")", "{", "result", "=", "Integer", ".", "MAX_VALUE", ";", "this", ".", "numberOfDifferentLocals", "=", "result", ";", "return", "result", ";", "}", "result", "++", ";", "currentLocalsCounter", "++", ";", "switch", "(", "currentLocal", ".", "id", "(", ")", ")", "{", "case", "TypeIds", ".", "T_double", ":", "case", "TypeIds", ".", "T_long", ":", "indexInCurrentLocals", "++", ";", "}", "}", "}", "else", "if", "(", "prevLocalsCounter", "<", "prevNumberOfLocals", ")", "{", "result", "=", "-", "result", ";", "for", "(", ";", "indexInPrevLocals", "<", "prevLocalsLength", "&&", "prevLocalsCounter", "<", "prevNumberOfLocals", ";", "indexInPrevLocals", "++", ")", "{", "VerificationTypeInfo", "prevLocal", "=", "prevLocals", "[", "indexInPrevLocals", "]", ";", "if", "(", "prevLocal", "==", "null", ")", "{", "result", "=", "Integer", ".", "MAX_VALUE", ";", "this", ".", "numberOfDifferentLocals", "=", "result", ";", "return", "result", ";", "}", "result", "--", ";", "prevLocalsCounter", "++", ";", "switch", "(", "prevLocal", ".", "id", "(", ")", ")", "{", "case", "TypeIds", ".", "T_double", ":", "case", "TypeIds", ".", "T_long", ":", "indexInPrevLocals", "++", ";", "}", "}", "}", "}", "this", ".", "numberOfDifferentLocals", "=", "result", ";", "return", "result", ";", "}", "public", "int", "getNumberOfLocals", "(", ")", "{", "if", "(", "this", ".", "numberOfLocals", "!=", "-", "1", ")", "{", "return", "this", ".", "numberOfLocals", ";", "}", "int", "result", "=", "0", ";", "final", "int", "length", "=", "this", ".", "locals", "==", "null", "?", "0", ":", "this", ".", "locals", ".", "length", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "this", ".", "locals", "[", "i", "]", "!=", "null", ")", "{", "switch", "(", "this", ".", "locals", "[", "i", "]", ".", "id", "(", ")", ")", "{", "case", "TypeIds", ".", "T_double", ":", "case", "TypeIds", ".", "T_long", ":", "i", "++", ";", "}", "result", "++", ";", "}", "}", "this", ".", "numberOfLocals", "=", "result", ";", "return", "result", ";", "}", "public", "int", "getOffsetDelta", "(", "StackMapFrame", "prevFrame", ")", "{", "if", "(", "prevFrame", "==", "null", ")", "return", "this", ".", "pc", ";", "return", "prevFrame", ".", "pc", "==", "-", "1", "?", "this", ".", "pc", ":", "this", ".", "pc", "-", "prevFrame", ".", "pc", "-", "1", ";", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", ")", ";", "printFrame", "(", "buffer", ",", "this", ")", ";", "return", "String", ".", "valueOf", "(", "buffer", ")", ";", "}", "private", "void", "printFrame", "(", "StringBuffer", "buffer", ",", "StackMapFrame", "frame", ")", "{", "String", "pattern", "=", "\"\"", ";", "int", "localsLength", "=", "frame", ".", "locals", "==", "null", "?", "0", ":", "frame", ".", "locals", ".", "length", ";", "buffer", ".", "append", "(", "MessageFormat", ".", "format", "(", "pattern", ",", "new", "String", "[", "]", "{", "Integer", ".", "toString", "(", "frame", ".", "pc", ")", ",", "Integer", ".", "toString", "(", "frame", ".", "getNumberOfLocals", "(", ")", ")", ",", "Integer", ".", "toString", "(", "frame", ".", "numberOfStackItems", ")", ",", "print", "(", "frame", ".", "locals", ",", "localsLength", ")", ",", "print", "(", "frame", ".", "stackItems", ",", "frame", ".", "numberOfStackItems", ")", "}", ")", ")", ";", "}", "private", "String", "print", "(", "VerificationTypeInfo", "[", "]", "infos", ",", "int", "length", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", ")", ";", "buffer", ".", "append", "(", "'['", ")", ";", "if", "(", "infos", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "i", "!=", "0", ")", "buffer", ".", "append", "(", "','", ")", ";", "VerificationTypeInfo", "verificationTypeInfo", "=", "infos", "[", "i", "]", ";", "if", "(", "verificationTypeInfo", "==", "null", ")", "{", "buffer", ".", "append", "(", "\"top\"", ")", ";", "continue", ";", "}", "buffer", ".", "append", "(", "verificationTypeInfo", ")", ";", "}", "}", "buffer", ".", "append", "(", "']'", ")", ";", "return", "String", ".", "valueOf", "(", "buffer", ")", ";", "}", "public", "void", "putLocal", "(", "int", "resolvedPosition", ",", "VerificationTypeInfo", "info", ")", "{", "if", "(", "this", ".", "locals", "==", "null", ")", "{", "this", ".", "locals", "=", "new", "VerificationTypeInfo", "[", "resolvedPosition", "+", "1", "]", ";", "this", ".", "locals", "[", "resolvedPosition", "]", "=", "info", ";", "}", "else", "{", "final", "int", "length", "=", "this", ".", "locals", ".", "length", ";", "if", "(", "resolvedPosition", ">=", "length", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "locals", ",", "0", ",", "this", ".", "locals", "=", "new", "VerificationTypeInfo", "[", "resolvedPosition", "+", "1", "]", ",", "0", ",", "length", ")", ";", "}", "this", ".", "locals", "[", "resolvedPosition", "]", "=", "info", ";", "}", "}", "public", "void", "replaceWithElementType", "(", ")", "{", "VerificationTypeInfo", "info", "=", "this", ".", "stackItems", "[", "this", ".", "numberOfStackItems", "-", "1", "]", ";", "VerificationTypeInfo", "info2", "=", "info", ".", "duplicate", "(", ")", ";", "info2", ".", "replaceWithElementType", "(", ")", ";", "this", ".", "stackItems", "[", "this", ".", "numberOfStackItems", "-", "1", "]", "=", "info2", ";", "}", "public", "int", "getIndexOfDifferentLocals", "(", "int", "differentLocalsCount", ")", "{", "for", "(", "int", "i", "=", "this", ".", "locals", ".", "length", "-", "1", ";", "i", ">=", "0", ";", "i", "--", ")", "{", "VerificationTypeInfo", "currentLocal", "=", "this", ".", "locals", "[", "i", "]", ";", "if", "(", "currentLocal", "==", "null", ")", "{", "continue", ";", "}", "else", "{", "differentLocalsCount", "--", ";", "}", "if", "(", "differentLocalsCount", "==", "0", ")", "{", "return", "i", ";", "}", "}", "return", "0", ";", "}", "private", "boolean", "equals", "(", "VerificationTypeInfo", "info", ",", "VerificationTypeInfo", "info2", ")", "{", "if", "(", "info", "==", "null", ")", "{", "return", "info2", "==", "null", ";", "}", "if", "(", "info2", "==", "null", ")", "return", "false", ";", "return", "info", ".", "equals", "(", "info2", ")", ";", "}", "}", "</s>" ]
5,553
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeIds", ";", "public", "class", "VerificationTypeInfo", "{", "public", "static", "final", "int", "ITEM_TOP", "=", "0", ";", "public", "static", "final", "int", "ITEM_INTEGER", "=", "1", ";", "public", "static", "final", "int", "ITEM_FLOAT", "=", "2", ";", "public", "static", "final", "int", "ITEM_DOUBLE", "=", "3", ";", "public", "static", "final", "int", "ITEM_LONG", "=", "4", ";", "public", "static", "final", "int", "ITEM_NULL", "=", "5", ";", "public", "static", "final", "int", "ITEM_UNINITIALIZED_THIS", "=", "6", ";", "public", "static", "final", "int", "ITEM_OBJECT", "=", "7", ";", "public", "static", "final", "int", "ITEM_UNINITIALIZED", "=", "8", ";", "public", "int", "tag", ";", "private", "int", "id", ";", "private", "char", "[", "]", "constantPoolName", ";", "public", "int", "offset", ";", "private", "VerificationTypeInfo", "(", ")", "{", "}", "public", "VerificationTypeInfo", "(", "int", "id", ",", "char", "[", "]", "constantPoolName", ")", "{", "this", "(", "id", ",", "VerificationTypeInfo", ".", "ITEM_OBJECT", ",", "constantPoolName", ")", ";", "}", "public", "VerificationTypeInfo", "(", "int", "id", ",", "int", "tag", ",", "char", "[", "]", "constantPoolName", ")", "{", "this", ".", "id", "=", "id", ";", "this", ".", "tag", "=", "tag", ";", "this", ".", "constantPoolName", "=", "constantPoolName", ";", "}", "public", "VerificationTypeInfo", "(", "int", "tag", ",", "TypeBinding", "binding", ")", "{", "this", "(", "binding", ")", ";", "this", ".", "tag", "=", "tag", ";", "}", "public", "VerificationTypeInfo", "(", "TypeBinding", "binding", ")", "{", "this", ".", "id", "=", "binding", ".", "id", ";", "switch", "(", "binding", ".", "id", ")", "{", "case", "TypeIds", ".", "T_boolean", ":", "case", "TypeIds", ".", "T_byte", ":", "case", "TypeIds", ".", "T_char", ":", "case", "TypeIds", ".", "T_int", ":", "case", "TypeIds", ".", "T_short", ":", "this", ".", "tag", "=", "VerificationTypeInfo", ".", "ITEM_INTEGER", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "this", ".", "tag", "=", "VerificationTypeInfo", ".", "ITEM_FLOAT", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "this", ".", "tag", "=", "VerificationTypeInfo", ".", "ITEM_LONG", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "this", ".", "tag", "=", "VerificationTypeInfo", ".", "ITEM_DOUBLE", ";", "break", ";", "case", "TypeIds", ".", "T_null", ":", "this", ".", "tag", "=", "VerificationTypeInfo", ".", "ITEM_NULL", ";", "break", ";", "default", ":", "this", ".", "tag", "=", "VerificationTypeInfo", ".", "ITEM_OBJECT", ";", "this", ".", "constantPoolName", "=", "binding", ".", "constantPoolName", "(", ")", ";", "}", "}", "public", "void", "setBinding", "(", "TypeBinding", "binding", ")", "{", "this", ".", "constantPoolName", "=", "binding", ".", "constantPoolName", "(", ")", ";", "final", "int", "typeBindingId", "=", "binding", ".", "id", ";", "this", ".", "id", "=", "typeBindingId", ";", "switch", "(", "typeBindingId", ")", "{", "case", "TypeIds", ".", "T_boolean", ":", "case", "TypeIds", ".", "T_byte", ":", "case", "TypeIds", ".", "T_char", ":", "case", "TypeIds", ".", "T_int", ":", "case", "TypeIds", ".", "T_short", ":", "this", ".", "tag", "=", "VerificationTypeInfo", ".", "ITEM_INTEGER", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "this", ".", "tag", "=", "VerificationTypeInfo", ".", "ITEM_FLOAT", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "this", ".", "tag", "=", "VerificationTypeInfo", ".", "ITEM_LONG", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "this", ".", "tag", "=", "VerificationTypeInfo", ".", "ITEM_DOUBLE", ";", "break", ";", "case", "TypeIds", ".", "T_null", ":", "this", ".", "tag", "=", "VerificationTypeInfo", ".", "ITEM_NULL", ";", "break", ";", "default", ":", "this", ".", "tag", "=", "VerificationTypeInfo", ".", "ITEM_OBJECT", ";", "}", "}", "public", "int", "id", "(", ")", "{", "return", "this", ".", "id", ";", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", ")", ";", "switch", "(", "this", ".", "tag", ")", "{", "case", "VerificationTypeInfo", ".", "ITEM_UNINITIALIZED_THIS", ":", "buffer", ".", "append", "(", "\"\"", ")", ".", "append", "(", "readableName", "(", ")", ")", ".", "append", "(", "\")\"", ")", ";", "break", ";", "case", "VerificationTypeInfo", ".", "ITEM_UNINITIALIZED", ":", "buffer", ".", "append", "(", "\"\"", ")", ".", "append", "(", "readableName", "(", ")", ")", ".", "append", "(", "\")\"", ")", ";", "break", ";", "case", "VerificationTypeInfo", ".", "ITEM_OBJECT", ":", "buffer", ".", "append", "(", "readableName", "(", ")", ")", ";", "break", ";", "case", "VerificationTypeInfo", ".", "ITEM_DOUBLE", ":", "buffer", ".", "append", "(", "'D'", ")", ";", "break", ";", "case", "VerificationTypeInfo", ".", "ITEM_FLOAT", ":", "buffer", ".", "append", "(", "'F'", ")", ";", "break", ";", "case", "VerificationTypeInfo", ".", "ITEM_INTEGER", ":", "buffer", ".", "append", "(", "'I'", ")", ";", "break", ";", "case", "VerificationTypeInfo", ".", "ITEM_LONG", ":", "buffer", ".", "append", "(", "'J'", ")", ";", "break", ";", "case", "VerificationTypeInfo", ".", "ITEM_NULL", ":", "buffer", ".", "append", "(", "\"null\"", ")", ";", "break", ";", "case", "VerificationTypeInfo", ".", "ITEM_TOP", ":", "buffer", ".", "append", "(", "\"top\"", ")", ";", "break", ";", "}", "return", "String", ".", "valueOf", "(", "buffer", ")", ";", "}", "public", "VerificationTypeInfo", "duplicate", "(", ")", "{", "final", "VerificationTypeInfo", "verificationTypeInfo", "=", "new", "VerificationTypeInfo", "(", ")", ";", "verificationTypeInfo", ".", "id", "=", "this", ".", "id", ";", "verificationTypeInfo", ".", "tag", "=", "this", ".", "tag", ";", "verificationTypeInfo", ".", "constantPoolName", "=", "this", ".", "constantPoolName", ";", "verificationTypeInfo", ".", "offset", "=", "this", ".", "offset", ";", "return", "verificationTypeInfo", ";", "}", "public", "boolean", "equals", "(", "Object", "obj", ")", "{", "if", "(", "obj", "instanceof", "VerificationTypeInfo", ")", "{", "VerificationTypeInfo", "info1", "=", "(", "VerificationTypeInfo", ")", "obj", ";", "return", "info1", ".", "tag", "==", "this", ".", "tag", "&&", "CharOperation", ".", "equals", "(", "info1", ".", "constantPoolName", "(", ")", ",", "constantPoolName", "(", ")", ")", ";", "}", "return", "false", ";", "}", "public", "int", "hashCode", "(", ")", "{", "return", "this", ".", "tag", "+", "this", ".", "id", "+", "this", ".", "constantPoolName", ".", "length", "+", "this", ".", "offset", ";", "}", "public", "char", "[", "]", "constantPoolName", "(", ")", "{", "return", "this", ".", "constantPoolName", ";", "}", "public", "char", "[", "]", "readableName", "(", ")", "{", "return", "this", ".", "constantPoolName", ";", "}", "public", "void", "replaceWithElementType", "(", ")", "{", "if", "(", "this", ".", "constantPoolName", "[", "1", "]", "==", "'L'", ")", "{", "this", ".", "constantPoolName", "=", "CharOperation", ".", "subarray", "(", "this", ".", "constantPoolName", ",", "2", ",", "this", ".", "constantPoolName", ".", "length", "-", "1", ")", ";", "}", "else", "{", "this", ".", "constantPoolName", "=", "CharOperation", ".", "subarray", "(", "this", ".", "constantPoolName", ",", "1", ",", "this", ".", "constantPoolName", ".", "length", ")", ";", "if", "(", "this", ".", "constantPoolName", ".", "length", "==", "1", ")", "{", "switch", "(", "this", ".", "constantPoolName", "[", "0", "]", ")", "{", "case", "'I'", ":", "this", ".", "id", "=", "TypeIds", ".", "T_int", ";", "break", ";", "case", "'B'", ":", "this", ".", "id", "=", "TypeIds", ".", "T_byte", ";", "break", ";", "case", "'S'", ":", "this", ".", "id", "=", "TypeIds", ".", "T_short", ";", "break", ";", "case", "'C'", ":", "this", ".", "id", "=", "TypeIds", ".", "T_char", ";", "break", ";", "case", "'J'", ":", "this", ".", "id", "=", "TypeIds", ".", "T_long", ";", "break", ";", "case", "'F'", ":", "this", ".", "id", "=", "TypeIds", ".", "T_float", ";", "break", ";", "case", "'D'", ":", "this", ".", "id", "=", "TypeIds", ".", "T_double", ";", "break", ";", "case", "'Z'", ":", "this", ".", "id", "=", "TypeIds", ".", "T_boolean", ";", "break", ";", "case", "'N'", ":", "this", ".", "id", "=", "TypeIds", ".", "T_null", ";", "break", ";", "case", "'V'", ":", "this", ".", "id", "=", "TypeIds", ".", "T_void", ";", "break", ";", "}", "}", "}", "}", "}", "</s>" ]
5,554
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "public", "abstract", "class", "Label", "{", "public", "CodeStream", "codeStream", ";", "public", "int", "position", "=", "POS_NOT_SET", ";", "public", "final", "static", "int", "POS_NOT_SET", "=", "-", "1", ";", "public", "Label", "(", ")", "{", "}", "public", "Label", "(", "CodeStream", "codeStream", ")", "{", "this", ".", "codeStream", "=", "codeStream", ";", "}", "public", "abstract", "void", "place", "(", ")", ";", "}", "</s>" ]
5,555
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "public", "class", "ObjectCache", "{", "public", "Object", "keyTable", "[", "]", ";", "public", "int", "valueTable", "[", "]", ";", "int", "elementSize", ";", "int", "threshold", ";", "public", "ObjectCache", "(", ")", "{", "this", "(", "13", ")", ";", "}", "public", "ObjectCache", "(", "int", "initialCapacity", ")", "{", "this", ".", "elementSize", "=", "0", ";", "this", ".", "threshold", "=", "(", "int", ")", "(", "initialCapacity", "*", "0.66f", ")", ";", "this", ".", "keyTable", "=", "new", "Object", "[", "initialCapacity", "]", ";", "this", ".", "valueTable", "=", "new", "int", "[", "initialCapacity", "]", ";", "}", "public", "void", "clear", "(", ")", "{", "for", "(", "int", "i", "=", "this", ".", "keyTable", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "{", "this", ".", "keyTable", "[", "i", "]", "=", "null", ";", "this", ".", "valueTable", "[", "i", "]", "=", "0", ";", "}", "this", ".", "elementSize", "=", "0", ";", "}", "public", "boolean", "containsKey", "(", "Object", "key", ")", "{", "int", "index", "=", "hashCode", "(", "key", ")", ",", "length", "=", "this", ".", "keyTable", ".", "length", ";", "while", "(", "this", ".", "keyTable", "[", "index", "]", "!=", "null", ")", "{", "if", "(", "this", ".", "keyTable", "[", "index", "]", "==", "key", ")", "return", "true", ";", "if", "(", "++", "index", "==", "length", ")", "{", "index", "=", "0", ";", "}", "}", "return", "false", ";", "}", "public", "int", "get", "(", "Object", "key", ")", "{", "int", "index", "=", "hashCode", "(", "key", ")", ",", "length", "=", "this", ".", "keyTable", ".", "length", ";", "while", "(", "this", ".", "keyTable", "[", "index", "]", "!=", "null", ")", "{", "if", "(", "this", ".", "keyTable", "[", "index", "]", "==", "key", ")", "return", "this", ".", "valueTable", "[", "index", "]", ";", "if", "(", "++", "index", "==", "length", ")", "{", "index", "=", "0", ";", "}", "}", "return", "-", "1", ";", "}", "public", "int", "hashCode", "(", "Object", "key", ")", "{", "return", "(", "key", ".", "hashCode", "(", ")", "&", "0x7FFFFFFF", ")", "%", "this", ".", "keyTable", ".", "length", ";", "}", "public", "int", "put", "(", "Object", "key", ",", "int", "value", ")", "{", "int", "index", "=", "hashCode", "(", "key", ")", ",", "length", "=", "this", ".", "keyTable", ".", "length", ";", "while", "(", "this", ".", "keyTable", "[", "index", "]", "!=", "null", ")", "{", "if", "(", "this", ".", "keyTable", "[", "index", "]", "==", "key", ")", "return", "this", ".", "valueTable", "[", "index", "]", "=", "value", ";", "if", "(", "++", "index", "==", "length", ")", "{", "index", "=", "0", ";", "}", "}", "this", ".", "keyTable", "[", "index", "]", "=", "key", ";", "this", ".", "valueTable", "[", "index", "]", "=", "value", ";", "if", "(", "++", "this", ".", "elementSize", ">", "this", ".", "threshold", ")", "rehash", "(", ")", ";", "return", "value", ";", "}", "private", "void", "rehash", "(", ")", "{", "ObjectCache", "newHashtable", "=", "new", "ObjectCache", "(", "this", ".", "keyTable", ".", "length", "*", "2", ")", ";", "for", "(", "int", "i", "=", "this", ".", "keyTable", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "this", ".", "keyTable", "[", "i", "]", "!=", "null", ")", "newHashtable", ".", "put", "(", "this", ".", "keyTable", "[", "i", "]", ",", "this", ".", "valueTable", "[", "i", "]", ")", ";", "this", ".", "keyTable", "=", "newHashtable", ".", "keyTable", ";", "this", ".", "valueTable", "=", "newHashtable", ".", "valueTable", ";", "this", ".", "threshold", "=", "newHashtable", ".", "threshold", ";", "}", "public", "int", "size", "(", ")", "{", "return", "this", ".", "elementSize", ";", "}", "public", "String", "toString", "(", ")", "{", "int", "max", "=", "size", "(", ")", ";", "StringBuffer", "buf", "=", "new", "StringBuffer", "(", ")", ";", "buf", ".", "append", "(", "\"{\"", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "max", ";", "++", "i", ")", "{", "if", "(", "this", ".", "keyTable", "[", "i", "]", "!=", "null", ")", "{", "buf", ".", "append", "(", "this", ".", "keyTable", "[", "i", "]", ")", ".", "append", "(", "\"->\"", ")", ".", "append", "(", "this", ".", "valueTable", "[", "i", "]", ")", ";", "}", "if", "(", "i", "<", "max", ")", "{", "buf", ".", "append", "(", "\",", "\"", ")", ";", "}", "}", "buf", ".", "append", "(", "\"}\"", ")", ";", "return", "buf", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
5,556
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "public", "class", "FloatCache", "{", "private", "float", "keyTable", "[", "]", ";", "private", "int", "valueTable", "[", "]", ";", "private", "int", "elementSize", ";", "public", "FloatCache", "(", ")", "{", "this", "(", "13", ")", ";", "}", "public", "FloatCache", "(", "int", "initialCapacity", ")", "{", "this", ".", "elementSize", "=", "0", ";", "this", ".", "keyTable", "=", "new", "float", "[", "initialCapacity", "]", ";", "this", ".", "valueTable", "=", "new", "int", "[", "initialCapacity", "]", ";", "}", "public", "void", "clear", "(", ")", "{", "for", "(", "int", "i", "=", "this", ".", "keyTable", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "{", "this", ".", "keyTable", "[", "i", "]", "=", "0.0f", ";", "this", ".", "valueTable", "[", "i", "]", "=", "0", ";", "}", "this", ".", "elementSize", "=", "0", ";", "}", "public", "boolean", "containsKey", "(", "float", "key", ")", "{", "if", "(", "key", "==", "0.0f", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "elementSize", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "this", ".", "keyTable", "[", "i", "]", "==", "0.0f", ")", "{", "int", "value1", "=", "Float", ".", "floatToIntBits", "(", "key", ")", ";", "int", "value2", "=", "Float", ".", "floatToIntBits", "(", "this", ".", "keyTable", "[", "i", "]", ")", ";", "if", "(", "value1", "==", "-", "2147483648", "&&", "value2", "==", "-", "2147483648", ")", "return", "true", ";", "if", "(", "value1", "==", "0", "&&", "value2", "==", "0", ")", "return", "true", ";", "}", "}", "}", "else", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "elementSize", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "this", ".", "keyTable", "[", "i", "]", "==", "key", ")", "{", "return", "true", ";", "}", "}", "}", "return", "false", ";", "}", "public", "int", "put", "(", "float", "key", ",", "int", "value", ")", "{", "if", "(", "this", ".", "elementSize", "==", "this", ".", "keyTable", ".", "length", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "keyTable", ",", "0", ",", "(", "this", ".", "keyTable", "=", "new", "float", "[", "this", ".", "elementSize", "*", "2", "]", ")", ",", "0", ",", "this", ".", "elementSize", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "valueTable", ",", "0", ",", "(", "this", ".", "valueTable", "=", "new", "int", "[", "this", ".", "elementSize", "*", "2", "]", ")", ",", "0", ",", "this", ".", "elementSize", ")", ";", "}", "this", ".", "keyTable", "[", "this", ".", "elementSize", "]", "=", "key", ";", "this", ".", "valueTable", "[", "this", ".", "elementSize", "]", "=", "value", ";", "this", ".", "elementSize", "++", ";", "return", "value", ";", "}", "public", "int", "putIfAbsent", "(", "float", "key", ",", "int", "value", ")", "{", "if", "(", "key", "==", "0.0f", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "elementSize", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "this", ".", "keyTable", "[", "i", "]", "==", "0.0f", ")", "{", "int", "value1", "=", "Float", ".", "floatToIntBits", "(", "key", ")", ";", "int", "value2", "=", "Float", ".", "floatToIntBits", "(", "this", ".", "keyTable", "[", "i", "]", ")", ";", "if", "(", "value1", "==", "-", "2147483648", "&&", "value2", "==", "-", "2147483648", ")", "return", "this", ".", "valueTable", "[", "i", "]", ";", "if", "(", "value1", "==", "0", "&&", "value2", "==", "0", ")", "return", "this", ".", "valueTable", "[", "i", "]", ";", "}", "}", "}", "else", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "elementSize", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "this", ".", "keyTable", "[", "i", "]", "==", "key", ")", "{", "return", "this", ".", "valueTable", "[", "i", "]", ";", "}", "}", "}", "if", "(", "this", ".", "elementSize", "==", "this", ".", "keyTable", ".", "length", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "keyTable", ",", "0", ",", "(", "this", ".", "keyTable", "=", "new", "float", "[", "this", ".", "elementSize", "*", "2", "]", ")", ",", "0", ",", "this", ".", "elementSize", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "valueTable", ",", "0", ",", "(", "this", ".", "valueTable", "=", "new", "int", "[", "this", ".", "elementSize", "*", "2", "]", ")", ",", "0", ",", "this", ".", "elementSize", ")", ";", "}", "this", ".", "keyTable", "[", "this", ".", "elementSize", "]", "=", "key", ";", "this", ".", "valueTable", "[", "this", ".", "elementSize", "]", "=", "value", ";", "this", ".", "elementSize", "++", ";", "return", "-", "value", ";", "}", "public", "String", "toString", "(", ")", "{", "int", "max", "=", "this", ".", "elementSize", ";", "StringBuffer", "buf", "=", "new", "StringBuffer", "(", ")", ";", "buf", ".", "append", "(", "\"{\"", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "max", ";", "++", "i", ")", "{", "if", "(", "(", "this", ".", "keyTable", "[", "i", "]", "!=", "0", ")", "||", "(", "(", "this", ".", "keyTable", "[", "i", "]", "==", "0", ")", "&&", "(", "this", ".", "valueTable", "[", "i", "]", "!=", "0", ")", ")", ")", "{", "buf", ".", "append", "(", "this", ".", "keyTable", "[", "i", "]", ")", ".", "append", "(", "\"->\"", ")", ".", "append", "(", "this", ".", "valueTable", "[", "i", "]", ")", ";", "}", "if", "(", "i", "<", "max", ")", "{", "buf", ".", "append", "(", "\",", "\"", ")", ";", "}", "}", "buf", ".", "append", "(", "\"}\"", ")", ";", "return", "buf", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
5,557
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "public", "class", "CharArrayCache", "{", "public", "char", "[", "]", "keyTable", "[", "]", ";", "public", "int", "valueTable", "[", "]", ";", "int", "elementSize", ";", "int", "threshold", ";", "public", "CharArrayCache", "(", ")", "{", "this", "(", "9", ")", ";", "}", "public", "CharArrayCache", "(", "int", "initialCapacity", ")", "{", "this", ".", "elementSize", "=", "0", ";", "this", ".", "threshold", "=", "(", "initialCapacity", "*", "2", ")", "/", "3", ";", "this", ".", "keyTable", "=", "new", "char", "[", "initialCapacity", "]", "[", "]", ";", "this", ".", "valueTable", "=", "new", "int", "[", "initialCapacity", "]", ";", "}", "public", "void", "clear", "(", ")", "{", "for", "(", "int", "i", "=", "this", ".", "keyTable", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "{", "this", ".", "keyTable", "[", "i", "]", "=", "null", ";", "this", ".", "valueTable", "[", "i", "]", "=", "0", ";", "}", "this", ".", "elementSize", "=", "0", ";", "}", "public", "boolean", "containsKey", "(", "char", "[", "]", "key", ")", "{", "int", "length", "=", "this", ".", "keyTable", ".", "length", ",", "index", "=", "CharOperation", ".", "hashCode", "(", "key", ")", "%", "length", ";", "while", "(", "this", ".", "keyTable", "[", "index", "]", "!=", "null", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "this", ".", "keyTable", "[", "index", "]", ",", "key", ")", ")", "return", "true", ";", "if", "(", "++", "index", "==", "length", ")", "{", "index", "=", "0", ";", "}", "}", "return", "false", ";", "}", "public", "int", "get", "(", "char", "[", "]", "key", ")", "{", "int", "length", "=", "this", ".", "keyTable", ".", "length", ",", "index", "=", "CharOperation", ".", "hashCode", "(", "key", ")", "%", "length", ";", "while", "(", "this", ".", "keyTable", "[", "index", "]", "!=", "null", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "this", ".", "keyTable", "[", "index", "]", ",", "key", ")", ")", "return", "this", ".", "valueTable", "[", "index", "]", ";", "if", "(", "++", "index", "==", "length", ")", "{", "index", "=", "0", ";", "}", "}", "return", "-", "1", ";", "}", "public", "int", "putIfAbsent", "(", "char", "[", "]", "key", ",", "int", "value", ")", "{", "int", "length", "=", "this", ".", "keyTable", ".", "length", ",", "index", "=", "CharOperation", ".", "hashCode", "(", "key", ")", "%", "length", ";", "while", "(", "this", ".", "keyTable", "[", "index", "]", "!=", "null", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "this", ".", "keyTable", "[", "index", "]", ",", "key", ")", ")", "return", "this", ".", "valueTable", "[", "index", "]", ";", "if", "(", "++", "index", "==", "length", ")", "{", "index", "=", "0", ";", "}", "}", "this", ".", "keyTable", "[", "index", "]", "=", "key", ";", "this", ".", "valueTable", "[", "index", "]", "=", "value", ";", "if", "(", "++", "this", ".", "elementSize", ">", "this", ".", "threshold", ")", "rehash", "(", ")", ";", "return", "-", "value", ";", "}", "private", "int", "put", "(", "char", "[", "]", "key", ",", "int", "value", ")", "{", "int", "length", "=", "this", ".", "keyTable", ".", "length", ",", "index", "=", "CharOperation", ".", "hashCode", "(", "key", ")", "%", "length", ";", "while", "(", "this", ".", "keyTable", "[", "index", "]", "!=", "null", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "this", ".", "keyTable", "[", "index", "]", ",", "key", ")", ")", "return", "this", ".", "valueTable", "[", "index", "]", "=", "value", ";", "if", "(", "++", "index", "==", "length", ")", "{", "index", "=", "0", ";", "}", "}", "this", ".", "keyTable", "[", "index", "]", "=", "key", ";", "this", ".", "valueTable", "[", "index", "]", "=", "value", ";", "if", "(", "++", "this", ".", "elementSize", ">", "this", ".", "threshold", ")", "rehash", "(", ")", ";", "return", "value", ";", "}", "private", "void", "rehash", "(", ")", "{", "CharArrayCache", "newHashtable", "=", "new", "CharArrayCache", "(", "this", ".", "keyTable", ".", "length", "*", "2", ")", ";", "for", "(", "int", "i", "=", "this", ".", "keyTable", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "this", ".", "keyTable", "[", "i", "]", "!=", "null", ")", "newHashtable", ".", "put", "(", "this", ".", "keyTable", "[", "i", "]", ",", "this", ".", "valueTable", "[", "i", "]", ")", ";", "this", ".", "keyTable", "=", "newHashtable", ".", "keyTable", ";", "this", ".", "valueTable", "=", "newHashtable", ".", "valueTable", ";", "this", ".", "threshold", "=", "newHashtable", ".", "threshold", ";", "}", "public", "void", "remove", "(", "char", "[", "]", "key", ")", "{", "int", "length", "=", "this", ".", "keyTable", ".", "length", ",", "index", "=", "CharOperation", ".", "hashCode", "(", "key", ")", "%", "length", ";", "while", "(", "this", ".", "keyTable", "[", "index", "]", "!=", "null", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "this", ".", "keyTable", "[", "index", "]", ",", "key", ")", ")", "{", "this", ".", "valueTable", "[", "index", "]", "=", "0", ";", "this", ".", "keyTable", "[", "index", "]", "=", "null", ";", "return", ";", "}", "if", "(", "++", "index", "==", "length", ")", "{", "index", "=", "0", ";", "}", "}", "}", "public", "char", "[", "]", "returnKeyFor", "(", "int", "value", ")", "{", "for", "(", "int", "i", "=", "this", ".", "keyTable", ".", "length", ";", "i", "--", ">", "0", ";", ")", "{", "if", "(", "this", ".", "valueTable", "[", "i", "]", "==", "value", ")", "{", "return", "this", ".", "keyTable", "[", "i", "]", ";", "}", "}", "return", "null", ";", "}", "public", "int", "size", "(", ")", "{", "return", "this", ".", "elementSize", ";", "}", "public", "String", "toString", "(", ")", "{", "int", "max", "=", "size", "(", ")", ";", "StringBuffer", "buf", "=", "new", "StringBuffer", "(", ")", ";", "buf", ".", "append", "(", "\"{\"", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "max", ";", "++", "i", ")", "{", "if", "(", "this", ".", "keyTable", "[", "i", "]", "!=", "null", ")", "{", "buf", ".", "append", "(", "this", ".", "keyTable", "[", "i", "]", ")", ".", "append", "(", "\"->\"", ")", ".", "append", "(", "this", ".", "valueTable", "[", "i", "]", ")", ";", "}", "if", "(", "i", "<", "max", ")", "{", "buf", ".", "append", "(", "\",", "\"", ")", ";", "}", "}", "buf", ".", "append", "(", "\"}\"", ")", ";", "return", "buf", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
5,558
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "Arrays", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "HashSet", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "Set", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ClassFile", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "FieldBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "LocalVariableBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "MethodBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "Scope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeIds", ";", "public", "class", "StackMapFrameCodeStream", "extends", "CodeStream", "{", "public", "static", "class", "ExceptionMarker", "implements", "Comparable", "{", "public", "char", "[", "]", "constantPoolName", ";", "public", "int", "pc", ";", "public", "ExceptionMarker", "(", "int", "pc", ",", "char", "[", "]", "constantPoolName", ")", "{", "this", ".", "pc", "=", "pc", ";", "this", ".", "constantPoolName", "=", "constantPoolName", ";", "}", "public", "int", "compareTo", "(", "Object", "o", ")", "{", "if", "(", "o", "instanceof", "ExceptionMarker", ")", "{", "return", "this", ".", "pc", "-", "(", "(", "ExceptionMarker", ")", "o", ")", ".", "pc", ";", "}", "return", "0", ";", "}", "public", "boolean", "equals", "(", "Object", "obj", ")", "{", "if", "(", "obj", "instanceof", "ExceptionMarker", ")", "{", "ExceptionMarker", "marker", "=", "(", "ExceptionMarker", ")", "obj", ";", "return", "this", ".", "pc", "==", "marker", ".", "pc", "&&", "CharOperation", ".", "equals", "(", "this", ".", "constantPoolName", ",", "marker", ".", "constantPoolName", ")", ";", "}", "return", "false", ";", "}", "public", "int", "hashCode", "(", ")", "{", "return", "this", ".", "pc", "+", "this", ".", "constantPoolName", ".", "hashCode", "(", ")", ";", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", ")", ";", "buffer", ".", "append", "(", "'('", ")", ".", "append", "(", "this", ".", "pc", ")", ".", "append", "(", "','", ")", ".", "append", "(", "this", ".", "constantPoolName", ")", ".", "append", "(", "')'", ")", ";", "return", "String", ".", "valueOf", "(", "buffer", ")", ";", "}", "}", "public", "static", "class", "StackDepthMarker", "{", "public", "int", "pc", ";", "public", "int", "delta", ";", "public", "TypeBinding", "typeBinding", ";", "public", "StackDepthMarker", "(", "int", "pc", ",", "int", "delta", ",", "TypeBinding", "typeBinding", ")", "{", "this", ".", "pc", "=", "pc", ";", "this", ".", "typeBinding", "=", "typeBinding", ";", "this", ".", "delta", "=", "delta", ";", "}", "public", "StackDepthMarker", "(", "int", "pc", ",", "int", "delta", ")", "{", "this", ".", "pc", "=", "pc", ";", "this", ".", "delta", "=", "delta", ";", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", ")", ";", "buffer", ".", "append", "(", "'('", ")", ".", "append", "(", "this", ".", "pc", ")", ".", "append", "(", "','", ")", ".", "append", "(", "this", ".", "delta", ")", ";", "if", "(", "this", ".", "typeBinding", "!=", "null", ")", "{", "buffer", ".", "append", "(", "','", ")", ".", "append", "(", "this", ".", "typeBinding", ".", "qualifiedPackageName", "(", ")", ")", ".", "append", "(", "this", ".", "typeBinding", ".", "qualifiedSourceName", "(", ")", ")", ";", "}", "buffer", ".", "append", "(", "')'", ")", ";", "return", "String", ".", "valueOf", "(", "buffer", ")", ";", "}", "}", "public", "static", "class", "StackMarker", "{", "public", "int", "pc", ";", "public", "int", "destinationPC", ";", "public", "VerificationTypeInfo", "[", "]", "infos", ";", "public", "StackMarker", "(", "int", "pc", ",", "int", "destinationPC", ")", "{", "this", ".", "pc", "=", "pc", ";", "this", ".", "destinationPC", "=", "destinationPC", ";", "}", "public", "void", "setInfos", "(", "VerificationTypeInfo", "[", "]", "infos", ")", "{", "this", ".", "infos", "=", "infos", ";", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", ")", ";", "buffer", ".", "append", "(", "\"\"", ")", ".", "append", "(", "this", ".", "pc", ")", ".", "append", "(", "\"", "to", "\"", ")", ".", "append", "(", "this", ".", "destinationPC", ")", ";", "if", "(", "this", ".", "infos", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "infos", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "i", ">", "0", ")", "buffer", ".", "append", "(", "','", ")", ";", "buffer", ".", "append", "(", "this", ".", "infos", "[", "i", "]", ")", ";", "}", "}", "buffer", ".", "append", "(", "']'", ")", ";", "return", "String", ".", "valueOf", "(", "buffer", ")", ";", "}", "}", "static", "class", "FramePosition", "{", "int", "counter", ";", "}", "public", "int", "[", "]", "stateIndexes", ";", "public", "int", "stateIndexesCounter", ";", "private", "HashMap", "framePositions", ";", "public", "Set", "exceptionMarkers", ";", "public", "ArrayList", "stackDepthMarkers", ";", "public", "ArrayList", "stackMarkers", ";", "public", "StackMapFrameCodeStream", "(", "ClassFile", "givenClassFile", ")", "{", "super", "(", "givenClassFile", ")", ";", "this", ".", "generateAttributes", "|=", "ClassFileConstants", ".", "ATTR_STACK_MAP", ";", "}", "public", "void", "addDefinitelyAssignedVariables", "(", "Scope", "scope", ",", "int", "initStateIndex", ")", "{", "loop", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "visibleLocalsCount", ";", "i", "++", ")", "{", "LocalVariableBinding", "localBinding", "=", "this", ".", "visibleLocals", "[", "i", "]", ";", "if", "(", "localBinding", "!=", "null", ")", "{", "boolean", "isDefinitelyAssigned", "=", "isDefinitelyAssigned", "(", "scope", ",", "initStateIndex", ",", "localBinding", ")", ";", "if", "(", "!", "isDefinitelyAssigned", ")", "{", "if", "(", "this", ".", "stateIndexes", "!=", "null", ")", "{", "for", "(", "int", "j", "=", "0", ",", "max", "=", "this", ".", "stateIndexesCounter", ";", "j", "<", "max", ";", "j", "++", ")", "{", "if", "(", "isDefinitelyAssigned", "(", "scope", ",", "this", ".", "stateIndexes", "[", "j", "]", ",", "localBinding", ")", ")", "{", "if", "(", "(", "localBinding", ".", "initializationCount", "==", "0", ")", "||", "(", "localBinding", ".", "initializationPCs", "[", "(", "(", "localBinding", ".", "initializationCount", "-", "1", ")", "<<", "1", ")", "+", "1", "]", "!=", "-", "1", ")", ")", "{", "localBinding", ".", "recordInitializationStartPC", "(", "this", ".", "position", ")", ";", "}", "continue", "loop", ";", "}", "}", "}", "}", "else", "{", "if", "(", "(", "localBinding", ".", "initializationCount", "==", "0", ")", "||", "(", "localBinding", ".", "initializationPCs", "[", "(", "(", "localBinding", ".", "initializationCount", "-", "1", ")", "<<", "1", ")", "+", "1", "]", "!=", "-", "1", ")", ")", "{", "localBinding", ".", "recordInitializationStartPC", "(", "this", ".", "position", ")", ";", "}", "}", "}", "}", "}", "public", "void", "addExceptionMarker", "(", "int", "pc", ",", "TypeBinding", "typeBinding", ")", "{", "if", "(", "this", ".", "exceptionMarkers", "==", "null", ")", "{", "this", ".", "exceptionMarkers", "=", "new", "HashSet", "(", ")", ";", "}", "if", "(", "typeBinding", "==", "null", ")", "{", "this", ".", "exceptionMarkers", ".", "add", "(", "new", "ExceptionMarker", "(", "pc", ",", "ConstantPool", ".", "JavaLangThrowableConstantPoolName", ")", ")", ";", "}", "else", "{", "switch", "(", "typeBinding", ".", "id", ")", "{", "case", "TypeIds", ".", "T_null", ":", "this", ".", "exceptionMarkers", ".", "add", "(", "new", "ExceptionMarker", "(", "pc", ",", "ConstantPool", ".", "JavaLangClassNotFoundExceptionConstantPoolName", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "this", ".", "exceptionMarkers", ".", "add", "(", "new", "ExceptionMarker", "(", "pc", ",", "ConstantPool", ".", "JavaLangNoSuchFieldErrorConstantPoolName", ")", ")", ";", "break", ";", "default", ":", "this", ".", "exceptionMarkers", ".", "add", "(", "new", "ExceptionMarker", "(", "pc", ",", "typeBinding", ".", "constantPoolName", "(", ")", ")", ")", ";", "}", "}", "}", "public", "void", "addFramePosition", "(", "int", "pc", ")", "{", "Integer", "newEntry", "=", "new", "Integer", "(", "pc", ")", ";", "FramePosition", "value", ";", "if", "(", "(", "value", "=", "(", "FramePosition", ")", "this", ".", "framePositions", ".", "get", "(", "newEntry", ")", ")", "!=", "null", ")", "{", "value", ".", "counter", "++", ";", "}", "else", "{", "this", ".", "framePositions", ".", "put", "(", "newEntry", ",", "new", "FramePosition", "(", ")", ")", ";", "}", "}", "public", "void", "optimizeBranch", "(", "int", "oldPosition", ",", "BranchLabel", "lbl", ")", "{", "super", ".", "optimizeBranch", "(", "oldPosition", ",", "lbl", ")", ";", "removeFramePosition", "(", "oldPosition", ")", ";", "}", "public", "void", "removeFramePosition", "(", "int", "pc", ")", "{", "Integer", "entry", "=", "new", "Integer", "(", "pc", ")", ";", "FramePosition", "value", ";", "if", "(", "(", "value", "=", "(", "FramePosition", ")", "this", ".", "framePositions", ".", "get", "(", "entry", ")", ")", "!=", "null", ")", "{", "value", ".", "counter", "--", ";", "if", "(", "value", ".", "counter", "<=", "0", ")", "{", "this", ".", "framePositions", ".", "remove", "(", "entry", ")", ";", "}", "}", "}", "public", "void", "addVariable", "(", "LocalVariableBinding", "localBinding", ")", "{", "if", "(", "localBinding", ".", "initializationPCs", "==", "null", ")", "{", "record", "(", "localBinding", ")", ";", "}", "localBinding", ".", "recordInitializationStartPC", "(", "this", ".", "position", ")", ";", "}", "private", "void", "addStackMarker", "(", "int", "pc", ",", "int", "destinationPC", ")", "{", "if", "(", "this", ".", "stackMarkers", "==", "null", ")", "{", "this", ".", "stackMarkers", "=", "new", "ArrayList", "(", ")", ";", "this", ".", "stackMarkers", ".", "add", "(", "new", "StackMarker", "(", "pc", ",", "destinationPC", ")", ")", ";", "}", "else", "{", "int", "size", "=", "this", ".", "stackMarkers", ".", "size", "(", ")", ";", "if", "(", "size", "==", "0", "||", "(", "(", "StackMarker", ")", "this", ".", "stackMarkers", ".", "get", "(", "size", "-", "1", ")", ")", ".", "pc", "!=", "this", ".", "position", ")", "{", "this", ".", "stackMarkers", ".", "add", "(", "new", "StackMarker", "(", "pc", ",", "destinationPC", ")", ")", ";", "}", "}", "}", "private", "void", "addStackDepthMarker", "(", "int", "pc", ",", "int", "delta", ",", "TypeBinding", "typeBinding", ")", "{", "if", "(", "this", ".", "stackDepthMarkers", "==", "null", ")", "{", "this", ".", "stackDepthMarkers", "=", "new", "ArrayList", "(", ")", ";", "this", ".", "stackDepthMarkers", ".", "add", "(", "new", "StackDepthMarker", "(", "pc", ",", "delta", ",", "typeBinding", ")", ")", ";", "}", "else", "{", "int", "size", "=", "this", ".", "stackDepthMarkers", ".", "size", "(", ")", ";", "if", "(", "size", "==", "0", "||", "(", "(", "StackDepthMarker", ")", "this", ".", "stackDepthMarkers", ".", "get", "(", "size", "-", "1", ")", ")", ".", "pc", "!=", "this", ".", "position", ")", "{", "this", ".", "stackDepthMarkers", ".", "add", "(", "new", "StackDepthMarker", "(", "pc", ",", "delta", ",", "typeBinding", ")", ")", ";", "}", "}", "}", "public", "void", "decrStackSize", "(", "int", "offset", ")", "{", "super", ".", "decrStackSize", "(", "offset", ")", ";", "addStackDepthMarker", "(", "this", ".", "position", ",", "-", "1", ",", "null", ")", ";", "}", "public", "void", "recordExpressionType", "(", "TypeBinding", "typeBinding", ")", "{", "addStackDepthMarker", "(", "this", ".", "position", ",", "0", ",", "typeBinding", ")", ";", "}", "public", "void", "generateClassLiteralAccessForType", "(", "TypeBinding", "accessedType", ",", "FieldBinding", "syntheticFieldBinding", ")", "{", "if", "(", "accessedType", ".", "isBaseType", "(", ")", "&&", "accessedType", "!=", "TypeBinding", ".", "NULL", ")", "{", "getTYPE", "(", "accessedType", ".", "id", ")", ";", "return", ";", "}", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "this", ".", "ldc", "(", "accessedType", ")", ";", "}", "else", "{", "BranchLabel", "endLabel", "=", "new", "BranchLabel", "(", "this", ")", ";", "if", "(", "syntheticFieldBinding", "!=", "null", ")", "{", "fieldAccess", "(", "Opcodes", ".", "OPC_getstatic", ",", "syntheticFieldBinding", ",", "null", ")", ";", "dup", "(", ")", ";", "ifnonnull", "(", "endLabel", ")", ";", "pop", "(", ")", ";", "}", "ExceptionLabel", "classNotFoundExceptionHandler", "=", "new", "ExceptionLabel", "(", "this", ",", "TypeBinding", ".", "NULL", ")", ";", "classNotFoundExceptionHandler", ".", "placeStart", "(", ")", ";", "this", ".", "ldc", "(", "accessedType", "==", "TypeBinding", ".", "NULL", "?", "\"\"", ":", "String", ".", "valueOf", "(", "accessedType", ".", "constantPoolName", "(", ")", ")", ".", "replace", "(", "'/'", ",", "'.'", ")", ")", ";", "invokeClassForName", "(", ")", ";", "classNotFoundExceptionHandler", ".", "placeEnd", "(", ")", ";", "if", "(", "syntheticFieldBinding", "!=", "null", ")", "{", "dup", "(", ")", ";", "fieldAccess", "(", "Opcodes", ".", "OPC_putstatic", ",", "syntheticFieldBinding", ",", "null", ")", ";", "}", "int", "fromPC", "=", "this", ".", "position", ";", "goto_", "(", "endLabel", ")", ";", "int", "savedStackDepth", "=", "this", ".", "stackDepth", ";", "pushExceptionOnStack", "(", "TypeBinding", ".", "NULL", ")", ";", "classNotFoundExceptionHandler", ".", "place", "(", ")", ";", "newNoClassDefFoundError", "(", ")", ";", "dup_x1", "(", ")", ";", "swap", "(", ")", ";", "invokeThrowableGetMessage", "(", ")", ";", "invokeNoClassDefFoundErrorStringConstructor", "(", ")", ";", "athrow", "(", ")", ";", "endLabel", ".", "place", "(", ")", ";", "addStackMarker", "(", "fromPC", ",", "this", ".", "position", ")", ";", "this", ".", "stackDepth", "=", "savedStackDepth", ";", "}", "}", "public", "ExceptionMarker", "[", "]", "getExceptionMarkers", "(", ")", "{", "Set", "exceptionMarkerSet", "=", "this", ".", "exceptionMarkers", ";", "if", "(", "this", ".", "exceptionMarkers", "==", "null", ")", "return", "null", ";", "int", "size", "=", "exceptionMarkerSet", ".", "size", "(", ")", ";", "ExceptionMarker", "[", "]", "markers", "=", "new", "ExceptionMarker", "[", "size", "]", ";", "int", "n", "=", "0", ";", "for", "(", "Iterator", "iterator", "=", "exceptionMarkerSet", ".", "iterator", "(", ")", ";", "iterator", ".", "hasNext", "(", ")", ";", ")", "{", "markers", "[", "n", "++", "]", "=", "(", "ExceptionMarker", ")", "iterator", ".", "next", "(", ")", ";", "}", "Arrays", ".", "sort", "(", "markers", ")", ";", "return", "markers", ";", "}", "public", "int", "[", "]", "getFramePositions", "(", ")", "{", "Set", "set", "=", "this", ".", "framePositions", ".", "keySet", "(", ")", ";", "int", "size", "=", "set", ".", "size", "(", ")", ";", "int", "[", "]", "positions", "=", "new", "int", "[", "size", "]", ";", "int", "n", "=", "0", ";", "for", "(", "Iterator", "iterator", "=", "set", ".", "iterator", "(", ")", ";", "iterator", ".", "hasNext", "(", ")", ";", ")", "{", "positions", "[", "n", "++", "]", "=", "(", "(", "Integer", ")", "iterator", ".", "next", "(", ")", ")", ".", "intValue", "(", ")", ";", "}", "Arrays", ".", "sort", "(", "positions", ")", ";", "return", "positions", ";", "}", "public", "StackDepthMarker", "[", "]", "getStackDepthMarkers", "(", ")", "{", "if", "(", "this", ".", "stackDepthMarkers", "==", "null", ")", "return", "null", ";", "int", "length", "=", "this", ".", "stackDepthMarkers", ".", "size", "(", ")", ";", "if", "(", "length", "==", "0", ")", "return", "null", ";", "StackDepthMarker", "[", "]", "result", "=", "new", "StackDepthMarker", "[", "length", "]", ";", "this", ".", "stackDepthMarkers", ".", "toArray", "(", "result", ")", ";", "return", "result", ";", "}", "public", "StackMarker", "[", "]", "getStackMarkers", "(", ")", "{", "if", "(", "this", ".", "stackMarkers", "==", "null", ")", "return", "null", ";", "int", "length", "=", "this", ".", "stackMarkers", ".", "size", "(", ")", ";", "if", "(", "length", "==", "0", ")", "return", "null", ";", "StackMarker", "[", "]", "result", "=", "new", "StackMarker", "[", "length", "]", ";", "this", ".", "stackMarkers", ".", "toArray", "(", "result", ")", ";", "return", "result", ";", "}", "public", "boolean", "hasFramePositions", "(", ")", "{", "return", "this", ".", "framePositions", ".", "size", "(", ")", "!=", "0", ";", "}", "public", "void", "init", "(", "ClassFile", "targetClassFile", ")", "{", "super", ".", "init", "(", "targetClassFile", ")", ";", "this", ".", "stateIndexesCounter", "=", "0", ";", "if", "(", "this", ".", "framePositions", "!=", "null", ")", "{", "this", ".", "framePositions", ".", "clear", "(", ")", ";", "}", "if", "(", "this", ".", "exceptionMarkers", "!=", "null", ")", "{", "this", ".", "exceptionMarkers", ".", "clear", "(", ")", ";", "}", "if", "(", "this", ".", "stackDepthMarkers", "!=", "null", ")", "{", "this", ".", "stackDepthMarkers", ".", "clear", "(", ")", ";", "}", "if", "(", "this", ".", "stackMarkers", "!=", "null", ")", "{", "this", ".", "stackMarkers", ".", "clear", "(", ")", ";", "}", "}", "public", "void", "initializeMaxLocals", "(", "MethodBinding", "methodBinding", ")", "{", "super", ".", "initializeMaxLocals", "(", "methodBinding", ")", ";", "if", "(", "this", ".", "framePositions", "==", "null", ")", "{", "this", ".", "framePositions", "=", "new", "HashMap", "(", ")", ";", "}", "else", "{", "this", ".", "framePositions", ".", "clear", "(", ")", ";", "}", "}", "public", "void", "popStateIndex", "(", ")", "{", "this", ".", "stateIndexesCounter", "--", ";", "}", "public", "void", "pushStateIndex", "(", "int", "naturalExitMergeInitStateIndex", ")", "{", "if", "(", "this", ".", "stateIndexes", "==", "null", ")", "{", "this", ".", "stateIndexes", "=", "new", "int", "[", "3", "]", ";", "}", "int", "length", "=", "this", ".", "stateIndexes", ".", "length", ";", "if", "(", "length", "==", "this", ".", "stateIndexesCounter", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "stateIndexes", ",", "0", ",", "(", "this", ".", "stateIndexes", "=", "new", "int", "[", "length", "*", "2", "]", ")", ",", "0", ",", "length", ")", ";", "}", "this", ".", "stateIndexes", "[", "this", ".", "stateIndexesCounter", "++", "]", "=", "naturalExitMergeInitStateIndex", ";", "}", "public", "void", "removeNotDefinitelyAssignedVariables", "(", "Scope", "scope", ",", "int", "initStateIndex", ")", "{", "int", "index", "=", "this", ".", "visibleLocalsCount", ";", "loop", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "index", ";", "i", "++", ")", "{", "LocalVariableBinding", "localBinding", "=", "this", ".", "visibleLocals", "[", "i", "]", ";", "if", "(", "localBinding", "!=", "null", "&&", "localBinding", ".", "initializationCount", ">", "0", ")", "{", "boolean", "isDefinitelyAssigned", "=", "isDefinitelyAssigned", "(", "scope", ",", "initStateIndex", ",", "localBinding", ")", ";", "if", "(", "!", "isDefinitelyAssigned", ")", "{", "if", "(", "this", ".", "stateIndexes", "!=", "null", ")", "{", "for", "(", "int", "j", "=", "0", ",", "max", "=", "this", ".", "stateIndexesCounter", ";", "j", "<", "max", ";", "j", "++", ")", "{", "if", "(", "isDefinitelyAssigned", "(", "scope", ",", "this", ".", "stateIndexes", "[", "j", "]", ",", "localBinding", ")", ")", "{", "continue", "loop", ";", "}", "}", "}", "localBinding", ".", "recordInitializationEndPC", "(", "this", ".", "position", ")", ";", "}", "}", "}", "}", "public", "void", "reset", "(", "ClassFile", "givenClassFile", ")", "{", "super", ".", "reset", "(", "givenClassFile", ")", ";", "this", ".", "stateIndexesCounter", "=", "0", ";", "if", "(", "this", ".", "framePositions", "!=", "null", ")", "{", "this", ".", "framePositions", ".", "clear", "(", ")", ";", "}", "if", "(", "this", ".", "exceptionMarkers", "!=", "null", ")", "{", "this", ".", "exceptionMarkers", ".", "clear", "(", ")", ";", "}", "if", "(", "this", ".", "stackDepthMarkers", "!=", "null", ")", "{", "this", ".", "stackDepthMarkers", ".", "clear", "(", ")", ";", "}", "if", "(", "this", ".", "stackMarkers", "!=", "null", ")", "{", "this", ".", "stackMarkers", ".", "clear", "(", ")", ";", "}", "}", "protected", "void", "writePosition", "(", "BranchLabel", "label", ")", "{", "super", ".", "writePosition", "(", "label", ")", ";", "addFramePosition", "(", "label", ".", "position", ")", ";", "}", "protected", "void", "writePosition", "(", "BranchLabel", "label", ",", "int", "forwardReference", ")", "{", "super", ".", "writePosition", "(", "label", ",", "forwardReference", ")", ";", "addFramePosition", "(", "label", ".", "position", ")", ";", "}", "protected", "void", "writeSignedWord", "(", "int", "pos", ",", "int", "value", ")", "{", "super", ".", "writeSignedWord", "(", "pos", ",", "value", ")", ";", "addFramePosition", "(", "this", ".", "position", ")", ";", "}", "protected", "void", "writeWidePosition", "(", "BranchLabel", "label", ")", "{", "super", ".", "writeWidePosition", "(", "label", ")", ";", "addFramePosition", "(", "label", ".", "position", ")", ";", "}", "public", "void", "areturn", "(", ")", "{", "super", ".", "areturn", "(", ")", ";", "addFramePosition", "(", "this", ".", "position", ")", ";", "}", "public", "void", "ireturn", "(", ")", "{", "super", ".", "ireturn", "(", ")", ";", "addFramePosition", "(", "this", ".", "position", ")", ";", "}", "public", "void", "lreturn", "(", ")", "{", "super", ".", "lreturn", "(", ")", ";", "addFramePosition", "(", "this", ".", "position", ")", ";", "}", "public", "void", "freturn", "(", ")", "{", "super", ".", "freturn", "(", ")", ";", "addFramePosition", "(", "this", ".", "position", ")", ";", "}", "public", "void", "dreturn", "(", ")", "{", "super", ".", "dreturn", "(", ")", ";", "addFramePosition", "(", "this", ".", "position", ")", ";", "}", "public", "void", "return_", "(", ")", "{", "super", ".", "return_", "(", ")", ";", "addFramePosition", "(", "this", ".", "position", ")", ";", "}", "public", "void", "athrow", "(", ")", "{", "super", ".", "athrow", "(", ")", ";", "addFramePosition", "(", "this", ".", "position", ")", ";", "}", "public", "void", "pushOnStack", "(", "TypeBinding", "binding", ")", "{", "super", ".", "pushOnStack", "(", "binding", ")", ";", "addStackDepthMarker", "(", "this", ".", "position", ",", "1", ",", "binding", ")", ";", "}", "public", "void", "pushExceptionOnStack", "(", "TypeBinding", "binding", ")", "{", "super", ".", "pushExceptionOnStack", "(", "binding", ")", ";", "addExceptionMarker", "(", "this", ".", "position", ",", "binding", ")", ";", "}", "public", "void", "goto_", "(", "BranchLabel", "label", ")", "{", "super", ".", "goto_", "(", "label", ")", ";", "addFramePosition", "(", "this", ".", "position", ")", ";", "}", "public", "void", "goto_w", "(", "BranchLabel", "label", ")", "{", "super", ".", "goto_w", "(", "label", ")", ";", "addFramePosition", "(", "this", ".", "position", ")", ";", "}", "public", "void", "resetInWideMode", "(", ")", "{", "this", ".", "resetSecretLocals", "(", ")", ";", "super", ".", "resetInWideMode", "(", ")", ";", "}", "public", "void", "resetSecretLocals", "(", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "locals", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "LocalVariableBinding", "localVariableBinding", "=", "this", ".", "locals", "[", "i", "]", ";", "if", "(", "localVariableBinding", "!=", "null", "&&", "localVariableBinding", ".", "isSecret", "(", ")", ")", "{", "localVariableBinding", ".", "resetInitializations", "(", ")", ";", "}", "}", "}", "}", "</s>" ]
5,559
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "public", "class", "LongCache", "{", "public", "long", "keyTable", "[", "]", ";", "public", "int", "valueTable", "[", "]", ";", "int", "elementSize", ";", "int", "threshold", ";", "public", "LongCache", "(", ")", "{", "this", "(", "13", ")", ";", "}", "public", "LongCache", "(", "int", "initialCapacity", ")", "{", "this", ".", "elementSize", "=", "0", ";", "this", ".", "threshold", "=", "(", "int", ")", "(", "initialCapacity", "*", "0.66", ")", ";", "this", ".", "keyTable", "=", "new", "long", "[", "initialCapacity", "]", ";", "this", ".", "valueTable", "=", "new", "int", "[", "initialCapacity", "]", ";", "}", "public", "void", "clear", "(", ")", "{", "for", "(", "int", "i", "=", "this", ".", "keyTable", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "{", "this", ".", "keyTable", "[", "i", "]", "=", "0", ";", "this", ".", "valueTable", "[", "i", "]", "=", "0", ";", "}", "this", ".", "elementSize", "=", "0", ";", "}", "public", "boolean", "containsKey", "(", "long", "key", ")", "{", "int", "index", "=", "hash", "(", "key", ")", ",", "length", "=", "this", ".", "keyTable", ".", "length", ";", "while", "(", "(", "this", ".", "keyTable", "[", "index", "]", "!=", "0", ")", "||", "(", "(", "this", ".", "keyTable", "[", "index", "]", "==", "0", ")", "&&", "(", "this", ".", "valueTable", "[", "index", "]", "!=", "0", ")", ")", ")", "{", "if", "(", "this", ".", "keyTable", "[", "index", "]", "==", "key", ")", "return", "true", ";", "if", "(", "++", "index", "==", "length", ")", "{", "index", "=", "0", ";", "}", "}", "return", "false", ";", "}", "public", "int", "hash", "(", "long", "key", ")", "{", "return", "(", "(", "int", ")", "key", "&", "0x7FFFFFFF", ")", "%", "this", ".", "keyTable", ".", "length", ";", "}", "public", "int", "put", "(", "long", "key", ",", "int", "value", ")", "{", "int", "index", "=", "hash", "(", "key", ")", ",", "length", "=", "this", ".", "keyTable", ".", "length", ";", "while", "(", "(", "this", ".", "keyTable", "[", "index", "]", "!=", "0", ")", "||", "(", "(", "this", ".", "keyTable", "[", "index", "]", "==", "0", ")", "&&", "(", "this", ".", "valueTable", "[", "index", "]", "!=", "0", ")", ")", ")", "{", "if", "(", "this", ".", "keyTable", "[", "index", "]", "==", "key", ")", "return", "this", ".", "valueTable", "[", "index", "]", "=", "value", ";", "if", "(", "++", "index", "==", "length", ")", "{", "index", "=", "0", ";", "}", "}", "this", ".", "keyTable", "[", "index", "]", "=", "key", ";", "this", ".", "valueTable", "[", "index", "]", "=", "value", ";", "if", "(", "++", "this", ".", "elementSize", ">", "this", ".", "threshold", ")", "{", "rehash", "(", ")", ";", "}", "return", "value", ";", "}", "public", "int", "putIfAbsent", "(", "long", "key", ",", "int", "value", ")", "{", "int", "index", "=", "hash", "(", "key", ")", ",", "length", "=", "this", ".", "keyTable", ".", "length", ";", "while", "(", "(", "this", ".", "keyTable", "[", "index", "]", "!=", "0", ")", "||", "(", "(", "this", ".", "keyTable", "[", "index", "]", "==", "0", ")", "&&", "(", "this", ".", "valueTable", "[", "index", "]", "!=", "0", ")", ")", ")", "{", "if", "(", "this", ".", "keyTable", "[", "index", "]", "==", "key", ")", "return", "this", ".", "valueTable", "[", "index", "]", ";", "if", "(", "++", "index", "==", "length", ")", "{", "index", "=", "0", ";", "}", "}", "this", ".", "keyTable", "[", "index", "]", "=", "key", ";", "this", ".", "valueTable", "[", "index", "]", "=", "value", ";", "if", "(", "++", "this", ".", "elementSize", ">", "this", ".", "threshold", ")", "{", "rehash", "(", ")", ";", "}", "return", "-", "value", ";", "}", "private", "void", "rehash", "(", ")", "{", "LongCache", "newHashtable", "=", "new", "LongCache", "(", "this", ".", "keyTable", ".", "length", "*", "2", ")", ";", "for", "(", "int", "i", "=", "this", ".", "keyTable", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "{", "long", "key", "=", "this", ".", "keyTable", "[", "i", "]", ";", "int", "value", "=", "this", ".", "valueTable", "[", "i", "]", ";", "if", "(", "(", "key", "!=", "0", ")", "||", "(", "(", "key", "==", "0", ")", "&&", "(", "value", "!=", "0", ")", ")", ")", "{", "newHashtable", ".", "put", "(", "key", ",", "value", ")", ";", "}", "}", "this", ".", "keyTable", "=", "newHashtable", ".", "keyTable", ";", "this", ".", "valueTable", "=", "newHashtable", ".", "valueTable", ";", "this", ".", "threshold", "=", "newHashtable", ".", "threshold", ";", "}", "public", "int", "size", "(", ")", "{", "return", "this", ".", "elementSize", ";", "}", "public", "String", "toString", "(", ")", "{", "int", "max", "=", "size", "(", ")", ";", "StringBuffer", "buf", "=", "new", "StringBuffer", "(", ")", ";", "buf", ".", "append", "(", "\"{\"", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "max", ";", "++", "i", ")", "{", "if", "(", "(", "this", ".", "keyTable", "[", "i", "]", "!=", "0", ")", "||", "(", "(", "this", ".", "keyTable", "[", "i", "]", "==", "0", ")", "&&", "(", "this", ".", "valueTable", "[", "i", "]", "!=", "0", ")", ")", ")", "{", "buf", ".", "append", "(", "this", ".", "keyTable", "[", "i", "]", ")", ".", "append", "(", "\"->\"", ")", ".", "append", "(", "this", ".", "valueTable", "[", "i", "]", ")", ";", "}", "if", "(", "i", "<", "max", ")", "{", "buf", ".", "append", "(", "\",", "\"", ")", ";", "}", "}", "buf", ".", "append", "(", "\"}\"", ")", ";", "return", "buf", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
5,560
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ClassFile", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "CompilationResult", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ASTNode", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AbstractMethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AllocationExpression", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ExplicitConstructorCall", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Expression", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "OperatorIds", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "flow", ".", "UnconditionalFlowInfo", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CompilerOptions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "Constant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "AbortMethod", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "Util", ";", "public", "class", "CodeStream", "{", "public", "static", "FieldBinding", "[", "]", "ImplicitThis", "=", "new", "FieldBinding", "[", "]", "{", "}", ";", "public", "static", "final", "int", "LABELS_INCREMENT", "=", "5", ";", "public", "static", "final", "int", "LOCALS_INCREMENT", "=", "10", ";", "static", "ExceptionLabel", "[", "]", "noExceptionHandlers", "=", "new", "ExceptionLabel", "[", "LABELS_INCREMENT", "]", ";", "static", "BranchLabel", "[", "]", "noLabels", "=", "new", "BranchLabel", "[", "LABELS_INCREMENT", "]", ";", "static", "LocalVariableBinding", "[", "]", "noLocals", "=", "new", "LocalVariableBinding", "[", "LOCALS_INCREMENT", "]", ";", "static", "LocalVariableBinding", "[", "]", "noVisibleLocals", "=", "new", "LocalVariableBinding", "[", "LOCALS_INCREMENT", "]", ";", "public", "static", "final", "CompilationResult", "RESTART_IN_WIDE_MODE", "=", "new", "CompilationResult", "(", "(", "char", "[", "]", ")", "null", ",", "0", ",", "0", ",", "0", ")", ";", "public", "int", "allLocalsCounter", ";", "public", "byte", "[", "]", "bCodeStream", ";", "public", "ClassFile", "classFile", ";", "public", "int", "classFileOffset", ";", "public", "ConstantPool", "constantPool", ";", "public", "int", "countLabels", ";", "public", "ExceptionLabel", "[", "]", "exceptionLabels", "=", "new", "ExceptionLabel", "[", "LABELS_INCREMENT", "]", ";", "public", "int", "exceptionLabelsCounter", ";", "public", "int", "generateAttributes", ";", "static", "final", "int", "L_UNKNOWN", "=", "0", ",", "L_OPTIMIZABLE", "=", "2", ",", "L_CANNOT_OPTIMIZE", "=", "4", ";", "public", "BranchLabel", "[", "]", "labels", "=", "new", "BranchLabel", "[", "LABELS_INCREMENT", "]", ";", "public", "int", "lastEntryPC", ";", "public", "int", "lastAbruptCompletion", ";", "public", "int", "[", "]", "lineSeparatorPositions", ";", "public", "int", "lineNumberStart", ";", "public", "int", "lineNumberEnd", ";", "public", "LocalVariableBinding", "[", "]", "locals", "=", "new", "LocalVariableBinding", "[", "LOCALS_INCREMENT", "]", ";", "public", "int", "maxFieldCount", ";", "public", "int", "maxLocals", ";", "public", "AbstractMethodDeclaration", "methodDeclaration", ";", "public", "int", "[", "]", "pcToSourceMap", "=", "new", "int", "[", "24", "]", ";", "public", "int", "pcToSourceMapSize", ";", "public", "int", "position", ";", "public", "boolean", "preserveUnusedLocals", ";", "public", "int", "stackDepth", ";", "public", "int", "stackMax", ";", "public", "int", "startingClassFileOffset", ";", "protected", "long", "targetLevel", ";", "public", "LocalVariableBinding", "[", "]", "visibleLocals", "=", "new", "LocalVariableBinding", "[", "LOCALS_INCREMENT", "]", ";", "int", "visibleLocalsCount", ";", "public", "boolean", "wideMode", "=", "false", ";", "public", "CodeStream", "(", "ClassFile", "givenClassFile", ")", "{", "this", ".", "targetLevel", "=", "givenClassFile", ".", "targetJDK", ";", "this", ".", "generateAttributes", "=", "givenClassFile", ".", "produceAttributes", ";", "if", "(", "(", "givenClassFile", ".", "produceAttributes", "&", "ClassFileConstants", ".", "ATTR_LINES", ")", "!=", "0", ")", "{", "this", ".", "lineSeparatorPositions", "=", "givenClassFile", ".", "referenceBinding", ".", "scope", ".", "referenceCompilationUnit", "(", ")", ".", "compilationResult", ".", "getLineSeparatorPositions", "(", ")", ";", "}", "}", "public", "static", "int", "insertionIndex", "(", "int", "[", "]", "pcToSourceMap", ",", "int", "length", ",", "int", "pc", ")", "{", "int", "g", "=", "0", ";", "int", "d", "=", "length", "-", "2", ";", "int", "m", "=", "0", ";", "while", "(", "g", "<=", "d", ")", "{", "m", "=", "(", "g", "+", "d", ")", "/", "2", ";", "if", "(", "(", "m", "&", "1", ")", "!=", "0", ")", "m", "--", ";", "int", "currentPC", "=", "pcToSourceMap", "[", "m", "]", ";", "if", "(", "pc", "<", "currentPC", ")", "{", "d", "=", "m", "-", "2", ";", "}", "else", "if", "(", "pc", ">", "currentPC", ")", "{", "g", "=", "m", "+", "2", ";", "}", "else", "{", "return", "-", "1", ";", "}", "}", "if", "(", "pc", "<", "pcToSourceMap", "[", "m", "]", ")", "return", "m", ";", "return", "m", "+", "2", ";", "}", "public", "static", "final", "void", "sort", "(", "int", "[", "]", "tab", ",", "int", "lo0", ",", "int", "hi0", ",", "int", "[", "]", "result", ")", "{", "int", "lo", "=", "lo0", ";", "int", "hi", "=", "hi0", ";", "int", "mid", ";", "if", "(", "hi0", ">", "lo0", ")", "{", "mid", "=", "tab", "[", "lo0", "+", "(", "hi0", "-", "lo0", ")", "/", "2", "]", ";", "while", "(", "lo", "<=", "hi", ")", "{", "while", "(", "(", "lo", "<", "hi0", ")", "&&", "(", "tab", "[", "lo", "]", "<", "mid", ")", ")", "++", "lo", ";", "while", "(", "(", "hi", ">", "lo0", ")", "&&", "(", "tab", "[", "hi", "]", ">", "mid", ")", ")", "--", "hi", ";", "if", "(", "lo", "<=", "hi", ")", "{", "swap", "(", "tab", ",", "lo", ",", "hi", ",", "result", ")", ";", "++", "lo", ";", "--", "hi", ";", "}", "}", "if", "(", "lo0", "<", "hi", ")", "sort", "(", "tab", ",", "lo0", ",", "hi", ",", "result", ")", ";", "if", "(", "lo", "<", "hi0", ")", "sort", "(", "tab", ",", "lo", ",", "hi0", ",", "result", ")", ";", "}", "}", "private", "static", "final", "void", "swap", "(", "int", "a", "[", "]", ",", "int", "i", ",", "int", "j", ",", "int", "result", "[", "]", ")", "{", "int", "T", ";", "T", "=", "a", "[", "i", "]", ";", "a", "[", "i", "]", "=", "a", "[", "j", "]", ";", "a", "[", "j", "]", "=", "T", ";", "T", "=", "result", "[", "j", "]", ";", "result", "[", "j", "]", "=", "result", "[", "i", "]", ";", "result", "[", "i", "]", "=", "T", ";", "}", "public", "void", "aaload", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_aaload", ";", "}", "public", "void", "aastore", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "3", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_aastore", ";", "}", "public", "void", "aconst_null", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "{", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_aconst_null", ";", "}", "public", "void", "addDefinitelyAssignedVariables", "(", "Scope", "scope", ",", "int", "initStateIndex", ")", "{", "if", "(", "(", "this", ".", "generateAttributes", "&", "(", "ClassFileConstants", ".", "ATTR_VARS", "|", "ClassFileConstants", ".", "ATTR_STACK_MAP_TABLE", "|", "ClassFileConstants", ".", "ATTR_STACK_MAP", ")", ")", "==", "0", ")", "return", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "visibleLocalsCount", ";", "i", "++", ")", "{", "LocalVariableBinding", "localBinding", "=", "this", ".", "visibleLocals", "[", "i", "]", ";", "if", "(", "localBinding", "!=", "null", ")", "{", "if", "(", "isDefinitelyAssigned", "(", "scope", ",", "initStateIndex", ",", "localBinding", ")", ")", "{", "if", "(", "(", "localBinding", ".", "initializationCount", "==", "0", ")", "||", "(", "localBinding", ".", "initializationPCs", "[", "(", "(", "localBinding", ".", "initializationCount", "-", "1", ")", "<<", "1", ")", "+", "1", "]", "!=", "-", "1", ")", ")", "{", "localBinding", ".", "recordInitializationStartPC", "(", "this", ".", "position", ")", ";", "}", "}", "}", "}", "}", "public", "void", "addLabel", "(", "BranchLabel", "aLabel", ")", "{", "if", "(", "this", ".", "countLabels", "==", "this", ".", "labels", ".", "length", ")", "System", ".", "arraycopy", "(", "this", ".", "labels", ",", "0", ",", "this", ".", "labels", "=", "new", "BranchLabel", "[", "this", ".", "countLabels", "+", "LABELS_INCREMENT", "]", ",", "0", ",", "this", ".", "countLabels", ")", ";", "this", ".", "labels", "[", "this", ".", "countLabels", "++", "]", "=", "aLabel", ";", "}", "public", "void", "addVariable", "(", "LocalVariableBinding", "localBinding", ")", "{", "}", "public", "void", "addVisibleLocalVariable", "(", "LocalVariableBinding", "localBinding", ")", "{", "if", "(", "(", "this", ".", "generateAttributes", "&", "(", "ClassFileConstants", ".", "ATTR_VARS", "|", "ClassFileConstants", ".", "ATTR_STACK_MAP_TABLE", "|", "ClassFileConstants", ".", "ATTR_STACK_MAP", ")", ")", "==", "0", ")", "return", ";", "if", "(", "this", ".", "visibleLocalsCount", ">=", "this", ".", "visibleLocals", ".", "length", ")", "System", ".", "arraycopy", "(", "this", ".", "visibleLocals", ",", "0", ",", "this", ".", "visibleLocals", "=", "new", "LocalVariableBinding", "[", "this", ".", "visibleLocalsCount", "*", "2", "]", ",", "0", ",", "this", ".", "visibleLocalsCount", ")", ";", "this", ".", "visibleLocals", "[", "this", ".", "visibleLocalsCount", "++", "]", "=", "localBinding", ";", "}", "public", "void", "aload", "(", "int", "iArg", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "maxLocals", "<=", "iArg", ")", "{", "this", ".", "maxLocals", "=", "iArg", "+", "1", ";", "}", "if", "(", "iArg", ">", "255", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "3", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_wide", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_aload", ";", "writeUnsignedShort", "(", "iArg", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_aload", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "iArg", ";", "}", "}", "public", "void", "aload_0", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "{", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "}", "if", "(", "this", ".", "maxLocals", "==", "0", ")", "{", "this", ".", "maxLocals", "=", "1", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_aload_0", ";", "}", "public", "void", "aload_1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "maxLocals", "<=", "1", ")", "{", "this", ".", "maxLocals", "=", "2", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_aload_1", ";", "}", "public", "void", "aload_2", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "maxLocals", "<=", "2", ")", "{", "this", ".", "maxLocals", "=", "3", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_aload_2", ";", "}", "public", "void", "aload_3", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "maxLocals", "<=", "3", ")", "{", "this", ".", "maxLocals", "=", "4", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_aload_3", ";", "}", "public", "void", "anewarray", "(", "TypeBinding", "typeBinding", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_anewarray", ";", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "typeBinding", ")", ")", ";", "}", "public", "void", "areturn", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_areturn", ";", "this", ".", "lastAbruptCompletion", "=", "this", ".", "position", ";", "}", "public", "void", "arrayAt", "(", "int", "typeBindingID", ")", "{", "switch", "(", "typeBindingID", ")", "{", "case", "TypeIds", ".", "T_int", ":", "iaload", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_byte", ":", "case", "TypeIds", ".", "T_boolean", ":", "baload", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_short", ":", "saload", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_char", ":", "caload", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "laload", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "faload", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "daload", "(", ")", ";", "break", ";", "default", ":", "aaload", "(", ")", ";", "}", "}", "public", "void", "arrayAtPut", "(", "int", "elementTypeID", ",", "boolean", "valueRequired", ")", "{", "switch", "(", "elementTypeID", ")", "{", "case", "TypeIds", ".", "T_int", ":", "if", "(", "valueRequired", ")", "dup_x2", "(", ")", ";", "iastore", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_byte", ":", "case", "TypeIds", ".", "T_boolean", ":", "if", "(", "valueRequired", ")", "dup_x2", "(", ")", ";", "bastore", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_short", ":", "if", "(", "valueRequired", ")", "dup_x2", "(", ")", ";", "sastore", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_char", ":", "if", "(", "valueRequired", ")", "dup_x2", "(", ")", ";", "castore", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "if", "(", "valueRequired", ")", "dup2_x2", "(", ")", ";", "lastore", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "if", "(", "valueRequired", ")", "dup_x2", "(", ")", ";", "fastore", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "if", "(", "valueRequired", ")", "dup2_x2", "(", ")", ";", "dastore", "(", ")", ";", "break", ";", "default", ":", "if", "(", "valueRequired", ")", "dup_x2", "(", ")", ";", "aastore", "(", ")", ";", "}", "}", "public", "void", "arraylength", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_arraylength", ";", "}", "public", "void", "astore", "(", "int", "iArg", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "maxLocals", "<=", "iArg", ")", "{", "this", ".", "maxLocals", "=", "iArg", "+", "1", ";", "}", "if", "(", "iArg", ">", "255", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "3", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_wide", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_astore", ";", "writeUnsignedShort", "(", "iArg", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_astore", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "iArg", ";", "}", "}", "public", "void", "astore_0", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "maxLocals", "==", "0", ")", "{", "this", ".", "maxLocals", "=", "1", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_astore_0", ";", "}", "public", "void", "astore_1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "maxLocals", "<=", "1", ")", "{", "this", ".", "maxLocals", "=", "2", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_astore_1", ";", "}", "public", "void", "astore_2", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "maxLocals", "<=", "2", ")", "{", "this", ".", "maxLocals", "=", "3", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_astore_2", ";", "}", "public", "void", "astore_3", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "maxLocals", "<=", "3", ")", "{", "this", ".", "maxLocals", "=", "4", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_astore_3", ";", "}", "public", "void", "athrow", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_athrow", ";", "this", ".", "lastAbruptCompletion", "=", "this", ".", "position", ";", "}", "public", "void", "baload", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_baload", ";", "}", "public", "void", "bastore", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "3", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_bastore", ";", "}", "public", "void", "bipush", "(", "byte", "b", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_bipush", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "b", ";", "}", "public", "void", "caload", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_caload", ";", "}", "public", "void", "castore", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "3", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_castore", ";", "}", "public", "void", "checkcast", "(", "int", "baseId", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_checkcast", ";", "switch", "(", "baseId", ")", "{", "case", "TypeIds", ".", "T_byte", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangByteConstantPoolName", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_short", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangShortConstantPoolName", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_char", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangCharacterConstantPoolName", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_int", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangIntegerConstantPoolName", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangLongConstantPoolName", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangFloatConstantPoolName", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangDoubleConstantPoolName", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_boolean", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangBooleanConstantPoolName", ")", ")", ";", "}", "}", "public", "void", "checkcast", "(", "TypeBinding", "typeBinding", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_checkcast", ";", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "typeBinding", ")", ")", ";", "}", "public", "void", "d2f", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_d2f", ";", "}", "public", "void", "d2i", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_d2i", ";", "}", "public", "void", "d2l", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_d2l", ";", "}", "public", "void", "dadd", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dadd", ";", "}", "public", "void", "daload", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_daload", ";", "}", "public", "void", "dastore", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "4", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dastore", ";", "}", "public", "void", "dcmpg", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "3", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dcmpg", ";", "}", "public", "void", "dcmpl", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "3", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dcmpl", ";", "}", "public", "void", "dconst_0", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dconst_0", ";", "}", "public", "void", "dconst_1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dconst_1", ";", "}", "public", "void", "ddiv", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ddiv", ";", "}", "public", "void", "decrStackSize", "(", "int", "offset", ")", "{", "this", ".", "stackDepth", "-=", "offset", ";", "}", "public", "void", "dload", "(", "int", "iArg", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "maxLocals", "<", "iArg", "+", "2", ")", "{", "this", ".", "maxLocals", "=", "iArg", "+", "2", ";", "}", "if", "(", "iArg", ">", "255", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "3", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_wide", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dload", ";", "writeUnsignedShort", "(", "iArg", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dload", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "iArg", ";", "}", "}", "public", "void", "dload_0", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "maxLocals", "<", "2", ")", "{", "this", ".", "maxLocals", "=", "2", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dload_0", ";", "}", "public", "void", "dload_1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "maxLocals", "<", "3", ")", "{", "this", ".", "maxLocals", "=", "3", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dload_1", ";", "}", "public", "void", "dload_2", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "maxLocals", "<", "4", ")", "{", "this", ".", "maxLocals", "=", "4", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dload_2", ";", "}", "public", "void", "dload_3", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "maxLocals", "<", "5", ")", "{", "this", ".", "maxLocals", "=", "5", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dload_3", ";", "}", "public", "void", "dmul", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dmul", ";", "}", "public", "void", "dneg", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dneg", ";", "}", "public", "void", "drem", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_drem", ";", "}", "public", "void", "dreturn", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dreturn", ";", "this", ".", "lastAbruptCompletion", "=", "this", ".", "position", ";", "}", "public", "void", "dstore", "(", "int", "iArg", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "maxLocals", "<=", "iArg", "+", "1", ")", "{", "this", ".", "maxLocals", "=", "iArg", "+", "2", ";", "}", "if", "(", "iArg", ">", "255", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "3", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_wide", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dstore", ";", "writeUnsignedShort", "(", "iArg", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dstore", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "iArg", ";", "}", "}", "public", "void", "dstore_0", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "maxLocals", "<", "2", ")", "{", "this", ".", "maxLocals", "=", "2", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dstore_0", ";", "}", "public", "void", "dstore_1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "maxLocals", "<", "3", ")", "{", "this", ".", "maxLocals", "=", "3", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dstore_1", ";", "}", "public", "void", "dstore_2", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "maxLocals", "<", "4", ")", "{", "this", ".", "maxLocals", "=", "4", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dstore_2", ";", "}", "public", "void", "dstore_3", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "maxLocals", "<", "5", ")", "{", "this", ".", "maxLocals", "=", "5", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dstore_3", ";", "}", "public", "void", "dsub", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dsub", ";", "}", "public", "void", "dup", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "{", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dup", ";", "}", "public", "void", "dup_x1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dup_x1", ";", "}", "public", "void", "dup_x2", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dup_x2", ";", "}", "public", "void", "dup2", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dup2", ";", "}", "public", "void", "dup2_x1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dup2_x1", ";", "}", "public", "void", "dup2_x2", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_dup2_x2", ";", "}", "public", "void", "exitUserScope", "(", "BlockScope", "currentScope", ")", "{", "if", "(", "(", "this", ".", "generateAttributes", "&", "(", "ClassFileConstants", ".", "ATTR_VARS", "|", "ClassFileConstants", ".", "ATTR_STACK_MAP_TABLE", "|", "ClassFileConstants", ".", "ATTR_STACK_MAP", ")", ")", "==", "0", ")", "return", ";", "int", "index", "=", "this", ".", "visibleLocalsCount", "-", "1", ";", "while", "(", "index", ">=", "0", ")", "{", "LocalVariableBinding", "visibleLocal", "=", "this", ".", "visibleLocals", "[", "index", "]", ";", "if", "(", "visibleLocal", "==", "null", "||", "visibleLocal", ".", "declaringScope", "!=", "currentScope", ")", "{", "index", "--", ";", "continue", ";", "}", "if", "(", "visibleLocal", ".", "initializationCount", ">", "0", ")", "{", "visibleLocal", ".", "recordInitializationEndPC", "(", "this", ".", "position", ")", ";", "}", "this", ".", "visibleLocals", "[", "index", "--", "]", "=", "null", ";", "}", "}", "public", "void", "exitUserScope", "(", "BlockScope", "currentScope", ",", "LocalVariableBinding", "binding", ")", "{", "if", "(", "(", "this", ".", "generateAttributes", "&", "(", "ClassFileConstants", ".", "ATTR_VARS", "|", "ClassFileConstants", ".", "ATTR_STACK_MAP_TABLE", "|", "ClassFileConstants", ".", "ATTR_STACK_MAP", ")", ")", "==", "0", ")", "return", ";", "int", "index", "=", "this", ".", "visibleLocalsCount", "-", "1", ";", "while", "(", "index", ">=", "0", ")", "{", "LocalVariableBinding", "visibleLocal", "=", "this", ".", "visibleLocals", "[", "index", "]", ";", "if", "(", "visibleLocal", "==", "null", "||", "visibleLocal", ".", "declaringScope", "!=", "currentScope", "||", "visibleLocal", "==", "binding", ")", "{", "index", "--", ";", "continue", ";", "}", "if", "(", "visibleLocal", ".", "initializationCount", ">", "0", ")", "{", "visibleLocal", ".", "recordInitializationEndPC", "(", "this", ".", "position", ")", ";", "}", "this", ".", "visibleLocals", "[", "index", "--", "]", "=", "null", ";", "}", "}", "public", "void", "f2d", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_f2d", ";", "}", "public", "void", "f2i", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_f2i", ";", "}", "public", "void", "f2l", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_f2l", ";", "}", "public", "void", "fadd", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fadd", ";", "}", "public", "void", "faload", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_faload", ";", "}", "public", "void", "fastore", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "3", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fastore", ";", "}", "public", "void", "fcmpg", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fcmpg", ";", "}", "public", "void", "fcmpl", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fcmpl", ";", "}", "public", "void", "fconst_0", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fconst_0", ";", "}", "public", "void", "fconst_1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fconst_1", ";", "}", "public", "void", "fconst_2", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fconst_2", ";", "}", "public", "void", "fdiv", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fdiv", ";", "}", "public", "void", "fieldAccess", "(", "byte", "opcode", ",", "FieldBinding", "fieldBinding", ",", "TypeBinding", "declaringClass", ")", "{", "if", "(", "declaringClass", "==", "null", ")", "declaringClass", "=", "fieldBinding", ".", "declaringClass", ";", "if", "(", "(", "declaringClass", ".", "tagBits", "&", "TagBits", ".", "ContainsNestedTypeReferences", ")", "!=", "0", ")", "{", "Util", ".", "recordNestedType", "(", "this", ".", "classFile", ",", "declaringClass", ")", ";", "}", "TypeBinding", "returnType", "=", "fieldBinding", ".", "type", ";", "int", "returnTypeSize", ";", "switch", "(", "returnType", ".", "id", ")", "{", "case", "TypeIds", ".", "T_long", ":", "case", "TypeIds", ".", "T_double", ":", "returnTypeSize", "=", "2", ";", "break", ";", "default", ":", "returnTypeSize", "=", "1", ";", "break", ";", "}", "this", ".", "fieldAccess", "(", "opcode", ",", "returnTypeSize", ",", "declaringClass", ".", "constantPoolName", "(", ")", ",", "fieldBinding", ".", "name", ",", "returnType", ".", "signature", "(", ")", ")", ";", "}", "private", "void", "fieldAccess", "(", "byte", "opcode", ",", "int", "returnTypeSize", ",", "char", "[", "]", "declaringClass", ",", "char", "[", "]", "fieldName", ",", "char", "[", "]", "signature", ")", "{", "this", ".", "countLabels", "=", "0", ";", "switch", "(", "opcode", ")", "{", "case", "Opcodes", ".", "OPC_getfield", ":", "if", "(", "returnTypeSize", "==", "2", ")", "{", "this", ".", "stackDepth", "++", ";", "}", "break", ";", "case", "Opcodes", ".", "OPC_getstatic", ":", "if", "(", "returnTypeSize", "==", "2", ")", "{", "this", ".", "stackDepth", "+=", "2", ";", "}", "else", "{", "this", ".", "stackDepth", "++", ";", "}", "break", ";", "case", "Opcodes", ".", "OPC_putfield", ":", "if", "(", "returnTypeSize", "==", "2", ")", "{", "this", ".", "stackDepth", "-=", "3", ";", "}", "else", "{", "this", ".", "stackDepth", "-=", "2", ";", "}", "break", ";", "case", "Opcodes", ".", "OPC_putstatic", ":", "if", "(", "returnTypeSize", "==", "2", ")", "{", "this", ".", "stackDepth", "-=", "2", ";", "}", "else", "{", "this", ".", "stackDepth", "--", ";", "}", "}", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "{", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "}", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "opcode", ";", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForField", "(", "declaringClass", ",", "fieldName", ",", "signature", ")", ")", ";", "}", "public", "void", "fload", "(", "int", "iArg", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "maxLocals", "<=", "iArg", ")", "{", "this", ".", "maxLocals", "=", "iArg", "+", "1", ";", "}", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "iArg", ">", "255", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "3", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_wide", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fload", ";", "writeUnsignedShort", "(", "iArg", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fload", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "iArg", ";", "}", "}", "public", "void", "fload_0", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "maxLocals", "==", "0", ")", "{", "this", ".", "maxLocals", "=", "1", ";", "}", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fload_0", ";", "}", "public", "void", "fload_1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "maxLocals", "<=", "1", ")", "{", "this", ".", "maxLocals", "=", "2", ";", "}", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fload_1", ";", "}", "public", "void", "fload_2", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "maxLocals", "<=", "2", ")", "{", "this", ".", "maxLocals", "=", "3", ";", "}", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fload_2", ";", "}", "public", "void", "fload_3", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "maxLocals", "<=", "3", ")", "{", "this", ".", "maxLocals", "=", "4", ";", "}", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fload_3", ";", "}", "public", "void", "fmul", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fmul", ";", "}", "public", "void", "fneg", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fneg", ";", "}", "public", "void", "frem", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_frem", ";", "}", "public", "void", "freturn", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_freturn", ";", "this", ".", "lastAbruptCompletion", "=", "this", ".", "position", ";", "}", "public", "void", "fstore", "(", "int", "iArg", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "maxLocals", "<=", "iArg", ")", "{", "this", ".", "maxLocals", "=", "iArg", "+", "1", ";", "}", "if", "(", "iArg", ">", "255", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "3", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_wide", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fstore", ";", "writeUnsignedShort", "(", "iArg", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fstore", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "iArg", ";", "}", "}", "public", "void", "fstore_0", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "maxLocals", "==", "0", ")", "{", "this", ".", "maxLocals", "=", "1", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fstore_0", ";", "}", "public", "void", "fstore_1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "maxLocals", "<=", "1", ")", "{", "this", ".", "maxLocals", "=", "2", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fstore_1", ";", "}", "public", "void", "fstore_2", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "maxLocals", "<=", "2", ")", "{", "this", ".", "maxLocals", "=", "3", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fstore_2", ";", "}", "public", "void", "fstore_3", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "maxLocals", "<=", "3", ")", "{", "this", ".", "maxLocals", "=", "4", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fstore_3", ";", "}", "public", "void", "fsub", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_fsub", ";", "}", "public", "void", "generateBoxingConversion", "(", "int", "unboxedTypeID", ")", "{", "switch", "(", "unboxedTypeID", ")", "{", "case", "TypeIds", ".", "T_byte", ":", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokestatic", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangByteConstantPoolName", ",", "ConstantPool", ".", "ValueOf", ",", "ConstantPool", ".", "byteByteSignature", ")", ";", "}", "else", "{", "newWrapperFor", "(", "unboxedTypeID", ")", ";", "dup_x1", "(", ")", ";", "swap", "(", ")", ";", "invoke", "(", "Opcodes", ".", "OPC_invokespecial", ",", "2", ",", "0", ",", "ConstantPool", ".", "JavaLangByteConstantPoolName", ",", "ConstantPool", ".", "Init", ",", "ConstantPool", ".", "ByteConstrSignature", ")", ";", "}", "break", ";", "case", "TypeIds", ".", "T_short", ":", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokestatic", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangShortConstantPoolName", ",", "ConstantPool", ".", "ValueOf", ",", "ConstantPool", ".", "shortShortSignature", ")", ";", "}", "else", "{", "newWrapperFor", "(", "unboxedTypeID", ")", ";", "dup_x1", "(", ")", ";", "swap", "(", ")", ";", "invoke", "(", "Opcodes", ".", "OPC_invokespecial", ",", "2", ",", "0", ",", "ConstantPool", ".", "JavaLangShortConstantPoolName", ",", "ConstantPool", ".", "Init", ",", "ConstantPool", ".", "ShortConstrSignature", ")", ";", "}", "break", ";", "case", "TypeIds", ".", "T_char", ":", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokestatic", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangCharacterConstantPoolName", ",", "ConstantPool", ".", "ValueOf", ",", "ConstantPool", ".", "charCharacterSignature", ")", ";", "}", "else", "{", "newWrapperFor", "(", "unboxedTypeID", ")", ";", "dup_x1", "(", ")", ";", "swap", "(", ")", ";", "invoke", "(", "Opcodes", ".", "OPC_invokespecial", ",", "2", ",", "0", ",", "ConstantPool", ".", "JavaLangCharacterConstantPoolName", ",", "ConstantPool", ".", "Init", ",", "ConstantPool", ".", "CharConstrSignature", ")", ";", "}", "break", ";", "case", "TypeIds", ".", "T_int", ":", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokestatic", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangIntegerConstantPoolName", ",", "ConstantPool", ".", "ValueOf", ",", "ConstantPool", ".", "IntIntegerSignature", ")", ";", "}", "else", "{", "newWrapperFor", "(", "unboxedTypeID", ")", ";", "dup_x1", "(", ")", ";", "swap", "(", ")", ";", "invoke", "(", "Opcodes", ".", "OPC_invokespecial", ",", "2", ",", "0", ",", "ConstantPool", ".", "JavaLangIntegerConstantPoolName", ",", "ConstantPool", ".", "Init", ",", "ConstantPool", ".", "IntConstrSignature", ")", ";", "}", "break", ";", "case", "TypeIds", ".", "T_long", ":", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokestatic", ",", "2", ",", "1", ",", "ConstantPool", ".", "JavaLangLongConstantPoolName", ",", "ConstantPool", ".", "ValueOf", ",", "ConstantPool", ".", "longLongSignature", ")", ";", "}", "else", "{", "newWrapperFor", "(", "unboxedTypeID", ")", ";", "dup_x2", "(", ")", ";", "dup_x2", "(", ")", ";", "pop", "(", ")", ";", "invoke", "(", "Opcodes", ".", "OPC_invokespecial", ",", "3", ",", "0", ",", "ConstantPool", ".", "JavaLangLongConstantPoolName", ",", "ConstantPool", ".", "Init", ",", "ConstantPool", ".", "LongConstrSignature", ")", ";", "}", "break", ";", "case", "TypeIds", ".", "T_float", ":", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokestatic", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangFloatConstantPoolName", ",", "ConstantPool", ".", "ValueOf", ",", "ConstantPool", ".", "floatFloatSignature", ")", ";", "}", "else", "{", "newWrapperFor", "(", "unboxedTypeID", ")", ";", "dup_x1", "(", ")", ";", "swap", "(", ")", ";", "invoke", "(", "Opcodes", ".", "OPC_invokespecial", ",", "2", ",", "0", ",", "ConstantPool", ".", "JavaLangFloatConstantPoolName", ",", "ConstantPool", ".", "Init", ",", "ConstantPool", ".", "FloatConstrSignature", ")", ";", "}", "break", ";", "case", "TypeIds", ".", "T_double", ":", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokestatic", ",", "2", ",", "1", ",", "ConstantPool", ".", "JavaLangDoubleConstantPoolName", ",", "ConstantPool", ".", "ValueOf", ",", "ConstantPool", ".", "doubleDoubleSignature", ")", ";", "}", "else", "{", "newWrapperFor", "(", "unboxedTypeID", ")", ";", "dup_x2", "(", ")", ";", "dup_x2", "(", ")", ";", "pop", "(", ")", ";", "invoke", "(", "Opcodes", ".", "OPC_invokespecial", ",", "3", ",", "0", ",", "ConstantPool", ".", "JavaLangDoubleConstantPoolName", ",", "ConstantPool", ".", "Init", ",", "ConstantPool", ".", "DoubleConstrSignature", ")", ";", "}", "break", ";", "case", "TypeIds", ".", "T_boolean", ":", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokestatic", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangBooleanConstantPoolName", ",", "ConstantPool", ".", "ValueOf", ",", "ConstantPool", ".", "booleanBooleanSignature", ")", ";", "}", "else", "{", "newWrapperFor", "(", "unboxedTypeID", ")", ";", "dup_x1", "(", ")", ";", "swap", "(", ")", ";", "invoke", "(", "Opcodes", ".", "OPC_invokespecial", ",", "2", ",", "0", ",", "ConstantPool", ".", "JavaLangBooleanConstantPoolName", ",", "ConstantPool", ".", "Init", ",", "ConstantPool", ".", "BooleanConstrSignature", ")", ";", "}", "}", "}", "public", "void", "generateClassLiteralAccessForType", "(", "TypeBinding", "accessedType", ",", "FieldBinding", "syntheticFieldBinding", ")", "{", "if", "(", "accessedType", ".", "isBaseType", "(", ")", "&&", "accessedType", "!=", "TypeBinding", ".", "NULL", ")", "{", "getTYPE", "(", "accessedType", ".", "id", ")", ";", "return", ";", "}", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "this", ".", "ldc", "(", "accessedType", ")", ";", "}", "else", "{", "BranchLabel", "endLabel", "=", "new", "BranchLabel", "(", "this", ")", ";", "if", "(", "syntheticFieldBinding", "!=", "null", ")", "{", "fieldAccess", "(", "Opcodes", ".", "OPC_getstatic", ",", "syntheticFieldBinding", ",", "null", ")", ";", "dup", "(", ")", ";", "ifnonnull", "(", "endLabel", ")", ";", "pop", "(", ")", ";", "}", "ExceptionLabel", "classNotFoundExceptionHandler", "=", "new", "ExceptionLabel", "(", "this", ",", "TypeBinding", ".", "NULL", ")", ";", "classNotFoundExceptionHandler", ".", "placeStart", "(", ")", ";", "this", ".", "ldc", "(", "accessedType", "==", "TypeBinding", ".", "NULL", "?", "\"\"", ":", "String", ".", "valueOf", "(", "accessedType", ".", "constantPoolName", "(", ")", ")", ".", "replace", "(", "'/'", ",", "'.'", ")", ")", ";", "invokeClassForName", "(", ")", ";", "classNotFoundExceptionHandler", ".", "placeEnd", "(", ")", ";", "if", "(", "syntheticFieldBinding", "!=", "null", ")", "{", "dup", "(", ")", ";", "fieldAccess", "(", "Opcodes", ".", "OPC_putstatic", ",", "syntheticFieldBinding", ",", "null", ")", ";", "}", "goto_", "(", "endLabel", ")", ";", "int", "savedStackDepth", "=", "this", ".", "stackDepth", ";", "pushExceptionOnStack", "(", "TypeBinding", ".", "NULL", ")", ";", "classNotFoundExceptionHandler", ".", "place", "(", ")", ";", "newNoClassDefFoundError", "(", ")", ";", "dup_x1", "(", ")", ";", "this", ".", "swap", "(", ")", ";", "invokeThrowableGetMessage", "(", ")", ";", "invokeNoClassDefFoundErrorStringConstructor", "(", ")", ";", "athrow", "(", ")", ";", "endLabel", ".", "place", "(", ")", ";", "this", ".", "stackDepth", "=", "savedStackDepth", ";", "}", "}", "final", "public", "void", "generateCodeAttributeForProblemMethod", "(", "String", "problemMessage", ")", "{", "newJavaLangError", "(", ")", ";", "dup", "(", ")", ";", "ldc", "(", "problemMessage", ")", ";", "invokeJavaLangErrorConstructor", "(", ")", ";", "athrow", "(", ")", ";", "}", "public", "void", "generateConstant", "(", "Constant", "constant", ",", "int", "implicitConversionCode", ")", "{", "int", "targetTypeID", "=", "(", "implicitConversionCode", "&", "TypeIds", ".", "IMPLICIT_CONVERSION_MASK", ")", ">>", "4", ";", "if", "(", "targetTypeID", "==", "0", ")", "targetTypeID", "=", "constant", ".", "typeID", "(", ")", ";", "switch", "(", "targetTypeID", ")", "{", "case", "TypeIds", ".", "T_boolean", ":", "generateInlinedValue", "(", "constant", ".", "booleanValue", "(", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_char", ":", "generateInlinedValue", "(", "constant", ".", "charValue", "(", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_byte", ":", "generateInlinedValue", "(", "constant", ".", "byteValue", "(", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_short", ":", "generateInlinedValue", "(", "constant", ".", "shortValue", "(", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_int", ":", "generateInlinedValue", "(", "constant", ".", "intValue", "(", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "generateInlinedValue", "(", "constant", ".", "longValue", "(", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "generateInlinedValue", "(", "constant", ".", "floatValue", "(", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "generateInlinedValue", "(", "constant", ".", "doubleValue", "(", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_JavaLangString", ":", "ldc", "(", "constant", ".", "stringValue", "(", ")", ")", ";", "}", "if", "(", "(", "implicitConversionCode", "&", "TypeIds", ".", "BOXING", ")", "!=", "0", ")", "{", "generateBoxingConversion", "(", "targetTypeID", ")", ";", "}", "}", "public", "void", "generateEmulatedReadAccessForField", "(", "FieldBinding", "fieldBinding", ")", "{", "generateEmulationForField", "(", "fieldBinding", ")", ";", "this", ".", "swap", "(", ")", ";", "invokeJavaLangReflectFieldGetter", "(", "fieldBinding", ".", "type", ".", "id", ")", ";", "if", "(", "!", "fieldBinding", ".", "type", ".", "isBaseType", "(", ")", ")", "{", "this", ".", "checkcast", "(", "fieldBinding", ".", "type", ")", ";", "}", "}", "public", "void", "generateEmulatedWriteAccessForField", "(", "FieldBinding", "fieldBinding", ")", "{", "invokeJavaLangReflectFieldSetter", "(", "fieldBinding", ".", "type", ".", "id", ")", ";", "}", "public", "void", "generateEmulationForConstructor", "(", "Scope", "scope", ",", "MethodBinding", "methodBinding", ")", "{", "this", ".", "ldc", "(", "String", ".", "valueOf", "(", "methodBinding", ".", "declaringClass", ".", "constantPoolName", "(", ")", ")", ".", "replace", "(", "'/'", ",", "'.'", ")", ")", ";", "invokeClassForName", "(", ")", ";", "int", "paramLength", "=", "methodBinding", ".", "parameters", ".", "length", ";", "this", ".", "generateInlinedValue", "(", "paramLength", ")", ";", "newArray", "(", "scope", ".", "createArrayType", "(", "scope", ".", "getType", "(", "TypeConstants", ".", "JAVA_LANG_CLASS", ",", "3", ")", ",", "1", ")", ")", ";", "if", "(", "paramLength", ">", "0", ")", "{", "dup", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "paramLength", ";", "i", "++", ")", "{", "this", ".", "generateInlinedValue", "(", "i", ")", ";", "TypeBinding", "parameter", "=", "methodBinding", ".", "parameters", "[", "i", "]", ";", "if", "(", "parameter", ".", "isBaseType", "(", ")", ")", "{", "getTYPE", "(", "parameter", ".", "id", ")", ";", "}", "else", "if", "(", "parameter", ".", "isArrayType", "(", ")", ")", "{", "ArrayBinding", "array", "=", "(", "ArrayBinding", ")", "parameter", ";", "if", "(", "array", ".", "leafComponentType", ".", "isBaseType", "(", ")", ")", "{", "getTYPE", "(", "array", ".", "leafComponentType", ".", "id", ")", ";", "}", "else", "{", "this", ".", "ldc", "(", "String", ".", "valueOf", "(", "array", ".", "leafComponentType", ".", "constantPoolName", "(", ")", ")", ".", "replace", "(", "'/'", ",", "'.'", ")", ")", ";", "invokeClassForName", "(", ")", ";", "}", "int", "dimensions", "=", "array", ".", "dimensions", ";", "this", ".", "generateInlinedValue", "(", "dimensions", ")", ";", "newarray", "(", "TypeIds", ".", "T_int", ")", ";", "invokeArrayNewInstance", "(", ")", ";", "invokeObjectGetClass", "(", ")", ";", "}", "else", "{", "this", ".", "ldc", "(", "String", ".", "valueOf", "(", "methodBinding", ".", "declaringClass", ".", "constantPoolName", "(", ")", ")", ".", "replace", "(", "'/'", ",", "'.'", ")", ")", ";", "invokeClassForName", "(", ")", ";", "}", "aastore", "(", ")", ";", "if", "(", "i", "<", "paramLength", "-", "1", ")", "{", "dup", "(", ")", ";", "}", "}", "}", "invokeClassGetDeclaredConstructor", "(", ")", ";", "dup", "(", ")", ";", "iconst_1", "(", ")", ";", "invokeAccessibleObjectSetAccessible", "(", ")", ";", "}", "public", "void", "generateEmulationForField", "(", "FieldBinding", "fieldBinding", ")", "{", "this", ".", "ldc", "(", "String", ".", "valueOf", "(", "fieldBinding", ".", "declaringClass", ".", "constantPoolName", "(", ")", ")", ".", "replace", "(", "'/'", ",", "'.'", ")", ")", ";", "invokeClassForName", "(", ")", ";", "this", ".", "ldc", "(", "String", ".", "valueOf", "(", "fieldBinding", ".", "name", ")", ")", ";", "invokeClassGetDeclaredField", "(", ")", ";", "dup", "(", ")", ";", "iconst_1", "(", ")", ";", "invokeAccessibleObjectSetAccessible", "(", ")", ";", "}", "public", "void", "generateEmulationForMethod", "(", "Scope", "scope", ",", "MethodBinding", "methodBinding", ")", "{", "this", ".", "ldc", "(", "String", ".", "valueOf", "(", "methodBinding", ".", "declaringClass", ".", "constantPoolName", "(", ")", ")", ".", "replace", "(", "'/'", ",", "'.'", ")", ")", ";", "invokeClassForName", "(", ")", ";", "this", ".", "ldc", "(", "String", ".", "valueOf", "(", "methodBinding", ".", "selector", ")", ")", ";", "int", "paramLength", "=", "methodBinding", ".", "parameters", ".", "length", ";", "this", ".", "generateInlinedValue", "(", "paramLength", ")", ";", "newArray", "(", "scope", ".", "createArrayType", "(", "scope", ".", "getType", "(", "TypeConstants", ".", "JAVA_LANG_CLASS", ",", "3", ")", ",", "1", ")", ")", ";", "if", "(", "paramLength", ">", "0", ")", "{", "dup", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "paramLength", ";", "i", "++", ")", "{", "this", ".", "generateInlinedValue", "(", "i", ")", ";", "TypeBinding", "parameter", "=", "methodBinding", ".", "parameters", "[", "i", "]", ";", "if", "(", "parameter", ".", "isBaseType", "(", ")", ")", "{", "getTYPE", "(", "parameter", ".", "id", ")", ";", "}", "else", "if", "(", "parameter", ".", "isArrayType", "(", ")", ")", "{", "ArrayBinding", "array", "=", "(", "ArrayBinding", ")", "parameter", ";", "if", "(", "array", ".", "leafComponentType", ".", "isBaseType", "(", ")", ")", "{", "getTYPE", "(", "array", ".", "leafComponentType", ".", "id", ")", ";", "}", "else", "{", "this", ".", "ldc", "(", "String", ".", "valueOf", "(", "array", ".", "leafComponentType", ".", "constantPoolName", "(", ")", ")", ".", "replace", "(", "'/'", ",", "'.'", ")", ")", ";", "invokeClassForName", "(", ")", ";", "}", "int", "dimensions", "=", "array", ".", "dimensions", ";", "this", ".", "generateInlinedValue", "(", "dimensions", ")", ";", "newarray", "(", "TypeIds", ".", "T_int", ")", ";", "invokeArrayNewInstance", "(", ")", ";", "invokeObjectGetClass", "(", ")", ";", "}", "else", "{", "this", ".", "ldc", "(", "String", ".", "valueOf", "(", "methodBinding", ".", "declaringClass", ".", "constantPoolName", "(", ")", ")", ".", "replace", "(", "'/'", ",", "'.'", ")", ")", ";", "invokeClassForName", "(", ")", ";", "}", "aastore", "(", ")", ";", "if", "(", "i", "<", "paramLength", "-", "1", ")", "{", "dup", "(", ")", ";", "}", "}", "}", "invokeClassGetDeclaredMethod", "(", ")", ";", "dup", "(", ")", ";", "iconst_1", "(", ")", ";", "invokeAccessibleObjectSetAccessible", "(", ")", ";", "}", "public", "void", "generateImplicitConversion", "(", "int", "implicitConversionCode", ")", "{", "if", "(", "(", "implicitConversionCode", "&", "TypeIds", ".", "UNBOXING", ")", "!=", "0", ")", "{", "final", "int", "typeId", "=", "implicitConversionCode", "&", "TypeIds", ".", "COMPILE_TYPE_MASK", ";", "generateUnboxingConversion", "(", "typeId", ")", ";", "}", "switch", "(", "implicitConversionCode", "&", "TypeIds", ".", "IMPLICIT_CONVERSION_MASK", ")", "{", "case", "TypeIds", ".", "Float2Char", ":", "f2i", "(", ")", ";", "i2c", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Double2Char", ":", "d2i", "(", ")", ";", "i2c", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Int2Char", ":", "case", "TypeIds", ".", "Short2Char", ":", "case", "TypeIds", ".", "Byte2Char", ":", "i2c", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Long2Char", ":", "l2i", "(", ")", ";", "i2c", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Char2Float", ":", "case", "TypeIds", ".", "Short2Float", ":", "case", "TypeIds", ".", "Int2Float", ":", "case", "TypeIds", ".", "Byte2Float", ":", "i2f", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Double2Float", ":", "d2f", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Long2Float", ":", "l2f", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Float2Byte", ":", "f2i", "(", ")", ";", "i2b", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Double2Byte", ":", "d2i", "(", ")", ";", "i2b", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Int2Byte", ":", "case", "TypeIds", ".", "Short2Byte", ":", "case", "TypeIds", ".", "Char2Byte", ":", "i2b", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Long2Byte", ":", "l2i", "(", ")", ";", "i2b", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Byte2Double", ":", "case", "TypeIds", ".", "Char2Double", ":", "case", "TypeIds", ".", "Short2Double", ":", "case", "TypeIds", ".", "Int2Double", ":", "i2d", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Float2Double", ":", "f2d", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Long2Double", ":", "l2d", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Byte2Short", ":", "case", "TypeIds", ".", "Char2Short", ":", "case", "TypeIds", ".", "Int2Short", ":", "i2s", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Double2Short", ":", "d2i", "(", ")", ";", "i2s", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Long2Short", ":", "l2i", "(", ")", ";", "i2s", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Float2Short", ":", "f2i", "(", ")", ";", "i2s", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Double2Int", ":", "d2i", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Float2Int", ":", "f2i", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Long2Int", ":", "l2i", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Int2Long", ":", "case", "TypeIds", ".", "Char2Long", ":", "case", "TypeIds", ".", "Byte2Long", ":", "case", "TypeIds", ".", "Short2Long", ":", "i2l", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Double2Long", ":", "d2l", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "Float2Long", ":", "f2l", "(", ")", ";", "}", "if", "(", "(", "implicitConversionCode", "&", "TypeIds", ".", "BOXING", ")", "!=", "0", ")", "{", "final", "int", "typeId", "=", "(", "implicitConversionCode", "&", "TypeIds", ".", "IMPLICIT_CONVERSION_MASK", ")", ">>", "4", ";", "generateBoxingConversion", "(", "typeId", ")", ";", "}", "}", "public", "void", "generateInlinedValue", "(", "boolean", "inlinedValue", ")", "{", "if", "(", "inlinedValue", ")", "iconst_1", "(", ")", ";", "else", "iconst_0", "(", ")", ";", "}", "public", "void", "generateInlinedValue", "(", "byte", "inlinedValue", ")", "{", "switch", "(", "inlinedValue", ")", "{", "case", "-", "1", ":", "iconst_m1", "(", ")", ";", "break", ";", "case", "0", ":", "iconst_0", "(", ")", ";", "break", ";", "case", "1", ":", "iconst_1", "(", ")", ";", "break", ";", "case", "2", ":", "iconst_2", "(", ")", ";", "break", ";", "case", "3", ":", "iconst_3", "(", ")", ";", "break", ";", "case", "4", ":", "iconst_4", "(", ")", ";", "break", ";", "case", "5", ":", "iconst_5", "(", ")", ";", "break", ";", "default", ":", "if", "(", "(", "-", "128", "<=", "inlinedValue", ")", "&&", "(", "inlinedValue", "<=", "127", ")", ")", "{", "bipush", "(", "inlinedValue", ")", ";", "return", ";", "}", "}", "}", "public", "void", "generateInlinedValue", "(", "char", "inlinedValue", ")", "{", "switch", "(", "inlinedValue", ")", "{", "case", "0", ":", "iconst_0", "(", ")", ";", "break", ";", "case", "1", ":", "iconst_1", "(", ")", ";", "break", ";", "case", "2", ":", "iconst_2", "(", ")", ";", "break", ";", "case", "3", ":", "iconst_3", "(", ")", ";", "break", ";", "case", "4", ":", "iconst_4", "(", ")", ";", "break", ";", "case", "5", ":", "iconst_5", "(", ")", ";", "break", ";", "default", ":", "if", "(", "(", "6", "<=", "inlinedValue", ")", "&&", "(", "inlinedValue", "<=", "127", ")", ")", "{", "bipush", "(", "(", "byte", ")", "inlinedValue", ")", ";", "return", ";", "}", "if", "(", "(", "128", "<=", "inlinedValue", ")", "&&", "(", "inlinedValue", "<=", "32767", ")", ")", "{", "sipush", "(", "inlinedValue", ")", ";", "return", ";", "}", "this", ".", "ldc", "(", "inlinedValue", ")", ";", "}", "}", "public", "void", "generateInlinedValue", "(", "double", "inlinedValue", ")", "{", "if", "(", "inlinedValue", "==", "0.0", ")", "{", "if", "(", "Double", ".", "doubleToLongBits", "(", "inlinedValue", ")", "!=", "0L", ")", "this", ".", "ldc2_w", "(", "inlinedValue", ")", ";", "else", "dconst_0", "(", ")", ";", "return", ";", "}", "if", "(", "inlinedValue", "==", "1.0", ")", "{", "dconst_1", "(", ")", ";", "return", ";", "}", "this", ".", "ldc2_w", "(", "inlinedValue", ")", ";", "}", "public", "void", "generateInlinedValue", "(", "float", "inlinedValue", ")", "{", "if", "(", "inlinedValue", "==", "0.0f", ")", "{", "if", "(", "Float", ".", "floatToIntBits", "(", "inlinedValue", ")", "!=", "0", ")", "this", ".", "ldc", "(", "inlinedValue", ")", ";", "else", "fconst_0", "(", ")", ";", "return", ";", "}", "if", "(", "inlinedValue", "==", "1.0f", ")", "{", "fconst_1", "(", ")", ";", "return", ";", "}", "if", "(", "inlinedValue", "==", "2.0f", ")", "{", "fconst_2", "(", ")", ";", "return", ";", "}", "this", ".", "ldc", "(", "inlinedValue", ")", ";", "}", "public", "void", "generateInlinedValue", "(", "int", "inlinedValue", ")", "{", "switch", "(", "inlinedValue", ")", "{", "case", "-", "1", ":", "iconst_m1", "(", ")", ";", "break", ";", "case", "0", ":", "iconst_0", "(", ")", ";", "break", ";", "case", "1", ":", "iconst_1", "(", ")", ";", "break", ";", "case", "2", ":", "iconst_2", "(", ")", ";", "break", ";", "case", "3", ":", "iconst_3", "(", ")", ";", "break", ";", "case", "4", ":", "iconst_4", "(", ")", ";", "break", ";", "case", "5", ":", "iconst_5", "(", ")", ";", "break", ";", "default", ":", "if", "(", "(", "-", "128", "<=", "inlinedValue", ")", "&&", "(", "inlinedValue", "<=", "127", ")", ")", "{", "bipush", "(", "(", "byte", ")", "inlinedValue", ")", ";", "return", ";", "}", "if", "(", "(", "-", "32768", "<=", "inlinedValue", ")", "&&", "(", "inlinedValue", "<=", "32767", ")", ")", "{", "sipush", "(", "inlinedValue", ")", ";", "return", ";", "}", "this", ".", "ldc", "(", "inlinedValue", ")", ";", "}", "}", "public", "void", "generateInlinedValue", "(", "long", "inlinedValue", ")", "{", "if", "(", "inlinedValue", "==", "0", ")", "{", "lconst_0", "(", ")", ";", "return", ";", "}", "if", "(", "inlinedValue", "==", "1", ")", "{", "lconst_1", "(", ")", ";", "return", ";", "}", "this", ".", "ldc2_w", "(", "inlinedValue", ")", ";", "}", "public", "void", "generateInlinedValue", "(", "short", "inlinedValue", ")", "{", "switch", "(", "inlinedValue", ")", "{", "case", "-", "1", ":", "iconst_m1", "(", ")", ";", "break", ";", "case", "0", ":", "iconst_0", "(", ")", ";", "break", ";", "case", "1", ":", "iconst_1", "(", ")", ";", "break", ";", "case", "2", ":", "iconst_2", "(", ")", ";", "break", ";", "case", "3", ":", "iconst_3", "(", ")", ";", "break", ";", "case", "4", ":", "iconst_4", "(", ")", ";", "break", ";", "case", "5", ":", "iconst_5", "(", ")", ";", "break", ";", "default", ":", "if", "(", "(", "-", "128", "<=", "inlinedValue", ")", "&&", "(", "inlinedValue", "<=", "127", ")", ")", "{", "bipush", "(", "(", "byte", ")", "inlinedValue", ")", ";", "return", ";", "}", "sipush", "(", "inlinedValue", ")", ";", "}", "}", "public", "void", "generateOuterAccess", "(", "Object", "[", "]", "mappingSequence", ",", "ASTNode", "invocationSite", ",", "Binding", "target", ",", "Scope", "scope", ")", "{", "if", "(", "mappingSequence", "==", "null", ")", "{", "if", "(", "target", "instanceof", "LocalVariableBinding", ")", "{", "scope", ".", "problemReporter", "(", ")", ".", "needImplementation", "(", "invocationSite", ")", ";", "}", "else", "{", "scope", ".", "problemReporter", "(", ")", ".", "noSuchEnclosingInstance", "(", "(", "ReferenceBinding", ")", "target", ",", "invocationSite", ",", "false", ")", ";", "}", "return", ";", "}", "if", "(", "mappingSequence", "==", "BlockScope", ".", "NoEnclosingInstanceInConstructorCall", ")", "{", "scope", ".", "problemReporter", "(", ")", ".", "noSuchEnclosingInstance", "(", "(", "ReferenceBinding", ")", "target", ",", "invocationSite", ",", "true", ")", ";", "return", ";", "}", "else", "if", "(", "mappingSequence", "==", "BlockScope", ".", "NoEnclosingInstanceInStaticContext", ")", "{", "scope", ".", "problemReporter", "(", ")", ".", "noSuchEnclosingInstance", "(", "(", "ReferenceBinding", ")", "target", ",", "invocationSite", ",", "false", ")", ";", "return", ";", "}", "if", "(", "mappingSequence", "==", "BlockScope", ".", "EmulationPathToImplicitThis", ")", "{", "aload_0", "(", ")", ";", "return", ";", "}", "else", "if", "(", "mappingSequence", "[", "0", "]", "instanceof", "FieldBinding", ")", "{", "FieldBinding", "fieldBinding", "=", "(", "FieldBinding", ")", "mappingSequence", "[", "0", "]", ";", "aload_0", "(", ")", ";", "fieldAccess", "(", "Opcodes", ".", "OPC_getfield", ",", "fieldBinding", ",", "null", ")", ";", "}", "else", "{", "load", "(", "(", "LocalVariableBinding", ")", "mappingSequence", "[", "0", "]", ")", ";", "}", "for", "(", "int", "i", "=", "1", ",", "length", "=", "mappingSequence", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "mappingSequence", "[", "i", "]", "instanceof", "FieldBinding", ")", "{", "FieldBinding", "fieldBinding", "=", "(", "FieldBinding", ")", "mappingSequence", "[", "i", "]", ";", "fieldAccess", "(", "Opcodes", ".", "OPC_getfield", ",", "fieldBinding", ",", "null", ")", ";", "}", "else", "{", "invoke", "(", "Opcodes", ".", "OPC_invokestatic", ",", "(", "MethodBinding", ")", "mappingSequence", "[", "i", "]", ",", "null", ")", ";", "}", "}", "}", "public", "void", "generateReturnBytecode", "(", "Expression", "expression", ")", "{", "if", "(", "expression", "==", "null", ")", "{", "return_", "(", ")", ";", "}", "else", "{", "final", "int", "implicitConversion", "=", "expression", ".", "implicitConversion", ";", "if", "(", "(", "implicitConversion", "&", "TypeIds", ".", "BOXING", ")", "!=", "0", ")", "{", "areturn", "(", ")", ";", "return", ";", "}", "int", "runtimeType", "=", "(", "implicitConversion", "&", "TypeIds", ".", "IMPLICIT_CONVERSION_MASK", ")", ">>", "4", ";", "switch", "(", "runtimeType", ")", "{", "case", "TypeIds", ".", "T_boolean", ":", "case", "TypeIds", ".", "T_int", ":", "ireturn", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "freturn", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "lreturn", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "dreturn", "(", ")", ";", "break", ";", "default", ":", "areturn", "(", ")", ";", "}", "}", "}", "public", "void", "generateStringConcatenationAppend", "(", "BlockScope", "blockScope", ",", "Expression", "oper1", ",", "Expression", "oper2", ")", "{", "int", "pc", ";", "if", "(", "oper1", "==", "null", ")", "{", "newStringContatenation", "(", ")", ";", "dup_x1", "(", ")", ";", "this", ".", "swap", "(", ")", ";", "invokeStringValueOf", "(", "TypeIds", ".", "T_JavaLangObject", ")", ";", "invokeStringConcatenationStringConstructor", "(", ")", ";", "}", "else", "{", "pc", "=", "this", ".", "position", ";", "oper1", ".", "generateOptimizedStringConcatenationCreation", "(", "blockScope", ",", "this", ",", "oper1", ".", "implicitConversion", "&", "TypeIds", ".", "COMPILE_TYPE_MASK", ")", ";", "this", ".", "recordPositionsFrom", "(", "pc", ",", "oper1", ".", "sourceStart", ")", ";", "}", "pc", "=", "this", ".", "position", ";", "oper2", ".", "generateOptimizedStringConcatenation", "(", "blockScope", ",", "this", ",", "oper2", ".", "implicitConversion", "&", "TypeIds", ".", "COMPILE_TYPE_MASK", ")", ";", "this", ".", "recordPositionsFrom", "(", "pc", ",", "oper2", ".", "sourceStart", ")", ";", "invokeStringConcatenationToString", "(", ")", ";", "}", "public", "void", "generateSyntheticBodyForConstructorAccess", "(", "SyntheticMethodBinding", "accessBinding", ")", "{", "initializeMaxLocals", "(", "accessBinding", ")", ";", "MethodBinding", "constructorBinding", "=", "accessBinding", ".", "targetMethod", ";", "TypeBinding", "[", "]", "parameters", "=", "constructorBinding", ".", "parameters", ";", "int", "length", "=", "parameters", ".", "length", ";", "int", "resolvedPosition", "=", "1", ";", "aload_0", "(", ")", ";", "TypeBinding", "declaringClass", "=", "constructorBinding", ".", "declaringClass", ";", "if", "(", "declaringClass", ".", "erasure", "(", ")", ".", "id", "==", "TypeIds", ".", "T_JavaLangEnum", "||", "declaringClass", ".", "isEnum", "(", ")", ")", "{", "aload_1", "(", ")", ";", "iload_2", "(", ")", ";", "resolvedPosition", "+=", "2", ";", "}", "if", "(", "declaringClass", ".", "isNestedType", "(", ")", ")", "{", "NestedTypeBinding", "nestedType", "=", "(", "NestedTypeBinding", ")", "declaringClass", ";", "SyntheticArgumentBinding", "[", "]", "syntheticArguments", "=", "nestedType", ".", "syntheticEnclosingInstances", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "(", "syntheticArguments", "==", "null", "?", "0", ":", "syntheticArguments", ".", "length", ")", ";", "i", "++", ")", "{", "TypeBinding", "type", ";", "load", "(", "(", "type", "=", "syntheticArguments", "[", "i", "]", ".", "type", ")", ",", "resolvedPosition", ")", ";", "switch", "(", "type", ".", "id", ")", "{", "case", "TypeIds", ".", "T_long", ":", "case", "TypeIds", ".", "T_double", ":", "resolvedPosition", "+=", "2", ";", "break", ";", "default", ":", "resolvedPosition", "++", ";", "break", ";", "}", "}", "}", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeBinding", "parameter", ";", "load", "(", "parameter", "=", "parameters", "[", "i", "]", ",", "resolvedPosition", ")", ";", "switch", "(", "parameter", ".", "id", ")", "{", "case", "TypeIds", ".", "T_long", ":", "case", "TypeIds", ".", "T_double", ":", "resolvedPosition", "+=", "2", ";", "break", ";", "default", ":", "resolvedPosition", "++", ";", "break", ";", "}", "}", "if", "(", "declaringClass", ".", "isNestedType", "(", ")", ")", "{", "NestedTypeBinding", "nestedType", "=", "(", "NestedTypeBinding", ")", "declaringClass", ";", "SyntheticArgumentBinding", "[", "]", "syntheticArguments", "=", "nestedType", ".", "syntheticOuterLocalVariables", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "(", "syntheticArguments", "==", "null", "?", "0", ":", "syntheticArguments", ".", "length", ")", ";", "i", "++", ")", "{", "TypeBinding", "type", ";", "load", "(", "type", "=", "syntheticArguments", "[", "i", "]", ".", "type", ",", "resolvedPosition", ")", ";", "switch", "(", "type", ".", "id", ")", "{", "case", "TypeIds", ".", "T_long", ":", "case", "TypeIds", ".", "T_double", ":", "resolvedPosition", "+=", "2", ";", "break", ";", "default", ":", "resolvedPosition", "++", ";", "break", ";", "}", "}", "}", "invoke", "(", "Opcodes", ".", "OPC_invokespecial", ",", "constructorBinding", ",", "null", ")", ";", "return_", "(", ")", ";", "}", "public", "void", "generateSyntheticBodyForEnumValueOf", "(", "SyntheticMethodBinding", "methodBinding", ")", "{", "initializeMaxLocals", "(", "methodBinding", ")", ";", "final", "ReferenceBinding", "declaringClass", "=", "methodBinding", ".", "declaringClass", ";", "generateClassLiteralAccessForType", "(", "declaringClass", ",", "null", ")", ";", "aload_0", "(", ")", ";", "invokeJavaLangEnumvalueOf", "(", "declaringClass", ")", ";", "this", ".", "checkcast", "(", "declaringClass", ")", ";", "areturn", "(", ")", ";", "}", "public", "void", "generateSyntheticBodyForEnumValues", "(", "SyntheticMethodBinding", "methodBinding", ")", "{", "ClassScope", "scope", "=", "(", "(", "SourceTypeBinding", ")", "methodBinding", ".", "declaringClass", ")", ".", "scope", ";", "initializeMaxLocals", "(", "methodBinding", ")", ";", "TypeBinding", "enumArray", "=", "methodBinding", ".", "returnType", ";", "fieldAccess", "(", "Opcodes", ".", "OPC_getstatic", ",", "scope", ".", "referenceContext", ".", "enumValuesSyntheticfield", ",", "null", ")", ";", "dup", "(", ")", ";", "astore_0", "(", ")", ";", "iconst_0", "(", ")", ";", "aload_0", "(", ")", ";", "arraylength", "(", ")", ";", "dup", "(", ")", ";", "istore_1", "(", ")", ";", "newArray", "(", "(", "ArrayBinding", ")", "enumArray", ")", ";", "dup", "(", ")", ";", "astore_2", "(", ")", ";", "iconst_0", "(", ")", ";", "iload_1", "(", ")", ";", "invokeSystemArraycopy", "(", ")", ";", "aload_2", "(", ")", ";", "areturn", "(", ")", ";", "}", "public", "void", "generateSyntheticBodyForFieldReadAccess", "(", "SyntheticMethodBinding", "accessMethod", ")", "{", "initializeMaxLocals", "(", "accessMethod", ")", ";", "FieldBinding", "fieldBinding", "=", "accessMethod", ".", "targetReadField", ";", "TypeBinding", "declaringClass", "=", "accessMethod", ".", "purpose", "==", "SyntheticMethodBinding", ".", "SuperFieldReadAccess", "?", "accessMethod", ".", "declaringClass", ".", "superclass", "(", ")", ":", "accessMethod", ".", "declaringClass", ";", "if", "(", "fieldBinding", ".", "isStatic", "(", ")", ")", "{", "fieldAccess", "(", "Opcodes", ".", "OPC_getstatic", ",", "fieldBinding", ",", "declaringClass", ")", ";", "}", "else", "{", "aload_0", "(", ")", ";", "fieldAccess", "(", "Opcodes", ".", "OPC_getfield", ",", "fieldBinding", ",", "declaringClass", ")", ";", "}", "switch", "(", "fieldBinding", ".", "type", ".", "id", ")", "{", "case", "TypeIds", ".", "T_boolean", ":", "case", "TypeIds", ".", "T_byte", ":", "case", "TypeIds", ".", "T_char", ":", "case", "TypeIds", ".", "T_short", ":", "case", "TypeIds", ".", "T_int", ":", "ireturn", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "lreturn", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "freturn", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "dreturn", "(", ")", ";", "break", ";", "default", ":", "areturn", "(", ")", ";", "}", "}", "public", "void", "generateSyntheticBodyForFieldWriteAccess", "(", "SyntheticMethodBinding", "accessMethod", ")", "{", "initializeMaxLocals", "(", "accessMethod", ")", ";", "FieldBinding", "fieldBinding", "=", "accessMethod", ".", "targetWriteField", ";", "TypeBinding", "declaringClass", "=", "accessMethod", ".", "purpose", "==", "SyntheticMethodBinding", ".", "SuperFieldWriteAccess", "?", "accessMethod", ".", "declaringClass", ".", "superclass", "(", ")", ":", "accessMethod", ".", "declaringClass", ";", "if", "(", "fieldBinding", ".", "isStatic", "(", ")", ")", "{", "load", "(", "fieldBinding", ".", "type", ",", "0", ")", ";", "fieldAccess", "(", "Opcodes", ".", "OPC_putstatic", ",", "fieldBinding", ",", "declaringClass", ")", ";", "}", "else", "{", "aload_0", "(", ")", ";", "load", "(", "fieldBinding", ".", "type", ",", "1", ")", ";", "fieldAccess", "(", "Opcodes", ".", "OPC_putfield", ",", "fieldBinding", ",", "declaringClass", ")", ";", "}", "return_", "(", ")", ";", "}", "public", "void", "generateSyntheticBodyForMethodAccess", "(", "SyntheticMethodBinding", "accessMethod", ")", "{", "initializeMaxLocals", "(", "accessMethod", ")", ";", "MethodBinding", "targetMethod", "=", "accessMethod", ".", "targetMethod", ";", "TypeBinding", "[", "]", "parameters", "=", "targetMethod", ".", "parameters", ";", "int", "length", "=", "parameters", ".", "length", ";", "TypeBinding", "[", "]", "arguments", "=", "accessMethod", ".", "purpose", "==", "SyntheticMethodBinding", ".", "BridgeMethod", "?", "accessMethod", ".", "parameters", ":", "null", ";", "int", "resolvedPosition", ";", "if", "(", "targetMethod", ".", "isStatic", "(", ")", ")", "resolvedPosition", "=", "0", ";", "else", "{", "aload_0", "(", ")", ";", "resolvedPosition", "=", "1", ";", "}", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeBinding", "parameter", "=", "parameters", "[", "i", "]", ";", "if", "(", "arguments", "!=", "null", ")", "{", "TypeBinding", "argument", "=", "arguments", "[", "i", "]", ";", "load", "(", "argument", ",", "resolvedPosition", ")", ";", "if", "(", "argument", "!=", "parameter", ")", "checkcast", "(", "parameter", ")", ";", "}", "else", "{", "load", "(", "parameter", ",", "resolvedPosition", ")", ";", "}", "switch", "(", "parameter", ".", "id", ")", "{", "case", "TypeIds", ".", "T_long", ":", "case", "TypeIds", ".", "T_double", ":", "resolvedPosition", "+=", "2", ";", "break", ";", "default", ":", "resolvedPosition", "++", ";", "break", ";", "}", "}", "if", "(", "targetMethod", ".", "isStatic", "(", ")", ")", "invoke", "(", "Opcodes", ".", "OPC_invokestatic", ",", "targetMethod", ",", "accessMethod", ".", "declaringClass", ")", ";", "else", "{", "if", "(", "targetMethod", ".", "isConstructor", "(", ")", "||", "targetMethod", ".", "isPrivate", "(", ")", "||", "accessMethod", ".", "purpose", "==", "SyntheticMethodBinding", ".", "SuperMethodAccess", ")", "{", "TypeBinding", "declaringClass", "=", "accessMethod", ".", "purpose", "==", "SyntheticMethodBinding", ".", "SuperMethodAccess", "?", "accessMethod", ".", "declaringClass", ".", "superclass", "(", ")", ":", "accessMethod", ".", "declaringClass", ";", "invoke", "(", "Opcodes", ".", "OPC_invokespecial", ",", "targetMethod", ",", "declaringClass", ")", ";", "}", "else", "{", "if", "(", "targetMethod", ".", "declaringClass", ".", "isInterface", "(", ")", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokeinterface", ",", "targetMethod", ",", "null", ")", ";", "}", "else", "{", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "targetMethod", ",", "accessMethod", ".", "declaringClass", ")", ";", "}", "}", "}", "switch", "(", "targetMethod", ".", "returnType", ".", "id", ")", "{", "case", "TypeIds", ".", "T_void", ":", "return_", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_boolean", ":", "case", "TypeIds", ".", "T_byte", ":", "case", "TypeIds", ".", "T_char", ":", "case", "TypeIds", ".", "T_short", ":", "case", "TypeIds", ".", "T_int", ":", "ireturn", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "lreturn", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "freturn", "(", ")", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "dreturn", "(", ")", ";", "break", ";", "default", ":", "TypeBinding", "accessErasure", "=", "accessMethod", ".", "returnType", ".", "erasure", "(", ")", ";", "TypeBinding", "match", "=", "targetMethod", ".", "returnType", ".", "findSuperTypeOriginatingFrom", "(", "accessErasure", ")", ";", "if", "(", "match", "==", "null", ")", "{", "this", ".", "checkcast", "(", "accessErasure", ")", ";", "}", "areturn", "(", ")", ";", "}", "}", "public", "void", "generateSyntheticBodyForSwitchTable", "(", "SyntheticMethodBinding", "methodBinding", ")", "{", "ClassScope", "scope", "=", "(", "(", "SourceTypeBinding", ")", "methodBinding", ".", "declaringClass", ")", ".", "scope", ";", "initializeMaxLocals", "(", "methodBinding", ")", ";", "final", "BranchLabel", "nullLabel", "=", "new", "BranchLabel", "(", "this", ")", ";", "FieldBinding", "syntheticFieldBinding", "=", "methodBinding", ".", "targetReadField", ";", "fieldAccess", "(", "Opcodes", ".", "OPC_getstatic", ",", "syntheticFieldBinding", ",", "null", ")", ";", "dup", "(", ")", ";", "ifnull", "(", "nullLabel", ")", ";", "areturn", "(", ")", ";", "pushOnStack", "(", "syntheticFieldBinding", ".", "type", ")", ";", "nullLabel", ".", "place", "(", ")", ";", "pop", "(", ")", ";", "ReferenceBinding", "enumBinding", "=", "(", "ReferenceBinding", ")", "methodBinding", ".", "targetEnumType", ";", "ArrayBinding", "arrayBinding", "=", "scope", ".", "createArrayType", "(", "enumBinding", ",", "1", ")", ";", "invokeJavaLangEnumValues", "(", "enumBinding", ",", "arrayBinding", ")", ";", "arraylength", "(", ")", ";", "newarray", "(", "ClassFileConstants", ".", "INT_ARRAY", ")", ";", "astore_0", "(", ")", ";", "LocalVariableBinding", "localVariableBinding", "=", "new", "LocalVariableBinding", "(", "\"", "tab\"", ".", "toCharArray", "(", ")", ",", "scope", ".", "createArrayType", "(", "TypeBinding", ".", "INT", ",", "1", ")", ",", "0", ",", "false", ")", ";", "addVariable", "(", "localVariableBinding", ")", ";", "final", "FieldBinding", "[", "]", "fields", "=", "enumBinding", ".", "fields", "(", ")", ";", "if", "(", "fields", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "fields", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "FieldBinding", "fieldBinding", "=", "fields", "[", "i", "]", ";", "if", "(", "(", "fieldBinding", ".", "getAccessFlags", "(", ")", "&", "ClassFileConstants", ".", "AccEnum", ")", "!=", "0", ")", "{", "final", "BranchLabel", "endLabel", "=", "new", "BranchLabel", "(", "this", ")", ";", "final", "ExceptionLabel", "anyExceptionHandler", "=", "new", "ExceptionLabel", "(", "this", ",", "TypeBinding", ".", "LONG", ")", ";", "anyExceptionHandler", ".", "placeStart", "(", ")", ";", "aload_0", "(", ")", ";", "fieldAccess", "(", "Opcodes", ".", "OPC_getstatic", ",", "fieldBinding", ",", "null", ")", ";", "invokeEnumOrdinal", "(", "enumBinding", ".", "constantPoolName", "(", ")", ")", ";", "this", ".", "generateInlinedValue", "(", "fieldBinding", ".", "id", "+", "1", ")", ";", "iastore", "(", ")", ";", "anyExceptionHandler", ".", "placeEnd", "(", ")", ";", "goto_", "(", "endLabel", ")", ";", "pushExceptionOnStack", "(", "TypeBinding", ".", "LONG", ")", ";", "anyExceptionHandler", ".", "place", "(", ")", ";", "pop", "(", ")", ";", "endLabel", ".", "place", "(", ")", ";", "}", "}", "}", "aload_0", "(", ")", ";", "dup", "(", ")", ";", "fieldAccess", "(", "Opcodes", ".", "OPC_putstatic", ",", "syntheticFieldBinding", ",", "null", ")", ";", "areturn", "(", ")", ";", "removeVariable", "(", "localVariableBinding", ")", ";", "}", "public", "void", "generateSyntheticEnclosingInstanceValues", "(", "BlockScope", "currentScope", ",", "ReferenceBinding", "targetType", ",", "Expression", "enclosingInstance", ",", "ASTNode", "invocationSite", ")", "{", "ReferenceBinding", "checkedTargetType", "=", "targetType", ".", "isAnonymousType", "(", ")", "?", "(", "ReferenceBinding", ")", "targetType", ".", "superclass", "(", ")", ".", "erasure", "(", ")", ":", "targetType", ";", "boolean", "hasExtraEnclosingInstance", "=", "enclosingInstance", "!=", "null", ";", "if", "(", "hasExtraEnclosingInstance", "&&", "(", "!", "checkedTargetType", ".", "isNestedType", "(", ")", "||", "checkedTargetType", ".", "isStatic", "(", ")", ")", ")", "{", "currentScope", ".", "problemReporter", "(", ")", ".", "unnecessaryEnclosingInstanceSpecification", "(", "enclosingInstance", ",", "checkedTargetType", ")", ";", "return", ";", "}", "ReferenceBinding", "[", "]", "syntheticArgumentTypes", ";", "if", "(", "(", "syntheticArgumentTypes", "=", "targetType", ".", "syntheticEnclosingInstanceTypes", "(", ")", ")", "!=", "null", ")", "{", "ReferenceBinding", "targetEnclosingType", "=", "checkedTargetType", ".", "enclosingType", "(", ")", ";", "long", "compliance", "=", "currentScope", ".", "compilerOptions", "(", ")", ".", "complianceLevel", ";", "boolean", "denyEnclosingArgInConstructorCall", ";", "if", "(", "compliance", "<=", "ClassFileConstants", ".", "JDK1_3", ")", "{", "denyEnclosingArgInConstructorCall", "=", "invocationSite", "instanceof", "AllocationExpression", ";", "}", "else", "if", "(", "compliance", "==", "ClassFileConstants", ".", "JDK1_4", ")", "{", "denyEnclosingArgInConstructorCall", "=", "invocationSite", "instanceof", "AllocationExpression", "||", "invocationSite", "instanceof", "ExplicitConstructorCall", "&&", "(", "(", "ExplicitConstructorCall", ")", "invocationSite", ")", ".", "isSuperAccess", "(", ")", ";", "}", "else", "{", "denyEnclosingArgInConstructorCall", "=", "(", "invocationSite", "instanceof", "AllocationExpression", "||", "invocationSite", "instanceof", "ExplicitConstructorCall", "&&", "(", "(", "ExplicitConstructorCall", ")", "invocationSite", ")", ".", "isSuperAccess", "(", ")", ")", "&&", "!", "targetType", ".", "isLocalType", "(", ")", ";", "}", "boolean", "complyTo14", "=", "compliance", ">=", "ClassFileConstants", ".", "JDK1_4", ";", "for", "(", "int", "i", "=", "0", ",", "max", "=", "syntheticArgumentTypes", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "ReferenceBinding", "syntheticArgType", "=", "syntheticArgumentTypes", "[", "i", "]", ";", "if", "(", "hasExtraEnclosingInstance", "&&", "syntheticArgType", "==", "targetEnclosingType", ")", "{", "hasExtraEnclosingInstance", "=", "false", ";", "enclosingInstance", ".", "generateCode", "(", "currentScope", ",", "this", ",", "true", ")", ";", "if", "(", "complyTo14", ")", "{", "dup", "(", ")", ";", "invokeObjectGetClass", "(", ")", ";", "pop", "(", ")", ";", "}", "}", "else", "{", "Object", "[", "]", "emulationPath", "=", "currentScope", ".", "getEmulationPath", "(", "syntheticArgType", ",", "false", ",", "denyEnclosingArgInConstructorCall", ")", ";", "generateOuterAccess", "(", "emulationPath", ",", "invocationSite", ",", "syntheticArgType", ",", "currentScope", ")", ";", "}", "}", "if", "(", "hasExtraEnclosingInstance", ")", "{", "currentScope", ".", "problemReporter", "(", ")", ".", "unnecessaryEnclosingInstanceSpecification", "(", "enclosingInstance", ",", "checkedTargetType", ")", ";", "}", "}", "}", "public", "void", "generateSyntheticOuterArgumentValues", "(", "BlockScope", "currentScope", ",", "ReferenceBinding", "targetType", ",", "ASTNode", "invocationSite", ")", "{", "SyntheticArgumentBinding", "syntheticArguments", "[", "]", ";", "if", "(", "(", "syntheticArguments", "=", "targetType", ".", "syntheticOuterLocalVariables", "(", ")", ")", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "syntheticArguments", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "LocalVariableBinding", "targetVariable", "=", "syntheticArguments", "[", "i", "]", ".", "actualOuterLocalVariable", ";", "VariableBinding", "[", "]", "emulationPath", "=", "currentScope", ".", "getEmulationPath", "(", "targetVariable", ")", ";", "generateOuterAccess", "(", "emulationPath", ",", "invocationSite", ",", "targetVariable", ",", "currentScope", ")", ";", "}", "}", "}", "public", "void", "generateUnboxingConversion", "(", "int", "unboxedTypeID", ")", "{", "switch", "(", "unboxedTypeID", ")", "{", "case", "TypeIds", ".", "T_byte", ":", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangByteConstantPoolName", ",", "ConstantPool", ".", "BYTEVALUE_BYTE_METHOD_NAME", ",", "ConstantPool", ".", "BYTEVALUE_BYTE_METHOD_SIGNATURE", ")", ";", "break", ";", "case", "TypeIds", ".", "T_short", ":", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangShortConstantPoolName", ",", "ConstantPool", ".", "SHORTVALUE_SHORT_METHOD_NAME", ",", "ConstantPool", ".", "SHORTVALUE_SHORT_METHOD_SIGNATURE", ")", ";", "break", ";", "case", "TypeIds", ".", "T_char", ":", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangCharacterConstantPoolName", ",", "ConstantPool", ".", "CHARVALUE_CHARACTER_METHOD_NAME", ",", "ConstantPool", ".", "CHARVALUE_CHARACTER_METHOD_SIGNATURE", ")", ";", "break", ";", "case", "TypeIds", ".", "T_int", ":", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangIntegerConstantPoolName", ",", "ConstantPool", ".", "INTVALUE_INTEGER_METHOD_NAME", ",", "ConstantPool", ".", "INTVALUE_INTEGER_METHOD_SIGNATURE", ")", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "2", ",", "ConstantPool", ".", "JavaLangLongConstantPoolName", ",", "ConstantPool", ".", "LONGVALUE_LONG_METHOD_NAME", ",", "ConstantPool", ".", "LONGVALUE_LONG_METHOD_SIGNATURE", ")", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangFloatConstantPoolName", ",", "ConstantPool", ".", "FLOATVALUE_FLOAT_METHOD_NAME", ",", "ConstantPool", ".", "FLOATVALUE_FLOAT_METHOD_SIGNATURE", ")", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "2", ",", "ConstantPool", ".", "JavaLangDoubleConstantPoolName", ",", "ConstantPool", ".", "DOUBLEVALUE_DOUBLE_METHOD_NAME", ",", "ConstantPool", ".", "DOUBLEVALUE_DOUBLE_METHOD_SIGNATURE", ")", ";", "break", ";", "case", "TypeIds", ".", "T_boolean", ":", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangBooleanConstantPoolName", ",", "ConstantPool", ".", "BOOLEANVALUE_BOOLEAN_METHOD_NAME", ",", "ConstantPool", ".", "BOOLEANVALUE_BOOLEAN_METHOD_SIGNATURE", ")", ";", "}", "}", "public", "void", "generateWideRevertedConditionalBranch", "(", "byte", "revertedOpcode", ",", "BranchLabel", "wideTarget", ")", "{", "BranchLabel", "intermediate", "=", "new", "BranchLabel", "(", "this", ")", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "revertedOpcode", ";", "intermediate", ".", "branch", "(", ")", ";", "goto_w", "(", "wideTarget", ")", ";", "intermediate", ".", "place", "(", ")", ";", "}", "public", "void", "getBaseTypeValue", "(", "int", "baseTypeID", ")", "{", "switch", "(", "baseTypeID", ")", "{", "case", "TypeIds", ".", "T_byte", ":", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangByteConstantPoolName", ",", "ConstantPool", ".", "BYTEVALUE_BYTE_METHOD_NAME", ",", "ConstantPool", ".", "BYTEVALUE_BYTE_METHOD_SIGNATURE", ")", ";", "break", ";", "case", "TypeIds", ".", "T_short", ":", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangShortConstantPoolName", ",", "ConstantPool", ".", "SHORTVALUE_SHORT_METHOD_NAME", ",", "ConstantPool", ".", "SHORTVALUE_SHORT_METHOD_SIGNATURE", ")", ";", "break", ";", "case", "TypeIds", ".", "T_char", ":", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangCharacterConstantPoolName", ",", "ConstantPool", ".", "CHARVALUE_CHARACTER_METHOD_NAME", ",", "ConstantPool", ".", "CHARVALUE_CHARACTER_METHOD_SIGNATURE", ")", ";", "break", ";", "case", "TypeIds", ".", "T_int", ":", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangIntegerConstantPoolName", ",", "ConstantPool", ".", "INTVALUE_INTEGER_METHOD_NAME", ",", "ConstantPool", ".", "INTVALUE_INTEGER_METHOD_SIGNATURE", ")", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "2", ",", "ConstantPool", ".", "JavaLangLongConstantPoolName", ",", "ConstantPool", ".", "LONGVALUE_LONG_METHOD_NAME", ",", "ConstantPool", ".", "LONGVALUE_LONG_METHOD_SIGNATURE", ")", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangFloatConstantPoolName", ",", "ConstantPool", ".", "FLOATVALUE_FLOAT_METHOD_NAME", ",", "ConstantPool", ".", "FLOATVALUE_FLOAT_METHOD_SIGNATURE", ")", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "2", ",", "ConstantPool", ".", "JavaLangDoubleConstantPoolName", ",", "ConstantPool", ".", "DOUBLEVALUE_DOUBLE_METHOD_NAME", ",", "ConstantPool", ".", "DOUBLEVALUE_DOUBLE_METHOD_SIGNATURE", ")", ";", "break", ";", "case", "TypeIds", ".", "T_boolean", ":", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangBooleanConstantPoolName", ",", "ConstantPool", ".", "BOOLEANVALUE_BOOLEAN_METHOD_NAME", ",", "ConstantPool", ".", "BOOLEANVALUE_BOOLEAN_METHOD_SIGNATURE", ")", ";", "}", "}", "final", "public", "byte", "[", "]", "getContents", "(", ")", "{", "byte", "[", "]", "contents", ";", "System", ".", "arraycopy", "(", "this", ".", "bCodeStream", ",", "0", ",", "contents", "=", "new", "byte", "[", "this", ".", "position", "]", ",", "0", ",", "this", ".", "position", ")", ";", "return", "contents", ";", "}", "public", "static", "TypeBinding", "getConstantPoolDeclaringClass", "(", "Scope", "currentScope", ",", "FieldBinding", "codegenBinding", ",", "TypeBinding", "actualReceiverType", ",", "boolean", "isImplicitThisReceiver", ")", "{", "ReferenceBinding", "constantPoolDeclaringClass", "=", "codegenBinding", ".", "declaringClass", ";", "if", "(", "constantPoolDeclaringClass", "!=", "actualReceiverType", ".", "erasure", "(", ")", "&&", "!", "actualReceiverType", ".", "isArrayType", "(", ")", "&&", "constantPoolDeclaringClass", "!=", "null", "&&", "codegenBinding", ".", "constant", "(", ")", "==", "Constant", ".", "NotAConstant", ")", "{", "CompilerOptions", "options", "=", "currentScope", ".", "compilerOptions", "(", ")", ";", "if", "(", "(", "options", ".", "targetJDK", ">=", "ClassFileConstants", ".", "JDK1_2", "&&", "(", "options", ".", "complianceLevel", ">=", "ClassFileConstants", ".", "JDK1_4", "||", "!", "(", "isImplicitThisReceiver", "&&", "codegenBinding", ".", "isStatic", "(", ")", ")", ")", "&&", "constantPoolDeclaringClass", ".", "id", "!=", "TypeIds", ".", "T_JavaLangObject", ")", "||", "!", "constantPoolDeclaringClass", ".", "canBeSeenBy", "(", "currentScope", ")", ")", "{", "return", "actualReceiverType", ".", "erasure", "(", ")", ";", "}", "}", "return", "constantPoolDeclaringClass", ";", "}", "public", "static", "TypeBinding", "getConstantPoolDeclaringClass", "(", "Scope", "currentScope", ",", "MethodBinding", "codegenBinding", ",", "TypeBinding", "actualReceiverType", ",", "boolean", "isImplicitThisReceiver", ")", "{", "TypeBinding", "constantPoolDeclaringClass", "=", "codegenBinding", ".", "declaringClass", ";", "if", "(", "codegenBinding", "==", "currentScope", ".", "environment", "(", ")", ".", "arrayClone", ")", "{", "CompilerOptions", "options", "=", "currentScope", ".", "compilerOptions", "(", ")", ";", "if", "(", "options", ".", "sourceLevel", ">", "ClassFileConstants", ".", "JDK1_4", ")", "{", "constantPoolDeclaringClass", "=", "actualReceiverType", ".", "erasure", "(", ")", ";", "}", "}", "else", "{", "if", "(", "constantPoolDeclaringClass", "!=", "actualReceiverType", ".", "erasure", "(", ")", "&&", "!", "actualReceiverType", ".", "isArrayType", "(", ")", ")", "{", "CompilerOptions", "options", "=", "currentScope", ".", "compilerOptions", "(", ")", ";", "if", "(", "(", "options", ".", "targetJDK", ">=", "ClassFileConstants", ".", "JDK1_2", "&&", "(", "options", ".", "complianceLevel", ">=", "ClassFileConstants", ".", "JDK1_4", "||", "!", "(", "isImplicitThisReceiver", "&&", "codegenBinding", ".", "isStatic", "(", ")", ")", ")", "&&", "codegenBinding", ".", "declaringClass", ".", "id", "!=", "TypeIds", ".", "T_JavaLangObject", ")", "||", "!", "codegenBinding", ".", "declaringClass", ".", "canBeSeenBy", "(", "currentScope", ")", ")", "{", "constantPoolDeclaringClass", "=", "actualReceiverType", ".", "erasure", "(", ")", ";", "}", "}", "}", "return", "constantPoolDeclaringClass", ";", "}", "protected", "int", "getPosition", "(", ")", "{", "return", "this", ".", "position", ";", "}", "public", "void", "getTYPE", "(", "int", "baseTypeID", ")", "{", "this", ".", "countLabels", "=", "0", ";", "switch", "(", "baseTypeID", ")", "{", "case", "TypeIds", ".", "T_byte", ":", "fieldAccess", "(", "Opcodes", ".", "OPC_getstatic", ",", "1", ",", "ConstantPool", ".", "JavaLangByteConstantPoolName", ",", "ConstantPool", ".", "TYPE", ",", "ConstantPool", ".", "JavaLangClassSignature", ")", ";", "break", ";", "case", "TypeIds", ".", "T_short", ":", "fieldAccess", "(", "Opcodes", ".", "OPC_getstatic", ",", "1", ",", "ConstantPool", ".", "JavaLangShortConstantPoolName", ",", "ConstantPool", ".", "TYPE", ",", "ConstantPool", ".", "JavaLangClassSignature", ")", ";", "break", ";", "case", "TypeIds", ".", "T_char", ":", "fieldAccess", "(", "Opcodes", ".", "OPC_getstatic", ",", "1", ",", "ConstantPool", ".", "JavaLangCharacterConstantPoolName", ",", "ConstantPool", ".", "TYPE", ",", "ConstantPool", ".", "JavaLangClassSignature", ")", ";", "break", ";", "case", "TypeIds", ".", "T_int", ":", "fieldAccess", "(", "Opcodes", ".", "OPC_getstatic", ",", "1", ",", "ConstantPool", ".", "JavaLangIntegerConstantPoolName", ",", "ConstantPool", ".", "TYPE", ",", "ConstantPool", ".", "JavaLangClassSignature", ")", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "fieldAccess", "(", "Opcodes", ".", "OPC_getstatic", ",", "1", ",", "ConstantPool", ".", "JavaLangLongConstantPoolName", ",", "ConstantPool", ".", "TYPE", ",", "ConstantPool", ".", "JavaLangClassSignature", ")", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "fieldAccess", "(", "Opcodes", ".", "OPC_getstatic", ",", "1", ",", "ConstantPool", ".", "JavaLangFloatConstantPoolName", ",", "ConstantPool", ".", "TYPE", ",", "ConstantPool", ".", "JavaLangClassSignature", ")", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "fieldAccess", "(", "Opcodes", ".", "OPC_getstatic", ",", "1", ",", "ConstantPool", ".", "JavaLangDoubleConstantPoolName", ",", "ConstantPool", ".", "TYPE", ",", "ConstantPool", ".", "JavaLangClassSignature", ")", ";", "break", ";", "case", "TypeIds", ".", "T_boolean", ":", "fieldAccess", "(", "Opcodes", ".", "OPC_getstatic", ",", "1", ",", "ConstantPool", ".", "JavaLangBooleanConstantPoolName", ",", "ConstantPool", ".", "TYPE", ",", "ConstantPool", ".", "JavaLangClassSignature", ")", ";", "break", ";", "case", "TypeIds", ".", "T_void", ":", "fieldAccess", "(", "Opcodes", ".", "OPC_getstatic", ",", "1", ",", "ConstantPool", ".", "JavaLangVoidConstantPoolName", ",", "ConstantPool", ".", "TYPE", ",", "ConstantPool", ".", "JavaLangClassSignature", ")", ";", "break", ";", "}", "}", "public", "void", "goto_", "(", "BranchLabel", "label", ")", "{", "if", "(", "this", ".", "wideMode", ")", "{", "goto_w", "(", "label", ")", ";", "return", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "boolean", "chained", "=", "inlineForwardReferencesFromLabelsTargeting", "(", "label", ",", "this", ".", "position", ")", ";", "if", "(", "chained", "&&", "this", ".", "lastAbruptCompletion", "==", "this", ".", "position", ")", "{", "if", "(", "label", ".", "position", "!=", "Label", ".", "POS_NOT_SET", ")", "{", "int", "[", "]", "forwardRefs", "=", "label", ".", "forwardReferences", "(", ")", ";", "for", "(", "int", "i", "=", "0", ",", "max", "=", "label", ".", "forwardReferenceCount", "(", ")", ";", "i", "<", "max", ";", "i", "++", ")", "{", "this", ".", "writePosition", "(", "label", ",", "forwardRefs", "[", "i", "]", ")", ";", "}", "this", ".", "countLabels", "=", "0", ";", "}", "return", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_goto", ";", "label", ".", "branch", "(", ")", ";", "this", ".", "lastAbruptCompletion", "=", "this", ".", "position", ";", "}", "public", "void", "goto_w", "(", "BranchLabel", "label", ")", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_goto_w", ";", "label", ".", "branchWide", "(", ")", ";", "this", ".", "lastAbruptCompletion", "=", "this", ".", "position", ";", "}", "public", "void", "i2b", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_i2b", ";", "}", "public", "void", "i2c", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_i2c", ";", "}", "public", "void", "i2d", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_i2d", ";", "}", "public", "void", "i2f", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_i2f", ";", "}", "public", "void", "i2l", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_i2l", ";", "}", "public", "void", "i2s", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_i2s", ";", "}", "public", "void", "iadd", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iadd", ";", "}", "public", "void", "iaload", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iaload", ";", "}", "public", "void", "iand", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iand", ";", "}", "public", "void", "iastore", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "3", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iastore", ";", "}", "public", "void", "iconst_0", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iconst_0", ";", "}", "public", "void", "iconst_1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iconst_1", ";", "}", "public", "void", "iconst_2", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iconst_2", ";", "}", "public", "void", "iconst_3", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iconst_3", ";", "}", "public", "void", "iconst_4", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iconst_4", ";", "}", "public", "void", "iconst_5", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iconst_5", ";", "}", "public", "void", "iconst_m1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iconst_m1", ";", "}", "public", "void", "idiv", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_idiv", ";", "}", "public", "void", "if_acmpeq", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "wideMode", ")", "{", "generateWideRevertedConditionalBranch", "(", "Opcodes", ".", "OPC_if_acmpne", ",", "lbl", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_if_acmpeq", ";", "lbl", ".", "branch", "(", ")", ";", "}", "}", "public", "void", "if_acmpne", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "wideMode", ")", "{", "generateWideRevertedConditionalBranch", "(", "Opcodes", ".", "OPC_if_acmpeq", ",", "lbl", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_if_acmpne", ";", "lbl", ".", "branch", "(", ")", ";", "}", "}", "public", "void", "if_icmpeq", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "wideMode", ")", "{", "generateWideRevertedConditionalBranch", "(", "Opcodes", ".", "OPC_if_icmpne", ",", "lbl", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_if_icmpeq", ";", "lbl", ".", "branch", "(", ")", ";", "}", "}", "public", "void", "if_icmpge", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "wideMode", ")", "{", "generateWideRevertedConditionalBranch", "(", "Opcodes", ".", "OPC_if_icmplt", ",", "lbl", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_if_icmpge", ";", "lbl", ".", "branch", "(", ")", ";", "}", "}", "public", "void", "if_icmpgt", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "wideMode", ")", "{", "generateWideRevertedConditionalBranch", "(", "Opcodes", ".", "OPC_if_icmple", ",", "lbl", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_if_icmpgt", ";", "lbl", ".", "branch", "(", ")", ";", "}", "}", "public", "void", "if_icmple", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "wideMode", ")", "{", "generateWideRevertedConditionalBranch", "(", "Opcodes", ".", "OPC_if_icmpgt", ",", "lbl", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_if_icmple", ";", "lbl", ".", "branch", "(", ")", ";", "}", "}", "public", "void", "if_icmplt", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "wideMode", ")", "{", "generateWideRevertedConditionalBranch", "(", "Opcodes", ".", "OPC_if_icmpge", ",", "lbl", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_if_icmplt", ";", "lbl", ".", "branch", "(", ")", ";", "}", "}", "public", "void", "if_icmpne", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "wideMode", ")", "{", "generateWideRevertedConditionalBranch", "(", "Opcodes", ".", "OPC_if_icmpeq", ",", "lbl", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_if_icmpne", ";", "lbl", ".", "branch", "(", ")", ";", "}", "}", "public", "void", "ifeq", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "wideMode", ")", "{", "generateWideRevertedConditionalBranch", "(", "Opcodes", ".", "OPC_ifne", ",", "lbl", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ifeq", ";", "lbl", ".", "branch", "(", ")", ";", "}", "}", "public", "void", "ifge", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "wideMode", ")", "{", "generateWideRevertedConditionalBranch", "(", "Opcodes", ".", "OPC_iflt", ",", "lbl", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ifge", ";", "lbl", ".", "branch", "(", ")", ";", "}", "}", "public", "void", "ifgt", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "wideMode", ")", "{", "generateWideRevertedConditionalBranch", "(", "Opcodes", ".", "OPC_ifle", ",", "lbl", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ifgt", ";", "lbl", ".", "branch", "(", ")", ";", "}", "}", "public", "void", "ifle", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "wideMode", ")", "{", "generateWideRevertedConditionalBranch", "(", "Opcodes", ".", "OPC_ifgt", ",", "lbl", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ifle", ";", "lbl", ".", "branch", "(", ")", ";", "}", "}", "public", "void", "iflt", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "wideMode", ")", "{", "generateWideRevertedConditionalBranch", "(", "Opcodes", ".", "OPC_ifge", ",", "lbl", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iflt", ";", "lbl", ".", "branch", "(", ")", ";", "}", "}", "public", "void", "ifne", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "wideMode", ")", "{", "generateWideRevertedConditionalBranch", "(", "Opcodes", ".", "OPC_ifeq", ",", "lbl", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ifne", ";", "lbl", ".", "branch", "(", ")", ";", "}", "}", "public", "void", "ifnonnull", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "wideMode", ")", "{", "generateWideRevertedConditionalBranch", "(", "Opcodes", ".", "OPC_ifnull", ",", "lbl", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ifnonnull", ";", "lbl", ".", "branch", "(", ")", ";", "}", "}", "public", "void", "ifnull", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "wideMode", ")", "{", "generateWideRevertedConditionalBranch", "(", "Opcodes", ".", "OPC_ifnonnull", ",", "lbl", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ifnull", ";", "lbl", ".", "branch", "(", ")", ";", "}", "}", "final", "public", "void", "iinc", "(", "int", "index", ",", "int", "value", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "(", "index", ">", "255", ")", "||", "(", "value", "<", "-", "128", "||", "value", ">", "127", ")", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "3", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_wide", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iinc", ";", "writeUnsignedShort", "(", "index", ")", ";", "writeSignedShort", "(", "value", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "3", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iinc", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "index", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "value", ";", "}", "}", "public", "void", "iload", "(", "int", "iArg", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "maxLocals", "<=", "iArg", ")", "{", "this", ".", "maxLocals", "=", "iArg", "+", "1", ";", "}", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "iArg", ">", "255", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "3", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_wide", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iload", ";", "writeUnsignedShort", "(", "iArg", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iload", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "iArg", ";", "}", "}", "public", "void", "iload_0", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "maxLocals", "<=", "0", ")", "{", "this", ".", "maxLocals", "=", "1", ";", "}", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iload_0", ";", "}", "public", "void", "iload_1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "maxLocals", "<=", "1", ")", "{", "this", ".", "maxLocals", "=", "2", ";", "}", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iload_1", ";", "}", "public", "void", "iload_2", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "maxLocals", "<=", "2", ")", "{", "this", ".", "maxLocals", "=", "3", ";", "}", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iload_2", ";", "}", "public", "void", "iload_3", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "maxLocals", "<=", "3", ")", "{", "this", ".", "maxLocals", "=", "4", ";", "}", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iload_3", ";", "}", "public", "void", "imul", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_imul", ";", "}", "public", "int", "indexOfSameLineEntrySincePC", "(", "int", "pc", ",", "int", "line", ")", "{", "for", "(", "int", "index", "=", "pc", ",", "max", "=", "this", ".", "pcToSourceMapSize", ";", "index", "<", "max", ";", "index", "+=", "2", ")", "{", "if", "(", "this", ".", "pcToSourceMap", "[", "index", "+", "1", "]", "==", "line", ")", "return", "index", ";", "}", "return", "-", "1", ";", "}", "public", "void", "ineg", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ineg", ";", "}", "public", "void", "init", "(", "ClassFile", "targetClassFile", ")", "{", "this", ".", "classFile", "=", "targetClassFile", ";", "this", ".", "constantPool", "=", "targetClassFile", ".", "constantPool", ";", "this", ".", "bCodeStream", "=", "targetClassFile", ".", "contents", ";", "this", ".", "classFileOffset", "=", "targetClassFile", ".", "contentsOffset", ";", "this", ".", "startingClassFileOffset", "=", "this", ".", "classFileOffset", ";", "this", ".", "pcToSourceMapSize", "=", "0", ";", "this", ".", "lastEntryPC", "=", "0", ";", "int", "length", "=", "this", ".", "visibleLocals", ".", "length", ";", "if", "(", "noVisibleLocals", ".", "length", "<", "length", ")", "{", "noVisibleLocals", "=", "new", "LocalVariableBinding", "[", "length", "]", ";", "}", "System", ".", "arraycopy", "(", "noVisibleLocals", ",", "0", ",", "this", ".", "visibleLocals", ",", "0", ",", "length", ")", ";", "this", ".", "visibleLocalsCount", "=", "0", ";", "length", "=", "this", ".", "locals", ".", "length", ";", "if", "(", "noLocals", ".", "length", "<", "length", ")", "{", "noLocals", "=", "new", "LocalVariableBinding", "[", "length", "]", ";", "}", "System", ".", "arraycopy", "(", "noLocals", ",", "0", ",", "this", ".", "locals", ",", "0", ",", "length", ")", ";", "this", ".", "allLocalsCounter", "=", "0", ";", "length", "=", "this", ".", "exceptionLabels", ".", "length", ";", "if", "(", "noExceptionHandlers", ".", "length", "<", "length", ")", "{", "noExceptionHandlers", "=", "new", "ExceptionLabel", "[", "length", "]", ";", "}", "System", ".", "arraycopy", "(", "noExceptionHandlers", ",", "0", ",", "this", ".", "exceptionLabels", ",", "0", ",", "length", ")", ";", "this", ".", "exceptionLabelsCounter", "=", "0", ";", "length", "=", "this", ".", "labels", ".", "length", ";", "if", "(", "noLabels", ".", "length", "<", "length", ")", "{", "noLabels", "=", "new", "BranchLabel", "[", "length", "]", ";", "}", "System", ".", "arraycopy", "(", "noLabels", ",", "0", ",", "this", ".", "labels", ",", "0", ",", "length", ")", ";", "this", ".", "countLabels", "=", "0", ";", "this", ".", "lastAbruptCompletion", "=", "-", "1", ";", "this", ".", "stackMax", "=", "0", ";", "this", ".", "stackDepth", "=", "0", ";", "this", ".", "maxLocals", "=", "0", ";", "this", ".", "position", "=", "0", ";", "}", "public", "void", "initializeMaxLocals", "(", "MethodBinding", "methodBinding", ")", "{", "if", "(", "methodBinding", "==", "null", ")", "{", "this", ".", "maxLocals", "=", "0", ";", "return", ";", "}", "this", ".", "maxLocals", "=", "methodBinding", ".", "isStatic", "(", ")", "?", "0", ":", "1", ";", "ReferenceBinding", "declaringClass", "=", "methodBinding", ".", "declaringClass", ";", "if", "(", "methodBinding", ".", "isConstructor", "(", ")", "&&", "declaringClass", ".", "isEnum", "(", ")", ")", "{", "this", ".", "maxLocals", "+=", "2", ";", "}", "if", "(", "methodBinding", ".", "isConstructor", "(", ")", "&&", "declaringClass", ".", "isNestedType", "(", ")", ")", "{", "this", ".", "maxLocals", "+=", "declaringClass", ".", "getEnclosingInstancesSlotSize", "(", ")", ";", "this", ".", "maxLocals", "+=", "declaringClass", ".", "getOuterLocalVariablesSlotSize", "(", ")", ";", "}", "TypeBinding", "[", "]", "parameterTypes", ";", "if", "(", "(", "parameterTypes", "=", "methodBinding", ".", "parameters", ")", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "parameterTypes", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "switch", "(", "parameterTypes", "[", "i", "]", ".", "id", ")", "{", "case", "TypeIds", ".", "T_long", ":", "case", "TypeIds", ".", "T_double", ":", "this", ".", "maxLocals", "+=", "2", ";", "break", ";", "default", ":", "this", ".", "maxLocals", "++", ";", "}", "}", "}", "}", "public", "boolean", "inlineForwardReferencesFromLabelsTargeting", "(", "BranchLabel", "targetLabel", ",", "int", "gotoLocation", ")", "{", "if", "(", "targetLabel", ".", "delegate", "!=", "null", ")", "return", "false", ";", "int", "chaining", "=", "L_UNKNOWN", ";", "for", "(", "int", "i", "=", "this", ".", "countLabels", "-", "1", ";", "i", ">=", "0", ";", "i", "--", ")", "{", "BranchLabel", "currentLabel", "=", "this", ".", "labels", "[", "i", "]", ";", "if", "(", "currentLabel", ".", "position", "!=", "gotoLocation", ")", "break", ";", "if", "(", "currentLabel", "==", "targetLabel", ")", "{", "chaining", "|=", "L_CANNOT_OPTIMIZE", ";", "continue", ";", "}", "if", "(", "currentLabel", ".", "isStandardLabel", "(", ")", ")", "{", "if", "(", "currentLabel", ".", "delegate", "!=", "null", ")", "continue", ";", "targetLabel", ".", "becomeDelegateFor", "(", "currentLabel", ")", ";", "chaining", "|=", "L_OPTIMIZABLE", ";", "continue", ";", "}", "chaining", "|=", "L_CANNOT_OPTIMIZE", ";", "}", "return", "(", "chaining", "&", "(", "L_OPTIMIZABLE", "|", "L_CANNOT_OPTIMIZE", ")", ")", "==", "L_OPTIMIZABLE", ";", "}", "public", "void", "instance_of", "(", "TypeBinding", "typeBinding", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_instanceof", ";", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "typeBinding", ")", ")", ";", "}", "protected", "void", "invoke", "(", "byte", "opcode", ",", "int", "receiverAndArgsSize", ",", "int", "returnTypeSize", ",", "char", "[", "]", "declaringClass", ",", "char", "[", "]", "selector", ",", "char", "[", "]", "signature", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "opcode", "==", "Opcodes", ".", "OPC_invokeinterface", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "4", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "3", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "opcode", ";", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForMethod", "(", "declaringClass", ",", "selector", ",", "signature", ",", "true", ")", ")", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "receiverAndArgsSize", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "0", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "opcode", ";", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForMethod", "(", "declaringClass", ",", "selector", ",", "signature", ",", "false", ")", ")", ";", "}", "this", ".", "stackDepth", "+=", "returnTypeSize", "-", "receiverAndArgsSize", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "{", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "}", "}", "public", "void", "invoke", "(", "byte", "opcode", ",", "MethodBinding", "methodBinding", ",", "TypeBinding", "declaringClass", ")", "{", "if", "(", "declaringClass", "==", "null", ")", "declaringClass", "=", "methodBinding", ".", "declaringClass", ";", "if", "(", "(", "declaringClass", ".", "tagBits", "&", "TagBits", ".", "ContainsNestedTypeReferences", ")", "!=", "0", ")", "{", "Util", ".", "recordNestedType", "(", "this", ".", "classFile", ",", "declaringClass", ")", ";", "}", "int", "receiverAndArgsSize", ";", "switch", "(", "opcode", ")", "{", "case", "Opcodes", ".", "OPC_invokestatic", ":", "receiverAndArgsSize", "=", "0", ";", "break", ";", "case", "Opcodes", ".", "OPC_invokeinterface", ":", "case", "Opcodes", ".", "OPC_invokevirtual", ":", "receiverAndArgsSize", "=", "1", ";", "break", ";", "case", "Opcodes", ".", "OPC_invokespecial", ":", "receiverAndArgsSize", "=", "1", ";", "if", "(", "methodBinding", ".", "isConstructor", "(", ")", ")", "{", "if", "(", "declaringClass", ".", "isNestedType", "(", ")", ")", "{", "ReferenceBinding", "nestedType", "=", "(", "ReferenceBinding", ")", "declaringClass", ";", "receiverAndArgsSize", "+=", "nestedType", ".", "getEnclosingInstancesSlotSize", "(", ")", ";", "SyntheticArgumentBinding", "[", "]", "syntheticArguments", "=", "nestedType", ".", "syntheticOuterLocalVariables", "(", ")", ";", "if", "(", "syntheticArguments", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "syntheticArguments", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "switch", "(", "syntheticArguments", "[", "i", "]", ".", "id", ")", "{", "case", "TypeIds", ".", "T_double", ":", "case", "TypeIds", ".", "T_long", ":", "receiverAndArgsSize", "+=", "2", ";", "break", ";", "default", ":", "receiverAndArgsSize", "++", ";", "break", ";", "}", "}", "}", "}", "if", "(", "declaringClass", ".", "isEnum", "(", ")", ")", "{", "receiverAndArgsSize", "+=", "2", ";", "}", "}", "break", ";", "default", ":", "return", ";", "}", "for", "(", "int", "i", "=", "methodBinding", ".", "parameters", ".", "length", "-", "1", ";", "i", ">=", "0", ";", "i", "--", ")", "{", "switch", "(", "methodBinding", ".", "parameters", "[", "i", "]", ".", "id", ")", "{", "case", "TypeIds", ".", "T_double", ":", "case", "TypeIds", ".", "T_long", ":", "receiverAndArgsSize", "+=", "2", ";", "break", ";", "default", ":", "receiverAndArgsSize", "++", ";", "break", ";", "}", "}", "int", "returnTypeSize", ";", "switch", "(", "methodBinding", ".", "returnType", ".", "id", ")", "{", "case", "TypeIds", ".", "T_double", ":", "case", "TypeIds", ".", "T_long", ":", "returnTypeSize", "=", "2", ";", "break", ";", "case", "TypeIds", ".", "T_void", ":", "returnTypeSize", "=", "0", ";", "break", ";", "default", ":", "returnTypeSize", "=", "1", ";", "break", ";", "}", "invoke", "(", "opcode", ",", "receiverAndArgsSize", ",", "returnTypeSize", ",", "declaringClass", ".", "constantPoolName", "(", ")", ",", "methodBinding", ".", "selector", ",", "methodBinding", ".", "signature", "(", "this", ".", "classFile", ")", ")", ";", "}", "protected", "void", "invokeAccessibleObjectSetAccessible", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "2", ",", "0", ",", "ConstantPool", ".", "JAVALANGREFLECTACCESSIBLEOBJECT_CONSTANTPOOLNAME", ",", "ConstantPool", ".", "SETACCESSIBLE_NAME", ",", "ConstantPool", ".", "SETACCESSIBLE_SIGNATURE", ")", ";", "}", "protected", "void", "invokeArrayNewInstance", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokestatic", ",", "2", ",", "1", ",", "ConstantPool", ".", "JAVALANGREFLECTARRAY_CONSTANTPOOLNAME", ",", "ConstantPool", ".", "NewInstance", ",", "ConstantPool", ".", "NewInstanceSignature", ")", ";", "}", "public", "void", "invokeClassForName", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokestatic", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangClassConstantPoolName", ",", "ConstantPool", ".", "ForName", ",", "ConstantPool", ".", "ForNameSignature", ")", ";", "}", "protected", "void", "invokeClassGetDeclaredConstructor", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "2", ",", "1", ",", "ConstantPool", ".", "JavaLangClassConstantPoolName", ",", "ConstantPool", ".", "GETDECLAREDCONSTRUCTOR_NAME", ",", "ConstantPool", ".", "GETDECLAREDCONSTRUCTOR_SIGNATURE", ")", ";", "}", "protected", "void", "invokeClassGetDeclaredField", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "2", ",", "1", ",", "ConstantPool", ".", "JavaLangClassConstantPoolName", ",", "ConstantPool", ".", "GETDECLAREDFIELD_NAME", ",", "ConstantPool", ".", "GETDECLAREDFIELD_SIGNATURE", ")", ";", "}", "protected", "void", "invokeClassGetDeclaredMethod", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "3", ",", "1", ",", "ConstantPool", ".", "JavaLangClassConstantPoolName", ",", "ConstantPool", ".", "GETDECLAREDMETHOD_NAME", ",", "ConstantPool", ".", "GETDECLAREDMETHOD_SIGNATURE", ")", ";", "}", "public", "void", "invokeEnumOrdinal", "(", "char", "[", "]", "enumTypeConstantPoolName", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "enumTypeConstantPoolName", ",", "ConstantPool", ".", "Ordinal", ",", "ConstantPool", ".", "OrdinalSignature", ")", ";", "}", "public", "void", "invokeIterableIterator", "(", "TypeBinding", "iterableReceiverType", ")", "{", "if", "(", "(", "iterableReceiverType", ".", "tagBits", "&", "TagBits", ".", "ContainsNestedTypeReferences", ")", "!=", "0", ")", "{", "Util", ".", "recordNestedType", "(", "this", ".", "classFile", ",", "iterableReceiverType", ")", ";", "}", "invoke", "(", "iterableReceiverType", ".", "isInterface", "(", ")", "?", "Opcodes", ".", "OPC_invokeinterface", ":", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "iterableReceiverType", ".", "constantPoolName", "(", ")", ",", "ConstantPool", ".", "ITERATOR_NAME", ",", "ConstantPool", ".", "ITERATOR_SIGNATURE", ")", ";", "}", "public", "void", "invokeJavaLangAssertionErrorConstructor", "(", "int", "typeBindingID", ")", "{", "int", "receiverAndArgsSize", ";", "char", "[", "]", "signature", ";", "switch", "(", "typeBindingID", ")", "{", "case", "TypeIds", ".", "T_int", ":", "case", "TypeIds", ".", "T_byte", ":", "case", "TypeIds", ".", "T_short", ":", "signature", "=", "ConstantPool", ".", "IntConstrSignature", ";", "receiverAndArgsSize", "=", "2", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "signature", "=", "ConstantPool", ".", "LongConstrSignature", ";", "receiverAndArgsSize", "=", "3", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "signature", "=", "ConstantPool", ".", "FloatConstrSignature", ";", "receiverAndArgsSize", "=", "2", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "signature", "=", "ConstantPool", ".", "DoubleConstrSignature", ";", "receiverAndArgsSize", "=", "3", ";", "break", ";", "case", "TypeIds", ".", "T_char", ":", "signature", "=", "ConstantPool", ".", "CharConstrSignature", ";", "receiverAndArgsSize", "=", "2", ";", "break", ";", "case", "TypeIds", ".", "T_boolean", ":", "signature", "=", "ConstantPool", ".", "BooleanConstrSignature", ";", "receiverAndArgsSize", "=", "2", ";", "break", ";", "case", "TypeIds", ".", "T_JavaLangObject", ":", "case", "TypeIds", ".", "T_JavaLangString", ":", "case", "TypeIds", ".", "T_null", ":", "signature", "=", "ConstantPool", ".", "ObjectConstrSignature", ";", "receiverAndArgsSize", "=", "2", ";", "break", ";", "default", ":", "return", ";", "}", "invoke", "(", "Opcodes", ".", "OPC_invokespecial", ",", "receiverAndArgsSize", ",", "0", ",", "ConstantPool", ".", "JavaLangAssertionErrorConstantPoolName", ",", "ConstantPool", ".", "Init", ",", "signature", ")", ";", "}", "public", "void", "invokeJavaLangAssertionErrorDefaultConstructor", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokespecial", ",", "1", ",", "0", ",", "ConstantPool", ".", "JavaLangAssertionErrorConstantPoolName", ",", "ConstantPool", ".", "Init", ",", "ConstantPool", ".", "DefaultConstructorSignature", ")", ";", "}", "public", "void", "invokeJavaLangClassDesiredAssertionStatus", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangClassConstantPoolName", ",", "ConstantPool", ".", "DesiredAssertionStatus", ",", "ConstantPool", ".", "DesiredAssertionStatusSignature", ")", ";", "}", "public", "void", "invokeJavaLangEnumvalueOf", "(", "ReferenceBinding", "binding", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokestatic", ",", "2", ",", "1", ",", "ConstantPool", ".", "JavaLangEnumConstantPoolName", ",", "ConstantPool", ".", "ValueOf", ",", "ConstantPool", ".", "ValueOfStringClassSignature", ")", ";", "}", "public", "void", "invokeJavaLangEnumValues", "(", "TypeBinding", "enumBinding", ",", "ArrayBinding", "arrayBinding", ")", "{", "char", "[", "]", "signature", "=", "\"()\"", ".", "toCharArray", "(", ")", ";", "signature", "=", "CharOperation", ".", "concat", "(", "signature", ",", "arrayBinding", ".", "constantPoolName", "(", ")", ")", ";", "invoke", "(", "Opcodes", ".", "OPC_invokestatic", ",", "0", ",", "1", ",", "enumBinding", ".", "constantPoolName", "(", ")", ",", "TypeConstants", ".", "VALUES", ",", "signature", ")", ";", "}", "public", "void", "invokeJavaLangErrorConstructor", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokespecial", ",", "2", ",", "0", ",", "ConstantPool", ".", "JavaLangErrorConstantPoolName", ",", "ConstantPool", ".", "Init", ",", "ConstantPool", ".", "StringConstructorSignature", ")", ";", "}", "public", "void", "invokeJavaLangReflectConstructorNewInstance", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "2", ",", "1", ",", "ConstantPool", ".", "JavaLangReflectConstructorConstantPoolName", ",", "ConstantPool", ".", "NewInstance", ",", "ConstantPool", ".", "JavaLangReflectConstructorNewInstanceSignature", ")", ";", "}", "protected", "void", "invokeJavaLangReflectFieldGetter", "(", "int", "typeID", ")", "{", "char", "[", "]", "selector", ";", "char", "[", "]", "signature", ";", "int", "returnTypeSize", ";", "switch", "(", "typeID", ")", "{", "case", "TypeIds", ".", "T_int", ":", "selector", "=", "ConstantPool", ".", "GET_INT_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "GET_INT_METHOD_SIGNATURE", ";", "returnTypeSize", "=", "1", ";", "break", ";", "case", "TypeIds", ".", "T_byte", ":", "selector", "=", "ConstantPool", ".", "GET_BYTE_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "GET_BYTE_METHOD_SIGNATURE", ";", "returnTypeSize", "=", "1", ";", "break", ";", "case", "TypeIds", ".", "T_short", ":", "selector", "=", "ConstantPool", ".", "GET_SHORT_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "GET_SHORT_METHOD_SIGNATURE", ";", "returnTypeSize", "=", "1", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "selector", "=", "ConstantPool", ".", "GET_LONG_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "GET_LONG_METHOD_SIGNATURE", ";", "returnTypeSize", "=", "2", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "selector", "=", "ConstantPool", ".", "GET_FLOAT_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "GET_FLOAT_METHOD_SIGNATURE", ";", "returnTypeSize", "=", "1", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "selector", "=", "ConstantPool", ".", "GET_DOUBLE_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "GET_DOUBLE_METHOD_SIGNATURE", ";", "returnTypeSize", "=", "2", ";", "break", ";", "case", "TypeIds", ".", "T_char", ":", "selector", "=", "ConstantPool", ".", "GET_CHAR_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "GET_CHAR_METHOD_SIGNATURE", ";", "returnTypeSize", "=", "1", ";", "break", ";", "case", "TypeIds", ".", "T_boolean", ":", "selector", "=", "ConstantPool", ".", "GET_BOOLEAN_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "GET_BOOLEAN_METHOD_SIGNATURE", ";", "returnTypeSize", "=", "1", ";", "break", ";", "default", ":", "selector", "=", "ConstantPool", ".", "GET_OBJECT_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "GET_OBJECT_METHOD_SIGNATURE", ";", "returnTypeSize", "=", "1", ";", "break", ";", "}", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "2", ",", "returnTypeSize", ",", "ConstantPool", ".", "JAVALANGREFLECTFIELD_CONSTANTPOOLNAME", ",", "selector", ",", "signature", ")", ";", "}", "protected", "void", "invokeJavaLangReflectFieldSetter", "(", "int", "typeID", ")", "{", "char", "[", "]", "selector", ";", "char", "[", "]", "signature", ";", "int", "receiverAndArgsSize", ";", "switch", "(", "typeID", ")", "{", "case", "TypeIds", ".", "T_int", ":", "selector", "=", "ConstantPool", ".", "SET_INT_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "SET_INT_METHOD_SIGNATURE", ";", "receiverAndArgsSize", "=", "3", ";", "break", ";", "case", "TypeIds", ".", "T_byte", ":", "selector", "=", "ConstantPool", ".", "SET_BYTE_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "SET_BYTE_METHOD_SIGNATURE", ";", "receiverAndArgsSize", "=", "3", ";", "break", ";", "case", "TypeIds", ".", "T_short", ":", "selector", "=", "ConstantPool", ".", "SET_SHORT_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "SET_SHORT_METHOD_SIGNATURE", ";", "receiverAndArgsSize", "=", "3", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "selector", "=", "ConstantPool", ".", "SET_LONG_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "SET_LONG_METHOD_SIGNATURE", ";", "receiverAndArgsSize", "=", "4", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "selector", "=", "ConstantPool", ".", "SET_FLOAT_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "SET_FLOAT_METHOD_SIGNATURE", ";", "receiverAndArgsSize", "=", "3", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "selector", "=", "ConstantPool", ".", "SET_DOUBLE_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "SET_DOUBLE_METHOD_SIGNATURE", ";", "receiverAndArgsSize", "=", "4", ";", "break", ";", "case", "TypeIds", ".", "T_char", ":", "selector", "=", "ConstantPool", ".", "SET_CHAR_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "SET_CHAR_METHOD_SIGNATURE", ";", "receiverAndArgsSize", "=", "3", ";", "break", ";", "case", "TypeIds", ".", "T_boolean", ":", "selector", "=", "ConstantPool", ".", "SET_BOOLEAN_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "SET_BOOLEAN_METHOD_SIGNATURE", ";", "receiverAndArgsSize", "=", "3", ";", "break", ";", "default", ":", "selector", "=", "ConstantPool", ".", "SET_OBJECT_METHOD_NAME", ";", "signature", "=", "ConstantPool", ".", "SET_OBJECT_METHOD_SIGNATURE", ";", "receiverAndArgsSize", "=", "3", ";", "break", ";", "}", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "receiverAndArgsSize", ",", "0", ",", "ConstantPool", ".", "JAVALANGREFLECTFIELD_CONSTANTPOOLNAME", ",", "selector", ",", "signature", ")", ";", "}", "public", "void", "invokeJavaLangReflectMethodInvoke", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "3", ",", "1", ",", "ConstantPool", ".", "JAVALANGREFLECTMETHOD_CONSTANTPOOLNAME", ",", "ConstantPool", ".", "INVOKE_METHOD_METHOD_NAME", ",", "ConstantPool", ".", "INVOKE_METHOD_METHOD_SIGNATURE", ")", ";", "}", "public", "void", "invokeJavaUtilIteratorHasNext", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokeinterface", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaUtilIteratorConstantPoolName", ",", "ConstantPool", ".", "HasNext", ",", "ConstantPool", ".", "HasNextSignature", ")", ";", "}", "public", "void", "invokeJavaUtilIteratorNext", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokeinterface", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaUtilIteratorConstantPoolName", ",", "ConstantPool", ".", "Next", ",", "ConstantPool", ".", "NextSignature", ")", ";", "}", "public", "void", "invokeNoClassDefFoundErrorStringConstructor", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokespecial", ",", "2", ",", "0", ",", "ConstantPool", ".", "JavaLangNoClassDefFoundErrorConstantPoolName", ",", "ConstantPool", ".", "Init", ",", "ConstantPool", ".", "StringConstructorSignature", ")", ";", "}", "public", "void", "invokeObjectGetClass", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangObjectConstantPoolName", ",", "ConstantPool", ".", "GetClass", ",", "ConstantPool", ".", "GetClassSignature", ")", ";", "}", "public", "void", "invokeStringConcatenationAppendForType", "(", "int", "typeID", ")", "{", "int", "receiverAndArgsSize", ";", "char", "[", "]", "declaringClass", "=", "null", ";", "char", "[", "]", "selector", "=", "ConstantPool", ".", "Append", ";", "char", "[", "]", "signature", "=", "null", ";", "switch", "(", "typeID", ")", "{", "case", "TypeIds", ".", "T_int", ":", "case", "TypeIds", ".", "T_byte", ":", "case", "TypeIds", ".", "T_short", ":", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBuilderConstantPoolName", ";", "signature", "=", "ConstantPool", ".", "StringBuilderAppendIntSignature", ";", "}", "else", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBufferConstantPoolName", ";", "signature", "=", "ConstantPool", ".", "StringBufferAppendIntSignature", ";", "}", "receiverAndArgsSize", "=", "2", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBuilderConstantPoolName", ";", "signature", "=", "ConstantPool", ".", "StringBuilderAppendLongSignature", ";", "}", "else", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBufferConstantPoolName", ";", "signature", "=", "ConstantPool", ".", "StringBufferAppendLongSignature", ";", "}", "receiverAndArgsSize", "=", "3", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBuilderConstantPoolName", ";", "signature", "=", "ConstantPool", ".", "StringBuilderAppendFloatSignature", ";", "}", "else", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBufferConstantPoolName", ";", "signature", "=", "ConstantPool", ".", "StringBufferAppendFloatSignature", ";", "}", "receiverAndArgsSize", "=", "2", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBuilderConstantPoolName", ";", "signature", "=", "ConstantPool", ".", "StringBuilderAppendDoubleSignature", ";", "}", "else", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBufferConstantPoolName", ";", "signature", "=", "ConstantPool", ".", "StringBufferAppendDoubleSignature", ";", "}", "receiverAndArgsSize", "=", "3", ";", "break", ";", "case", "TypeIds", ".", "T_char", ":", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBuilderConstantPoolName", ";", "signature", "=", "ConstantPool", ".", "StringBuilderAppendCharSignature", ";", "}", "else", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBufferConstantPoolName", ";", "signature", "=", "ConstantPool", ".", "StringBufferAppendCharSignature", ";", "}", "receiverAndArgsSize", "=", "2", ";", "break", ";", "case", "TypeIds", ".", "T_boolean", ":", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBuilderConstantPoolName", ";", "signature", "=", "ConstantPool", ".", "StringBuilderAppendBooleanSignature", ";", "}", "else", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBufferConstantPoolName", ";", "signature", "=", "ConstantPool", ".", "StringBufferAppendBooleanSignature", ";", "}", "receiverAndArgsSize", "=", "2", ";", "break", ";", "case", "TypeIds", ".", "T_JavaLangString", ":", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBuilderConstantPoolName", ";", "signature", "=", "ConstantPool", ".", "StringBuilderAppendStringSignature", ";", "}", "else", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBufferConstantPoolName", ";", "signature", "=", "ConstantPool", ".", "StringBufferAppendStringSignature", ";", "}", "receiverAndArgsSize", "=", "2", ";", "break", ";", "default", ":", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBuilderConstantPoolName", ";", "signature", "=", "ConstantPool", ".", "StringBuilderAppendObjectSignature", ";", "}", "else", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBufferConstantPoolName", ";", "signature", "=", "ConstantPool", ".", "StringBufferAppendObjectSignature", ";", "}", "receiverAndArgsSize", "=", "2", ";", "break", ";", "}", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "receiverAndArgsSize", ",", "1", ",", "declaringClass", ",", "selector", ",", "signature", ")", ";", "}", "public", "void", "invokeStringConcatenationDefaultConstructor", "(", ")", "{", "char", "[", "]", "declaringClass", ";", "if", "(", "this", ".", "targetLevel", "<", "ClassFileConstants", ".", "JDK1_5", ")", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBufferConstantPoolName", ";", "}", "else", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBuilderConstantPoolName", ";", "}", "invoke", "(", "Opcodes", ".", "OPC_invokespecial", ",", "1", ",", "0", ",", "declaringClass", ",", "ConstantPool", ".", "Init", ",", "ConstantPool", ".", "DefaultConstructorSignature", ")", ";", "}", "public", "void", "invokeStringConcatenationStringConstructor", "(", ")", "{", "char", "[", "]", "declaringClass", ";", "if", "(", "this", ".", "targetLevel", "<", "ClassFileConstants", ".", "JDK1_5", ")", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBufferConstantPoolName", ";", "}", "else", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBuilderConstantPoolName", ";", "}", "invoke", "(", "Opcodes", ".", "OPC_invokespecial", ",", "2", ",", "0", ",", "declaringClass", ",", "ConstantPool", ".", "Init", ",", "ConstantPool", ".", "StringConstructorSignature", ")", ";", "}", "public", "void", "invokeStringConcatenationToString", "(", ")", "{", "char", "[", "]", "declaringClass", ";", "if", "(", "this", ".", "targetLevel", "<", "ClassFileConstants", ".", "JDK1_5", ")", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBufferConstantPoolName", ";", "}", "else", "{", "declaringClass", "=", "ConstantPool", ".", "JavaLangStringBuilderConstantPoolName", ";", "}", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "declaringClass", ",", "ConstantPool", ".", "ToString", ",", "ConstantPool", ".", "ToStringSignature", ")", ";", "}", "public", "void", "invokeStringIntern", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangStringConstantPoolName", ",", "ConstantPool", ".", "Intern", ",", "ConstantPool", ".", "InternSignature", ")", ";", "}", "public", "void", "invokeStringValueOf", "(", "int", "typeID", ")", "{", "char", "[", "]", "signature", ";", "int", "receiverAndArgsSize", ";", "switch", "(", "typeID", ")", "{", "case", "TypeIds", ".", "T_int", ":", "case", "TypeIds", ".", "T_byte", ":", "case", "TypeIds", ".", "T_short", ":", "signature", "=", "ConstantPool", ".", "ValueOfIntSignature", ";", "receiverAndArgsSize", "=", "1", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "signature", "=", "ConstantPool", ".", "ValueOfLongSignature", ";", "receiverAndArgsSize", "=", "2", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "signature", "=", "ConstantPool", ".", "ValueOfFloatSignature", ";", "receiverAndArgsSize", "=", "1", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "signature", "=", "ConstantPool", ".", "ValueOfDoubleSignature", ";", "receiverAndArgsSize", "=", "2", ";", "break", ";", "case", "TypeIds", ".", "T_char", ":", "signature", "=", "ConstantPool", ".", "ValueOfCharSignature", ";", "receiverAndArgsSize", "=", "1", ";", "break", ";", "case", "TypeIds", ".", "T_boolean", ":", "signature", "=", "ConstantPool", ".", "ValueOfBooleanSignature", ";", "receiverAndArgsSize", "=", "1", ";", "break", ";", "case", "TypeIds", ".", "T_JavaLangObject", ":", "case", "TypeIds", ".", "T_JavaLangString", ":", "case", "TypeIds", ".", "T_null", ":", "case", "TypeIds", ".", "T_undefined", ":", "signature", "=", "ConstantPool", ".", "ValueOfObjectSignature", ";", "receiverAndArgsSize", "=", "1", ";", "break", ";", "default", ":", "return", ";", "}", "invoke", "(", "Opcodes", ".", "OPC_invokestatic", ",", "receiverAndArgsSize", ",", "1", ",", "ConstantPool", ".", "JavaLangStringConstantPoolName", ",", "ConstantPool", ".", "ValueOf", ",", "signature", ")", ";", "}", "public", "void", "invokeSystemArraycopy", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokestatic", ",", "5", ",", "0", ",", "ConstantPool", ".", "JavaLangSystemConstantPoolName", ",", "ConstantPool", ".", "ArrayCopy", ",", "ConstantPool", ".", "ArrayCopySignature", ")", ";", "}", "public", "void", "invokeThrowableGetMessage", "(", ")", "{", "invoke", "(", "Opcodes", ".", "OPC_invokevirtual", ",", "1", ",", "1", ",", "ConstantPool", ".", "JavaLangThrowableConstantPoolName", ",", "ConstantPool", ".", "GetMessage", ",", "ConstantPool", ".", "GetMessageSignature", ")", ";", "}", "public", "void", "ior", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ior", ";", "}", "public", "void", "irem", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_irem", ";", "}", "public", "void", "ireturn", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ireturn", ";", "this", ".", "lastAbruptCompletion", "=", "this", ".", "position", ";", "}", "public", "boolean", "isDefinitelyAssigned", "(", "Scope", "scope", ",", "int", "initStateIndex", ",", "LocalVariableBinding", "local", ")", "{", "if", "(", "(", "local", ".", "tagBits", "&", "TagBits", ".", "IsArgument", ")", "!=", "0", ")", "{", "return", "true", ";", "}", "if", "(", "initStateIndex", "==", "-", "1", ")", "return", "false", ";", "int", "localPosition", "=", "local", ".", "id", "+", "this", ".", "maxFieldCount", ";", "MethodScope", "methodScope", "=", "scope", ".", "methodScope", "(", ")", ";", "if", "(", "localPosition", "<", "UnconditionalFlowInfo", ".", "BitCacheSize", ")", "{", "return", "(", "methodScope", ".", "definiteInits", "[", "initStateIndex", "]", "&", "(", "1L", "<<", "localPosition", ")", ")", "!=", "0", ";", "}", "long", "[", "]", "extraInits", "=", "methodScope", ".", "extraDefiniteInits", "[", "initStateIndex", "]", ";", "if", "(", "extraInits", "==", "null", ")", "return", "false", ";", "int", "vectorIndex", ";", "if", "(", "(", "vectorIndex", "=", "(", "localPosition", "/", "UnconditionalFlowInfo", ".", "BitCacheSize", ")", "-", "1", ")", ">=", "extraInits", ".", "length", ")", "return", "false", ";", "return", "(", "(", "extraInits", "[", "vectorIndex", "]", ")", "&", "(", "1L", "<<", "(", "localPosition", "%", "UnconditionalFlowInfo", ".", "BitCacheSize", ")", ")", ")", "!=", "0", ";", "}", "public", "void", "ishl", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ishl", ";", "}", "public", "void", "ishr", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ishr", ";", "}", "public", "void", "istore", "(", "int", "iArg", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "maxLocals", "<=", "iArg", ")", "{", "this", ".", "maxLocals", "=", "iArg", "+", "1", ";", "}", "if", "(", "iArg", ">", "255", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "3", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_wide", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_istore", ";", "writeUnsignedShort", "(", "iArg", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_istore", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "iArg", ";", "}", "}", "public", "void", "istore_0", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "maxLocals", "==", "0", ")", "{", "this", ".", "maxLocals", "=", "1", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_istore_0", ";", "}", "public", "void", "istore_1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "maxLocals", "<=", "1", ")", "{", "this", ".", "maxLocals", "=", "2", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_istore_1", ";", "}", "public", "void", "istore_2", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "maxLocals", "<=", "2", ")", "{", "this", ".", "maxLocals", "=", "3", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_istore_2", ";", "}", "public", "void", "istore_3", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "maxLocals", "<=", "3", ")", "{", "this", ".", "maxLocals", "=", "4", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_istore_3", ";", "}", "public", "void", "isub", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_isub", ";", "}", "public", "void", "iushr", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_iushr", ";", "}", "public", "void", "ixor", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ixor", ";", "}", "final", "public", "void", "jsr", "(", "BranchLabel", "lbl", ")", "{", "if", "(", "this", ".", "wideMode", ")", "{", "jsr_w", "(", "lbl", ")", ";", "return", ";", "}", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_jsr", ";", "lbl", ".", "branch", "(", ")", ";", "}", "final", "public", "void", "jsr_w", "(", "BranchLabel", "lbl", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_jsr_w", ";", "lbl", ".", "branchWide", "(", ")", ";", "}", "public", "void", "l2d", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_l2d", ";", "}", "public", "void", "l2f", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_l2f", ";", "}", "public", "void", "l2i", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_l2i", ";", "}", "public", "void", "ladd", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ladd", ";", "}", "public", "void", "laload", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_laload", ";", "}", "public", "void", "land", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_land", ";", "}", "public", "void", "lastore", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "4", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lastore", ";", "}", "public", "void", "lcmp", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "3", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lcmp", ";", "}", "public", "void", "lconst_0", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lconst_0", ";", "}", "public", "void", "lconst_1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lconst_1", ";", "}", "public", "void", "ldc", "(", "float", "constant", ")", "{", "this", ".", "countLabels", "=", "0", ";", "int", "index", "=", "this", ".", "constantPool", ".", "literalIndex", "(", "constant", ")", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "index", ">", "255", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ldc_w", ";", "writeUnsignedShort", "(", "index", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ldc", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "index", ";", "}", "}", "public", "void", "ldc", "(", "int", "constant", ")", "{", "this", ".", "countLabels", "=", "0", ";", "int", "index", "=", "this", ".", "constantPool", ".", "literalIndex", "(", "constant", ")", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "index", ">", "255", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ldc_w", ";", "writeUnsignedShort", "(", "index", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ldc", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "index", ";", "}", "}", "public", "void", "ldc", "(", "String", "constant", ")", "{", "this", ".", "countLabels", "=", "0", ";", "int", "currentCodeStreamPosition", "=", "this", ".", "position", ";", "char", "[", "]", "constantChars", "=", "constant", ".", "toCharArray", "(", ")", ";", "int", "index", "=", "this", ".", "constantPool", ".", "literalIndexForLdc", "(", "constantChars", ")", ";", "if", "(", "index", ">", "0", ")", "{", "ldcForIndex", "(", "index", ")", ";", "}", "else", "{", "this", ".", "position", "=", "currentCodeStreamPosition", ";", "int", "i", "=", "0", ";", "int", "length", "=", "0", ";", "int", "constantLength", "=", "constant", ".", "length", "(", ")", ";", "byte", "[", "]", "utf8encoding", "=", "new", "byte", "[", "Math", ".", "min", "(", "constantLength", "+", "100", ",", "65535", ")", "]", ";", "int", "utf8encodingLength", "=", "0", ";", "while", "(", "(", "length", "<", "65532", ")", "&&", "(", "i", "<", "constantLength", ")", ")", "{", "char", "current", "=", "constantChars", "[", "i", "]", ";", "if", "(", "length", "+", "3", ">", "(", "utf8encodingLength", "=", "utf8encoding", ".", "length", ")", ")", "{", "System", ".", "arraycopy", "(", "utf8encoding", ",", "0", ",", "utf8encoding", "=", "new", "byte", "[", "Math", ".", "min", "(", "utf8encodingLength", "+", "100", ",", "65535", ")", "]", ",", "0", ",", "length", ")", ";", "}", "if", "(", "(", "current", ">=", "0x0001", ")", "&&", "(", "current", "<=", "0x007F", ")", ")", "{", "utf8encoding", "[", "length", "++", "]", "=", "(", "byte", ")", "current", ";", "}", "else", "{", "if", "(", "current", ">", "0x07FF", ")", "{", "utf8encoding", "[", "length", "++", "]", "=", "(", "byte", ")", "(", "0xE0", "|", "(", "(", "current", ">>", "12", ")", "&", "0x0F", ")", ")", ";", "utf8encoding", "[", "length", "++", "]", "=", "(", "byte", ")", "(", "0x80", "|", "(", "(", "current", ">>", "6", ")", "&", "0x3F", ")", ")", ";", "utf8encoding", "[", "length", "++", "]", "=", "(", "byte", ")", "(", "0x80", "|", "(", "current", "&", "0x3F", ")", ")", ";", "}", "else", "{", "utf8encoding", "[", "length", "++", "]", "=", "(", "byte", ")", "(", "0xC0", "|", "(", "(", "current", ">>", "6", ")", "&", "0x1F", ")", ")", ";", "utf8encoding", "[", "length", "++", "]", "=", "(", "byte", ")", "(", "0x80", "|", "(", "current", "&", "0x3F", ")", ")", ";", "}", "}", "i", "++", ";", "}", "newStringContatenation", "(", ")", ";", "dup", "(", ")", ";", "char", "[", "]", "subChars", "=", "new", "char", "[", "i", "]", ";", "System", ".", "arraycopy", "(", "constantChars", ",", "0", ",", "subChars", ",", "0", ",", "i", ")", ";", "System", ".", "arraycopy", "(", "utf8encoding", ",", "0", ",", "utf8encoding", "=", "new", "byte", "[", "length", "]", ",", "0", ",", "length", ")", ";", "index", "=", "this", ".", "constantPool", ".", "literalIndex", "(", "subChars", ",", "utf8encoding", ")", ";", "ldcForIndex", "(", "index", ")", ";", "invokeStringConcatenationStringConstructor", "(", ")", ";", "while", "(", "i", "<", "constantLength", ")", "{", "length", "=", "0", ";", "utf8encoding", "=", "new", "byte", "[", "Math", ".", "min", "(", "constantLength", "-", "i", "+", "100", ",", "65535", ")", "]", ";", "int", "startIndex", "=", "i", ";", "while", "(", "(", "length", "<", "65532", ")", "&&", "(", "i", "<", "constantLength", ")", ")", "{", "char", "current", "=", "constantChars", "[", "i", "]", ";", "if", "(", "length", "+", "3", ">", "(", "utf8encodingLength", "=", "utf8encoding", ".", "length", ")", ")", "{", "System", ".", "arraycopy", "(", "utf8encoding", ",", "0", ",", "utf8encoding", "=", "new", "byte", "[", "Math", ".", "min", "(", "utf8encodingLength", "+", "100", ",", "65535", ")", "]", ",", "0", ",", "length", ")", ";", "}", "if", "(", "(", "current", ">=", "0x0001", ")", "&&", "(", "current", "<=", "0x007F", ")", ")", "{", "utf8encoding", "[", "length", "++", "]", "=", "(", "byte", ")", "current", ";", "}", "else", "{", "if", "(", "current", ">", "0x07FF", ")", "{", "utf8encoding", "[", "length", "++", "]", "=", "(", "byte", ")", "(", "0xE0", "|", "(", "(", "current", ">>", "12", ")", "&", "0x0F", ")", ")", ";", "utf8encoding", "[", "length", "++", "]", "=", "(", "byte", ")", "(", "0x80", "|", "(", "(", "current", ">>", "6", ")", "&", "0x3F", ")", ")", ";", "utf8encoding", "[", "length", "++", "]", "=", "(", "byte", ")", "(", "0x80", "|", "(", "current", "&", "0x3F", ")", ")", ";", "}", "else", "{", "utf8encoding", "[", "length", "++", "]", "=", "(", "byte", ")", "(", "0xC0", "|", "(", "(", "current", ">>", "6", ")", "&", "0x1F", ")", ")", ";", "utf8encoding", "[", "length", "++", "]", "=", "(", "byte", ")", "(", "0x80", "|", "(", "current", "&", "0x3F", ")", ")", ";", "}", "}", "i", "++", ";", "}", "int", "newCharLength", "=", "i", "-", "startIndex", ";", "subChars", "=", "new", "char", "[", "newCharLength", "]", ";", "System", ".", "arraycopy", "(", "constantChars", ",", "startIndex", ",", "subChars", ",", "0", ",", "newCharLength", ")", ";", "System", ".", "arraycopy", "(", "utf8encoding", ",", "0", ",", "utf8encoding", "=", "new", "byte", "[", "length", "]", ",", "0", ",", "length", ")", ";", "index", "=", "this", ".", "constantPool", ".", "literalIndex", "(", "subChars", ",", "utf8encoding", ")", ";", "ldcForIndex", "(", "index", ")", ";", "invokeStringConcatenationAppendForType", "(", "TypeIds", ".", "T_JavaLangString", ")", ";", "}", "invokeStringConcatenationToString", "(", ")", ";", "invokeStringIntern", "(", ")", ";", "}", "}", "public", "void", "ldc", "(", "TypeBinding", "typeBinding", ")", "{", "this", ".", "countLabels", "=", "0", ";", "int", "index", "=", "this", ".", "constantPool", ".", "literalIndexForType", "(", "typeBinding", ")", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "index", ">", "255", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ldc_w", ";", "writeUnsignedShort", "(", "index", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ldc", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "index", ";", "}", "}", "public", "void", "ldc2_w", "(", "double", "constant", ")", "{", "this", ".", "countLabels", "=", "0", ";", "int", "index", "=", "this", ".", "constantPool", ".", "literalIndex", "(", "constant", ")", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ldc2_w", ";", "writeUnsignedShort", "(", "index", ")", ";", "}", "public", "void", "ldc2_w", "(", "long", "constant", ")", "{", "this", ".", "countLabels", "=", "0", ";", "int", "index", "=", "this", ".", "constantPool", ".", "literalIndex", "(", "constant", ")", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ldc2_w", ";", "writeUnsignedShort", "(", "index", ")", ";", "}", "public", "void", "ldcForIndex", "(", "int", "index", ")", "{", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "{", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "}", "if", "(", "index", ">", "255", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ldc_w", ";", "writeUnsignedShort", "(", "index", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ldc", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "index", ";", "}", "}", "public", "void", "ldiv", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ldiv", ";", "}", "public", "void", "lload", "(", "int", "iArg", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "maxLocals", "<=", "iArg", "+", "1", ")", "{", "this", ".", "maxLocals", "=", "iArg", "+", "2", ";", "}", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "iArg", ">", "255", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "3", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_wide", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lload", ";", "writeUnsignedShort", "(", "iArg", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lload", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "iArg", ";", "}", "}", "public", "void", "lload_0", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "maxLocals", "<", "2", ")", "{", "this", ".", "maxLocals", "=", "2", ";", "}", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lload_0", ";", "}", "public", "void", "lload_1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "maxLocals", "<", "3", ")", "{", "this", ".", "maxLocals", "=", "3", ";", "}", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lload_1", ";", "}", "public", "void", "lload_2", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "maxLocals", "<", "4", ")", "{", "this", ".", "maxLocals", "=", "4", ";", "}", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lload_2", ";", "}", "public", "void", "lload_3", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "2", ";", "if", "(", "this", ".", "maxLocals", "<", "5", ")", "{", "this", ".", "maxLocals", "=", "5", ";", "}", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lload_3", ";", "}", "public", "void", "lmul", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lmul", ";", "}", "public", "void", "lneg", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lneg", ";", "}", "public", "final", "void", "load", "(", "LocalVariableBinding", "localBinding", ")", "{", "load", "(", "localBinding", ".", "type", ",", "localBinding", ".", "resolvedPosition", ")", ";", "}", "protected", "final", "void", "load", "(", "TypeBinding", "typeBinding", ",", "int", "resolvedPosition", ")", "{", "this", ".", "countLabels", "=", "0", ";", "switch", "(", "typeBinding", ".", "id", ")", "{", "case", "TypeIds", ".", "T_int", ":", "case", "TypeIds", ".", "T_byte", ":", "case", "TypeIds", ".", "T_char", ":", "case", "TypeIds", ".", "T_boolean", ":", "case", "TypeIds", ".", "T_short", ":", "switch", "(", "resolvedPosition", ")", "{", "case", "0", ":", "iload_0", "(", ")", ";", "break", ";", "case", "1", ":", "iload_1", "(", ")", ";", "break", ";", "case", "2", ":", "iload_2", "(", ")", ";", "break", ";", "case", "3", ":", "iload_3", "(", ")", ";", "break", ";", "default", ":", "iload", "(", "resolvedPosition", ")", ";", "}", "break", ";", "case", "TypeIds", ".", "T_float", ":", "switch", "(", "resolvedPosition", ")", "{", "case", "0", ":", "fload_0", "(", ")", ";", "break", ";", "case", "1", ":", "fload_1", "(", ")", ";", "break", ";", "case", "2", ":", "fload_2", "(", ")", ";", "break", ";", "case", "3", ":", "fload_3", "(", ")", ";", "break", ";", "default", ":", "fload", "(", "resolvedPosition", ")", ";", "}", "break", ";", "case", "TypeIds", ".", "T_long", ":", "switch", "(", "resolvedPosition", ")", "{", "case", "0", ":", "lload_0", "(", ")", ";", "break", ";", "case", "1", ":", "lload_1", "(", ")", ";", "break", ";", "case", "2", ":", "lload_2", "(", ")", ";", "break", ";", "case", "3", ":", "lload_3", "(", ")", ";", "break", ";", "default", ":", "lload", "(", "resolvedPosition", ")", ";", "}", "break", ";", "case", "TypeIds", ".", "T_double", ":", "switch", "(", "resolvedPosition", ")", "{", "case", "0", ":", "dload_0", "(", ")", ";", "break", ";", "case", "1", ":", "dload_1", "(", ")", ";", "break", ";", "case", "2", ":", "dload_2", "(", ")", ";", "break", ";", "case", "3", ":", "dload_3", "(", ")", ";", "break", ";", "default", ":", "dload", "(", "resolvedPosition", ")", ";", "}", "break", ";", "default", ":", "switch", "(", "resolvedPosition", ")", "{", "case", "0", ":", "aload_0", "(", ")", ";", "break", ";", "case", "1", ":", "aload_1", "(", ")", ";", "break", ";", "case", "2", ":", "aload_2", "(", ")", ";", "break", ";", "case", "3", ":", "aload_3", "(", ")", ";", "break", ";", "default", ":", "aload", "(", "resolvedPosition", ")", ";", "}", "}", "}", "public", "void", "lookupswitch", "(", "CaseLabel", "defaultLabel", ",", "int", "[", "]", "keys", ",", "int", "[", "]", "sortedIndexes", ",", "CaseLabel", "[", "]", "casesLabel", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "int", "length", "=", "keys", ".", "length", ";", "int", "pos", "=", "this", ".", "position", ";", "defaultLabel", ".", "placeInstruction", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "casesLabel", "[", "i", "]", ".", "placeInstruction", "(", ")", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lookupswitch", ";", "for", "(", "int", "i", "=", "(", "3", "-", "(", "pos", "&", "3", ")", ")", ";", "i", ">", "0", ";", "i", "--", ")", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "0", ";", "}", "defaultLabel", ".", "branch", "(", ")", ";", "writeSignedWord", "(", "length", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "writeSignedWord", "(", "keys", "[", "sortedIndexes", "[", "i", "]", "]", ")", ";", "casesLabel", "[", "sortedIndexes", "[", "i", "]", "]", ".", "branch", "(", ")", ";", "}", "}", "public", "void", "lor", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lor", ";", "}", "public", "void", "lrem", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lrem", ";", "}", "public", "void", "lreturn", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lreturn", ";", "this", ".", "lastAbruptCompletion", "=", "this", ".", "position", ";", "}", "public", "void", "lshl", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lshl", ";", "}", "public", "void", "lshr", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lshr", ";", "}", "public", "void", "lstore", "(", "int", "iArg", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "maxLocals", "<=", "iArg", "+", "1", ")", "{", "this", ".", "maxLocals", "=", "iArg", "+", "2", ";", "}", "if", "(", "iArg", ">", "255", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "3", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_wide", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lstore", ";", "writeUnsignedShort", "(", "iArg", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lstore", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "iArg", ";", "}", "}", "public", "void", "lstore_0", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "maxLocals", "<", "2", ")", "{", "this", ".", "maxLocals", "=", "2", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lstore_0", ";", "}", "public", "void", "lstore_1", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "maxLocals", "<", "3", ")", "{", "this", ".", "maxLocals", "=", "3", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lstore_1", ";", "}", "public", "void", "lstore_2", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "maxLocals", "<", "4", ")", "{", "this", ".", "maxLocals", "=", "4", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lstore_2", ";", "}", "public", "void", "lstore_3", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "maxLocals", "<", "5", ")", "{", "this", ".", "maxLocals", "=", "5", ";", "}", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lstore_3", ";", "}", "public", "void", "lsub", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lsub", ";", "}", "public", "void", "lushr", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lushr", ";", "}", "public", "void", "lxor", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_lxor", ";", "}", "public", "void", "monitorenter", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_monitorenter", ";", "}", "public", "void", "monitorexit", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_monitorexit", ";", "}", "public", "void", "multianewarray", "(", "TypeBinding", "typeBinding", ",", "int", "dimensions", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "+=", "(", "1", "-", "dimensions", ")", ";", "if", "(", "this", ".", "classFileOffset", "+", "3", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_multianewarray", ";", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "typeBinding", ")", ")", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "dimensions", ";", "}", "public", "void", "new_", "(", "TypeBinding", "typeBinding", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_new", ";", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "typeBinding", ")", ")", ";", "}", "public", "void", "newarray", "(", "int", "array_Type", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_newarray", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "array_Type", ";", "}", "public", "void", "newArray", "(", "ArrayBinding", "arrayBinding", ")", "{", "TypeBinding", "component", "=", "arrayBinding", ".", "elementsType", "(", ")", ";", "switch", "(", "component", ".", "id", ")", "{", "case", "TypeIds", ".", "T_int", ":", "newarray", "(", "ClassFileConstants", ".", "INT_ARRAY", ")", ";", "break", ";", "case", "TypeIds", ".", "T_byte", ":", "newarray", "(", "ClassFileConstants", ".", "BYTE_ARRAY", ")", ";", "break", ";", "case", "TypeIds", ".", "T_boolean", ":", "newarray", "(", "ClassFileConstants", ".", "BOOLEAN_ARRAY", ")", ";", "break", ";", "case", "TypeIds", ".", "T_short", ":", "newarray", "(", "ClassFileConstants", ".", "SHORT_ARRAY", ")", ";", "break", ";", "case", "TypeIds", ".", "T_char", ":", "newarray", "(", "ClassFileConstants", ".", "CHAR_ARRAY", ")", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "newarray", "(", "ClassFileConstants", ".", "LONG_ARRAY", ")", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "newarray", "(", "ClassFileConstants", ".", "FLOAT_ARRAY", ")", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "newarray", "(", "ClassFileConstants", ".", "DOUBLE_ARRAY", ")", ";", "break", ";", "default", ":", "anewarray", "(", "component", ")", ";", "}", "}", "public", "void", "newJavaLangAssertionError", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_new", ";", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangAssertionErrorConstantPoolName", ")", ")", ";", "}", "public", "void", "newJavaLangError", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_new", ";", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangErrorConstantPoolName", ")", ")", ";", "}", "public", "void", "newNoClassDefFoundError", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_new", ";", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangNoClassDefFoundErrorConstantPoolName", ")", ")", ";", "}", "public", "void", "newStringContatenation", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "{", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "}", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_new", ";", "if", "(", "this", ".", "targetLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangStringBuilderConstantPoolName", ")", ")", ";", "}", "else", "{", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangStringBufferConstantPoolName", ")", ")", ";", "}", "}", "public", "void", "newWrapperFor", "(", "int", "typeID", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", "+", "2", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_new", ";", "switch", "(", "typeID", ")", "{", "case", "TypeIds", ".", "T_int", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangIntegerConstantPoolName", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_boolean", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangBooleanConstantPoolName", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_byte", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangByteConstantPoolName", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_char", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangCharacterConstantPoolName", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_float", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangFloatConstantPoolName", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_double", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangDoubleConstantPoolName", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_short", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangShortConstantPoolName", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_long", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangLongConstantPoolName", ")", ")", ";", "break", ";", "case", "TypeIds", ".", "T_void", ":", "writeUnsignedShort", "(", "this", ".", "constantPool", ".", "literalIndexForType", "(", "ConstantPool", ".", "JavaLangVoidConstantPoolName", ")", ")", ";", "}", "}", "public", "void", "nop", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_nop", ";", "}", "public", "void", "optimizeBranch", "(", "int", "oldPosition", ",", "BranchLabel", "lbl", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "countLabels", ";", "i", "++", ")", "{", "BranchLabel", "label", "=", "this", ".", "labels", "[", "i", "]", ";", "if", "(", "oldPosition", "==", "label", ".", "position", ")", "{", "label", ".", "position", "=", "this", ".", "position", ";", "if", "(", "label", "instanceof", "CaseLabel", ")", "{", "int", "offset", "=", "this", ".", "position", "-", "(", "(", "CaseLabel", ")", "label", ")", ".", "instructionPosition", ";", "int", "[", "]", "forwardRefs", "=", "label", ".", "forwardReferences", "(", ")", ";", "for", "(", "int", "j", "=", "0", ",", "length", "=", "label", ".", "forwardReferenceCount", "(", ")", ";", "j", "<", "length", ";", "j", "++", ")", "{", "int", "forwardRef", "=", "forwardRefs", "[", "j", "]", ";", "this", ".", "writeSignedWord", "(", "forwardRef", ",", "offset", ")", ";", "}", "}", "else", "{", "int", "[", "]", "forwardRefs", "=", "label", ".", "forwardReferences", "(", ")", ";", "for", "(", "int", "j", "=", "0", ",", "length", "=", "label", ".", "forwardReferenceCount", "(", ")", ";", "j", "<", "length", ";", "j", "++", ")", "{", "final", "int", "forwardRef", "=", "forwardRefs", "[", "j", "]", ";", "this", ".", "writePosition", "(", "lbl", ",", "forwardRef", ")", ";", "}", "}", "}", "}", "}", "public", "void", "pop", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_pop", ";", "}", "public", "void", "pop2", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "2", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_pop2", ";", "}", "public", "void", "pushExceptionOnStack", "(", "TypeBinding", "binding", ")", "{", "this", ".", "stackDepth", "=", "1", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "}", "public", "void", "pushOnStack", "(", "TypeBinding", "binding", ")", "{", "if", "(", "++", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "}", "public", "void", "record", "(", "LocalVariableBinding", "local", ")", "{", "if", "(", "(", "this", ".", "generateAttributes", "&", "(", "ClassFileConstants", ".", "ATTR_VARS", "|", "ClassFileConstants", ".", "ATTR_STACK_MAP_TABLE", "|", "ClassFileConstants", ".", "ATTR_STACK_MAP", ")", ")", "==", "0", ")", "return", ";", "if", "(", "this", ".", "allLocalsCounter", "==", "this", ".", "locals", ".", "length", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "locals", ",", "0", ",", "this", ".", "locals", "=", "new", "LocalVariableBinding", "[", "this", ".", "allLocalsCounter", "+", "LOCALS_INCREMENT", "]", ",", "0", ",", "this", ".", "allLocalsCounter", ")", ";", "}", "this", ".", "locals", "[", "this", ".", "allLocalsCounter", "++", "]", "=", "local", ";", "local", ".", "initializationPCs", "=", "new", "int", "[", "4", "]", ";", "local", ".", "initializationCount", "=", "0", ";", "}", "public", "void", "recordExpressionType", "(", "TypeBinding", "typeBinding", ")", "{", "}", "public", "void", "recordPositionsFrom", "(", "int", "startPC", ",", "int", "sourcePos", ")", "{", "this", ".", "recordPositionsFrom", "(", "startPC", ",", "sourcePos", ",", "false", ")", ";", "}", "public", "void", "recordPositionsFrom", "(", "int", "startPC", ",", "int", "sourcePos", ",", "boolean", "widen", ")", "{", "if", "(", "(", "this", ".", "generateAttributes", "&", "ClassFileConstants", ".", "ATTR_LINES", ")", "==", "0", "||", "sourcePos", "==", "0", "||", "(", "startPC", "==", "this", ".", "position", "&&", "!", "widen", ")", ")", "return", ";", "if", "(", "this", ".", "pcToSourceMapSize", "+", "4", ">", "this", ".", "pcToSourceMap", ".", "length", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "pcToSourceMap", ",", "0", ",", "this", ".", "pcToSourceMap", "=", "new", "int", "[", "this", ".", "pcToSourceMapSize", "<<", "1", "]", ",", "0", ",", "this", ".", "pcToSourceMapSize", ")", ";", "}", "if", "(", "this", ".", "pcToSourceMapSize", ">", "0", ")", "{", "int", "lineNumber", ";", "int", "previousLineNumber", "=", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "1", "]", ";", "if", "(", "this", ".", "lineNumberStart", "==", "this", ".", "lineNumberEnd", ")", "{", "lineNumber", "=", "this", ".", "lineNumberStart", ";", "}", "else", "{", "int", "[", "]", "lineSeparatorPositions2", "=", "this", ".", "lineSeparatorPositions", ";", "int", "length", "=", "lineSeparatorPositions2", ".", "length", ";", "if", "(", "previousLineNumber", "==", "1", ")", "{", "if", "(", "sourcePos", "<", "lineSeparatorPositions2", "[", "0", "]", ")", "{", "lineNumber", "=", "1", ";", "if", "(", "startPC", "<", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "2", "]", ")", "{", "int", "insertionIndex", "=", "insertionIndex", "(", "this", ".", "pcToSourceMap", ",", "this", ".", "pcToSourceMapSize", ",", "startPC", ")", ";", "if", "(", "insertionIndex", "!=", "-", "1", ")", "{", "if", "(", "!", "(", "(", "insertionIndex", ">", "1", ")", "&&", "(", "this", ".", "pcToSourceMap", "[", "insertionIndex", "-", "1", "]", "==", "lineNumber", ")", ")", ")", "{", "if", "(", "(", "this", ".", "pcToSourceMapSize", ">", "4", ")", "&&", "(", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "4", "]", ">", "startPC", ")", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "pcToSourceMap", ",", "insertionIndex", ",", "this", ".", "pcToSourceMap", ",", "insertionIndex", "+", "2", ",", "this", ".", "pcToSourceMapSize", "-", "2", "-", "insertionIndex", ")", ";", "this", ".", "pcToSourceMap", "[", "insertionIndex", "++", "]", "=", "startPC", ";", "this", ".", "pcToSourceMap", "[", "insertionIndex", "]", "=", "lineNumber", ";", "}", "else", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "2", "]", "=", "startPC", ";", "}", "}", "}", "}", "this", ".", "lastEntryPC", "=", "this", ".", "position", ";", "return", ";", "}", "else", "if", "(", "length", "==", "1", "||", "sourcePos", "<", "lineSeparatorPositions2", "[", "1", "]", ")", "{", "lineNumber", "=", "2", ";", "if", "(", "startPC", "<=", "this", ".", "lastEntryPC", ")", "{", "int", "insertionIndex", "=", "insertionIndex", "(", "this", ".", "pcToSourceMap", ",", "this", ".", "pcToSourceMapSize", ",", "startPC", ")", ";", "if", "(", "insertionIndex", "!=", "-", "1", ")", "{", "int", "existingEntryIndex", "=", "indexOfSameLineEntrySincePC", "(", "startPC", ",", "lineNumber", ")", ";", "if", "(", "existingEntryIndex", "!=", "-", "1", ")", "{", "this", ".", "pcToSourceMap", "[", "existingEntryIndex", "]", "=", "startPC", ";", "}", "else", "if", "(", "insertionIndex", "<", "1", "||", "this", ".", "pcToSourceMap", "[", "insertionIndex", "-", "1", "]", "!=", "lineNumber", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "pcToSourceMap", ",", "insertionIndex", ",", "this", ".", "pcToSourceMap", ",", "insertionIndex", "+", "2", ",", "this", ".", "pcToSourceMapSize", "-", "insertionIndex", ")", ";", "this", ".", "pcToSourceMap", "[", "insertionIndex", "++", "]", "=", "startPC", ";", "this", ".", "pcToSourceMap", "[", "insertionIndex", "]", "=", "lineNumber", ";", "this", ".", "pcToSourceMapSize", "+=", "2", ";", "}", "}", "else", "if", "(", "this", ".", "position", "!=", "this", ".", "lastEntryPC", ")", "{", "if", "(", "this", ".", "lastEntryPC", "==", "startPC", "||", "this", ".", "lastEntryPC", "==", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "2", "]", ")", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "1", "]", "=", "lineNumber", ";", "}", "else", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "this", ".", "lastEntryPC", ";", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "lineNumber", ";", "}", "}", "else", "if", "(", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "1", "]", "<", "lineNumber", "&&", "widen", ")", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "1", "]", "=", "lineNumber", ";", "}", "}", "else", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "startPC", ";", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "lineNumber", ";", "}", "this", ".", "lastEntryPC", "=", "this", ".", "position", ";", "return", ";", "}", "else", "{", "lineNumber", "=", "Util", ".", "getLineNumber", "(", "sourcePos", ",", "this", ".", "lineSeparatorPositions", ",", "this", ".", "lineNumberStart", "-", "1", ",", "this", ".", "lineNumberEnd", "-", "1", ")", ";", "}", "}", "else", "if", "(", "previousLineNumber", "<", "length", ")", "{", "if", "(", "lineSeparatorPositions2", "[", "previousLineNumber", "-", "2", "]", "<", "sourcePos", ")", "{", "if", "(", "sourcePos", "<", "lineSeparatorPositions2", "[", "previousLineNumber", "-", "1", "]", ")", "{", "lineNumber", "=", "previousLineNumber", ";", "if", "(", "startPC", "<", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "2", "]", ")", "{", "int", "insertionIndex", "=", "insertionIndex", "(", "this", ".", "pcToSourceMap", ",", "this", ".", "pcToSourceMapSize", ",", "startPC", ")", ";", "if", "(", "insertionIndex", "!=", "-", "1", ")", "{", "if", "(", "!", "(", "(", "insertionIndex", ">", "1", ")", "&&", "(", "this", ".", "pcToSourceMap", "[", "insertionIndex", "-", "1", "]", "==", "lineNumber", ")", ")", ")", "{", "if", "(", "(", "this", ".", "pcToSourceMapSize", ">", "4", ")", "&&", "(", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "4", "]", ">", "startPC", ")", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "pcToSourceMap", ",", "insertionIndex", ",", "this", ".", "pcToSourceMap", ",", "insertionIndex", "+", "2", ",", "this", ".", "pcToSourceMapSize", "-", "2", "-", "insertionIndex", ")", ";", "this", ".", "pcToSourceMap", "[", "insertionIndex", "++", "]", "=", "startPC", ";", "this", ".", "pcToSourceMap", "[", "insertionIndex", "]", "=", "lineNumber", ";", "}", "else", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "2", "]", "=", "startPC", ";", "}", "}", "}", "}", "this", ".", "lastEntryPC", "=", "this", ".", "position", ";", "return", ";", "}", "else", "if", "(", "sourcePos", "<", "lineSeparatorPositions2", "[", "previousLineNumber", "]", ")", "{", "lineNumber", "=", "previousLineNumber", "+", "1", ";", "if", "(", "startPC", "<=", "this", ".", "lastEntryPC", ")", "{", "int", "insertionIndex", "=", "insertionIndex", "(", "this", ".", "pcToSourceMap", ",", "this", ".", "pcToSourceMapSize", ",", "startPC", ")", ";", "if", "(", "insertionIndex", "!=", "-", "1", ")", "{", "int", "existingEntryIndex", "=", "indexOfSameLineEntrySincePC", "(", "startPC", ",", "lineNumber", ")", ";", "if", "(", "existingEntryIndex", "!=", "-", "1", ")", "{", "this", ".", "pcToSourceMap", "[", "existingEntryIndex", "]", "=", "startPC", ";", "}", "else", "if", "(", "insertionIndex", "<", "1", "||", "this", ".", "pcToSourceMap", "[", "insertionIndex", "-", "1", "]", "!=", "lineNumber", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "pcToSourceMap", ",", "insertionIndex", ",", "this", ".", "pcToSourceMap", ",", "insertionIndex", "+", "2", ",", "this", ".", "pcToSourceMapSize", "-", "insertionIndex", ")", ";", "this", ".", "pcToSourceMap", "[", "insertionIndex", "++", "]", "=", "startPC", ";", "this", ".", "pcToSourceMap", "[", "insertionIndex", "]", "=", "lineNumber", ";", "this", ".", "pcToSourceMapSize", "+=", "2", ";", "}", "}", "else", "if", "(", "this", ".", "position", "!=", "this", ".", "lastEntryPC", ")", "{", "if", "(", "this", ".", "lastEntryPC", "==", "startPC", "||", "this", ".", "lastEntryPC", "==", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "2", "]", ")", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "1", "]", "=", "lineNumber", ";", "}", "else", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "this", ".", "lastEntryPC", ";", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "lineNumber", ";", "}", "}", "else", "if", "(", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "1", "]", "<", "lineNumber", "&&", "widen", ")", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "1", "]", "=", "lineNumber", ";", "}", "}", "else", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "startPC", ";", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "lineNumber", ";", "}", "this", ".", "lastEntryPC", "=", "this", ".", "position", ";", "return", ";", "}", "else", "{", "lineNumber", "=", "Util", ".", "getLineNumber", "(", "sourcePos", ",", "this", ".", "lineSeparatorPositions", ",", "this", ".", "lineNumberStart", "-", "1", ",", "this", ".", "lineNumberEnd", "-", "1", ")", ";", "}", "}", "else", "{", "lineNumber", "=", "Util", ".", "getLineNumber", "(", "sourcePos", ",", "this", ".", "lineSeparatorPositions", ",", "this", ".", "lineNumberStart", "-", "1", ",", "this", ".", "lineNumberEnd", "-", "1", ")", ";", "}", "}", "else", "if", "(", "lineSeparatorPositions2", "[", "length", "-", "1", "]", "<", "sourcePos", ")", "{", "lineNumber", "=", "length", "+", "1", ";", "if", "(", "startPC", "<=", "this", ".", "lastEntryPC", ")", "{", "int", "insertionIndex", "=", "insertionIndex", "(", "this", ".", "pcToSourceMap", ",", "this", ".", "pcToSourceMapSize", ",", "startPC", ")", ";", "if", "(", "insertionIndex", "!=", "-", "1", ")", "{", "int", "existingEntryIndex", "=", "indexOfSameLineEntrySincePC", "(", "startPC", ",", "lineNumber", ")", ";", "if", "(", "existingEntryIndex", "!=", "-", "1", ")", "{", "this", ".", "pcToSourceMap", "[", "existingEntryIndex", "]", "=", "startPC", ";", "}", "else", "if", "(", "insertionIndex", "<", "1", "||", "this", ".", "pcToSourceMap", "[", "insertionIndex", "-", "1", "]", "!=", "lineNumber", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "pcToSourceMap", ",", "insertionIndex", ",", "this", ".", "pcToSourceMap", ",", "insertionIndex", "+", "2", ",", "this", ".", "pcToSourceMapSize", "-", "insertionIndex", ")", ";", "this", ".", "pcToSourceMap", "[", "insertionIndex", "++", "]", "=", "startPC", ";", "this", ".", "pcToSourceMap", "[", "insertionIndex", "]", "=", "lineNumber", ";", "this", ".", "pcToSourceMapSize", "+=", "2", ";", "}", "}", "else", "if", "(", "this", ".", "position", "!=", "this", ".", "lastEntryPC", ")", "{", "if", "(", "this", ".", "lastEntryPC", "==", "startPC", "||", "this", ".", "lastEntryPC", "==", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "2", "]", ")", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "1", "]", "=", "lineNumber", ";", "}", "else", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "this", ".", "lastEntryPC", ";", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "lineNumber", ";", "}", "}", "else", "if", "(", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "1", "]", "<", "lineNumber", "&&", "widen", ")", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "1", "]", "=", "lineNumber", ";", "}", "}", "else", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "startPC", ";", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "lineNumber", ";", "}", "this", ".", "lastEntryPC", "=", "this", ".", "position", ";", "return", ";", "}", "else", "{", "lineNumber", "=", "Util", ".", "getLineNumber", "(", "sourcePos", ",", "this", ".", "lineSeparatorPositions", ",", "this", ".", "lineNumberStart", "-", "1", ",", "this", ".", "lineNumberEnd", "-", "1", ")", ";", "}", "}", "if", "(", "previousLineNumber", "!=", "lineNumber", ")", "{", "if", "(", "startPC", "<=", "this", ".", "lastEntryPC", ")", "{", "int", "insertionIndex", "=", "insertionIndex", "(", "this", ".", "pcToSourceMap", ",", "this", ".", "pcToSourceMapSize", ",", "startPC", ")", ";", "if", "(", "insertionIndex", "!=", "-", "1", ")", "{", "int", "existingEntryIndex", "=", "indexOfSameLineEntrySincePC", "(", "startPC", ",", "lineNumber", ")", ";", "if", "(", "existingEntryIndex", "!=", "-", "1", ")", "{", "this", ".", "pcToSourceMap", "[", "existingEntryIndex", "]", "=", "startPC", ";", "}", "else", "if", "(", "insertionIndex", "<", "1", "||", "this", ".", "pcToSourceMap", "[", "insertionIndex", "-", "1", "]", "!=", "lineNumber", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "pcToSourceMap", ",", "insertionIndex", ",", "this", ".", "pcToSourceMap", ",", "insertionIndex", "+", "2", ",", "this", ".", "pcToSourceMapSize", "-", "insertionIndex", ")", ";", "this", ".", "pcToSourceMap", "[", "insertionIndex", "++", "]", "=", "startPC", ";", "this", ".", "pcToSourceMap", "[", "insertionIndex", "]", "=", "lineNumber", ";", "this", ".", "pcToSourceMapSize", "+=", "2", ";", "}", "}", "else", "if", "(", "this", ".", "position", "!=", "this", ".", "lastEntryPC", ")", "{", "if", "(", "this", ".", "lastEntryPC", "==", "startPC", "||", "this", ".", "lastEntryPC", "==", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "2", "]", ")", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "1", "]", "=", "lineNumber", ";", "}", "else", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "this", ".", "lastEntryPC", ";", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "lineNumber", ";", "}", "}", "else", "if", "(", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "1", "]", "<", "lineNumber", "&&", "widen", ")", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "1", "]", "=", "lineNumber", ";", "}", "}", "else", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "startPC", ";", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "lineNumber", ";", "}", "}", "else", "{", "if", "(", "startPC", "<", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "2", "]", ")", "{", "int", "insertionIndex", "=", "insertionIndex", "(", "this", ".", "pcToSourceMap", ",", "this", ".", "pcToSourceMapSize", ",", "startPC", ")", ";", "if", "(", "insertionIndex", "!=", "-", "1", ")", "{", "if", "(", "!", "(", "(", "insertionIndex", ">", "1", ")", "&&", "(", "this", ".", "pcToSourceMap", "[", "insertionIndex", "-", "1", "]", "==", "lineNumber", ")", ")", ")", "{", "if", "(", "(", "this", ".", "pcToSourceMapSize", ">", "4", ")", "&&", "(", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "4", "]", ">", "startPC", ")", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "pcToSourceMap", ",", "insertionIndex", ",", "this", ".", "pcToSourceMap", ",", "insertionIndex", "+", "2", ",", "this", ".", "pcToSourceMapSize", "-", "2", "-", "insertionIndex", ")", ";", "this", ".", "pcToSourceMap", "[", "insertionIndex", "++", "]", "=", "startPC", ";", "this", ".", "pcToSourceMap", "[", "insertionIndex", "]", "=", "lineNumber", ";", "}", "else", "{", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "2", "]", "=", "startPC", ";", "}", "}", "}", "}", "}", "this", ".", "lastEntryPC", "=", "this", ".", "position", ";", "}", "else", "{", "int", "lineNumber", "=", "0", ";", "if", "(", "this", ".", "lineNumberStart", "==", "this", ".", "lineNumberEnd", ")", "{", "lineNumber", "=", "this", ".", "lineNumberStart", ";", "}", "else", "{", "lineNumber", "=", "Util", ".", "getLineNumber", "(", "sourcePos", ",", "this", ".", "lineSeparatorPositions", ",", "this", ".", "lineNumberStart", "-", "1", ",", "this", ".", "lineNumberEnd", "-", "1", ")", ";", "}", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "startPC", ";", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "++", "]", "=", "lineNumber", ";", "this", ".", "lastEntryPC", "=", "this", ".", "position", ";", "}", "}", "public", "void", "registerExceptionHandler", "(", "ExceptionLabel", "anExceptionLabel", ")", "{", "int", "length", ";", "if", "(", "this", ".", "exceptionLabelsCounter", "==", "(", "length", "=", "this", ".", "exceptionLabels", ".", "length", ")", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "exceptionLabels", ",", "0", ",", "this", ".", "exceptionLabels", "=", "new", "ExceptionLabel", "[", "length", "+", "LABELS_INCREMENT", "]", ",", "0", ",", "length", ")", ";", "}", "this", ".", "exceptionLabels", "[", "this", ".", "exceptionLabelsCounter", "++", "]", "=", "anExceptionLabel", ";", "}", "public", "void", "removeNotDefinitelyAssignedVariables", "(", "Scope", "scope", ",", "int", "initStateIndex", ")", "{", "if", "(", "(", "this", ".", "generateAttributes", "&", "(", "ClassFileConstants", ".", "ATTR_VARS", "|", "ClassFileConstants", ".", "ATTR_STACK_MAP_TABLE", "|", "ClassFileConstants", ".", "ATTR_STACK_MAP", ")", ")", "==", "0", ")", "return", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "visibleLocalsCount", ";", "i", "++", ")", "{", "LocalVariableBinding", "localBinding", "=", "this", ".", "visibleLocals", "[", "i", "]", ";", "if", "(", "localBinding", "!=", "null", "&&", "!", "isDefinitelyAssigned", "(", "scope", ",", "initStateIndex", ",", "localBinding", ")", "&&", "localBinding", ".", "initializationCount", ">", "0", ")", "{", "localBinding", ".", "recordInitializationEndPC", "(", "this", ".", "position", ")", ";", "}", "}", "}", "public", "void", "removeUnusedPcToSourceMapEntries", "(", ")", "{", "if", "(", "this", ".", "pcToSourceMapSize", "!=", "0", ")", "{", "while", "(", "this", ".", "pcToSourceMapSize", ">=", "2", "&&", "this", ".", "pcToSourceMap", "[", "this", ".", "pcToSourceMapSize", "-", "2", "]", ">", "this", ".", "position", ")", "{", "this", ".", "pcToSourceMapSize", "-=", "2", ";", "}", "}", "}", "public", "void", "removeVariable", "(", "LocalVariableBinding", "localBinding", ")", "{", "if", "(", "localBinding", "==", "null", ")", "return", ";", "if", "(", "localBinding", ".", "initializationCount", ">", "0", ")", "{", "localBinding", ".", "recordInitializationEndPC", "(", "this", ".", "position", ")", ";", "}", "for", "(", "int", "i", "=", "this", ".", "visibleLocalsCount", "-", "1", ";", "i", ">=", "0", ";", "i", "--", ")", "{", "LocalVariableBinding", "visibleLocal", "=", "this", ".", "visibleLocals", "[", "i", "]", ";", "if", "(", "visibleLocal", "==", "localBinding", ")", "{", "this", ".", "visibleLocals", "[", "i", "]", "=", "null", ";", "return", ";", "}", "}", "}", "public", "void", "reset", "(", "AbstractMethodDeclaration", "referenceMethod", ",", "ClassFile", "targetClassFile", ")", "{", "init", "(", "targetClassFile", ")", ";", "this", ".", "methodDeclaration", "=", "referenceMethod", ";", "int", "[", "]", "lineSeparatorPositions2", "=", "this", ".", "lineSeparatorPositions", ";", "if", "(", "lineSeparatorPositions2", "!=", "null", ")", "{", "int", "length", "=", "lineSeparatorPositions2", ".", "length", ";", "int", "lineSeparatorPositionsEnd", "=", "length", "-", "1", ";", "if", "(", "referenceMethod", ".", "isClinit", "(", ")", "||", "referenceMethod", ".", "isConstructor", "(", ")", ")", "{", "this", ".", "lineNumberStart", "=", "1", ";", "this", ".", "lineNumberEnd", "=", "length", "==", "0", "?", "1", ":", "length", ";", "}", "else", "{", "int", "start", "=", "Util", ".", "getLineNumber", "(", "referenceMethod", ".", "bodyStart", ",", "lineSeparatorPositions2", ",", "0", ",", "lineSeparatorPositionsEnd", ")", ";", "this", ".", "lineNumberStart", "=", "start", ";", "if", "(", "start", ">", "lineSeparatorPositionsEnd", ")", "{", "this", ".", "lineNumberEnd", "=", "start", ";", "}", "else", "{", "int", "end", "=", "Util", ".", "getLineNumber", "(", "referenceMethod", ".", "bodyEnd", ",", "lineSeparatorPositions2", ",", "start", "-", "1", ",", "lineSeparatorPositionsEnd", ")", ";", "if", "(", "end", ">=", "lineSeparatorPositionsEnd", ")", "{", "end", "=", "length", ";", "}", "this", ".", "lineNumberEnd", "=", "end", "==", "0", "?", "1", ":", "end", ";", "}", "}", "}", "this", ".", "preserveUnusedLocals", "=", "referenceMethod", ".", "scope", ".", "compilerOptions", "(", ")", ".", "preserveAllLocalVariables", ";", "initializeMaxLocals", "(", "referenceMethod", ".", "binding", ")", ";", "}", "public", "void", "reset", "(", "ClassFile", "givenClassFile", ")", "{", "this", ".", "targetLevel", "=", "givenClassFile", ".", "targetJDK", ";", "int", "produceAttributes", "=", "givenClassFile", ".", "produceAttributes", ";", "this", ".", "generateAttributes", "=", "produceAttributes", ";", "if", "(", "(", "produceAttributes", "&", "ClassFileConstants", ".", "ATTR_LINES", ")", "!=", "0", ")", "{", "this", ".", "lineSeparatorPositions", "=", "givenClassFile", ".", "referenceBinding", ".", "scope", ".", "referenceCompilationUnit", "(", ")", ".", "compilationResult", ".", "getLineSeparatorPositions", "(", ")", ";", "}", "else", "{", "this", ".", "lineSeparatorPositions", "=", "null", ";", "}", "}", "public", "void", "resetForProblemClinit", "(", "ClassFile", "targetClassFile", ")", "{", "init", "(", "targetClassFile", ")", ";", "initializeMaxLocals", "(", "null", ")", ";", "}", "public", "void", "resetInWideMode", "(", ")", "{", "this", ".", "wideMode", "=", "true", ";", "}", "private", "final", "void", "resizeByteArray", "(", ")", "{", "int", "length", "=", "this", ".", "bCodeStream", ".", "length", ";", "int", "requiredSize", "=", "length", "+", "length", ";", "if", "(", "this", ".", "classFileOffset", ">=", "requiredSize", ")", "{", "requiredSize", "=", "this", ".", "classFileOffset", "+", "length", ";", "}", "System", ".", "arraycopy", "(", "this", ".", "bCodeStream", ",", "0", ",", "this", ".", "bCodeStream", "=", "new", "byte", "[", "requiredSize", "]", ",", "0", ",", "length", ")", ";", "}", "final", "public", "void", "ret", "(", "int", "index", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "index", ">", "255", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "3", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_wide", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ret", ";", "writeUnsignedShort", "(", "index", ")", ";", "}", "else", "{", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_ret", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "index", ";", "}", "}", "public", "void", "return_", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_return", ";", "this", ".", "lastAbruptCompletion", "=", "this", ".", "position", ";", "}", "public", "void", "saload", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_saload", ";", "}", "public", "void", "sastore", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "-=", "3", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_sastore", ";", "}", "public", "void", "sendOperator", "(", "int", "operatorConstant", ",", "int", "type_ID", ")", "{", "switch", "(", "type_ID", ")", "{", "case", "TypeIds", ".", "T_int", ":", "case", "TypeIds", ".", "T_boolean", ":", "case", "TypeIds", ".", "T_char", ":", "case", "TypeIds", ".", "T_byte", ":", "case", "TypeIds", ".", "T_short", ":", "switch", "(", "operatorConstant", ")", "{", "case", "OperatorIds", ".", "PLUS", ":", "iadd", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "MINUS", ":", "isub", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "MULTIPLY", ":", "imul", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "DIVIDE", ":", "idiv", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "REMAINDER", ":", "irem", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "LEFT_SHIFT", ":", "ishl", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "RIGHT_SHIFT", ":", "ishr", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "UNSIGNED_RIGHT_SHIFT", ":", "iushr", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "AND", ":", "iand", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "OR", ":", "ior", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "XOR", ":", "ixor", "(", ")", ";", "break", ";", "}", "break", ";", "case", "TypeIds", ".", "T_long", ":", "switch", "(", "operatorConstant", ")", "{", "case", "OperatorIds", ".", "PLUS", ":", "ladd", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "MINUS", ":", "lsub", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "MULTIPLY", ":", "lmul", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "DIVIDE", ":", "ldiv", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "REMAINDER", ":", "lrem", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "LEFT_SHIFT", ":", "lshl", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "RIGHT_SHIFT", ":", "lshr", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "UNSIGNED_RIGHT_SHIFT", ":", "lushr", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "AND", ":", "land", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "OR", ":", "lor", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "XOR", ":", "lxor", "(", ")", ";", "break", ";", "}", "break", ";", "case", "TypeIds", ".", "T_float", ":", "switch", "(", "operatorConstant", ")", "{", "case", "OperatorIds", ".", "PLUS", ":", "fadd", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "MINUS", ":", "fsub", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "MULTIPLY", ":", "fmul", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "DIVIDE", ":", "fdiv", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "REMAINDER", ":", "frem", "(", ")", ";", "}", "break", ";", "case", "TypeIds", ".", "T_double", ":", "switch", "(", "operatorConstant", ")", "{", "case", "OperatorIds", ".", "PLUS", ":", "dadd", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "MINUS", ":", "dsub", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "MULTIPLY", ":", "dmul", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "DIVIDE", ":", "ddiv", "(", ")", ";", "break", ";", "case", "OperatorIds", ".", "REMAINDER", ":", "drem", "(", ")", ";", "}", "}", "}", "public", "void", "sipush", "(", "int", "s", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "++", ";", "if", "(", "this", ".", "stackDepth", ">", "this", ".", "stackMax", ")", "this", ".", "stackMax", "=", "this", ".", "stackDepth", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_sipush", ";", "writeSignedShort", "(", "s", ")", ";", "}", "public", "void", "store", "(", "LocalVariableBinding", "localBinding", ",", "boolean", "valueRequired", ")", "{", "int", "localPosition", "=", "localBinding", ".", "resolvedPosition", ";", "switch", "(", "localBinding", ".", "type", ".", "id", ")", "{", "case", "TypeIds", ".", "T_int", ":", "case", "TypeIds", ".", "T_char", ":", "case", "TypeIds", ".", "T_byte", ":", "case", "TypeIds", ".", "T_short", ":", "case", "TypeIds", ".", "T_boolean", ":", "if", "(", "valueRequired", ")", "dup", "(", ")", ";", "switch", "(", "localPosition", ")", "{", "case", "0", ":", "istore_0", "(", ")", ";", "break", ";", "case", "1", ":", "istore_1", "(", ")", ";", "break", ";", "case", "2", ":", "istore_2", "(", ")", ";", "break", ";", "case", "3", ":", "istore_3", "(", ")", ";", "break", ";", "default", ":", "istore", "(", "localPosition", ")", ";", "}", "break", ";", "case", "TypeIds", ".", "T_float", ":", "if", "(", "valueRequired", ")", "dup", "(", ")", ";", "switch", "(", "localPosition", ")", "{", "case", "0", ":", "fstore_0", "(", ")", ";", "break", ";", "case", "1", ":", "fstore_1", "(", ")", ";", "break", ";", "case", "2", ":", "fstore_2", "(", ")", ";", "break", ";", "case", "3", ":", "fstore_3", "(", ")", ";", "break", ";", "default", ":", "fstore", "(", "localPosition", ")", ";", "}", "break", ";", "case", "TypeIds", ".", "T_double", ":", "if", "(", "valueRequired", ")", "dup2", "(", ")", ";", "switch", "(", "localPosition", ")", "{", "case", "0", ":", "dstore_0", "(", ")", ";", "break", ";", "case", "1", ":", "dstore_1", "(", ")", ";", "break", ";", "case", "2", ":", "dstore_2", "(", ")", ";", "break", ";", "case", "3", ":", "dstore_3", "(", ")", ";", "break", ";", "default", ":", "dstore", "(", "localPosition", ")", ";", "}", "break", ";", "case", "TypeIds", ".", "T_long", ":", "if", "(", "valueRequired", ")", "dup2", "(", ")", ";", "switch", "(", "localPosition", ")", "{", "case", "0", ":", "lstore_0", "(", ")", ";", "break", ";", "case", "1", ":", "lstore_1", "(", ")", ";", "break", ";", "case", "2", ":", "lstore_2", "(", ")", ";", "break", ";", "case", "3", ":", "lstore_3", "(", ")", ";", "break", ";", "default", ":", "lstore", "(", "localPosition", ")", ";", "}", "break", ";", "default", ":", "if", "(", "valueRequired", ")", "dup", "(", ")", ";", "switch", "(", "localPosition", ")", "{", "case", "0", ":", "astore_0", "(", ")", ";", "break", ";", "case", "1", ":", "astore_1", "(", ")", ";", "break", ";", "case", "2", ":", "astore_2", "(", ")", ";", "break", ";", "case", "3", ":", "astore_3", "(", ")", ";", "break", ";", "default", ":", "astore", "(", "localPosition", ")", ";", "}", "}", "}", "public", "void", "swap", "(", ")", "{", "this", ".", "countLabels", "=", "0", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_swap", ";", "}", "public", "void", "tableswitch", "(", "CaseLabel", "defaultLabel", ",", "int", "low", ",", "int", "high", ",", "int", "[", "]", "keys", ",", "int", "[", "]", "sortedIndexes", ",", "CaseLabel", "[", "]", "casesLabel", ")", "{", "this", ".", "countLabels", "=", "0", ";", "this", ".", "stackDepth", "--", ";", "int", "length", "=", "casesLabel", ".", "length", ";", "int", "pos", "=", "this", ".", "position", ";", "defaultLabel", ".", "placeInstruction", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "casesLabel", "[", "i", "]", ".", "placeInstruction", "(", ")", ";", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "Opcodes", ".", "OPC_tableswitch", ";", "for", "(", "int", "i", "=", "(", "3", "-", "(", "pos", "&", "3", ")", ")", ";", "i", ">", "0", ";", "i", "--", ")", "{", "if", "(", "this", ".", "classFileOffset", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "++", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "0", ";", "}", "defaultLabel", ".", "branch", "(", ")", ";", "writeSignedWord", "(", "low", ")", ";", "writeSignedWord", "(", "high", ")", ";", "int", "i", "=", "low", ",", "j", "=", "low", ";", "while", "(", "true", ")", "{", "int", "index", ";", "int", "key", "=", "keys", "[", "index", "=", "sortedIndexes", "[", "j", "-", "low", "]", "]", ";", "if", "(", "key", "==", "i", ")", "{", "casesLabel", "[", "index", "]", ".", "branch", "(", ")", ";", "j", "++", ";", "if", "(", "i", "==", "high", ")", "break", ";", "}", "else", "{", "defaultLabel", ".", "branch", "(", ")", ";", "}", "i", "++", ";", "}", "}", "public", "void", "throwAnyException", "(", "LocalVariableBinding", "anyExceptionVariable", ")", "{", "this", ".", "load", "(", "anyExceptionVariable", ")", ";", "athrow", "(", ")", ";", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", "\"(", "position:\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "position", ")", ";", "buffer", ".", "append", "(", "\"\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "stackDepth", ")", ";", "buffer", ".", "append", "(", "\",nmaxStack:\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "stackMax", ")", ";", "buffer", ".", "append", "(", "\",nmaxLocals:\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "maxLocals", ")", ";", "buffer", ".", "append", "(", "\")\"", ")", ";", "return", "buffer", ".", "toString", "(", ")", ";", "}", "public", "void", "updateLastRecordedEndPC", "(", "Scope", "scope", ",", "int", "pos", ")", "{", "if", "(", "(", "this", ".", "generateAttributes", "&", "ClassFileConstants", ".", "ATTR_LINES", ")", "!=", "0", ")", "{", "this", ".", "lastEntryPC", "=", "pos", ";", "}", "if", "(", "(", "this", ".", "generateAttributes", "&", "(", "ClassFileConstants", ".", "ATTR_VARS", "|", "ClassFileConstants", ".", "ATTR_STACK_MAP_TABLE", "|", "ClassFileConstants", ".", "ATTR_STACK_MAP", ")", ")", "!=", "0", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "locals", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "LocalVariableBinding", "local", "=", "this", ".", "locals", "[", "i", "]", ";", "if", "(", "local", "!=", "null", "&&", "local", ".", "declaringScope", "==", "scope", "&&", "local", ".", "initializationCount", ">", "0", ")", "{", "if", "(", "local", ".", "initializationPCs", "[", "(", "(", "local", ".", "initializationCount", "-", "1", ")", "<<", "1", ")", "+", "1", "]", "==", "pos", ")", "{", "local", ".", "initializationPCs", "[", "(", "(", "local", ".", "initializationCount", "-", "1", ")", "<<", "1", ")", "+", "1", "]", "=", "this", ".", "position", ";", "}", "}", "}", "}", "}", "protected", "void", "writePosition", "(", "BranchLabel", "label", ")", "{", "int", "offset", "=", "label", ".", "position", "-", "this", ".", "position", "+", "1", ";", "if", "(", "Math", ".", "abs", "(", "offset", ")", ">", "0x7FFF", "&&", "!", "this", ".", "wideMode", ")", "{", "throw", "new", "AbortMethod", "(", "CodeStream", ".", "RESTART_IN_WIDE_MODE", ",", "null", ")", ";", "}", "this", ".", "writeSignedShort", "(", "offset", ")", ";", "int", "[", "]", "forwardRefs", "=", "label", ".", "forwardReferences", "(", ")", ";", "for", "(", "int", "i", "=", "0", ",", "max", "=", "label", ".", "forwardReferenceCount", "(", ")", ";", "i", "<", "max", ";", "i", "++", ")", "{", "this", ".", "writePosition", "(", "label", ",", "forwardRefs", "[", "i", "]", ")", ";", "}", "}", "protected", "void", "writePosition", "(", "BranchLabel", "label", ",", "int", "forwardReference", ")", "{", "final", "int", "offset", "=", "label", ".", "position", "-", "forwardReference", "+", "1", ";", "if", "(", "Math", ".", "abs", "(", "offset", ")", ">", "0x7FFF", "&&", "!", "this", ".", "wideMode", ")", "{", "throw", "new", "AbortMethod", "(", "CodeStream", ".", "RESTART_IN_WIDE_MODE", ",", "null", ")", ";", "}", "if", "(", "this", ".", "wideMode", ")", "{", "if", "(", "(", "label", ".", "tagBits", "&", "BranchLabel", ".", "WIDE", ")", "!=", "0", ")", "{", "this", ".", "writeSignedWord", "(", "forwardReference", ",", "offset", ")", ";", "}", "else", "{", "this", ".", "writeSignedShort", "(", "forwardReference", ",", "offset", ")", ";", "}", "}", "else", "{", "this", ".", "writeSignedShort", "(", "forwardReference", ",", "offset", ")", ";", "}", "}", "private", "final", "void", "writeSignedShort", "(", "int", "value", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "(", "value", ">>", "8", ")", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "value", ";", "}", "private", "final", "void", "writeSignedShort", "(", "int", "pos", ",", "int", "value", ")", "{", "int", "currentOffset", "=", "this", ".", "startingClassFileOffset", "+", "pos", ";", "if", "(", "currentOffset", "+", "1", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "bCodeStream", "[", "currentOffset", "]", "=", "(", "byte", ")", "(", "value", ">>", "8", ")", ";", "this", ".", "bCodeStream", "[", "currentOffset", "+", "1", "]", "=", "(", "byte", ")", "value", ";", "}", "protected", "final", "void", "writeSignedWord", "(", "int", "value", ")", "{", "if", "(", "this", ".", "classFileOffset", "+", "3", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "position", "+=", "4", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "(", "(", "value", "&", "0xFF000000", ")", ">>", "24", ")", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "(", "(", "value", "&", "0xFF0000", ")", ">>", "16", ")", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "(", "(", "value", "&", "0xFF00", ")", ">>", "8", ")", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "(", "value", "&", "0xFF", ")", ";", "}", "protected", "void", "writeSignedWord", "(", "int", "pos", ",", "int", "value", ")", "{", "int", "currentOffset", "=", "this", ".", "startingClassFileOffset", "+", "pos", ";", "if", "(", "currentOffset", "+", "3", ">=", "this", ".", "bCodeStream", ".", "length", ")", "{", "resizeByteArray", "(", ")", ";", "}", "this", ".", "bCodeStream", "[", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "(", "value", "&", "0xFF000000", ")", ">>", "24", ")", ";", "this", ".", "bCodeStream", "[", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "(", "value", "&", "0xFF0000", ")", ">>", "16", ")", ";", "this", ".", "bCodeStream", "[", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "(", "value", "&", "0xFF00", ")", ">>", "8", ")", ";", "this", ".", "bCodeStream", "[", "currentOffset", "++", "]", "=", "(", "byte", ")", "(", "value", "&", "0xFF", ")", ";", "}", "private", "final", "void", "writeUnsignedShort", "(", "int", "value", ")", "{", "this", ".", "position", "+=", "2", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "(", "value", ">>>", "8", ")", ";", "this", ".", "bCodeStream", "[", "this", ".", "classFileOffset", "++", "]", "=", "(", "byte", ")", "value", ";", "}", "protected", "void", "writeWidePosition", "(", "BranchLabel", "label", ")", "{", "int", "labelPos", "=", "label", ".", "position", ";", "int", "offset", "=", "labelPos", "-", "this", ".", "position", "+", "1", ";", "this", ".", "writeSignedWord", "(", "offset", ")", ";", "int", "[", "]", "forwardRefs", "=", "label", ".", "forwardReferences", "(", ")", ";", "for", "(", "int", "i", "=", "0", ",", "max", "=", "label", ".", "forwardReferenceCount", "(", ")", ";", "i", "<", "max", ";", "i", "++", ")", "{", "int", "forward", "=", "forwardRefs", "[", "i", "]", ";", "offset", "=", "labelPos", "-", "forward", "+", "1", ";", "this", ".", "writeSignedWord", "(", "forward", ",", "offset", ")", ";", "}", "}", "}", "</s>" ]
5,561
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "public", "class", "CaseLabel", "extends", "BranchLabel", "{", "public", "int", "instructionPosition", "=", "POS_NOT_SET", ";", "public", "CaseLabel", "(", "CodeStream", "codeStream", ")", "{", "super", "(", "codeStream", ")", ";", "}", "void", "branch", "(", ")", "{", "if", "(", "this", ".", "position", "==", "POS_NOT_SET", ")", "{", "addForwardReference", "(", "this", ".", "codeStream", ".", "position", ")", ";", "this", ".", "codeStream", ".", "position", "+=", "4", ";", "this", ".", "codeStream", ".", "classFileOffset", "+=", "4", ";", "}", "else", "{", "this", ".", "codeStream", ".", "writeSignedWord", "(", "this", ".", "position", "-", "this", ".", "instructionPosition", ")", ";", "}", "}", "void", "branchWide", "(", ")", "{", "branch", "(", ")", ";", "}", "public", "boolean", "isCaseLabel", "(", ")", "{", "return", "true", ";", "}", "public", "boolean", "isStandardLabel", "(", ")", "{", "return", "false", ";", "}", "public", "void", "place", "(", ")", "{", "if", "(", "(", "this", ".", "tagBits", "&", "USED", ")", "!=", "0", ")", "{", "this", ".", "position", "=", "this", ".", "codeStream", ".", "getPosition", "(", ")", ";", "}", "else", "{", "this", ".", "position", "=", "this", ".", "codeStream", ".", "position", ";", "}", "if", "(", "this", ".", "instructionPosition", "!=", "POS_NOT_SET", ")", "{", "int", "offset", "=", "this", ".", "position", "-", "this", ".", "instructionPosition", ";", "int", "[", "]", "forwardRefs", "=", "forwardReferences", "(", ")", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "forwardReferenceCount", "(", ")", ";", "i", "<", "length", ";", "i", "++", ")", "{", "this", ".", "codeStream", ".", "writeSignedWord", "(", "forwardRefs", "[", "i", "]", ",", "offset", ")", ";", "}", "this", ".", "codeStream", ".", "addLabel", "(", "this", ")", ";", "}", "}", "void", "placeInstruction", "(", ")", "{", "if", "(", "this", ".", "instructionPosition", "==", "POS_NOT_SET", ")", "{", "this", ".", "instructionPosition", "=", "this", ".", "codeStream", ".", "position", ";", "}", "}", "}", "</s>" ]
5,562
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "public", "class", "CachedIndexEntry", "{", "public", "char", "[", "]", "signature", ";", "public", "int", "index", ";", "public", "CachedIndexEntry", "(", "char", "[", "]", "signature", ",", "int", "index", ")", "{", "this", ".", "signature", "=", "signature", ";", "this", ".", "index", "=", "index", ";", "}", "}", "</s>" ]
5,563
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "public", "interface", "Opcodes", "{", "public", "static", "final", "byte", "OPC_nop", "=", "0", ";", "public", "static", "final", "byte", "OPC_aconst_null", "=", "1", ";", "public", "static", "final", "byte", "OPC_iconst_m1", "=", "2", ";", "public", "static", "final", "byte", "OPC_iconst_0", "=", "3", ";", "public", "static", "final", "byte", "OPC_iconst_1", "=", "4", ";", "public", "static", "final", "byte", "OPC_iconst_2", "=", "5", ";", "public", "static", "final", "byte", "OPC_iconst_3", "=", "6", ";", "public", "static", "final", "byte", "OPC_iconst_4", "=", "7", ";", "public", "static", "final", "byte", "OPC_iconst_5", "=", "8", ";", "public", "static", "final", "byte", "OPC_lconst_0", "=", "9", ";", "public", "static", "final", "byte", "OPC_lconst_1", "=", "10", ";", "public", "static", "final", "byte", "OPC_fconst_0", "=", "11", ";", "public", "static", "final", "byte", "OPC_fconst_1", "=", "12", ";", "public", "static", "final", "byte", "OPC_fconst_2", "=", "13", ";", "public", "static", "final", "byte", "OPC_dconst_0", "=", "14", ";", "public", "static", "final", "byte", "OPC_dconst_1", "=", "15", ";", "public", "static", "final", "byte", "OPC_bipush", "=", "16", ";", "public", "static", "final", "byte", "OPC_sipush", "=", "17", ";", "public", "static", "final", "byte", "OPC_ldc", "=", "18", ";", "public", "static", "final", "byte", "OPC_ldc_w", "=", "19", ";", "public", "static", "final", "byte", "OPC_ldc2_w", "=", "20", ";", "public", "static", "final", "byte", "OPC_iload", "=", "21", ";", "public", "static", "final", "byte", "OPC_lload", "=", "22", ";", "public", "static", "final", "byte", "OPC_fload", "=", "23", ";", "public", "static", "final", "byte", "OPC_dload", "=", "24", ";", "public", "static", "final", "byte", "OPC_aload", "=", "25", ";", "public", "static", "final", "byte", "OPC_iload_0", "=", "26", ";", "public", "static", "final", "byte", "OPC_iload_1", "=", "27", ";", "public", "static", "final", "byte", "OPC_iload_2", "=", "28", ";", "public", "static", "final", "byte", "OPC_iload_3", "=", "29", ";", "public", "static", "final", "byte", "OPC_lload_0", "=", "30", ";", "public", "static", "final", "byte", "OPC_lload_1", "=", "31", ";", "public", "static", "final", "byte", "OPC_lload_2", "=", "32", ";", "public", "static", "final", "byte", "OPC_lload_3", "=", "33", ";", "public", "static", "final", "byte", "OPC_fload_0", "=", "34", ";", "public", "static", "final", "byte", "OPC_fload_1", "=", "35", ";", "public", "static", "final", "byte", "OPC_fload_2", "=", "36", ";", "public", "static", "final", "byte", "OPC_fload_3", "=", "37", ";", "public", "static", "final", "byte", "OPC_dload_0", "=", "38", ";", "public", "static", "final", "byte", "OPC_dload_1", "=", "39", ";", "public", "static", "final", "byte", "OPC_dload_2", "=", "40", ";", "public", "static", "final", "byte", "OPC_dload_3", "=", "41", ";", "public", "static", "final", "byte", "OPC_aload_0", "=", "42", ";", "public", "static", "final", "byte", "OPC_aload_1", "=", "43", ";", "public", "static", "final", "byte", "OPC_aload_2", "=", "44", ";", "public", "static", "final", "byte", "OPC_aload_3", "=", "45", ";", "public", "static", "final", "byte", "OPC_iaload", "=", "46", ";", "public", "static", "final", "byte", "OPC_laload", "=", "47", ";", "public", "static", "final", "byte", "OPC_faload", "=", "48", ";", "public", "static", "final", "byte", "OPC_daload", "=", "49", ";", "public", "static", "final", "byte", "OPC_aaload", "=", "50", ";", "public", "static", "final", "byte", "OPC_baload", "=", "51", ";", "public", "static", "final", "byte", "OPC_caload", "=", "52", ";", "public", "static", "final", "byte", "OPC_saload", "=", "53", ";", "public", "static", "final", "byte", "OPC_istore", "=", "54", ";", "public", "static", "final", "byte", "OPC_lstore", "=", "55", ";", "public", "static", "final", "byte", "OPC_fstore", "=", "56", ";", "public", "static", "final", "byte", "OPC_dstore", "=", "57", ";", "public", "static", "final", "byte", "OPC_astore", "=", "58", ";", "public", "static", "final", "byte", "OPC_istore_0", "=", "59", ";", "public", "static", "final", "byte", "OPC_istore_1", "=", "60", ";", "public", "static", "final", "byte", "OPC_istore_2", "=", "61", ";", "public", "static", "final", "byte", "OPC_istore_3", "=", "62", ";", "public", "static", "final", "byte", "OPC_lstore_0", "=", "63", ";", "public", "static", "final", "byte", "OPC_lstore_1", "=", "64", ";", "public", "static", "final", "byte", "OPC_lstore_2", "=", "65", ";", "public", "static", "final", "byte", "OPC_lstore_3", "=", "66", ";", "public", "static", "final", "byte", "OPC_fstore_0", "=", "67", ";", "public", "static", "final", "byte", "OPC_fstore_1", "=", "68", ";", "public", "static", "final", "byte", "OPC_fstore_2", "=", "69", ";", "public", "static", "final", "byte", "OPC_fstore_3", "=", "70", ";", "public", "static", "final", "byte", "OPC_dstore_0", "=", "71", ";", "public", "static", "final", "byte", "OPC_dstore_1", "=", "72", ";", "public", "static", "final", "byte", "OPC_dstore_2", "=", "73", ";", "public", "static", "final", "byte", "OPC_dstore_3", "=", "74", ";", "public", "static", "final", "byte", "OPC_astore_0", "=", "75", ";", "public", "static", "final", "byte", "OPC_astore_1", "=", "76", ";", "public", "static", "final", "byte", "OPC_astore_2", "=", "77", ";", "public", "static", "final", "byte", "OPC_astore_3", "=", "78", ";", "public", "static", "final", "byte", "OPC_iastore", "=", "79", ";", "public", "static", "final", "byte", "OPC_lastore", "=", "80", ";", "public", "static", "final", "byte", "OPC_fastore", "=", "81", ";", "public", "static", "final", "byte", "OPC_dastore", "=", "82", ";", "public", "static", "final", "byte", "OPC_aastore", "=", "83", ";", "public", "static", "final", "byte", "OPC_bastore", "=", "84", ";", "public", "static", "final", "byte", "OPC_castore", "=", "85", ";", "public", "static", "final", "byte", "OPC_sastore", "=", "86", ";", "public", "static", "final", "byte", "OPC_pop", "=", "87", ";", "public", "static", "final", "byte", "OPC_pop2", "=", "88", ";", "public", "static", "final", "byte", "OPC_dup", "=", "89", ";", "public", "static", "final", "byte", "OPC_dup_x1", "=", "90", ";", "public", "static", "final", "byte", "OPC_dup_x2", "=", "91", ";", "public", "static", "final", "byte", "OPC_dup2", "=", "92", ";", "public", "static", "final", "byte", "OPC_dup2_x1", "=", "93", ";", "public", "static", "final", "byte", "OPC_dup2_x2", "=", "94", ";", "public", "static", "final", "byte", "OPC_swap", "=", "95", ";", "public", "static", "final", "byte", "OPC_iadd", "=", "96", ";", "public", "static", "final", "byte", "OPC_ladd", "=", "97", ";", "public", "static", "final", "byte", "OPC_fadd", "=", "98", ";", "public", "static", "final", "byte", "OPC_dadd", "=", "99", ";", "public", "static", "final", "byte", "OPC_isub", "=", "100", ";", "public", "static", "final", "byte", "OPC_lsub", "=", "101", ";", "public", "static", "final", "byte", "OPC_fsub", "=", "102", ";", "public", "static", "final", "byte", "OPC_dsub", "=", "103", ";", "public", "static", "final", "byte", "OPC_imul", "=", "104", ";", "public", "static", "final", "byte", "OPC_lmul", "=", "105", ";", "public", "static", "final", "byte", "OPC_fmul", "=", "106", ";", "public", "static", "final", "byte", "OPC_dmul", "=", "107", ";", "public", "static", "final", "byte", "OPC_idiv", "=", "108", ";", "public", "static", "final", "byte", "OPC_ldiv", "=", "109", ";", "public", "static", "final", "byte", "OPC_fdiv", "=", "110", ";", "public", "static", "final", "byte", "OPC_ddiv", "=", "111", ";", "public", "static", "final", "byte", "OPC_irem", "=", "112", ";", "public", "static", "final", "byte", "OPC_lrem", "=", "113", ";", "public", "static", "final", "byte", "OPC_frem", "=", "114", ";", "public", "static", "final", "byte", "OPC_drem", "=", "115", ";", "public", "static", "final", "byte", "OPC_ineg", "=", "116", ";", "public", "static", "final", "byte", "OPC_lneg", "=", "117", ";", "public", "static", "final", "byte", "OPC_fneg", "=", "118", ";", "public", "static", "final", "byte", "OPC_dneg", "=", "119", ";", "public", "static", "final", "byte", "OPC_ishl", "=", "120", ";", "public", "static", "final", "byte", "OPC_lshl", "=", "121", ";", "public", "static", "final", "byte", "OPC_ishr", "=", "122", ";", "public", "static", "final", "byte", "OPC_lshr", "=", "123", ";", "public", "static", "final", "byte", "OPC_iushr", "=", "124", ";", "public", "static", "final", "byte", "OPC_lushr", "=", "125", ";", "public", "static", "final", "byte", "OPC_iand", "=", "126", ";", "public", "static", "final", "byte", "OPC_land", "=", "127", ";", "public", "static", "final", "byte", "OPC_ior", "=", "(", "byte", ")", "128", ";", "public", "static", "final", "byte", "OPC_lor", "=", "(", "byte", ")", "129", ";", "public", "static", "final", "byte", "OPC_ixor", "=", "(", "byte", ")", "130", ";", "public", "static", "final", "byte", "OPC_lxor", "=", "(", "byte", ")", "131", ";", "public", "static", "final", "byte", "OPC_iinc", "=", "(", "byte", ")", "132", ";", "public", "static", "final", "byte", "OPC_i2l", "=", "(", "byte", ")", "133", ";", "public", "static", "final", "byte", "OPC_i2f", "=", "(", "byte", ")", "134", ";", "public", "static", "final", "byte", "OPC_i2d", "=", "(", "byte", ")", "135", ";", "public", "static", "final", "byte", "OPC_l2i", "=", "(", "byte", ")", "136", ";", "public", "static", "final", "byte", "OPC_l2f", "=", "(", "byte", ")", "137", ";", "public", "static", "final", "byte", "OPC_l2d", "=", "(", "byte", ")", "138", ";", "public", "static", "final", "byte", "OPC_f2i", "=", "(", "byte", ")", "139", ";", "public", "static", "final", "byte", "OPC_f2l", "=", "(", "byte", ")", "140", ";", "public", "static", "final", "byte", "OPC_f2d", "=", "(", "byte", ")", "141", ";", "public", "static", "final", "byte", "OPC_d2i", "=", "(", "byte", ")", "142", ";", "public", "static", "final", "byte", "OPC_d2l", "=", "(", "byte", ")", "143", ";", "public", "static", "final", "byte", "OPC_d2f", "=", "(", "byte", ")", "144", ";", "public", "static", "final", "byte", "OPC_i2b", "=", "(", "byte", ")", "145", ";", "public", "static", "final", "byte", "OPC_i2c", "=", "(", "byte", ")", "146", ";", "public", "static", "final", "byte", "OPC_i2s", "=", "(", "byte", ")", "147", ";", "public", "static", "final", "byte", "OPC_lcmp", "=", "(", "byte", ")", "148", ";", "public", "static", "final", "byte", "OPC_fcmpl", "=", "(", "byte", ")", "149", ";", "public", "static", "final", "byte", "OPC_fcmpg", "=", "(", "byte", ")", "150", ";", "public", "static", "final", "byte", "OPC_dcmpl", "=", "(", "byte", ")", "151", ";", "public", "static", "final", "byte", "OPC_dcmpg", "=", "(", "byte", ")", "152", ";", "public", "static", "final", "byte", "OPC_ifeq", "=", "(", "byte", ")", "153", ";", "public", "static", "final", "byte", "OPC_ifne", "=", "(", "byte", ")", "154", ";", "public", "static", "final", "byte", "OPC_iflt", "=", "(", "byte", ")", "155", ";", "public", "static", "final", "byte", "OPC_ifge", "=", "(", "byte", ")", "156", ";", "public", "static", "final", "byte", "OPC_ifgt", "=", "(", "byte", ")", "157", ";", "public", "static", "final", "byte", "OPC_ifle", "=", "(", "byte", ")", "158", ";", "public", "static", "final", "byte", "OPC_if_icmpeq", "=", "(", "byte", ")", "159", ";", "public", "static", "final", "byte", "OPC_if_icmpne", "=", "(", "byte", ")", "160", ";", "public", "static", "final", "byte", "OPC_if_icmplt", "=", "(", "byte", ")", "161", ";", "public", "static", "final", "byte", "OPC_if_icmpge", "=", "(", "byte", ")", "162", ";", "public", "static", "final", "byte", "OPC_if_icmpgt", "=", "(", "byte", ")", "163", ";", "public", "static", "final", "byte", "OPC_if_icmple", "=", "(", "byte", ")", "164", ";", "public", "static", "final", "byte", "OPC_if_acmpeq", "=", "(", "byte", ")", "165", ";", "public", "static", "final", "byte", "OPC_if_acmpne", "=", "(", "byte", ")", "166", ";", "public", "static", "final", "byte", "OPC_goto", "=", "(", "byte", ")", "167", ";", "public", "static", "final", "byte", "OPC_jsr", "=", "(", "byte", ")", "168", ";", "public", "static", "final", "byte", "OPC_ret", "=", "(", "byte", ")", "169", ";", "public", "static", "final", "byte", "OPC_tableswitch", "=", "(", "byte", ")", "170", ";", "public", "static", "final", "byte", "OPC_lookupswitch", "=", "(", "byte", ")", "171", ";", "public", "static", "final", "byte", "OPC_ireturn", "=", "(", "byte", ")", "172", ";", "public", "static", "final", "byte", "OPC_lreturn", "=", "(", "byte", ")", "173", ";", "public", "static", "final", "byte", "OPC_freturn", "=", "(", "byte", ")", "174", ";", "public", "static", "final", "byte", "OPC_dreturn", "=", "(", "byte", ")", "175", ";", "public", "static", "final", "byte", "OPC_areturn", "=", "(", "byte", ")", "176", ";", "public", "static", "final", "byte", "OPC_return", "=", "(", "byte", ")", "177", ";", "public", "static", "final", "byte", "OPC_getstatic", "=", "(", "byte", ")", "178", ";", "public", "static", "final", "byte", "OPC_putstatic", "=", "(", "byte", ")", "179", ";", "public", "static", "final", "byte", "OPC_getfield", "=", "(", "byte", ")", "180", ";", "public", "static", "final", "byte", "OPC_putfield", "=", "(", "byte", ")", "181", ";", "public", "static", "final", "byte", "OPC_invokevirtual", "=", "(", "byte", ")", "182", ";", "public", "static", "final", "byte", "OPC_invokespecial", "=", "(", "byte", ")", "183", ";", "public", "static", "final", "byte", "OPC_invokestatic", "=", "(", "byte", ")", "184", ";", "public", "static", "final", "byte", "OPC_invokeinterface", "=", "(", "byte", ")", "185", ";", "public", "static", "final", "byte", "OPC_new", "=", "(", "byte", ")", "187", ";", "public", "static", "final", "byte", "OPC_newarray", "=", "(", "byte", ")", "188", ";", "public", "static", "final", "byte", "OPC_anewarray", "=", "(", "byte", ")", "189", ";", "public", "static", "final", "byte", "OPC_arraylength", "=", "(", "byte", ")", "190", ";", "public", "static", "final", "byte", "OPC_athrow", "=", "(", "byte", ")", "191", ";", "public", "static", "final", "byte", "OPC_checkcast", "=", "(", "byte", ")", "192", ";", "public", "static", "final", "byte", "OPC_instanceof", "=", "(", "byte", ")", "193", ";", "public", "static", "final", "byte", "OPC_monitorenter", "=", "(", "byte", ")", "194", ";", "public", "static", "final", "byte", "OPC_monitorexit", "=", "(", "byte", ")", "195", ";", "public", "static", "final", "byte", "OPC_wide", "=", "(", "byte", ")", "196", ";", "public", "static", "final", "byte", "OPC_multianewarray", "=", "(", "byte", ")", "197", ";", "public", "static", "final", "byte", "OPC_ifnull", "=", "(", "byte", ")", "198", ";", "public", "static", "final", "byte", "OPC_ifnonnull", "=", "(", "byte", ")", "199", ";", "public", "static", "final", "byte", "OPC_goto_w", "=", "(", "byte", ")", "200", ";", "public", "static", "final", "byte", "OPC_jsr_w", "=", "(", "byte", ")", "201", ";", "}", "</s>" ]
5,564
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "import", "java", ".", "util", ".", "Arrays", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "LocalVariableBinding", ";", "public", "class", "BranchLabel", "extends", "Label", "{", "private", "int", "[", "]", "forwardReferences", "=", "new", "int", "[", "10", "]", ";", "private", "int", "forwardReferenceCount", "=", "0", ";", "BranchLabel", "delegate", ";", "public", "int", "tagBits", ";", "public", "final", "static", "int", "WIDE", "=", "1", ";", "public", "final", "static", "int", "USED", "=", "2", ";", "public", "BranchLabel", "(", ")", "{", "}", "public", "BranchLabel", "(", "CodeStream", "codeStream", ")", "{", "super", "(", "codeStream", ")", ";", "}", "void", "addForwardReference", "(", "int", "pos", ")", "{", "if", "(", "this", ".", "delegate", "!=", "null", ")", "{", "this", ".", "delegate", ".", "addForwardReference", "(", "pos", ")", ";", "return", ";", "}", "final", "int", "count", "=", "this", ".", "forwardReferenceCount", ";", "if", "(", "count", ">=", "1", ")", "{", "int", "previousValue", "=", "this", ".", "forwardReferences", "[", "count", "-", "1", "]", ";", "if", "(", "previousValue", "<", "pos", ")", "{", "int", "length", ";", "if", "(", "count", ">=", "(", "length", "=", "this", ".", "forwardReferences", ".", "length", ")", ")", "System", ".", "arraycopy", "(", "this", ".", "forwardReferences", ",", "0", ",", "(", "this", ".", "forwardReferences", "=", "new", "int", "[", "2", "*", "length", "]", ")", ",", "0", ",", "length", ")", ";", "this", ".", "forwardReferences", "[", "this", ".", "forwardReferenceCount", "++", "]", "=", "pos", ";", "}", "else", "if", "(", "previousValue", ">", "pos", ")", "{", "int", "[", "]", "refs", "=", "this", ".", "forwardReferences", ";", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "forwardReferenceCount", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "refs", "[", "i", "]", "==", "pos", ")", "return", ";", "}", "int", "length", ";", "if", "(", "count", ">=", "(", "length", "=", "refs", ".", "length", ")", ")", "System", ".", "arraycopy", "(", "refs", ",", "0", ",", "(", "this", ".", "forwardReferences", "=", "new", "int", "[", "2", "*", "length", "]", ")", ",", "0", ",", "length", ")", ";", "this", ".", "forwardReferences", "[", "this", ".", "forwardReferenceCount", "++", "]", "=", "pos", ";", "Arrays", ".", "sort", "(", "this", ".", "forwardReferences", ",", "0", ",", "this", ".", "forwardReferenceCount", ")", ";", "}", "}", "else", "{", "int", "length", ";", "if", "(", "count", ">=", "(", "length", "=", "this", ".", "forwardReferences", ".", "length", ")", ")", "System", ".", "arraycopy", "(", "this", ".", "forwardReferences", ",", "0", ",", "(", "this", ".", "forwardReferences", "=", "new", "int", "[", "2", "*", "length", "]", ")", ",", "0", ",", "length", ")", ";", "this", ".", "forwardReferences", "[", "this", ".", "forwardReferenceCount", "++", "]", "=", "pos", ";", "}", "}", "public", "void", "becomeDelegateFor", "(", "BranchLabel", "otherLabel", ")", "{", "otherLabel", ".", "delegate", "=", "this", ";", "final", "int", "otherCount", "=", "otherLabel", ".", "forwardReferenceCount", ";", "if", "(", "otherCount", "==", "0", ")", "return", ";", "int", "[", "]", "mergedForwardReferences", "=", "new", "int", "[", "this", ".", "forwardReferenceCount", "+", "otherCount", "]", ";", "int", "indexInMerge", "=", "0", ";", "int", "j", "=", "0", ";", "int", "i", "=", "0", ";", "int", "max", "=", "this", ".", "forwardReferenceCount", ";", "int", "max2", "=", "otherLabel", ".", "forwardReferenceCount", ";", "loop1", ":", "for", "(", ";", "i", "<", "max", ";", "i", "++", ")", "{", "final", "int", "value1", "=", "this", ".", "forwardReferences", "[", "i", "]", ";", "for", "(", ";", "j", "<", "max2", ";", "j", "++", ")", "{", "final", "int", "value2", "=", "otherLabel", ".", "forwardReferences", "[", "j", "]", ";", "if", "(", "value1", "<", "value2", ")", "{", "mergedForwardReferences", "[", "indexInMerge", "++", "]", "=", "value1", ";", "continue", "loop1", ";", "}", "else", "if", "(", "value1", "==", "value2", ")", "{", "mergedForwardReferences", "[", "indexInMerge", "++", "]", "=", "value1", ";", "j", "++", ";", "continue", "loop1", ";", "}", "else", "{", "mergedForwardReferences", "[", "indexInMerge", "++", "]", "=", "value2", ";", "}", "}", "mergedForwardReferences", "[", "indexInMerge", "++", "]", "=", "value1", ";", "}", "for", "(", ";", "j", "<", "max2", ";", "j", "++", ")", "{", "mergedForwardReferences", "[", "indexInMerge", "++", "]", "=", "otherLabel", ".", "forwardReferences", "[", "j", "]", ";", "}", "this", ".", "forwardReferences", "=", "mergedForwardReferences", ";", "this", ".", "forwardReferenceCount", "=", "indexInMerge", ";", "}", "void", "branch", "(", ")", "{", "this", ".", "tagBits", "|=", "BranchLabel", ".", "USED", ";", "if", "(", "this", ".", "delegate", "!=", "null", ")", "{", "this", ".", "delegate", ".", "branch", "(", ")", ";", "return", ";", "}", "if", "(", "this", ".", "position", "==", "Label", ".", "POS_NOT_SET", ")", "{", "addForwardReference", "(", "this", ".", "codeStream", ".", "position", ")", ";", "this", ".", "codeStream", ".", "position", "+=", "2", ";", "this", ".", "codeStream", ".", "classFileOffset", "+=", "2", ";", "}", "else", "{", "this", ".", "codeStream", ".", "writePosition", "(", "this", ")", ";", "}", "}", "void", "branchWide", "(", ")", "{", "this", ".", "tagBits", "|=", "BranchLabel", ".", "USED", ";", "if", "(", "this", ".", "delegate", "!=", "null", ")", "{", "this", ".", "delegate", ".", "branchWide", "(", ")", ";", "return", ";", "}", "if", "(", "this", ".", "position", "==", "Label", ".", "POS_NOT_SET", ")", "{", "addForwardReference", "(", "this", ".", "codeStream", ".", "position", ")", ";", "this", ".", "tagBits", "|=", "BranchLabel", ".", "WIDE", ";", "this", ".", "codeStream", ".", "position", "+=", "4", ";", "this", ".", "codeStream", ".", "classFileOffset", "+=", "4", ";", "}", "else", "{", "this", ".", "codeStream", ".", "writeWidePosition", "(", "this", ")", ";", "}", "}", "public", "int", "forwardReferenceCount", "(", ")", "{", "if", "(", "this", ".", "delegate", "!=", "null", ")", "this", ".", "delegate", ".", "forwardReferenceCount", "(", ")", ";", "return", "this", ".", "forwardReferenceCount", ";", "}", "public", "int", "[", "]", "forwardReferences", "(", ")", "{", "if", "(", "this", ".", "delegate", "!=", "null", ")", "this", ".", "delegate", ".", "forwardReferences", "(", ")", ";", "return", "this", ".", "forwardReferences", ";", "}", "public", "void", "initialize", "(", "CodeStream", "stream", ")", "{", "this", ".", "codeStream", "=", "stream", ";", "this", ".", "position", "=", "Label", ".", "POS_NOT_SET", ";", "this", ".", "forwardReferenceCount", "=", "0", ";", "this", ".", "delegate", "=", "null", ";", "}", "public", "boolean", "isCaseLabel", "(", ")", "{", "return", "false", ";", "}", "public", "boolean", "isStandardLabel", "(", ")", "{", "return", "true", ";", "}", "public", "void", "place", "(", ")", "{", "if", "(", "this", ".", "position", "==", "Label", ".", "POS_NOT_SET", ")", "{", "this", ".", "position", "=", "this", ".", "codeStream", ".", "position", ";", "this", ".", "codeStream", ".", "addLabel", "(", "this", ")", ";", "int", "oldPosition", "=", "this", ".", "position", ";", "boolean", "isOptimizedBranch", "=", "false", ";", "if", "(", "this", ".", "forwardReferenceCount", "!=", "0", ")", "{", "isOptimizedBranch", "=", "(", "this", ".", "forwardReferences", "[", "this", ".", "forwardReferenceCount", "-", "1", "]", "+", "2", "==", "this", ".", "position", ")", "&&", "(", "this", ".", "codeStream", ".", "bCodeStream", "[", "this", ".", "codeStream", ".", "classFileOffset", "-", "3", "]", "==", "Opcodes", ".", "OPC_goto", ")", ";", "if", "(", "isOptimizedBranch", ")", "{", "if", "(", "this", ".", "codeStream", ".", "lastAbruptCompletion", "==", "this", ".", "position", ")", "{", "this", ".", "codeStream", ".", "lastAbruptCompletion", "=", "-", "1", ";", "}", "this", ".", "codeStream", ".", "position", "=", "(", "this", ".", "position", "-=", "3", ")", ";", "this", ".", "codeStream", ".", "classFileOffset", "-=", "3", ";", "this", ".", "forwardReferenceCount", "--", ";", "if", "(", "this", ".", "codeStream", ".", "lastEntryPC", "==", "oldPosition", ")", "{", "this", ".", "codeStream", ".", "lastEntryPC", "=", "this", ".", "position", ";", "}", "if", "(", "(", "this", ".", "codeStream", ".", "generateAttributes", "&", "(", "ClassFileConstants", ".", "ATTR_VARS", "|", "ClassFileConstants", ".", "ATTR_STACK_MAP_TABLE", "|", "ClassFileConstants", ".", "ATTR_STACK_MAP", ")", ")", "!=", "0", ")", "{", "LocalVariableBinding", "locals", "[", "]", "=", "this", ".", "codeStream", ".", "locals", ";", "for", "(", "int", "i", "=", "0", ",", "max", "=", "locals", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "LocalVariableBinding", "local", "=", "locals", "[", "i", "]", ";", "if", "(", "(", "local", "!=", "null", ")", "&&", "(", "local", ".", "initializationCount", ">", "0", ")", ")", "{", "if", "(", "local", ".", "initializationPCs", "[", "(", "(", "local", ".", "initializationCount", "-", "1", ")", "<<", "1", ")", "+", "1", "]", "==", "oldPosition", ")", "{", "local", ".", "initializationPCs", "[", "(", "(", "local", ".", "initializationCount", "-", "1", ")", "<<", "1", ")", "+", "1", "]", "=", "this", ".", "position", ";", "}", "if", "(", "local", ".", "initializationPCs", "[", "(", "local", ".", "initializationCount", "-", "1", ")", "<<", "1", "]", "==", "oldPosition", ")", "{", "local", ".", "initializationPCs", "[", "(", "local", ".", "initializationCount", "-", "1", ")", "<<", "1", "]", "=", "this", ".", "position", ";", "}", "}", "}", "}", "if", "(", "(", "this", ".", "codeStream", ".", "generateAttributes", "&", "ClassFileConstants", ".", "ATTR_LINES", ")", "!=", "0", ")", "{", "this", ".", "codeStream", ".", "removeUnusedPcToSourceMapEntries", "(", ")", ";", "}", "}", "}", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "forwardReferenceCount", ";", "i", "++", ")", "{", "this", ".", "codeStream", ".", "writePosition", "(", "this", ",", "this", ".", "forwardReferences", "[", "i", "]", ")", ";", "}", "if", "(", "isOptimizedBranch", ")", "{", "this", ".", "codeStream", ".", "optimizeBranch", "(", "oldPosition", ",", "this", ")", ";", "}", "}", "}", "public", "String", "toString", "(", ")", "{", "String", "basic", "=", "getClass", "(", ")", ".", "getName", "(", ")", ";", "basic", "=", "basic", ".", "substring", "(", "basic", ".", "lastIndexOf", "(", "'.'", ")", "+", "1", ")", ";", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", "basic", ")", ";", "buffer", ".", "append", "(", "'@'", ")", ".", "append", "(", "Integer", ".", "toHexString", "(", "hashCode", "(", ")", ")", ")", ";", "buffer", ".", "append", "(", "\"(position=\"", ")", ".", "append", "(", "this", ".", "position", ")", ";", "if", "(", "this", ".", "delegate", "!=", "null", ")", "buffer", ".", "append", "(", "\"delegate=\"", ")", ".", "append", "(", "this", ".", "delegate", ")", ";", "buffer", ".", "append", "(", "\"\"", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "forwardReferenceCount", "-", "1", ";", "i", "++", ")", "buffer", ".", "append", "(", "this", ".", "forwardReferences", "[", "i", "]", "+", "\",", "\"", ")", ";", "if", "(", "this", ".", "forwardReferenceCount", ">=", "1", ")", "buffer", ".", "append", "(", "this", ".", "forwardReferences", "[", "this", ".", "forwardReferenceCount", "-", "1", "]", ")", ";", "buffer", ".", "append", "(", "\"]", ")\"", ")", ";", "return", "buffer", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
5,565
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeBinding", ";", "public", "class", "ExceptionLabel", "extends", "Label", "{", "public", "int", "ranges", "[", "]", "=", "{", "POS_NOT_SET", ",", "POS_NOT_SET", "}", ";", "public", "int", "count", "=", "0", ";", "public", "TypeBinding", "exceptionType", ";", "public", "ExceptionLabel", "(", "CodeStream", "codeStream", ",", "TypeBinding", "exceptionType", ")", "{", "super", "(", "codeStream", ")", ";", "this", ".", "exceptionType", "=", "exceptionType", ";", "}", "public", "void", "place", "(", ")", "{", "this", ".", "codeStream", ".", "registerExceptionHandler", "(", "this", ")", ";", "this", ".", "position", "=", "this", ".", "codeStream", ".", "getPosition", "(", ")", ";", "}", "public", "void", "placeEnd", "(", ")", "{", "int", "endPosition", "=", "this", ".", "codeStream", ".", "position", ";", "if", "(", "this", ".", "ranges", "[", "this", ".", "count", "-", "1", "]", "==", "endPosition", ")", "{", "this", ".", "count", "--", ";", "}", "else", "{", "this", ".", "ranges", "[", "this", ".", "count", "++", "]", "=", "endPosition", ";", "}", "}", "public", "void", "placeStart", "(", ")", "{", "int", "startPosition", "=", "this", ".", "codeStream", ".", "position", ";", "if", "(", "this", ".", "count", ">", "0", "&&", "this", ".", "ranges", "[", "this", ".", "count", "-", "1", "]", "==", "startPosition", ")", "{", "this", ".", "count", "--", ";", "return", ";", "}", "int", "length", ";", "if", "(", "this", ".", "count", "==", "(", "length", "=", "this", ".", "ranges", ".", "length", ")", ")", "{", "System", ".", "arraycopy", "(", "this", ".", "ranges", ",", "0", ",", "this", ".", "ranges", "=", "new", "int", "[", "length", "*", "2", "]", ",", "0", ",", "length", ")", ";", "}", "this", ".", "ranges", "[", "this", ".", "count", "++", "]", "=", "startPosition", ";", "}", "public", "String", "toString", "(", ")", "{", "String", "basic", "=", "getClass", "(", ")", ".", "getName", "(", ")", ";", "basic", "=", "basic", ".", "substring", "(", "basic", ".", "lastIndexOf", "(", "'.'", ")", "+", "1", ")", ";", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", "basic", ")", ";", "buffer", ".", "append", "(", "'@'", ")", ".", "append", "(", "Integer", ".", "toHexString", "(", "hashCode", "(", ")", ")", ")", ";", "buffer", ".", "append", "(", "\"(type=\"", ")", ".", "append", "(", "this", ".", "exceptionType", "==", "null", "?", "CharOperation", ".", "NO_CHAR", ":", "this", ".", "exceptionType", ".", "readableName", "(", ")", ")", ";", "buffer", ".", "append", "(", "\",", "position=\"", ")", ".", "append", "(", "this", ".", "position", ")", ";", "buffer", ".", "append", "(", "\",", "ranges", "=", "\"", ")", ";", "if", "(", "this", ".", "count", "==", "0", ")", "{", "buffer", ".", "append", "(", "\"[]\"", ")", ";", "}", "else", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "count", ";", "i", "++", ")", "{", "if", "(", "(", "i", "&", "1", ")", "==", "0", ")", "{", "buffer", ".", "append", "(", "\"[\"", ")", ".", "append", "(", "this", ".", "ranges", "[", "i", "]", ")", ";", "}", "else", "{", "buffer", ".", "append", "(", "\",\"", ")", ".", "append", "(", "this", ".", "ranges", "[", "i", "]", ")", ".", "append", "(", "\"]\"", ")", ";", "}", "}", "if", "(", "(", "this", ".", "count", "&", "1", ")", "==", "1", ")", "{", "buffer", ".", "append", "(", "\",?]\"", ")", ";", "}", "}", "buffer", ".", "append", "(", "')'", ")", ";", "return", "buffer", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
5,566
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ";", "public", "interface", "AttributeNamesConstants", "{", "final", "char", "[", "]", "SyntheticName", "=", "\"Synthetic\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "ConstantValueName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "LineNumberTableName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "LocalVariableTableName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "InnerClassName", "=", "\"InnerClasses\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "CodeName", "=", "\"Code\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "ExceptionsName", "=", "\"Exceptions\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "SourceName", "=", "\"SourceFile\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "DeprecatedName", "=", "\"Deprecated\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "SignatureName", "=", "\"Signature\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "LocalVariableTypeTableName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "EnclosingMethodName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "AnnotationDefaultName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "RuntimeInvisibleAnnotationsName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "RuntimeVisibleAnnotationsName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "RuntimeInvisibleParameterAnnotationsName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "RuntimeVisibleParameterAnnotationsName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "StackMapTableName", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "InconsistentHierarchy", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "VarargsName", "=", "\"Varargs\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "StackMapName", "=", "\"StackMap\"", ".", "toCharArray", "(", ")", ";", "final", "char", "[", "]", "MissingTypesName", "=", "\"MissingTypes\"", ".", "toCharArray", "(", ")", ";", "}", "</s>" ]
5,567
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ";", "public", "class", "DefaultErrorHandlingPolicies", "{", "public", "static", "IErrorHandlingPolicy", "exitAfterAllProblems", "(", ")", "{", "return", "new", "IErrorHandlingPolicy", "(", ")", "{", "public", "boolean", "stopOnFirstError", "(", ")", "{", "return", "false", ";", "}", "public", "boolean", "proceedOnErrors", "(", ")", "{", "return", "false", ";", "}", "}", ";", "}", "public", "static", "IErrorHandlingPolicy", "exitOnFirstError", "(", ")", "{", "return", "new", "IErrorHandlingPolicy", "(", ")", "{", "public", "boolean", "stopOnFirstError", "(", ")", "{", "return", "true", ";", "}", "public", "boolean", "proceedOnErrors", "(", ")", "{", "return", "false", ";", "}", "}", ";", "}", "public", "static", "IErrorHandlingPolicy", "proceedOnFirstError", "(", ")", "{", "return", "new", "IErrorHandlingPolicy", "(", ")", "{", "public", "boolean", "stopOnFirstError", "(", ")", "{", "return", "true", ";", "}", "public", "boolean", "proceedOnErrors", "(", ")", "{", "return", "true", ";", "}", "}", ";", "}", "public", "static", "IErrorHandlingPolicy", "proceedWithAllProblems", "(", ")", "{", "return", "new", "IErrorHandlingPolicy", "(", ")", "{", "public", "boolean", "stopOnFirstError", "(", ")", "{", "return", "false", ";", "}", "public", "boolean", "proceedOnErrors", "(", ")", "{", "return", "true", ";", "}", "}", ";", "}", "}", "</s>" ]
5,568
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Wildcard", ";", "abstract", "public", "class", "TypeBinding", "extends", "Binding", "{", "public", "int", "id", "=", "TypeIds", ".", "NoId", ";", "public", "long", "tagBits", "=", "0", ";", "public", "final", "static", "BaseTypeBinding", "INT", "=", "new", "BaseTypeBinding", "(", "TypeIds", ".", "T_int", ",", "TypeConstants", ".", "INT", ",", "new", "char", "[", "]", "{", "'I'", "}", ")", ";", "public", "final", "static", "BaseTypeBinding", "BYTE", "=", "new", "BaseTypeBinding", "(", "TypeIds", ".", "T_byte", ",", "TypeConstants", ".", "BYTE", ",", "new", "char", "[", "]", "{", "'B'", "}", ")", ";", "public", "final", "static", "BaseTypeBinding", "SHORT", "=", "new", "BaseTypeBinding", "(", "TypeIds", ".", "T_short", ",", "TypeConstants", ".", "SHORT", ",", "new", "char", "[", "]", "{", "'S'", "}", ")", ";", "public", "final", "static", "BaseTypeBinding", "CHAR", "=", "new", "BaseTypeBinding", "(", "TypeIds", ".", "T_char", ",", "TypeConstants", ".", "CHAR", ",", "new", "char", "[", "]", "{", "'C'", "}", ")", ";", "public", "final", "static", "BaseTypeBinding", "LONG", "=", "new", "BaseTypeBinding", "(", "TypeIds", ".", "T_long", ",", "TypeConstants", ".", "LONG", ",", "new", "char", "[", "]", "{", "'J'", "}", ")", ";", "public", "final", "static", "BaseTypeBinding", "FLOAT", "=", "new", "BaseTypeBinding", "(", "TypeIds", ".", "T_float", ",", "TypeConstants", ".", "FLOAT", ",", "new", "char", "[", "]", "{", "'F'", "}", ")", ";", "public", "final", "static", "BaseTypeBinding", "DOUBLE", "=", "new", "BaseTypeBinding", "(", "TypeIds", ".", "T_double", ",", "TypeConstants", ".", "DOUBLE", ",", "new", "char", "[", "]", "{", "'D'", "}", ")", ";", "public", "final", "static", "BaseTypeBinding", "BOOLEAN", "=", "new", "BaseTypeBinding", "(", "TypeIds", ".", "T_boolean", ",", "TypeConstants", ".", "BOOLEAN", ",", "new", "char", "[", "]", "{", "'Z'", "}", ")", ";", "public", "final", "static", "BaseTypeBinding", "NULL", "=", "new", "BaseTypeBinding", "(", "TypeIds", ".", "T_null", ",", "TypeConstants", ".", "NULL", ",", "new", "char", "[", "]", "{", "'N'", "}", ")", ";", "public", "final", "static", "BaseTypeBinding", "VOID", "=", "new", "BaseTypeBinding", "(", "TypeIds", ".", "T_void", ",", "TypeConstants", ".", "VOID", ",", "new", "char", "[", "]", "{", "'V'", "}", ")", ";", "public", "static", "final", "TypeBinding", "wellKnownType", "(", "Scope", "scope", ",", "int", "id", ")", "{", "switch", "(", "id", ")", "{", "case", "TypeIds", ".", "T_boolean", ":", "return", "TypeBinding", ".", "BOOLEAN", ";", "case", "TypeIds", ".", "T_byte", ":", "return", "TypeBinding", ".", "BYTE", ";", "case", "TypeIds", ".", "T_char", ":", "return", "TypeBinding", ".", "CHAR", ";", "case", "TypeIds", ".", "T_short", ":", "return", "TypeBinding", ".", "SHORT", ";", "case", "TypeIds", ".", "T_double", ":", "return", "TypeBinding", ".", "DOUBLE", ";", "case", "TypeIds", ".", "T_float", ":", "return", "TypeBinding", ".", "FLOAT", ";", "case", "TypeIds", ".", "T_int", ":", "return", "TypeBinding", ".", "INT", ";", "case", "TypeIds", ".", "T_long", ":", "return", "TypeBinding", ".", "LONG", ";", "case", "TypeIds", ".", "T_JavaLangObject", ":", "return", "scope", ".", "getJavaLangObject", "(", ")", ";", "case", "TypeIds", ".", "T_JavaLangString", ":", "return", "scope", ".", "getJavaLangString", "(", ")", ";", "default", ":", "return", "null", ";", "}", "}", "public", "boolean", "canBeInstantiated", "(", ")", "{", "return", "!", "isBaseType", "(", ")", ";", "}", "public", "TypeBinding", "capture", "(", "Scope", "scope", ",", "int", "position", ")", "{", "return", "this", ";", "}", "public", "TypeBinding", "closestMatch", "(", ")", "{", "return", "this", ";", "}", "public", "List", "collectMissingTypes", "(", "List", "missingTypes", ")", "{", "return", "missingTypes", ";", "}", "public", "void", "collectSubstitutes", "(", "Scope", "scope", ",", "TypeBinding", "actualType", ",", "InferenceContext", "inferenceContext", ",", "int", "constraint", ")", "{", "}", "public", "abstract", "char", "[", "]", "constantPoolName", "(", ")", ";", "public", "String", "debugName", "(", ")", "{", "return", "new", "String", "(", "readableName", "(", ")", ")", ";", "}", "public", "int", "dimensions", "(", ")", "{", "return", "0", ";", "}", "public", "ReferenceBinding", "enclosingType", "(", ")", "{", "return", "null", ";", "}", "public", "TypeBinding", "erasure", "(", ")", "{", "return", "this", ";", "}", "public", "ReferenceBinding", "findSuperTypeOriginatingFrom", "(", "int", "wellKnownOriginalID", ",", "boolean", "originalIsClass", ")", "{", "if", "(", "!", "(", "this", "instanceof", "ReferenceBinding", ")", ")", "return", "null", ";", "ReferenceBinding", "reference", "=", "(", "ReferenceBinding", ")", "this", ";", "if", "(", "reference", ".", "id", "==", "wellKnownOriginalID", "||", "(", "original", "(", ")", ".", "id", "==", "wellKnownOriginalID", ")", ")", "return", "reference", ";", "ReferenceBinding", "currentType", "=", "reference", ";", "if", "(", "originalIsClass", ")", "{", "while", "(", "(", "currentType", "=", "currentType", ".", "superclass", "(", ")", ")", "!=", "null", ")", "{", "if", "(", "currentType", ".", "id", "==", "wellKnownOriginalID", ")", "return", "currentType", ";", "if", "(", "currentType", ".", "original", "(", ")", ".", "id", "==", "wellKnownOriginalID", ")", "return", "currentType", ";", "}", "return", "null", ";", "}", "ReferenceBinding", "[", "]", "interfacesToVisit", "=", "null", ";", "int", "nextPosition", "=", "0", ";", "do", "{", "ReferenceBinding", "[", "]", "itsInterfaces", "=", "currentType", ".", "superInterfaces", "(", ")", ";", "if", "(", "itsInterfaces", "!=", "null", "&&", "itsInterfaces", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "if", "(", "interfacesToVisit", "==", "null", ")", "{", "interfacesToVisit", "=", "itsInterfaces", ";", "nextPosition", "=", "interfacesToVisit", ".", "length", ";", "}", "else", "{", "int", "itsLength", "=", "itsInterfaces", ".", "length", ";", "if", "(", "nextPosition", "+", "itsLength", ">=", "interfacesToVisit", ".", "length", ")", "System", ".", "arraycopy", "(", "interfacesToVisit", ",", "0", ",", "interfacesToVisit", "=", "new", "ReferenceBinding", "[", "nextPosition", "+", "itsLength", "+", "5", "]", ",", "0", ",", "nextPosition", ")", ";", "nextInterface", ":", "for", "(", "int", "a", "=", "0", ";", "a", "<", "itsLength", ";", "a", "++", ")", "{", "ReferenceBinding", "next", "=", "itsInterfaces", "[", "a", "]", ";", "for", "(", "int", "b", "=", "0", ";", "b", "<", "nextPosition", ";", "b", "++", ")", "if", "(", "next", "==", "interfacesToVisit", "[", "b", "]", ")", "continue", "nextInterface", ";", "interfacesToVisit", "[", "nextPosition", "++", "]", "=", "next", ";", "}", "}", "}", "}", "while", "(", "(", "currentType", "=", "currentType", ".", "superclass", "(", ")", ")", "!=", "null", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "nextPosition", ";", "i", "++", ")", "{", "currentType", "=", "interfacesToVisit", "[", "i", "]", ";", "if", "(", "currentType", ".", "id", "==", "wellKnownOriginalID", ")", "return", "currentType", ";", "if", "(", "currentType", ".", "original", "(", ")", ".", "id", "==", "wellKnownOriginalID", ")", "return", "currentType", ";", "ReferenceBinding", "[", "]", "itsInterfaces", "=", "currentType", ".", "superInterfaces", "(", ")", ";", "if", "(", "itsInterfaces", "!=", "null", "&&", "itsInterfaces", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "int", "itsLength", "=", "itsInterfaces", ".", "length", ";", "if", "(", "nextPosition", "+", "itsLength", ">=", "interfacesToVisit", ".", "length", ")", "System", ".", "arraycopy", "(", "interfacesToVisit", ",", "0", ",", "interfacesToVisit", "=", "new", "ReferenceBinding", "[", "nextPosition", "+", "itsLength", "+", "5", "]", ",", "0", ",", "nextPosition", ")", ";", "nextInterface", ":", "for", "(", "int", "a", "=", "0", ";", "a", "<", "itsLength", ";", "a", "++", ")", "{", "ReferenceBinding", "next", "=", "itsInterfaces", "[", "a", "]", ";", "for", "(", "int", "b", "=", "0", ";", "b", "<", "nextPosition", ";", "b", "++", ")", "if", "(", "next", "==", "interfacesToVisit", "[", "b", "]", ")", "continue", "nextInterface", ";", "interfacesToVisit", "[", "nextPosition", "++", "]", "=", "next", ";", "}", "}", "}", "return", "null", ";", "}", "public", "TypeBinding", "findSuperTypeOriginatingFrom", "(", "TypeBinding", "otherType", ")", "{", "if", "(", "this", "==", "otherType", ")", "return", "this", ";", "if", "(", "otherType", "==", "null", ")", "return", "null", ";", "switch", "(", "kind", "(", ")", ")", "{", "case", "Binding", ".", "ARRAY_TYPE", ":", "ArrayBinding", "arrayType", "=", "(", "ArrayBinding", ")", "this", ";", "int", "otherDim", "=", "otherType", ".", "dimensions", "(", ")", ";", "if", "(", "arrayType", ".", "dimensions", "!=", "otherDim", ")", "{", "switch", "(", "otherType", ".", "id", ")", "{", "case", "TypeIds", ".", "T_JavaLangObject", ":", "case", "TypeIds", ".", "T_JavaIoSerializable", ":", "case", "TypeIds", ".", "T_JavaLangCloneable", ":", "return", "otherType", ";", "}", "if", "(", "otherDim", "<", "arrayType", ".", "dimensions", "&&", "otherType", ".", "leafComponentType", "(", ")", ".", "id", "==", "TypeIds", ".", "T_JavaLangObject", ")", "{", "return", "otherType", ";", "}", "return", "null", ";", "}", "if", "(", "!", "(", "arrayType", ".", "leafComponentType", "instanceof", "ReferenceBinding", ")", ")", "return", "null", ";", "TypeBinding", "leafSuperType", "=", "arrayType", ".", "leafComponentType", ".", "findSuperTypeOriginatingFrom", "(", "otherType", ".", "leafComponentType", "(", ")", ")", ";", "if", "(", "leafSuperType", "==", "null", ")", "return", "null", ";", "return", "arrayType", ".", "environment", "(", ")", ".", "createArrayType", "(", "leafSuperType", ",", "arrayType", ".", "dimensions", ")", ";", "case", "Binding", ".", "TYPE_PARAMETER", ":", "if", "(", "isCapture", "(", ")", ")", "{", "CaptureBinding", "capture", "=", "(", "CaptureBinding", ")", "this", ";", "TypeBinding", "captureBound", "=", "capture", ".", "firstBound", ";", "if", "(", "captureBound", "instanceof", "ArrayBinding", ")", "{", "TypeBinding", "match", "=", "captureBound", ".", "findSuperTypeOriginatingFrom", "(", "otherType", ")", ";", "if", "(", "match", "!=", "null", ")", "return", "match", ";", "}", "}", "case", "Binding", ".", "TYPE", ":", "case", "Binding", ".", "PARAMETERIZED_TYPE", ":", "case", "Binding", ".", "GENERIC_TYPE", ":", "case", "Binding", ".", "RAW_TYPE", ":", "case", "Binding", ".", "WILDCARD_TYPE", ":", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "otherType", "=", "otherType", ".", "original", "(", ")", ";", "if", "(", "this", "==", "otherType", ")", "return", "this", ";", "if", "(", "original", "(", ")", "==", "otherType", ")", "return", "this", ";", "ReferenceBinding", "currentType", "=", "(", "ReferenceBinding", ")", "this", ";", "if", "(", "!", "otherType", ".", "isInterface", "(", ")", ")", "{", "while", "(", "(", "currentType", "=", "currentType", ".", "superclass", "(", ")", ")", "!=", "null", ")", "{", "if", "(", "currentType", "==", "otherType", ")", "return", "currentType", ";", "if", "(", "currentType", ".", "original", "(", ")", "==", "otherType", ")", "return", "currentType", ";", "}", "return", "null", ";", "}", "ReferenceBinding", "[", "]", "interfacesToVisit", "=", "null", ";", "int", "nextPosition", "=", "0", ";", "do", "{", "ReferenceBinding", "[", "]", "itsInterfaces", "=", "currentType", ".", "superInterfaces", "(", ")", ";", "if", "(", "itsInterfaces", "!=", "null", "&&", "itsInterfaces", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "if", "(", "interfacesToVisit", "==", "null", ")", "{", "interfacesToVisit", "=", "itsInterfaces", ";", "nextPosition", "=", "interfacesToVisit", ".", "length", ";", "}", "else", "{", "int", "itsLength", "=", "itsInterfaces", ".", "length", ";", "if", "(", "nextPosition", "+", "itsLength", ">=", "interfacesToVisit", ".", "length", ")", "System", ".", "arraycopy", "(", "interfacesToVisit", ",", "0", ",", "interfacesToVisit", "=", "new", "ReferenceBinding", "[", "nextPosition", "+", "itsLength", "+", "5", "]", ",", "0", ",", "nextPosition", ")", ";", "nextInterface", ":", "for", "(", "int", "a", "=", "0", ";", "a", "<", "itsLength", ";", "a", "++", ")", "{", "ReferenceBinding", "next", "=", "itsInterfaces", "[", "a", "]", ";", "for", "(", "int", "b", "=", "0", ";", "b", "<", "nextPosition", ";", "b", "++", ")", "if", "(", "next", "==", "interfacesToVisit", "[", "b", "]", ")", "continue", "nextInterface", ";", "interfacesToVisit", "[", "nextPosition", "++", "]", "=", "next", ";", "}", "}", "}", "}", "while", "(", "(", "currentType", "=", "currentType", ".", "superclass", "(", ")", ")", "!=", "null", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "nextPosition", ";", "i", "++", ")", "{", "currentType", "=", "interfacesToVisit", "[", "i", "]", ";", "if", "(", "currentType", "==", "otherType", ")", "return", "currentType", ";", "if", "(", "currentType", ".", "original", "(", ")", "==", "otherType", ")", "return", "currentType", ";", "ReferenceBinding", "[", "]", "itsInterfaces", "=", "currentType", ".", "superInterfaces", "(", ")", ";", "if", "(", "itsInterfaces", "!=", "null", "&&", "itsInterfaces", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "int", "itsLength", "=", "itsInterfaces", ".", "length", ";", "if", "(", "nextPosition", "+", "itsLength", ">=", "interfacesToVisit", ".", "length", ")", "System", ".", "arraycopy", "(", "interfacesToVisit", ",", "0", ",", "interfacesToVisit", "=", "new", "ReferenceBinding", "[", "nextPosition", "+", "itsLength", "+", "5", "]", ",", "0", ",", "nextPosition", ")", ";", "nextInterface", ":", "for", "(", "int", "a", "=", "0", ";", "a", "<", "itsLength", ";", "a", "++", ")", "{", "ReferenceBinding", "next", "=", "itsInterfaces", "[", "a", "]", ";", "for", "(", "int", "b", "=", "0", ";", "b", "<", "nextPosition", ";", "b", "++", ")", "if", "(", "next", "==", "interfacesToVisit", "[", "b", "]", ")", "continue", "nextInterface", ";", "interfacesToVisit", "[", "nextPosition", "++", "]", "=", "next", ";", "}", "}", "}", "}", "return", "null", ";", "}", "public", "TypeBinding", "genericCast", "(", "TypeBinding", "targetType", ")", "{", "if", "(", "this", "==", "targetType", ")", "return", "null", ";", "TypeBinding", "targetErasure", "=", "targetType", ".", "erasure", "(", ")", ";", "if", "(", "erasure", "(", ")", ".", "findSuperTypeOriginatingFrom", "(", "targetErasure", ")", "!=", "null", ")", "return", "null", ";", "return", "targetErasure", ";", "}", "public", "char", "[", "]", "genericTypeSignature", "(", ")", "{", "return", "signature", "(", ")", ";", "}", "public", "TypeBinding", "getErasureCompatibleType", "(", "TypeBinding", "declaringClass", ")", "{", "switch", "(", "kind", "(", ")", ")", "{", "case", "Binding", ".", "TYPE_PARAMETER", ":", "TypeVariableBinding", "variable", "=", "(", "TypeVariableBinding", ")", "this", ";", "if", "(", "variable", ".", "erasure", "(", ")", ".", "findSuperTypeOriginatingFrom", "(", "declaringClass", ")", "!=", "null", ")", "{", "return", "this", ";", "}", "if", "(", "variable", ".", "superclass", "!=", "null", "&&", "variable", ".", "superclass", ".", "findSuperTypeOriginatingFrom", "(", "declaringClass", ")", "!=", "null", ")", "{", "return", "variable", ".", "superclass", ".", "getErasureCompatibleType", "(", "declaringClass", ")", ";", "}", "for", "(", "int", "i", "=", "0", ",", "otherLength", "=", "variable", ".", "superInterfaces", ".", "length", ";", "i", "<", "otherLength", ";", "i", "++", ")", "{", "ReferenceBinding", "superInterface", "=", "variable", ".", "superInterfaces", "[", "i", "]", ";", "if", "(", "superInterface", ".", "findSuperTypeOriginatingFrom", "(", "declaringClass", ")", "!=", "null", ")", "{", "return", "superInterface", ".", "getErasureCompatibleType", "(", "declaringClass", ")", ";", "}", "}", "return", "this", ";", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "WildcardBinding", "intersection", "=", "(", "WildcardBinding", ")", "this", ";", "if", "(", "intersection", ".", "erasure", "(", ")", ".", "findSuperTypeOriginatingFrom", "(", "declaringClass", ")", "!=", "null", ")", "{", "return", "this", ";", "}", "if", "(", "intersection", ".", "superclass", "!=", "null", "&&", "intersection", ".", "superclass", ".", "findSuperTypeOriginatingFrom", "(", "declaringClass", ")", "!=", "null", ")", "{", "return", "intersection", ".", "superclass", ".", "getErasureCompatibleType", "(", "declaringClass", ")", ";", "}", "for", "(", "int", "i", "=", "0", ",", "otherLength", "=", "intersection", ".", "superInterfaces", ".", "length", ";", "i", "<", "otherLength", ";", "i", "++", ")", "{", "ReferenceBinding", "superInterface", "=", "intersection", ".", "superInterfaces", "[", "i", "]", ";", "if", "(", "superInterface", ".", "findSuperTypeOriginatingFrom", "(", "declaringClass", ")", "!=", "null", ")", "{", "return", "superInterface", ".", "getErasureCompatibleType", "(", "declaringClass", ")", ";", "}", "}", "return", "this", ";", "default", ":", "return", "this", ";", "}", "}", "public", "abstract", "PackageBinding", "getPackage", "(", ")", ";", "void", "initializeForStaticImports", "(", ")", "{", "}", "public", "boolean", "isAnnotationType", "(", ")", "{", "return", "false", ";", "}", "public", "final", "boolean", "isAnonymousType", "(", ")", "{", "return", "(", "this", ".", "tagBits", "&", "TagBits", ".", "IsAnonymousType", ")", "!=", "0", ";", "}", "public", "final", "boolean", "isArrayType", "(", ")", "{", "return", "(", "this", ".", "tagBits", "&", "TagBits", ".", "IsArrayType", ")", "!=", "0", ";", "}", "public", "final", "boolean", "isBaseType", "(", ")", "{", "return", "(", "this", ".", "tagBits", "&", "TagBits", ".", "IsBaseType", ")", "!=", "0", ";", "}", "public", "boolean", "isBoundParameterizedType", "(", ")", "{", "return", "(", "this", ".", "tagBits", "&", "TagBits", ".", "IsBoundParameterizedType", ")", "!=", "0", ";", "}", "public", "boolean", "isCapture", "(", ")", "{", "return", "false", ";", "}", "public", "boolean", "isClass", "(", ")", "{", "return", "false", ";", "}", "public", "abstract", "boolean", "isCompatibleWith", "(", "TypeBinding", "right", ")", ";", "public", "boolean", "isEnum", "(", ")", "{", "return", "false", ";", "}", "public", "boolean", "isEquivalentTo", "(", "TypeBinding", "otherType", ")", "{", "if", "(", "this", "==", "otherType", ")", "return", "true", ";", "if", "(", "otherType", "==", "null", ")", "return", "false", ";", "switch", "(", "otherType", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "WILDCARD_TYPE", ":", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "return", "(", "(", "WildcardBinding", ")", "otherType", ")", ".", "boundCheck", "(", "this", ")", ";", "}", "return", "false", ";", "}", "public", "boolean", "isGenericType", "(", ")", "{", "return", "false", ";", "}", "public", "final", "boolean", "isHierarchyInconsistent", "(", ")", "{", "return", "(", "this", ".", "tagBits", "&", "TagBits", ".", "HierarchyHasProblems", ")", "!=", "0", ";", "}", "public", "boolean", "isInterface", "(", ")", "{", "return", "false", ";", "}", "public", "boolean", "isIntersectionType", "(", ")", "{", "return", "false", ";", "}", "public", "final", "boolean", "isLocalType", "(", ")", "{", "return", "(", "this", ".", "tagBits", "&", "TagBits", ".", "IsLocalType", ")", "!=", "0", ";", "}", "public", "final", "boolean", "isMemberType", "(", ")", "{", "return", "(", "this", ".", "tagBits", "&", "TagBits", ".", "IsMemberType", ")", "!=", "0", ";", "}", "public", "final", "boolean", "isNestedType", "(", ")", "{", "return", "(", "this", ".", "tagBits", "&", "TagBits", ".", "IsNestedType", ")", "!=", "0", ";", "}", "public", "final", "boolean", "isNumericType", "(", ")", "{", "switch", "(", "this", ".", "id", ")", "{", "case", "TypeIds", ".", "T_int", ":", "case", "TypeIds", ".", "T_float", ":", "case", "TypeIds", ".", "T_double", ":", "case", "TypeIds", ".", "T_short", ":", "case", "TypeIds", ".", "T_byte", ":", "case", "TypeIds", ".", "T_long", ":", "case", "TypeIds", ".", "T_char", ":", "return", "true", ";", "default", ":", "return", "false", ";", "}", "}", "public", "final", "boolean", "isParameterizedType", "(", ")", "{", "return", "kind", "(", ")", "==", "Binding", ".", "PARAMETERIZED_TYPE", ";", "}", "public", "final", "boolean", "isParameterizedTypeWithActualArguments", "(", ")", "{", "return", "(", "kind", "(", ")", "==", "Binding", ".", "PARAMETERIZED_TYPE", ")", "&&", "(", "(", "ParameterizedTypeBinding", ")", "this", ")", ".", "arguments", "!=", "null", ";", "}", "public", "boolean", "isParameterizedWithOwnVariables", "(", ")", "{", "if", "(", "kind", "(", ")", "!=", "Binding", ".", "PARAMETERIZED_TYPE", ")", "return", "false", ";", "ParameterizedTypeBinding", "paramType", "=", "(", "ParameterizedTypeBinding", ")", "this", ";", "if", "(", "paramType", ".", "arguments", "==", "null", ")", "return", "false", ";", "TypeVariableBinding", "[", "]", "variables", "=", "erasure", "(", ")", ".", "typeVariables", "(", ")", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "variables", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "variables", "[", "i", "]", "!=", "paramType", ".", "arguments", "[", "i", "]", ")", "return", "false", ";", "}", "ReferenceBinding", "enclosing", "=", "paramType", ".", "enclosingType", "(", ")", ";", "if", "(", "enclosing", "!=", "null", "&&", "enclosing", ".", "erasure", "(", ")", ".", "isGenericType", "(", ")", "&&", "!", "enclosing", ".", "isParameterizedWithOwnVariables", "(", ")", ")", "{", "return", "false", ";", "}", "return", "true", ";", "}", "private", "boolean", "isProvableDistinctSubType", "(", "TypeBinding", "otherType", ")", "{", "if", "(", "otherType", ".", "isInterface", "(", ")", ")", "{", "if", "(", "isInterface", "(", ")", ")", "return", "false", ";", "if", "(", "isArrayType", "(", ")", "||", "(", "(", "this", "instanceof", "ReferenceBinding", ")", "&&", "(", "(", "ReferenceBinding", ")", "this", ")", ".", "isFinal", "(", ")", ")", "||", "(", "isTypeVariable", "(", ")", "&&", "(", "(", "TypeVariableBinding", ")", "this", ")", ".", "superclass", "(", ")", ".", "isFinal", "(", ")", ")", ")", "{", "return", "!", "isCompatibleWith", "(", "otherType", ")", ";", "}", "return", "false", ";", "}", "else", "{", "if", "(", "isInterface", "(", ")", ")", "{", "if", "(", "otherType", ".", "isArrayType", "(", ")", "||", "(", "(", "otherType", "instanceof", "ReferenceBinding", ")", "&&", "(", "(", "ReferenceBinding", ")", "otherType", ")", ".", "isFinal", "(", ")", ")", "||", "(", "otherType", ".", "isTypeVariable", "(", ")", "&&", "(", "(", "TypeVariableBinding", ")", "otherType", ")", ".", "superclass", "(", ")", ".", "isFinal", "(", ")", ")", ")", "{", "return", "!", "isCompatibleWith", "(", "otherType", ")", ";", "}", "}", "else", "{", "if", "(", "!", "isTypeVariable", "(", ")", "&&", "!", "otherType", ".", "isTypeVariable", "(", ")", ")", "{", "return", "!", "isCompatibleWith", "(", "otherType", ")", ";", "}", "}", "}", "return", "false", ";", "}", "public", "boolean", "isProvablyDistinct", "(", "TypeBinding", "otherType", ")", "{", "if", "(", "this", "==", "otherType", ")", "return", "false", ";", "if", "(", "otherType", "==", "null", ")", "return", "true", ";", "switch", "(", "kind", "(", ")", ")", "{", "case", "Binding", ".", "PARAMETERIZED_TYPE", ":", "ParameterizedTypeBinding", "paramType", "=", "(", "ParameterizedTypeBinding", ")", "this", ";", "switch", "(", "otherType", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "PARAMETERIZED_TYPE", ":", "ParameterizedTypeBinding", "otherParamType", "=", "(", "ParameterizedTypeBinding", ")", "otherType", ";", "if", "(", "paramType", ".", "genericType", "(", ")", "!=", "otherParamType", ".", "genericType", "(", ")", ")", "return", "true", ";", "if", "(", "!", "paramType", ".", "isStatic", "(", ")", ")", "{", "ReferenceBinding", "enclosing", "=", "enclosingType", "(", ")", ";", "if", "(", "enclosing", "!=", "null", ")", "{", "ReferenceBinding", "otherEnclosing", "=", "otherParamType", ".", "enclosingType", "(", ")", ";", "if", "(", "otherEnclosing", "==", "null", ")", "return", "true", ";", "if", "(", "(", "otherEnclosing", ".", "tagBits", "&", "TagBits", ".", "HasDirectWildcard", ")", "==", "0", ")", "{", "if", "(", "enclosing", ".", "isProvablyDistinct", "(", "otherEnclosing", ")", ")", "return", "true", ";", "}", "else", "{", "if", "(", "!", "enclosing", ".", "isEquivalentTo", "(", "otherParamType", ".", "enclosingType", "(", ")", ")", ")", "return", "true", ";", "}", "}", "}", "int", "length", "=", "paramType", ".", "arguments", "==", "null", "?", "0", ":", "paramType", ".", "arguments", ".", "length", ";", "TypeBinding", "[", "]", "otherArguments", "=", "otherParamType", ".", "arguments", ";", "int", "otherLength", "=", "otherArguments", "==", "null", "?", "0", ":", "otherArguments", ".", "length", ";", "if", "(", "otherLength", "!=", "length", ")", "return", "true", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "paramType", ".", "arguments", "[", "i", "]", ".", "isProvablyDistinctTypeArgument", "(", "otherArguments", "[", "i", "]", ",", "paramType", ",", "i", ")", ")", "return", "true", ";", "}", "return", "false", ";", "case", "Binding", ".", "GENERIC_TYPE", ":", "SourceTypeBinding", "otherGenericType", "=", "(", "SourceTypeBinding", ")", "otherType", ";", "if", "(", "paramType", ".", "genericType", "(", ")", "!=", "otherGenericType", ")", "return", "true", ";", "if", "(", "!", "paramType", ".", "isStatic", "(", ")", ")", "{", "ReferenceBinding", "enclosing", "=", "enclosingType", "(", ")", ";", "if", "(", "enclosing", "!=", "null", ")", "{", "ReferenceBinding", "otherEnclosing", "=", "otherGenericType", ".", "enclosingType", "(", ")", ";", "if", "(", "otherEnclosing", "==", "null", ")", "return", "true", ";", "if", "(", "(", "otherEnclosing", ".", "tagBits", "&", "TagBits", ".", "HasDirectWildcard", ")", "==", "0", ")", "{", "if", "(", "enclosing", "!=", "otherEnclosing", ")", "return", "true", ";", "}", "else", "{", "if", "(", "!", "enclosing", ".", "isEquivalentTo", "(", "otherGenericType", ".", "enclosingType", "(", ")", ")", ")", "return", "true", ";", "}", "}", "}", "length", "=", "paramType", ".", "arguments", "==", "null", "?", "0", ":", "paramType", ".", "arguments", ".", "length", ";", "otherArguments", "=", "otherGenericType", ".", "typeVariables", "(", ")", ";", "otherLength", "=", "otherArguments", "==", "null", "?", "0", ":", "otherArguments", ".", "length", ";", "if", "(", "otherLength", "!=", "length", ")", "return", "true", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "paramType", ".", "arguments", "[", "i", "]", ".", "isProvablyDistinctTypeArgument", "(", "otherArguments", "[", "i", "]", ",", "paramType", ",", "i", ")", ")", "return", "true", ";", "}", "return", "false", ";", "case", "Binding", ".", "RAW_TYPE", ":", "return", "erasure", "(", ")", "!=", "otherType", ".", "erasure", "(", ")", ";", "}", "return", "true", ";", "case", "Binding", ".", "RAW_TYPE", ":", "switch", "(", "otherType", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "GENERIC_TYPE", ":", "case", "Binding", ".", "PARAMETERIZED_TYPE", ":", "case", "Binding", ".", "RAW_TYPE", ":", "return", "erasure", "(", ")", "!=", "otherType", ".", "erasure", "(", ")", ";", "}", "return", "true", ";", "default", ":", "break", ";", "}", "return", "true", ";", "}", "private", "boolean", "isProvablyDistinctTypeArgument", "(", "TypeBinding", "otherArgument", ",", "final", "ParameterizedTypeBinding", "paramType", ",", "final", "int", "rank", ")", "{", "if", "(", "this", "==", "otherArgument", ")", "return", "false", ";", "TypeBinding", "upperBound1", "=", "null", ";", "TypeBinding", "lowerBound1", "=", "null", ";", "switch", "(", "kind", "(", ")", ")", "{", "case", "Binding", ".", "WILDCARD_TYPE", ":", "WildcardBinding", "wildcard", "=", "(", "WildcardBinding", ")", "this", ";", "switch", "(", "wildcard", ".", "boundKind", ")", "{", "case", "Wildcard", ".", "EXTENDS", ":", "upperBound1", "=", "wildcard", ".", "bound", ";", "break", ";", "case", "Wildcard", ".", "SUPER", ":", "lowerBound1", "=", "wildcard", ".", "bound", ";", "break", ";", "case", "Wildcard", ".", "UNBOUND", ":", "return", "false", ";", "}", "break", ";", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "break", ";", "case", "Binding", ".", "TYPE_PARAMETER", ":", "final", "TypeVariableBinding", "variable", "=", "(", "TypeVariableBinding", ")", "this", ";", "if", "(", "variable", ".", "isCapture", "(", ")", ")", "{", "CaptureBinding", "capture", "=", "(", "CaptureBinding", ")", "variable", ";", "switch", "(", "capture", ".", "wildcard", ".", "boundKind", ")", "{", "case", "Wildcard", ".", "EXTENDS", ":", "upperBound1", "=", "capture", ".", "wildcard", ".", "bound", ";", "break", ";", "case", "Wildcard", ".", "SUPER", ":", "lowerBound1", "=", "capture", ".", "wildcard", ".", "bound", ";", "break", ";", "case", "Wildcard", ".", "UNBOUND", ":", "return", "false", ";", "}", "break", ";", "}", "if", "(", "variable", ".", "firstBound", "==", "null", ")", "return", "false", ";", "TypeBinding", "eliminatedType", "=", "Scope", ".", "convertEliminatingTypeVariables", "(", "variable", ",", "paramType", ".", "genericType", "(", ")", ",", "rank", ",", "null", ")", ";", "switch", "(", "eliminatedType", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "WILDCARD_TYPE", ":", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "wildcard", "=", "(", "WildcardBinding", ")", "eliminatedType", ";", "switch", "(", "wildcard", ".", "boundKind", ")", "{", "case", "Wildcard", ".", "EXTENDS", ":", "upperBound1", "=", "wildcard", ".", "bound", ";", "break", ";", "case", "Wildcard", ".", "SUPER", ":", "lowerBound1", "=", "wildcard", ".", "bound", ";", "break", ";", "case", "Wildcard", ".", "UNBOUND", ":", "return", "false", ";", "}", "break", ";", "}", "break", ";", "}", "TypeBinding", "upperBound2", "=", "null", ";", "TypeBinding", "lowerBound2", "=", "null", ";", "switch", "(", "otherArgument", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "WILDCARD_TYPE", ":", "WildcardBinding", "otherWildcard", "=", "(", "WildcardBinding", ")", "otherArgument", ";", "switch", "(", "otherWildcard", ".", "boundKind", ")", "{", "case", "Wildcard", ".", "EXTENDS", ":", "upperBound2", "=", "otherWildcard", ".", "bound", ";", "break", ";", "case", "Wildcard", ".", "SUPER", ":", "lowerBound2", "=", "otherWildcard", ".", "bound", ";", "break", ";", "case", "Wildcard", ".", "UNBOUND", ":", "return", "false", ";", "}", "break", ";", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "break", ";", "case", "Binding", ".", "TYPE_PARAMETER", ":", "TypeVariableBinding", "otherVariable", "=", "(", "TypeVariableBinding", ")", "otherArgument", ";", "if", "(", "otherVariable", ".", "isCapture", "(", ")", ")", "{", "CaptureBinding", "otherCapture", "=", "(", "CaptureBinding", ")", "otherVariable", ";", "switch", "(", "otherCapture", ".", "wildcard", ".", "boundKind", ")", "{", "case", "Wildcard", ".", "EXTENDS", ":", "upperBound2", "=", "otherCapture", ".", "wildcard", ".", "bound", ";", "break", ";", "case", "Wildcard", ".", "SUPER", ":", "lowerBound2", "=", "otherCapture", ".", "wildcard", ".", "bound", ";", "break", ";", "case", "Wildcard", ".", "UNBOUND", ":", "return", "false", ";", "}", "break", ";", "}", "if", "(", "otherVariable", ".", "firstBound", "==", "null", ")", "return", "false", ";", "TypeBinding", "otherEliminatedType", "=", "Scope", ".", "convertEliminatingTypeVariables", "(", "otherVariable", ",", "paramType", ".", "genericType", "(", ")", ",", "rank", ",", "null", ")", ";", "switch", "(", "otherEliminatedType", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "WILDCARD_TYPE", ":", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "otherWildcard", "=", "(", "WildcardBinding", ")", "otherEliminatedType", ";", "switch", "(", "otherWildcard", ".", "boundKind", ")", "{", "case", "Wildcard", ".", "EXTENDS", ":", "upperBound2", "=", "otherWildcard", ".", "bound", ";", "break", ";", "case", "Wildcard", ".", "SUPER", ":", "lowerBound2", "=", "otherWildcard", ".", "bound", ";", "break", ";", "case", "Wildcard", ".", "UNBOUND", ":", "return", "false", ";", "}", "break", ";", "}", "break", ";", "}", "if", "(", "lowerBound1", "!=", "null", ")", "{", "if", "(", "lowerBound2", "!=", "null", ")", "{", "return", "false", ";", "}", "else", "if", "(", "upperBound2", "!=", "null", ")", "{", "if", "(", "lowerBound1", ".", "isTypeVariable", "(", ")", "||", "upperBound2", ".", "isTypeVariable", "(", ")", ")", "{", "return", "false", ";", "}", "return", "!", "lowerBound1", ".", "isCompatibleWith", "(", "upperBound2", ")", ";", "}", "else", "{", "if", "(", "lowerBound1", ".", "isTypeVariable", "(", ")", "||", "otherArgument", ".", "isTypeVariable", "(", ")", ")", "{", "return", "false", ";", "}", "return", "!", "lowerBound1", ".", "isCompatibleWith", "(", "otherArgument", ")", ";", "}", "}", "else", "if", "(", "upperBound1", "!=", "null", ")", "{", "if", "(", "lowerBound2", "!=", "null", ")", "{", "return", "!", "lowerBound2", ".", "isCompatibleWith", "(", "upperBound1", ")", ";", "}", "else", "if", "(", "upperBound2", "!=", "null", ")", "{", "return", "upperBound1", ".", "isProvableDistinctSubType", "(", "upperBound2", ")", "&&", "upperBound2", ".", "isProvableDistinctSubType", "(", "upperBound1", ")", ";", "}", "else", "{", "return", "otherArgument", ".", "isProvableDistinctSubType", "(", "upperBound1", ")", ";", "}", "}", "else", "{", "if", "(", "lowerBound2", "!=", "null", ")", "{", "if", "(", "lowerBound2", ".", "isTypeVariable", "(", ")", "||", "isTypeVariable", "(", ")", ")", "{", "return", "false", ";", "}", "return", "!", "lowerBound2", ".", "isCompatibleWith", "(", "this", ")", ";", "}", "else", "if", "(", "upperBound2", "!=", "null", ")", "{", "return", "isProvableDistinctSubType", "(", "upperBound2", ")", ";", "}", "else", "{", "return", "true", ";", "}", "}", "}", "public", "final", "boolean", "isRawType", "(", ")", "{", "return", "kind", "(", ")", "==", "Binding", ".", "RAW_TYPE", ";", "}", "public", "boolean", "isReifiable", "(", ")", "{", "TypeBinding", "leafType", "=", "leafComponentType", "(", ")", ";", "if", "(", "!", "(", "leafType", "instanceof", "ReferenceBinding", ")", ")", "return", "true", ";", "ReferenceBinding", "current", "=", "(", "ReferenceBinding", ")", "leafType", ";", "do", "{", "switch", "(", "current", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "TYPE_PARAMETER", ":", "case", "Binding", ".", "WILDCARD_TYPE", ":", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "case", "Binding", ".", "GENERIC_TYPE", ":", "return", "false", ";", "case", "Binding", ".", "PARAMETERIZED_TYPE", ":", "if", "(", "current", ".", "isBoundParameterizedType", "(", ")", ")", "return", "false", ";", "break", ";", "case", "Binding", ".", "RAW_TYPE", ":", "return", "true", ";", "}", "if", "(", "current", ".", "isStatic", "(", ")", ")", "{", "return", "true", ";", "}", "if", "(", "current", ".", "isLocalType", "(", ")", ")", "{", "LocalTypeBinding", "localTypeBinding", "=", "(", "LocalTypeBinding", ")", "current", ".", "erasure", "(", ")", ";", "MethodBinding", "enclosingMethod", "=", "localTypeBinding", ".", "enclosingMethod", ";", "if", "(", "enclosingMethod", "!=", "null", "&&", "enclosingMethod", ".", "isStatic", "(", ")", ")", "{", "return", "true", ";", "}", "}", "}", "while", "(", "(", "current", "=", "current", ".", "enclosingType", "(", ")", ")", "!=", "null", ")", ";", "return", "true", ";", "}", "public", "boolean", "isThrowable", "(", ")", "{", "return", "false", ";", "}", "public", "boolean", "isTypeArgumentContainedBy", "(", "TypeBinding", "otherType", ")", "{", "if", "(", "this", "==", "otherType", ")", "return", "true", ";", "switch", "(", "otherType", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "WILDCARD_TYPE", ":", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "TypeBinding", "lowerBound", "=", "this", ";", "TypeBinding", "upperBound", "=", "this", ";", "switch", "(", "kind", "(", ")", ")", "{", "case", "Binding", ".", "WILDCARD_TYPE", ":", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "WildcardBinding", "wildcard", "=", "(", "WildcardBinding", ")", "this", ";", "switch", "(", "wildcard", ".", "boundKind", ")", "{", "case", "Wildcard", ".", "EXTENDS", ":", "if", "(", "wildcard", ".", "otherBounds", "!=", "null", ")", "break", ";", "upperBound", "=", "wildcard", ".", "bound", ";", "lowerBound", "=", "null", ";", "break", ";", "case", "Wildcard", ".", "SUPER", ":", "upperBound", "=", "wildcard", ";", "lowerBound", "=", "wildcard", ".", "bound", ";", "break", ";", "case", "Wildcard", ".", "UNBOUND", ":", "upperBound", "=", "wildcard", ";", "lowerBound", "=", "null", ";", "}", "break", ";", "case", "Binding", ".", "TYPE_PARAMETER", ":", "if", "(", "isCapture", "(", ")", ")", "{", "CaptureBinding", "capture", "=", "(", "CaptureBinding", ")", "this", ";", "if", "(", "capture", ".", "lowerBound", "!=", "null", ")", "lowerBound", "=", "capture", ".", "lowerBound", ";", "}", "}", "WildcardBinding", "otherWildcard", "=", "(", "WildcardBinding", ")", "otherType", ";", "if", "(", "otherWildcard", ".", "otherBounds", "!=", "null", ")", "return", "false", ";", "TypeBinding", "otherBound", "=", "otherWildcard", ".", "bound", ";", "switch", "(", "otherWildcard", ".", "boundKind", ")", "{", "case", "Wildcard", ".", "EXTENDS", ":", "if", "(", "otherBound", "==", "this", ")", "return", "true", ";", "if", "(", "upperBound", "==", "null", ")", "return", "false", ";", "TypeBinding", "match", "=", "upperBound", ".", "findSuperTypeOriginatingFrom", "(", "otherBound", ")", ";", "if", "(", "match", "!=", "null", "&&", "(", "match", "=", "match", ".", "leafComponentType", "(", ")", ")", ".", "isRawType", "(", ")", ")", "{", "return", "match", "==", "otherBound", ".", "leafComponentType", "(", ")", ";", "}", "return", "upperBound", ".", "isCompatibleWith", "(", "otherBound", ")", ";", "case", "Wildcard", ".", "SUPER", ":", "if", "(", "otherBound", "==", "this", ")", "return", "true", ";", "if", "(", "lowerBound", "==", "null", ")", "return", "false", ";", "match", "=", "otherBound", ".", "findSuperTypeOriginatingFrom", "(", "lowerBound", ")", ";", "if", "(", "match", "!=", "null", "&&", "(", "match", "=", "match", ".", "leafComponentType", "(", ")", ")", ".", "isRawType", "(", ")", ")", "{", "return", "match", "==", "lowerBound", ".", "leafComponentType", "(", ")", ";", "}", "return", "otherBound", ".", "isCompatibleWith", "(", "lowerBound", ")", ";", "case", "Wildcard", ".", "UNBOUND", ":", "default", ":", "return", "true", ";", "}", "case", "Binding", ".", "PARAMETERIZED_TYPE", ":", "if", "(", "!", "isParameterizedType", "(", ")", ")", "return", "false", ";", "ParameterizedTypeBinding", "paramType", "=", "(", "ParameterizedTypeBinding", ")", "this", ";", "ParameterizedTypeBinding", "otherParamType", "=", "(", "ParameterizedTypeBinding", ")", "otherType", ";", "if", "(", "paramType", ".", "actualType", "(", ")", "!=", "otherParamType", ".", "actualType", "(", ")", ")", "return", "false", ";", "if", "(", "!", "paramType", ".", "isStatic", "(", ")", ")", "{", "ReferenceBinding", "enclosing", "=", "enclosingType", "(", ")", ";", "if", "(", "enclosing", "!=", "null", ")", "{", "ReferenceBinding", "otherEnclosing", "=", "otherParamType", ".", "enclosingType", "(", ")", ";", "if", "(", "otherEnclosing", "==", "null", ")", "return", "false", ";", "if", "(", "(", "otherEnclosing", ".", "tagBits", "&", "TagBits", ".", "HasDirectWildcard", ")", "==", "0", ")", "{", "if", "(", "enclosing", "!=", "otherEnclosing", ")", "return", "false", ";", "}", "else", "{", "if", "(", "!", "enclosing", ".", "isEquivalentTo", "(", "otherParamType", ".", "enclosingType", "(", ")", ")", ")", "return", "false", ";", "}", "}", "}", "int", "length", "=", "paramType", ".", "arguments", "==", "null", "?", "0", ":", "paramType", ".", "arguments", ".", "length", ";", "TypeBinding", "[", "]", "otherArguments", "=", "otherParamType", ".", "arguments", ";", "int", "otherLength", "=", "otherArguments", "==", "null", "?", "0", ":", "otherArguments", ".", "length", ";", "if", "(", "otherLength", "!=", "length", ")", "return", "false", ";", "nextArgument", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeBinding", "argument", "=", "paramType", ".", "arguments", "[", "i", "]", ";", "TypeBinding", "otherArgument", "=", "otherArguments", "[", "i", "]", ";", "if", "(", "argument", "==", "otherArgument", ")", "continue", "nextArgument", ";", "int", "kind", "=", "argument", ".", "kind", "(", ")", ";", "if", "(", "otherArgument", ".", "kind", "(", ")", "!=", "kind", ")", "return", "false", ";", "switch", "(", "kind", ")", "{", "case", "Binding", ".", "PARAMETERIZED_TYPE", ":", "if", "(", "argument", ".", "isTypeArgumentContainedBy", "(", "otherArgument", ")", ")", "continue", "nextArgument", ";", "break", ";", "case", "Binding", ".", "WILDCARD_TYPE", ":", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "WildcardBinding", "wildcard", "=", "(", "WildcardBinding", ")", "argument", ";", "otherWildcard", "=", "(", "WildcardBinding", ")", "otherArgument", ";", "switch", "(", "wildcard", ".", "boundKind", ")", "{", "case", "Wildcard", ".", "EXTENDS", ":", "if", "(", "otherWildcard", ".", "boundKind", "==", "Wildcard", ".", "UNBOUND", "&&", "wildcard", ".", "bound", "==", "wildcard", ".", "typeVariable", "(", ")", ".", "upperBound", "(", ")", ")", "continue", "nextArgument", ";", "break", ";", "case", "Wildcard", ".", "SUPER", ":", "break", ";", "case", "Wildcard", ".", "UNBOUND", ":", "if", "(", "otherWildcard", ".", "boundKind", "==", "Wildcard", ".", "EXTENDS", "&&", "otherWildcard", ".", "bound", "==", "otherWildcard", ".", "typeVariable", "(", ")", ".", "upperBound", "(", ")", ")", "continue", "nextArgument", ";", "break", ";", "}", "break", ";", "}", "return", "false", ";", "}", "return", "true", ";", "}", "if", "(", "otherType", ".", "id", "==", "TypeIds", ".", "T_JavaLangObject", ")", "{", "switch", "(", "kind", "(", ")", ")", "{", "case", "Binding", ".", "WILDCARD_TYPE", ":", "WildcardBinding", "wildcard", "=", "(", "WildcardBinding", ")", "this", ";", "if", "(", "wildcard", ".", "boundKind", "==", "Wildcard", ".", "SUPER", "&&", "wildcard", ".", "bound", ".", "id", "==", "TypeIds", ".", "T_JavaLangObject", ")", "{", "return", "true", ";", "}", "break", ";", "}", "}", "return", "false", ";", "}", "public", "boolean", "isTypeVariable", "(", ")", "{", "return", "false", ";", "}", "public", "boolean", "isUnboundWildcard", "(", ")", "{", "return", "false", ";", "}", "public", "boolean", "isUncheckedException", "(", "boolean", "includeSupertype", ")", "{", "return", "false", ";", "}", "public", "boolean", "isWildcard", "(", ")", "{", "return", "false", ";", "}", "public", "int", "kind", "(", ")", "{", "return", "Binding", ".", "TYPE", ";", "}", "public", "TypeBinding", "leafComponentType", "(", ")", "{", "return", "this", ";", "}", "public", "boolean", "needsUncheckedConversion", "(", "TypeBinding", "targetType", ")", "{", "if", "(", "this", "==", "targetType", ")", "return", "false", ";", "targetType", "=", "targetType", ".", "leafComponentType", "(", ")", ";", "if", "(", "!", "(", "targetType", "instanceof", "ReferenceBinding", ")", ")", "return", "false", ";", "TypeBinding", "currentType", "=", "leafComponentType", "(", ")", ";", "TypeBinding", "match", "=", "currentType", ".", "findSuperTypeOriginatingFrom", "(", "targetType", ")", ";", "if", "(", "!", "(", "match", "instanceof", "ReferenceBinding", ")", ")", "return", "false", ";", "ReferenceBinding", "compatible", "=", "(", "ReferenceBinding", ")", "match", ";", "while", "(", "compatible", ".", "isRawType", "(", ")", ")", "{", "if", "(", "targetType", ".", "isBoundParameterizedType", "(", ")", ")", "return", "true", ";", "if", "(", "compatible", ".", "isStatic", "(", ")", ")", "break", ";", "if", "(", "(", "compatible", "=", "compatible", ".", "enclosingType", "(", ")", ")", "==", "null", ")", "break", ";", "if", "(", "(", "targetType", "=", "targetType", ".", "enclosingType", "(", ")", ")", "==", "null", ")", "break", ";", "}", "return", "false", ";", "}", "public", "TypeBinding", "original", "(", ")", "{", "switch", "(", "kind", "(", ")", ")", "{", "case", "Binding", ".", "PARAMETERIZED_TYPE", ":", "case", "Binding", ".", "RAW_TYPE", ":", "case", "Binding", ".", "ARRAY_TYPE", ":", "return", "erasure", "(", ")", ";", "default", ":", "return", "this", ";", "}", "}", "public", "char", "[", "]", "qualifiedPackageName", "(", ")", "{", "PackageBinding", "packageBinding", "=", "getPackage", "(", ")", ";", "return", "packageBinding", "==", "null", "||", "packageBinding", ".", "compoundName", "==", "CharOperation", ".", "NO_CHAR_CHAR", "?", "CharOperation", ".", "NO_CHAR", ":", "packageBinding", ".", "readableName", "(", ")", ";", "}", "public", "abstract", "char", "[", "]", "qualifiedSourceName", "(", ")", ";", "public", "char", "[", "]", "signature", "(", ")", "{", "return", "constantPoolName", "(", ")", ";", "}", "public", "abstract", "char", "[", "]", "sourceName", "(", ")", ";", "public", "void", "swapUnresolved", "(", "UnresolvedReferenceBinding", "unresolvedType", ",", "ReferenceBinding", "resolvedType", ",", "LookupEnvironment", "environment", ")", "{", "}", "public", "TypeVariableBinding", "[", "]", "typeVariables", "(", ")", "{", "return", "Binding", ".", "NO_TYPE_VARIABLES", ";", "}", "}", "</s>" ]
5,569
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AbstractMethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "FieldDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "public", "class", "SyntheticMethodBinding", "extends", "MethodBinding", "{", "public", "FieldBinding", "targetReadField", ";", "public", "FieldBinding", "targetWriteField", ";", "public", "MethodBinding", "targetMethod", ";", "public", "TypeBinding", "targetEnumType", ";", "public", "int", "purpose", ";", "public", "final", "static", "int", "FieldReadAccess", "=", "1", ";", "public", "final", "static", "int", "FieldWriteAccess", "=", "2", ";", "public", "final", "static", "int", "SuperFieldReadAccess", "=", "3", ";", "public", "final", "static", "int", "SuperFieldWriteAccess", "=", "4", ";", "public", "final", "static", "int", "MethodAccess", "=", "5", ";", "public", "final", "static", "int", "ConstructorAccess", "=", "6", ";", "public", "final", "static", "int", "SuperMethodAccess", "=", "7", ";", "public", "final", "static", "int", "BridgeMethod", "=", "8", ";", "public", "final", "static", "int", "EnumValues", "=", "9", ";", "public", "final", "static", "int", "EnumValueOf", "=", "10", ";", "public", "final", "static", "int", "SwitchTable", "=", "11", ";", "public", "int", "sourceStart", "=", "0", ";", "public", "int", "index", ";", "public", "SyntheticMethodBinding", "(", "FieldBinding", "targetField", ",", "boolean", "isReadAccess", ",", "boolean", "isSuperAccess", ",", "ReferenceBinding", "declaringClass", ")", "{", "this", ".", "modifiers", "=", "ClassFileConstants", ".", "AccDefault", "|", "ClassFileConstants", ".", "AccStatic", "|", "ClassFileConstants", ".", "AccSynthetic", ";", "this", ".", "tagBits", "|=", "(", "TagBits", ".", "AnnotationResolved", "|", "TagBits", ".", "DeprecatedAnnotationResolved", ")", ";", "SourceTypeBinding", "declaringSourceType", "=", "(", "SourceTypeBinding", ")", "declaringClass", ";", "SyntheticMethodBinding", "[", "]", "knownAccessMethods", "=", "declaringSourceType", ".", "syntheticMethods", "(", ")", ";", "int", "methodId", "=", "knownAccessMethods", "==", "null", "?", "0", ":", "knownAccessMethods", ".", "length", ";", "this", ".", "index", "=", "methodId", ";", "this", ".", "selector", "=", "CharOperation", ".", "concat", "(", "TypeConstants", ".", "SYNTHETIC_ACCESS_METHOD_PREFIX", ",", "String", ".", "valueOf", "(", "methodId", ")", ".", "toCharArray", "(", ")", ")", ";", "if", "(", "isReadAccess", ")", "{", "this", ".", "returnType", "=", "targetField", ".", "type", ";", "if", "(", "targetField", ".", "isStatic", "(", ")", ")", "{", "this", ".", "parameters", "=", "Binding", ".", "NO_PARAMETERS", ";", "}", "else", "{", "this", ".", "parameters", "=", "new", "TypeBinding", "[", "1", "]", ";", "this", ".", "parameters", "[", "0", "]", "=", "declaringSourceType", ";", "}", "this", ".", "targetReadField", "=", "targetField", ";", "this", ".", "purpose", "=", "isSuperAccess", "?", "SyntheticMethodBinding", ".", "SuperFieldReadAccess", ":", "SyntheticMethodBinding", ".", "FieldReadAccess", ";", "}", "else", "{", "this", ".", "returnType", "=", "TypeBinding", ".", "VOID", ";", "if", "(", "targetField", ".", "isStatic", "(", ")", ")", "{", "this", ".", "parameters", "=", "new", "TypeBinding", "[", "1", "]", ";", "this", ".", "parameters", "[", "0", "]", "=", "targetField", ".", "type", ";", "}", "else", "{", "this", ".", "parameters", "=", "new", "TypeBinding", "[", "2", "]", ";", "this", ".", "parameters", "[", "0", "]", "=", "declaringSourceType", ";", "this", ".", "parameters", "[", "1", "]", "=", "targetField", ".", "type", ";", "}", "this", ".", "targetWriteField", "=", "targetField", ";", "this", ".", "purpose", "=", "isSuperAccess", "?", "SyntheticMethodBinding", ".", "SuperFieldWriteAccess", ":", "SyntheticMethodBinding", ".", "FieldWriteAccess", ";", "}", "this", ".", "thrownExceptions", "=", "Binding", ".", "NO_EXCEPTIONS", ";", "this", ".", "declaringClass", "=", "declaringSourceType", ";", "boolean", "needRename", ";", "do", "{", "check", ":", "{", "needRename", "=", "false", ";", "long", "range", ";", "MethodBinding", "[", "]", "methods", "=", "declaringSourceType", ".", "methods", "(", ")", ";", "if", "(", "(", "range", "=", "ReferenceBinding", ".", "binarySearch", "(", "this", ".", "selector", ",", "methods", ")", ")", ">=", "0", ")", "{", "int", "paramCount", "=", "this", ".", "parameters", ".", "length", ";", "nextMethod", ":", "for", "(", "int", "imethod", "=", "(", "int", ")", "range", ",", "end", "=", "(", "int", ")", "(", "range", ">>", "32", ")", ";", "imethod", "<=", "end", ";", "imethod", "++", ")", "{", "MethodBinding", "method", "=", "methods", "[", "imethod", "]", ";", "if", "(", "method", ".", "parameters", ".", "length", "==", "paramCount", ")", "{", "TypeBinding", "[", "]", "toMatch", "=", "method", ".", "parameters", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "paramCount", ";", "i", "++", ")", "{", "if", "(", "toMatch", "[", "i", "]", "!=", "this", ".", "parameters", "[", "i", "]", ")", "{", "continue", "nextMethod", ";", "}", "}", "needRename", "=", "true", ";", "break", "check", ";", "}", "}", "}", "if", "(", "knownAccessMethods", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "knownAccessMethods", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "knownAccessMethods", "[", "i", "]", "==", "null", ")", "continue", ";", "if", "(", "CharOperation", ".", "equals", "(", "this", ".", "selector", ",", "knownAccessMethods", "[", "i", "]", ".", "selector", ")", "&&", "areParametersEqual", "(", "methods", "[", "i", "]", ")", ")", "{", "needRename", "=", "true", ";", "break", "check", ";", "}", "}", "}", "}", "if", "(", "needRename", ")", "{", "setSelector", "(", "CharOperation", ".", "concat", "(", "TypeConstants", ".", "SYNTHETIC_ACCESS_METHOD_PREFIX", ",", "String", ".", "valueOf", "(", "++", "methodId", ")", ".", "toCharArray", "(", ")", ")", ")", ";", "}", "}", "while", "(", "needRename", ")", ";", "FieldDeclaration", "[", "]", "fieldDecls", "=", "declaringSourceType", ".", "scope", ".", "referenceContext", ".", "fields", ";", "if", "(", "fieldDecls", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "fieldDecls", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "fieldDecls", "[", "i", "]", ".", "binding", "==", "targetField", ")", "{", "this", ".", "sourceStart", "=", "fieldDecls", "[", "i", "]", ".", "sourceStart", ";", "return", ";", "}", "}", "}", "this", ".", "sourceStart", "=", "declaringSourceType", ".", "scope", ".", "referenceContext", ".", "sourceStart", ";", "}", "public", "SyntheticMethodBinding", "(", "FieldBinding", "targetField", ",", "ReferenceBinding", "declaringClass", ",", "TypeBinding", "enumBinding", ",", "char", "[", "]", "selector", ")", "{", "this", ".", "modifiers", "=", "ClassFileConstants", ".", "AccDefault", "|", "ClassFileConstants", ".", "AccStatic", "|", "ClassFileConstants", ".", "AccSynthetic", ";", "this", ".", "tagBits", "|=", "(", "TagBits", ".", "AnnotationResolved", "|", "TagBits", ".", "DeprecatedAnnotationResolved", ")", ";", "SourceTypeBinding", "declaringSourceType", "=", "(", "SourceTypeBinding", ")", "declaringClass", ";", "SyntheticMethodBinding", "[", "]", "knownAccessMethods", "=", "declaringSourceType", ".", "syntheticMethods", "(", ")", ";", "int", "methodId", "=", "knownAccessMethods", "==", "null", "?", "0", ":", "knownAccessMethods", ".", "length", ";", "this", ".", "index", "=", "methodId", ";", "this", ".", "selector", "=", "selector", ";", "this", ".", "returnType", "=", "declaringSourceType", ".", "scope", ".", "createArrayType", "(", "TypeBinding", ".", "INT", ",", "1", ")", ";", "this", ".", "parameters", "=", "Binding", ".", "NO_PARAMETERS", ";", "this", ".", "targetReadField", "=", "targetField", ";", "this", ".", "targetEnumType", "=", "enumBinding", ";", "this", ".", "purpose", "=", "SyntheticMethodBinding", ".", "SwitchTable", ";", "this", ".", "thrownExceptions", "=", "Binding", ".", "NO_EXCEPTIONS", ";", "this", ".", "declaringClass", "=", "declaringSourceType", ";", "if", "(", "declaringSourceType", ".", "isStrictfp", "(", ")", ")", "{", "this", ".", "modifiers", "|=", "ClassFileConstants", ".", "AccStrictfp", ";", "}", "boolean", "needRename", ";", "do", "{", "check", ":", "{", "needRename", "=", "false", ";", "long", "range", ";", "MethodBinding", "[", "]", "methods", "=", "declaringSourceType", ".", "methods", "(", ")", ";", "if", "(", "(", "range", "=", "ReferenceBinding", ".", "binarySearch", "(", "this", ".", "selector", ",", "methods", ")", ")", ">=", "0", ")", "{", "int", "paramCount", "=", "this", ".", "parameters", ".", "length", ";", "nextMethod", ":", "for", "(", "int", "imethod", "=", "(", "int", ")", "range", ",", "end", "=", "(", "int", ")", "(", "range", ">>", "32", ")", ";", "imethod", "<=", "end", ";", "imethod", "++", ")", "{", "MethodBinding", "method", "=", "methods", "[", "imethod", "]", ";", "if", "(", "method", ".", "parameters", ".", "length", "==", "paramCount", ")", "{", "TypeBinding", "[", "]", "toMatch", "=", "method", ".", "parameters", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "paramCount", ";", "i", "++", ")", "{", "if", "(", "toMatch", "[", "i", "]", "!=", "this", ".", "parameters", "[", "i", "]", ")", "{", "continue", "nextMethod", ";", "}", "}", "needRename", "=", "true", ";", "break", "check", ";", "}", "}", "}", "if", "(", "knownAccessMethods", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "knownAccessMethods", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "knownAccessMethods", "[", "i", "]", "==", "null", ")", "continue", ";", "if", "(", "CharOperation", ".", "equals", "(", "this", ".", "selector", ",", "knownAccessMethods", "[", "i", "]", ".", "selector", ")", "&&", "areParametersEqual", "(", "methods", "[", "i", "]", ")", ")", "{", "needRename", "=", "true", ";", "break", "check", ";", "}", "}", "}", "}", "if", "(", "needRename", ")", "{", "setSelector", "(", "CharOperation", ".", "concat", "(", "selector", ",", "String", ".", "valueOf", "(", "++", "methodId", ")", ".", "toCharArray", "(", ")", ")", ")", ";", "}", "}", "while", "(", "needRename", ")", ";", "this", ".", "sourceStart", "=", "declaringSourceType", ".", "scope", ".", "referenceContext", ".", "sourceStart", ";", "}", "public", "SyntheticMethodBinding", "(", "MethodBinding", "targetMethod", ",", "boolean", "isSuperAccess", ",", "ReferenceBinding", "declaringClass", ")", "{", "if", "(", "targetMethod", ".", "isConstructor", "(", ")", ")", "{", "initializeConstructorAccessor", "(", "targetMethod", ")", ";", "}", "else", "{", "initializeMethodAccessor", "(", "targetMethod", ",", "isSuperAccess", ",", "declaringClass", ")", ";", "}", "}", "public", "SyntheticMethodBinding", "(", "MethodBinding", "overridenMethodToBridge", ",", "MethodBinding", "targetMethod", ",", "SourceTypeBinding", "declaringClass", ")", "{", "this", ".", "declaringClass", "=", "declaringClass", ";", "this", ".", "selector", "=", "overridenMethodToBridge", ".", "selector", ";", "this", ".", "modifiers", "=", "(", "targetMethod", ".", "modifiers", "|", "ClassFileConstants", ".", "AccBridge", "|", "ClassFileConstants", ".", "AccSynthetic", ")", "&", "~", "(", "ClassFileConstants", ".", "AccAbstract", "|", "ClassFileConstants", ".", "AccNative", "|", "ClassFileConstants", ".", "AccFinal", "|", "ExtraCompilerModifiers", ".", "AccGenericSignature", ")", ";", "this", ".", "tagBits", "|=", "(", "TagBits", ".", "AnnotationResolved", "|", "TagBits", ".", "DeprecatedAnnotationResolved", ")", ";", "this", ".", "returnType", "=", "overridenMethodToBridge", ".", "returnType", ";", "this", ".", "parameters", "=", "overridenMethodToBridge", ".", "parameters", ";", "this", ".", "thrownExceptions", "=", "overridenMethodToBridge", ".", "thrownExceptions", ";", "this", ".", "targetMethod", "=", "targetMethod", ";", "this", ".", "purpose", "=", "SyntheticMethodBinding", ".", "BridgeMethod", ";", "SyntheticMethodBinding", "[", "]", "knownAccessMethods", "=", "declaringClass", ".", "syntheticMethods", "(", ")", ";", "int", "methodId", "=", "knownAccessMethods", "==", "null", "?", "0", ":", "knownAccessMethods", ".", "length", ";", "this", ".", "index", "=", "methodId", ";", "}", "public", "SyntheticMethodBinding", "(", "SourceTypeBinding", "declaringEnum", ",", "char", "[", "]", "selector", ")", "{", "this", ".", "declaringClass", "=", "declaringEnum", ";", "this", ".", "selector", "=", "selector", ";", "this", ".", "modifiers", "=", "ClassFileConstants", ".", "AccPublic", "|", "ClassFileConstants", ".", "AccStatic", ";", "this", ".", "tagBits", "|=", "(", "TagBits", ".", "AnnotationResolved", "|", "TagBits", ".", "DeprecatedAnnotationResolved", ")", ";", "LookupEnvironment", "environment", "=", "declaringEnum", ".", "scope", ".", "environment", "(", ")", ";", "this", ".", "thrownExceptions", "=", "Binding", ".", "NO_EXCEPTIONS", ";", "if", "(", "selector", "==", "TypeConstants", ".", "VALUES", ")", "{", "this", ".", "returnType", "=", "environment", ".", "createArrayType", "(", "environment", ".", "convertToParameterizedType", "(", "declaringEnum", ")", ",", "1", ")", ";", "this", ".", "parameters", "=", "Binding", ".", "NO_PARAMETERS", ";", "this", ".", "purpose", "=", "SyntheticMethodBinding", ".", "EnumValues", ";", "}", "else", "if", "(", "selector", "==", "TypeConstants", ".", "VALUEOF", ")", "{", "this", ".", "returnType", "=", "environment", ".", "convertToParameterizedType", "(", "declaringEnum", ")", ";", "this", ".", "parameters", "=", "new", "TypeBinding", "[", "]", "{", "declaringEnum", ".", "scope", ".", "getJavaLangString", "(", ")", "}", ";", "this", ".", "purpose", "=", "SyntheticMethodBinding", ".", "EnumValueOf", ";", "}", "SyntheticMethodBinding", "[", "]", "knownAccessMethods", "=", "(", "(", "SourceTypeBinding", ")", "this", ".", "declaringClass", ")", ".", "syntheticMethods", "(", ")", ";", "int", "methodId", "=", "knownAccessMethods", "==", "null", "?", "0", ":", "knownAccessMethods", ".", "length", ";", "this", ".", "index", "=", "methodId", ";", "if", "(", "declaringEnum", ".", "isStrictfp", "(", ")", ")", "{", "this", ".", "modifiers", "|=", "ClassFileConstants", ".", "AccStrictfp", ";", "}", "}", "public", "SyntheticMethodBinding", "(", "MethodBinding", "overridenMethodToBridge", ",", "SourceTypeBinding", "declaringClass", ")", "{", "this", ".", "declaringClass", "=", "declaringClass", ";", "this", ".", "selector", "=", "overridenMethodToBridge", ".", "selector", ";", "this", ".", "modifiers", "=", "(", "overridenMethodToBridge", ".", "modifiers", "|", "ClassFileConstants", ".", "AccBridge", "|", "ClassFileConstants", ".", "AccSynthetic", ")", "&", "~", "(", "ClassFileConstants", ".", "AccAbstract", "|", "ClassFileConstants", ".", "AccNative", "|", "ClassFileConstants", ".", "AccFinal", "|", "ExtraCompilerModifiers", ".", "AccGenericSignature", ")", ";", "this", ".", "tagBits", "|=", "(", "TagBits", ".", "AnnotationResolved", "|", "TagBits", ".", "DeprecatedAnnotationResolved", ")", ";", "this", ".", "returnType", "=", "overridenMethodToBridge", ".", "returnType", ";", "this", ".", "parameters", "=", "overridenMethodToBridge", ".", "parameters", ";", "this", ".", "thrownExceptions", "=", "overridenMethodToBridge", ".", "thrownExceptions", ";", "this", ".", "targetMethod", "=", "overridenMethodToBridge", ";", "this", ".", "purpose", "=", "SyntheticMethodBinding", ".", "SuperMethodAccess", ";", "SyntheticMethodBinding", "[", "]", "knownAccessMethods", "=", "declaringClass", ".", "syntheticMethods", "(", ")", ";", "int", "methodId", "=", "knownAccessMethods", "==", "null", "?", "0", ":", "knownAccessMethods", ".", "length", ";", "this", ".", "index", "=", "methodId", ";", "}", "public", "void", "initializeConstructorAccessor", "(", "MethodBinding", "accessedConstructor", ")", "{", "this", ".", "targetMethod", "=", "accessedConstructor", ";", "this", ".", "modifiers", "=", "ClassFileConstants", ".", "AccDefault", "|", "ClassFileConstants", ".", "AccSynthetic", ";", "this", ".", "tagBits", "|=", "(", "TagBits", ".", "AnnotationResolved", "|", "TagBits", ".", "DeprecatedAnnotationResolved", ")", ";", "SourceTypeBinding", "sourceType", "=", "(", "SourceTypeBinding", ")", "accessedConstructor", ".", "declaringClass", ";", "SyntheticMethodBinding", "[", "]", "knownSyntheticMethods", "=", "sourceType", ".", "syntheticMethods", "(", ")", ";", "this", ".", "index", "=", "knownSyntheticMethods", "==", "null", "?", "0", ":", "knownSyntheticMethods", ".", "length", ";", "this", ".", "selector", "=", "accessedConstructor", ".", "selector", ";", "this", ".", "returnType", "=", "accessedConstructor", ".", "returnType", ";", "this", ".", "purpose", "=", "SyntheticMethodBinding", ".", "ConstructorAccess", ";", "this", ".", "parameters", "=", "new", "TypeBinding", "[", "accessedConstructor", ".", "parameters", ".", "length", "+", "1", "]", ";", "System", ".", "arraycopy", "(", "accessedConstructor", ".", "parameters", ",", "0", ",", "this", ".", "parameters", ",", "0", ",", "accessedConstructor", ".", "parameters", ".", "length", ")", ";", "this", ".", "parameters", "[", "accessedConstructor", ".", "parameters", ".", "length", "]", "=", "accessedConstructor", ".", "declaringClass", ";", "this", ".", "thrownExceptions", "=", "accessedConstructor", ".", "thrownExceptions", ";", "this", ".", "declaringClass", "=", "sourceType", ";", "boolean", "needRename", ";", "do", "{", "check", ":", "{", "needRename", "=", "false", ";", "MethodBinding", "[", "]", "methods", "=", "sourceType", ".", "methods", "(", ")", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "methods", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "this", ".", "selector", ",", "methods", "[", "i", "]", ".", "selector", ")", "&&", "areParameterErasuresEqual", "(", "methods", "[", "i", "]", ")", ")", "{", "needRename", "=", "true", ";", "break", "check", ";", "}", "}", "if", "(", "knownSyntheticMethods", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "knownSyntheticMethods", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "knownSyntheticMethods", "[", "i", "]", "==", "null", ")", "continue", ";", "if", "(", "CharOperation", ".", "equals", "(", "this", ".", "selector", ",", "knownSyntheticMethods", "[", "i", "]", ".", "selector", ")", "&&", "areParameterErasuresEqual", "(", "knownSyntheticMethods", "[", "i", "]", ")", ")", "{", "needRename", "=", "true", ";", "break", "check", ";", "}", "}", "}", "}", "if", "(", "needRename", ")", "{", "int", "length", "=", "this", ".", "parameters", ".", "length", ";", "System", ".", "arraycopy", "(", "this", ".", "parameters", ",", "0", ",", "this", ".", "parameters", "=", "new", "TypeBinding", "[", "length", "+", "1", "]", ",", "0", ",", "length", ")", ";", "this", ".", "parameters", "[", "length", "]", "=", "this", ".", "declaringClass", ";", "}", "}", "while", "(", "needRename", ")", ";", "AbstractMethodDeclaration", "[", "]", "methodDecls", "=", "sourceType", ".", "scope", ".", "referenceContext", ".", "methods", ";", "if", "(", "methodDecls", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "methodDecls", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "methodDecls", "[", "i", "]", ".", "binding", "==", "accessedConstructor", ")", "{", "this", ".", "sourceStart", "=", "methodDecls", "[", "i", "]", ".", "sourceStart", ";", "return", ";", "}", "}", "}", "}", "public", "void", "initializeMethodAccessor", "(", "MethodBinding", "accessedMethod", ",", "boolean", "isSuperAccess", ",", "ReferenceBinding", "receiverType", ")", "{", "this", ".", "targetMethod", "=", "accessedMethod", ";", "this", ".", "modifiers", "=", "ClassFileConstants", ".", "AccDefault", "|", "ClassFileConstants", ".", "AccStatic", "|", "ClassFileConstants", ".", "AccSynthetic", ";", "this", ".", "tagBits", "|=", "(", "TagBits", ".", "AnnotationResolved", "|", "TagBits", ".", "DeprecatedAnnotationResolved", ")", ";", "SourceTypeBinding", "declaringSourceType", "=", "(", "SourceTypeBinding", ")", "receiverType", ";", "SyntheticMethodBinding", "[", "]", "knownAccessMethods", "=", "declaringSourceType", ".", "syntheticMethods", "(", ")", ";", "int", "methodId", "=", "knownAccessMethods", "==", "null", "?", "0", ":", "knownAccessMethods", ".", "length", ";", "this", ".", "index", "=", "methodId", ";", "this", ".", "selector", "=", "CharOperation", ".", "concat", "(", "TypeConstants", ".", "SYNTHETIC_ACCESS_METHOD_PREFIX", ",", "String", ".", "valueOf", "(", "methodId", ")", ".", "toCharArray", "(", ")", ")", ";", "this", ".", "returnType", "=", "accessedMethod", ".", "returnType", ";", "this", ".", "purpose", "=", "isSuperAccess", "?", "SyntheticMethodBinding", ".", "SuperMethodAccess", ":", "SyntheticMethodBinding", ".", "MethodAccess", ";", "if", "(", "accessedMethod", ".", "isStatic", "(", ")", ")", "{", "this", ".", "parameters", "=", "accessedMethod", ".", "parameters", ";", "}", "else", "{", "this", ".", "parameters", "=", "new", "TypeBinding", "[", "accessedMethod", ".", "parameters", ".", "length", "+", "1", "]", ";", "this", ".", "parameters", "[", "0", "]", "=", "declaringSourceType", ";", "System", ".", "arraycopy", "(", "accessedMethod", ".", "parameters", ",", "0", ",", "this", ".", "parameters", ",", "1", ",", "accessedMethod", ".", "parameters", ".", "length", ")", ";", "}", "this", ".", "thrownExceptions", "=", "accessedMethod", ".", "thrownExceptions", ";", "this", ".", "declaringClass", "=", "declaringSourceType", ";", "boolean", "needRename", ";", "do", "{", "check", ":", "{", "needRename", "=", "false", ";", "MethodBinding", "[", "]", "methods", "=", "declaringSourceType", ".", "methods", "(", ")", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "methods", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "this", ".", "selector", ",", "methods", "[", "i", "]", ".", "selector", ")", "&&", "areParameterErasuresEqual", "(", "methods", "[", "i", "]", ")", ")", "{", "needRename", "=", "true", ";", "break", "check", ";", "}", "}", "if", "(", "knownAccessMethods", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "knownAccessMethods", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "knownAccessMethods", "[", "i", "]", "==", "null", ")", "continue", ";", "if", "(", "CharOperation", ".", "equals", "(", "this", ".", "selector", ",", "knownAccessMethods", "[", "i", "]", ".", "selector", ")", "&&", "areParameterErasuresEqual", "(", "knownAccessMethods", "[", "i", "]", ")", ")", "{", "needRename", "=", "true", ";", "break", "check", ";", "}", "}", "}", "}", "if", "(", "needRename", ")", "{", "setSelector", "(", "CharOperation", ".", "concat", "(", "TypeConstants", ".", "SYNTHETIC_ACCESS_METHOD_PREFIX", ",", "String", ".", "valueOf", "(", "++", "methodId", ")", ".", "toCharArray", "(", ")", ")", ")", ";", "}", "}", "while", "(", "needRename", ")", ";", "AbstractMethodDeclaration", "[", "]", "methodDecls", "=", "declaringSourceType", ".", "scope", ".", "referenceContext", ".", "methods", ";", "if", "(", "methodDecls", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "methodDecls", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "methodDecls", "[", "i", "]", ".", "binding", "==", "accessedMethod", ")", "{", "this", ".", "sourceStart", "=", "methodDecls", "[", "i", "]", ".", "sourceStart", ";", "return", ";", "}", "}", "}", "}", "protected", "boolean", "isConstructorRelated", "(", ")", "{", "return", "this", ".", "purpose", "==", "SyntheticMethodBinding", ".", "ConstructorAccess", ";", "}", "}", "</s>" ]
5,570
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ASTNode", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "CompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ImportReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "AccessRestriction", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemReporter", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "CompoundNameVector", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "HashtableOfObject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "HashtableOfType", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "ObjectVector", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "SimpleNameVector", ";", "public", "class", "CompilationUnitScope", "extends", "Scope", "{", "public", "LookupEnvironment", "environment", ";", "public", "CompilationUnitDeclaration", "referenceContext", ";", "public", "char", "[", "]", "[", "]", "currentPackageName", ";", "public", "PackageBinding", "fPackage", ";", "public", "ImportBinding", "[", "]", "imports", ";", "public", "HashtableOfObject", "typeOrPackageCache", ";", "public", "SourceTypeBinding", "[", "]", "topLevelTypes", ";", "private", "CompoundNameVector", "qualifiedReferences", ";", "private", "SimpleNameVector", "simpleNameReferences", ";", "private", "SimpleNameVector", "rootReferences", ";", "private", "ObjectVector", "referencedTypes", ";", "private", "ObjectVector", "referencedSuperTypes", ";", "HashtableOfType", "constantPoolNameUsage", ";", "private", "int", "captureID", "=", "1", ";", "public", "CompilationUnitScope", "(", "CompilationUnitDeclaration", "unit", ",", "LookupEnvironment", "environment", ")", "{", "super", "(", "COMPILATION_UNIT_SCOPE", ",", "null", ")", ";", "this", ".", "environment", "=", "environment", ";", "this", ".", "referenceContext", "=", "unit", ";", "unit", ".", "scope", "=", "this", ";", "this", ".", "currentPackageName", "=", "unit", ".", "currentPackage", "==", "null", "?", "CharOperation", ".", "NO_CHAR_CHAR", ":", "unit", ".", "currentPackage", ".", "tokens", ";", "if", "(", "compilerOptions", "(", ")", ".", "produceReferenceInfo", ")", "{", "this", ".", "qualifiedReferences", "=", "new", "CompoundNameVector", "(", ")", ";", "this", ".", "simpleNameReferences", "=", "new", "SimpleNameVector", "(", ")", ";", "this", ".", "rootReferences", "=", "new", "SimpleNameVector", "(", ")", ";", "this", ".", "referencedTypes", "=", "new", "ObjectVector", "(", ")", ";", "this", ".", "referencedSuperTypes", "=", "new", "ObjectVector", "(", ")", ";", "}", "else", "{", "this", ".", "qualifiedReferences", "=", "null", ";", "this", ".", "simpleNameReferences", "=", "null", ";", "this", ".", "rootReferences", "=", "null", ";", "this", ".", "referencedTypes", "=", "null", ";", "this", ".", "referencedSuperTypes", "=", "null", ";", "}", "}", "void", "buildFieldsAndMethods", "(", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "this", ".", "topLevelTypes", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "this", ".", "topLevelTypes", "[", "i", "]", ".", "scope", ".", "buildFieldsAndMethods", "(", ")", ";", "}", "protected", "boolean", "reportPackageIsNotExpectedPackage", "(", "CompilationUnitDeclaration", "referenceContext", ")", "{", "problemReporter", "(", ")", ".", "packageIsNotExpectedPackage", "(", "referenceContext", ")", ";", "return", "true", ";", "}", "void", "buildTypeBindings", "(", "AccessRestriction", "accessRestriction", ")", "{", "this", ".", "topLevelTypes", "=", "new", "SourceTypeBinding", "[", "0", "]", ";", "boolean", "firstIsSynthetic", "=", "false", ";", "if", "(", "this", ".", "referenceContext", ".", "compilationResult", ".", "compilationUnit", "!=", "null", ")", "{", "char", "[", "]", "[", "]", "expectedPackageName", "=", "this", ".", "referenceContext", ".", "compilationResult", ".", "compilationUnit", ".", "getPackageName", "(", ")", ";", "if", "(", "expectedPackageName", "!=", "null", "&&", "!", "CharOperation", ".", "equals", "(", "this", ".", "currentPackageName", ",", "expectedPackageName", ")", ")", "{", "boolean", "errorReported", "=", "true", ";", "if", "(", "this", ".", "referenceContext", ".", "currentPackage", "!=", "null", "||", "this", ".", "referenceContext", ".", "types", "!=", "null", "||", "this", ".", "referenceContext", ".", "imports", "!=", "null", ")", "{", "errorReported", "=", "reportPackageIsNotExpectedPackage", "(", "this", ".", "referenceContext", ")", ";", "}", "if", "(", "errorReported", ")", "{", "this", ".", "currentPackageName", "=", "expectedPackageName", ".", "length", "==", "0", "?", "CharOperation", ".", "NO_CHAR_CHAR", ":", "expectedPackageName", ";", "}", "}", "}", "if", "(", "this", ".", "currentPackageName", "==", "CharOperation", ".", "NO_CHAR_CHAR", ")", "{", "if", "(", "(", "this", ".", "fPackage", "=", "this", ".", "environment", ".", "defaultPackage", ")", "==", "null", ")", "{", "problemReporter", "(", ")", ".", "mustSpecifyPackage", "(", "this", ".", "referenceContext", ")", ";", "return", ";", "}", "}", "else", "{", "if", "(", "(", "this", ".", "fPackage", "=", "this", ".", "environment", ".", "createPackage", "(", "this", ".", "currentPackageName", ")", ")", "==", "null", ")", "{", "if", "(", "this", ".", "referenceContext", ".", "currentPackage", "!=", "null", ")", "problemReporter", "(", ")", ".", "packageCollidesWithType", "(", "this", ".", "referenceContext", ")", ";", "return", ";", "}", "else", "if", "(", "this", ".", "referenceContext", ".", "isPackageInfo", "(", ")", ")", "{", "if", "(", "this", ".", "referenceContext", ".", "types", "==", "null", "||", "this", ".", "referenceContext", ".", "types", ".", "length", "==", "0", ")", "{", "this", ".", "referenceContext", ".", "types", "=", "new", "TypeDeclaration", "[", "1", "]", ";", "this", ".", "referenceContext", ".", "createPackageInfoType", "(", ")", ";", "firstIsSynthetic", "=", "true", ";", "}", "if", "(", "this", ".", "referenceContext", ".", "currentPackage", "!=", "null", ")", "this", ".", "referenceContext", ".", "types", "[", "0", "]", ".", "annotations", "=", "this", ".", "referenceContext", ".", "currentPackage", ".", "annotations", ";", "}", "recordQualifiedReference", "(", "this", ".", "currentPackageName", ")", ";", "}", "TypeDeclaration", "[", "]", "types", "=", "this", ".", "referenceContext", ".", "types", ";", "int", "typeLength", "=", "(", "types", "==", "null", ")", "?", "0", ":", "types", ".", "length", ";", "this", ".", "topLevelTypes", "=", "new", "SourceTypeBinding", "[", "typeLength", "]", ";", "int", "count", "=", "0", ";", "nextType", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "typeLength", ";", "i", "++", ")", "{", "TypeDeclaration", "typeDecl", "=", "types", "[", "i", "]", ";", "if", "(", "this", ".", "environment", ".", "isProcessingAnnotations", "&&", "this", ".", "environment", ".", "isMissingType", "(", "typeDecl", ".", "name", ")", ")", "throw", "new", "SourceTypeCollisionException", "(", ")", ";", "ReferenceBinding", "typeBinding", "=", "this", ".", "fPackage", ".", "getType0", "(", "typeDecl", ".", "name", ")", ";", "recordSimpleReference", "(", "typeDecl", ".", "name", ")", ";", "if", "(", "typeBinding", "!=", "null", "&&", "typeBinding", ".", "isValidBinding", "(", ")", "&&", "!", "(", "typeBinding", "instanceof", "UnresolvedReferenceBinding", ")", ")", "{", "if", "(", "this", ".", "environment", ".", "isProcessingAnnotations", ")", "throw", "new", "SourceTypeCollisionException", "(", ")", ";", "problemReporter", "(", ")", ".", "duplicateTypes", "(", "this", ".", "referenceContext", ",", "typeDecl", ")", ";", "continue", "nextType", ";", "}", "if", "(", "this", ".", "fPackage", "!=", "this", ".", "environment", ".", "defaultPackage", "&&", "this", ".", "fPackage", ".", "getPackage", "(", "typeDecl", ".", "name", ")", "!=", "null", ")", "{", "problemReporter", "(", ")", ".", "typeCollidesWithPackage", "(", "this", ".", "referenceContext", ",", "typeDecl", ")", ";", "}", "checkPublicTypeNameMatchesFilename", "(", "typeDecl", ")", ";", "ClassScope", "child", "=", "buildClassScope", "(", "this", ",", "typeDecl", ")", ";", "SourceTypeBinding", "type", "=", "child", ".", "buildType", "(", "null", ",", "this", ".", "fPackage", ",", "accessRestriction", ")", ";", "if", "(", "firstIsSynthetic", "&&", "i", "==", "0", ")", "type", ".", "modifiers", "|=", "ClassFileConstants", ".", "AccSynthetic", ";", "if", "(", "type", "!=", "null", ")", "this", ".", "topLevelTypes", "[", "count", "++", "]", "=", "type", ";", "}", "if", "(", "count", "!=", "this", ".", "topLevelTypes", ".", "length", ")", "System", ".", "arraycopy", "(", "this", ".", "topLevelTypes", ",", "0", ",", "this", ".", "topLevelTypes", "=", "new", "SourceTypeBinding", "[", "count", "]", ",", "0", ",", "count", ")", ";", "}", "protected", "void", "checkPublicTypeNameMatchesFilename", "(", "TypeDeclaration", "typeDecl", ")", "{", "if", "(", "(", "typeDecl", ".", "modifiers", "&", "ClassFileConstants", ".", "AccPublic", ")", "!=", "0", ")", "{", "char", "[", "]", "mainTypeName", ";", "if", "(", "(", "mainTypeName", "=", "referenceContext", ".", "getMainTypeName", "(", ")", ")", "!=", "null", "&&", "!", "CharOperation", ".", "equals", "(", "mainTypeName", ",", "typeDecl", ".", "name", ")", ")", "{", "problemReporter", "(", ")", ".", "publicClassMustMatchFileName", "(", "referenceContext", ",", "typeDecl", ")", ";", "}", "}", "}", "protected", "ClassScope", "buildClassScope", "(", "Scope", "parent", ",", "TypeDeclaration", "typeDecl", ")", "{", "return", "new", "ClassScope", "(", "parent", ",", "typeDecl", ")", ";", "}", "void", "checkAndSetImports", "(", ")", "{", "if", "(", "this", ".", "referenceContext", ".", "imports", "==", "null", ")", "{", "this", ".", "imports", "=", "getDefaultImports", "(", ")", ";", "return", ";", "}", "int", "numberOfStatements", "=", "this", ".", "referenceContext", ".", "imports", ".", "length", ";", "int", "numberOfImports", "=", "numberOfStatements", "+", "1", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "numberOfStatements", ";", "i", "++", ")", "{", "ImportReference", "importReference", "=", "this", ".", "referenceContext", ".", "imports", "[", "i", "]", ";", "if", "(", "(", "(", "importReference", ".", "bits", "&", "ASTNode", ".", "OnDemand", ")", "!=", "0", ")", "&&", "CharOperation", ".", "equals", "(", "TypeConstants", ".", "JAVA_LANG", ",", "importReference", ".", "tokens", ")", "&&", "!", "importReference", ".", "isStatic", "(", ")", ")", "{", "numberOfImports", "--", ";", "break", ";", "}", "}", "ImportBinding", "[", "]", "resolvedImports", "=", "null", ";", "int", "index", "=", "-", "1", ";", "ImportBinding", "[", "]", "defaultImportBindings", "=", "getDefaultImports", "(", ")", ";", "if", "(", "defaultImportBindings", ".", "length", "==", "1", ")", "{", "resolvedImports", "=", "new", "ImportBinding", "[", "numberOfImports", "]", ";", "resolvedImports", "[", "0", "]", "=", "getDefaultImports", "(", ")", "[", "0", "]", ";", "index", "=", "1", ";", "}", "else", "{", "resolvedImports", "=", "new", "ImportBinding", "[", "numberOfImports", "+", "defaultImportBindings", ".", "length", "-", "1", "]", ";", "index", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "defaultImportBindings", ".", "length", ";", "i", "++", ")", "{", "resolvedImports", "[", "index", "++", "]", "=", "defaultImportBindings", "[", "i", "]", ";", "}", "}", "nextImport", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "numberOfStatements", ";", "i", "++", ")", "{", "ImportReference", "importReference", "=", "this", ".", "referenceContext", ".", "imports", "[", "i", "]", ";", "char", "[", "]", "[", "]", "compoundName", "=", "importReference", ".", "tokens", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "index", ";", "j", "++", ")", "{", "ImportBinding", "resolved", "=", "resolvedImports", "[", "j", "]", ";", "if", "(", "resolved", ".", "onDemand", "==", "(", "(", "importReference", ".", "bits", "&", "ASTNode", ".", "OnDemand", ")", "!=", "0", ")", "&&", "resolved", ".", "isStatic", "(", ")", "==", "importReference", ".", "isStatic", "(", ")", ")", "if", "(", "CharOperation", ".", "equals", "(", "compoundName", ",", "resolvedImports", "[", "j", "]", ".", "compoundName", ")", ")", "continue", "nextImport", ";", "}", "if", "(", "(", "importReference", ".", "bits", "&", "ASTNode", ".", "OnDemand", ")", "!=", "0", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "compoundName", ",", "this", ".", "currentPackageName", ")", ")", "continue", "nextImport", ";", "Binding", "importBinding", "=", "findImport", "(", "compoundName", ",", "compoundName", ".", "length", ")", ";", "if", "(", "!", "importBinding", ".", "isValidBinding", "(", ")", "||", "(", "importReference", ".", "isStatic", "(", ")", "&&", "importBinding", "instanceof", "PackageBinding", ")", ")", "continue", "nextImport", ";", "resolvedImports", "[", "index", "++", "]", "=", "new", "ImportBinding", "(", "compoundName", ",", "true", ",", "importBinding", ",", "importReference", ")", ";", "}", "else", "{", "resolvedImports", "[", "index", "++", "]", "=", "new", "ImportBinding", "(", "compoundName", ",", "false", ",", "null", ",", "importReference", ")", ";", "}", "}", "if", "(", "resolvedImports", ".", "length", ">", "index", ")", "System", ".", "arraycopy", "(", "resolvedImports", ",", "0", ",", "resolvedImports", "=", "new", "ImportBinding", "[", "index", "]", ",", "0", ",", "index", ")", ";", "this", ".", "imports", "=", "resolvedImports", ";", "}", "protected", "void", "checkParameterizedTypes", "(", ")", "{", "if", "(", "compilerOptions", "(", ")", ".", "sourceLevel", "<", "ClassFileConstants", ".", "JDK1_5", ")", "return", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "this", ".", "topLevelTypes", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "ClassScope", "scope", "=", "this", ".", "topLevelTypes", "[", "i", "]", ".", "scope", ";", "scope", ".", "checkParameterizedTypeBounds", "(", ")", ";", "scope", ".", "checkParameterizedSuperTypeCollisions", "(", ")", ";", "}", "}", "public", "char", "[", "]", "computeConstantPoolName", "(", "LocalTypeBinding", "localType", ")", "{", "if", "(", "localType", ".", "constantPoolName", "!=", "null", ")", "{", "return", "localType", ".", "constantPoolName", ";", "}", "if", "(", "this", ".", "constantPoolNameUsage", "==", "null", ")", "this", ".", "constantPoolNameUsage", "=", "new", "HashtableOfType", "(", ")", ";", "ReferenceBinding", "outerMostEnclosingType", "=", "localType", ".", "scope", ".", "outerMostClassScope", "(", ")", ".", "enclosingSourceType", "(", ")", ";", "int", "index", "=", "0", ";", "char", "[", "]", "candidateName", ";", "boolean", "isCompliant15", "=", "compilerOptions", "(", ")", ".", "complianceLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ";", "while", "(", "true", ")", "{", "if", "(", "localType", ".", "isMemberType", "(", ")", ")", "{", "if", "(", "index", "==", "0", ")", "{", "candidateName", "=", "CharOperation", ".", "concat", "(", "localType", ".", "enclosingType", "(", ")", ".", "constantPoolName", "(", ")", ",", "localType", ".", "sourceName", ",", "'$'", ")", ";", "}", "else", "{", "candidateName", "=", "CharOperation", ".", "concat", "(", "localType", ".", "enclosingType", "(", ")", ".", "constantPoolName", "(", ")", ",", "'$'", ",", "String", ".", "valueOf", "(", "index", ")", ".", "toCharArray", "(", ")", ",", "'$'", ",", "localType", ".", "sourceName", ")", ";", "}", "}", "else", "if", "(", "localType", ".", "isAnonymousType", "(", ")", ")", "{", "if", "(", "isCompliant15", ")", "{", "candidateName", "=", "CharOperation", ".", "concat", "(", "localType", ".", "enclosingType", ".", "constantPoolName", "(", ")", ",", "String", ".", "valueOf", "(", "index", "+", "1", ")", ".", "toCharArray", "(", ")", ",", "'$'", ")", ";", "}", "else", "{", "candidateName", "=", "CharOperation", ".", "concat", "(", "outerMostEnclosingType", ".", "constantPoolName", "(", ")", ",", "String", ".", "valueOf", "(", "index", "+", "1", ")", ".", "toCharArray", "(", ")", ",", "'$'", ")", ";", "}", "}", "else", "{", "if", "(", "isCompliant15", ")", "{", "candidateName", "=", "CharOperation", ".", "concat", "(", "CharOperation", ".", "concat", "(", "localType", ".", "enclosingType", "(", ")", ".", "constantPoolName", "(", ")", ",", "String", ".", "valueOf", "(", "index", "+", "1", ")", ".", "toCharArray", "(", ")", ",", "'$'", ")", ",", "localType", ".", "sourceName", ")", ";", "}", "else", "{", "candidateName", "=", "CharOperation", ".", "concat", "(", "outerMostEnclosingType", ".", "constantPoolName", "(", ")", ",", "'$'", ",", "String", ".", "valueOf", "(", "index", "+", "1", ")", ".", "toCharArray", "(", ")", ",", "'$'", ",", "localType", ".", "sourceName", ")", ";", "}", "}", "if", "(", "this", ".", "constantPoolNameUsage", ".", "get", "(", "candidateName", ")", "!=", "null", ")", "{", "index", "++", ";", "}", "else", "{", "this", ".", "constantPoolNameUsage", ".", "put", "(", "candidateName", ",", "localType", ")", ";", "break", ";", "}", "}", "return", "candidateName", ";", "}", "void", "connectTypeHierarchy", "(", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "this", ".", "topLevelTypes", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "this", ".", "topLevelTypes", "[", "i", "]", ".", "scope", ".", "connectTypeHierarchy", "(", ")", ";", "}", "protected", "void", "faultInImports", "(", ")", "{", "if", "(", "this", ".", "typeOrPackageCache", "!=", "null", ")", "return", ";", "if", "(", "this", ".", "referenceContext", ".", "imports", "==", "null", ")", "{", "this", ".", "typeOrPackageCache", "=", "new", "HashtableOfObject", "(", "1", ")", ";", "return", ";", "}", "int", "numberOfStatements", "=", "this", ".", "referenceContext", ".", "imports", ".", "length", ";", "HashtableOfType", "typesBySimpleNames", "=", "null", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "numberOfStatements", ";", "i", "++", ")", "{", "if", "(", "(", "this", ".", "referenceContext", ".", "imports", "[", "i", "]", ".", "bits", "&", "ASTNode", ".", "OnDemand", ")", "==", "0", ")", "{", "typesBySimpleNames", "=", "new", "HashtableOfType", "(", "this", ".", "topLevelTypes", ".", "length", "+", "numberOfStatements", ")", ";", "for", "(", "int", "j", "=", "0", ",", "length", "=", "this", ".", "topLevelTypes", ".", "length", ";", "j", "<", "length", ";", "j", "++", ")", "typesBySimpleNames", ".", "put", "(", "this", ".", "topLevelTypes", "[", "j", "]", ".", "sourceName", ",", "this", ".", "topLevelTypes", "[", "j", "]", ")", ";", "break", ";", "}", "}", "int", "numberOfImports", "=", "numberOfStatements", "+", "1", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "numberOfStatements", ";", "i", "++", ")", "{", "ImportReference", "importReference", "=", "this", ".", "referenceContext", ".", "imports", "[", "i", "]", ";", "if", "(", "(", "(", "importReference", ".", "bits", "&", "ASTNode", ".", "OnDemand", ")", "!=", "0", ")", "&&", "CharOperation", ".", "equals", "(", "TypeConstants", ".", "JAVA_LANG", ",", "importReference", ".", "tokens", ")", "&&", "!", "importReference", ".", "isStatic", "(", ")", ")", "{", "numberOfImports", "--", ";", "break", ";", "}", "}", "ImportBinding", "[", "]", "resolvedImports", "=", "null", ";", "int", "index", "=", "-", "1", ";", "ImportBinding", "[", "]", "defaultImportBindings", "=", "getDefaultImports", "(", ")", ";", "if", "(", "defaultImportBindings", ".", "length", "==", "1", ")", "{", "resolvedImports", "=", "new", "ImportBinding", "[", "numberOfImports", "]", ";", "resolvedImports", "[", "0", "]", "=", "getDefaultImports", "(", ")", "[", "0", "]", ";", "index", "=", "1", ";", "}", "else", "{", "resolvedImports", "=", "new", "ImportBinding", "[", "numberOfImports", "+", "defaultImportBindings", ".", "length", "-", "1", "]", ";", "index", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "defaultImportBindings", ".", "length", ";", "i", "++", ")", "{", "resolvedImports", "[", "index", "++", "]", "=", "defaultImportBindings", "[", "i", "]", ";", "}", "}", "nextImport", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "numberOfStatements", ";", "i", "++", ")", "{", "ImportReference", "importReference", "=", "this", ".", "referenceContext", ".", "imports", "[", "i", "]", ";", "char", "[", "]", "[", "]", "compoundName", "=", "importReference", ".", "tokens", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "index", ";", "j", "++", ")", "{", "ImportBinding", "resolved", "=", "resolvedImports", "[", "j", "]", ";", "if", "(", "resolved", ".", "onDemand", "==", "(", "(", "importReference", ".", "bits", "&", "ASTNode", ".", "OnDemand", ")", "!=", "0", ")", "&&", "resolved", ".", "isStatic", "(", ")", "==", "importReference", ".", "isStatic", "(", ")", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "compoundName", ",", "resolved", ".", "compoundName", ")", ")", "{", "problemReporter", "(", ")", ".", "unusedImport", "(", "importReference", ")", ";", "continue", "nextImport", ";", "}", "}", "}", "if", "(", "(", "importReference", ".", "bits", "&", "ASTNode", ".", "OnDemand", ")", "!=", "0", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "compoundName", ",", "this", ".", "currentPackageName", ")", ")", "{", "problemReporter", "(", ")", ".", "unusedImport", "(", "importReference", ")", ";", "continue", "nextImport", ";", "}", "Binding", "importBinding", "=", "findImport", "(", "compoundName", ",", "compoundName", ".", "length", ")", ";", "if", "(", "!", "importBinding", ".", "isValidBinding", "(", ")", ")", "{", "reportImportProblem", "(", "importReference", ",", "importBinding", ")", ";", "continue", "nextImport", ";", "}", "if", "(", "importReference", ".", "isStatic", "(", ")", "&&", "importBinding", "instanceof", "PackageBinding", ")", "{", "problemReporter", "(", ")", ".", "cannotImportPackage", "(", "importReference", ")", ";", "continue", "nextImport", ";", "}", "resolvedImports", "[", "index", "++", "]", "=", "new", "ImportBinding", "(", "compoundName", ",", "true", ",", "importBinding", ",", "importReference", ")", ";", "}", "else", "{", "Binding", "importBinding", "=", "findSingleImport", "(", "compoundName", ",", "Binding", ".", "TYPE", "|", "Binding", ".", "FIELD", "|", "Binding", ".", "METHOD", ",", "importReference", ".", "isStatic", "(", ")", ")", ";", "if", "(", "!", "importBinding", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "importBinding", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "Ambiguous", ")", "{", "}", "else", "{", "recordImportProblem", "(", "importReference", ",", "importBinding", ")", ";", "continue", "nextImport", ";", "}", "}", "if", "(", "importBinding", "instanceof", "PackageBinding", ")", "{", "problemReporter", "(", ")", ".", "cannotImportPackage", "(", "importReference", ")", ";", "continue", "nextImport", ";", "}", "ReferenceBinding", "conflictingType", "=", "null", ";", "if", "(", "importBinding", "instanceof", "MethodBinding", ")", "{", "conflictingType", "=", "(", "ReferenceBinding", ")", "getType", "(", "compoundName", ",", "compoundName", ".", "length", ")", ";", "if", "(", "!", "conflictingType", ".", "isValidBinding", "(", ")", "||", "(", "importReference", ".", "isStatic", "(", ")", "&&", "!", "conflictingType", ".", "isStatic", "(", ")", ")", ")", "conflictingType", "=", "null", ";", "}", "if", "(", "importBinding", "instanceof", "ReferenceBinding", "||", "conflictingType", "!=", "null", ")", "{", "ReferenceBinding", "referenceBinding", "=", "conflictingType", "==", "null", "?", "(", "ReferenceBinding", ")", "importBinding", ":", "conflictingType", ";", "ReferenceBinding", "typeToCheck", "=", "referenceBinding", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "Ambiguous", "?", "(", "(", "ProblemReferenceBinding", ")", "referenceBinding", ")", ".", "closestMatch", ":", "referenceBinding", ";", "if", "(", "importReference", ".", "isTypeUseDeprecated", "(", "typeToCheck", ",", "this", ")", ")", "problemReporter", "(", ")", ".", "deprecatedType", "(", "typeToCheck", ",", "importReference", ")", ";", "ReferenceBinding", "existingType", "=", "typesBySimpleNames", ".", "get", "(", "importReference", ".", "getSimpleName", "(", ")", ")", ";", "if", "(", "existingType", "!=", "null", ")", "{", "if", "(", "existingType", "==", "referenceBinding", ")", "{", "for", "(", "int", "j", "=", "0", ";", "j", "<", "index", ";", "j", "++", ")", "{", "ImportBinding", "resolved", "=", "resolvedImports", "[", "j", "]", ";", "if", "(", "resolved", "instanceof", "ImportConflictBinding", ")", "{", "ImportConflictBinding", "importConflictBinding", "=", "(", "ImportConflictBinding", ")", "resolved", ";", "if", "(", "importConflictBinding", ".", "conflictingTypeBinding", "==", "referenceBinding", ")", "{", "if", "(", "!", "importReference", ".", "isStatic", "(", ")", ")", "{", "problemReporter", "(", ")", ".", "duplicateImport", "(", "importReference", ")", ";", "resolvedImports", "[", "index", "++", "]", "=", "new", "ImportBinding", "(", "compoundName", ",", "false", ",", "importBinding", ",", "importReference", ")", ";", "}", "}", "}", "else", "if", "(", "resolved", ".", "resolvedImport", "==", "referenceBinding", ")", "{", "if", "(", "importReference", ".", "isStatic", "(", ")", "!=", "resolved", ".", "isStatic", "(", ")", ")", "{", "problemReporter", "(", ")", ".", "duplicateImport", "(", "importReference", ")", ";", "resolvedImports", "[", "index", "++", "]", "=", "new", "ImportBinding", "(", "compoundName", ",", "false", ",", "importBinding", ",", "importReference", ")", ";", "}", "}", "}", "continue", "nextImport", ";", "}", "for", "(", "int", "j", "=", "0", ",", "length", "=", "this", ".", "topLevelTypes", ".", "length", ";", "j", "<", "length", ";", "j", "++", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "this", ".", "topLevelTypes", "[", "j", "]", ".", "sourceName", ",", "existingType", ".", "sourceName", ")", ")", "{", "problemReporter", "(", ")", ".", "conflictingImport", "(", "importReference", ")", ";", "continue", "nextImport", ";", "}", "}", "problemReporter", "(", ")", ".", "duplicateImport", "(", "importReference", ")", ";", "continue", "nextImport", ";", "}", "typesBySimpleNames", ".", "put", "(", "importReference", ".", "getSimpleName", "(", ")", ",", "referenceBinding", ")", ";", "}", "else", "if", "(", "importBinding", "instanceof", "FieldBinding", ")", "{", "for", "(", "int", "j", "=", "0", ";", "j", "<", "index", ";", "j", "++", ")", "{", "ImportBinding", "resolved", "=", "resolvedImports", "[", "j", "]", ";", "if", "(", "resolved", ".", "isStatic", "(", ")", "&&", "resolved", ".", "resolvedImport", "instanceof", "FieldBinding", "&&", "importBinding", "!=", "resolved", ".", "resolvedImport", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "compoundName", "[", "compoundName", ".", "length", "-", "1", "]", ",", "resolved", ".", "compoundName", "[", "resolved", ".", "compoundName", ".", "length", "-", "1", "]", ")", ")", "{", "problemReporter", "(", ")", ".", "duplicateImport", "(", "importReference", ")", ";", "continue", "nextImport", ";", "}", "}", "}", "}", "resolvedImports", "[", "index", "++", "]", "=", "conflictingType", "==", "null", "?", "new", "ImportBinding", "(", "compoundName", ",", "false", ",", "importBinding", ",", "importReference", ")", ":", "new", "ImportConflictBinding", "(", "compoundName", ",", "importBinding", ",", "conflictingType", ",", "importReference", ")", ";", "}", "}", "if", "(", "resolvedImports", ".", "length", ">", "index", ")", "System", ".", "arraycopy", "(", "resolvedImports", ",", "0", ",", "resolvedImports", "=", "new", "ImportBinding", "[", "index", "]", ",", "0", ",", "index", ")", ";", "this", ".", "imports", "=", "resolvedImports", ";", "int", "length", "=", "this", ".", "imports", ".", "length", ";", "this", ".", "typeOrPackageCache", "=", "new", "HashtableOfObject", "(", "length", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "ImportBinding", "binding", "=", "this", ".", "imports", "[", "i", "]", ";", "if", "(", "!", "binding", ".", "onDemand", "&&", "binding", ".", "resolvedImport", "instanceof", "ReferenceBinding", "||", "binding", "instanceof", "ImportConflictBinding", ")", "this", ".", "typeOrPackageCache", ".", "put", "(", "getSimpleName", "(", "binding", ")", ",", "binding", ")", ";", "}", "}", "public", "void", "faultInTypes", "(", ")", "{", "faultInImports", "(", ")", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "this", ".", "topLevelTypes", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "this", ".", "topLevelTypes", "[", "i", "]", ".", "faultInTypesForFieldsAndMethods", "(", ")", ";", "}", "protected", "void", "recordImportProblem", "(", "ImportReference", "importReference", ",", "Binding", "importBinding", ")", "{", "problemReporter", "(", ")", ".", "importProblem", "(", "importReference", ",", "importBinding", ")", ";", "}", "public", "Binding", "findImport", "(", "char", "[", "]", "[", "]", "compoundName", ",", "boolean", "findStaticImports", ",", "boolean", "onDemand", ")", "{", "if", "(", "onDemand", ")", "{", "return", "findImport", "(", "compoundName", ",", "compoundName", ".", "length", ")", ";", "}", "else", "{", "return", "findSingleImport", "(", "compoundName", ",", "Binding", ".", "TYPE", "|", "Binding", ".", "FIELD", "|", "Binding", ".", "METHOD", ",", "findStaticImports", ")", ";", "}", "}", "private", "Binding", "findImport", "(", "char", "[", "]", "[", "]", "compoundName", ",", "int", "length", ")", "{", "recordQualifiedReference", "(", "compoundName", ")", ";", "Binding", "binding", "=", "this", ".", "environment", ".", "getTopLevelPackage", "(", "compoundName", "[", "0", "]", ")", ";", "int", "i", "=", "1", ";", "foundNothingOrType", ":", "if", "(", "binding", "!=", "null", ")", "{", "PackageBinding", "packageBinding", "=", "(", "PackageBinding", ")", "binding", ";", "while", "(", "i", "<", "length", ")", "{", "binding", "=", "packageBinding", ".", "getTypeOrPackage", "(", "compoundName", "[", "i", "++", "]", ")", ";", "if", "(", "binding", "==", "null", "||", "!", "binding", ".", "isValidBinding", "(", ")", ")", "{", "binding", "=", "null", ";", "break", "foundNothingOrType", ";", "}", "if", "(", "!", "(", "binding", "instanceof", "PackageBinding", ")", ")", "break", "foundNothingOrType", ";", "packageBinding", "=", "(", "PackageBinding", ")", "binding", ";", "}", "return", "packageBinding", ";", "}", "ReferenceBinding", "type", ";", "if", "(", "binding", "==", "null", ")", "{", "if", "(", "this", ".", "environment", ".", "defaultPackage", "==", "null", "||", "compilerOptions", "(", ")", ".", "complianceLevel", ">=", "ClassFileConstants", ".", "JDK1_4", ")", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "i", ")", ",", "null", ",", "ProblemReasons", ".", "NotFound", ")", ";", "type", "=", "findType", "(", "compoundName", "[", "0", "]", ",", "this", ".", "environment", ".", "defaultPackage", ",", "this", ".", "environment", ".", "defaultPackage", ")", ";", "if", "(", "type", "==", "null", "||", "!", "type", ".", "isValidBinding", "(", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "i", ")", ",", "null", ",", "ProblemReasons", ".", "NotFound", ")", ";", "i", "=", "1", ";", "}", "else", "{", "type", "=", "(", "ReferenceBinding", ")", "binding", ";", "}", "while", "(", "i", "<", "length", ")", "{", "type", "=", "(", "ReferenceBinding", ")", "this", ".", "environment", ".", "convertToRawType", "(", "type", ",", "false", ")", ";", "if", "(", "!", "type", ".", "canBeSeenBy", "(", "this", ".", "fPackage", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "i", ")", ",", "type", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "char", "[", "]", "name", "=", "compoundName", "[", "i", "++", "]", ";", "type", "=", "type", ".", "getMemberType", "(", "name", ")", ";", "if", "(", "type", "==", "null", ")", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "i", ")", ",", "null", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "if", "(", "!", "canBeSeenBy", "(", "type", ",", "fPackage", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "compoundName", ",", "type", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "return", "type", ";", "}", "protected", "boolean", "canBeSeenBy", "(", "ReferenceBinding", "type", ",", "PackageBinding", "fPackage", ")", "{", "return", "type", ".", "canBeSeenBy", "(", "fPackage", ")", ";", "}", "protected", "Binding", "findSingleImport", "(", "char", "[", "]", "[", "]", "compoundName", ",", "int", "mask", ",", "boolean", "findStaticImports", ")", "{", "if", "(", "compoundName", ".", "length", "==", "1", ")", "{", "if", "(", "this", ".", "environment", ".", "defaultPackage", "==", "null", "||", "compilerOptions", "(", ")", ".", "complianceLevel", ">=", "ClassFileConstants", ".", "JDK1_4", ")", "return", "new", "ProblemReferenceBinding", "(", "compoundName", ",", "null", ",", "ProblemReasons", ".", "NotFound", ")", ";", "ReferenceBinding", "typeBinding", "=", "findType", "(", "compoundName", "[", "0", "]", ",", "this", ".", "environment", ".", "defaultPackage", ",", "this", ".", "fPackage", ")", ";", "if", "(", "typeBinding", "==", "null", ")", "return", "new", "ProblemReferenceBinding", "(", "compoundName", ",", "null", ",", "ProblemReasons", ".", "NotFound", ")", ";", "return", "typeBinding", ";", "}", "if", "(", "findStaticImports", ")", "return", "findSingleStaticImport", "(", "compoundName", ",", "mask", ")", ";", "return", "findImport", "(", "compoundName", ",", "compoundName", ".", "length", ")", ";", "}", "private", "Binding", "findSingleStaticImport", "(", "char", "[", "]", "[", "]", "compoundName", ",", "int", "mask", ")", "{", "Binding", "binding", "=", "findImport", "(", "compoundName", ",", "compoundName", ".", "length", "-", "1", ")", ";", "if", "(", "!", "binding", ".", "isValidBinding", "(", ")", ")", "return", "binding", ";", "char", "[", "]", "name", "=", "compoundName", "[", "compoundName", ".", "length", "-", "1", "]", ";", "if", "(", "binding", "instanceof", "PackageBinding", ")", "{", "Binding", "temp", "=", "(", "(", "PackageBinding", ")", "binding", ")", ".", "getTypeOrPackage", "(", "name", ")", ";", "if", "(", "temp", "!=", "null", "&&", "temp", "instanceof", "ReferenceBinding", ")", "return", "new", "ProblemReferenceBinding", "(", "compoundName", ",", "(", "ReferenceBinding", ")", "temp", ",", "ProblemReasons", ".", "InvalidTypeForStaticImport", ")", ";", "return", "binding", ";", "}", "ReferenceBinding", "type", "=", "(", "ReferenceBinding", ")", "binding", ";", "FieldBinding", "field", "=", "(", "mask", "&", "Binding", ".", "FIELD", ")", "!=", "0", "?", "findField", "(", "type", ",", "name", ",", "null", ",", "true", ")", ":", "null", ";", "if", "(", "field", "!=", "null", ")", "{", "if", "(", "field", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "Ambiguous", "&&", "(", "(", "ProblemFieldBinding", ")", "field", ")", ".", "closestMatch", ".", "isStatic", "(", ")", ")", "return", "field", ";", "if", "(", "field", ".", "isValidBinding", "(", ")", "&&", "field", ".", "isStatic", "(", ")", "&&", "field", ".", "canBeSeenBy", "(", "type", ",", "null", ",", "this", ")", ")", "return", "field", ";", "}", "MethodBinding", "method", "=", "(", "mask", "&", "Binding", ".", "METHOD", ")", "!=", "0", "?", "findStaticMethod", "(", "type", ",", "name", ")", ":", "null", ";", "if", "(", "method", "!=", "null", ")", "return", "method", ";", "type", "=", "findMemberType", "(", "name", ",", "type", ")", ";", "if", "(", "type", "==", "null", "||", "!", "type", ".", "isStatic", "(", ")", ")", "{", "if", "(", "field", "!=", "null", "&&", "!", "field", ".", "isValidBinding", "(", ")", "&&", "field", ".", "problemId", "(", ")", "!=", "ProblemReasons", ".", "NotFound", ")", "return", "field", ";", "return", "new", "ProblemReferenceBinding", "(", "compoundName", ",", "type", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "if", "(", "type", ".", "isValidBinding", "(", ")", "&&", "!", "type", ".", "canBeSeenBy", "(", "this", ".", "fPackage", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "compoundName", ",", "type", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "if", "(", "type", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "NotVisible", ")", "return", "new", "ProblemReferenceBinding", "(", "compoundName", ",", "(", "(", "ProblemReferenceBinding", ")", "type", ")", ".", "closestMatch", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "return", "type", ";", "}", "private", "MethodBinding", "findStaticMethod", "(", "ReferenceBinding", "currentType", ",", "char", "[", "]", "selector", ")", "{", "if", "(", "!", "currentType", ".", "canBeSeenBy", "(", "this", ")", ")", "return", "null", ";", "do", "{", "currentType", ".", "initializeForStaticImports", "(", ")", ";", "MethodBinding", "[", "]", "methods", "=", "currentType", ".", "getMethods", "(", "selector", ")", ";", "if", "(", "methods", "!=", "Binding", ".", "NO_METHODS", ")", "{", "for", "(", "int", "i", "=", "methods", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "{", "MethodBinding", "method", "=", "methods", "[", "i", "]", ";", "if", "(", "method", ".", "isStatic", "(", ")", "&&", "method", ".", "canBeSeenBy", "(", "this", ".", "fPackage", ")", ")", "return", "method", ";", "}", "}", "}", "while", "(", "(", "currentType", "=", "currentType", ".", "superclass", "(", ")", ")", "!=", "null", ")", ";", "return", "null", ";", "}", "protected", "ImportBinding", "[", "]", "getDefaultImports", "(", ")", "{", "if", "(", "this", ".", "environment", ".", "defaultImports", "!=", "null", ")", "return", "this", ".", "environment", ".", "defaultImports", ";", "Binding", "importBinding", "=", "this", ".", "environment", ".", "getTopLevelPackage", "(", "TypeConstants", ".", "JAVA", ")", ";", "if", "(", "importBinding", "!=", "null", ")", "importBinding", "=", "(", "(", "PackageBinding", ")", "importBinding", ")", ".", "getTypeOrPackage", "(", "TypeConstants", ".", "JAVA_LANG", "[", "1", "]", ")", ";", "if", "(", "importBinding", "==", "null", "||", "!", "importBinding", ".", "isValidBinding", "(", ")", ")", "{", "problemReporter", "(", ")", ".", "isClassPathCorrect", "(", "TypeConstants", ".", "JAVA_LANG_OBJECT", ",", "this", ".", "referenceContext", ",", "this", ".", "environment", ".", "missingClassFileLocation", ")", ";", "BinaryTypeBinding", "missingObject", "=", "this", ".", "environment", ".", "createMissingType", "(", "null", ",", "TypeConstants", ".", "JAVA_LANG_OBJECT", ")", ";", "importBinding", "=", "missingObject", ".", "fPackage", ";", "}", "return", "this", ".", "environment", ".", "defaultImports", "=", "new", "ImportBinding", "[", "]", "{", "new", "ImportBinding", "(", "TypeConstants", ".", "JAVA_LANG", ",", "true", ",", "importBinding", ",", "null", ")", "}", ";", "}", "public", "final", "Binding", "getImport", "(", "char", "[", "]", "[", "]", "compoundName", ",", "boolean", "onDemand", ",", "boolean", "isStaticImport", ")", "{", "if", "(", "onDemand", ")", "return", "findImport", "(", "compoundName", ",", "compoundName", ".", "length", ")", ";", "return", "findSingleImport", "(", "compoundName", ",", "Binding", ".", "TYPE", "|", "Binding", ".", "FIELD", "|", "Binding", ".", "METHOD", ",", "isStaticImport", ")", ";", "}", "public", "int", "nextCaptureID", "(", ")", "{", "return", "this", ".", "captureID", "++", ";", "}", "public", "ProblemReporter", "problemReporter", "(", ")", "{", "ProblemReporter", "problemReporter", "=", "this", ".", "referenceContext", ".", "problemReporter", ";", "problemReporter", ".", "referenceContext", "=", "this", ".", "referenceContext", ";", "return", "problemReporter", ";", "}", "public", "void", "recordQualifiedReference", "(", "char", "[", "]", "[", "]", "qualifiedName", ")", "{", "if", "(", "this", ".", "qualifiedReferences", "==", "null", ")", "return", ";", "int", "length", "=", "qualifiedName", ".", "length", ";", "if", "(", "length", ">", "1", ")", "{", "recordRootReference", "(", "qualifiedName", "[", "0", "]", ")", ";", "while", "(", "!", "this", ".", "qualifiedReferences", ".", "contains", "(", "qualifiedName", ")", ")", "{", "this", ".", "qualifiedReferences", ".", "add", "(", "qualifiedName", ")", ";", "if", "(", "length", "==", "2", ")", "{", "recordSimpleReference", "(", "qualifiedName", "[", "0", "]", ")", ";", "recordSimpleReference", "(", "qualifiedName", "[", "1", "]", ")", ";", "return", ";", "}", "length", "--", ";", "recordSimpleReference", "(", "qualifiedName", "[", "length", "]", ")", ";", "System", ".", "arraycopy", "(", "qualifiedName", ",", "0", ",", "qualifiedName", "=", "new", "char", "[", "length", "]", "[", "]", ",", "0", ",", "length", ")", ";", "}", "}", "else", "if", "(", "length", "==", "1", ")", "{", "recordRootReference", "(", "qualifiedName", "[", "0", "]", ")", ";", "recordSimpleReference", "(", "qualifiedName", "[", "0", "]", ")", ";", "}", "}", "void", "recordReference", "(", "char", "[", "]", "[", "]", "qualifiedEnclosingName", ",", "char", "[", "]", "simpleName", ")", "{", "recordQualifiedReference", "(", "qualifiedEnclosingName", ")", ";", "if", "(", "qualifiedEnclosingName", ".", "length", "==", "0", ")", "recordRootReference", "(", "simpleName", ")", ";", "recordSimpleReference", "(", "simpleName", ")", ";", "}", "void", "recordReference", "(", "ReferenceBinding", "type", ",", "char", "[", "]", "simpleName", ")", "{", "ReferenceBinding", "actualType", "=", "typeToRecord", "(", "type", ")", ";", "if", "(", "actualType", "!=", "null", ")", "recordReference", "(", "actualType", ".", "compoundName", ",", "simpleName", ")", ";", "}", "void", "recordRootReference", "(", "char", "[", "]", "simpleName", ")", "{", "if", "(", "this", ".", "rootReferences", "==", "null", ")", "return", ";", "if", "(", "!", "this", ".", "rootReferences", ".", "contains", "(", "simpleName", ")", ")", "this", ".", "rootReferences", ".", "add", "(", "simpleName", ")", ";", "}", "public", "void", "recordSimpleReference", "(", "char", "[", "]", "simpleName", ")", "{", "if", "(", "this", ".", "simpleNameReferences", "==", "null", ")", "return", ";", "if", "(", "!", "this", ".", "simpleNameReferences", ".", "contains", "(", "simpleName", ")", ")", "this", ".", "simpleNameReferences", ".", "add", "(", "simpleName", ")", ";", "}", "void", "recordSuperTypeReference", "(", "TypeBinding", "type", ")", "{", "if", "(", "this", ".", "referencedSuperTypes", "==", "null", ")", "return", ";", "ReferenceBinding", "actualType", "=", "typeToRecord", "(", "type", ")", ";", "if", "(", "actualType", "!=", "null", "&&", "!", "this", ".", "referencedSuperTypes", ".", "containsIdentical", "(", "actualType", ")", ")", "this", ".", "referencedSuperTypes", ".", "add", "(", "actualType", ")", ";", "}", "public", "void", "recordTypeConversion", "(", "TypeBinding", "superType", ",", "TypeBinding", "subType", ")", "{", "recordSuperTypeReference", "(", "subType", ")", ";", "}", "void", "recordTypeReference", "(", "TypeBinding", "type", ")", "{", "if", "(", "this", ".", "referencedTypes", "==", "null", ")", "return", ";", "ReferenceBinding", "actualType", "=", "typeToRecord", "(", "type", ")", ";", "if", "(", "actualType", "!=", "null", "&&", "!", "this", ".", "referencedTypes", ".", "containsIdentical", "(", "actualType", ")", ")", "this", ".", "referencedTypes", ".", "add", "(", "actualType", ")", ";", "}", "void", "recordTypeReferences", "(", "TypeBinding", "[", "]", "types", ")", "{", "if", "(", "this", ".", "referencedTypes", "==", "null", ")", "return", ";", "if", "(", "types", "==", "null", "||", "types", ".", "length", "==", "0", ")", "return", ";", "for", "(", "int", "i", "=", "0", ",", "max", "=", "types", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "ReferenceBinding", "actualType", "=", "typeToRecord", "(", "types", "[", "i", "]", ")", ";", "if", "(", "actualType", "!=", "null", "&&", "!", "this", ".", "referencedTypes", ".", "containsIdentical", "(", "actualType", ")", ")", "this", ".", "referencedTypes", ".", "add", "(", "actualType", ")", ";", "}", "}", "Binding", "resolveSingleImport", "(", "ImportBinding", "importBinding", ",", "int", "mask", ")", "{", "if", "(", "importBinding", ".", "resolvedImport", "==", "null", ")", "{", "importBinding", ".", "resolvedImport", "=", "findSingleImport", "(", "importBinding", ".", "compoundName", ",", "mask", ",", "importBinding", ".", "isStatic", "(", ")", ")", ";", "if", "(", "!", "importBinding", ".", "resolvedImport", ".", "isValidBinding", "(", ")", "||", "importBinding", ".", "resolvedImport", "instanceof", "PackageBinding", ")", "{", "if", "(", "importBinding", ".", "resolvedImport", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "Ambiguous", ")", "return", "importBinding", ".", "resolvedImport", ";", "if", "(", "this", ".", "imports", "!=", "null", ")", "{", "ImportBinding", "[", "]", "newImports", "=", "new", "ImportBinding", "[", "this", ".", "imports", ".", "length", "-", "1", "]", ";", "for", "(", "int", "i", "=", "0", ",", "n", "=", "0", ",", "max", "=", "this", ".", "imports", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "if", "(", "this", ".", "imports", "[", "i", "]", "!=", "importBinding", ")", "newImports", "[", "n", "++", "]", "=", "this", ".", "imports", "[", "i", "]", ";", "this", ".", "imports", "=", "newImports", ";", "}", "return", "null", ";", "}", "}", "return", "importBinding", ".", "resolvedImport", ";", "}", "public", "void", "storeDependencyInfo", "(", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "referencedSuperTypes", ".", "size", ";", "i", "++", ")", "{", "ReferenceBinding", "type", "=", "(", "ReferenceBinding", ")", "this", ".", "referencedSuperTypes", ".", "elementAt", "(", "i", ")", ";", "if", "(", "!", "this", ".", "referencedTypes", ".", "containsIdentical", "(", "type", ")", ")", "this", ".", "referencedTypes", ".", "add", "(", "type", ")", ";", "if", "(", "!", "type", ".", "isLocalType", "(", ")", ")", "{", "ReferenceBinding", "enclosing", "=", "type", ".", "enclosingType", "(", ")", ";", "if", "(", "enclosing", "!=", "null", ")", "recordSuperTypeReference", "(", "enclosing", ")", ";", "}", "ReferenceBinding", "superclass", "=", "type", ".", "superclass", "(", ")", ";", "if", "(", "superclass", "!=", "null", ")", "recordSuperTypeReference", "(", "superclass", ")", ";", "ReferenceBinding", "[", "]", "interfaces", "=", "type", ".", "superInterfaces", "(", ")", ";", "if", "(", "interfaces", "!=", "null", ")", "for", "(", "int", "j", "=", "0", ",", "length", "=", "interfaces", ".", "length", ";", "j", "<", "length", ";", "j", "++", ")", "recordSuperTypeReference", "(", "interfaces", "[", "j", "]", ")", ";", "}", "for", "(", "int", "i", "=", "0", ",", "l", "=", "this", ".", "referencedTypes", ".", "size", ";", "i", "<", "l", ";", "i", "++", ")", "{", "ReferenceBinding", "type", "=", "(", "ReferenceBinding", ")", "this", ".", "referencedTypes", ".", "elementAt", "(", "i", ")", ";", "if", "(", "!", "type", ".", "isLocalType", "(", ")", ")", "recordQualifiedReference", "(", "type", ".", "isMemberType", "(", ")", "?", "CharOperation", ".", "splitOn", "(", "'.'", ",", "type", ".", "readableName", "(", ")", ")", ":", "type", ".", "compoundName", ")", ";", "}", "int", "size", "=", "this", ".", "qualifiedReferences", ".", "size", ";", "char", "[", "]", "[", "]", "[", "]", "qualifiedRefs", "=", "new", "char", "[", "size", "]", "[", "]", "[", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "size", ";", "i", "++", ")", "qualifiedRefs", "[", "i", "]", "=", "this", ".", "qualifiedReferences", ".", "elementAt", "(", "i", ")", ";", "this", ".", "referenceContext", ".", "compilationResult", ".", "qualifiedReferences", "=", "qualifiedRefs", ";", "size", "=", "this", ".", "simpleNameReferences", ".", "size", ";", "char", "[", "]", "[", "]", "simpleRefs", "=", "new", "char", "[", "size", "]", "[", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "size", ";", "i", "++", ")", "simpleRefs", "[", "i", "]", "=", "this", ".", "simpleNameReferences", ".", "elementAt", "(", "i", ")", ";", "this", ".", "referenceContext", ".", "compilationResult", ".", "simpleNameReferences", "=", "simpleRefs", ";", "size", "=", "this", ".", "rootReferences", ".", "size", ";", "char", "[", "]", "[", "]", "rootRefs", "=", "new", "char", "[", "size", "]", "[", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "size", ";", "i", "++", ")", "rootRefs", "[", "i", "]", "=", "this", ".", "rootReferences", ".", "elementAt", "(", "i", ")", ";", "this", ".", "referenceContext", ".", "compilationResult", ".", "rootReferences", "=", "rootRefs", ";", "}", "public", "String", "toString", "(", ")", "{", "return", "\"\"", "+", "new", "String", "(", "this", ".", "referenceContext", ".", "getFileName", "(", ")", ")", ";", "}", "private", "ReferenceBinding", "typeToRecord", "(", "TypeBinding", "type", ")", "{", "if", "(", "type", ".", "isArrayType", "(", ")", ")", "type", "=", "(", "(", "ArrayBinding", ")", "type", ")", ".", "leafComponentType", ";", "switch", "(", "type", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "BASE_TYPE", ":", "case", "Binding", ".", "TYPE_PARAMETER", ":", "case", "Binding", ".", "WILDCARD_TYPE", ":", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "return", "null", ";", "case", "Binding", ".", "PARAMETERIZED_TYPE", ":", "case", "Binding", ".", "RAW_TYPE", ":", "type", "=", "type", ".", "erasure", "(", ")", ";", "}", "ReferenceBinding", "refType", "=", "(", "ReferenceBinding", ")", "type", ";", "if", "(", "refType", ".", "isLocalType", "(", ")", ")", "return", "null", ";", "return", "refType", ";", "}", "public", "void", "verifyMethods", "(", "MethodVerifier", "verifier", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "this", ".", "topLevelTypes", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "this", ".", "topLevelTypes", "[", "i", "]", ".", "verifyMethods", "(", "verifier", ")", ";", "}", "public", "void", "augmentTypeHierarchy", "(", ")", "{", "}", "public", "boolean", "checkTargetCompatibility", "(", ")", "{", "return", "true", ";", "}", "public", "boolean", "scannerAvailable", "(", ")", "{", "return", "true", ";", "}", "public", "boolean", "reportInvalidType", "(", "TypeReference", "typeReference", ",", "TypeBinding", "resolvedType", ")", "{", "return", "true", ";", "}", "protected", "void", "reportImportProblem", "(", "ImportReference", "importReference", ",", "Binding", "importBinding", ")", "{", "problemReporter", "(", ")", ".", "importProblem", "(", "importReference", ",", "importBinding", ")", ";", "}", "public", "boolean", "canSeeEverything", "(", ")", "{", "return", "false", ";", "}", "public", "ReferenceBinding", "selectBinding", "(", "ReferenceBinding", "temp", ",", "ReferenceBinding", "type", ",", "boolean", "isDeclaredImport", ")", "{", "return", "null", ";", "}", "}", "</s>" ]
5,571
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "public", "class", "UnresolvedReferenceBinding", "extends", "ReferenceBinding", "{", "ReferenceBinding", "resolvedType", ";", "TypeBinding", "[", "]", "wrappers", ";", "UnresolvedReferenceBinding", "(", "char", "[", "]", "[", "]", "compoundName", ",", "PackageBinding", "packageBinding", ")", "{", "this", ".", "compoundName", "=", "compoundName", ";", "this", ".", "sourceName", "=", "compoundName", "[", "compoundName", ".", "length", "-", "1", "]", ";", "this", ".", "fPackage", "=", "packageBinding", ";", "this", ".", "wrappers", "=", "null", ";", "}", "void", "addWrapper", "(", "TypeBinding", "wrapper", ",", "LookupEnvironment", "environment", ")", "{", "if", "(", "this", ".", "resolvedType", "!=", "null", ")", "{", "wrapper", ".", "swapUnresolved", "(", "this", ",", "this", ".", "resolvedType", ",", "environment", ")", ";", "return", ";", "}", "if", "(", "this", ".", "wrappers", "==", "null", ")", "{", "this", ".", "wrappers", "=", "new", "TypeBinding", "[", "]", "{", "wrapper", "}", ";", "}", "else", "{", "int", "length", "=", "this", ".", "wrappers", ".", "length", ";", "System", ".", "arraycopy", "(", "this", ".", "wrappers", ",", "0", ",", "this", ".", "wrappers", "=", "new", "TypeBinding", "[", "length", "+", "1", "]", ",", "0", ",", "length", ")", ";", "this", ".", "wrappers", "[", "length", "]", "=", "wrapper", ";", "}", "}", "public", "String", "debugName", "(", ")", "{", "return", "toString", "(", ")", ";", "}", "ReferenceBinding", "resolve", "(", "LookupEnvironment", "environment", ",", "boolean", "convertGenericToRawType", ")", "{", "ReferenceBinding", "targetType", "=", "this", ".", "resolvedType", ";", "if", "(", "targetType", "==", "null", ")", "{", "targetType", "=", "this", ".", "fPackage", ".", "getType0", "(", "this", ".", "compoundName", "[", "this", ".", "compoundName", ".", "length", "-", "1", "]", ")", ";", "if", "(", "targetType", "==", "this", ")", "{", "targetType", "=", "environment", ".", "askForType", "(", "this", ".", "compoundName", ")", ";", "}", "if", "(", "targetType", "==", "null", "||", "targetType", "==", "this", ")", "{", "if", "(", "(", "this", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "==", "0", ")", "{", "environment", ".", "problemReporter", ".", "isClassPathCorrect", "(", "this", ".", "compoundName", ",", "environment", ".", "unitBeingCompleted", ",", "environment", ".", "missingClassFileLocation", ")", ";", "}", "targetType", "=", "environment", ".", "createMissingType", "(", "null", ",", "this", ".", "compoundName", ")", ";", "}", "setResolvedType", "(", "targetType", ",", "environment", ")", ";", "}", "if", "(", "convertGenericToRawType", ")", "{", "targetType", "=", "(", "ReferenceBinding", ")", "environment", ".", "convertUnresolvedBinaryToRawType", "(", "targetType", ")", ";", "}", "return", "targetType", ";", "}", "void", "setResolvedType", "(", "ReferenceBinding", "targetType", ",", "LookupEnvironment", "environment", ")", "{", "if", "(", "this", ".", "resolvedType", "==", "targetType", ")", "return", ";", "this", ".", "resolvedType", "=", "targetType", ";", "if", "(", "this", ".", "wrappers", "!=", "null", ")", "for", "(", "int", "i", "=", "0", ",", "l", "=", "this", ".", "wrappers", ".", "length", ";", "i", "<", "l", ";", "i", "++", ")", "this", ".", "wrappers", "[", "i", "]", ".", "swapUnresolved", "(", "this", ",", "targetType", ",", "environment", ")", ";", "environment", ".", "updateCaches", "(", "this", ",", "targetType", ")", ";", "}", "public", "String", "toString", "(", ")", "{", "return", "\"\"", "+", "(", "(", "this", ".", "compoundName", "!=", "null", ")", "?", "CharOperation", ".", "toString", "(", "this", ".", "compoundName", ")", ":", "\"UNNAMED\"", ")", ";", "}", "}", "</s>" ]
5,572
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "public", "class", "ParameterizedGenericMethodBinding", "extends", "ParameterizedMethodBinding", "implements", "Substitution", "{", "public", "TypeBinding", "[", "]", "typeArguments", ";", "private", "LookupEnvironment", "environment", ";", "public", "boolean", "inferredReturnType", ";", "public", "boolean", "wasInferred", ";", "public", "boolean", "isRaw", ";", "private", "MethodBinding", "tiebreakMethod", ";", "public", "static", "MethodBinding", "computeCompatibleMethod", "(", "MethodBinding", "originalMethod", ",", "TypeBinding", "[", "]", "arguments", ",", "Scope", "scope", ",", "InvocationSite", "invocationSite", ")", "{", "ParameterizedGenericMethodBinding", "methodSubstitute", ";", "TypeVariableBinding", "[", "]", "typeVariables", "=", "originalMethod", ".", "typeVariables", ";", "TypeBinding", "[", "]", "substitutes", "=", "invocationSite", ".", "genericTypeArguments", "(", ")", ";", "TypeBinding", "[", "]", "uncheckedArguments", "=", "null", ";", "computeSubstitutes", ":", "{", "if", "(", "substitutes", "!=", "null", ")", "{", "if", "(", "substitutes", ".", "length", "!=", "typeVariables", ".", "length", ")", "{", "return", "new", "ProblemMethodBinding", "(", "originalMethod", ",", "originalMethod", ".", "selector", ",", "substitutes", ",", "ProblemReasons", ".", "TypeParameterArityMismatch", ")", ";", "}", "methodSubstitute", "=", "scope", ".", "environment", "(", ")", ".", "createParameterizedGenericMethod", "(", "originalMethod", ",", "substitutes", ")", ";", "break", "computeSubstitutes", ";", "}", "TypeBinding", "[", "]", "parameters", "=", "originalMethod", ".", "parameters", ";", "InferenceContext", "inferenceContext", "=", "new", "InferenceContext", "(", "originalMethod", ")", ";", "methodSubstitute", "=", "inferFromArgumentTypes", "(", "scope", ",", "originalMethod", ",", "arguments", ",", "parameters", ",", "inferenceContext", ")", ";", "if", "(", "methodSubstitute", "==", "null", ")", "return", "null", ";", "if", "(", "inferenceContext", ".", "hasUnresolvedTypeArgument", "(", ")", ")", "{", "if", "(", "inferenceContext", ".", "isUnchecked", ")", "{", "int", "length", "=", "inferenceContext", ".", "substitutes", ".", "length", ";", "System", ".", "arraycopy", "(", "inferenceContext", ".", "substitutes", ",", "0", ",", "uncheckedArguments", "=", "new", "TypeBinding", "[", "length", "]", ",", "0", ",", "length", ")", ";", "}", "if", "(", "methodSubstitute", ".", "returnType", "!=", "TypeBinding", ".", "VOID", ")", "{", "TypeBinding", "expectedType", "=", "invocationSite", ".", "expectedType", "(", ")", ";", "if", "(", "expectedType", "!=", "null", ")", "{", "inferenceContext", ".", "hasExplicitExpectedType", "=", "true", ";", "}", "else", "{", "expectedType", "=", "scope", ".", "getJavaLangObject", "(", ")", ";", "}", "inferenceContext", ".", "expectedType", "=", "expectedType", ";", "}", "methodSubstitute", "=", "methodSubstitute", ".", "inferFromExpectedType", "(", "scope", ",", "inferenceContext", ")", ";", "if", "(", "methodSubstitute", "==", "null", ")", "return", "null", ";", "}", "}", "for", "(", "int", "i", "=", "0", ",", "length", "=", "typeVariables", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeVariableBinding", "typeVariable", "=", "typeVariables", "[", "i", "]", ";", "TypeBinding", "substitute", "=", "methodSubstitute", ".", "typeArguments", "[", "i", "]", ";", "if", "(", "uncheckedArguments", "!=", "null", "&&", "uncheckedArguments", "[", "i", "]", "==", "null", ")", "continue", ";", "switch", "(", "typeVariable", ".", "boundCheck", "(", "methodSubstitute", ",", "substitute", ")", ")", "{", "case", "TypeConstants", ".", "MISMATCH", ":", "int", "argLength", "=", "arguments", ".", "length", ";", "TypeBinding", "[", "]", "augmentedArguments", "=", "new", "TypeBinding", "[", "argLength", "+", "2", "]", ";", "System", ".", "arraycopy", "(", "arguments", ",", "0", ",", "augmentedArguments", ",", "0", ",", "argLength", ")", ";", "augmentedArguments", "[", "argLength", "]", "=", "substitute", ";", "augmentedArguments", "[", "argLength", "+", "1", "]", "=", "typeVariable", ";", "return", "new", "ProblemMethodBinding", "(", "methodSubstitute", ",", "originalMethod", ".", "selector", ",", "augmentedArguments", ",", "ProblemReasons", ".", "ParameterBoundMismatch", ")", ";", "case", "TypeConstants", ".", "UNCHECKED", ":", "methodSubstitute", ".", "tagBits", "|=", "TagBits", ".", "HasUncheckedTypeArgumentForBoundCheck", ";", "break", ";", "}", "}", "return", "methodSubstitute", ";", "}", "private", "static", "ParameterizedGenericMethodBinding", "inferFromArgumentTypes", "(", "Scope", "scope", ",", "MethodBinding", "originalMethod", ",", "TypeBinding", "[", "]", "arguments", ",", "TypeBinding", "[", "]", "parameters", ",", "InferenceContext", "inferenceContext", ")", "{", "if", "(", "originalMethod", ".", "isVarargs", "(", ")", ")", "{", "int", "paramLength", "=", "parameters", ".", "length", ";", "int", "minArgLength", "=", "paramLength", "-", "1", ";", "int", "argLength", "=", "arguments", ".", "length", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "minArgLength", ";", "i", "++", ")", "{", "parameters", "[", "i", "]", ".", "collectSubstitutes", "(", "scope", ",", "arguments", "[", "i", "]", ",", "inferenceContext", ",", "TypeConstants", ".", "CONSTRAINT_EXTENDS", ")", ";", "if", "(", "inferenceContext", ".", "status", "==", "InferenceContext", ".", "FAILED", ")", "return", "null", ";", "}", "if", "(", "minArgLength", "<", "argLength", ")", "{", "TypeBinding", "varargType", "=", "parameters", "[", "minArgLength", "]", ";", "TypeBinding", "lastArgument", "=", "arguments", "[", "minArgLength", "]", ";", "checkVarargDimension", ":", "{", "if", "(", "paramLength", "==", "argLength", ")", "{", "if", "(", "lastArgument", "==", "TypeBinding", ".", "NULL", ")", "break", "checkVarargDimension", ";", "switch", "(", "lastArgument", ".", "dimensions", "(", ")", ")", "{", "case", "0", ":", "break", ";", "case", "1", ":", "if", "(", "!", "lastArgument", ".", "leafComponentType", "(", ")", ".", "isBaseType", "(", ")", ")", "break", "checkVarargDimension", ";", "break", ";", "default", ":", "break", "checkVarargDimension", ";", "}", "}", "varargType", "=", "(", "(", "ArrayBinding", ")", "varargType", ")", ".", "elementsType", "(", ")", ";", "}", "for", "(", "int", "i", "=", "minArgLength", ";", "i", "<", "argLength", ";", "i", "++", ")", "{", "varargType", ".", "collectSubstitutes", "(", "scope", ",", "arguments", "[", "i", "]", ",", "inferenceContext", ",", "TypeConstants", ".", "CONSTRAINT_EXTENDS", ")", ";", "if", "(", "inferenceContext", ".", "status", "==", "InferenceContext", ".", "FAILED", ")", "return", "null", ";", "}", "}", "}", "else", "{", "int", "paramLength", "=", "parameters", ".", "length", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "paramLength", ";", "i", "++", ")", "{", "parameters", "[", "i", "]", ".", "collectSubstitutes", "(", "scope", ",", "arguments", "[", "i", "]", ",", "inferenceContext", ",", "TypeConstants", ".", "CONSTRAINT_EXTENDS", ")", ";", "if", "(", "inferenceContext", ".", "status", "==", "InferenceContext", ".", "FAILED", ")", "return", "null", ";", "}", "}", "TypeVariableBinding", "[", "]", "originalVariables", "=", "originalMethod", ".", "typeVariables", ";", "if", "(", "!", "resolveSubstituteConstraints", "(", "scope", ",", "originalVariables", ",", "inferenceContext", ",", "false", ")", ")", "return", "null", ";", "TypeBinding", "[", "]", "inferredSustitutes", "=", "inferenceContext", ".", "substitutes", ";", "TypeBinding", "[", "]", "actualSubstitutes", "=", "inferredSustitutes", ";", "for", "(", "int", "i", "=", "0", ",", "varLength", "=", "originalVariables", ".", "length", ";", "i", "<", "varLength", ";", "i", "++", ")", "{", "if", "(", "inferredSustitutes", "[", "i", "]", "==", "null", ")", "{", "if", "(", "actualSubstitutes", "==", "inferredSustitutes", ")", "{", "System", ".", "arraycopy", "(", "inferredSustitutes", ",", "0", ",", "actualSubstitutes", "=", "new", "TypeBinding", "[", "varLength", "]", ",", "0", ",", "i", ")", ";", "}", "actualSubstitutes", "[", "i", "]", "=", "originalVariables", "[", "i", "]", ";", "}", "else", "if", "(", "actualSubstitutes", "!=", "inferredSustitutes", ")", "{", "actualSubstitutes", "[", "i", "]", "=", "inferredSustitutes", "[", "i", "]", ";", "}", "}", "ParameterizedGenericMethodBinding", "paramMethod", "=", "scope", ".", "environment", "(", ")", ".", "createParameterizedGenericMethod", "(", "originalMethod", ",", "actualSubstitutes", ")", ";", "return", "paramMethod", ";", "}", "private", "static", "boolean", "resolveSubstituteConstraints", "(", "Scope", "scope", ",", "TypeVariableBinding", "[", "]", "typeVariables", ",", "InferenceContext", "inferenceContext", ",", "boolean", "considerEXTENDSConstraints", ")", "{", "TypeBinding", "[", "]", "substitutes", "=", "inferenceContext", ".", "substitutes", ";", "int", "varLength", "=", "typeVariables", ".", "length", ";", "nextTypeParameter", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "varLength", ";", "i", "++", ")", "{", "TypeVariableBinding", "current", "=", "typeVariables", "[", "i", "]", ";", "TypeBinding", "substitute", "=", "substitutes", "[", "i", "]", ";", "if", "(", "substitute", "!=", "null", ")", "continue", "nextTypeParameter", ";", "TypeBinding", "[", "]", "equalSubstitutes", "=", "inferenceContext", ".", "getSubstitutes", "(", "current", ",", "TypeConstants", ".", "CONSTRAINT_EQUAL", ")", ";", "if", "(", "equalSubstitutes", "!=", "null", ")", "{", "nextConstraint", ":", "for", "(", "int", "j", "=", "0", ",", "equalLength", "=", "equalSubstitutes", ".", "length", ";", "j", "<", "equalLength", ";", "j", "++", ")", "{", "TypeBinding", "equalSubstitute", "=", "equalSubstitutes", "[", "j", "]", ";", "if", "(", "equalSubstitute", "==", "null", ")", "continue", "nextConstraint", ";", "if", "(", "equalSubstitute", "==", "current", ")", "{", "for", "(", "int", "k", "=", "j", "+", "1", ";", "k", "<", "equalLength", ";", "k", "++", ")", "{", "equalSubstitute", "=", "equalSubstitutes", "[", "k", "]", ";", "if", "(", "equalSubstitute", "!=", "current", "&&", "equalSubstitute", "!=", "null", ")", "{", "substitutes", "[", "i", "]", "=", "equalSubstitute", ";", "continue", "nextTypeParameter", ";", "}", "}", "substitutes", "[", "i", "]", "=", "current", ";", "continue", "nextTypeParameter", ";", "}", "substitutes", "[", "i", "]", "=", "equalSubstitute", ";", "continue", "nextTypeParameter", ";", "}", "}", "}", "if", "(", "inferenceContext", ".", "hasUnresolvedTypeArgument", "(", ")", ")", "{", "nextTypeParameter", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "varLength", ";", "i", "++", ")", "{", "TypeVariableBinding", "current", "=", "typeVariables", "[", "i", "]", ";", "TypeBinding", "substitute", "=", "substitutes", "[", "i", "]", ";", "if", "(", "substitute", "!=", "null", ")", "continue", "nextTypeParameter", ";", "TypeBinding", "[", "]", "bounds", "=", "inferenceContext", ".", "getSubstitutes", "(", "current", ",", "TypeConstants", ".", "CONSTRAINT_SUPER", ")", ";", "if", "(", "bounds", "==", "null", ")", "continue", "nextTypeParameter", ";", "TypeBinding", "mostSpecificSubstitute", "=", "scope", ".", "lowerUpperBound", "(", "bounds", ")", ";", "if", "(", "mostSpecificSubstitute", "==", "null", ")", "{", "return", "false", ";", "}", "if", "(", "mostSpecificSubstitute", "!=", "TypeBinding", ".", "VOID", ")", "{", "substitutes", "[", "i", "]", "=", "mostSpecificSubstitute", ";", "}", "}", "}", "if", "(", "considerEXTENDSConstraints", "&&", "inferenceContext", ".", "hasUnresolvedTypeArgument", "(", ")", ")", "{", "nextTypeParameter", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "varLength", ";", "i", "++", ")", "{", "TypeVariableBinding", "current", "=", "typeVariables", "[", "i", "]", ";", "TypeBinding", "substitute", "=", "substitutes", "[", "i", "]", ";", "if", "(", "substitute", "!=", "null", ")", "continue", "nextTypeParameter", ";", "TypeBinding", "[", "]", "bounds", "=", "inferenceContext", ".", "getSubstitutes", "(", "current", ",", "TypeConstants", ".", "CONSTRAINT_EXTENDS", ")", ";", "if", "(", "bounds", "==", "null", ")", "continue", "nextTypeParameter", ";", "TypeBinding", "[", "]", "glb", "=", "Scope", ".", "greaterLowerBound", "(", "bounds", ")", ";", "TypeBinding", "mostSpecificSubstitute", "=", "null", ";", "if", "(", "glb", "!=", "null", ")", "mostSpecificSubstitute", "=", "glb", "[", "0", "]", ";", "if", "(", "mostSpecificSubstitute", "!=", "null", ")", "{", "substitutes", "[", "i", "]", "=", "mostSpecificSubstitute", ";", "}", "}", "}", "return", "true", ";", "}", "public", "ParameterizedGenericMethodBinding", "(", "MethodBinding", "originalMethod", ",", "RawTypeBinding", "rawType", ",", "LookupEnvironment", "environment", ")", "{", "TypeVariableBinding", "[", "]", "originalVariables", "=", "originalMethod", ".", "typeVariables", ";", "int", "length", "=", "originalVariables", ".", "length", ";", "TypeBinding", "[", "]", "rawArguments", "=", "new", "TypeBinding", "[", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "rawArguments", "[", "i", "]", "=", "environment", ".", "convertToRawType", "(", "originalVariables", "[", "i", "]", ".", "erasure", "(", ")", ",", "false", ")", ";", "}", "this", ".", "isRaw", "=", "true", ";", "this", ".", "tagBits", "=", "originalMethod", ".", "tagBits", ";", "this", ".", "environment", "=", "environment", ";", "this", ".", "modifiers", "=", "originalMethod", ".", "modifiers", ";", "this", ".", "selector", "=", "originalMethod", ".", "selector", ";", "this", ".", "declaringClass", "=", "rawType", "==", "null", "?", "originalMethod", ".", "declaringClass", ":", "rawType", ";", "this", ".", "typeVariables", "=", "Binding", ".", "NO_TYPE_VARIABLES", ";", "this", ".", "typeArguments", "=", "rawArguments", ";", "this", ".", "originalMethod", "=", "originalMethod", ";", "boolean", "ignoreRawTypeSubstitution", "=", "rawType", "==", "null", "||", "originalMethod", ".", "isStatic", "(", ")", ";", "this", ".", "parameters", "=", "Scope", ".", "substitute", "(", "this", ",", "ignoreRawTypeSubstitution", "?", "originalMethod", ".", "parameters", ":", "Scope", ".", "substitute", "(", "rawType", ",", "originalMethod", ".", "parameters", ")", ")", ";", "this", ".", "thrownExceptions", "=", "Scope", ".", "substitute", "(", "this", ",", "ignoreRawTypeSubstitution", "?", "originalMethod", ".", "thrownExceptions", ":", "Scope", ".", "substitute", "(", "rawType", ",", "originalMethod", ".", "thrownExceptions", ")", ")", ";", "if", "(", "this", ".", "thrownExceptions", "==", "null", ")", "this", ".", "thrownExceptions", "=", "Binding", ".", "NO_EXCEPTIONS", ";", "this", ".", "returnType", "=", "Scope", ".", "substitute", "(", "this", ",", "ignoreRawTypeSubstitution", "?", "originalMethod", ".", "returnType", ":", "Scope", ".", "substitute", "(", "rawType", ",", "originalMethod", ".", "returnType", ")", ")", ";", "this", ".", "wasInferred", "=", "false", ";", "}", "public", "ParameterizedGenericMethodBinding", "(", "MethodBinding", "originalMethod", ",", "TypeBinding", "[", "]", "typeArguments", ",", "LookupEnvironment", "environment", ")", "{", "this", ".", "environment", "=", "environment", ";", "this", ".", "modifiers", "=", "originalMethod", ".", "modifiers", ";", "this", ".", "selector", "=", "originalMethod", ".", "selector", ";", "this", ".", "declaringClass", "=", "originalMethod", ".", "declaringClass", ";", "this", ".", "typeVariables", "=", "Binding", ".", "NO_TYPE_VARIABLES", ";", "this", ".", "typeArguments", "=", "typeArguments", ";", "this", ".", "isRaw", "=", "false", ";", "this", ".", "tagBits", "=", "originalMethod", ".", "tagBits", ";", "this", ".", "originalMethod", "=", "originalMethod", ";", "this", ".", "parameters", "=", "Scope", ".", "substitute", "(", "this", ",", "originalMethod", ".", "parameters", ")", ";", "this", ".", "returnType", "=", "Scope", ".", "substitute", "(", "this", ",", "originalMethod", ".", "returnType", ")", ";", "this", ".", "thrownExceptions", "=", "Scope", ".", "substitute", "(", "this", ",", "originalMethod", ".", "thrownExceptions", ")", ";", "if", "(", "this", ".", "thrownExceptions", "==", "null", ")", "this", ".", "thrownExceptions", "=", "Binding", ".", "NO_EXCEPTIONS", ";", "checkMissingType", ":", "{", "if", "(", "(", "this", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "!=", "0", ")", "break", "checkMissingType", ";", "if", "(", "(", "this", ".", "returnType", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "!=", "0", ")", "{", "this", ".", "tagBits", "|=", "TagBits", ".", "HasMissingType", ";", "break", "checkMissingType", ";", "}", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "parameters", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "(", "this", ".", "parameters", "[", "i", "]", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "!=", "0", ")", "{", "this", ".", "tagBits", "|=", "TagBits", ".", "HasMissingType", ";", "break", "checkMissingType", ";", "}", "}", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "thrownExceptions", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "(", "this", ".", "thrownExceptions", "[", "i", "]", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "!=", "0", ")", "{", "this", ".", "tagBits", "|=", "TagBits", ".", "HasMissingType", ";", "break", "checkMissingType", ";", "}", "}", "}", "this", ".", "wasInferred", "=", "true", ";", "}", "public", "char", "[", "]", "computeUniqueKey", "(", "boolean", "isLeaf", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", ")", ";", "buffer", ".", "append", "(", "this", ".", "originalMethod", ".", "computeUniqueKey", "(", "false", ")", ")", ";", "buffer", ".", "append", "(", "'%'", ")", ";", "buffer", ".", "append", "(", "'<'", ")", ";", "if", "(", "!", "this", ".", "isRaw", ")", "{", "int", "length", "=", "this", ".", "typeArguments", ".", "length", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeBinding", "typeArgument", "=", "this", ".", "typeArguments", "[", "i", "]", ";", "buffer", ".", "append", "(", "typeArgument", ".", "computeUniqueKey", "(", "false", ")", ")", ";", "}", "}", "buffer", ".", "append", "(", "'>'", ")", ";", "int", "resultLength", "=", "buffer", ".", "length", "(", ")", ";", "char", "[", "]", "result", "=", "new", "char", "[", "resultLength", "]", ";", "buffer", ".", "getChars", "(", "0", ",", "resultLength", ",", "result", ",", "0", ")", ";", "return", "result", ";", "}", "public", "LookupEnvironment", "environment", "(", ")", "{", "return", "this", ".", "environment", ";", "}", "public", "boolean", "hasSubstitutedParameters", "(", ")", "{", "if", "(", "this", ".", "wasInferred", ")", "return", "this", ".", "originalMethod", ".", "hasSubstitutedParameters", "(", ")", ";", "return", "super", ".", "hasSubstitutedParameters", "(", ")", ";", "}", "public", "boolean", "hasSubstitutedReturnType", "(", ")", "{", "if", "(", "this", ".", "inferredReturnType", ")", "return", "this", ".", "originalMethod", ".", "hasSubstitutedReturnType", "(", ")", ";", "return", "super", ".", "hasSubstitutedReturnType", "(", ")", ";", "}", "private", "ParameterizedGenericMethodBinding", "inferFromExpectedType", "(", "Scope", "scope", ",", "InferenceContext", "inferenceContext", ")", "{", "TypeVariableBinding", "[", "]", "originalVariables", "=", "this", ".", "originalMethod", ".", "typeVariables", ";", "int", "varLength", "=", "originalVariables", ".", "length", ";", "if", "(", "inferenceContext", ".", "expectedType", "!=", "null", ")", "{", "this", ".", "returnType", ".", "collectSubstitutes", "(", "scope", ",", "inferenceContext", ".", "expectedType", ",", "inferenceContext", ",", "TypeConstants", ".", "CONSTRAINT_SUPER", ")", ";", "if", "(", "inferenceContext", ".", "status", "==", "InferenceContext", ".", "FAILED", ")", "return", "null", ";", "}", "for", "(", "int", "i", "=", "0", ";", "i", "<", "varLength", ";", "i", "++", ")", "{", "TypeVariableBinding", "originalVariable", "=", "originalVariables", "[", "i", "]", ";", "TypeBinding", "argument", "=", "this", ".", "typeArguments", "[", "i", "]", ";", "boolean", "argAlreadyInferred", "=", "argument", "!=", "originalVariable", ";", "if", "(", "originalVariable", ".", "firstBound", "==", "originalVariable", ".", "superclass", ")", "{", "TypeBinding", "substitutedBound", "=", "Scope", ".", "substitute", "(", "this", ",", "originalVariable", ".", "superclass", ")", ";", "argument", ".", "collectSubstitutes", "(", "scope", ",", "substitutedBound", ",", "inferenceContext", ",", "TypeConstants", ".", "CONSTRAINT_SUPER", ")", ";", "if", "(", "inferenceContext", ".", "status", "==", "InferenceContext", ".", "FAILED", ")", "return", "null", ";", "if", "(", "argAlreadyInferred", ")", "{", "substitutedBound", ".", "collectSubstitutes", "(", "scope", ",", "argument", ",", "inferenceContext", ",", "TypeConstants", ".", "CONSTRAINT_EXTENDS", ")", ";", "if", "(", "inferenceContext", ".", "status", "==", "InferenceContext", ".", "FAILED", ")", "return", "null", ";", "}", "}", "for", "(", "int", "j", "=", "0", ",", "max", "=", "originalVariable", ".", "superInterfaces", ".", "length", ";", "j", "<", "max", ";", "j", "++", ")", "{", "TypeBinding", "substitutedBound", "=", "Scope", ".", "substitute", "(", "this", ",", "originalVariable", ".", "superInterfaces", "[", "j", "]", ")", ";", "argument", ".", "collectSubstitutes", "(", "scope", ",", "substitutedBound", ",", "inferenceContext", ",", "TypeConstants", ".", "CONSTRAINT_SUPER", ")", ";", "if", "(", "inferenceContext", ".", "status", "==", "InferenceContext", ".", "FAILED", ")", "return", "null", ";", "if", "(", "argAlreadyInferred", ")", "{", "substitutedBound", ".", "collectSubstitutes", "(", "scope", ",", "argument", ",", "inferenceContext", ",", "TypeConstants", ".", "CONSTRAINT_EXTENDS", ")", ";", "if", "(", "inferenceContext", ".", "status", "==", "InferenceContext", ".", "FAILED", ")", "return", "null", ";", "}", "}", "}", "if", "(", "!", "resolveSubstituteConstraints", "(", "scope", ",", "originalVariables", ",", "inferenceContext", ",", "true", ")", ")", "return", "null", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "varLength", ";", "i", "++", ")", "{", "TypeBinding", "substitute", "=", "inferenceContext", ".", "substitutes", "[", "i", "]", ";", "if", "(", "substitute", "!=", "null", ")", "{", "this", ".", "typeArguments", "[", "i", "]", "=", "inferenceContext", ".", "substitutes", "[", "i", "]", ";", "}", "else", "{", "this", ".", "typeArguments", "[", "i", "]", "=", "originalVariables", "[", "i", "]", ".", "upperBound", "(", ")", ";", "}", "}", "this", ".", "typeArguments", "=", "Scope", ".", "substitute", "(", "this", ",", "this", ".", "typeArguments", ")", ";", "TypeBinding", "oldReturnType", "=", "this", ".", "returnType", ";", "this", ".", "returnType", "=", "Scope", ".", "substitute", "(", "this", ",", "this", ".", "returnType", ")", ";", "this", ".", "inferredReturnType", "=", "inferenceContext", ".", "hasExplicitExpectedType", "&&", "this", ".", "returnType", "!=", "oldReturnType", ";", "this", ".", "parameters", "=", "Scope", ".", "substitute", "(", "this", ",", "this", ".", "parameters", ")", ";", "this", ".", "thrownExceptions", "=", "Scope", ".", "substitute", "(", "this", ",", "this", ".", "thrownExceptions", ")", ";", "if", "(", "this", ".", "thrownExceptions", "==", "null", ")", "this", ".", "thrownExceptions", "=", "Binding", ".", "NO_EXCEPTIONS", ";", "checkMissingType", ":", "{", "if", "(", "(", "this", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "!=", "0", ")", "break", "checkMissingType", ";", "if", "(", "(", "this", ".", "returnType", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "!=", "0", ")", "{", "this", ".", "tagBits", "|=", "TagBits", ".", "HasMissingType", ";", "break", "checkMissingType", ";", "}", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "parameters", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "(", "this", ".", "parameters", "[", "i", "]", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "!=", "0", ")", "{", "this", ".", "tagBits", "|=", "TagBits", ".", "HasMissingType", ";", "break", "checkMissingType", ";", "}", "}", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "thrownExceptions", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "(", "this", ".", "thrownExceptions", "[", "i", "]", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "!=", "0", ")", "{", "this", ".", "tagBits", "|=", "TagBits", ".", "HasMissingType", ";", "break", "checkMissingType", ";", "}", "}", "}", "return", "this", ";", "}", "public", "boolean", "isRawSubstitution", "(", ")", "{", "return", "this", ".", "isRaw", ";", "}", "public", "TypeBinding", "substitute", "(", "TypeVariableBinding", "originalVariable", ")", "{", "TypeVariableBinding", "[", "]", "variables", "=", "this", ".", "originalMethod", ".", "typeVariables", ";", "int", "length", "=", "variables", ".", "length", ";", "if", "(", "originalVariable", ".", "rank", "<", "length", "&&", "variables", "[", "originalVariable", ".", "rank", "]", "==", "originalVariable", ")", "{", "return", "this", ".", "typeArguments", "[", "originalVariable", ".", "rank", "]", ";", "}", "return", "originalVariable", ";", "}", "public", "MethodBinding", "tiebreakMethod", "(", ")", "{", "if", "(", "this", ".", "tiebreakMethod", "==", "null", ")", "this", ".", "tiebreakMethod", "=", "this", ".", "originalMethod", ".", "asRawMethod", "(", "this", ".", "environment", ")", ";", "return", "this", ".", "tiebreakMethod", ";", "}", "}", "</s>" ]
5,573
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "public", "class", "AnnotationHolder", "{", "AnnotationBinding", "[", "]", "annotations", ";", "static", "AnnotationHolder", "storeAnnotations", "(", "AnnotationBinding", "[", "]", "annotations", ",", "AnnotationBinding", "[", "]", "[", "]", "parameterAnnotations", ",", "Object", "defaultValue", ",", "LookupEnvironment", "optionalEnv", ")", "{", "if", "(", "parameterAnnotations", "!=", "null", ")", "{", "boolean", "isEmpty", "=", "true", ";", "for", "(", "int", "i", "=", "parameterAnnotations", ".", "length", ";", "isEmpty", "&&", "--", "i", ">=", "0", ";", ")", "if", "(", "parameterAnnotations", "[", "i", "]", "!=", "null", "&&", "parameterAnnotations", "[", "i", "]", ".", "length", ">", "0", ")", "isEmpty", "=", "false", ";", "if", "(", "isEmpty", ")", "parameterAnnotations", "=", "null", ";", "}", "if", "(", "defaultValue", "!=", "null", ")", "return", "new", "AnnotationMethodHolder", "(", "annotations", ",", "parameterAnnotations", ",", "defaultValue", ",", "optionalEnv", ")", ";", "if", "(", "parameterAnnotations", "!=", "null", ")", "return", "new", "MethodHolder", "(", "annotations", ",", "parameterAnnotations", ")", ";", "return", "new", "AnnotationHolder", "(", ")", ".", "setAnnotations", "(", "annotations", ")", ";", "}", "AnnotationBinding", "[", "]", "getAnnotations", "(", ")", "{", "return", "this", ".", "annotations", ";", "}", "Object", "getDefaultValue", "(", ")", "{", "return", "null", ";", "}", "public", "AnnotationBinding", "[", "]", "[", "]", "getParameterAnnotations", "(", ")", "{", "return", "null", ";", "}", "AnnotationBinding", "[", "]", "getParameterAnnotations", "(", "int", "paramIndex", ")", "{", "return", "Binding", ".", "NO_ANNOTATIONS", ";", "}", "AnnotationHolder", "setAnnotations", "(", "AnnotationBinding", "[", "]", "annotations", ")", "{", "if", "(", "annotations", "==", "null", "||", "annotations", ".", "length", "==", "0", ")", "return", "null", ";", "this", ".", "annotations", "=", "annotations", ";", "return", "this", ";", "}", "static", "class", "MethodHolder", "extends", "AnnotationHolder", "{", "AnnotationBinding", "[", "]", "[", "]", "parameterAnnotations", ";", "MethodHolder", "(", "AnnotationBinding", "[", "]", "annotations", ",", "AnnotationBinding", "[", "]", "[", "]", "parameterAnnotations", ")", "{", "super", "(", ")", ";", "setAnnotations", "(", "annotations", ")", ";", "this", ".", "parameterAnnotations", "=", "parameterAnnotations", ";", "}", "public", "AnnotationBinding", "[", "]", "[", "]", "getParameterAnnotations", "(", ")", "{", "return", "this", ".", "parameterAnnotations", ";", "}", "AnnotationBinding", "[", "]", "getParameterAnnotations", "(", "int", "paramIndex", ")", "{", "AnnotationBinding", "[", "]", "result", "=", "this", ".", "parameterAnnotations", "==", "null", "?", "null", ":", "this", ".", "parameterAnnotations", "[", "paramIndex", "]", ";", "return", "result", "==", "null", "?", "Binding", ".", "NO_ANNOTATIONS", ":", "result", ";", "}", "AnnotationHolder", "setAnnotations", "(", "AnnotationBinding", "[", "]", "annotations", ")", "{", "this", ".", "annotations", "=", "annotations", "==", "null", "||", "annotations", ".", "length", "==", "0", "?", "Binding", ".", "NO_ANNOTATIONS", ":", "annotations", ";", "return", "this", ";", "}", "}", "static", "class", "AnnotationMethodHolder", "extends", "MethodHolder", "{", "Object", "defaultValue", ";", "LookupEnvironment", "env", ";", "AnnotationMethodHolder", "(", "AnnotationBinding", "[", "]", "annotations", ",", "AnnotationBinding", "[", "]", "[", "]", "parameterAnnotations", ",", "Object", "defaultValue", ",", "LookupEnvironment", "optionalEnv", ")", "{", "super", "(", "annotations", ",", "parameterAnnotations", ")", ";", "this", ".", "defaultValue", "=", "defaultValue", ";", "this", ".", "env", "=", "optionalEnv", ";", "}", "Object", "getDefaultValue", "(", ")", "{", "if", "(", "this", ".", "defaultValue", "instanceof", "UnresolvedReferenceBinding", ")", "{", "if", "(", "this", ".", "env", "==", "null", ")", "throw", "new", "IllegalStateException", "(", ")", ";", "this", ".", "defaultValue", "=", "(", "(", "UnresolvedReferenceBinding", ")", "this", ".", "defaultValue", ")", ".", "resolve", "(", "this", ".", "env", ",", "false", ")", ";", "}", "return", "this", ".", "defaultValue", ";", "}", "}", "}", "</s>" ]
5,574
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "codegen", ".", "CodeStream", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "Constant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemReporter", ";", "public", "class", "BlockScope", "extends", "Scope", "{", "public", "LocalVariableBinding", "[", "]", "locals", ";", "public", "int", "localIndex", ";", "public", "int", "startIndex", ";", "public", "int", "offset", ";", "public", "int", "maxOffset", ";", "public", "BlockScope", "[", "]", "shiftScopes", ";", "public", "Scope", "[", "]", "subscopes", "=", "new", "Scope", "[", "1", "]", ";", "public", "int", "subscopeCount", "=", "0", ";", "public", "CaseStatement", "enclosingCase", ";", "public", "final", "static", "VariableBinding", "[", "]", "EmulationPathToImplicitThis", "=", "{", "}", ";", "public", "final", "static", "VariableBinding", "[", "]", "NoEnclosingInstanceInConstructorCall", "=", "{", "}", ";", "public", "final", "static", "VariableBinding", "[", "]", "NoEnclosingInstanceInStaticContext", "=", "{", "}", ";", "public", "BlockScope", "(", "BlockScope", "parent", ")", "{", "this", "(", "parent", ",", "true", ")", ";", "}", "public", "BlockScope", "(", "BlockScope", "parent", ",", "boolean", "addToParentScope", ")", "{", "this", "(", "Scope", ".", "BLOCK_SCOPE", ",", "parent", ")", ";", "this", ".", "locals", "=", "new", "LocalVariableBinding", "[", "5", "]", ";", "if", "(", "addToParentScope", ")", "parent", ".", "addSubscope", "(", "this", ")", ";", "this", ".", "startIndex", "=", "parent", ".", "localIndex", ";", "}", "public", "BlockScope", "(", "BlockScope", "parent", ",", "int", "variableCount", ")", "{", "this", "(", "Scope", ".", "BLOCK_SCOPE", ",", "parent", ")", ";", "this", ".", "locals", "=", "new", "LocalVariableBinding", "[", "variableCount", "]", ";", "parent", ".", "addSubscope", "(", "this", ")", ";", "this", ".", "startIndex", "=", "parent", ".", "localIndex", ";", "}", "protected", "BlockScope", "(", "int", "kind", ",", "Scope", "parent", ")", "{", "super", "(", "kind", ",", "parent", ")", ";", "}", "public", "final", "void", "addAnonymousType", "(", "TypeDeclaration", "anonymousType", ",", "ReferenceBinding", "superBinding", ")", "{", "ClassScope", "anonymousClassScope", "=", "new", "ClassScope", "(", "this", ",", "anonymousType", ")", ";", "anonymousClassScope", ".", "buildAnonymousTypeBinding", "(", "enclosingSourceType", "(", ")", ",", "superBinding", ")", ";", "}", "public", "final", "void", "addLocalType", "(", "TypeDeclaration", "localType", ")", "{", "ClassScope", "localTypeScope", "=", "new", "ClassScope", "(", "this", ",", "localType", ")", ";", "addSubscope", "(", "localTypeScope", ")", ";", "localTypeScope", ".", "buildLocalTypeBinding", "(", "enclosingSourceType", "(", ")", ")", ";", "}", "public", "final", "void", "addLocalVariable", "(", "LocalVariableBinding", "binding", ")", "{", "checkAndSetModifiersForVariable", "(", "binding", ")", ";", "if", "(", "this", ".", "localIndex", "==", "this", ".", "locals", ".", "length", ")", "System", ".", "arraycopy", "(", "this", ".", "locals", ",", "0", ",", "(", "this", ".", "locals", "=", "new", "LocalVariableBinding", "[", "this", ".", "localIndex", "*", "2", "]", ")", ",", "0", ",", "this", ".", "localIndex", ")", ";", "this", ".", "locals", "[", "this", ".", "localIndex", "++", "]", "=", "binding", ";", "binding", ".", "declaringScope", "=", "this", ";", "binding", ".", "id", "=", "outerMostMethodScope", "(", ")", ".", "analysisIndex", "++", ";", "}", "public", "void", "addSubscope", "(", "Scope", "childScope", ")", "{", "if", "(", "this", ".", "subscopeCount", "==", "this", ".", "subscopes", ".", "length", ")", "System", ".", "arraycopy", "(", "this", ".", "subscopes", ",", "0", ",", "(", "this", ".", "subscopes", "=", "new", "Scope", "[", "this", ".", "subscopeCount", "*", "2", "]", ")", ",", "0", ",", "this", ".", "subscopeCount", ")", ";", "this", ".", "subscopes", "[", "this", ".", "subscopeCount", "++", "]", "=", "childScope", ";", "}", "public", "final", "boolean", "allowBlankFinalFieldAssignment", "(", "FieldBinding", "binding", ")", "{", "if", "(", "enclosingReceiverType", "(", ")", "!=", "binding", ".", "declaringClass", ")", "return", "false", ";", "MethodScope", "methodScope", "=", "methodScope", "(", ")", ";", "if", "(", "methodScope", ".", "isStatic", "!=", "binding", ".", "isStatic", "(", ")", ")", "return", "false", ";", "return", "methodScope", ".", "isInsideInitializer", "(", ")", "||", "(", "(", "AbstractMethodDeclaration", ")", "methodScope", ".", "referenceContext", ")", ".", "isInitializationMethod", "(", ")", ";", "}", "String", "basicToString", "(", "int", "tab", ")", "{", "String", "newLine", "=", "\"n\"", ";", "for", "(", "int", "i", "=", "tab", ";", "--", "i", ">=", "0", ";", ")", "newLine", "+=", "\"t\"", ";", "String", "s", "=", "newLine", "+", "\"\"", ";", "newLine", "+=", "\"t\"", ";", "s", "+=", "newLine", "+", "\"locals:\"", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "localIndex", ";", "i", "++", ")", "s", "+=", "newLine", "+", "\"t\"", "+", "this", ".", "locals", "[", "i", "]", ".", "toString", "(", ")", ";", "s", "+=", "newLine", "+", "\"\"", "+", "this", ".", "startIndex", ";", "return", "s", ";", "}", "private", "void", "checkAndSetModifiersForVariable", "(", "LocalVariableBinding", "varBinding", ")", "{", "int", "modifiers", "=", "varBinding", ".", "modifiers", ";", "if", "(", "(", "modifiers", "&", "ExtraCompilerModifiers", ".", "AccAlternateModifierProblem", ")", "!=", "0", "&&", "varBinding", ".", "declaration", "!=", "null", ")", "{", "problemReporter", "(", ")", ".", "duplicateModifierForVariable", "(", "varBinding", ".", "declaration", ",", "this", "instanceof", "MethodScope", ")", ";", "}", "int", "realModifiers", "=", "modifiers", "&", "ExtraCompilerModifiers", ".", "AccJustFlag", ";", "int", "unexpectedModifiers", "=", "~", "ClassFileConstants", ".", "AccFinal", ";", "if", "(", "(", "realModifiers", "&", "unexpectedModifiers", ")", "!=", "0", "&&", "varBinding", ".", "declaration", "!=", "null", ")", "{", "problemReporter", "(", ")", ".", "illegalModifierForVariable", "(", "varBinding", ".", "declaration", ",", "this", "instanceof", "MethodScope", ")", ";", "}", "varBinding", ".", "modifiers", "=", "modifiers", ";", "}", "void", "computeLocalVariablePositions", "(", "int", "ilocal", ",", "int", "initOffset", ",", "CodeStream", "codeStream", ")", "{", "this", ".", "offset", "=", "initOffset", ";", "this", ".", "maxOffset", "=", "initOffset", ";", "int", "maxLocals", "=", "this", ".", "localIndex", ";", "boolean", "hasMoreVariables", "=", "ilocal", "<", "maxLocals", ";", "int", "iscope", "=", "0", ",", "maxScopes", "=", "this", ".", "subscopeCount", ";", "boolean", "hasMoreScopes", "=", "maxScopes", ">", "0", ";", "while", "(", "hasMoreVariables", "||", "hasMoreScopes", ")", "{", "if", "(", "hasMoreScopes", "&&", "(", "!", "hasMoreVariables", "||", "(", "this", ".", "subscopes", "[", "iscope", "]", ".", "startIndex", "(", ")", "<=", "ilocal", ")", ")", ")", "{", "if", "(", "this", ".", "subscopes", "[", "iscope", "]", "instanceof", "BlockScope", ")", "{", "BlockScope", "subscope", "=", "(", "BlockScope", ")", "this", ".", "subscopes", "[", "iscope", "]", ";", "int", "subOffset", "=", "subscope", ".", "shiftScopes", "==", "null", "?", "this", ".", "offset", ":", "subscope", ".", "maxShiftedOffset", "(", ")", ";", "subscope", ".", "computeLocalVariablePositions", "(", "0", ",", "subOffset", ",", "codeStream", ")", ";", "if", "(", "subscope", ".", "maxOffset", ">", "this", ".", "maxOffset", ")", "this", ".", "maxOffset", "=", "subscope", ".", "maxOffset", ";", "}", "hasMoreScopes", "=", "++", "iscope", "<", "maxScopes", ";", "}", "else", "{", "LocalVariableBinding", "local", "=", "this", ".", "locals", "[", "ilocal", "]", ";", "boolean", "generateCurrentLocalVar", "=", "(", "local", ".", "useFlag", "!=", "LocalVariableBinding", ".", "UNUSED", "&&", "local", ".", "constant", "(", ")", "==", "Constant", ".", "NotAConstant", ")", ";", "if", "(", "local", ".", "useFlag", "==", "LocalVariableBinding", ".", "UNUSED", "&&", "(", "local", ".", "declaration", "!=", "null", ")", "&&", "(", "(", "local", ".", "declaration", ".", "bits", "&", "ASTNode", ".", "IsLocalDeclarationReachable", ")", "!=", "0", ")", ")", "{", "if", "(", "!", "(", "local", ".", "declaration", "instanceof", "Argument", ")", ")", "problemReporter", "(", ")", ".", "unusedLocalVariable", "(", "local", ".", "declaration", ")", ";", "}", "if", "(", "!", "generateCurrentLocalVar", ")", "{", "if", "(", "local", ".", "declaration", "!=", "null", "&&", "compilerOptions", "(", ")", ".", "preserveAllLocalVariables", ")", "{", "generateCurrentLocalVar", "=", "true", ";", "local", ".", "useFlag", "=", "LocalVariableBinding", ".", "USED", ";", "}", "}", "if", "(", "generateCurrentLocalVar", ")", "{", "if", "(", "local", ".", "declaration", "!=", "null", ")", "{", "codeStream", ".", "record", "(", "local", ")", ";", "}", "local", ".", "resolvedPosition", "=", "this", ".", "offset", ";", "if", "(", "(", "local", ".", "type", "==", "TypeBinding", ".", "LONG", ")", "||", "(", "local", ".", "type", "==", "TypeBinding", ".", "DOUBLE", ")", ")", "{", "this", ".", "offset", "+=", "2", ";", "}", "else", "{", "this", ".", "offset", "++", ";", "}", "if", "(", "this", ".", "offset", ">", "0xFFFF", ")", "{", "problemReporter", "(", ")", ".", "noMoreAvailableSpaceForLocal", "(", "local", ",", "local", ".", "declaration", "==", "null", "?", "(", "ASTNode", ")", "methodScope", "(", ")", ".", "referenceContext", ":", "local", ".", "declaration", ")", ";", "}", "}", "else", "{", "local", ".", "resolvedPosition", "=", "-", "1", ";", "}", "hasMoreVariables", "=", "++", "ilocal", "<", "maxLocals", ";", "}", "}", "if", "(", "this", ".", "offset", ">", "this", ".", "maxOffset", ")", "this", ".", "maxOffset", "=", "this", ".", "offset", ";", "}", "public", "void", "emulateOuterAccess", "(", "LocalVariableBinding", "outerLocalVariable", ")", "{", "BlockScope", "outerVariableScope", "=", "outerLocalVariable", ".", "declaringScope", ";", "if", "(", "outerVariableScope", "==", "null", ")", "return", ";", "MethodScope", "currentMethodScope", "=", "methodScope", "(", ")", ";", "if", "(", "outerVariableScope", ".", "methodScope", "(", ")", "!=", "currentMethodScope", ")", "{", "NestedTypeBinding", "currentType", "=", "(", "NestedTypeBinding", ")", "enclosingSourceType", "(", ")", ";", "if", "(", "!", "currentType", ".", "isLocalType", "(", ")", ")", "{", "return", ";", "}", "if", "(", "!", "currentMethodScope", ".", "isInsideInitializerOrConstructor", "(", ")", ")", "{", "currentType", ".", "addSyntheticArgumentAndField", "(", "outerLocalVariable", ")", ";", "}", "else", "{", "currentType", ".", "addSyntheticArgument", "(", "outerLocalVariable", ")", ";", "}", "}", "}", "public", "final", "ReferenceBinding", "findLocalType", "(", "char", "[", "]", "name", ")", "{", "long", "compliance", "=", "compilerOptions", "(", ")", ".", "complianceLevel", ";", "for", "(", "int", "i", "=", "this", ".", "subscopeCount", "-", "1", ";", "i", ">=", "0", ";", "i", "--", ")", "{", "if", "(", "this", ".", "subscopes", "[", "i", "]", "instanceof", "ClassScope", ")", "{", "LocalTypeBinding", "sourceType", "=", "(", "LocalTypeBinding", ")", "(", "(", "ClassScope", ")", "this", ".", "subscopes", "[", "i", "]", ")", ".", "referenceContext", ".", "binding", ";", "if", "(", "compliance", ">=", "ClassFileConstants", ".", "JDK1_4", "&&", "sourceType", ".", "enclosingCase", "!=", "null", ")", "{", "if", "(", "!", "isInsideCase", "(", "sourceType", ".", "enclosingCase", ")", ")", "{", "continue", ";", "}", "}", "if", "(", "CharOperation", ".", "equals", "(", "sourceType", ".", "sourceName", "(", ")", ",", "name", ")", ")", "return", "sourceType", ";", "}", "}", "return", "null", ";", "}", "public", "LocalDeclaration", "[", "]", "findLocalVariableDeclarations", "(", "int", "position", ")", "{", "int", "ilocal", "=", "0", ",", "maxLocals", "=", "this", ".", "localIndex", ";", "boolean", "hasMoreVariables", "=", "maxLocals", ">", "0", ";", "LocalDeclaration", "[", "]", "localDeclarations", "=", "null", ";", "int", "declPtr", "=", "0", ";", "int", "iscope", "=", "0", ",", "maxScopes", "=", "this", ".", "subscopeCount", ";", "boolean", "hasMoreScopes", "=", "maxScopes", ">", "0", ";", "while", "(", "hasMoreVariables", "||", "hasMoreScopes", ")", "{", "if", "(", "hasMoreScopes", "&&", "(", "!", "hasMoreVariables", "||", "(", "this", ".", "subscopes", "[", "iscope", "]", ".", "startIndex", "(", ")", "<=", "ilocal", ")", ")", ")", "{", "Scope", "subscope", "=", "this", ".", "subscopes", "[", "iscope", "]", ";", "if", "(", "subscope", ".", "kind", "==", "Scope", ".", "BLOCK_SCOPE", ")", "{", "localDeclarations", "=", "(", "(", "BlockScope", ")", "subscope", ")", ".", "findLocalVariableDeclarations", "(", "position", ")", ";", "if", "(", "localDeclarations", "!=", "null", ")", "{", "return", "localDeclarations", ";", "}", "}", "hasMoreScopes", "=", "++", "iscope", "<", "maxScopes", ";", "}", "else", "{", "LocalVariableBinding", "local", "=", "this", ".", "locals", "[", "ilocal", "]", ";", "if", "(", "local", "!=", "null", ")", "{", "LocalDeclaration", "localDecl", "=", "local", ".", "declaration", ";", "if", "(", "localDecl", "!=", "null", ")", "{", "if", "(", "localDecl", ".", "declarationSourceStart", "<=", "position", ")", "{", "if", "(", "position", "<=", "localDecl", ".", "declarationSourceEnd", ")", "{", "if", "(", "localDeclarations", "==", "null", ")", "{", "localDeclarations", "=", "new", "LocalDeclaration", "[", "maxLocals", "]", ";", "}", "localDeclarations", "[", "declPtr", "++", "]", "=", "localDecl", ";", "}", "}", "else", "{", "return", "localDeclarations", ";", "}", "}", "}", "hasMoreVariables", "=", "++", "ilocal", "<", "maxLocals", ";", "if", "(", "!", "hasMoreVariables", "&&", "localDeclarations", "!=", "null", ")", "{", "return", "localDeclarations", ";", "}", "}", "}", "return", "null", ";", "}", "public", "LocalVariableBinding", "findVariable", "(", "char", "[", "]", "variableName", ")", "{", "int", "varLength", "=", "variableName", ".", "length", ";", "for", "(", "int", "i", "=", "this", ".", "localIndex", "-", "1", ";", "i", ">=", "0", ";", "i", "--", ")", "{", "LocalVariableBinding", "local", ";", "char", "[", "]", "localName", ";", "if", "(", "(", "localName", "=", "(", "local", "=", "this", ".", "locals", "[", "i", "]", ")", ".", "name", ")", ".", "length", "==", "varLength", "&&", "CharOperation", ".", "equals", "(", "localName", ",", "variableName", ")", ")", "return", "local", ";", "}", "return", "null", ";", "}", "public", "Binding", "getBinding", "(", "char", "[", "]", "[", "]", "compoundName", ",", "int", "mask", ",", "InvocationSite", "invocationSite", ",", "boolean", "needResolve", ")", "{", "Binding", "binding", "=", "getBinding", "(", "compoundName", "[", "0", "]", ",", "mask", "|", "Binding", ".", "TYPE", "|", "Binding", ".", "PACKAGE", ",", "invocationSite", ",", "needResolve", ")", ";", "invocationSite", ".", "setFieldIndex", "(", "1", ")", ";", "if", "(", "binding", "instanceof", "VariableBinding", ")", "return", "binding", ";", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordQualifiedReference", "(", "compoundName", ")", ";", "if", "(", "!", "binding", ".", "isValidBinding", "(", ")", ")", "return", "binding", ";", "int", "length", "=", "compoundName", ".", "length", ";", "int", "currentIndex", "=", "1", ";", "foundType", ":", "if", "(", "binding", "instanceof", "PackageBinding", ")", "{", "PackageBinding", "packageBinding", "=", "(", "PackageBinding", ")", "binding", ";", "while", "(", "currentIndex", "<", "length", ")", "{", "unitScope", ".", "recordReference", "(", "packageBinding", ".", "compoundName", ",", "compoundName", "[", "currentIndex", "]", ")", ";", "binding", "=", "packageBinding", ".", "getTypeOrPackage", "(", "compoundName", "[", "currentIndex", "++", "]", ")", ";", "invocationSite", ".", "setFieldIndex", "(", "currentIndex", ")", ";", "if", "(", "binding", "==", "null", ")", "{", "if", "(", "currentIndex", "==", "length", ")", "{", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "null", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "return", "new", "ProblemBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "if", "(", "binding", "instanceof", "ReferenceBinding", ")", "{", "if", "(", "!", "binding", ".", "isValidBinding", "(", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "(", "ReferenceBinding", ")", "(", "(", "ReferenceBinding", ")", "binding", ")", ".", "closestMatch", "(", ")", ",", "binding", ".", "problemId", "(", ")", ")", ";", "if", "(", "!", "(", "(", "ReferenceBinding", ")", "binding", ")", ".", "canBeSeenBy", "(", "this", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "(", "ReferenceBinding", ")", "binding", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "break", "foundType", ";", "}", "packageBinding", "=", "(", "PackageBinding", ")", "binding", ";", "}", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "null", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "ReferenceBinding", "referenceBinding", "=", "(", "ReferenceBinding", ")", "binding", ";", "binding", "=", "environment", "(", ")", ".", "convertToRawType", "(", "referenceBinding", ",", "false", ")", ";", "if", "(", "invocationSite", "instanceof", "ASTNode", ")", "{", "ASTNode", "invocationNode", "=", "(", "ASTNode", ")", "invocationSite", ";", "if", "(", "invocationNode", ".", "isTypeUseDeprecated", "(", "referenceBinding", ",", "this", ")", ")", "{", "problemReporter", "(", ")", ".", "deprecatedType", "(", "referenceBinding", ",", "invocationNode", ")", ";", "}", "}", "while", "(", "currentIndex", "<", "length", ")", "{", "referenceBinding", "=", "(", "ReferenceBinding", ")", "binding", ";", "char", "[", "]", "nextName", "=", "compoundName", "[", "currentIndex", "++", "]", ";", "invocationSite", ".", "setFieldIndex", "(", "currentIndex", ")", ";", "invocationSite", ".", "setActualReceiverType", "(", "referenceBinding", ")", ";", "if", "(", "(", "mask", "&", "Binding", ".", "FIELD", ")", "!=", "0", "&&", "(", "binding", "=", "findField", "(", "referenceBinding", ",", "nextName", ",", "invocationSite", ",", "true", ")", ")", "!=", "null", ")", "{", "if", "(", "!", "binding", ".", "isValidBinding", "(", ")", ")", "{", "return", "new", "ProblemFieldBinding", "(", "(", "(", "ProblemFieldBinding", ")", "binding", ")", ".", "closestMatch", ",", "(", "(", "ProblemFieldBinding", ")", "binding", ")", ".", "declaringClass", ",", "CharOperation", ".", "concatWith", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "'.'", ")", ",", "binding", ".", "problemId", "(", ")", ")", ";", "}", "break", ";", "}", "if", "(", "(", "binding", "=", "findMemberType", "(", "nextName", ",", "referenceBinding", ")", ")", "==", "null", ")", "{", "if", "(", "(", "mask", "&", "Binding", ".", "FIELD", ")", "!=", "0", ")", "{", "return", "new", "ProblemFieldBinding", "(", "null", ",", "referenceBinding", ",", "nextName", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "else", "if", "(", "(", "mask", "&", "Binding", ".", "VARIABLE", ")", "!=", "0", ")", "{", "return", "new", "ProblemBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "referenceBinding", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "referenceBinding", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "if", "(", "!", "binding", ".", "isValidBinding", "(", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "(", "ReferenceBinding", ")", "(", "(", "ReferenceBinding", ")", "binding", ")", ".", "closestMatch", "(", ")", ",", "binding", ".", "problemId", "(", ")", ")", ";", "if", "(", "invocationSite", "instanceof", "ASTNode", ")", "{", "referenceBinding", "=", "(", "ReferenceBinding", ")", "binding", ";", "ASTNode", "invocationNode", "=", "(", "ASTNode", ")", "invocationSite", ";", "if", "(", "invocationNode", ".", "isTypeUseDeprecated", "(", "referenceBinding", ",", "this", ")", ")", "{", "problemReporter", "(", ")", ".", "deprecatedType", "(", "referenceBinding", ",", "invocationNode", ")", ";", "}", "}", "}", "if", "(", "(", "mask", "&", "Binding", ".", "FIELD", ")", "!=", "0", "&&", "(", "binding", "instanceof", "FieldBinding", ")", ")", "{", "FieldBinding", "field", "=", "(", "FieldBinding", ")", "binding", ";", "if", "(", "!", "field", ".", "isStatic", "(", ")", ")", "return", "new", "ProblemFieldBinding", "(", "field", ",", "field", ".", "declaringClass", ",", "CharOperation", ".", "concatWith", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "'.'", ")", ",", "ProblemReasons", ".", "NonStaticReferenceInStaticContext", ")", ";", "return", "binding", ";", "}", "if", "(", "(", "mask", "&", "Binding", ".", "TYPE", ")", "!=", "0", "&&", "(", "binding", "instanceof", "ReferenceBinding", ")", ")", "{", "return", "binding", ";", "}", "return", "new", "ProblemBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "public", "final", "Binding", "getBinding", "(", "char", "[", "]", "[", "]", "compoundName", ",", "InvocationSite", "invocationSite", ")", "{", "int", "currentIndex", "=", "0", ";", "int", "length", "=", "compoundName", ".", "length", ";", "Binding", "binding", "=", "getBinding", "(", "compoundName", "[", "currentIndex", "++", "]", ",", "Binding", ".", "VARIABLE", "|", "Binding", ".", "TYPE", "|", "Binding", ".", "PACKAGE", ",", "invocationSite", ",", "true", ")", ";", "if", "(", "!", "binding", ".", "isValidBinding", "(", ")", ")", "return", "binding", ";", "foundType", ":", "if", "(", "binding", "instanceof", "PackageBinding", ")", "{", "while", "(", "currentIndex", "<", "length", ")", "{", "PackageBinding", "packageBinding", "=", "(", "PackageBinding", ")", "binding", ";", "binding", "=", "packageBinding", ".", "getTypeOrPackage", "(", "compoundName", "[", "currentIndex", "++", "]", ")", ";", "if", "(", "binding", "==", "null", ")", "{", "if", "(", "currentIndex", "==", "length", ")", "{", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "null", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "return", "new", "ProblemBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "if", "(", "binding", "instanceof", "ReferenceBinding", ")", "{", "if", "(", "!", "binding", ".", "isValidBinding", "(", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "(", "ReferenceBinding", ")", "(", "(", "ReferenceBinding", ")", "binding", ")", ".", "closestMatch", "(", ")", ",", "binding", ".", "problemId", "(", ")", ")", ";", "if", "(", "!", "(", "(", "ReferenceBinding", ")", "binding", ")", ".", "canBeSeenBy", "(", "this", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "(", "ReferenceBinding", ")", "binding", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "break", "foundType", ";", "}", "}", "return", "binding", ";", "}", "foundField", ":", "if", "(", "binding", "instanceof", "ReferenceBinding", ")", "{", "while", "(", "currentIndex", "<", "length", ")", "{", "ReferenceBinding", "typeBinding", "=", "(", "ReferenceBinding", ")", "binding", ";", "char", "[", "]", "nextName", "=", "compoundName", "[", "currentIndex", "++", "]", ";", "TypeBinding", "receiverType", "=", "typeBinding", ".", "capture", "(", "this", ",", "invocationSite", ".", "sourceEnd", "(", ")", ")", ";", "if", "(", "(", "binding", "=", "findField", "(", "receiverType", ",", "nextName", ",", "invocationSite", ",", "true", ")", ")", "!=", "null", ")", "{", "if", "(", "!", "binding", ".", "isValidBinding", "(", ")", ")", "{", "return", "new", "ProblemFieldBinding", "(", "(", "FieldBinding", ")", "binding", ",", "(", "(", "FieldBinding", ")", "binding", ")", ".", "declaringClass", ",", "CharOperation", ".", "concatWith", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "'.'", ")", ",", "binding", ".", "problemId", "(", ")", ")", ";", "}", "if", "(", "!", "(", "(", "FieldBinding", ")", "binding", ")", ".", "isStatic", "(", ")", ")", "return", "new", "ProblemFieldBinding", "(", "(", "FieldBinding", ")", "binding", ",", "(", "(", "FieldBinding", ")", "binding", ")", ".", "declaringClass", ",", "CharOperation", ".", "concatWith", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "'.'", ")", ",", "ProblemReasons", ".", "NonStaticReferenceInStaticContext", ")", ";", "break", "foundField", ";", "}", "if", "(", "(", "binding", "=", "findMemberType", "(", "nextName", ",", "typeBinding", ")", ")", "==", "null", ")", "{", "return", "new", "ProblemBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "typeBinding", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "if", "(", "!", "binding", ".", "isValidBinding", "(", ")", ")", "{", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "(", "ReferenceBinding", ")", "(", "(", "ReferenceBinding", ")", "binding", ")", ".", "closestMatch", "(", ")", ",", "binding", ".", "problemId", "(", ")", ")", ";", "}", "}", "return", "binding", ";", "}", "VariableBinding", "variableBinding", "=", "(", "VariableBinding", ")", "binding", ";", "while", "(", "currentIndex", "<", "length", ")", "{", "TypeBinding", "typeBinding", "=", "variableBinding", ".", "type", ";", "if", "(", "typeBinding", "==", "null", ")", "{", "return", "new", "ProblemFieldBinding", "(", "null", ",", "null", ",", "CharOperation", ".", "concatWith", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "'.'", ")", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "TypeBinding", "receiverType", "=", "typeBinding", ".", "capture", "(", "this", ",", "invocationSite", ".", "sourceEnd", "(", ")", ")", ";", "variableBinding", "=", "findField", "(", "receiverType", ",", "compoundName", "[", "currentIndex", "++", "]", ",", "invocationSite", ",", "true", ")", ";", "if", "(", "variableBinding", "==", "null", ")", "{", "return", "new", "ProblemFieldBinding", "(", "null", ",", "receiverType", "instanceof", "ReferenceBinding", "?", "(", "ReferenceBinding", ")", "receiverType", ":", "null", ",", "CharOperation", ".", "concatWith", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "'.'", ")", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "if", "(", "!", "variableBinding", ".", "isValidBinding", "(", ")", ")", "return", "variableBinding", ";", "}", "return", "variableBinding", ";", "}", "public", "VariableBinding", "[", "]", "getEmulationPath", "(", "LocalVariableBinding", "outerLocalVariable", ")", "{", "MethodScope", "currentMethodScope", "=", "methodScope", "(", ")", ";", "SourceTypeBinding", "sourceType", "=", "currentMethodScope", ".", "enclosingSourceType", "(", ")", ";", "BlockScope", "variableScope", "=", "outerLocalVariable", ".", "declaringScope", ";", "if", "(", "variableScope", "==", "null", "||", "currentMethodScope", "==", "variableScope", ".", "methodScope", "(", ")", ")", "{", "return", "new", "VariableBinding", "[", "]", "{", "outerLocalVariable", "}", ";", "}", "if", "(", "currentMethodScope", ".", "isInsideInitializerOrConstructor", "(", ")", "&&", "(", "sourceType", ".", "isNestedType", "(", ")", ")", ")", "{", "SyntheticArgumentBinding", "syntheticArg", ";", "if", "(", "(", "syntheticArg", "=", "(", "(", "NestedTypeBinding", ")", "sourceType", ")", ".", "getSyntheticArgument", "(", "outerLocalVariable", ")", ")", "!=", "null", ")", "{", "return", "new", "VariableBinding", "[", "]", "{", "syntheticArg", "}", ";", "}", "}", "if", "(", "!", "currentMethodScope", ".", "isStatic", ")", "{", "FieldBinding", "syntheticField", ";", "if", "(", "(", "syntheticField", "=", "sourceType", ".", "getSyntheticField", "(", "outerLocalVariable", ")", ")", "!=", "null", ")", "{", "return", "new", "VariableBinding", "[", "]", "{", "syntheticField", "}", ";", "}", "}", "return", "null", ";", "}", "public", "Object", "[", "]", "getEmulationPath", "(", "ReferenceBinding", "targetEnclosingType", ",", "boolean", "onlyExactMatch", ",", "boolean", "denyEnclosingArgInConstructorCall", ")", "{", "MethodScope", "currentMethodScope", "=", "methodScope", "(", ")", ";", "SourceTypeBinding", "sourceType", "=", "currentMethodScope", ".", "enclosingSourceType", "(", ")", ";", "if", "(", "!", "currentMethodScope", ".", "isStatic", "&&", "!", "currentMethodScope", ".", "isConstructorCall", ")", "{", "if", "(", "sourceType", "==", "targetEnclosingType", "||", "(", "!", "onlyExactMatch", "&&", "sourceType", ".", "findSuperTypeOriginatingFrom", "(", "targetEnclosingType", ")", "!=", "null", ")", ")", "{", "return", "BlockScope", ".", "EmulationPathToImplicitThis", ";", "}", "}", "if", "(", "!", "sourceType", ".", "isNestedType", "(", ")", "||", "sourceType", ".", "isStatic", "(", ")", ")", "{", "if", "(", "currentMethodScope", ".", "isConstructorCall", ")", "{", "return", "BlockScope", ".", "NoEnclosingInstanceInConstructorCall", ";", "}", "else", "if", "(", "currentMethodScope", ".", "isStatic", ")", "{", "return", "BlockScope", ".", "NoEnclosingInstanceInStaticContext", ";", "}", "return", "null", ";", "}", "boolean", "insideConstructor", "=", "currentMethodScope", ".", "isInsideInitializerOrConstructor", "(", ")", ";", "if", "(", "insideConstructor", ")", "{", "SyntheticArgumentBinding", "syntheticArg", ";", "if", "(", "(", "syntheticArg", "=", "(", "(", "NestedTypeBinding", ")", "sourceType", ")", ".", "getSyntheticArgument", "(", "targetEnclosingType", ",", "onlyExactMatch", ")", ")", "!=", "null", ")", "{", "if", "(", "denyEnclosingArgInConstructorCall", "&&", "currentMethodScope", ".", "isConstructorCall", "&&", "(", "sourceType", "==", "targetEnclosingType", "||", "(", "!", "onlyExactMatch", "&&", "sourceType", ".", "findSuperTypeOriginatingFrom", "(", "targetEnclosingType", ")", "!=", "null", ")", ")", ")", "{", "return", "BlockScope", ".", "NoEnclosingInstanceInConstructorCall", ";", "}", "return", "new", "Object", "[", "]", "{", "syntheticArg", "}", ";", "}", "}", "if", "(", "currentMethodScope", ".", "isStatic", ")", "{", "return", "BlockScope", ".", "NoEnclosingInstanceInStaticContext", ";", "}", "if", "(", "sourceType", ".", "isAnonymousType", "(", ")", ")", "{", "ReferenceBinding", "enclosingType", "=", "sourceType", ".", "enclosingType", "(", ")", ";", "if", "(", "enclosingType", ".", "isNestedType", "(", ")", ")", "{", "NestedTypeBinding", "nestedEnclosingType", "=", "(", "NestedTypeBinding", ")", "enclosingType", ";", "SyntheticArgumentBinding", "enclosingArgument", "=", "nestedEnclosingType", ".", "getSyntheticArgument", "(", "nestedEnclosingType", ".", "enclosingType", "(", ")", ",", "onlyExactMatch", ")", ";", "if", "(", "enclosingArgument", "!=", "null", ")", "{", "FieldBinding", "syntheticField", "=", "sourceType", ".", "getSyntheticField", "(", "enclosingArgument", ")", ";", "if", "(", "syntheticField", "!=", "null", ")", "{", "if", "(", "syntheticField", ".", "type", "==", "targetEnclosingType", "||", "(", "!", "onlyExactMatch", "&&", "(", "(", "ReferenceBinding", ")", "syntheticField", ".", "type", ")", ".", "findSuperTypeOriginatingFrom", "(", "targetEnclosingType", ")", "!=", "null", ")", ")", "return", "new", "Object", "[", "]", "{", "syntheticField", "}", ";", "}", "}", "}", "}", "FieldBinding", "syntheticField", "=", "sourceType", ".", "getSyntheticField", "(", "targetEnclosingType", ",", "onlyExactMatch", ")", ";", "if", "(", "syntheticField", "!=", "null", ")", "{", "if", "(", "currentMethodScope", ".", "isConstructorCall", ")", "{", "return", "BlockScope", ".", "NoEnclosingInstanceInConstructorCall", ";", "}", "return", "new", "Object", "[", "]", "{", "syntheticField", "}", ";", "}", "Object", "[", "]", "path", "=", "new", "Object", "[", "2", "]", ";", "ReferenceBinding", "currentType", "=", "sourceType", ".", "enclosingType", "(", ")", ";", "if", "(", "insideConstructor", ")", "{", "path", "[", "0", "]", "=", "(", "(", "NestedTypeBinding", ")", "sourceType", ")", ".", "getSyntheticArgument", "(", "currentType", ",", "onlyExactMatch", ")", ";", "}", "else", "{", "if", "(", "currentMethodScope", ".", "isConstructorCall", ")", "{", "return", "BlockScope", ".", "NoEnclosingInstanceInConstructorCall", ";", "}", "path", "[", "0", "]", "=", "sourceType", ".", "getSyntheticField", "(", "currentType", ",", "onlyExactMatch", ")", ";", "}", "if", "(", "path", "[", "0", "]", "!=", "null", ")", "{", "int", "count", "=", "1", ";", "ReferenceBinding", "currentEnclosingType", ";", "while", "(", "(", "currentEnclosingType", "=", "currentType", ".", "enclosingType", "(", ")", ")", "!=", "null", ")", "{", "if", "(", "currentType", "==", "targetEnclosingType", "||", "(", "!", "onlyExactMatch", "&&", "currentType", ".", "findSuperTypeOriginatingFrom", "(", "targetEnclosingType", ")", "!=", "null", ")", ")", "break", ";", "if", "(", "currentMethodScope", "!=", "null", ")", "{", "currentMethodScope", "=", "currentMethodScope", ".", "enclosingMethodScope", "(", ")", ";", "if", "(", "currentMethodScope", "!=", "null", "&&", "currentMethodScope", ".", "isConstructorCall", ")", "{", "return", "BlockScope", ".", "NoEnclosingInstanceInConstructorCall", ";", "}", "if", "(", "currentMethodScope", "!=", "null", "&&", "currentMethodScope", ".", "isStatic", ")", "{", "return", "BlockScope", ".", "NoEnclosingInstanceInStaticContext", ";", "}", "}", "syntheticField", "=", "(", "(", "NestedTypeBinding", ")", "currentType", ")", ".", "getSyntheticField", "(", "currentEnclosingType", ",", "onlyExactMatch", ")", ";", "if", "(", "syntheticField", "==", "null", ")", "break", ";", "if", "(", "count", "==", "path", ".", "length", ")", "{", "System", ".", "arraycopy", "(", "path", ",", "0", ",", "(", "path", "=", "new", "Object", "[", "count", "+", "1", "]", ")", ",", "0", ",", "count", ")", ";", "}", "path", "[", "count", "++", "]", "=", "(", "(", "SourceTypeBinding", ")", "syntheticField", ".", "declaringClass", ")", ".", "addSyntheticMethod", "(", "syntheticField", ",", "true", ",", "false", ")", ";", "currentType", "=", "currentEnclosingType", ";", "}", "if", "(", "currentType", "==", "targetEnclosingType", "||", "(", "!", "onlyExactMatch", "&&", "currentType", ".", "findSuperTypeOriginatingFrom", "(", "targetEnclosingType", ")", "!=", "null", ")", ")", "{", "return", "path", ";", "}", "}", "return", "null", ";", "}", "public", "final", "boolean", "isDuplicateLocalVariable", "(", "char", "[", "]", "name", ")", "{", "BlockScope", "current", "=", "this", ";", "while", "(", "true", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "localIndex", ";", "i", "++", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "name", ",", "current", ".", "locals", "[", "i", "]", ".", "name", ")", ")", "return", "true", ";", "}", "if", "(", "current", ".", "kind", "!=", "Scope", ".", "BLOCK_SCOPE", ")", "return", "false", ";", "current", "=", "(", "BlockScope", ")", "current", ".", "parent", ";", "}", "}", "public", "int", "maxShiftedOffset", "(", ")", "{", "int", "max", "=", "-", "1", ";", "if", "(", "this", ".", "shiftScopes", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "this", ".", "shiftScopes", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "int", "subMaxOffset", "=", "this", ".", "shiftScopes", "[", "i", "]", ".", "maxOffset", ";", "if", "(", "subMaxOffset", ">", "max", ")", "max", "=", "subMaxOffset", ";", "}", "}", "return", "max", ";", "}", "public", "final", "boolean", "needBlankFinalFieldInitializationCheck", "(", "FieldBinding", "binding", ")", "{", "boolean", "isStatic", "=", "binding", ".", "isStatic", "(", ")", ";", "ReferenceBinding", "fieldDeclaringClass", "=", "binding", ".", "declaringClass", ";", "MethodScope", "methodScope", "=", "methodScope", "(", ")", ";", "while", "(", "methodScope", "!=", "null", ")", "{", "if", "(", "methodScope", ".", "isStatic", "!=", "isStatic", ")", "return", "false", ";", "if", "(", "!", "methodScope", ".", "isInsideInitializer", "(", ")", "&&", "!", "(", "(", "AbstractMethodDeclaration", ")", "methodScope", ".", "referenceContext", ")", ".", "isInitializationMethod", "(", ")", ")", "{", "return", "false", ";", "}", "ReferenceBinding", "enclosingType", "=", "methodScope", ".", "enclosingReceiverType", "(", ")", ";", "if", "(", "enclosingType", "==", "fieldDeclaringClass", ")", "{", "return", "true", ";", "}", "if", "(", "!", "enclosingType", ".", "erasure", "(", ")", ".", "isAnonymousType", "(", ")", ")", "{", "return", "false", ";", "}", "methodScope", "=", "methodScope", ".", "enclosingMethodScope", "(", ")", ";", "}", "return", "false", ";", "}", "public", "ProblemReporter", "problemReporter", "(", ")", "{", "return", "outerMostMethodScope", "(", ")", ".", "problemReporter", "(", ")", ";", "}", "public", "void", "propagateInnerEmulation", "(", "ReferenceBinding", "targetType", ",", "boolean", "isEnclosingInstanceSupplied", ")", "{", "SyntheticArgumentBinding", "[", "]", "syntheticArguments", ";", "if", "(", "(", "syntheticArguments", "=", "targetType", ".", "syntheticOuterLocalVariables", "(", ")", ")", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "syntheticArguments", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "SyntheticArgumentBinding", "syntheticArg", "=", "syntheticArguments", "[", "i", "]", ";", "if", "(", "!", "(", "isEnclosingInstanceSupplied", "&&", "(", "syntheticArg", ".", "type", "==", "targetType", ".", "enclosingType", "(", ")", ")", ")", ")", "{", "emulateOuterAccess", "(", "syntheticArg", ".", "actualOuterLocalVariable", ")", ";", "}", "}", "}", "}", "public", "TypeDeclaration", "referenceType", "(", ")", "{", "return", "methodScope", "(", ")", ".", "referenceType", "(", ")", ";", "}", "public", "int", "scopeIndex", "(", ")", "{", "if", "(", "this", "instanceof", "MethodScope", ")", "return", "-", "1", ";", "BlockScope", "parentScope", "=", "(", "BlockScope", ")", "this", ".", "parent", ";", "Scope", "[", "]", "parentSubscopes", "=", "parentScope", ".", "subscopes", ";", "for", "(", "int", "i", "=", "0", ",", "max", "=", "parentScope", ".", "subscopeCount", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "parentSubscopes", "[", "i", "]", "==", "this", ")", "return", "i", ";", "}", "return", "-", "1", ";", "}", "int", "startIndex", "(", ")", "{", "return", "this", ".", "startIndex", ";", "}", "public", "String", "toString", "(", ")", "{", "return", "toString", "(", "0", ")", ";", "}", "public", "String", "toString", "(", "int", "tab", ")", "{", "String", "s", "=", "basicToString", "(", "tab", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "this", ".", "subscopeCount", ";", "i", "++", ")", "if", "(", "this", ".", "subscopes", "[", "i", "]", "instanceof", "BlockScope", ")", "s", "+=", "(", "(", "BlockScope", ")", "this", ".", "subscopes", "[", "i", "]", ")", ".", "toString", "(", "tab", "+", "1", ")", "+", "\"n\"", ";", "return", "s", ";", "}", "}", "</s>" ]
5,575
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "public", "class", "SignatureWrapper", "{", "public", "char", "[", "]", "signature", ";", "public", "int", "start", ";", "public", "int", "end", ";", "public", "int", "bracket", ";", "public", "SignatureWrapper", "(", "char", "[", "]", "signature", ")", "{", "this", ".", "signature", "=", "signature", ";", "this", ".", "start", "=", "0", ";", "this", ".", "end", "=", "this", ".", "bracket", "=", "-", "1", ";", "}", "public", "boolean", "atEnd", "(", ")", "{", "return", "this", ".", "start", "<", "0", "||", "this", ".", "start", ">=", "this", ".", "signature", ".", "length", ";", "}", "public", "int", "computeEnd", "(", ")", "{", "int", "index", "=", "this", ".", "start", ";", "while", "(", "this", ".", "signature", "[", "index", "]", "==", "'['", ")", "index", "++", ";", "switch", "(", "this", ".", "signature", "[", "index", "]", ")", "{", "case", "'L'", ":", "case", "'T'", ":", "this", ".", "end", "=", "CharOperation", ".", "indexOf", "(", "';'", ",", "this", ".", "signature", ",", "this", ".", "start", ")", ";", "if", "(", "this", ".", "bracket", "<=", "this", ".", "start", ")", "this", ".", "bracket", "=", "CharOperation", ".", "indexOf", "(", "'<'", ",", "this", ".", "signature", ",", "this", ".", "start", ")", ";", "if", "(", "this", ".", "bracket", ">", "this", ".", "start", "&&", "this", ".", "bracket", "<", "this", ".", "end", ")", "this", ".", "end", "=", "this", ".", "bracket", ";", "else", "if", "(", "this", ".", "end", "==", "-", "1", ")", "this", ".", "end", "=", "this", ".", "signature", ".", "length", "+", "1", ";", "break", ";", "default", ":", "this", ".", "end", "=", "this", ".", "start", ";", "}", "this", ".", "start", "=", "this", ".", "end", "+", "1", ";", "return", "this", ".", "end", ";", "}", "public", "char", "[", "]", "nextWord", "(", ")", "{", "this", ".", "end", "=", "CharOperation", ".", "indexOf", "(", "';'", ",", "this", ".", "signature", ",", "this", ".", "start", ")", ";", "if", "(", "this", ".", "bracket", "<=", "this", ".", "start", ")", "this", ".", "bracket", "=", "CharOperation", ".", "indexOf", "(", "'<'", ",", "this", ".", "signature", ",", "this", ".", "start", ")", ";", "int", "dot", "=", "CharOperation", ".", "indexOf", "(", "'.'", ",", "this", ".", "signature", ",", "this", ".", "start", ")", ";", "if", "(", "this", ".", "bracket", ">", "this", ".", "start", "&&", "this", ".", "bracket", "<", "this", ".", "end", ")", "this", ".", "end", "=", "this", ".", "bracket", ";", "if", "(", "dot", ">", "this", ".", "start", "&&", "dot", "<", "this", ".", "end", ")", "this", ".", "end", "=", "dot", ";", "return", "CharOperation", ".", "subarray", "(", "this", ".", "signature", ",", "this", ".", "start", ",", "this", ".", "start", "=", "this", ".", "end", ")", ";", "}", "public", "String", "toString", "(", ")", "{", "return", "new", "String", "(", "this", ".", "signature", ")", "+", "\"", "@", "\"", "+", "this", ".", "start", ";", "}", "}", "</s>" ]
5,576
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "public", "interface", "Substitution", "{", "TypeBinding", "substitute", "(", "TypeVariableBinding", "typeVariable", ")", ";", "LookupEnvironment", "environment", "(", ")", ";", "boolean", "isRawSubstitution", "(", ")", ";", "}", "</s>" ]
5,577
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "public", "class", "SyntheticArgumentBinding", "extends", "LocalVariableBinding", "{", "{", "this", ".", "tagBits", "|=", "TagBits", ".", "IsArgument", ";", "this", ".", "useFlag", "=", "USED", ";", "}", "public", "LocalVariableBinding", "actualOuterLocalVariable", ";", "public", "FieldBinding", "matchingField", ";", "public", "SyntheticArgumentBinding", "(", "LocalVariableBinding", "actualOuterLocalVariable", ")", "{", "super", "(", "CharOperation", ".", "concat", "(", "TypeConstants", ".", "SYNTHETIC_OUTER_LOCAL_PREFIX", ",", "actualOuterLocalVariable", ".", "name", ")", ",", "actualOuterLocalVariable", ".", "type", ",", "ClassFileConstants", ".", "AccFinal", ",", "true", ")", ";", "this", ".", "actualOuterLocalVariable", "=", "actualOuterLocalVariable", ";", "}", "public", "SyntheticArgumentBinding", "(", "ReferenceBinding", "enclosingType", ")", "{", "super", "(", "CharOperation", ".", "concat", "(", "TypeConstants", ".", "SYNTHETIC_ENCLOSING_INSTANCE_PREFIX", ",", "String", ".", "valueOf", "(", "enclosingType", ".", "depth", "(", ")", ")", ".", "toCharArray", "(", ")", ")", ",", "enclosingType", ",", "ClassFileConstants", ".", "AccFinal", ",", "true", ")", ";", "}", "}", "</s>" ]
5,578
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "public", "class", "ProblemFieldBinding", "extends", "FieldBinding", "{", "private", "int", "problemId", ";", "public", "FieldBinding", "closestMatch", ";", "public", "ProblemFieldBinding", "(", "ReferenceBinding", "declaringClass", ",", "char", "[", "]", "name", ",", "int", "problemId", ")", "{", "this", "(", "null", ",", "declaringClass", ",", "name", ",", "problemId", ")", ";", "}", "public", "ProblemFieldBinding", "(", "FieldBinding", "closestMatch", ",", "ReferenceBinding", "declaringClass", ",", "char", "[", "]", "name", ",", "int", "problemId", ")", "{", "this", ".", "closestMatch", "=", "closestMatch", ";", "this", ".", "declaringClass", "=", "declaringClass", ";", "this", ".", "name", "=", "name", ";", "this", ".", "problemId", "=", "problemId", ";", "}", "public", "final", "int", "problemId", "(", ")", "{", "return", "this", ".", "problemId", ";", "}", "}", "</s>" ]
5,579
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ASTNode", ";", "public", "interface", "TagBits", "{", "long", "IsArrayType", "=", "ASTNode", ".", "Bit1", ";", "long", "IsBaseType", "=", "ASTNode", ".", "Bit2", ";", "long", "IsNestedType", "=", "ASTNode", ".", "Bit3", ";", "long", "IsMemberType", "=", "ASTNode", ".", "Bit4", ";", "long", "ContainsNestedTypeReferences", "=", "ASTNode", ".", "Bit12", ";", "long", "MemberTypeMask", "=", "IsNestedType", "|", "IsMemberType", "|", "ContainsNestedTypeReferences", ";", "long", "IsLocalType", "=", "ASTNode", ".", "Bit5", ";", "long", "LocalTypeMask", "=", "IsNestedType", "|", "IsLocalType", "|", "ContainsNestedTypeReferences", ";", "long", "IsAnonymousType", "=", "ASTNode", ".", "Bit6", ";", "long", "AnonymousTypeMask", "=", "LocalTypeMask", "|", "IsAnonymousType", "|", "ContainsNestedTypeReferences", ";", "long", "IsBinaryBinding", "=", "ASTNode", ".", "Bit7", ";", "long", "HasMissingType", "=", "ASTNode", ".", "Bit8", ";", "long", "HasUncheckedTypeArgumentForBoundCheck", "=", "ASTNode", ".", "Bit9", ";", "long", "HasUnresolvedArguments", "=", "ASTNode", ".", "Bit10", ";", "long", "BeginHierarchyCheck", "=", "ASTNode", ".", "Bit9", ";", "long", "EndHierarchyCheck", "=", "ASTNode", ".", "Bit10", ";", "long", "PauseHierarchyCheck", "=", "ASTNode", ".", "Bit20", ";", "long", "HasParameterAnnotations", "=", "ASTNode", ".", "Bit11", ";", "long", "KnowsDefaultAbstractMethods", "=", "ASTNode", ".", "Bit11", ";", "long", "IsArgument", "=", "ASTNode", ".", "Bit11", ";", "long", "ClearPrivateModifier", "=", "ASTNode", ".", "Bit10", ";", "long", "AreFieldsSorted", "=", "ASTNode", ".", "Bit13", ";", "long", "AreFieldsComplete", "=", "ASTNode", ".", "Bit14", ";", "long", "AreMethodsSorted", "=", "ASTNode", ".", "Bit15", ";", "long", "AreMethodsComplete", "=", "ASTNode", ".", "Bit16", ";", "long", "HasNoMemberTypes", "=", "ASTNode", ".", "Bit17", ";", "long", "HierarchyHasProblems", "=", "ASTNode", ".", "Bit18", ";", "long", "TypeVariablesAreConnected", "=", "ASTNode", ".", "Bit19", ";", "long", "PassedBoundCheck", "=", "ASTNode", ".", "Bit23", ";", "long", "IsBoundParameterizedType", "=", "ASTNode", ".", "Bit24", ";", "long", "HasUnresolvedTypeVariables", "=", "ASTNode", ".", "Bit25", ";", "long", "HasUnresolvedSuperclass", "=", "ASTNode", ".", "Bit26", ";", "long", "HasUnresolvedSuperinterfaces", "=", "ASTNode", ".", "Bit27", ";", "long", "HasUnresolvedEnclosingType", "=", "ASTNode", ".", "Bit28", ";", "long", "HasUnresolvedMemberTypes", "=", "ASTNode", ".", "Bit29", ";", "long", "HasTypeVariable", "=", "ASTNode", ".", "Bit30", ";", "long", "HasDirectWildcard", "=", "ASTNode", ".", "Bit31", ";", "long", "BeginAnnotationCheck", "=", "ASTNode", ".", "Bit32L", ";", "long", "EndAnnotationCheck", "=", "ASTNode", ".", "Bit33L", ";", "long", "AnnotationResolved", "=", "ASTNode", ".", "Bit34L", ";", "long", "DeprecatedAnnotationResolved", "=", "ASTNode", ".", "Bit35L", ";", "long", "AnnotationTarget", "=", "ASTNode", ".", "Bit36L", ";", "long", "AnnotationForType", "=", "ASTNode", ".", "Bit37L", ";", "long", "AnnotationForField", "=", "ASTNode", ".", "Bit38L", ";", "long", "AnnotationForMethod", "=", "ASTNode", ".", "Bit39L", ";", "long", "AnnotationForParameter", "=", "ASTNode", ".", "Bit40L", ";", "long", "AnnotationForConstructor", "=", "ASTNode", ".", "Bit41L", ";", "long", "AnnotationForLocalVariable", "=", "ASTNode", ".", "Bit42L", ";", "long", "AnnotationForAnnotationType", "=", "ASTNode", ".", "Bit43L", ";", "long", "AnnotationForPackage", "=", "ASTNode", ".", "Bit44L", ";", "long", "AnnotationTargetMASK", "=", "AnnotationTarget", "|", "AnnotationForType", "|", "AnnotationForField", "|", "AnnotationForMethod", "|", "AnnotationForParameter", "|", "AnnotationForConstructor", "|", "AnnotationForLocalVariable", "|", "AnnotationForAnnotationType", "|", "AnnotationForPackage", ";", "long", "AnnotationSourceRetention", "=", "ASTNode", ".", "Bit45L", ";", "long", "AnnotationClassRetention", "=", "ASTNode", ".", "Bit46L", ";", "long", "AnnotationRuntimeRetention", "=", "AnnotationSourceRetention", "|", "AnnotationClassRetention", ";", "long", "AnnotationRetentionMASK", "=", "AnnotationSourceRetention", "|", "AnnotationClassRetention", "|", "AnnotationRuntimeRetention", ";", "long", "AnnotationDeprecated", "=", "ASTNode", ".", "Bit47L", ";", "long", "AnnotationDocumented", "=", "ASTNode", ".", "Bit48L", ";", "long", "AnnotationInherited", "=", "ASTNode", ".", "Bit49L", ";", "long", "AnnotationOverride", "=", "ASTNode", ".", "Bit50L", ";", "long", "AnnotationSuppressWarnings", "=", "ASTNode", ".", "Bit51L", ";", "long", "AllStandardAnnotationsMask", "=", "AnnotationTargetMASK", "|", "AnnotationRetentionMASK", "|", "AnnotationDeprecated", "|", "AnnotationDocumented", "|", "AnnotationInherited", "|", "AnnotationOverride", "|", "AnnotationSuppressWarnings", ";", "long", "DefaultValueResolved", "=", "ASTNode", ".", "Bit52L", ";", "long", "HasNonPrivateConstructor", "=", "ASTNode", ".", "Bit53L", ";", "}", "</s>" ]
5,580
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "public", "class", "ProblemMethodBinding", "extends", "MethodBinding", "{", "private", "int", "problemReason", ";", "public", "MethodBinding", "closestMatch", ";", "public", "ProblemMethodBinding", "(", "char", "[", "]", "selector", ",", "TypeBinding", "[", "]", "args", ",", "int", "problemReason", ")", "{", "this", ".", "selector", "=", "selector", ";", "this", ".", "parameters", "=", "(", "args", "==", "null", "||", "args", ".", "length", "==", "0", ")", "?", "Binding", ".", "NO_PARAMETERS", ":", "args", ";", "this", ".", "problemReason", "=", "problemReason", ";", "this", ".", "thrownExceptions", "=", "Binding", ".", "NO_EXCEPTIONS", ";", "}", "public", "ProblemMethodBinding", "(", "char", "[", "]", "selector", ",", "TypeBinding", "[", "]", "args", ",", "ReferenceBinding", "declaringClass", ",", "int", "problemReason", ")", "{", "this", ".", "selector", "=", "selector", ";", "this", ".", "parameters", "=", "(", "args", "==", "null", "||", "args", ".", "length", "==", "0", ")", "?", "Binding", ".", "NO_PARAMETERS", ":", "args", ";", "this", ".", "declaringClass", "=", "declaringClass", ";", "this", ".", "problemReason", "=", "problemReason", ";", "this", ".", "thrownExceptions", "=", "Binding", ".", "NO_EXCEPTIONS", ";", "}", "public", "ProblemMethodBinding", "(", "MethodBinding", "closestMatch", ",", "char", "[", "]", "selector", ",", "TypeBinding", "[", "]", "args", ",", "int", "problemReason", ")", "{", "this", "(", "selector", ",", "args", ",", "problemReason", ")", ";", "this", ".", "closestMatch", "=", "closestMatch", ";", "if", "(", "closestMatch", "!=", "null", "&&", "problemReason", "!=", "ProblemReasons", ".", "Ambiguous", ")", "this", ".", "declaringClass", "=", "closestMatch", ".", "declaringClass", ";", "}", "public", "final", "int", "problemId", "(", ")", "{", "return", "this", ".", "problemReason", ";", "}", "}", "</s>" ]
5,581
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "Constant", ";", "public", "final", "class", "ArrayBinding", "extends", "TypeBinding", "{", "public", "static", "final", "FieldBinding", "ArrayLength", "=", "new", "FieldBinding", "(", "TypeConstants", ".", "LENGTH", ",", "TypeBinding", ".", "INT", ",", "ClassFileConstants", ".", "AccPublic", "|", "ClassFileConstants", ".", "AccFinal", ",", "null", ",", "Constant", ".", "NotAConstant", ")", ";", "public", "TypeBinding", "leafComponentType", ";", "public", "int", "dimensions", ";", "LookupEnvironment", "environment", ";", "char", "[", "]", "constantPoolName", ";", "char", "[", "]", "genericTypeSignature", ";", "public", "ArrayBinding", "(", "TypeBinding", "type", ",", "int", "dimensions", ",", "LookupEnvironment", "environment", ")", "{", "this", ".", "tagBits", "|=", "TagBits", ".", "IsArrayType", ";", "this", ".", "leafComponentType", "=", "type", ";", "this", ".", "dimensions", "=", "dimensions", ";", "this", ".", "environment", "=", "environment", ";", "if", "(", "type", "instanceof", "UnresolvedReferenceBinding", ")", "(", "(", "UnresolvedReferenceBinding", ")", "type", ")", ".", "addWrapper", "(", "this", ",", "environment", ")", ";", "else", "this", ".", "tagBits", "|=", "type", ".", "tagBits", "&", "(", "TagBits", ".", "HasTypeVariable", "|", "TagBits", ".", "HasDirectWildcard", "|", "TagBits", ".", "HasMissingType", "|", "TagBits", ".", "ContainsNestedTypeReferences", ")", ";", "}", "public", "TypeBinding", "closestMatch", "(", ")", "{", "if", "(", "isValidBinding", "(", ")", ")", "{", "return", "this", ";", "}", "TypeBinding", "leafClosestMatch", "=", "this", ".", "leafComponentType", ".", "closestMatch", "(", ")", ";", "if", "(", "leafClosestMatch", "==", "null", ")", "{", "return", "null", ";", "}", "return", "this", ".", "environment", ".", "createArrayType", "(", "this", ".", "leafComponentType", ".", "closestMatch", "(", ")", ",", "this", ".", "dimensions", ")", ";", "}", "public", "List", "collectMissingTypes", "(", "List", "missingTypes", ")", "{", "if", "(", "(", "this", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "!=", "0", ")", "{", "missingTypes", "=", "this", ".", "leafComponentType", ".", "collectMissingTypes", "(", "missingTypes", ")", ";", "}", "return", "missingTypes", ";", "}", "public", "void", "collectSubstitutes", "(", "Scope", "scope", ",", "TypeBinding", "actualType", ",", "InferenceContext", "inferenceContext", ",", "int", "constraint", ")", "{", "if", "(", "(", "this", ".", "tagBits", "&", "TagBits", ".", "HasTypeVariable", ")", "==", "0", ")", "return", ";", "if", "(", "actualType", "==", "TypeBinding", ".", "NULL", ")", "return", ";", "switch", "(", "actualType", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "ARRAY_TYPE", ":", "int", "actualDim", "=", "actualType", ".", "dimensions", "(", ")", ";", "if", "(", "actualDim", "==", "this", ".", "dimensions", ")", "{", "this", ".", "leafComponentType", ".", "collectSubstitutes", "(", "scope", ",", "actualType", ".", "leafComponentType", "(", ")", ",", "inferenceContext", ",", "constraint", ")", ";", "}", "else", "if", "(", "actualDim", ">", "this", ".", "dimensions", ")", "{", "ArrayBinding", "actualReducedType", "=", "this", ".", "environment", ".", "createArrayType", "(", "actualType", ".", "leafComponentType", "(", ")", ",", "actualDim", "-", "this", ".", "dimensions", ")", ";", "this", ".", "leafComponentType", ".", "collectSubstitutes", "(", "scope", ",", "actualReducedType", ",", "inferenceContext", ",", "constraint", ")", ";", "}", "break", ";", "case", "Binding", ".", "TYPE_PARAMETER", ":", "break", ";", "}", "}", "public", "char", "[", "]", "computeUniqueKey", "(", "boolean", "isLeaf", ")", "{", "char", "[", "]", "brackets", "=", "new", "char", "[", "this", ".", "dimensions", "]", ";", "for", "(", "int", "i", "=", "this", ".", "dimensions", "-", "1", ";", "i", ">=", "0", ";", "i", "--", ")", "brackets", "[", "i", "]", "=", "'['", ";", "return", "CharOperation", ".", "concat", "(", "brackets", ",", "this", ".", "leafComponentType", ".", "computeUniqueKey", "(", "isLeaf", ")", ")", ";", "}", "public", "char", "[", "]", "constantPoolName", "(", ")", "{", "if", "(", "this", ".", "constantPoolName", "!=", "null", ")", "return", "this", ".", "constantPoolName", ";", "char", "[", "]", "brackets", "=", "new", "char", "[", "this", ".", "dimensions", "]", ";", "for", "(", "int", "i", "=", "this", ".", "dimensions", "-", "1", ";", "i", ">=", "0", ";", "i", "--", ")", "brackets", "[", "i", "]", "=", "'['", ";", "return", "this", ".", "constantPoolName", "=", "CharOperation", ".", "concat", "(", "brackets", ",", "this", ".", "leafComponentType", ".", "signature", "(", ")", ")", ";", "}", "public", "String", "debugName", "(", ")", "{", "StringBuffer", "brackets", "=", "new", "StringBuffer", "(", "this", ".", "dimensions", "*", "2", ")", ";", "for", "(", "int", "i", "=", "this", ".", "dimensions", ";", "--", "i", ">=", "0", ";", ")", "brackets", ".", "append", "(", "\"[]\"", ")", ";", "return", "this", ".", "leafComponentType", ".", "debugName", "(", ")", "+", "brackets", ".", "toString", "(", ")", ";", "}", "public", "int", "dimensions", "(", ")", "{", "return", "this", ".", "dimensions", ";", "}", "public", "TypeBinding", "elementsType", "(", ")", "{", "if", "(", "this", ".", "dimensions", "==", "1", ")", "return", "this", ".", "leafComponentType", ";", "return", "this", ".", "environment", ".", "createArrayType", "(", "this", ".", "leafComponentType", ",", "this", ".", "dimensions", "-", "1", ")", ";", "}", "public", "TypeBinding", "erasure", "(", ")", "{", "TypeBinding", "erasedType", "=", "this", ".", "leafComponentType", ".", "erasure", "(", ")", ";", "if", "(", "this", ".", "leafComponentType", "!=", "erasedType", ")", "return", "this", ".", "environment", ".", "createArrayType", "(", "erasedType", ",", "this", ".", "dimensions", ")", ";", "return", "this", ";", "}", "public", "LookupEnvironment", "environment", "(", ")", "{", "return", "this", ".", "environment", ";", "}", "public", "char", "[", "]", "genericTypeSignature", "(", ")", "{", "if", "(", "this", ".", "genericTypeSignature", "==", "null", ")", "{", "char", "[", "]", "brackets", "=", "new", "char", "[", "this", ".", "dimensions", "]", ";", "for", "(", "int", "i", "=", "this", ".", "dimensions", "-", "1", ";", "i", ">=", "0", ";", "i", "--", ")", "brackets", "[", "i", "]", "=", "'['", ";", "this", ".", "genericTypeSignature", "=", "CharOperation", ".", "concat", "(", "brackets", ",", "this", ".", "leafComponentType", ".", "genericTypeSignature", "(", ")", ")", ";", "}", "return", "this", ".", "genericTypeSignature", ";", "}", "public", "PackageBinding", "getPackage", "(", ")", "{", "return", "this", ".", "leafComponentType", ".", "getPackage", "(", ")", ";", "}", "public", "int", "hashCode", "(", ")", "{", "return", "this", ".", "leafComponentType", "==", "null", "?", "super", ".", "hashCode", "(", ")", ":", "this", ".", "leafComponentType", ".", "hashCode", "(", ")", ";", "}", "public", "boolean", "isCompatibleWith", "(", "TypeBinding", "otherType", ")", "{", "if", "(", "this", "==", "otherType", ")", "return", "true", ";", "switch", "(", "otherType", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "ARRAY_TYPE", ":", "ArrayBinding", "otherArray", "=", "(", "ArrayBinding", ")", "otherType", ";", "if", "(", "otherArray", ".", "leafComponentType", ".", "isBaseType", "(", ")", ")", "return", "false", ";", "if", "(", "this", ".", "dimensions", "==", "otherArray", ".", "dimensions", ")", "return", "this", ".", "leafComponentType", ".", "isCompatibleWith", "(", "otherArray", ".", "leafComponentType", ")", ";", "if", "(", "this", ".", "dimensions", "<", "otherArray", ".", "dimensions", ")", "return", "false", ";", "break", ";", "case", "Binding", ".", "BASE_TYPE", ":", "return", "false", ";", "case", "Binding", ".", "WILDCARD_TYPE", ":", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "return", "(", "(", "WildcardBinding", ")", "otherType", ")", ".", "boundCheck", "(", "this", ")", ";", "case", "Binding", ".", "TYPE_PARAMETER", ":", "if", "(", "otherType", ".", "isCapture", "(", ")", ")", "{", "CaptureBinding", "otherCapture", "=", "(", "CaptureBinding", ")", "otherType", ";", "TypeBinding", "otherLowerBound", ";", "if", "(", "(", "otherLowerBound", "=", "otherCapture", ".", "lowerBound", ")", "!=", "null", ")", "{", "if", "(", "!", "otherLowerBound", ".", "isArrayType", "(", ")", ")", "return", "false", ";", "return", "isCompatibleWith", "(", "otherLowerBound", ")", ";", "}", "}", "return", "false", ";", "}", "switch", "(", "otherType", ".", "leafComponentType", "(", ")", ".", "id", ")", "{", "case", "TypeIds", ".", "T_JavaLangObject", ":", "case", "TypeIds", ".", "T_JavaLangCloneable", ":", "case", "TypeIds", ".", "T_JavaIoSerializable", ":", "return", "true", ";", "}", "return", "false", ";", "}", "public", "int", "kind", "(", ")", "{", "return", "ARRAY_TYPE", ";", "}", "public", "TypeBinding", "leafComponentType", "(", ")", "{", "return", "this", ".", "leafComponentType", ";", "}", "public", "int", "problemId", "(", ")", "{", "return", "this", ".", "leafComponentType", ".", "problemId", "(", ")", ";", "}", "public", "char", "[", "]", "qualifiedSourceName", "(", ")", "{", "char", "[", "]", "brackets", "=", "new", "char", "[", "this", ".", "dimensions", "*", "2", "]", ";", "for", "(", "int", "i", "=", "this", ".", "dimensions", "*", "2", "-", "1", ";", "i", ">=", "0", ";", "i", "-=", "2", ")", "{", "brackets", "[", "i", "]", "=", "']'", ";", "brackets", "[", "i", "-", "1", "]", "=", "'['", ";", "}", "return", "CharOperation", ".", "concat", "(", "this", ".", "leafComponentType", ".", "qualifiedSourceName", "(", ")", ",", "brackets", ")", ";", "}", "public", "char", "[", "]", "readableName", "(", ")", "{", "char", "[", "]", "brackets", "=", "new", "char", "[", "this", ".", "dimensions", "*", "2", "]", ";", "for", "(", "int", "i", "=", "this", ".", "dimensions", "*", "2", "-", "1", ";", "i", ">=", "0", ";", "i", "-=", "2", ")", "{", "brackets", "[", "i", "]", "=", "']'", ";", "brackets", "[", "i", "-", "1", "]", "=", "'['", ";", "}", "return", "CharOperation", ".", "concat", "(", "this", ".", "leafComponentType", ".", "readableName", "(", ")", ",", "brackets", ")", ";", "}", "public", "char", "[", "]", "shortReadableName", "(", ")", "{", "char", "[", "]", "brackets", "=", "new", "char", "[", "this", ".", "dimensions", "*", "2", "]", ";", "for", "(", "int", "i", "=", "this", ".", "dimensions", "*", "2", "-", "1", ";", "i", ">=", "0", ";", "i", "-=", "2", ")", "{", "brackets", "[", "i", "]", "=", "']'", ";", "brackets", "[", "i", "-", "1", "]", "=", "'['", ";", "}", "return", "CharOperation", ".", "concat", "(", "this", ".", "leafComponentType", ".", "shortReadableName", "(", ")", ",", "brackets", ")", ";", "}", "public", "char", "[", "]", "sourceName", "(", ")", "{", "char", "[", "]", "brackets", "=", "new", "char", "[", "this", ".", "dimensions", "*", "2", "]", ";", "for", "(", "int", "i", "=", "this", ".", "dimensions", "*", "2", "-", "1", ";", "i", ">=", "0", ";", "i", "-=", "2", ")", "{", "brackets", "[", "i", "]", "=", "']'", ";", "brackets", "[", "i", "-", "1", "]", "=", "'['", ";", "}", "return", "CharOperation", ".", "concat", "(", "this", ".", "leafComponentType", ".", "sourceName", "(", ")", ",", "brackets", ")", ";", "}", "public", "void", "swapUnresolved", "(", "UnresolvedReferenceBinding", "unresolvedType", ",", "ReferenceBinding", "resolvedType", ",", "LookupEnvironment", "env", ")", "{", "if", "(", "this", ".", "leafComponentType", "==", "unresolvedType", ")", "{", "this", ".", "leafComponentType", "=", "env", ".", "convertUnresolvedBinaryToRawType", "(", "resolvedType", ")", ";", "this", ".", "tagBits", "|=", "this", ".", "leafComponentType", ".", "tagBits", "&", "(", "TagBits", ".", "HasTypeVariable", "|", "TagBits", ".", "HasDirectWildcard", "|", "TagBits", ".", "HasMissingType", ")", ";", "}", "}", "public", "String", "toString", "(", ")", "{", "return", "this", ".", "leafComponentType", "!=", "null", "?", "debugName", "(", ")", ":", "\"\"", ";", "}", "}", "</s>" ]
5,582
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "public", "interface", "ProblemReasons", "{", "final", "int", "NoError", "=", "0", ";", "final", "int", "NotFound", "=", "1", ";", "final", "int", "NotVisible", "=", "2", ";", "final", "int", "Ambiguous", "=", "3", ";", "final", "int", "InternalNameProvided", "=", "4", ";", "final", "int", "InheritedNameHidesEnclosingName", "=", "5", ";", "final", "int", "NonStaticReferenceInConstructorInvocation", "=", "6", ";", "final", "int", "NonStaticReferenceInStaticContext", "=", "7", ";", "final", "int", "ReceiverTypeNotVisible", "=", "8", ";", "final", "int", "IllegalSuperTypeVariable", "=", "9", ";", "final", "int", "ParameterBoundMismatch", "=", "10", ";", "final", "int", "TypeParameterArityMismatch", "=", "11", ";", "final", "int", "ParameterizedMethodTypeMismatch", "=", "12", ";", "final", "int", "TypeArgumentsForRawGenericMethod", "=", "13", ";", "final", "int", "InvalidTypeForStaticImport", "=", "14", ";", "}", "</s>" ]
5,583
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "Constant", ";", "public", "class", "ParameterizedFieldBinding", "extends", "FieldBinding", "{", "public", "FieldBinding", "originalField", ";", "public", "ParameterizedFieldBinding", "(", "ParameterizedTypeBinding", "parameterizedDeclaringClass", ",", "FieldBinding", "originalField", ")", "{", "super", "(", "originalField", ".", "name", ",", "(", "originalField", ".", "modifiers", "&", "ClassFileConstants", ".", "AccEnum", ")", "!=", "0", "?", "parameterizedDeclaringClass", ":", "(", "originalField", ".", "modifiers", "&", "ClassFileConstants", ".", "AccStatic", ")", "!=", "0", "?", "originalField", ".", "type", ":", "Scope", ".", "substitute", "(", "parameterizedDeclaringClass", ",", "originalField", ".", "type", ")", ",", "originalField", ".", "modifiers", ",", "parameterizedDeclaringClass", ",", "null", ")", ";", "this", ".", "originalField", "=", "originalField", ";", "this", ".", "tagBits", "=", "originalField", ".", "tagBits", ";", "this", ".", "id", "=", "originalField", ".", "id", ";", "}", "public", "Constant", "constant", "(", ")", "{", "return", "this", ".", "originalField", ".", "constant", "(", ")", ";", "}", "public", "FieldBinding", "original", "(", ")", "{", "return", "this", ".", "originalField", ".", "original", "(", ")", ";", "}", "public", "void", "setConstant", "(", "Constant", "constant", ")", "{", "this", ".", "originalField", ".", "setConstant", "(", "constant", ")", ";", "}", "}", "</s>" ]
5,584
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "public", "class", "MissingTypeBinding", "extends", "BinaryTypeBinding", "{", "public", "MissingTypeBinding", "(", "PackageBinding", "packageBinding", ",", "char", "[", "]", "[", "]", "compoundName", ",", "LookupEnvironment", "environment", ")", "{", "this", ".", "compoundName", "=", "compoundName", ";", "computeId", "(", ")", ";", "this", ".", "tagBits", "|=", "TagBits", ".", "IsBinaryBinding", "|", "TagBits", ".", "HierarchyHasProblems", "|", "TagBits", ".", "HasMissingType", ";", "this", ".", "environment", "=", "environment", ";", "this", ".", "fPackage", "=", "packageBinding", ";", "this", ".", "fileName", "=", "CharOperation", ".", "concatWith", "(", "compoundName", ",", "'/'", ")", ";", "this", ".", "sourceName", "=", "compoundName", "[", "compoundName", ".", "length", "-", "1", "]", ";", "this", ".", "modifiers", "=", "ClassFileConstants", ".", "AccPublic", ";", "this", ".", "superclass", "=", "null", ";", "this", ".", "superInterfaces", "=", "Binding", ".", "NO_SUPERINTERFACES", ";", "this", ".", "typeVariables", "=", "Binding", ".", "NO_TYPE_VARIABLES", ";", "this", ".", "memberTypes", "=", "Binding", ".", "NO_MEMBER_TYPES", ";", "this", ".", "fields", "=", "Binding", ".", "NO_FIELDS", ";", "this", ".", "methods", "=", "Binding", ".", "NO_METHODS", ";", "}", "public", "List", "collectMissingTypes", "(", "List", "missingTypes", ")", "{", "if", "(", "missingTypes", "==", "null", ")", "{", "missingTypes", "=", "new", "ArrayList", "(", "5", ")", ";", "}", "else", "if", "(", "missingTypes", ".", "contains", "(", "this", ")", ")", "{", "return", "missingTypes", ";", "}", "missingTypes", ".", "add", "(", "this", ")", ";", "return", "missingTypes", ";", "}", "public", "int", "problemId", "(", ")", "{", "return", "ProblemReasons", ".", "NotFound", ";", "}", "void", "setMissingSuperclass", "(", "ReferenceBinding", "missingSuperclass", ")", "{", "this", ".", "superclass", "=", "missingSuperclass", ";", "}", "public", "String", "toString", "(", ")", "{", "return", "\"[MISSING:\"", "+", "new", "String", "(", "CharOperation", ".", "concatWith", "(", "this", ".", "compoundName", ",", "'.'", ")", ")", "+", "\"]\"", ";", "}", "}", "</s>" ]
5,585
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Annotation", ";", "public", "class", "AnnotationBinding", "{", "ReferenceBinding", "type", ";", "ElementValuePair", "[", "]", "pairs", ";", "public", "static", "AnnotationBinding", "[", "]", "addStandardAnnotations", "(", "AnnotationBinding", "[", "]", "recordedAnnotations", ",", "long", "annotationTagBits", ",", "LookupEnvironment", "env", ")", "{", "int", "count", "=", "0", ";", "if", "(", "(", "annotationTagBits", "&", "TagBits", ".", "AnnotationTargetMASK", ")", "!=", "0", ")", "count", "++", ";", "if", "(", "(", "annotationTagBits", "&", "TagBits", ".", "AnnotationRetentionMASK", ")", "!=", "0", ")", "count", "++", ";", "if", "(", "(", "annotationTagBits", "&", "TagBits", ".", "AnnotationDeprecated", ")", "!=", "0", ")", "count", "++", ";", "if", "(", "(", "annotationTagBits", "&", "TagBits", ".", "AnnotationDocumented", ")", "!=", "0", ")", "count", "++", ";", "if", "(", "(", "annotationTagBits", "&", "TagBits", ".", "AnnotationInherited", ")", "!=", "0", ")", "count", "++", ";", "if", "(", "(", "annotationTagBits", "&", "TagBits", ".", "AnnotationOverride", ")", "!=", "0", ")", "count", "++", ";", "if", "(", "(", "annotationTagBits", "&", "TagBits", ".", "AnnotationSuppressWarnings", ")", "!=", "0", ")", "count", "++", ";", "if", "(", "count", "==", "0", ")", "return", "recordedAnnotations", ";", "int", "index", "=", "recordedAnnotations", ".", "length", ";", "AnnotationBinding", "[", "]", "result", "=", "new", "AnnotationBinding", "[", "index", "+", "count", "]", ";", "System", ".", "arraycopy", "(", "recordedAnnotations", ",", "0", ",", "result", ",", "0", ",", "index", ")", ";", "if", "(", "(", "annotationTagBits", "&", "TagBits", ".", "AnnotationTargetMASK", ")", "!=", "0", ")", "result", "[", "index", "++", "]", "=", "buildTargetAnnotation", "(", "annotationTagBits", ",", "env", ")", ";", "if", "(", "(", "annotationTagBits", "&", "TagBits", ".", "AnnotationRetentionMASK", ")", "!=", "0", ")", "result", "[", "index", "++", "]", "=", "buildRetentionAnnotation", "(", "annotationTagBits", ",", "env", ")", ";", "if", "(", "(", "annotationTagBits", "&", "TagBits", ".", "AnnotationDeprecated", ")", "!=", "0", ")", "result", "[", "index", "++", "]", "=", "buildMarkerAnnotation", "(", "TypeConstants", ".", "JAVA_LANG_DEPRECATED", ",", "env", ")", ";", "if", "(", "(", "annotationTagBits", "&", "TagBits", ".", "AnnotationDocumented", ")", "!=", "0", ")", "result", "[", "index", "++", "]", "=", "buildMarkerAnnotation", "(", "TypeConstants", ".", "JAVA_LANG_ANNOTATION_DOCUMENTED", ",", "env", ")", ";", "if", "(", "(", "annotationTagBits", "&", "TagBits", ".", "AnnotationInherited", ")", "!=", "0", ")", "result", "[", "index", "++", "]", "=", "buildMarkerAnnotation", "(", "TypeConstants", ".", "JAVA_LANG_ANNOTATION_INHERITED", ",", "env", ")", ";", "if", "(", "(", "annotationTagBits", "&", "TagBits", ".", "AnnotationOverride", ")", "!=", "0", ")", "result", "[", "index", "++", "]", "=", "buildMarkerAnnotation", "(", "TypeConstants", ".", "JAVA_LANG_OVERRIDE", ",", "env", ")", ";", "if", "(", "(", "annotationTagBits", "&", "TagBits", ".", "AnnotationSuppressWarnings", ")", "!=", "0", ")", "result", "[", "index", "++", "]", "=", "buildMarkerAnnotation", "(", "TypeConstants", ".", "JAVA_LANG_SUPPRESSWARNINGS", ",", "env", ")", ";", "return", "result", ";", "}", "private", "static", "AnnotationBinding", "buildMarkerAnnotation", "(", "char", "[", "]", "[", "]", "compoundName", ",", "LookupEnvironment", "env", ")", "{", "ReferenceBinding", "type", "=", "env", ".", "getResolvedType", "(", "compoundName", ",", "null", ")", ";", "return", "env", ".", "createAnnotation", "(", "type", ",", "Binding", ".", "NO_ELEMENT_VALUE_PAIRS", ")", ";", "}", "private", "static", "AnnotationBinding", "buildRetentionAnnotation", "(", "long", "bits", ",", "LookupEnvironment", "env", ")", "{", "ReferenceBinding", "retentionPolicy", "=", "env", ".", "getResolvedType", "(", "TypeConstants", ".", "JAVA_LANG_ANNOTATION_RETENTIONPOLICY", ",", "null", ")", ";", "Object", "value", "=", "null", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationRuntimeRetention", ")", "==", "TagBits", ".", "AnnotationRuntimeRetention", ")", "{", "value", "=", "retentionPolicy", ".", "getField", "(", "TypeConstants", ".", "UPPER_RUNTIME", ",", "true", ")", ";", "}", "else", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationClassRetention", ")", "!=", "0", ")", "{", "value", "=", "retentionPolicy", ".", "getField", "(", "TypeConstants", ".", "UPPER_CLASS", ",", "true", ")", ";", "}", "else", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationSourceRetention", ")", "!=", "0", ")", "{", "value", "=", "retentionPolicy", ".", "getField", "(", "TypeConstants", ".", "UPPER_SOURCE", ",", "true", ")", ";", "}", "return", "env", ".", "createAnnotation", "(", "env", ".", "getResolvedType", "(", "TypeConstants", ".", "JAVA_LANG_ANNOTATION_RETENTION", ",", "null", ")", ",", "new", "ElementValuePair", "[", "]", "{", "new", "ElementValuePair", "(", "TypeConstants", ".", "VALUE", ",", "value", ",", "null", ")", "}", ")", ";", "}", "private", "static", "AnnotationBinding", "buildTargetAnnotation", "(", "long", "bits", ",", "LookupEnvironment", "env", ")", "{", "ReferenceBinding", "target", "=", "env", ".", "getResolvedType", "(", "TypeConstants", ".", "JAVA_LANG_ANNOTATION_TARGET", ",", "null", ")", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationTarget", ")", "!=", "0", ")", "return", "new", "AnnotationBinding", "(", "target", ",", "Binding", ".", "NO_ELEMENT_VALUE_PAIRS", ")", ";", "int", "arraysize", "=", "0", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationForAnnotationType", ")", "!=", "0", ")", "arraysize", "++", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationForConstructor", ")", "!=", "0", ")", "arraysize", "++", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationForField", ")", "!=", "0", ")", "arraysize", "++", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationForLocalVariable", ")", "!=", "0", ")", "arraysize", "++", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationForMethod", ")", "!=", "0", ")", "arraysize", "++", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationForPackage", ")", "!=", "0", ")", "arraysize", "++", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationForParameter", ")", "!=", "0", ")", "arraysize", "++", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationForType", ")", "!=", "0", ")", "arraysize", "++", ";", "Object", "[", "]", "value", "=", "new", "Object", "[", "arraysize", "]", ";", "if", "(", "arraysize", ">", "0", ")", "{", "ReferenceBinding", "elementType", "=", "env", ".", "getResolvedType", "(", "TypeConstants", ".", "JAVA_LANG_ANNOTATION_ELEMENTTYPE", ",", "null", ")", ";", "int", "index", "=", "0", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationForAnnotationType", ")", "!=", "0", ")", "value", "[", "index", "++", "]", "=", "elementType", ".", "getField", "(", "TypeConstants", ".", "UPPER_ANNOTATION_TYPE", ",", "true", ")", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationForConstructor", ")", "!=", "0", ")", "value", "[", "index", "++", "]", "=", "elementType", ".", "getField", "(", "TypeConstants", ".", "UPPER_CONSTRUCTOR", ",", "true", ")", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationForField", ")", "!=", "0", ")", "value", "[", "index", "++", "]", "=", "elementType", ".", "getField", "(", "TypeConstants", ".", "UPPER_FIELD", ",", "true", ")", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationForLocalVariable", ")", "!=", "0", ")", "value", "[", "index", "++", "]", "=", "elementType", ".", "getField", "(", "TypeConstants", ".", "UPPER_LOCAL_VARIABLE", ",", "true", ")", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationForMethod", ")", "!=", "0", ")", "value", "[", "index", "++", "]", "=", "elementType", ".", "getField", "(", "TypeConstants", ".", "UPPER_METHOD", ",", "true", ")", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationForPackage", ")", "!=", "0", ")", "value", "[", "index", "++", "]", "=", "elementType", ".", "getField", "(", "TypeConstants", ".", "UPPER_PACKAGE", ",", "true", ")", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationForParameter", ")", "!=", "0", ")", "value", "[", "index", "++", "]", "=", "elementType", ".", "getField", "(", "TypeConstants", ".", "UPPER_PARAMETER", ",", "true", ")", ";", "if", "(", "(", "bits", "&", "TagBits", ".", "AnnotationForType", ")", "!=", "0", ")", "value", "[", "index", "++", "]", "=", "elementType", ".", "getField", "(", "TypeConstants", ".", "TYPE", ",", "true", ")", ";", "}", "return", "env", ".", "createAnnotation", "(", "target", ",", "new", "ElementValuePair", "[", "]", "{", "new", "ElementValuePair", "(", "TypeConstants", ".", "VALUE", ",", "value", ",", "null", ")", "}", ")", ";", "}", "AnnotationBinding", "(", "ReferenceBinding", "type", ",", "ElementValuePair", "[", "]", "pairs", ")", "{", "this", ".", "type", "=", "type", ";", "this", ".", "pairs", "=", "pairs", ";", "}", "AnnotationBinding", "(", "Annotation", "astAnnotation", ")", "{", "this", "(", "(", "ReferenceBinding", ")", "astAnnotation", ".", "resolvedType", ",", "astAnnotation", ".", "computeElementValuePairs", "(", ")", ")", ";", "}", "public", "char", "[", "]", "computeUniqueKey", "(", "char", "[", "]", "recipientKey", ")", "{", "char", "[", "]", "typeKey", "=", "this", ".", "type", ".", "computeUniqueKey", "(", "false", ")", ";", "int", "recipientKeyLength", "=", "recipientKey", ".", "length", ";", "char", "[", "]", "uniqueKey", "=", "new", "char", "[", "recipientKeyLength", "+", "1", "+", "typeKey", ".", "length", "]", ";", "System", ".", "arraycopy", "(", "recipientKey", ",", "0", ",", "uniqueKey", ",", "0", ",", "recipientKeyLength", ")", ";", "uniqueKey", "[", "recipientKeyLength", "]", "=", "'@'", ";", "System", ".", "arraycopy", "(", "typeKey", ",", "0", ",", "uniqueKey", ",", "recipientKeyLength", "+", "1", ",", "typeKey", ".", "length", ")", ";", "return", "uniqueKey", ";", "}", "public", "ReferenceBinding", "getAnnotationType", "(", ")", "{", "return", "this", ".", "type", ";", "}", "public", "ElementValuePair", "[", "]", "getElementValuePairs", "(", ")", "{", "return", "this", ".", "pairs", ";", "}", "public", "static", "void", "setMethodBindings", "(", "ReferenceBinding", "type", ",", "ElementValuePair", "[", "]", "pairs", ")", "{", "for", "(", "int", "i", "=", "pairs", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "{", "ElementValuePair", "pair", "=", "pairs", "[", "i", "]", ";", "MethodBinding", "[", "]", "methods", "=", "type", ".", "getMethods", "(", "pair", ".", "getName", "(", ")", ")", ";", "if", "(", "methods", "!=", "null", "&&", "methods", ".", "length", "==", "1", ")", "pair", ".", "setMethodBinding", "(", "methods", "[", "0", "]", ")", ";", "}", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", "5", ")", ";", "buffer", ".", "append", "(", "'@'", ")", ".", "append", "(", "this", ".", "type", ".", "sourceName", ")", ";", "if", "(", "this", ".", "pairs", "!=", "null", "&&", "this", ".", "pairs", ".", "length", ">", "0", ")", "{", "buffer", ".", "append", "(", "\"{", "\"", ")", ";", "for", "(", "int", "i", "=", "0", ",", "max", "=", "this", ".", "pairs", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "i", ">", "0", ")", "buffer", ".", "append", "(", "\",", "\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "pairs", "[", "i", "]", ")", ";", "}", "buffer", ".", "append", "(", "'}'", ")", ";", "}", "return", "buffer", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
5,586
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "public", "class", "InnerEmulationDependency", "{", "public", "BlockScope", "scope", ";", "public", "boolean", "wasEnclosingInstanceSupplied", ";", "public", "InnerEmulationDependency", "(", "BlockScope", "scope", ",", "boolean", "wasEnclosingInstanceSupplied", ")", "{", "this", ".", "scope", "=", "scope", ";", "this", ".", "wasEnclosingInstanceSupplied", "=", "wasEnclosingInstanceSupplied", ";", "}", "}", "</s>" ]
5,587
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "public", "class", "ProblemBinding", "extends", "Binding", "{", "public", "char", "[", "]", "name", ";", "public", "ReferenceBinding", "searchType", ";", "private", "int", "problemId", ";", "public", "ProblemBinding", "(", "char", "[", "]", "[", "]", "compoundName", ",", "int", "problemId", ")", "{", "this", "(", "CharOperation", ".", "concatWith", "(", "compoundName", ",", "'.'", ")", ",", "problemId", ")", ";", "}", "public", "ProblemBinding", "(", "char", "[", "]", "[", "]", "compoundName", ",", "ReferenceBinding", "searchType", ",", "int", "problemId", ")", "{", "this", "(", "CharOperation", ".", "concatWith", "(", "compoundName", ",", "'.'", ")", ",", "searchType", ",", "problemId", ")", ";", "}", "ProblemBinding", "(", "char", "[", "]", "name", ",", "int", "problemId", ")", "{", "this", ".", "name", "=", "name", ";", "this", ".", "problemId", "=", "problemId", ";", "}", "ProblemBinding", "(", "char", "[", "]", "name", ",", "ReferenceBinding", "searchType", ",", "int", "problemId", ")", "{", "this", "(", "name", ",", "problemId", ")", ";", "this", ".", "searchType", "=", "searchType", ";", "}", "public", "final", "int", "kind", "(", ")", "{", "return", "VARIABLE", "|", "TYPE", ";", "}", "public", "final", "int", "problemId", "(", ")", "{", "return", "this", ".", "problemId", ";", "}", "public", "char", "[", "]", "readableName", "(", ")", "{", "return", "this", ".", "name", ";", "}", "}", "</s>" ]
5,588
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ASTNode", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "public", "interface", "ExtraCompilerModifiers", "{", "final", "int", "AccJustFlag", "=", "0xFFFF", ";", "final", "int", "AccRestrictedAccess", "=", "ASTNode", ".", "Bit19", ";", "final", "int", "AccFromClassFile", "=", "ASTNode", ".", "Bit20", ";", "final", "int", "AccDefaultAbstract", "=", "ASTNode", ".", "Bit20", ";", "final", "int", "AccDeprecatedImplicitly", "=", "ASTNode", ".", "Bit22", ";", "final", "int", "AccAlternateModifierProblem", "=", "ASTNode", ".", "Bit23", ";", "final", "int", "AccModifierProblem", "=", "ASTNode", ".", "Bit24", ";", "final", "int", "AccSemicolonBody", "=", "ASTNode", ".", "Bit25", ";", "final", "int", "AccUnresolved", "=", "ASTNode", ".", "Bit26", ";", "final", "int", "AccBlankFinal", "=", "ASTNode", ".", "Bit27", ";", "final", "int", "AccIsDefaultConstructor", "=", "ASTNode", ".", "Bit27", ";", "final", "int", "AccLocallyUsed", "=", "ASTNode", ".", "Bit28", ";", "final", "int", "AccVisibilityMASK", "=", "ClassFileConstants", ".", "AccPublic", "|", "ClassFileConstants", ".", "AccProtected", "|", "ClassFileConstants", ".", "AccPrivate", ";", "final", "int", "AccOverriding", "=", "ASTNode", ".", "Bit29", ";", "final", "int", "AccImplementing", "=", "ASTNode", ".", "Bit30", ";", "final", "int", "AccGenericSignature", "=", "ASTNode", ".", "Bit31", ";", "}", "</s>" ]
5,589
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "java", ".", "lang", ".", "reflect", ".", "Field", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "public", "class", "ProblemReferenceBinding", "extends", "ReferenceBinding", "{", "ReferenceBinding", "closestMatch", ";", "private", "int", "problemReason", ";", "public", "ProblemReferenceBinding", "(", "char", "[", "]", "[", "]", "compoundName", ",", "ReferenceBinding", "closestMatch", ",", "int", "problemReason", ")", "{", "this", ".", "compoundName", "=", "compoundName", ";", "this", ".", "closestMatch", "=", "closestMatch", ";", "this", ".", "problemReason", "=", "problemReason", ";", "}", "public", "TypeBinding", "closestMatch", "(", ")", "{", "return", "this", ".", "closestMatch", ";", "}", "public", "ReferenceBinding", "closestReferenceMatch", "(", ")", "{", "return", "this", ".", "closestMatch", ";", "}", "public", "int", "problemId", "(", ")", "{", "return", "this", ".", "problemReason", ";", "}", "public", "static", "String", "problemReasonString", "(", "int", "problemReason", ")", "{", "try", "{", "Class", "reasons", "=", "ProblemReasons", ".", "class", ";", "String", "simpleName", "=", "reasons", ".", "getName", "(", ")", ";", "int", "lastDot", "=", "simpleName", ".", "lastIndexOf", "(", "'.'", ")", ";", "if", "(", "lastDot", ">=", "0", ")", "{", "simpleName", "=", "simpleName", ".", "substring", "(", "lastDot", "+", "1", ")", ";", "}", "Field", "[", "]", "fields", "=", "reasons", ".", "getFields", "(", ")", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "fields", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "Field", "field", "=", "fields", "[", "i", "]", ";", "if", "(", "!", "field", ".", "getType", "(", ")", ".", "equals", "(", "int", ".", "class", ")", ")", "continue", ";", "if", "(", "field", ".", "getInt", "(", "reasons", ")", "==", "problemReason", ")", "{", "return", "simpleName", "+", "'.'", "+", "field", ".", "getName", "(", ")", ";", "}", "}", "}", "catch", "(", "IllegalAccessException", "e", ")", "{", "}", "return", "\"unknown\"", ";", "}", "public", "char", "[", "]", "shortReadableName", "(", ")", "{", "return", "readableName", "(", ")", ";", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", "10", ")", ";", "buffer", ".", "append", "(", "\"\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "compoundName", "==", "null", "?", "\"<null>\"", ":", "new", "String", "(", "CharOperation", ".", "concatWith", "(", "this", ".", "compoundName", ",", "'.'", ")", ")", ")", ";", "buffer", ".", "append", "(", "\"][problemID=\"", ")", ".", "append", "(", "problemReasonString", "(", "this", ".", "problemReason", ")", ")", ";", "buffer", ".", "append", "(", "\"\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "closestMatch", "==", "null", "?", "\"<null>\"", ":", "this", ".", "closestMatch", ".", "toString", "(", ")", ")", ";", "buffer", ".", "append", "(", "\"]\"", ")", ";", "return", "buffer", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
5,590
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "public", "class", "RawTypeBinding", "extends", "ParameterizedTypeBinding", "{", "public", "RawTypeBinding", "(", "ReferenceBinding", "type", ",", "ReferenceBinding", "enclosingType", ",", "LookupEnvironment", "environment", ")", "{", "super", "(", "type", ",", "null", ",", "enclosingType", ",", "environment", ")", ";", "this", ".", "tagBits", "&=", "~", "TagBits", ".", "HasMissingType", ";", "if", "(", "(", "type", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "!=", "0", ")", "{", "if", "(", "type", "instanceof", "MissingTypeBinding", ")", "{", "this", ".", "tagBits", "|=", "TagBits", ".", "HasMissingType", ";", "}", "else", "if", "(", "type", "instanceof", "ParameterizedTypeBinding", ")", "{", "ParameterizedTypeBinding", "parameterizedTypeBinding", "=", "(", "ParameterizedTypeBinding", ")", "type", ";", "if", "(", "parameterizedTypeBinding", ".", "genericType", "(", ")", "instanceof", "MissingTypeBinding", ")", "{", "this", ".", "tagBits", "|=", "TagBits", ".", "HasMissingType", ";", "}", "}", "}", "if", "(", "enclosingType", "!=", "null", "&&", "(", "enclosingType", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "!=", "0", ")", "{", "if", "(", "enclosingType", "instanceof", "MissingTypeBinding", ")", "{", "this", ".", "tagBits", "|=", "TagBits", ".", "HasMissingType", ";", "}", "else", "if", "(", "enclosingType", "instanceof", "ParameterizedTypeBinding", ")", "{", "ParameterizedTypeBinding", "parameterizedTypeBinding", "=", "(", "ParameterizedTypeBinding", ")", "enclosingType", ";", "if", "(", "parameterizedTypeBinding", ".", "genericType", "(", ")", "instanceof", "MissingTypeBinding", ")", "{", "this", ".", "tagBits", "|=", "TagBits", ".", "HasMissingType", ";", "}", "}", "}", "if", "(", "enclosingType", "==", "null", "||", "(", "enclosingType", ".", "modifiers", "&", "ExtraCompilerModifiers", ".", "AccGenericSignature", ")", "==", "0", ")", "{", "this", ".", "modifiers", "&=", "~", "ExtraCompilerModifiers", ".", "AccGenericSignature", ";", "}", "}", "public", "char", "[", "]", "computeUniqueKey", "(", "boolean", "isLeaf", ")", "{", "StringBuffer", "sig", "=", "new", "StringBuffer", "(", "10", ")", ";", "if", "(", "isMemberType", "(", ")", "&&", "enclosingType", "(", ")", ".", "isParameterizedType", "(", ")", ")", "{", "char", "[", "]", "typeSig", "=", "enclosingType", "(", ")", ".", "computeUniqueKey", "(", "false", ")", ";", "sig", ".", "append", "(", "typeSig", ",", "0", ",", "typeSig", ".", "length", "-", "1", ")", ";", "sig", ".", "append", "(", "'.'", ")", ".", "append", "(", "sourceName", "(", ")", ")", ".", "append", "(", "'<'", ")", ".", "append", "(", "'>'", ")", ".", "append", "(", "';'", ")", ";", "}", "else", "{", "sig", ".", "append", "(", "genericType", "(", ")", ".", "computeUniqueKey", "(", "false", ")", ")", ";", "sig", ".", "insert", "(", "sig", ".", "length", "(", ")", "-", "1", ",", "\"<>\"", ")", ";", "}", "int", "sigLength", "=", "sig", ".", "length", "(", ")", ";", "char", "[", "]", "uniqueKey", "=", "new", "char", "[", "sigLength", "]", ";", "sig", ".", "getChars", "(", "0", ",", "sigLength", ",", "uniqueKey", ",", "0", ")", ";", "return", "uniqueKey", ";", "}", "public", "ParameterizedMethodBinding", "createParameterizedMethod", "(", "MethodBinding", "originalMethod", ")", "{", "if", "(", "originalMethod", ".", "typeVariables", "==", "Binding", ".", "NO_TYPE_VARIABLES", "||", "originalMethod", ".", "isStatic", "(", ")", ")", "{", "return", "super", ".", "createParameterizedMethod", "(", "originalMethod", ")", ";", "}", "return", "this", ".", "environment", ".", "createParameterizedGenericMethod", "(", "originalMethod", ",", "this", ")", ";", "}", "public", "int", "kind", "(", ")", "{", "return", "RAW_TYPE", ";", "}", "public", "String", "debugName", "(", ")", "{", "StringBuffer", "nameBuffer", "=", "new", "StringBuffer", "(", "10", ")", ";", "nameBuffer", ".", "append", "(", "actualType", "(", ")", ".", "sourceName", "(", ")", ")", ".", "append", "(", "\"#RAW\"", ")", ";", "return", "nameBuffer", ".", "toString", "(", ")", ";", "}", "public", "char", "[", "]", "genericTypeSignature", "(", ")", "{", "if", "(", "this", ".", "genericTypeSignature", "==", "null", ")", "{", "if", "(", "(", "this", ".", "modifiers", "&", "ExtraCompilerModifiers", ".", "AccGenericSignature", ")", "==", "0", ")", "{", "this", ".", "genericTypeSignature", "=", "genericType", "(", ")", ".", "signature", "(", ")", ";", "}", "else", "{", "StringBuffer", "sig", "=", "new", "StringBuffer", "(", "10", ")", ";", "if", "(", "isMemberType", "(", ")", ")", "{", "ReferenceBinding", "enclosing", "=", "enclosingType", "(", ")", ";", "char", "[", "]", "typeSig", "=", "enclosing", ".", "genericTypeSignature", "(", ")", ";", "sig", ".", "append", "(", "typeSig", ",", "0", ",", "typeSig", ".", "length", "-", "1", ")", ";", "if", "(", "(", "enclosing", ".", "modifiers", "&", "ExtraCompilerModifiers", ".", "AccGenericSignature", ")", "!=", "0", ")", "{", "sig", ".", "append", "(", "'.'", ")", ";", "}", "else", "{", "sig", ".", "append", "(", "'$'", ")", ";", "}", "sig", ".", "append", "(", "sourceName", "(", ")", ")", ";", "}", "else", "{", "char", "[", "]", "typeSig", "=", "genericType", "(", ")", ".", "signature", "(", ")", ";", "sig", ".", "append", "(", "typeSig", ",", "0", ",", "typeSig", ".", "length", "-", "1", ")", ";", "}", "sig", ".", "append", "(", "';'", ")", ";", "int", "sigLength", "=", "sig", ".", "length", "(", ")", ";", "this", ".", "genericTypeSignature", "=", "new", "char", "[", "sigLength", "]", ";", "sig", ".", "getChars", "(", "0", ",", "sigLength", ",", "this", ".", "genericTypeSignature", ",", "0", ")", ";", "}", "}", "return", "this", ".", "genericTypeSignature", ";", "}", "public", "boolean", "isEquivalentTo", "(", "TypeBinding", "otherType", ")", "{", "if", "(", "this", "==", "otherType", ")", "return", "true", ";", "if", "(", "otherType", "==", "null", ")", "return", "false", ";", "switch", "(", "otherType", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "WILDCARD_TYPE", ":", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "return", "(", "(", "WildcardBinding", ")", "otherType", ")", ".", "boundCheck", "(", "this", ")", ";", "case", "Binding", ".", "GENERIC_TYPE", ":", "case", "Binding", ".", "PARAMETERIZED_TYPE", ":", "case", "Binding", ".", "RAW_TYPE", ":", "return", "erasure", "(", ")", "==", "otherType", ".", "erasure", "(", ")", ";", "}", "return", "false", ";", "}", "public", "boolean", "isProvablyDistinct", "(", "TypeBinding", "otherType", ")", "{", "if", "(", "this", "==", "otherType", ")", "return", "false", ";", "if", "(", "otherType", "==", "null", ")", "return", "true", ";", "switch", "(", "otherType", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "GENERIC_TYPE", ":", "case", "Binding", ".", "PARAMETERIZED_TYPE", ":", "case", "Binding", ".", "RAW_TYPE", ":", "return", "erasure", "(", ")", "!=", "otherType", ".", "erasure", "(", ")", ";", "}", "return", "true", ";", "}", "protected", "void", "initializeArguments", "(", ")", "{", "TypeVariableBinding", "[", "]", "typeVariables", "=", "genericType", "(", ")", ".", "typeVariables", "(", ")", ";", "int", "length", "=", "typeVariables", ".", "length", ";", "TypeBinding", "[", "]", "typeArguments", "=", "new", "TypeBinding", "[", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "typeArguments", "[", "i", "]", "=", "this", ".", "environment", ".", "convertToRawType", "(", "typeVariables", "[", "i", "]", ".", "erasure", "(", ")", ",", "false", ")", ";", "}", "this", ".", "arguments", "=", "typeArguments", ";", "}", "public", "char", "[", "]", "readableName", "(", ")", "{", "char", "[", "]", "readableName", ";", "if", "(", "isMemberType", "(", ")", ")", "{", "readableName", "=", "CharOperation", ".", "concat", "(", "enclosingType", "(", ")", ".", "readableName", "(", ")", ",", "this", ".", "sourceName", ",", "'.'", ")", ";", "}", "else", "{", "readableName", "=", "CharOperation", ".", "concatWith", "(", "actualType", "(", ")", ".", "compoundName", ",", "'.'", ")", ";", "}", "return", "readableName", ";", "}", "public", "char", "[", "]", "shortReadableName", "(", ")", "{", "char", "[", "]", "shortReadableName", ";", "if", "(", "isMemberType", "(", ")", ")", "{", "shortReadableName", "=", "CharOperation", ".", "concat", "(", "enclosingType", "(", ")", ".", "shortReadableName", "(", ")", ",", "this", ".", "sourceName", ",", "'.'", ")", ";", "}", "else", "{", "shortReadableName", "=", "actualType", "(", ")", ".", "sourceName", ";", "}", "return", "shortReadableName", ";", "}", "}", "</s>" ]
5,591
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CompilerOptions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemReporter", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "HashtableOfObject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "SimpleSet", ";", "public", "class", "MethodVerifier", "{", "SourceTypeBinding", "type", ";", "HashtableOfObject", "inheritedMethods", ";", "HashtableOfObject", "currentMethods", ";", "LookupEnvironment", "environment", ";", "private", "boolean", "allowCompatibleReturnTypes", ";", "MethodVerifier", "(", "LookupEnvironment", "environment", ")", "{", "this", ".", "type", "=", "null", ";", "this", ".", "inheritedMethods", "=", "null", ";", "this", ".", "currentMethods", "=", "null", ";", "this", ".", "environment", "=", "environment", ";", "this", ".", "allowCompatibleReturnTypes", "=", "environment", ".", "globalOptions", ".", "complianceLevel", ">=", "ClassFileConstants", ".", "JDK1_5", "&&", "environment", ".", "globalOptions", ".", "sourceLevel", "<", "ClassFileConstants", ".", "JDK1_5", ";", "}", "boolean", "areMethodsCompatible", "(", "MethodBinding", "one", ",", "MethodBinding", "two", ")", "{", "return", "isParameterSubsignature", "(", "one", ",", "two", ")", "&&", "areReturnTypesCompatible", "(", "one", ",", "two", ")", ";", "}", "boolean", "areParametersEqual", "(", "MethodBinding", "one", ",", "MethodBinding", "two", ")", "{", "TypeBinding", "[", "]", "oneArgs", "=", "one", ".", "parameters", ";", "TypeBinding", "[", "]", "twoArgs", "=", "two", ".", "parameters", ";", "if", "(", "oneArgs", "==", "twoArgs", ")", "return", "true", ";", "int", "length", "=", "oneArgs", ".", "length", ";", "if", "(", "length", "!=", "twoArgs", ".", "length", ")", "return", "false", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "if", "(", "!", "areTypesEqual", "(", "oneArgs", "[", "i", "]", ",", "twoArgs", "[", "i", "]", ")", ")", "return", "false", ";", "return", "true", ";", "}", "boolean", "areReturnTypesCompatible", "(", "MethodBinding", "one", ",", "MethodBinding", "two", ")", "{", "if", "(", "one", ".", "returnType", "==", "two", ".", "returnType", ")", "return", "true", ";", "if", "(", "areTypesEqual", "(", "one", ".", "returnType", ",", "two", ".", "returnType", ")", ")", "return", "true", ";", "if", "(", "this", ".", "allowCompatibleReturnTypes", "&&", "one", ".", "declaringClass", "instanceof", "BinaryTypeBinding", "&&", "two", ".", "declaringClass", "instanceof", "BinaryTypeBinding", ")", "{", "return", "areReturnTypesCompatible0", "(", "one", ",", "two", ")", ";", "}", "return", "false", ";", "}", "boolean", "areReturnTypesCompatible0", "(", "MethodBinding", "one", ",", "MethodBinding", "two", ")", "{", "if", "(", "one", ".", "returnType", ".", "isBaseType", "(", ")", ")", "return", "false", ";", "if", "(", "!", "one", ".", "declaringClass", ".", "isInterface", "(", ")", "&&", "one", ".", "declaringClass", ".", "id", "==", "TypeIds", ".", "T_JavaLangObject", ")", "return", "two", ".", "returnType", ".", "isCompatibleWith", "(", "one", ".", "returnType", ")", ";", "return", "one", ".", "returnType", ".", "isCompatibleWith", "(", "two", ".", "returnType", ")", ";", "}", "boolean", "areTypesEqual", "(", "TypeBinding", "one", ",", "TypeBinding", "two", ")", "{", "if", "(", "one", "==", "two", ")", "return", "true", ";", "if", "(", "one", "instanceof", "UnresolvedReferenceBinding", ")", "return", "(", "(", "UnresolvedReferenceBinding", ")", "one", ")", ".", "resolvedType", "==", "two", ";", "if", "(", "two", "instanceof", "UnresolvedReferenceBinding", ")", "return", "(", "(", "UnresolvedReferenceBinding", ")", "two", ")", ".", "resolvedType", "==", "one", ";", "return", "false", ";", "}", "boolean", "canSkipInheritedMethods", "(", ")", "{", "if", "(", "this", ".", "type", ".", "superclass", "(", ")", "!=", "null", "&&", "this", ".", "type", ".", "superclass", "(", ")", ".", "isAbstract", "(", ")", ")", "return", "false", ";", "return", "this", ".", "type", ".", "superInterfaces", "(", ")", "==", "Binding", ".", "NO_SUPERINTERFACES", ";", "}", "boolean", "canSkipInheritedMethods", "(", "MethodBinding", "one", ",", "MethodBinding", "two", ")", "{", "return", "two", "==", "null", "||", "one", ".", "declaringClass", "==", "two", ".", "declaringClass", ";", "}", "void", "checkAbstractMethod", "(", "MethodBinding", "abstractMethod", ")", "{", "if", "(", "mustImplementAbstractMethod", "(", "abstractMethod", ".", "declaringClass", ")", ")", "{", "TypeDeclaration", "typeDeclaration", "=", "this", ".", "type", ".", "scope", ".", "referenceContext", ";", "if", "(", "typeDeclaration", "!=", "null", ")", "{", "MethodDeclaration", "missingAbstractMethod", "=", "typeDeclaration", ".", "addMissingAbstractMethodFor", "(", "abstractMethod", ")", ";", "missingAbstractMethod", ".", "scope", ".", "problemReporter", "(", ")", ".", "abstractMethodMustBeImplemented", "(", "this", ".", "type", ",", "abstractMethod", ")", ";", "}", "else", "{", "problemReporter", "(", ")", ".", "abstractMethodMustBeImplemented", "(", "this", ".", "type", ",", "abstractMethod", ")", ";", "}", "}", "}", "void", "checkAgainstInheritedMethods", "(", "MethodBinding", "currentMethod", ",", "MethodBinding", "[", "]", "methods", ",", "int", "length", ",", "MethodBinding", "[", "]", "allInheritedMethods", ")", "{", "if", "(", "this", ".", "type", ".", "isAnnotationType", "(", ")", ")", "{", "problemReporter", "(", ")", ".", "annotationCannotOverrideMethod", "(", "currentMethod", ",", "methods", "[", "length", "-", "1", "]", ")", ";", "return", ";", "}", "CompilerOptions", "options", "=", "this", ".", "type", ".", "scope", ".", "compilerOptions", "(", ")", ";", "int", "[", "]", "overriddenInheritedMethods", "=", "length", ">", "1", "?", "findOverriddenInheritedMethods", "(", "methods", ",", "length", ")", ":", "null", ";", "nextMethod", ":", "for", "(", "int", "i", "=", "length", ";", "--", "i", ">=", "0", ";", ")", "{", "MethodBinding", "inheritedMethod", "=", "methods", "[", "i", "]", ";", "if", "(", "overriddenInheritedMethods", "==", "null", "||", "overriddenInheritedMethods", "[", "i", "]", "==", "0", ")", "{", "if", "(", "currentMethod", ".", "isStatic", "(", ")", "!=", "inheritedMethod", ".", "isStatic", "(", ")", ")", "{", "problemReporter", "(", "currentMethod", ")", ".", "staticAndInstanceConflict", "(", "currentMethod", ",", "inheritedMethod", ")", ";", "continue", "nextMethod", ";", "}", "if", "(", "inheritedMethod", ".", "isAbstract", "(", ")", ")", "{", "if", "(", "inheritedMethod", ".", "declaringClass", ".", "isInterface", "(", ")", ")", "{", "currentMethod", ".", "modifiers", "|=", "ExtraCompilerModifiers", ".", "AccImplementing", ";", "}", "else", "{", "currentMethod", ".", "modifiers", "|=", "ExtraCompilerModifiers", ".", "AccImplementing", "|", "ExtraCompilerModifiers", ".", "AccOverriding", ";", "}", "}", "else", "if", "(", "inheritedMethod", ".", "isPublic", "(", ")", "||", "!", "this", ".", "type", ".", "isInterface", "(", ")", ")", "{", "currentMethod", ".", "modifiers", "|=", "ExtraCompilerModifiers", ".", "AccOverriding", ";", "}", "if", "(", "!", "areReturnTypesCompatible", "(", "currentMethod", ",", "inheritedMethod", ")", "&&", "(", "currentMethod", ".", "returnType", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "==", "0", ")", "{", "if", "(", "reportIncompatibleReturnTypeError", "(", "currentMethod", ",", "inheritedMethod", ")", ")", "continue", "nextMethod", ";", "}", "if", "(", "currentMethod", ".", "thrownExceptions", "!=", "Binding", ".", "NO_EXCEPTIONS", ")", "checkExceptions", "(", "currentMethod", ",", "inheritedMethod", ")", ";", "if", "(", "inheritedMethod", ".", "isFinal", "(", ")", ")", "problemReporter", "(", "currentMethod", ")", ".", "finalMethodCannotBeOverridden", "(", "currentMethod", ",", "inheritedMethod", ")", ";", "if", "(", "!", "isAsVisible", "(", "currentMethod", ",", "inheritedMethod", ")", ")", "problemReporter", "(", "currentMethod", ")", ".", "visibilityConflict", "(", "currentMethod", ",", "inheritedMethod", ")", ";", "if", "(", "inheritedMethod", ".", "isSynchronized", "(", ")", "&&", "!", "currentMethod", ".", "isSynchronized", "(", ")", ")", "{", "problemReporter", "(", "currentMethod", ")", ".", "missingSynchronizedOnInheritedMethod", "(", "currentMethod", ",", "inheritedMethod", ")", ";", "}", "if", "(", "options", ".", "reportDeprecationWhenOverridingDeprecatedMethod", "&&", "inheritedMethod", ".", "isViewedAsDeprecated", "(", ")", ")", "{", "if", "(", "!", "currentMethod", ".", "isViewedAsDeprecated", "(", ")", "||", "options", ".", "reportDeprecationInsideDeprecatedCode", ")", "{", "ReferenceBinding", "declaringClass", "=", "inheritedMethod", ".", "declaringClass", ";", "if", "(", "declaringClass", ".", "isInterface", "(", ")", ")", "for", "(", "int", "j", "=", "length", ";", "--", "j", ">=", "0", ";", ")", "if", "(", "i", "!=", "j", "&&", "methods", "[", "j", "]", ".", "declaringClass", ".", "implementsInterface", "(", "declaringClass", ",", "false", ")", ")", "continue", "nextMethod", ";", "problemReporter", "(", "currentMethod", ")", ".", "overridesDeprecatedMethod", "(", "currentMethod", ",", "inheritedMethod", ")", ";", "}", "}", "}", "checkForBridgeMethod", "(", "currentMethod", ",", "inheritedMethod", ",", "allInheritedMethods", ")", ";", "}", "}", "void", "checkConcreteInheritedMethod", "(", "MethodBinding", "concreteMethod", ",", "MethodBinding", "[", "]", "abstractMethods", ")", "{", "if", "(", "concreteMethod", ".", "isStatic", "(", ")", ")", "problemReporter", "(", ")", ".", "staticInheritedMethodConflicts", "(", "this", ".", "type", ",", "concreteMethod", ",", "abstractMethods", ")", ";", "if", "(", "!", "concreteMethod", ".", "isPublic", "(", ")", ")", "{", "int", "index", "=", "0", ",", "length", "=", "abstractMethods", ".", "length", ";", "if", "(", "concreteMethod", ".", "isProtected", "(", ")", ")", "{", "for", "(", ";", "index", "<", "length", ";", "index", "++", ")", "if", "(", "abstractMethods", "[", "index", "]", ".", "isPublic", "(", ")", ")", "break", ";", "}", "else", "if", "(", "concreteMethod", ".", "isDefault", "(", ")", ")", "{", "for", "(", ";", "index", "<", "length", ";", "index", "++", ")", "if", "(", "!", "abstractMethods", "[", "index", "]", ".", "isDefault", "(", ")", ")", "break", ";", "}", "if", "(", "index", "<", "length", ")", "problemReporter", "(", ")", ".", "inheritedMethodReducesVisibility", "(", "this", ".", "type", ",", "concreteMethod", ",", "abstractMethods", ")", ";", "}", "if", "(", "concreteMethod", ".", "thrownExceptions", "!=", "Binding", ".", "NO_EXCEPTIONS", ")", "for", "(", "int", "i", "=", "abstractMethods", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "checkExceptions", "(", "concreteMethod", ",", "abstractMethods", "[", "i", "]", ")", ";", "if", "(", "concreteMethod", ".", "isOrEnclosedByPrivateType", "(", ")", ")", "concreteMethod", ".", "original", "(", ")", ".", "modifiers", "|=", "ExtraCompilerModifiers", ".", "AccLocallyUsed", ";", "}", "void", "checkExceptions", "(", "MethodBinding", "newMethod", ",", "MethodBinding", "inheritedMethod", ")", "{", "ReferenceBinding", "[", "]", "newExceptions", "=", "resolvedExceptionTypesFor", "(", "newMethod", ")", ";", "ReferenceBinding", "[", "]", "inheritedExceptions", "=", "resolvedExceptionTypesFor", "(", "inheritedMethod", ")", ";", "for", "(", "int", "i", "=", "newExceptions", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "{", "ReferenceBinding", "newException", "=", "newExceptions", "[", "i", "]", ";", "int", "j", "=", "inheritedExceptions", ".", "length", ";", "while", "(", "--", "j", ">", "-", "1", "&&", "!", "isSameClassOrSubclassOf", "(", "newException", ",", "inheritedExceptions", "[", "j", "]", ")", ")", "{", "}", "if", "(", "j", "==", "-", "1", ")", "if", "(", "!", "newException", ".", "isUncheckedException", "(", "false", ")", "&&", "(", "newException", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "==", "0", ")", "{", "problemReporter", "(", "newMethod", ")", ".", "incompatibleExceptionInThrowsClause", "(", "this", ".", "type", ",", "newMethod", ",", "inheritedMethod", ",", "newException", ")", ";", "}", "}", "}", "void", "checkForBridgeMethod", "(", "MethodBinding", "currentMethod", ",", "MethodBinding", "inheritedMethod", ",", "MethodBinding", "[", "]", "allInheritedMethods", ")", "{", "}", "void", "checkForMissingHashCodeMethod", "(", ")", "{", "MethodBinding", "[", "]", "choices", "=", "this", ".", "type", ".", "getMethods", "(", "TypeConstants", ".", "EQUALS", ")", ";", "boolean", "overridesEquals", "=", "false", ";", "for", "(", "int", "i", "=", "choices", ".", "length", ";", "!", "overridesEquals", "&&", "--", "i", ">=", "0", ";", ")", "overridesEquals", "=", "choices", "[", "i", "]", ".", "parameters", ".", "length", "==", "1", "&&", "choices", "[", "i", "]", ".", "parameters", "[", "0", "]", ".", "id", "==", "TypeIds", ".", "T_JavaLangObject", ";", "if", "(", "overridesEquals", ")", "{", "MethodBinding", "hashCodeMethod", "=", "this", ".", "type", ".", "getExactMethod", "(", "TypeConstants", ".", "HASHCODE", ",", "Binding", ".", "NO_PARAMETERS", ",", "null", ")", ";", "if", "(", "hashCodeMethod", "!=", "null", "&&", "hashCodeMethod", ".", "declaringClass", ".", "id", "==", "TypeIds", ".", "T_JavaLangObject", ")", "this", ".", "problemReporter", "(", ")", ".", "shouldImplementHashcode", "(", "this", ".", "type", ")", ";", "}", "}", "void", "checkForRedundantSuperinterfaces", "(", "ReferenceBinding", "superclass", ",", "ReferenceBinding", "[", "]", "superInterfaces", ")", "{", "if", "(", "superInterfaces", "==", "Binding", ".", "NO_SUPERINTERFACES", ")", "return", ";", "SimpleSet", "interfacesToCheck", "=", "new", "SimpleSet", "(", "superInterfaces", ".", "length", ")", ";", "next", ":", "for", "(", "int", "i", "=", "0", ",", "l", "=", "superInterfaces", ".", "length", ";", "i", "<", "l", ";", "i", "++", ")", "{", "ReferenceBinding", "toCheck", "=", "superInterfaces", "[", "i", "]", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "l", ";", "j", "++", ")", "{", "if", "(", "i", "!=", "j", "&&", "toCheck", ".", "implementsInterface", "(", "superInterfaces", "[", "j", "]", ",", "true", ")", ")", "{", "TypeReference", "[", "]", "refs", "=", "this", ".", "type", ".", "scope", ".", "referenceContext", ".", "superInterfaces", ";", "for", "(", "int", "r", "=", "0", ",", "rl", "=", "refs", ".", "length", ";", "r", "<", "rl", ";", "r", "++", ")", "{", "if", "(", "refs", "[", "r", "]", ".", "resolvedType", "==", "toCheck", ")", "{", "problemReporter", "(", ")", ".", "redundantSuperInterface", "(", "this", ".", "type", ",", "refs", "[", "j", "]", ",", "superInterfaces", "[", "j", "]", ",", "toCheck", ")", ";", "continue", "next", ";", "}", "}", "}", "}", "interfacesToCheck", ".", "add", "(", "toCheck", ")", ";", "}", "ReferenceBinding", "[", "]", "itsInterfaces", "=", "null", ";", "SimpleSet", "inheritedInterfaces", "=", "new", "SimpleSet", "(", "5", ")", ";", "ReferenceBinding", "superType", "=", "superclass", ";", "while", "(", "superType", "!=", "null", "&&", "superType", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "(", "itsInterfaces", "=", "superType", ".", "superInterfaces", "(", ")", ")", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "for", "(", "int", "i", "=", "0", ",", "l", "=", "itsInterfaces", ".", "length", ";", "i", "<", "l", ";", "i", "++", ")", "{", "ReferenceBinding", "inheritedInterface", "=", "itsInterfaces", "[", "i", "]", ";", "if", "(", "!", "inheritedInterfaces", ".", "includes", "(", "inheritedInterface", ")", "&&", "inheritedInterface", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "interfacesToCheck", ".", "includes", "(", "inheritedInterface", ")", ")", "{", "TypeReference", "[", "]", "refs", "=", "this", ".", "type", ".", "scope", ".", "referenceContext", ".", "superInterfaces", ";", "for", "(", "int", "r", "=", "0", ",", "rl", "=", "refs", ".", "length", ";", "r", "<", "rl", ";", "r", "++", ")", "{", "if", "(", "refs", "[", "r", "]", ".", "resolvedType", "==", "inheritedInterface", ")", "{", "problemReporter", "(", ")", ".", "redundantSuperInterface", "(", "this", ".", "type", ",", "refs", "[", "r", "]", ",", "inheritedInterface", ",", "superType", ")", ";", "break", ";", "}", "}", "}", "else", "{", "inheritedInterfaces", ".", "add", "(", "inheritedInterface", ")", ";", "}", "}", "}", "}", "superType", "=", "superType", ".", "superclass", "(", ")", ";", "}", "int", "nextPosition", "=", "inheritedInterfaces", ".", "elementSize", ";", "if", "(", "nextPosition", "==", "0", ")", "return", ";", "ReferenceBinding", "[", "]", "interfacesToVisit", "=", "new", "ReferenceBinding", "[", "nextPosition", "]", ";", "inheritedInterfaces", ".", "asArray", "(", "interfacesToVisit", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "nextPosition", ";", "i", "++", ")", "{", "superType", "=", "interfacesToVisit", "[", "i", "]", ";", "if", "(", "(", "itsInterfaces", "=", "superType", ".", "superInterfaces", "(", ")", ")", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "int", "itsLength", "=", "itsInterfaces", ".", "length", ";", "if", "(", "nextPosition", "+", "itsLength", ">=", "interfacesToVisit", ".", "length", ")", "System", ".", "arraycopy", "(", "interfacesToVisit", ",", "0", ",", "interfacesToVisit", "=", "new", "ReferenceBinding", "[", "nextPosition", "+", "itsLength", "+", "5", "]", ",", "0", ",", "nextPosition", ")", ";", "for", "(", "int", "a", "=", "0", ";", "a", "<", "itsLength", ";", "a", "++", ")", "{", "ReferenceBinding", "inheritedInterface", "=", "itsInterfaces", "[", "a", "]", ";", "if", "(", "!", "inheritedInterfaces", ".", "includes", "(", "inheritedInterface", ")", "&&", "inheritedInterface", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "interfacesToCheck", ".", "includes", "(", "inheritedInterface", ")", ")", "{", "TypeReference", "[", "]", "refs", "=", "this", ".", "type", ".", "scope", ".", "referenceContext", ".", "superInterfaces", ";", "for", "(", "int", "r", "=", "0", ",", "rl", "=", "refs", ".", "length", ";", "r", "<", "rl", ";", "r", "++", ")", "{", "if", "(", "refs", "[", "r", "]", ".", "resolvedType", "==", "inheritedInterface", ")", "{", "problemReporter", "(", ")", ".", "redundantSuperInterface", "(", "this", ".", "type", ",", "refs", "[", "r", "]", ",", "inheritedInterface", ",", "superType", ")", ";", "break", ";", "}", "}", "}", "else", "{", "inheritedInterfaces", ".", "add", "(", "inheritedInterface", ")", ";", "interfacesToVisit", "[", "nextPosition", "++", "]", "=", "inheritedInterface", ";", "}", "}", "}", "}", "}", "}", "void", "checkInheritedMethods", "(", "MethodBinding", "[", "]", "methods", ",", "int", "length", ")", "{", "MethodBinding", "concreteMethod", "=", "this", ".", "type", ".", "isInterface", "(", ")", "||", "methods", "[", "0", "]", ".", "isAbstract", "(", ")", "?", "null", ":", "methods", "[", "0", "]", ";", "if", "(", "concreteMethod", "==", "null", ")", "{", "MethodBinding", "bestAbstractMethod", "=", "length", "==", "1", "?", "methods", "[", "0", "]", ":", "findBestInheritedAbstractMethod", "(", "methods", ",", "length", ")", ";", "boolean", "noMatch", "=", "bestAbstractMethod", "==", "null", ";", "if", "(", "noMatch", ")", "bestAbstractMethod", "=", "methods", "[", "0", "]", ";", "if", "(", "mustImplementAbstractMethod", "(", "bestAbstractMethod", ".", "declaringClass", ")", ")", "{", "TypeDeclaration", "typeDeclaration", "=", "this", ".", "type", ".", "scope", ".", "referenceContext", ";", "MethodBinding", "superclassAbstractMethod", "=", "methods", "[", "0", "]", ";", "if", "(", "superclassAbstractMethod", "==", "bestAbstractMethod", "||", "superclassAbstractMethod", ".", "declaringClass", ".", "isInterface", "(", ")", ")", "{", "if", "(", "typeDeclaration", "!=", "null", ")", "{", "MethodDeclaration", "missingAbstractMethod", "=", "typeDeclaration", ".", "addMissingAbstractMethodFor", "(", "bestAbstractMethod", ")", ";", "missingAbstractMethod", ".", "scope", ".", "problemReporter", "(", ")", ".", "abstractMethodMustBeImplemented", "(", "this", ".", "type", ",", "bestAbstractMethod", ")", ";", "}", "else", "{", "problemReporter", "(", ")", ".", "abstractMethodMustBeImplemented", "(", "this", ".", "type", ",", "bestAbstractMethod", ")", ";", "}", "}", "else", "{", "if", "(", "typeDeclaration", "!=", "null", ")", "{", "MethodDeclaration", "missingAbstractMethod", "=", "typeDeclaration", ".", "addMissingAbstractMethodFor", "(", "bestAbstractMethod", ")", ";", "missingAbstractMethod", ".", "scope", ".", "problemReporter", "(", ")", ".", "abstractMethodMustBeImplemented", "(", "this", ".", "type", ",", "bestAbstractMethod", ",", "superclassAbstractMethod", ")", ";", "}", "else", "{", "problemReporter", "(", ")", ".", "abstractMethodMustBeImplemented", "(", "this", ".", "type", ",", "bestAbstractMethod", ",", "superclassAbstractMethod", ")", ";", "}", "}", "}", "else", "if", "(", "noMatch", ")", "{", "problemReporter", "(", ")", ".", "inheritedMethodsHaveIncompatibleReturnTypes", "(", "this", ".", "type", ",", "methods", ",", "length", ")", ";", "}", "return", ";", "}", "if", "(", "length", "<", "2", ")", "return", ";", "int", "index", "=", "length", ";", "while", "(", "--", "index", ">", "0", "&&", "checkInheritedReturnTypes", "(", "concreteMethod", ",", "methods", "[", "index", "]", ")", ")", "{", "}", "if", "(", "index", ">", "0", ")", "{", "MethodBinding", "bestAbstractMethod", "=", "findBestInheritedAbstractMethod", "(", "methods", ",", "length", ")", ";", "if", "(", "bestAbstractMethod", "==", "null", ")", "problemReporter", "(", ")", ".", "inheritedMethodsHaveIncompatibleReturnTypes", "(", "this", ".", "type", ",", "methods", ",", "length", ")", ";", "else", "problemReporter", "(", ")", ".", "abstractMethodMustBeImplemented", "(", "this", ".", "type", ",", "bestAbstractMethod", ",", "concreteMethod", ")", ";", "return", ";", "}", "MethodBinding", "[", "]", "abstractMethods", "=", "new", "MethodBinding", "[", "length", "-", "1", "]", ";", "index", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "if", "(", "methods", "[", "i", "]", ".", "isAbstract", "(", ")", ")", "abstractMethods", "[", "index", "++", "]", "=", "methods", "[", "i", "]", ";", "if", "(", "index", "==", "0", ")", "return", ";", "if", "(", "index", "<", "abstractMethods", ".", "length", ")", "System", ".", "arraycopy", "(", "abstractMethods", ",", "0", ",", "abstractMethods", "=", "new", "MethodBinding", "[", "index", "]", ",", "0", ",", "index", ")", ";", "checkConcreteInheritedMethod", "(", "concreteMethod", ",", "abstractMethods", ")", ";", "}", "boolean", "checkInheritedReturnTypes", "(", "MethodBinding", "method", ",", "MethodBinding", "otherMethod", ")", "{", "if", "(", "areReturnTypesCompatible", "(", "method", ",", "otherMethod", ")", ")", "return", "true", ";", "if", "(", "!", "this", ".", "type", ".", "isInterface", "(", ")", ")", "if", "(", "method", ".", "declaringClass", ".", "isClass", "(", ")", "||", "!", "this", ".", "type", ".", "implementsInterface", "(", "method", ".", "declaringClass", ",", "false", ")", ")", "if", "(", "otherMethod", ".", "declaringClass", ".", "isClass", "(", ")", "||", "!", "this", ".", "type", ".", "implementsInterface", "(", "otherMethod", ".", "declaringClass", ",", "false", ")", ")", "return", "true", ";", "return", "false", ";", "}", "void", "checkMethods", "(", ")", "{", "boolean", "mustImplementAbstractMethods", "=", "mustImplementAbstractMethods", "(", ")", ";", "boolean", "skipInheritedMethods", "=", "mustImplementAbstractMethods", "&&", "canSkipInheritedMethods", "(", ")", ";", "boolean", "isOrEnclosedByPrivateType", "=", "this", ".", "type", ".", "isOrEnclosedByPrivateType", "(", ")", ";", "char", "[", "]", "[", "]", "methodSelectors", "=", "this", ".", "inheritedMethods", ".", "keyTable", ";", "nextSelector", ":", "for", "(", "int", "s", "=", "methodSelectors", ".", "length", ";", "--", "s", ">=", "0", ";", ")", "{", "if", "(", "methodSelectors", "[", "s", "]", "==", "null", ")", "continue", "nextSelector", ";", "MethodBinding", "[", "]", "current", "=", "(", "MethodBinding", "[", "]", ")", "this", ".", "currentMethods", ".", "get", "(", "methodSelectors", "[", "s", "]", ")", ";", "MethodBinding", "[", "]", "inherited", "=", "(", "MethodBinding", "[", "]", ")", "this", ".", "inheritedMethods", ".", "valueTable", "[", "s", "]", ";", "if", "(", "current", "==", "null", "&&", "!", "isOrEnclosedByPrivateType", ")", "{", "int", "length", "=", "inherited", ".", "length", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "inherited", "[", "i", "]", ".", "original", "(", ")", ".", "modifiers", "|=", "ExtraCompilerModifiers", ".", "AccLocallyUsed", ";", "}", "}", "if", "(", "current", "==", "null", "&&", "skipInheritedMethods", ")", "continue", "nextSelector", ";", "if", "(", "inherited", ".", "length", "==", "1", "&&", "current", "==", "null", ")", "{", "if", "(", "mustImplementAbstractMethods", "&&", "inherited", "[", "0", "]", ".", "isAbstract", "(", ")", ")", "checkAbstractMethod", "(", "inherited", "[", "0", "]", ")", ";", "continue", "nextSelector", ";", "}", "int", "index", "=", "-", "1", ";", "MethodBinding", "[", "]", "matchingInherited", "=", "new", "MethodBinding", "[", "inherited", ".", "length", "]", ";", "if", "(", "current", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length1", "=", "current", ".", "length", ";", "i", "<", "length1", ";", "i", "++", ")", "{", "MethodBinding", "currentMethod", "=", "current", "[", "i", "]", ";", "for", "(", "int", "j", "=", "0", ",", "length2", "=", "inherited", ".", "length", ";", "j", "<", "length2", ";", "j", "++", ")", "{", "MethodBinding", "inheritedMethod", "=", "computeSubstituteMethod", "(", "inherited", "[", "j", "]", ",", "currentMethod", ")", ";", "if", "(", "inheritedMethod", "!=", "null", ")", "{", "if", "(", "isParameterSubsignature", "(", "currentMethod", ",", "inheritedMethod", ")", ")", "{", "matchingInherited", "[", "++", "index", "]", "=", "inheritedMethod", ";", "inherited", "[", "j", "]", "=", "null", ";", "}", "}", "}", "if", "(", "index", ">=", "0", ")", "{", "checkAgainstInheritedMethods", "(", "currentMethod", ",", "matchingInherited", ",", "index", "+", "1", ",", "inherited", ")", ";", "while", "(", "index", ">=", "0", ")", "matchingInherited", "[", "index", "--", "]", "=", "null", ";", "}", "}", "}", "for", "(", "int", "i", "=", "0", ",", "length", "=", "inherited", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "MethodBinding", "inheritedMethod", "=", "inherited", "[", "i", "]", ";", "if", "(", "inheritedMethod", "==", "null", ")", "continue", ";", "if", "(", "!", "isOrEnclosedByPrivateType", "&&", "current", "!=", "null", ")", "{", "inheritedMethod", ".", "original", "(", ")", ".", "modifiers", "|=", "ExtraCompilerModifiers", ".", "AccLocallyUsed", ";", "}", "matchingInherited", "[", "++", "index", "]", "=", "inheritedMethod", ";", "for", "(", "int", "j", "=", "i", "+", "1", ";", "j", "<", "length", ";", "j", "++", ")", "{", "MethodBinding", "otherInheritedMethod", "=", "inherited", "[", "j", "]", ";", "if", "(", "canSkipInheritedMethods", "(", "inheritedMethod", ",", "otherInheritedMethod", ")", ")", "continue", ";", "otherInheritedMethod", "=", "computeSubstituteMethod", "(", "otherInheritedMethod", ",", "inheritedMethod", ")", ";", "if", "(", "otherInheritedMethod", "!=", "null", ")", "{", "if", "(", "isParameterSubsignature", "(", "inheritedMethod", ",", "otherInheritedMethod", ")", ")", "{", "matchingInherited", "[", "++", "index", "]", "=", "otherInheritedMethod", ";", "inherited", "[", "j", "]", "=", "null", ";", "}", "}", "}", "if", "(", "index", "==", "-", "1", ")", "continue", ";", "if", "(", "index", ">", "0", ")", "checkInheritedMethods", "(", "matchingInherited", ",", "index", "+", "1", ")", ";", "else", "if", "(", "mustImplementAbstractMethods", "&&", "matchingInherited", "[", "0", "]", ".", "isAbstract", "(", ")", ")", "checkAbstractMethod", "(", "matchingInherited", "[", "0", "]", ")", ";", "while", "(", "index", ">=", "0", ")", "matchingInherited", "[", "index", "--", "]", "=", "null", ";", "}", "}", "}", "void", "checkPackagePrivateAbstractMethod", "(", "MethodBinding", "abstractMethod", ")", "{", "PackageBinding", "necessaryPackage", "=", "abstractMethod", ".", "declaringClass", ".", "fPackage", ";", "if", "(", "necessaryPackage", "==", "this", ".", "type", ".", "fPackage", ")", "return", ";", "ReferenceBinding", "superType", "=", "this", ".", "type", ".", "superclass", "(", ")", ";", "char", "[", "]", "selector", "=", "abstractMethod", ".", "selector", ";", "do", "{", "if", "(", "!", "superType", ".", "isValidBinding", "(", ")", ")", "return", ";", "if", "(", "!", "superType", ".", "isAbstract", "(", ")", ")", "return", ";", "if", "(", "necessaryPackage", "==", "superType", ".", "fPackage", ")", "{", "MethodBinding", "[", "]", "methods", "=", "superType", ".", "getMethods", "(", "selector", ")", ";", "nextMethod", ":", "for", "(", "int", "m", "=", "methods", ".", "length", ";", "--", "m", ">=", "0", ";", ")", "{", "MethodBinding", "method", "=", "methods", "[", "m", "]", ";", "if", "(", "method", ".", "isPrivate", "(", ")", "||", "method", ".", "isConstructor", "(", ")", "||", "method", ".", "isDefaultAbstract", "(", ")", ")", "continue", "nextMethod", ";", "if", "(", "areMethodsCompatible", "(", "method", ",", "abstractMethod", ")", ")", "return", ";", "}", "}", "}", "while", "(", "(", "superType", "=", "superType", ".", "superclass", "(", ")", ")", "!=", "abstractMethod", ".", "declaringClass", ")", ";", "problemReporter", "(", ")", ".", "abstractMethodCannotBeOverridden", "(", "this", ".", "type", ",", "abstractMethod", ")", ";", "}", "void", "computeInheritedMethods", "(", ")", "{", "ReferenceBinding", "superclass", "=", "this", ".", "type", ".", "isInterface", "(", ")", "?", "this", ".", "type", ".", "scope", ".", "getJavaLangObject", "(", ")", ":", "this", ".", "type", ".", "superclass", "(", ")", ";", "computeInheritedMethods", "(", "superclass", ",", "this", ".", "type", ".", "superInterfaces", "(", ")", ")", ";", "checkForRedundantSuperinterfaces", "(", "superclass", ",", "this", ".", "type", ".", "superInterfaces", "(", ")", ")", ";", "}", "void", "computeInheritedMethods", "(", "ReferenceBinding", "superclass", ",", "ReferenceBinding", "[", "]", "superInterfaces", ")", "{", "this", ".", "inheritedMethods", "=", "new", "HashtableOfObject", "(", "51", ")", ";", "ReferenceBinding", "[", "]", "interfacesToVisit", "=", "null", ";", "int", "nextPosition", "=", "0", ";", "ReferenceBinding", "[", "]", "itsInterfaces", "=", "superInterfaces", ";", "if", "(", "itsInterfaces", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "nextPosition", "=", "itsInterfaces", ".", "length", ";", "interfacesToVisit", "=", "itsInterfaces", ";", "}", "ReferenceBinding", "superType", "=", "superclass", ";", "HashtableOfObject", "nonVisibleDefaultMethods", "=", "new", "HashtableOfObject", "(", "3", ")", ";", "while", "(", "superType", "!=", "null", "&&", "superType", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "(", "itsInterfaces", "=", "superType", ".", "superInterfaces", "(", ")", ")", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "if", "(", "interfacesToVisit", "==", "null", ")", "{", "interfacesToVisit", "=", "itsInterfaces", ";", "nextPosition", "=", "interfacesToVisit", ".", "length", ";", "}", "else", "{", "int", "itsLength", "=", "itsInterfaces", ".", "length", ";", "if", "(", "nextPosition", "+", "itsLength", ">=", "interfacesToVisit", ".", "length", ")", "System", ".", "arraycopy", "(", "interfacesToVisit", ",", "0", ",", "interfacesToVisit", "=", "new", "ReferenceBinding", "[", "nextPosition", "+", "itsLength", "+", "5", "]", ",", "0", ",", "nextPosition", ")", ";", "nextInterface", ":", "for", "(", "int", "a", "=", "0", ";", "a", "<", "itsLength", ";", "a", "++", ")", "{", "ReferenceBinding", "next", "=", "itsInterfaces", "[", "a", "]", ";", "for", "(", "int", "b", "=", "0", ";", "b", "<", "nextPosition", ";", "b", "++", ")", "if", "(", "next", "==", "interfacesToVisit", "[", "b", "]", ")", "continue", "nextInterface", ";", "interfacesToVisit", "[", "nextPosition", "++", "]", "=", "next", ";", "}", "}", "}", "MethodBinding", "[", "]", "methods", "=", "superType", ".", "unResolvedMethods", "(", ")", ";", "nextMethod", ":", "for", "(", "int", "m", "=", "methods", ".", "length", ";", "--", "m", ">=", "0", ";", ")", "{", "MethodBinding", "inheritedMethod", "=", "methods", "[", "m", "]", ";", "if", "(", "inheritedMethod", ".", "isPrivate", "(", ")", "||", "inheritedMethod", ".", "isConstructor", "(", ")", "||", "inheritedMethod", ".", "isDefaultAbstract", "(", ")", ")", "continue", "nextMethod", ";", "MethodBinding", "[", "]", "existingMethods", "=", "(", "MethodBinding", "[", "]", ")", "this", ".", "inheritedMethods", ".", "get", "(", "inheritedMethod", ".", "selector", ")", ";", "if", "(", "existingMethods", "!=", "null", ")", "{", "existing", ":", "for", "(", "int", "i", "=", "0", ",", "length", "=", "existingMethods", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "MethodBinding", "existingMethod", "=", "existingMethods", "[", "i", "]", ";", "if", "(", "existingMethod", ".", "declaringClass", "!=", "inheritedMethod", ".", "declaringClass", "&&", "areMethodsCompatible", "(", "existingMethod", ",", "inheritedMethod", ")", "&&", "!", "canOverridingMethodDifferInErasure", "(", "existingMethod", ",", "inheritedMethod", ")", ")", "{", "if", "(", "inheritedMethod", ".", "isDefault", "(", ")", ")", "{", "if", "(", "inheritedMethod", ".", "isAbstract", "(", ")", ")", "{", "checkPackagePrivateAbstractMethod", "(", "inheritedMethod", ")", ";", "}", "else", "if", "(", "existingMethod", ".", "declaringClass", ".", "fPackage", "!=", "inheritedMethod", ".", "declaringClass", ".", "fPackage", ")", "{", "if", "(", "this", ".", "type", ".", "fPackage", "==", "inheritedMethod", ".", "declaringClass", ".", "fPackage", "&&", "!", "areReturnTypesCompatible", "(", "inheritedMethod", ",", "existingMethod", ")", ")", "continue", "existing", ";", "}", "}", "continue", "nextMethod", ";", "}", "}", "}", "if", "(", "!", "inheritedMethod", ".", "isDefault", "(", ")", "||", "inheritedMethod", ".", "declaringClass", ".", "fPackage", "==", "this", ".", "type", ".", "fPackage", ")", "{", "if", "(", "existingMethods", "==", "null", ")", "{", "existingMethods", "=", "new", "MethodBinding", "[", "]", "{", "inheritedMethod", "}", ";", "}", "else", "{", "int", "length", "=", "existingMethods", ".", "length", ";", "System", ".", "arraycopy", "(", "existingMethods", ",", "0", ",", "existingMethods", "=", "new", "MethodBinding", "[", "length", "+", "1", "]", ",", "0", ",", "length", ")", ";", "existingMethods", "[", "length", "]", "=", "inheritedMethod", ";", "}", "this", ".", "inheritedMethods", ".", "put", "(", "inheritedMethod", ".", "selector", ",", "existingMethods", ")", ";", "}", "else", "{", "MethodBinding", "[", "]", "nonVisible", "=", "(", "MethodBinding", "[", "]", ")", "nonVisibleDefaultMethods", ".", "get", "(", "inheritedMethod", ".", "selector", ")", ";", "if", "(", "nonVisible", "!=", "null", ")", "for", "(", "int", "i", "=", "0", ",", "l", "=", "nonVisible", ".", "length", ";", "i", "<", "l", ";", "i", "++", ")", "if", "(", "areMethodsCompatible", "(", "nonVisible", "[", "i", "]", ",", "inheritedMethod", ")", ")", "continue", "nextMethod", ";", "if", "(", "nonVisible", "==", "null", ")", "{", "nonVisible", "=", "new", "MethodBinding", "[", "]", "{", "inheritedMethod", "}", ";", "}", "else", "{", "int", "length", "=", "nonVisible", ".", "length", ";", "System", ".", "arraycopy", "(", "nonVisible", ",", "0", ",", "nonVisible", "=", "new", "MethodBinding", "[", "length", "+", "1", "]", ",", "0", ",", "length", ")", ";", "nonVisible", "[", "length", "]", "=", "inheritedMethod", ";", "}", "nonVisibleDefaultMethods", ".", "put", "(", "inheritedMethod", ".", "selector", ",", "nonVisible", ")", ";", "if", "(", "inheritedMethod", ".", "isAbstract", "(", ")", "&&", "!", "this", ".", "type", ".", "isAbstract", "(", ")", ")", "problemReporter", "(", ")", ".", "abstractMethodCannotBeOverridden", "(", "this", ".", "type", ",", "inheritedMethod", ")", ";", "MethodBinding", "[", "]", "current", "=", "(", "MethodBinding", "[", "]", ")", "this", ".", "currentMethods", ".", "get", "(", "inheritedMethod", ".", "selector", ")", ";", "if", "(", "current", "!=", "null", "&&", "!", "inheritedMethod", ".", "isStatic", "(", ")", ")", "{", "foundMatch", ":", "for", "(", "int", "i", "=", "0", ",", "length", "=", "current", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "!", "current", "[", "i", "]", ".", "isStatic", "(", ")", "&&", "areMethodsCompatible", "(", "current", "[", "i", "]", ",", "inheritedMethod", ")", ")", "{", "problemReporter", "(", ")", ".", "overridesPackageDefaultMethod", "(", "current", "[", "i", "]", ",", "inheritedMethod", ")", ";", "break", "foundMatch", ";", "}", "}", "}", "}", "}", "superType", "=", "superType", ".", "superclass", "(", ")", ";", "}", "if", "(", "nextPosition", "==", "0", ")", "return", ";", "SimpleSet", "skip", "=", "findSuperinterfaceCollisions", "(", "superclass", ",", "superInterfaces", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "nextPosition", ";", "i", "++", ")", "{", "superType", "=", "interfacesToVisit", "[", "i", "]", ";", "if", "(", "superType", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "skip", "!=", "null", "&&", "skip", ".", "includes", "(", "superType", ")", ")", "continue", ";", "if", "(", "(", "itsInterfaces", "=", "superType", ".", "superInterfaces", "(", ")", ")", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "int", "itsLength", "=", "itsInterfaces", ".", "length", ";", "if", "(", "nextPosition", "+", "itsLength", ">=", "interfacesToVisit", ".", "length", ")", "System", ".", "arraycopy", "(", "interfacesToVisit", ",", "0", ",", "interfacesToVisit", "=", "new", "ReferenceBinding", "[", "nextPosition", "+", "itsLength", "+", "5", "]", ",", "0", ",", "nextPosition", ")", ";", "nextInterface", ":", "for", "(", "int", "a", "=", "0", ";", "a", "<", "itsLength", ";", "a", "++", ")", "{", "ReferenceBinding", "next", "=", "itsInterfaces", "[", "a", "]", ";", "for", "(", "int", "b", "=", "0", ";", "b", "<", "nextPosition", ";", "b", "++", ")", "if", "(", "next", "==", "interfacesToVisit", "[", "b", "]", ")", "continue", "nextInterface", ";", "interfacesToVisit", "[", "nextPosition", "++", "]", "=", "next", ";", "}", "}", "MethodBinding", "[", "]", "methods", "=", "superType", ".", "unResolvedMethods", "(", ")", ";", "nextMethod", ":", "for", "(", "int", "m", "=", "methods", ".", "length", ";", "--", "m", ">=", "0", ";", ")", "{", "MethodBinding", "inheritedMethod", "=", "methods", "[", "m", "]", ";", "MethodBinding", "[", "]", "existingMethods", "=", "(", "MethodBinding", "[", "]", ")", "this", ".", "inheritedMethods", ".", "get", "(", "inheritedMethod", ".", "selector", ")", ";", "if", "(", "existingMethods", "==", "null", ")", "{", "existingMethods", "=", "new", "MethodBinding", "[", "]", "{", "inheritedMethod", "}", ";", "}", "else", "{", "int", "length", "=", "existingMethods", ".", "length", ";", "for", "(", "int", "e", "=", "0", ";", "e", "<", "length", ";", "e", "++", ")", "if", "(", "isInterfaceMethodImplemented", "(", "inheritedMethod", ",", "existingMethods", "[", "e", "]", ",", "superType", ")", "&&", "!", "canOverridingMethodDifferInErasure", "(", "existingMethods", "[", "e", "]", ",", "inheritedMethod", ")", ")", "continue", "nextMethod", ";", "System", ".", "arraycopy", "(", "existingMethods", ",", "0", ",", "existingMethods", "=", "new", "MethodBinding", "[", "length", "+", "1", "]", ",", "0", ",", "length", ")", ";", "existingMethods", "[", "length", "]", "=", "inheritedMethod", ";", "}", "this", ".", "inheritedMethods", ".", "put", "(", "inheritedMethod", ".", "selector", ",", "existingMethods", ")", ";", "}", "}", "}", "}", "protected", "boolean", "canOverridingMethodDifferInErasure", "(", "MethodBinding", "overridingMethod", ",", "MethodBinding", "inheritedMethod", ")", "{", "return", "false", ";", "}", "void", "computeMethods", "(", ")", "{", "MethodBinding", "[", "]", "methods", "=", "this", ".", "type", ".", "methods", "(", ")", ";", "int", "size", "=", "methods", ".", "length", ";", "this", ".", "currentMethods", "=", "new", "HashtableOfObject", "(", "size", "==", "0", "?", "1", ":", "size", ")", ";", "for", "(", "int", "m", "=", "size", ";", "--", "m", ">=", "0", ";", ")", "{", "MethodBinding", "method", "=", "methods", "[", "m", "]", ";", "if", "(", "!", "(", "method", ".", "isConstructor", "(", ")", "||", "method", ".", "isDefaultAbstract", "(", ")", ")", ")", "{", "MethodBinding", "[", "]", "existingMethods", "=", "(", "MethodBinding", "[", "]", ")", "this", ".", "currentMethods", ".", "get", "(", "method", ".", "selector", ")", ";", "if", "(", "existingMethods", "==", "null", ")", "existingMethods", "=", "new", "MethodBinding", "[", "1", "]", ";", "else", "System", ".", "arraycopy", "(", "existingMethods", ",", "0", ",", "(", "existingMethods", "=", "new", "MethodBinding", "[", "existingMethods", ".", "length", "+", "1", "]", ")", ",", "0", ",", "existingMethods", ".", "length", "-", "1", ")", ";", "existingMethods", "[", "existingMethods", ".", "length", "-", "1", "]", "=", "method", ";", "this", ".", "currentMethods", ".", "put", "(", "method", ".", "selector", ",", "existingMethods", ")", ";", "}", "}", "}", "MethodBinding", "computeSubstituteMethod", "(", "MethodBinding", "inheritedMethod", ",", "MethodBinding", "currentMethod", ")", "{", "if", "(", "inheritedMethod", "==", "null", ")", "return", "null", ";", "if", "(", "currentMethod", ".", "parameters", ".", "length", "!=", "inheritedMethod", ".", "parameters", ".", "length", ")", "return", "null", ";", "return", "inheritedMethod", ";", "}", "boolean", "couldMethodOverride", "(", "MethodBinding", "method", ",", "MethodBinding", "inheritedMethod", ")", "{", "if", "(", "!", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ".", "equals", "(", "method", ".", "selector", ",", "inheritedMethod", ".", "selector", ")", ")", "return", "false", ";", "if", "(", "method", "==", "inheritedMethod", "||", "method", ".", "isStatic", "(", ")", "||", "inheritedMethod", ".", "isStatic", "(", ")", ")", "return", "false", ";", "if", "(", "inheritedMethod", ".", "isPrivate", "(", ")", ")", "return", "false", ";", "if", "(", "inheritedMethod", ".", "isDefault", "(", ")", "&&", "method", ".", "declaringClass", ".", "getPackage", "(", ")", "!=", "inheritedMethod", ".", "declaringClass", ".", "getPackage", "(", ")", ")", "return", "false", ";", "if", "(", "!", "method", ".", "isPublic", "(", ")", ")", "{", "if", "(", "inheritedMethod", ".", "isPublic", "(", ")", ")", "return", "false", ";", "if", "(", "inheritedMethod", ".", "isProtected", "(", ")", "&&", "!", "method", ".", "isProtected", "(", ")", ")", "return", "false", ";", "}", "return", "true", ";", "}", "public", "boolean", "doesMethodOverride", "(", "MethodBinding", "method", ",", "MethodBinding", "inheritedMethod", ")", "{", "if", "(", "!", "couldMethodOverride", "(", "method", ",", "inheritedMethod", ")", ")", "return", "false", ";", "inheritedMethod", "=", "inheritedMethod", ".", "original", "(", ")", ";", "TypeBinding", "match", "=", "method", ".", "declaringClass", ".", "findSuperTypeOriginatingFrom", "(", "inheritedMethod", ".", "declaringClass", ")", ";", "if", "(", "!", "(", "match", "instanceof", "ReferenceBinding", ")", ")", "return", "false", ";", "return", "isParameterSubsignature", "(", "method", ",", "inheritedMethod", ")", ";", "}", "SimpleSet", "findSuperinterfaceCollisions", "(", "ReferenceBinding", "superclass", ",", "ReferenceBinding", "[", "]", "superInterfaces", ")", "{", "return", "null", ";", "}", "MethodBinding", "findBestInheritedAbstractMethod", "(", "MethodBinding", "[", "]", "methods", ",", "int", "length", ")", "{", "findMethod", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "MethodBinding", "method", "=", "methods", "[", "i", "]", ";", "if", "(", "!", "method", ".", "isAbstract", "(", ")", ")", "continue", "findMethod", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "length", ";", "j", "++", ")", "{", "if", "(", "i", "==", "j", ")", "continue", ";", "if", "(", "!", "checkInheritedReturnTypes", "(", "method", ",", "methods", "[", "j", "]", ")", ")", "{", "if", "(", "this", ".", "type", ".", "isInterface", "(", ")", "&&", "methods", "[", "j", "]", ".", "declaringClass", ".", "id", "==", "TypeIds", ".", "T_JavaLangObject", ")", "return", "method", ";", "continue", "findMethod", ";", "}", "}", "return", "method", ";", "}", "return", "null", ";", "}", "int", "[", "]", "findOverriddenInheritedMethods", "(", "MethodBinding", "[", "]", "methods", ",", "int", "length", ")", "{", "int", "[", "]", "toSkip", "=", "null", ";", "int", "i", "=", "0", ";", "ReferenceBinding", "declaringClass", "=", "methods", "[", "i", "]", ".", "declaringClass", ";", "if", "(", "!", "declaringClass", ".", "isInterface", "(", ")", ")", "{", "ReferenceBinding", "declaringClass2", "=", "methods", "[", "++", "i", "]", ".", "declaringClass", ";", "while", "(", "declaringClass", "==", "declaringClass2", ")", "{", "if", "(", "++", "i", "==", "length", ")", "return", "null", ";", "declaringClass2", "=", "methods", "[", "i", "]", ".", "declaringClass", ";", "}", "if", "(", "!", "declaringClass2", ".", "isInterface", "(", ")", ")", "{", "if", "(", "declaringClass", ".", "fPackage", "!=", "declaringClass2", ".", "fPackage", "&&", "methods", "[", "i", "]", ".", "isDefault", "(", ")", ")", "return", "null", ";", "toSkip", "=", "new", "int", "[", "length", "]", ";", "do", "{", "toSkip", "[", "i", "]", "=", "-", "1", ";", "if", "(", "++", "i", "==", "length", ")", "return", "toSkip", ";", "declaringClass2", "=", "methods", "[", "i", "]", ".", "declaringClass", ";", "}", "while", "(", "!", "declaringClass2", ".", "isInterface", "(", ")", ")", ";", "}", "}", "nextMethod", ":", "for", "(", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "toSkip", "!=", "null", "&&", "toSkip", "[", "i", "]", "==", "-", "1", ")", "continue", "nextMethod", ";", "declaringClass", "=", "methods", "[", "i", "]", ".", "declaringClass", ";", "for", "(", "int", "j", "=", "i", "+", "1", ";", "j", "<", "length", ";", "j", "++", ")", "{", "if", "(", "toSkip", "!=", "null", "&&", "toSkip", "[", "j", "]", "==", "-", "1", ")", "continue", ";", "ReferenceBinding", "declaringClass2", "=", "methods", "[", "j", "]", ".", "declaringClass", ";", "if", "(", "declaringClass", "==", "declaringClass2", ")", "continue", ";", "if", "(", "declaringClass", ".", "implementsInterface", "(", "declaringClass2", ",", "true", ")", ")", "{", "if", "(", "toSkip", "==", "null", ")", "toSkip", "=", "new", "int", "[", "length", "]", ";", "toSkip", "[", "j", "]", "=", "-", "1", ";", "}", "else", "if", "(", "declaringClass2", ".", "implementsInterface", "(", "declaringClass", ",", "true", ")", ")", "{", "if", "(", "toSkip", "==", "null", ")", "toSkip", "=", "new", "int", "[", "length", "]", ";", "toSkip", "[", "i", "]", "=", "-", "1", ";", "continue", "nextMethod", ";", "}", "}", "}", "return", "toSkip", ";", "}", "boolean", "isAsVisible", "(", "MethodBinding", "newMethod", ",", "MethodBinding", "inheritedMethod", ")", "{", "if", "(", "inheritedMethod", ".", "modifiers", "==", "newMethod", ".", "modifiers", ")", "return", "true", ";", "if", "(", "newMethod", ".", "isPublic", "(", ")", ")", "return", "true", ";", "if", "(", "inheritedMethod", ".", "isPublic", "(", ")", ")", "return", "false", ";", "if", "(", "newMethod", ".", "isProtected", "(", ")", ")", "return", "true", ";", "if", "(", "inheritedMethod", ".", "isProtected", "(", ")", ")", "return", "false", ";", "return", "!", "newMethod", ".", "isPrivate", "(", ")", ";", "}", "boolean", "isInterfaceMethodImplemented", "(", "MethodBinding", "inheritedMethod", ",", "MethodBinding", "existingMethod", ",", "ReferenceBinding", "superType", ")", "{", "return", "areParametersEqual", "(", "existingMethod", ",", "inheritedMethod", ")", "&&", "existingMethod", ".", "declaringClass", ".", "implementsInterface", "(", "superType", ",", "true", ")", ";", "}", "public", "boolean", "isMethodSubsignature", "(", "MethodBinding", "method", ",", "MethodBinding", "inheritedMethod", ")", "{", "return", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ".", "equals", "(", "method", ".", "selector", ",", "inheritedMethod", ".", "selector", ")", "&&", "isParameterSubsignature", "(", "method", ",", "inheritedMethod", ")", ";", "}", "boolean", "isParameterSubsignature", "(", "MethodBinding", "method", ",", "MethodBinding", "inheritedMethod", ")", "{", "return", "areParametersEqual", "(", "method", ",", "inheritedMethod", ")", ";", "}", "boolean", "isSameClassOrSubclassOf", "(", "ReferenceBinding", "testClass", ",", "ReferenceBinding", "superclass", ")", "{", "do", "{", "if", "(", "testClass", "==", "superclass", ")", "return", "true", ";", "}", "while", "(", "(", "testClass", "=", "testClass", ".", "superclass", "(", ")", ")", "!=", "null", ")", ";", "return", "false", ";", "}", "boolean", "mustImplementAbstractMethod", "(", "ReferenceBinding", "declaringClass", ")", "{", "if", "(", "!", "mustImplementAbstractMethods", "(", ")", ")", "return", "false", ";", "ReferenceBinding", "superclass", "=", "this", ".", "type", ".", "superclass", "(", ")", ";", "if", "(", "declaringClass", ".", "isClass", "(", ")", ")", "{", "while", "(", "superclass", ".", "isAbstract", "(", ")", "&&", "superclass", "!=", "declaringClass", ")", "superclass", "=", "superclass", ".", "superclass", "(", ")", ";", "}", "else", "{", "if", "(", "this", ".", "type", ".", "implementsInterface", "(", "declaringClass", ",", "false", ")", ")", "if", "(", "!", "superclass", ".", "implementsInterface", "(", "declaringClass", ",", "true", ")", ")", "return", "true", ";", "while", "(", "superclass", ".", "isAbstract", "(", ")", "&&", "!", "superclass", ".", "implementsInterface", "(", "declaringClass", ",", "false", ")", ")", "superclass", "=", "superclass", ".", "superclass", "(", ")", ";", "}", "return", "superclass", ".", "isAbstract", "(", ")", ";", "}", "boolean", "mustImplementAbstractMethods", "(", ")", "{", "return", "!", "this", ".", "type", ".", "isInterface", "(", ")", "&&", "!", "this", ".", "type", ".", "isAbstract", "(", ")", ";", "}", "ProblemReporter", "problemReporter", "(", ")", "{", "return", "this", ".", "type", ".", "scope", ".", "problemReporter", "(", ")", ";", "}", "ProblemReporter", "problemReporter", "(", "MethodBinding", "currentMethod", ")", "{", "ProblemReporter", "reporter", "=", "problemReporter", "(", ")", ";", "if", "(", "currentMethod", ".", "declaringClass", "==", "this", ".", "type", "&&", "currentMethod", ".", "sourceMethod", "(", ")", "!=", "null", ")", "reporter", ".", "referenceContext", "=", "currentMethod", ".", "sourceMethod", "(", ")", ";", "return", "reporter", ";", "}", "boolean", "reportIncompatibleReturnTypeError", "(", "MethodBinding", "currentMethod", ",", "MethodBinding", "inheritedMethod", ")", "{", "problemReporter", "(", "currentMethod", ")", ".", "incompatibleReturnType", "(", "currentMethod", ",", "inheritedMethod", ")", ";", "return", "true", ";", "}", "ReferenceBinding", "[", "]", "resolvedExceptionTypesFor", "(", "MethodBinding", "method", ")", "{", "ReferenceBinding", "[", "]", "exceptions", "=", "method", ".", "thrownExceptions", ";", "if", "(", "(", "method", ".", "modifiers", "&", "ExtraCompilerModifiers", ".", "AccUnresolved", ")", "==", "0", ")", "return", "exceptions", ";", "if", "(", "!", "(", "method", ".", "declaringClass", "instanceof", "BinaryTypeBinding", ")", ")", "return", "Binding", ".", "NO_EXCEPTIONS", ";", "for", "(", "int", "i", "=", "exceptions", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "exceptions", "[", "i", "]", "=", "(", "ReferenceBinding", ")", "BinaryTypeBinding", ".", "resolveType", "(", "exceptions", "[", "i", "]", ",", "this", ".", "environment", ",", "true", ")", ";", "return", "exceptions", ";", "}", "void", "verify", "(", ")", "{", "computeMethods", "(", ")", ";", "computeInheritedMethods", "(", ")", ";", "checkMethods", "(", ")", ";", "if", "(", "this", ".", "type", ".", "isClass", "(", ")", ")", "checkForMissingHashCodeMethod", "(", ")", ";", "}", "void", "verify", "(", "SourceTypeBinding", "someType", ")", "{", "if", "(", "this", ".", "type", "==", "null", ")", "{", "try", "{", "this", ".", "type", "=", "someType", ";", "verify", "(", ")", ";", "}", "finally", "{", "this", ".", "type", "=", "null", ";", "}", "}", "else", "{", "this", ".", "environment", ".", "newMethodVerifier", "(", ")", ".", "verify", "(", "someType", ")", ";", "}", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", "10", ")", ";", "buffer", ".", "append", "(", "\"\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "type", ".", "readableName", "(", ")", ")", ";", "buffer", ".", "append", "(", "'\\n'", ")", ";", "buffer", ".", "append", "(", "\"\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "inheritedMethods", ")", ";", "return", "buffer", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
5,592
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "public", "class", "InferenceContext", "{", "private", "TypeBinding", "[", "]", "[", "]", "[", "]", "collectedSubstitutes", ";", "MethodBinding", "genericMethod", ";", "int", "depth", ";", "int", "status", ";", "TypeBinding", "expectedType", ";", "boolean", "hasExplicitExpectedType", ";", "public", "boolean", "isUnchecked", ";", "TypeBinding", "[", "]", "substitutes", ";", "final", "static", "int", "FAILED", "=", "1", ";", "public", "InferenceContext", "(", "MethodBinding", "genericMethod", ")", "{", "this", ".", "genericMethod", "=", "genericMethod", ";", "TypeVariableBinding", "[", "]", "typeVariables", "=", "genericMethod", ".", "typeVariables", ";", "int", "varLength", "=", "typeVariables", ".", "length", ";", "this", ".", "collectedSubstitutes", "=", "new", "TypeBinding", "[", "varLength", "]", "[", "3", "]", "[", "]", ";", "this", ".", "substitutes", "=", "new", "TypeBinding", "[", "varLength", "]", ";", "}", "public", "TypeBinding", "[", "]", "getSubstitutes", "(", "TypeVariableBinding", "typeVariable", ",", "int", "constraint", ")", "{", "return", "this", ".", "collectedSubstitutes", "[", "typeVariable", ".", "rank", "]", "[", "constraint", "]", ";", "}", "public", "boolean", "hasUnresolvedTypeArgument", "(", ")", "{", "for", "(", "int", "i", "=", "0", ",", "varLength", "=", "this", ".", "substitutes", ".", "length", ";", "i", "<", "varLength", ";", "i", "++", ")", "{", "if", "(", "this", ".", "substitutes", "[", "i", "]", "==", "null", ")", "{", "return", "true", ";", "}", "}", "return", "false", ";", "}", "public", "void", "recordSubstitute", "(", "TypeVariableBinding", "typeVariable", ",", "TypeBinding", "actualType", ",", "int", "constraint", ")", "{", "TypeBinding", "[", "]", "[", "]", "variableSubstitutes", "=", "this", ".", "collectedSubstitutes", "[", "typeVariable", ".", "rank", "]", ";", "insertLoop", ":", "{", "TypeBinding", "[", "]", "constraintSubstitutes", "=", "variableSubstitutes", "[", "constraint", "]", ";", "int", "length", ";", "if", "(", "constraintSubstitutes", "==", "null", ")", "{", "length", "=", "0", ";", "constraintSubstitutes", "=", "new", "TypeBinding", "[", "1", "]", ";", "}", "else", "{", "length", "=", "constraintSubstitutes", ".", "length", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeBinding", "substitute", "=", "constraintSubstitutes", "[", "i", "]", ";", "if", "(", "substitute", "==", "actualType", ")", "return", ";", "if", "(", "substitute", "==", "null", ")", "{", "constraintSubstitutes", "[", "i", "]", "=", "actualType", ";", "break", "insertLoop", ";", "}", "}", "System", ".", "arraycopy", "(", "constraintSubstitutes", ",", "0", ",", "constraintSubstitutes", "=", "new", "TypeBinding", "[", "length", "+", "1", "]", ",", "0", ",", "length", ")", ";", "}", "constraintSubstitutes", "[", "length", "]", "=", "actualType", ";", "variableSubstitutes", "[", "constraint", "]", "=", "constraintSubstitutes", ";", "}", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", "20", ")", ";", "buffer", ".", "append", "(", "\"\"", ")", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "this", ".", "genericMethod", ".", "typeVariables", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "buffer", ".", "append", "(", "this", ".", "genericMethod", ".", "typeVariables", "[", "i", "]", ")", ";", "}", "buffer", ".", "append", "(", "this", ".", "genericMethod", ")", ";", "buffer", ".", "append", "(", "\"nt[status=\"", ")", ";", "switch", "(", "this", ".", "status", ")", "{", "case", "0", ":", "buffer", ".", "append", "(", "\"ok]\"", ")", ";", "break", ";", "case", "FAILED", ":", "buffer", ".", "append", "(", "\"failed]\"", ")", ";", "break", ";", "}", "if", "(", "this", ".", "expectedType", "==", "null", ")", "{", "buffer", ".", "append", "(", "\"\"", ")", ";", "}", "else", "{", "buffer", ".", "append", "(", "\"\"", ")", ".", "append", "(", "this", ".", "expectedType", ".", "shortReadableName", "(", ")", ")", ".", "append", "(", "']'", ")", ";", "}", "buffer", ".", "append", "(", "\"", "[depth=\"", ")", ".", "append", "(", "this", ".", "depth", ")", ".", "append", "(", "']'", ")", ";", "buffer", ".", "append", "(", "\"\"", ")", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "this", ".", "collectedSubstitutes", "==", "null", "?", "0", ":", "this", ".", "collectedSubstitutes", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeBinding", "[", "]", "[", "]", "collected", "=", "this", ".", "collectedSubstitutes", "[", "i", "]", ";", "for", "(", "int", "j", "=", "TypeConstants", ".", "CONSTRAINT_EQUAL", ";", "j", "<=", "TypeConstants", ".", "CONSTRAINT_SUPER", ";", "j", "++", ")", "{", "TypeBinding", "[", "]", "constraintCollected", "=", "collected", "[", "j", "]", ";", "if", "(", "constraintCollected", "!=", "null", ")", "{", "for", "(", "int", "k", "=", "0", ",", "clength", "=", "constraintCollected", ".", "length", ";", "k", "<", "clength", ";", "k", "++", ")", "{", "buffer", ".", "append", "(", "\"ntt\"", ")", ".", "append", "(", "this", ".", "genericMethod", ".", "typeVariables", "[", "i", "]", ".", "sourceName", ")", ";", "switch", "(", "j", ")", "{", "case", "TypeConstants", ".", "CONSTRAINT_EQUAL", ":", "buffer", ".", "append", "(", "\"=\"", ")", ";", "break", ";", "case", "TypeConstants", ".", "CONSTRAINT_EXTENDS", ":", "buffer", ".", "append", "(", "\"<:\"", ")", ";", "break", ";", "case", "TypeConstants", ".", "CONSTRAINT_SUPER", ":", "buffer", ".", "append", "(", "\">:\"", ")", ";", "break", ";", "}", "if", "(", "constraintCollected", "[", "k", "]", "!=", "null", ")", "{", "buffer", ".", "append", "(", "constraintCollected", "[", "k", "]", ".", "shortReadableName", "(", ")", ")", ";", "}", "}", "}", "}", "}", "buffer", ".", "append", "(", "\"}]\"", ")", ";", "buffer", ".", "append", "(", "\"nt[inferred=\"", ")", ";", "int", "count", "=", "0", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "this", ".", "substitutes", "==", "null", "?", "0", ":", "this", ".", "substitutes", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "if", "(", "this", ".", "substitutes", "[", "i", "]", "==", "null", ")", "continue", ";", "count", "++", ";", "buffer", ".", "append", "(", "'{'", ")", ".", "append", "(", "this", ".", "genericMethod", ".", "typeVariables", "[", "i", "]", ".", "sourceName", ")", ";", "buffer", ".", "append", "(", "\"=\"", ")", ".", "append", "(", "this", ".", "substitutes", "[", "i", "]", ".", "shortReadableName", "(", ")", ")", ".", "append", "(", "'}'", ")", ";", "}", "if", "(", "count", "==", "0", ")", "buffer", ".", "append", "(", "\"{}\"", ")", ";", "buffer", ".", "append", "(", "']'", ")", ";", "return", "buffer", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
5,593
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ASTNode", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "FieldDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "Constant", ";", "public", "class", "FieldBinding", "extends", "VariableBinding", "{", "public", "ReferenceBinding", "declaringClass", ";", "protected", "FieldBinding", "(", ")", "{", "super", "(", "null", ",", "null", ",", "0", ",", "null", ")", ";", "}", "public", "FieldBinding", "(", "char", "[", "]", "name", ",", "TypeBinding", "type", ",", "int", "modifiers", ",", "ReferenceBinding", "declaringClass", ",", "Constant", "constant", ")", "{", "super", "(", "name", ",", "type", ",", "modifiers", ",", "constant", ")", ";", "this", ".", "declaringClass", "=", "declaringClass", ";", "}", "public", "FieldBinding", "(", "FieldBinding", "initialFieldBinding", ",", "ReferenceBinding", "declaringClass", ")", "{", "super", "(", "initialFieldBinding", ".", "name", ",", "initialFieldBinding", ".", "type", ",", "initialFieldBinding", ".", "modifiers", ",", "initialFieldBinding", ".", "constant", "(", ")", ")", ";", "this", ".", "declaringClass", "=", "declaringClass", ";", "this", ".", "id", "=", "initialFieldBinding", ".", "id", ";", "setAnnotations", "(", "initialFieldBinding", ".", "getAnnotations", "(", ")", ")", ";", "}", "public", "FieldBinding", "(", "FieldDeclaration", "field", ",", "TypeBinding", "type", ",", "int", "modifiers", ",", "ReferenceBinding", "declaringClass", ")", "{", "this", "(", "field", ".", "name", ",", "type", ",", "modifiers", ",", "declaringClass", ",", "null", ")", ";", "field", ".", "binding", "=", "this", ";", "}", "public", "final", "boolean", "canBeSeenBy", "(", "PackageBinding", "invocationPackage", ")", "{", "if", "(", "isPublic", "(", ")", ")", "return", "true", ";", "if", "(", "isPrivate", "(", ")", ")", "return", "false", ";", "return", "invocationPackage", "==", "this", ".", "declaringClass", ".", "getPackage", "(", ")", ";", "}", "public", "final", "boolean", "canBeSeenBy", "(", "TypeBinding", "receiverType", ",", "InvocationSite", "invocationSite", ",", "Scope", "scope", ")", "{", "if", "(", "isPublic", "(", ")", ")", "return", "true", ";", "SourceTypeBinding", "invocationType", "=", "scope", ".", "enclosingSourceType", "(", ")", ";", "if", "(", "invocationType", "==", "this", ".", "declaringClass", "&&", "invocationType", "==", "receiverType", ")", "return", "true", ";", "if", "(", "invocationType", "==", "null", ")", "return", "!", "isPrivate", "(", ")", "&&", "scope", ".", "getCurrentPackage", "(", ")", "==", "this", ".", "declaringClass", ".", "fPackage", ";", "if", "(", "isProtected", "(", ")", ")", "{", "if", "(", "invocationType", "==", "this", ".", "declaringClass", ")", "return", "true", ";", "if", "(", "invocationType", ".", "fPackage", "==", "this", ".", "declaringClass", ".", "fPackage", ")", "return", "true", ";", "ReferenceBinding", "currentType", "=", "invocationType", ";", "int", "depth", "=", "0", ";", "ReferenceBinding", "receiverErasure", "=", "(", "ReferenceBinding", ")", "receiverType", ".", "erasure", "(", ")", ";", "ReferenceBinding", "declaringErasure", "=", "(", "ReferenceBinding", ")", "this", ".", "declaringClass", ".", "erasure", "(", ")", ";", "do", "{", "if", "(", "currentType", ".", "findSuperTypeOriginatingFrom", "(", "declaringErasure", ")", "!=", "null", ")", "{", "if", "(", "invocationSite", ".", "isSuperAccess", "(", ")", ")", "return", "true", ";", "if", "(", "receiverType", "instanceof", "ArrayBinding", ")", "return", "false", ";", "if", "(", "isStatic", "(", ")", ")", "{", "if", "(", "depth", ">", "0", ")", "invocationSite", ".", "setDepth", "(", "depth", ")", ";", "return", "true", ";", "}", "if", "(", "currentType", "==", "receiverErasure", "||", "receiverErasure", ".", "findSuperTypeOriginatingFrom", "(", "currentType", ")", "!=", "null", ")", "{", "if", "(", "depth", ">", "0", ")", "invocationSite", ".", "setDepth", "(", "depth", ")", ";", "return", "true", ";", "}", "}", "depth", "++", ";", "currentType", "=", "currentType", ".", "enclosingType", "(", ")", ";", "}", "while", "(", "currentType", "!=", "null", ")", ";", "return", "false", ";", "}", "if", "(", "isPrivate", "(", ")", ")", "{", "receiverCheck", ":", "{", "if", "(", "receiverType", "!=", "this", ".", "declaringClass", ")", "{", "if", "(", "receiverType", ".", "isTypeVariable", "(", ")", "&&", "(", "(", "TypeVariableBinding", ")", "receiverType", ")", ".", "isErasureBoundTo", "(", "this", ".", "declaringClass", ".", "erasure", "(", ")", ")", ")", "break", "receiverCheck", ";", "return", "false", ";", "}", "}", "if", "(", "invocationType", "!=", "this", ".", "declaringClass", ")", "{", "ReferenceBinding", "outerInvocationType", "=", "invocationType", ";", "ReferenceBinding", "temp", "=", "outerInvocationType", ".", "enclosingType", "(", ")", ";", "while", "(", "temp", "!=", "null", ")", "{", "outerInvocationType", "=", "temp", ";", "temp", "=", "temp", ".", "enclosingType", "(", ")", ";", "}", "ReferenceBinding", "outerDeclaringClass", "=", "(", "ReferenceBinding", ")", "this", ".", "declaringClass", ".", "erasure", "(", ")", ";", "temp", "=", "outerDeclaringClass", ".", "enclosingType", "(", ")", ";", "while", "(", "temp", "!=", "null", ")", "{", "outerDeclaringClass", "=", "temp", ";", "temp", "=", "temp", ".", "enclosingType", "(", ")", ";", "}", "if", "(", "outerInvocationType", "!=", "outerDeclaringClass", ")", "return", "false", ";", "}", "return", "true", ";", "}", "PackageBinding", "declaringPackage", "=", "this", ".", "declaringClass", ".", "fPackage", ";", "if", "(", "invocationType", ".", "fPackage", "!=", "declaringPackage", ")", "return", "false", ";", "if", "(", "receiverType", "instanceof", "ArrayBinding", ")", "return", "false", ";", "TypeBinding", "originalDeclaringClass", "=", "this", ".", "declaringClass", ".", "original", "(", ")", ";", "ReferenceBinding", "currentType", "=", "(", "ReferenceBinding", ")", "receiverType", ";", "do", "{", "if", "(", "currentType", ".", "isCapture", "(", ")", ")", "{", "if", "(", "originalDeclaringClass", "==", "currentType", ".", "erasure", "(", ")", ".", "original", "(", ")", ")", "return", "true", ";", "}", "else", "{", "if", "(", "originalDeclaringClass", "==", "currentType", ".", "original", "(", ")", ")", "return", "true", ";", "}", "PackageBinding", "currentPackage", "=", "currentType", ".", "fPackage", ";", "if", "(", "currentPackage", "!=", "null", "&&", "currentPackage", "!=", "declaringPackage", ")", "return", "false", ";", "}", "while", "(", "(", "currentType", "=", "currentType", ".", "superclass", "(", ")", ")", "!=", "null", ")", ";", "return", "false", ";", "}", "public", "char", "[", "]", "computeUniqueKey", "(", "boolean", "isLeaf", ")", "{", "char", "[", "]", "declaringKey", "=", "this", ".", "declaringClass", "==", "null", "?", "CharOperation", ".", "NO_CHAR", ":", "this", ".", "declaringClass", ".", "computeUniqueKey", "(", "false", ")", ";", "int", "declaringLength", "=", "declaringKey", ".", "length", ";", "int", "nameLength", "=", "this", ".", "name", ".", "length", ";", "char", "[", "]", "returnTypeKey", "=", "this", ".", "type", "==", "null", "?", "new", "char", "[", "]", "{", "'V'", "}", ":", "this", ".", "type", ".", "computeUniqueKey", "(", "false", ")", ";", "int", "returnTypeLength", "=", "returnTypeKey", ".", "length", ";", "char", "[", "]", "uniqueKey", "=", "new", "char", "[", "declaringLength", "+", "1", "+", "nameLength", "+", "1", "+", "returnTypeLength", "]", ";", "int", "index", "=", "0", ";", "System", ".", "arraycopy", "(", "declaringKey", ",", "0", ",", "uniqueKey", ",", "index", ",", "declaringLength", ")", ";", "index", "+=", "declaringLength", ";", "uniqueKey", "[", "index", "++", "]", "=", "'.'", ";", "System", ".", "arraycopy", "(", "this", ".", "name", ",", "0", ",", "uniqueKey", ",", "index", ",", "nameLength", ")", ";", "index", "+=", "nameLength", ";", "uniqueKey", "[", "index", "++", "]", "=", "')'", ";", "System", ".", "arraycopy", "(", "returnTypeKey", ",", "0", ",", "uniqueKey", ",", "index", ",", "returnTypeLength", ")", ";", "return", "uniqueKey", ";", "}", "public", "Constant", "constant", "(", ")", "{", "Constant", "fieldConstant", "=", "this", ".", "constant", ";", "if", "(", "fieldConstant", "==", "null", ")", "{", "if", "(", "isFinal", "(", ")", ")", "{", "FieldBinding", "originalField", "=", "original", "(", ")", ";", "if", "(", "originalField", ".", "declaringClass", "instanceof", "SourceTypeBinding", ")", "{", "SourceTypeBinding", "sourceType", "=", "(", "SourceTypeBinding", ")", "originalField", ".", "declaringClass", ";", "if", "(", "sourceType", ".", "scope", "!=", "null", ")", "{", "TypeDeclaration", "typeDecl", "=", "sourceType", ".", "scope", ".", "referenceContext", ";", "FieldDeclaration", "fieldDecl", "=", "typeDecl", ".", "declarationOf", "(", "originalField", ")", ";", "MethodScope", "initScope", "=", "originalField", ".", "isStatic", "(", ")", "?", "typeDecl", ".", "staticInitializerScope", ":", "typeDecl", ".", "initializerScope", ";", "boolean", "old", "=", "initScope", ".", "insideTypeAnnotation", ";", "try", "{", "initScope", ".", "insideTypeAnnotation", "=", "false", ";", "fieldDecl", ".", "resolve", "(", "initScope", ")", ";", "}", "finally", "{", "initScope", ".", "insideTypeAnnotation", "=", "old", ";", "}", "fieldConstant", "=", "originalField", ".", "constant", "==", "null", "?", "Constant", ".", "NotAConstant", ":", "originalField", ".", "constant", ";", "}", "else", "{", "fieldConstant", "=", "Constant", ".", "NotAConstant", ";", "}", "}", "else", "{", "fieldConstant", "=", "Constant", ".", "NotAConstant", ";", "}", "}", "else", "{", "fieldConstant", "=", "Constant", ".", "NotAConstant", ";", "}", "this", ".", "constant", "=", "fieldConstant", ";", "}", "return", "fieldConstant", ";", "}", "public", "char", "[", "]", "genericSignature", "(", ")", "{", "if", "(", "(", "this", ".", "modifiers", "&", "ExtraCompilerModifiers", ".", "AccGenericSignature", ")", "==", "0", ")", "return", "null", ";", "return", "this", ".", "type", ".", "genericTypeSignature", "(", ")", ";", "}", "public", "final", "int", "getAccessFlags", "(", ")", "{", "return", "this", ".", "modifiers", "&", "ExtraCompilerModifiers", ".", "AccJustFlag", ";", "}", "public", "AnnotationBinding", "[", "]", "getAnnotations", "(", ")", "{", "FieldBinding", "originalField", "=", "original", "(", ")", ";", "ReferenceBinding", "declaringClassBinding", "=", "originalField", ".", "declaringClass", ";", "if", "(", "declaringClassBinding", "==", "null", ")", "{", "return", "Binding", ".", "NO_ANNOTATIONS", ";", "}", "return", "declaringClassBinding", ".", "retrieveAnnotations", "(", "originalField", ")", ";", "}", "public", "long", "getAnnotationTagBits", "(", ")", "{", "FieldBinding", "originalField", "=", "original", "(", ")", ";", "if", "(", "(", "originalField", ".", "tagBits", "&", "TagBits", ".", "AnnotationResolved", ")", "==", "0", "&&", "originalField", ".", "declaringClass", "instanceof", "SourceTypeBinding", ")", "{", "ClassScope", "scope", "=", "(", "(", "SourceTypeBinding", ")", "originalField", ".", "declaringClass", ")", ".", "scope", ";", "if", "(", "scope", "==", "null", ")", "{", "this", ".", "tagBits", "|=", "(", "TagBits", ".", "AnnotationResolved", "|", "TagBits", ".", "DeprecatedAnnotationResolved", ")", ";", "return", "0", ";", "}", "TypeDeclaration", "typeDecl", "=", "scope", ".", "referenceContext", ";", "FieldDeclaration", "fieldDecl", "=", "typeDecl", ".", "declarationOf", "(", "originalField", ")", ";", "if", "(", "fieldDecl", "!=", "null", ")", "{", "MethodScope", "initializationScope", "=", "isStatic", "(", ")", "?", "typeDecl", ".", "staticInitializerScope", ":", "typeDecl", ".", "initializerScope", ";", "FieldBinding", "previousField", "=", "initializationScope", ".", "initializedField", ";", "int", "previousFieldID", "=", "initializationScope", ".", "lastVisibleFieldID", ";", "try", "{", "initializationScope", ".", "initializedField", "=", "originalField", ";", "initializationScope", ".", "lastVisibleFieldID", "=", "originalField", ".", "id", ";", "ASTNode", ".", "resolveAnnotations", "(", "initializationScope", ",", "fieldDecl", ".", "annotations", ",", "originalField", ")", ";", "}", "finally", "{", "initializationScope", ".", "initializedField", "=", "previousField", ";", "initializationScope", ".", "lastVisibleFieldID", "=", "previousFieldID", ";", "}", "}", "}", "return", "originalField", ".", "tagBits", ";", "}", "public", "final", "boolean", "isDefault", "(", ")", "{", "return", "!", "isPublic", "(", ")", "&&", "!", "isProtected", "(", ")", "&&", "!", "isPrivate", "(", ")", ";", "}", "public", "final", "boolean", "isDeprecated", "(", ")", "{", "return", "(", "this", ".", "modifiers", "&", "ClassFileConstants", ".", "AccDeprecated", ")", "!=", "0", ";", "}", "public", "final", "boolean", "isPrivate", "(", ")", "{", "return", "(", "this", ".", "modifiers", "&", "ClassFileConstants", ".", "AccPrivate", ")", "!=", "0", ";", "}", "public", "final", "boolean", "isOrEnclosedByPrivateType", "(", ")", "{", "if", "(", "(", "this", ".", "modifiers", "&", "ClassFileConstants", ".", "AccPrivate", ")", "!=", "0", ")", "return", "true", ";", "return", "this", ".", "declaringClass", "!=", "null", "&&", "this", ".", "declaringClass", ".", "isOrEnclosedByPrivateType", "(", ")", ";", "}", "public", "final", "boolean", "isProtected", "(", ")", "{", "return", "(", "this", ".", "modifiers", "&", "ClassFileConstants", ".", "AccProtected", ")", "!=", "0", ";", "}", "public", "final", "boolean", "isPublic", "(", ")", "{", "return", "(", "this", ".", "modifiers", "&", "ClassFileConstants", ".", "AccPublic", ")", "!=", "0", ";", "}", "public", "final", "boolean", "isStatic", "(", ")", "{", "return", "(", "this", ".", "modifiers", "&", "ClassFileConstants", ".", "AccStatic", ")", "!=", "0", ";", "}", "public", "final", "boolean", "isSynthetic", "(", ")", "{", "return", "(", "this", ".", "modifiers", "&", "ClassFileConstants", ".", "AccSynthetic", ")", "!=", "0", ";", "}", "public", "final", "boolean", "isTransient", "(", ")", "{", "return", "(", "this", ".", "modifiers", "&", "ClassFileConstants", ".", "AccTransient", ")", "!=", "0", ";", "}", "public", "final", "boolean", "isUsed", "(", ")", "{", "return", "(", "this", ".", "modifiers", "&", "ExtraCompilerModifiers", ".", "AccLocallyUsed", ")", "!=", "0", ";", "}", "public", "final", "boolean", "isViewedAsDeprecated", "(", ")", "{", "return", "(", "this", ".", "modifiers", "&", "(", "ClassFileConstants", ".", "AccDeprecated", "|", "ExtraCompilerModifiers", ".", "AccDeprecatedImplicitly", ")", ")", "!=", "0", ";", "}", "public", "final", "boolean", "isVolatile", "(", ")", "{", "return", "(", "this", ".", "modifiers", "&", "ClassFileConstants", ".", "AccVolatile", ")", "!=", "0", ";", "}", "public", "final", "int", "kind", "(", ")", "{", "return", "FIELD", ";", "}", "public", "FieldBinding", "original", "(", ")", "{", "return", "this", ";", "}", "public", "void", "setAnnotations", "(", "AnnotationBinding", "[", "]", "annotations", ")", "{", "this", ".", "declaringClass", ".", "storeAnnotations", "(", "this", ",", "annotations", ")", ";", "}", "public", "FieldDeclaration", "sourceField", "(", ")", "{", "SourceTypeBinding", "sourceType", ";", "try", "{", "sourceType", "=", "(", "SourceTypeBinding", ")", "this", ".", "declaringClass", ";", "}", "catch", "(", "ClassCastException", "e", ")", "{", "return", "null", ";", "}", "FieldDeclaration", "[", "]", "fields", "=", "sourceType", ".", "scope", ".", "referenceContext", ".", "fields", ";", "if", "(", "fields", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "fields", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "this", "==", "fields", "[", "i", "]", ".", "binding", ")", "return", "fields", "[", "i", "]", ";", "}", "return", "null", ";", "}", "}", "</s>" ]
5,594
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "public", "class", "UnresolvedAnnotationBinding", "extends", "AnnotationBinding", "{", "private", "LookupEnvironment", "env", ";", "private", "boolean", "typeUnresolved", "=", "true", ";", "UnresolvedAnnotationBinding", "(", "ReferenceBinding", "type", ",", "ElementValuePair", "[", "]", "pairs", ",", "LookupEnvironment", "env", ")", "{", "super", "(", "type", ",", "pairs", ")", ";", "this", ".", "env", "=", "env", ";", "}", "public", "ReferenceBinding", "getAnnotationType", "(", ")", "{", "if", "(", "this", ".", "typeUnresolved", ")", "{", "this", ".", "type", "=", "(", "ReferenceBinding", ")", "BinaryTypeBinding", ".", "resolveType", "(", "this", ".", "type", ",", "this", ".", "env", ",", "false", ")", ";", "this", ".", "typeUnresolved", "=", "false", ";", "}", "return", "this", ".", "type", ";", "}", "public", "ElementValuePair", "[", "]", "getElementValuePairs", "(", ")", "{", "if", "(", "this", ".", "env", "!=", "null", ")", "{", "if", "(", "this", ".", "typeUnresolved", ")", "{", "getAnnotationType", "(", ")", ";", "}", "for", "(", "int", "i", "=", "this", ".", "pairs", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "{", "ElementValuePair", "pair", "=", "this", ".", "pairs", "[", "i", "]", ";", "MethodBinding", "[", "]", "methods", "=", "this", ".", "type", ".", "getMethods", "(", "pair", ".", "getName", "(", ")", ")", ";", "if", "(", "methods", "!=", "null", "&&", "methods", ".", "length", "==", "1", ")", "{", "pair", ".", "setMethodBinding", "(", "methods", "[", "0", "]", ")", ";", "}", "Object", "value", "=", "pair", ".", "getValue", "(", ")", ";", "if", "(", "value", "instanceof", "UnresolvedReferenceBinding", ")", "{", "pair", ".", "setValue", "(", "(", "(", "UnresolvedReferenceBinding", ")", "value", ")", ".", "resolve", "(", "this", ".", "env", ",", "false", ")", ")", ";", "}", "}", "this", ".", "env", "=", "null", ";", "}", "return", "this", ".", "pairs", ";", "}", "}", "</s>" ]
5,595
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "java", ".", "util", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CompilerOptions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "ReferenceContext", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "AbortCompilation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemReporter", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "HashtableOfObject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "ObjectVector", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "SimpleSet", ";", "public", "abstract", "class", "Scope", "{", "public", "final", "static", "int", "BLOCK_SCOPE", "=", "1", ";", "public", "final", "static", "int", "CLASS_SCOPE", "=", "3", ";", "public", "final", "static", "int", "COMPILATION_UNIT_SCOPE", "=", "4", ";", "public", "final", "static", "int", "METHOD_SCOPE", "=", "2", ";", "public", "final", "static", "int", "NOT_COMPATIBLE", "=", "-", "1", ";", "public", "final", "static", "int", "COMPATIBLE", "=", "0", ";", "public", "final", "static", "int", "AUTOBOX_COMPATIBLE", "=", "1", ";", "public", "final", "static", "int", "VARARGS_COMPATIBLE", "=", "2", ";", "public", "static", "final", "int", "EQUAL_OR_MORE_SPECIFIC", "=", "-", "1", ";", "public", "static", "final", "int", "NOT_RELATED", "=", "0", ";", "public", "static", "final", "int", "MORE_GENERIC", "=", "1", ";", "public", "int", "kind", ";", "public", "Scope", "parent", ";", "protected", "Scope", "(", "int", "kind", ",", "Scope", "parent", ")", "{", "this", ".", "kind", "=", "kind", ";", "this", ".", "parent", "=", "parent", ";", "}", "public", "static", "int", "compareTypes", "(", "TypeBinding", "left", ",", "TypeBinding", "right", ")", "{", "if", "(", "left", ".", "isCompatibleWith", "(", "right", ")", ")", "return", "Scope", ".", "EQUAL_OR_MORE_SPECIFIC", ";", "if", "(", "right", ".", "isCompatibleWith", "(", "left", ")", ")", "return", "Scope", ".", "MORE_GENERIC", ";", "return", "Scope", ".", "NOT_RELATED", ";", "}", "public", "static", "TypeBinding", "convertEliminatingTypeVariables", "(", "TypeBinding", "originalType", ",", "ReferenceBinding", "genericType", ",", "int", "rank", ",", "Set", "eliminatedVariables", ")", "{", "if", "(", "(", "originalType", ".", "tagBits", "&", "TagBits", ".", "HasTypeVariable", ")", "!=", "0", ")", "{", "switch", "(", "originalType", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "ARRAY_TYPE", ":", "ArrayBinding", "originalArrayType", "=", "(", "ArrayBinding", ")", "originalType", ";", "TypeBinding", "originalLeafComponentType", "=", "originalArrayType", ".", "leafComponentType", ";", "TypeBinding", "substitute", "=", "convertEliminatingTypeVariables", "(", "originalLeafComponentType", ",", "genericType", ",", "rank", ",", "eliminatedVariables", ")", ";", "if", "(", "substitute", "!=", "originalLeafComponentType", ")", "{", "return", "originalArrayType", ".", "environment", ".", "createArrayType", "(", "substitute", ".", "leafComponentType", "(", ")", ",", "substitute", ".", "dimensions", "(", ")", "+", "originalArrayType", ".", "dimensions", "(", ")", ")", ";", "}", "break", ";", "case", "Binding", ".", "PARAMETERIZED_TYPE", ":", "ParameterizedTypeBinding", "paramType", "=", "(", "ParameterizedTypeBinding", ")", "originalType", ";", "ReferenceBinding", "originalEnclosing", "=", "paramType", ".", "enclosingType", "(", ")", ";", "ReferenceBinding", "substitutedEnclosing", "=", "originalEnclosing", ";", "if", "(", "originalEnclosing", "!=", "null", ")", "{", "substitutedEnclosing", "=", "(", "ReferenceBinding", ")", "convertEliminatingTypeVariables", "(", "originalEnclosing", ",", "genericType", ",", "rank", ",", "eliminatedVariables", ")", ";", "}", "TypeBinding", "[", "]", "originalArguments", "=", "paramType", ".", "arguments", ";", "TypeBinding", "[", "]", "substitutedArguments", "=", "originalArguments", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "originalArguments", "==", "null", "?", "0", ":", "originalArguments", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeBinding", "originalArgument", "=", "originalArguments", "[", "i", "]", ";", "TypeBinding", "substitutedArgument", "=", "convertEliminatingTypeVariables", "(", "originalArgument", ",", "paramType", ".", "genericType", "(", ")", ",", "i", ",", "eliminatedVariables", ")", ";", "if", "(", "substitutedArgument", "!=", "originalArgument", ")", "{", "if", "(", "substitutedArguments", "==", "originalArguments", ")", "{", "System", ".", "arraycopy", "(", "originalArguments", ",", "0", ",", "substitutedArguments", "=", "new", "TypeBinding", "[", "length", "]", ",", "0", ",", "i", ")", ";", "}", "substitutedArguments", "[", "i", "]", "=", "substitutedArgument", ";", "}", "else", "if", "(", "substitutedArguments", "!=", "originalArguments", ")", "{", "substitutedArguments", "[", "i", "]", "=", "originalArgument", ";", "}", "}", "if", "(", "originalEnclosing", "!=", "substitutedEnclosing", "||", "originalArguments", "!=", "substitutedArguments", ")", "{", "return", "paramType", ".", "environment", ".", "createParameterizedType", "(", "paramType", ".", "genericType", "(", ")", ",", "substitutedArguments", ",", "substitutedEnclosing", ")", ";", "}", "break", ";", "case", "Binding", ".", "TYPE_PARAMETER", ":", "if", "(", "genericType", "==", "null", ")", "{", "break", ";", "}", "TypeVariableBinding", "originalVariable", "=", "(", "TypeVariableBinding", ")", "originalType", ";", "if", "(", "eliminatedVariables", "!=", "null", "&&", "eliminatedVariables", ".", "contains", "(", "originalType", ")", ")", "{", "return", "originalVariable", ".", "environment", ".", "createWildcard", "(", "genericType", ",", "rank", ",", "null", ",", "null", ",", "Wildcard", ".", "UNBOUND", ")", ";", "}", "TypeBinding", "originalUpperBound", "=", "originalVariable", ".", "upperBound", "(", ")", ";", "if", "(", "eliminatedVariables", "==", "null", ")", "{", "eliminatedVariables", "=", "new", "HashSet", "(", "2", ")", ";", "}", "eliminatedVariables", ".", "add", "(", "originalVariable", ")", ";", "TypeBinding", "substitutedUpperBound", "=", "convertEliminatingTypeVariables", "(", "originalUpperBound", ",", "genericType", ",", "rank", ",", "eliminatedVariables", ")", ";", "eliminatedVariables", ".", "remove", "(", "originalVariable", ")", ";", "return", "originalVariable", ".", "environment", ".", "createWildcard", "(", "genericType", ",", "rank", ",", "substitutedUpperBound", ",", "null", ",", "Wildcard", ".", "EXTENDS", ")", ";", "case", "Binding", ".", "RAW_TYPE", ":", "break", ";", "case", "Binding", ".", "GENERIC_TYPE", ":", "ReferenceBinding", "currentType", "=", "(", "ReferenceBinding", ")", "originalType", ";", "originalEnclosing", "=", "currentType", ".", "enclosingType", "(", ")", ";", "substitutedEnclosing", "=", "originalEnclosing", ";", "if", "(", "originalEnclosing", "!=", "null", ")", "{", "substitutedEnclosing", "=", "(", "ReferenceBinding", ")", "convertEliminatingTypeVariables", "(", "originalEnclosing", ",", "genericType", ",", "rank", ",", "eliminatedVariables", ")", ";", "}", "originalArguments", "=", "currentType", ".", "typeVariables", "(", ")", ";", "substitutedArguments", "=", "originalArguments", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "originalArguments", "==", "null", "?", "0", ":", "originalArguments", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeBinding", "originalArgument", "=", "originalArguments", "[", "i", "]", ";", "TypeBinding", "substitutedArgument", "=", "convertEliminatingTypeVariables", "(", "originalArgument", ",", "currentType", ",", "i", ",", "eliminatedVariables", ")", ";", "if", "(", "substitutedArgument", "!=", "originalArgument", ")", "{", "if", "(", "substitutedArguments", "==", "originalArguments", ")", "{", "System", ".", "arraycopy", "(", "originalArguments", ",", "0", ",", "substitutedArguments", "=", "new", "TypeBinding", "[", "length", "]", ",", "0", ",", "i", ")", ";", "}", "substitutedArguments", "[", "i", "]", "=", "substitutedArgument", ";", "}", "else", "if", "(", "substitutedArguments", "!=", "originalArguments", ")", "{", "substitutedArguments", "[", "i", "]", "=", "originalArgument", ";", "}", "}", "if", "(", "originalEnclosing", "!=", "substitutedEnclosing", "||", "originalArguments", "!=", "substitutedArguments", ")", "{", "return", "(", "(", "TypeVariableBinding", ")", "originalArguments", "[", "0", "]", ")", ".", "environment", ".", "createParameterizedType", "(", "genericType", ",", "substitutedArguments", ",", "substitutedEnclosing", ")", ";", "}", "break", ";", "case", "Binding", ".", "WILDCARD_TYPE", ":", "WildcardBinding", "wildcard", "=", "(", "WildcardBinding", ")", "originalType", ";", "TypeBinding", "originalBound", "=", "wildcard", ".", "bound", ";", "TypeBinding", "substitutedBound", "=", "originalBound", ";", "if", "(", "originalBound", "!=", "null", ")", "{", "substitutedBound", "=", "convertEliminatingTypeVariables", "(", "originalBound", ",", "genericType", ",", "rank", ",", "eliminatedVariables", ")", ";", "if", "(", "substitutedBound", "!=", "originalBound", ")", "{", "return", "wildcard", ".", "environment", ".", "createWildcard", "(", "wildcard", ".", "genericType", ",", "wildcard", ".", "rank", ",", "substitutedBound", ",", "null", ",", "wildcard", ".", "boundKind", ")", ";", "}", "}", "break", ";", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "WildcardBinding", "intersection", "=", "(", "WildcardBinding", ")", "originalType", ";", "originalBound", "=", "intersection", ".", "bound", ";", "substitutedBound", "=", "originalBound", ";", "if", "(", "originalBound", "!=", "null", ")", "{", "substitutedBound", "=", "convertEliminatingTypeVariables", "(", "originalBound", ",", "genericType", ",", "rank", ",", "eliminatedVariables", ")", ";", "}", "TypeBinding", "[", "]", "originalOtherBounds", "=", "intersection", ".", "otherBounds", ";", "TypeBinding", "[", "]", "substitutedOtherBounds", "=", "originalOtherBounds", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "originalOtherBounds", "==", "null", "?", "0", ":", "originalOtherBounds", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeBinding", "originalOtherBound", "=", "originalOtherBounds", "[", "i", "]", ";", "TypeBinding", "substitutedOtherBound", "=", "convertEliminatingTypeVariables", "(", "originalOtherBound", ",", "genericType", ",", "rank", ",", "eliminatedVariables", ")", ";", "if", "(", "substitutedOtherBound", "!=", "originalOtherBound", ")", "{", "if", "(", "substitutedOtherBounds", "==", "originalOtherBounds", ")", "{", "System", ".", "arraycopy", "(", "originalOtherBounds", ",", "0", ",", "substitutedOtherBounds", "=", "new", "TypeBinding", "[", "length", "]", ",", "0", ",", "i", ")", ";", "}", "substitutedOtherBounds", "[", "i", "]", "=", "substitutedOtherBound", ";", "}", "else", "if", "(", "substitutedOtherBounds", "!=", "originalOtherBounds", ")", "{", "substitutedOtherBounds", "[", "i", "]", "=", "originalOtherBound", ";", "}", "}", "if", "(", "substitutedBound", "!=", "originalBound", "||", "substitutedOtherBounds", "!=", "originalOtherBounds", ")", "{", "return", "intersection", ".", "environment", ".", "createWildcard", "(", "intersection", ".", "genericType", ",", "intersection", ".", "rank", ",", "substitutedBound", ",", "substitutedOtherBounds", ",", "intersection", ".", "boundKind", ")", ";", "}", "break", ";", "}", "}", "return", "originalType", ";", "}", "public", "static", "TypeBinding", "getBaseType", "(", "char", "[", "]", "name", ")", "{", "int", "length", "=", "name", ".", "length", ";", "if", "(", "length", ">", "2", "&&", "length", "<", "8", ")", "{", "switch", "(", "name", "[", "0", "]", ")", "{", "case", "'i'", ":", "if", "(", "length", "==", "3", "&&", "name", "[", "1", "]", "==", "'n'", "&&", "name", "[", "2", "]", "==", "'t'", ")", "return", "TypeBinding", ".", "INT", ";", "break", ";", "case", "'v'", ":", "if", "(", "length", "==", "4", "&&", "name", "[", "1", "]", "==", "'o'", "&&", "name", "[", "2", "]", "==", "'i'", "&&", "name", "[", "3", "]", "==", "'d'", ")", "return", "TypeBinding", ".", "VOID", ";", "break", ";", "case", "'b'", ":", "if", "(", "length", "==", "7", "&&", "name", "[", "1", "]", "==", "'o'", "&&", "name", "[", "2", "]", "==", "'o'", "&&", "name", "[", "3", "]", "==", "'l'", "&&", "name", "[", "4", "]", "==", "'e'", "&&", "name", "[", "5", "]", "==", "'a'", "&&", "name", "[", "6", "]", "==", "'n'", ")", "return", "TypeBinding", ".", "BOOLEAN", ";", "if", "(", "length", "==", "4", "&&", "name", "[", "1", "]", "==", "'y'", "&&", "name", "[", "2", "]", "==", "'t'", "&&", "name", "[", "3", "]", "==", "'e'", ")", "return", "TypeBinding", ".", "BYTE", ";", "break", ";", "case", "'c'", ":", "if", "(", "length", "==", "4", "&&", "name", "[", "1", "]", "==", "'h'", "&&", "name", "[", "2", "]", "==", "'a'", "&&", "name", "[", "3", "]", "==", "'r'", ")", "return", "TypeBinding", ".", "CHAR", ";", "break", ";", "case", "'d'", ":", "if", "(", "length", "==", "6", "&&", "name", "[", "1", "]", "==", "'o'", "&&", "name", "[", "2", "]", "==", "'u'", "&&", "name", "[", "3", "]", "==", "'b'", "&&", "name", "[", "4", "]", "==", "'l'", "&&", "name", "[", "5", "]", "==", "'e'", ")", "return", "TypeBinding", ".", "DOUBLE", ";", "break", ";", "case", "'f'", ":", "if", "(", "length", "==", "5", "&&", "name", "[", "1", "]", "==", "'l'", "&&", "name", "[", "2", "]", "==", "'o'", "&&", "name", "[", "3", "]", "==", "'a'", "&&", "name", "[", "4", "]", "==", "'t'", ")", "return", "TypeBinding", ".", "FLOAT", ";", "break", ";", "case", "'l'", ":", "if", "(", "length", "==", "4", "&&", "name", "[", "1", "]", "==", "'o'", "&&", "name", "[", "2", "]", "==", "'n'", "&&", "name", "[", "3", "]", "==", "'g'", ")", "return", "TypeBinding", ".", "LONG", ";", "break", ";", "case", "'s'", ":", "if", "(", "length", "==", "5", "&&", "name", "[", "1", "]", "==", "'h'", "&&", "name", "[", "2", "]", "==", "'o'", "&&", "name", "[", "3", "]", "==", "'r'", "&&", "name", "[", "4", "]", "==", "'t'", ")", "return", "TypeBinding", ".", "SHORT", ";", "}", "}", "return", "null", ";", "}", "public", "static", "ReferenceBinding", "[", "]", "greaterLowerBound", "(", "ReferenceBinding", "[", "]", "types", ")", "{", "if", "(", "types", "==", "null", ")", "return", "null", ";", "int", "length", "=", "types", ".", "length", ";", "if", "(", "length", "==", "0", ")", "return", "null", ";", "ReferenceBinding", "[", "]", "result", "=", "types", ";", "int", "removed", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "ReferenceBinding", "iType", "=", "result", "[", "i", "]", ";", "if", "(", "iType", "==", "null", ")", "continue", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "length", ";", "j", "++", ")", "{", "if", "(", "i", "==", "j", ")", "continue", ";", "ReferenceBinding", "jType", "=", "result", "[", "j", "]", ";", "if", "(", "jType", "==", "null", ")", "continue", ";", "if", "(", "iType", ".", "isCompatibleWith", "(", "jType", ")", ")", "{", "if", "(", "result", "==", "types", ")", "{", "System", ".", "arraycopy", "(", "result", ",", "0", ",", "result", "=", "new", "ReferenceBinding", "[", "length", "]", ",", "0", ",", "length", ")", ";", "}", "result", "[", "j", "]", "=", "null", ";", "removed", "++", ";", "}", "}", "}", "if", "(", "removed", "==", "0", ")", "return", "result", ";", "if", "(", "length", "==", "removed", ")", "return", "null", ";", "ReferenceBinding", "[", "]", "trimmedResult", "=", "new", "ReferenceBinding", "[", "length", "-", "removed", "]", ";", "for", "(", "int", "i", "=", "0", ",", "index", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "ReferenceBinding", "iType", "=", "result", "[", "i", "]", ";", "if", "(", "iType", "!=", "null", ")", "{", "trimmedResult", "[", "index", "++", "]", "=", "iType", ";", "}", "}", "return", "trimmedResult", ";", "}", "public", "static", "TypeBinding", "[", "]", "greaterLowerBound", "(", "TypeBinding", "[", "]", "types", ")", "{", "if", "(", "types", "==", "null", ")", "return", "null", ";", "int", "length", "=", "types", ".", "length", ";", "if", "(", "length", "==", "0", ")", "return", "null", ";", "TypeBinding", "[", "]", "result", "=", "types", ";", "int", "removed", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeBinding", "iType", "=", "result", "[", "i", "]", ";", "if", "(", "iType", "==", "null", ")", "continue", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "length", ";", "j", "++", ")", "{", "if", "(", "i", "==", "j", ")", "continue", ";", "TypeBinding", "jType", "=", "result", "[", "j", "]", ";", "if", "(", "jType", "==", "null", ")", "continue", ";", "if", "(", "iType", ".", "isCompatibleWith", "(", "jType", ")", ")", "{", "if", "(", "result", "==", "types", ")", "{", "System", ".", "arraycopy", "(", "result", ",", "0", ",", "result", "=", "new", "TypeBinding", "[", "length", "]", ",", "0", ",", "length", ")", ";", "}", "result", "[", "j", "]", "=", "null", ";", "removed", "++", ";", "}", "}", "}", "if", "(", "removed", "==", "0", ")", "return", "result", ";", "if", "(", "length", "==", "removed", ")", "return", "null", ";", "TypeBinding", "[", "]", "trimmedResult", "=", "new", "TypeBinding", "[", "length", "-", "removed", "]", ";", "for", "(", "int", "i", "=", "0", ",", "index", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeBinding", "iType", "=", "result", "[", "i", "]", ";", "if", "(", "iType", "!=", "null", ")", "{", "trimmedResult", "[", "index", "++", "]", "=", "iType", ";", "}", "}", "return", "trimmedResult", ";", "}", "public", "static", "ReferenceBinding", "[", "]", "substitute", "(", "Substitution", "substitution", ",", "ReferenceBinding", "[", "]", "originalTypes", ")", "{", "if", "(", "originalTypes", "==", "null", ")", "return", "null", ";", "ReferenceBinding", "[", "]", "substitutedTypes", "=", "originalTypes", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "originalTypes", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "ReferenceBinding", "originalType", "=", "originalTypes", "[", "i", "]", ";", "TypeBinding", "substitutedType", "=", "substitute", "(", "substitution", ",", "originalType", ")", ";", "if", "(", "!", "(", "substitutedType", "instanceof", "ReferenceBinding", ")", ")", "{", "return", "null", ";", "}", "if", "(", "substitutedType", "!=", "originalType", ")", "{", "if", "(", "substitutedTypes", "==", "originalTypes", ")", "{", "System", ".", "arraycopy", "(", "originalTypes", ",", "0", ",", "substitutedTypes", "=", "new", "ReferenceBinding", "[", "length", "]", ",", "0", ",", "i", ")", ";", "}", "substitutedTypes", "[", "i", "]", "=", "(", "ReferenceBinding", ")", "substitutedType", ";", "}", "else", "if", "(", "substitutedTypes", "!=", "originalTypes", ")", "{", "substitutedTypes", "[", "i", "]", "=", "originalType", ";", "}", "}", "return", "substitutedTypes", ";", "}", "public", "static", "TypeBinding", "substitute", "(", "Substitution", "substitution", ",", "TypeBinding", "originalType", ")", "{", "if", "(", "originalType", "==", "null", ")", "return", "null", ";", "switch", "(", "originalType", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "TYPE_PARAMETER", ":", "return", "substitution", ".", "substitute", "(", "(", "TypeVariableBinding", ")", "originalType", ")", ";", "case", "Binding", ".", "PARAMETERIZED_TYPE", ":", "ParameterizedTypeBinding", "originalParameterizedType", "=", "(", "ParameterizedTypeBinding", ")", "originalType", ";", "ReferenceBinding", "originalEnclosing", "=", "originalType", ".", "enclosingType", "(", ")", ";", "ReferenceBinding", "substitutedEnclosing", "=", "originalEnclosing", ";", "if", "(", "originalEnclosing", "!=", "null", ")", "{", "substitutedEnclosing", "=", "(", "ReferenceBinding", ")", "substitute", "(", "substitution", ",", "originalEnclosing", ")", ";", "}", "TypeBinding", "[", "]", "originalArguments", "=", "originalParameterizedType", ".", "arguments", ";", "TypeBinding", "[", "]", "substitutedArguments", "=", "originalArguments", ";", "if", "(", "originalArguments", "!=", "null", ")", "{", "if", "(", "substitution", ".", "isRawSubstitution", "(", ")", ")", "{", "return", "originalParameterizedType", ".", "environment", ".", "createRawType", "(", "originalParameterizedType", ".", "genericType", "(", ")", ",", "substitutedEnclosing", ")", ";", "}", "substitutedArguments", "=", "substitute", "(", "substitution", ",", "originalArguments", ")", ";", "}", "if", "(", "substitutedArguments", "!=", "originalArguments", "||", "substitutedEnclosing", "!=", "originalEnclosing", ")", "{", "return", "originalParameterizedType", ".", "environment", ".", "createParameterizedType", "(", "originalParameterizedType", ".", "genericType", "(", ")", ",", "substitutedArguments", ",", "substitutedEnclosing", ")", ";", "}", "break", ";", "case", "Binding", ".", "ARRAY_TYPE", ":", "ArrayBinding", "originalArrayType", "=", "(", "ArrayBinding", ")", "originalType", ";", "TypeBinding", "originalLeafComponentType", "=", "originalArrayType", ".", "leafComponentType", ";", "TypeBinding", "substitute", "=", "substitute", "(", "substitution", ",", "originalLeafComponentType", ")", ";", "if", "(", "substitute", "!=", "originalLeafComponentType", ")", "{", "return", "originalArrayType", ".", "environment", ".", "createArrayType", "(", "substitute", ".", "leafComponentType", "(", ")", ",", "substitute", ".", "dimensions", "(", ")", "+", "originalType", ".", "dimensions", "(", ")", ")", ";", "}", "break", ";", "case", "Binding", ".", "WILDCARD_TYPE", ":", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "WildcardBinding", "wildcard", "=", "(", "WildcardBinding", ")", "originalType", ";", "if", "(", "wildcard", ".", "boundKind", "!=", "Wildcard", ".", "UNBOUND", ")", "{", "TypeBinding", "originalBound", "=", "wildcard", ".", "bound", ";", "TypeBinding", "substitutedBound", "=", "substitute", "(", "substitution", ",", "originalBound", ")", ";", "TypeBinding", "[", "]", "originalOtherBounds", "=", "wildcard", ".", "otherBounds", ";", "TypeBinding", "[", "]", "substitutedOtherBounds", "=", "substitute", "(", "substitution", ",", "originalOtherBounds", ")", ";", "if", "(", "substitutedBound", "!=", "originalBound", "||", "originalOtherBounds", "!=", "substitutedOtherBounds", ")", "{", "return", "wildcard", ".", "environment", ".", "createWildcard", "(", "wildcard", ".", "genericType", ",", "wildcard", ".", "rank", ",", "substitutedBound", ",", "substitutedOtherBounds", ",", "wildcard", ".", "boundKind", ")", ";", "}", "}", "break", ";", "case", "Binding", ".", "TYPE", ":", "if", "(", "!", "originalType", ".", "isMemberType", "(", ")", ")", "break", ";", "ReferenceBinding", "originalReferenceType", "=", "(", "ReferenceBinding", ")", "originalType", ";", "originalEnclosing", "=", "originalType", ".", "enclosingType", "(", ")", ";", "substitutedEnclosing", "=", "originalEnclosing", ";", "if", "(", "originalEnclosing", "!=", "null", ")", "{", "substitutedEnclosing", "=", "(", "ReferenceBinding", ")", "substitute", "(", "substitution", ",", "originalEnclosing", ")", ";", "}", "if", "(", "substitutedEnclosing", "!=", "originalEnclosing", ")", "{", "return", "substitution", ".", "isRawSubstitution", "(", ")", "?", "substitution", ".", "environment", "(", ")", ".", "createRawType", "(", "originalReferenceType", ",", "substitutedEnclosing", ")", ":", "substitution", ".", "environment", "(", ")", ".", "createParameterizedType", "(", "originalReferenceType", ",", "null", ",", "substitutedEnclosing", ")", ";", "}", "break", ";", "case", "Binding", ".", "GENERIC_TYPE", ":", "originalReferenceType", "=", "(", "ReferenceBinding", ")", "originalType", ";", "originalEnclosing", "=", "originalType", ".", "enclosingType", "(", ")", ";", "substitutedEnclosing", "=", "originalEnclosing", ";", "if", "(", "originalEnclosing", "!=", "null", ")", "{", "substitutedEnclosing", "=", "(", "ReferenceBinding", ")", "substitute", "(", "substitution", ",", "originalEnclosing", ")", ";", "}", "if", "(", "substitution", ".", "isRawSubstitution", "(", ")", ")", "{", "return", "substitution", ".", "environment", "(", ")", ".", "createRawType", "(", "originalReferenceType", ",", "substitutedEnclosing", ")", ";", "}", "originalArguments", "=", "originalReferenceType", ".", "typeVariables", "(", ")", ";", "substitutedArguments", "=", "substitute", "(", "substitution", ",", "originalArguments", ")", ";", "return", "substitution", ".", "environment", "(", ")", ".", "createParameterizedType", "(", "originalReferenceType", ",", "substitutedArguments", ",", "substitutedEnclosing", ")", ";", "}", "return", "originalType", ";", "}", "public", "static", "TypeBinding", "[", "]", "substitute", "(", "Substitution", "substitution", ",", "TypeBinding", "[", "]", "originalTypes", ")", "{", "if", "(", "originalTypes", "==", "null", ")", "return", "null", ";", "TypeBinding", "[", "]", "substitutedTypes", "=", "originalTypes", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "originalTypes", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeBinding", "originalType", "=", "originalTypes", "[", "i", "]", ";", "TypeBinding", "substitutedParameter", "=", "substitute", "(", "substitution", ",", "originalType", ")", ";", "if", "(", "substitutedParameter", "!=", "originalType", ")", "{", "if", "(", "substitutedTypes", "==", "originalTypes", ")", "{", "System", ".", "arraycopy", "(", "originalTypes", ",", "0", ",", "substitutedTypes", "=", "new", "TypeBinding", "[", "length", "]", ",", "0", ",", "i", ")", ";", "}", "substitutedTypes", "[", "i", "]", "=", "substitutedParameter", ";", "}", "else", "if", "(", "substitutedTypes", "!=", "originalTypes", ")", "{", "substitutedTypes", "[", "i", "]", "=", "originalType", ";", "}", "}", "return", "substitutedTypes", ";", "}", "public", "TypeBinding", "boxing", "(", "TypeBinding", "type", ")", "{", "if", "(", "type", ".", "isBaseType", "(", ")", ")", "return", "environment", "(", ")", ".", "computeBoxingType", "(", "type", ")", ";", "return", "type", ";", "}", "public", "final", "ClassScope", "classScope", "(", ")", "{", "Scope", "scope", "=", "this", ";", "do", "{", "if", "(", "scope", "instanceof", "ClassScope", ")", "return", "(", "ClassScope", ")", "scope", ";", "scope", "=", "scope", ".", "parent", ";", "}", "while", "(", "scope", "!=", "null", ")", ";", "return", "null", ";", "}", "public", "final", "CompilationUnitScope", "compilationUnitScope", "(", ")", "{", "Scope", "lastScope", "=", "null", ";", "Scope", "scope", "=", "this", ";", "do", "{", "lastScope", "=", "scope", ";", "scope", "=", "scope", ".", "parent", ";", "}", "while", "(", "scope", "!=", "null", ")", ";", "return", "(", "CompilationUnitScope", ")", "lastScope", ";", "}", "public", "final", "CompilerOptions", "compilerOptions", "(", ")", "{", "return", "compilationUnitScope", "(", ")", ".", "environment", ".", "globalOptions", ";", "}", "protected", "final", "MethodBinding", "computeCompatibleMethod", "(", "MethodBinding", "method", ",", "TypeBinding", "[", "]", "arguments", ",", "InvocationSite", "invocationSite", ")", "{", "TypeBinding", "[", "]", "genericTypeArguments", "=", "invocationSite", ".", "genericTypeArguments", "(", ")", ";", "TypeBinding", "[", "]", "parameters", "=", "method", ".", "parameters", ";", "TypeVariableBinding", "[", "]", "typeVariables", "=", "method", ".", "typeVariables", ";", "if", "(", "parameters", "==", "arguments", "&&", "(", "method", ".", "returnType", ".", "tagBits", "&", "TagBits", ".", "HasTypeVariable", ")", "==", "0", "&&", "genericTypeArguments", "==", "null", "&&", "typeVariables", "==", "Binding", ".", "NO_TYPE_VARIABLES", ")", "return", "method", ";", "int", "argLength", "=", "arguments", ".", "length", ";", "int", "paramLength", "=", "parameters", ".", "length", ";", "boolean", "isVarArgs", "=", "method", ".", "isVarargs", "(", ")", ";", "if", "(", "argLength", "!=", "paramLength", ")", "if", "(", "!", "isVarArgs", "||", "argLength", "<", "paramLength", "-", "1", ")", "return", "null", ";", "if", "(", "typeVariables", "!=", "Binding", ".", "NO_TYPE_VARIABLES", ")", "{", "TypeBinding", "[", "]", "newArgs", "=", "null", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "argLength", ";", "i", "++", ")", "{", "TypeBinding", "param", "=", "i", "<", "paramLength", "?", "parameters", "[", "i", "]", ":", "parameters", "[", "paramLength", "-", "1", "]", ";", "if", "(", "arguments", "[", "i", "]", ".", "isBaseType", "(", ")", "!=", "param", ".", "isBaseType", "(", ")", ")", "{", "if", "(", "newArgs", "==", "null", ")", "{", "newArgs", "=", "new", "TypeBinding", "[", "argLength", "]", ";", "System", ".", "arraycopy", "(", "arguments", ",", "0", ",", "newArgs", ",", "0", ",", "argLength", ")", ";", "}", "newArgs", "[", "i", "]", "=", "environment", "(", ")", ".", "computeBoxingType", "(", "arguments", "[", "i", "]", ")", ";", "}", "}", "if", "(", "newArgs", "!=", "null", ")", "arguments", "=", "newArgs", ";", "method", "=", "ParameterizedGenericMethodBinding", ".", "computeCompatibleMethod", "(", "method", ",", "arguments", ",", "this", ",", "invocationSite", ")", ";", "if", "(", "method", "==", "null", ")", "return", "null", ";", "if", "(", "!", "method", ".", "isValidBinding", "(", ")", ")", "return", "method", ";", "}", "else", "if", "(", "genericTypeArguments", "!=", "null", "&&", "compilerOptions", "(", ")", ".", "complianceLevel", "<", "ClassFileConstants", ".", "JDK1_7", ")", "{", "if", "(", "method", "instanceof", "ParameterizedGenericMethodBinding", ")", "{", "if", "(", "!", "(", "(", "ParameterizedGenericMethodBinding", ")", "method", ")", ".", "wasInferred", ")", "return", "new", "ProblemMethodBinding", "(", "method", ",", "method", ".", "selector", ",", "genericTypeArguments", ",", "ProblemReasons", ".", "TypeArgumentsForRawGenericMethod", ")", ";", "}", "else", "if", "(", "!", "method", ".", "isOverriding", "(", ")", "||", "!", "isOverriddenMethodGeneric", "(", "method", ")", ")", "{", "return", "new", "ProblemMethodBinding", "(", "method", ",", "method", ".", "selector", ",", "genericTypeArguments", ",", "ProblemReasons", ".", "TypeParameterArityMismatch", ")", ";", "}", "}", "if", "(", "parameterCompatibilityLevel", "(", "method", ",", "arguments", ")", ">", "NOT_COMPATIBLE", ")", "return", "method", ";", "if", "(", "genericTypeArguments", "!=", "null", ")", "return", "new", "ProblemMethodBinding", "(", "method", ",", "method", ".", "selector", ",", "arguments", ",", "ProblemReasons", ".", "ParameterizedMethodTypeMismatch", ")", ";", "return", "null", ";", "}", "protected", "boolean", "connectTypeVariables", "(", "TypeParameter", "[", "]", "typeParameters", ",", "boolean", "checkForErasedCandidateCollisions", ")", "{", "if", "(", "typeParameters", "==", "null", "||", "compilerOptions", "(", ")", ".", "sourceLevel", "<", "ClassFileConstants", ".", "JDK1_5", ")", "return", "true", ";", "Map", "invocations", "=", "new", "HashMap", "(", "2", ")", ";", "boolean", "noProblems", "=", "true", ";", "for", "(", "int", "i", "=", "0", ",", "paramLength", "=", "typeParameters", ".", "length", ";", "i", "<", "paramLength", ";", "i", "++", ")", "{", "TypeParameter", "typeParameter", "=", "typeParameters", "[", "i", "]", ";", "TypeVariableBinding", "typeVariable", "=", "typeParameter", ".", "binding", ";", "if", "(", "typeVariable", "==", "null", ")", "return", "false", ";", "typeVariable", ".", "superclass", "=", "getJavaLangObject", "(", ")", ";", "typeVariable", ".", "superInterfaces", "=", "Binding", ".", "NO_SUPERINTERFACES", ";", "typeVariable", ".", "firstBound", "=", "null", ";", "}", "nextVariable", ":", "for", "(", "int", "i", "=", "0", ",", "paramLength", "=", "typeParameters", ".", "length", ";", "i", "<", "paramLength", ";", "i", "++", ")", "{", "TypeParameter", "typeParameter", "=", "typeParameters", "[", "i", "]", ";", "TypeVariableBinding", "typeVariable", "=", "typeParameter", ".", "binding", ";", "TypeReference", "typeRef", "=", "typeParameter", ".", "type", ";", "if", "(", "typeRef", "==", "null", ")", "continue", "nextVariable", ";", "boolean", "isFirstBoundTypeVariable", "=", "false", ";", "TypeBinding", "superType", "=", "this", ".", "kind", "==", "METHOD_SCOPE", "?", "typeRef", ".", "resolveType", "(", "(", "BlockScope", ")", "this", ",", "false", ")", ":", "typeRef", ".", "resolveType", "(", "(", "ClassScope", ")", "this", ")", ";", "if", "(", "superType", "==", "null", ")", "{", "typeVariable", ".", "tagBits", "|=", "TagBits", ".", "HierarchyHasProblems", ";", "}", "else", "{", "typeRef", ".", "resolvedType", "=", "superType", ";", "firstBound", ":", "{", "switch", "(", "superType", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "ARRAY_TYPE", ":", "problemReporter", "(", ")", ".", "boundCannotBeArray", "(", "typeRef", ",", "superType", ")", ";", "typeVariable", ".", "tagBits", "|=", "TagBits", ".", "HierarchyHasProblems", ";", "break", "firstBound", ";", "case", "Binding", ".", "TYPE_PARAMETER", ":", "isFirstBoundTypeVariable", "=", "true", ";", "TypeVariableBinding", "varSuperType", "=", "(", "TypeVariableBinding", ")", "superType", ";", "if", "(", "varSuperType", ".", "rank", ">=", "typeVariable", ".", "rank", "&&", "varSuperType", ".", "declaringElement", "==", "typeVariable", ".", "declaringElement", ")", "{", "if", "(", "compilerOptions", "(", ")", ".", "complianceLevel", "<=", "ClassFileConstants", ".", "JDK1_6", ")", "{", "problemReporter", "(", ")", ".", "forwardTypeVariableReference", "(", "typeParameter", ",", "varSuperType", ")", ";", "typeVariable", ".", "tagBits", "|=", "TagBits", ".", "HierarchyHasProblems", ";", "break", "firstBound", ";", "}", "}", "break", ";", "default", ":", "if", "(", "(", "(", "ReferenceBinding", ")", "superType", ")", ".", "isFinal", "(", ")", ")", "{", "problemReporter", "(", ")", ".", "finalVariableBound", "(", "typeVariable", ",", "typeRef", ")", ";", "}", "break", ";", "}", "ReferenceBinding", "superRefType", "=", "(", "ReferenceBinding", ")", "superType", ";", "if", "(", "!", "superType", ".", "isInterface", "(", ")", ")", "{", "typeVariable", ".", "superclass", "=", "superRefType", ";", "}", "else", "{", "typeVariable", ".", "superInterfaces", "=", "new", "ReferenceBinding", "[", "]", "{", "superRefType", "}", ";", "}", "typeVariable", ".", "tagBits", "|=", "superType", ".", "tagBits", "&", "TagBits", ".", "ContainsNestedTypeReferences", ";", "typeVariable", ".", "firstBound", "=", "superRefType", ";", "}", "}", "TypeReference", "[", "]", "boundRefs", "=", "typeParameter", ".", "bounds", ";", "if", "(", "boundRefs", "!=", "null", ")", "{", "nextBound", ":", "for", "(", "int", "j", "=", "0", ",", "boundLength", "=", "boundRefs", ".", "length", ";", "j", "<", "boundLength", ";", "j", "++", ")", "{", "typeRef", "=", "boundRefs", "[", "j", "]", ";", "superType", "=", "this", ".", "kind", "==", "METHOD_SCOPE", "?", "typeRef", ".", "resolveType", "(", "(", "BlockScope", ")", "this", ",", "false", ")", ":", "typeRef", ".", "resolveType", "(", "(", "ClassScope", ")", "this", ")", ";", "if", "(", "superType", "==", "null", ")", "{", "typeVariable", ".", "tagBits", "|=", "TagBits", ".", "HierarchyHasProblems", ";", "continue", "nextBound", ";", "}", "else", "{", "typeVariable", ".", "tagBits", "|=", "superType", ".", "tagBits", "&", "TagBits", ".", "ContainsNestedTypeReferences", ";", "boolean", "didAlreadyComplain", "=", "!", "typeRef", ".", "resolvedType", ".", "isValidBinding", "(", ")", ";", "if", "(", "isFirstBoundTypeVariable", "&&", "j", "==", "0", ")", "{", "problemReporter", "(", ")", ".", "noAdditionalBoundAfterTypeVariable", "(", "typeRef", ")", ";", "typeVariable", ".", "tagBits", "|=", "TagBits", ".", "HierarchyHasProblems", ";", "didAlreadyComplain", "=", "true", ";", "}", "else", "if", "(", "superType", ".", "isArrayType", "(", ")", ")", "{", "if", "(", "!", "didAlreadyComplain", ")", "{", "problemReporter", "(", ")", ".", "boundCannotBeArray", "(", "typeRef", ",", "superType", ")", ";", "typeVariable", ".", "tagBits", "|=", "TagBits", ".", "HierarchyHasProblems", ";", "}", "continue", "nextBound", ";", "}", "else", "{", "if", "(", "!", "superType", ".", "isInterface", "(", ")", ")", "{", "if", "(", "!", "didAlreadyComplain", ")", "{", "problemReporter", "(", ")", ".", "boundMustBeAnInterface", "(", "typeRef", ",", "superType", ")", ";", "typeVariable", ".", "tagBits", "|=", "TagBits", ".", "HierarchyHasProblems", ";", "}", "continue", "nextBound", ";", "}", "}", "if", "(", "checkForErasedCandidateCollisions", "&&", "typeVariable", ".", "firstBound", "==", "typeVariable", ".", "superclass", ")", "{", "if", "(", "hasErasedCandidatesCollisions", "(", "superType", ",", "typeVariable", ".", "superclass", ",", "invocations", ",", "typeVariable", ",", "typeRef", ")", ")", "{", "continue", "nextBound", ";", "}", "}", "ReferenceBinding", "superRefType", "=", "(", "ReferenceBinding", ")", "superType", ";", "for", "(", "int", "index", "=", "typeVariable", ".", "superInterfaces", ".", "length", ";", "--", "index", ">=", "0", ";", ")", "{", "ReferenceBinding", "previousInterface", "=", "typeVariable", ".", "superInterfaces", "[", "index", "]", ";", "if", "(", "previousInterface", "==", "superRefType", ")", "{", "problemReporter", "(", ")", ".", "duplicateBounds", "(", "typeRef", ",", "superType", ")", ";", "typeVariable", ".", "tagBits", "|=", "TagBits", ".", "HierarchyHasProblems", ";", "continue", "nextBound", ";", "}", "if", "(", "checkForErasedCandidateCollisions", ")", "{", "if", "(", "hasErasedCandidatesCollisions", "(", "superType", ",", "previousInterface", ",", "invocations", ",", "typeVariable", ",", "typeRef", ")", ")", "{", "continue", "nextBound", ";", "}", "}", "}", "int", "size", "=", "typeVariable", ".", "superInterfaces", ".", "length", ";", "System", ".", "arraycopy", "(", "typeVariable", ".", "superInterfaces", ",", "0", ",", "typeVariable", ".", "superInterfaces", "=", "new", "ReferenceBinding", "[", "size", "+", "1", "]", ",", "0", ",", "size", ")", ";", "typeVariable", ".", "superInterfaces", "[", "size", "]", "=", "superRefType", ";", "}", "}", "}", "noProblems", "&=", "(", "typeVariable", ".", "tagBits", "&", "TagBits", ".", "HierarchyHasProblems", ")", "==", "0", ";", "}", "return", "noProblems", ";", "}", "public", "ArrayBinding", "createArrayType", "(", "TypeBinding", "type", ",", "int", "dimension", ")", "{", "if", "(", "type", ".", "isValidBinding", "(", ")", ")", "return", "environment", "(", ")", ".", "createArrayType", "(", "type", ",", "dimension", ")", ";", "return", "new", "ArrayBinding", "(", "type", ",", "dimension", ",", "environment", "(", ")", ")", ";", "}", "public", "TypeVariableBinding", "[", "]", "createTypeVariables", "(", "TypeParameter", "[", "]", "typeParameters", ",", "Binding", "declaringElement", ")", "{", "if", "(", "typeParameters", "==", "null", "||", "compilerOptions", "(", ")", ".", "sourceLevel", "<", "ClassFileConstants", ".", "JDK1_5", ")", "return", "Binding", ".", "NO_TYPE_VARIABLES", ";", "PackageBinding", "unitPackage", "=", "compilationUnitScope", "(", ")", ".", "fPackage", ";", "int", "length", "=", "typeParameters", ".", "length", ";", "TypeVariableBinding", "[", "]", "typeVariableBindings", "=", "new", "TypeVariableBinding", "[", "length", "]", ";", "int", "count", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeParameter", "typeParameter", "=", "typeParameters", "[", "i", "]", ";", "TypeVariableBinding", "parameterBinding", "=", "new", "TypeVariableBinding", "(", "typeParameter", ".", "name", ",", "declaringElement", ",", "i", ",", "environment", "(", ")", ")", ";", "parameterBinding", ".", "fPackage", "=", "unitPackage", ";", "typeParameter", ".", "binding", "=", "parameterBinding", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "count", ";", "j", "++", ")", "{", "TypeVariableBinding", "knownVar", "=", "typeVariableBindings", "[", "j", "]", ";", "if", "(", "CharOperation", ".", "equals", "(", "knownVar", ".", "sourceName", ",", "typeParameter", ".", "name", ")", ")", "problemReporter", "(", ")", ".", "duplicateTypeParameterInType", "(", "typeParameter", ")", ";", "}", "typeVariableBindings", "[", "count", "++", "]", "=", "parameterBinding", ";", "}", "if", "(", "count", "!=", "length", ")", "System", ".", "arraycopy", "(", "typeVariableBindings", ",", "0", ",", "typeVariableBindings", "=", "new", "TypeVariableBinding", "[", "count", "]", ",", "0", ",", "count", ")", ";", "return", "typeVariableBindings", ";", "}", "public", "final", "ClassScope", "enclosingClassScope", "(", ")", "{", "Scope", "scope", "=", "this", ";", "while", "(", "(", "scope", "=", "scope", ".", "parent", ")", "!=", "null", ")", "{", "if", "(", "scope", "instanceof", "ClassScope", ")", "return", "(", "ClassScope", ")", "scope", ";", "}", "return", "null", ";", "}", "public", "final", "MethodScope", "enclosingMethodScope", "(", ")", "{", "Scope", "scope", "=", "this", ";", "while", "(", "(", "scope", "=", "scope", ".", "parent", ")", "!=", "null", ")", "{", "if", "(", "scope", "instanceof", "MethodScope", ")", "return", "(", "MethodScope", ")", "scope", ";", "}", "return", "null", ";", "}", "public", "final", "ReferenceBinding", "enclosingReceiverType", "(", ")", "{", "Scope", "scope", "=", "this", ";", "do", "{", "if", "(", "scope", "instanceof", "ClassScope", ")", "{", "return", "environment", "(", ")", ".", "convertToParameterizedType", "(", "(", "(", "ClassScope", ")", "scope", ")", ".", "referenceContext", ".", "binding", ")", ";", "}", "scope", "=", "scope", ".", "parent", ";", "}", "while", "(", "scope", "!=", "null", ")", ";", "return", "null", ";", "}", "public", "ReferenceContext", "enclosingReferenceContext", "(", ")", "{", "Scope", "current", "=", "this", ";", "while", "(", "(", "current", "=", "current", ".", "parent", ")", "!=", "null", ")", "{", "switch", "(", "current", ".", "kind", ")", "{", "case", "METHOD_SCOPE", ":", "return", "(", "(", "MethodScope", ")", "current", ")", ".", "referenceContext", ";", "case", "CLASS_SCOPE", ":", "return", "(", "(", "ClassScope", ")", "current", ")", ".", "referenceContext", ";", "case", "COMPILATION_UNIT_SCOPE", ":", "return", "(", "(", "CompilationUnitScope", ")", "current", ")", ".", "referenceContext", ";", "}", "}", "return", "null", ";", "}", "public", "final", "SourceTypeBinding", "enclosingSourceType", "(", ")", "{", "Scope", "scope", "=", "this", ";", "do", "{", "if", "(", "scope", "instanceof", "ClassScope", ")", "return", "(", "(", "ClassScope", ")", "scope", ")", ".", "referenceContext", ".", "binding", ";", "scope", "=", "scope", ".", "parent", ";", "}", "while", "(", "scope", "!=", "null", ")", ";", "return", "null", ";", "}", "public", "final", "LookupEnvironment", "environment", "(", ")", "{", "Scope", "scope", ",", "unitScope", "=", "this", ";", "while", "(", "(", "scope", "=", "unitScope", ".", "parent", ")", "!=", "null", ")", "unitScope", "=", "scope", ";", "return", "(", "(", "CompilationUnitScope", ")", "unitScope", ")", ".", "environment", ";", "}", "protected", "MethodBinding", "findDefaultAbstractMethod", "(", "ReferenceBinding", "receiverType", ",", "char", "[", "]", "selector", ",", "TypeBinding", "[", "]", "argumentTypes", ",", "InvocationSite", "invocationSite", ",", "ReferenceBinding", "classHierarchyStart", ",", "ObjectVector", "found", ",", "MethodBinding", "concreteMatch", ")", "{", "int", "startFoundSize", "=", "found", ".", "size", ";", "ReferenceBinding", "currentType", "=", "classHierarchyStart", ";", "while", "(", "currentType", "!=", "null", ")", "{", "findMethodInSuperInterfaces", "(", "currentType", ",", "selector", ",", "found", ",", "invocationSite", ")", ";", "currentType", "=", "currentType", ".", "superclass", "(", ")", ";", "}", "MethodBinding", "[", "]", "candidates", "=", "null", ";", "int", "candidatesCount", "=", "0", ";", "MethodBinding", "problemMethod", "=", "null", ";", "int", "foundSize", "=", "found", ".", "size", ";", "if", "(", "foundSize", ">", "startFoundSize", ")", "{", "for", "(", "int", "i", "=", "startFoundSize", ";", "i", "<", "foundSize", ";", "i", "++", ")", "{", "MethodBinding", "methodBinding", "=", "(", "MethodBinding", ")", "found", ".", "elementAt", "(", "i", ")", ";", "MethodBinding", "compatibleMethod", "=", "computeCompatibleMethod", "(", "methodBinding", ",", "argumentTypes", ",", "invocationSite", ")", ";", "if", "(", "compatibleMethod", "!=", "null", ")", "{", "if", "(", "compatibleMethod", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "concreteMatch", "!=", "null", "&&", "environment", "(", ")", ".", "methodVerifier", "(", ")", ".", "areMethodsCompatible", "(", "concreteMatch", ",", "compatibleMethod", ")", ")", "continue", ";", "if", "(", "candidatesCount", "==", "0", ")", "{", "candidates", "=", "new", "MethodBinding", "[", "foundSize", "-", "startFoundSize", "+", "1", "]", ";", "if", "(", "concreteMatch", "!=", "null", ")", "candidates", "[", "candidatesCount", "++", "]", "=", "concreteMatch", ";", "}", "candidates", "[", "candidatesCount", "++", "]", "=", "compatibleMethod", ";", "}", "else", "if", "(", "problemMethod", "==", "null", ")", "{", "problemMethod", "=", "compatibleMethod", ";", "}", "}", "}", "}", "if", "(", "candidatesCount", "<", "2", ")", "{", "if", "(", "concreteMatch", "==", "null", ")", "{", "if", "(", "candidatesCount", "==", "0", ")", "return", "problemMethod", ";", "concreteMatch", "=", "candidates", "[", "0", "]", ";", "}", "compilationUnitScope", "(", ")", ".", "recordTypeReferences", "(", "concreteMatch", ".", "thrownExceptions", ")", ";", "return", "concreteMatch", ";", "}", "if", "(", "compilerOptions", "(", ")", ".", "complianceLevel", ">=", "ClassFileConstants", ".", "JDK1_4", ")", "return", "mostSpecificMethodBinding", "(", "candidates", ",", "candidatesCount", ",", "argumentTypes", ",", "invocationSite", ",", "receiverType", ")", ";", "return", "mostSpecificInterfaceMethodBinding", "(", "candidates", ",", "candidatesCount", ",", "invocationSite", ")", ";", "}", "public", "ReferenceBinding", "findDirectMemberType", "(", "char", "[", "]", "typeName", ",", "ReferenceBinding", "enclosingType", ")", "{", "if", "(", "(", "enclosingType", ".", "tagBits", "&", "TagBits", ".", "HasNoMemberTypes", ")", "!=", "0", ")", "return", "null", ";", "ReferenceBinding", "enclosingReceiverType", "=", "enclosingReceiverType", "(", ")", ";", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordReference", "(", "enclosingType", ",", "typeName", ")", ";", "ReferenceBinding", "memberType", "=", "enclosingType", ".", "getMemberType", "(", "typeName", ")", ";", "if", "(", "memberType", "!=", "null", ")", "{", "unitScope", ".", "recordTypeReference", "(", "memberType", ")", ";", "if", "(", "enclosingReceiverType", "==", "null", ")", "{", "if", "(", "memberType", ".", "canBeSeenBy", "(", "getCurrentPackage", "(", ")", ")", ")", "{", "return", "memberType", ";", "}", "if", "(", "this", "instanceof", "CompilationUnitScope", ")", "{", "TypeDeclaration", "[", "]", "types", "=", "(", "(", "CompilationUnitScope", ")", "this", ")", ".", "referenceContext", ".", "types", ";", "if", "(", "types", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "types", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "if", "(", "memberType", ".", "canBeSeenBy", "(", "enclosingType", ",", "types", "[", "i", "]", ".", "binding", ")", ")", "{", "return", "memberType", ";", "}", "}", "}", "}", "}", "else", "if", "(", "memberType", ".", "canBeSeenBy", "(", "enclosingType", ",", "enclosingReceiverType", ")", ")", "{", "return", "memberType", ";", "}", "return", "new", "ProblemReferenceBinding", "(", "new", "char", "[", "]", "[", "]", "{", "typeName", "}", ",", "memberType", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "}", "return", "null", ";", "}", "public", "MethodBinding", "findExactMethod", "(", "ReferenceBinding", "receiverType", ",", "char", "[", "]", "selector", ",", "TypeBinding", "[", "]", "argumentTypes", ",", "InvocationSite", "invocationSite", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordTypeReferences", "(", "argumentTypes", ")", ";", "MethodBinding", "exactMethod", "=", "receiverType", ".", "getExactMethod", "(", "selector", ",", "argumentTypes", ",", "unitScope", ")", ";", "if", "(", "exactMethod", "!=", "null", "&&", "exactMethod", ".", "typeVariables", "==", "Binding", ".", "NO_TYPE_VARIABLES", "&&", "!", "exactMethod", ".", "isBridge", "(", ")", ")", "{", "if", "(", "compilerOptions", "(", ")", ".", "sourceLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "for", "(", "int", "i", "=", "argumentTypes", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "isPossibleSubtypeOfRawType", "(", "argumentTypes", "[", "i", "]", ")", ")", "return", "null", ";", "unitScope", ".", "recordTypeReferences", "(", "exactMethod", ".", "thrownExceptions", ")", ";", "if", "(", "exactMethod", ".", "isAbstract", "(", ")", "&&", "exactMethod", ".", "thrownExceptions", "!=", "Binding", ".", "NO_EXCEPTIONS", ")", "return", "null", ";", "if", "(", "receiverType", ".", "isInterface", "(", ")", "||", "exactMethod", ".", "canBeSeenBy", "(", "receiverType", ",", "invocationSite", ",", "this", ")", ")", "{", "if", "(", "argumentTypes", "==", "Binding", ".", "NO_PARAMETERS", "&&", "CharOperation", ".", "equals", "(", "selector", ",", "TypeConstants", ".", "GETCLASS", ")", "&&", "exactMethod", ".", "returnType", ".", "isParameterizedType", "(", ")", ")", "{", "return", "environment", "(", ")", ".", "createGetClassMethod", "(", "receiverType", ",", "exactMethod", ",", "this", ")", ";", "}", "if", "(", "invocationSite", ".", "genericTypeArguments", "(", ")", "!=", "null", ")", "{", "exactMethod", "=", "computeCompatibleMethod", "(", "exactMethod", ",", "argumentTypes", ",", "invocationSite", ")", ";", "}", "return", "exactMethod", ";", "}", "}", "return", "null", ";", "}", "public", "FieldBinding", "findField", "(", "TypeBinding", "receiverType", ",", "char", "[", "]", "fieldName", ",", "InvocationSite", "invocationSite", ",", "boolean", "needResolve", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordTypeReference", "(", "receiverType", ")", ";", "checkArrayField", ":", "{", "TypeBinding", "leafType", ";", "switch", "(", "receiverType", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "BASE_TYPE", ":", "return", "null", ";", "case", "Binding", ".", "WILDCARD_TYPE", ":", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "case", "Binding", ".", "TYPE_PARAMETER", ":", "TypeBinding", "receiverErasure", "=", "receiverType", ".", "erasure", "(", ")", ";", "if", "(", "!", "receiverErasure", ".", "isArrayType", "(", ")", ")", "break", "checkArrayField", ";", "leafType", "=", "receiverErasure", ".", "leafComponentType", "(", ")", ";", "break", ";", "case", "Binding", ".", "ARRAY_TYPE", ":", "leafType", "=", "receiverType", ".", "leafComponentType", "(", ")", ";", "break", ";", "default", ":", "break", "checkArrayField", ";", "}", "if", "(", "leafType", "instanceof", "ReferenceBinding", ")", "if", "(", "!", "(", "(", "ReferenceBinding", ")", "leafType", ")", ".", "canBeSeenBy", "(", "this", ")", ")", "return", "new", "ProblemFieldBinding", "(", "(", "ReferenceBinding", ")", "leafType", ",", "fieldName", ",", "ProblemReasons", ".", "ReceiverTypeNotVisible", ")", ";", "if", "(", "CharOperation", ".", "equals", "(", "fieldName", ",", "TypeConstants", ".", "LENGTH", ")", ")", "{", "if", "(", "(", "leafType", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "!=", "0", ")", "{", "return", "new", "ProblemFieldBinding", "(", "ArrayBinding", ".", "ArrayLength", ",", "null", ",", "fieldName", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "return", "ArrayBinding", ".", "ArrayLength", ";", "}", "return", "null", ";", "}", "ReferenceBinding", "currentType", "=", "(", "ReferenceBinding", ")", "receiverType", ";", "if", "(", "!", "currentType", ".", "canBeSeenBy", "(", "this", ")", ")", "return", "new", "ProblemFieldBinding", "(", "currentType", ",", "fieldName", ",", "ProblemReasons", ".", "ReceiverTypeNotVisible", ")", ";", "currentType", ".", "initializeForStaticImports", "(", ")", ";", "FieldBinding", "field", "=", "currentType", ".", "getField", "(", "fieldName", ",", "needResolve", ")", ";", "boolean", "insideTypeAnnotations", "=", "this", "instanceof", "MethodScope", "&&", "(", "(", "MethodScope", ")", "this", ")", ".", "insideTypeAnnotation", ";", "if", "(", "field", "!=", "null", ")", "{", "if", "(", "invocationSite", "==", "null", "||", "insideTypeAnnotations", "?", "field", ".", "canBeSeenBy", "(", "getCurrentPackage", "(", ")", ")", ":", "field", ".", "canBeSeenBy", "(", "currentType", ",", "invocationSite", ",", "this", ")", ")", "return", "field", ";", "return", "new", "ProblemFieldBinding", "(", "field", ",", "field", ".", "declaringClass", ",", "fieldName", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "}", "ReferenceBinding", "[", "]", "interfacesToVisit", "=", "null", ";", "int", "nextPosition", "=", "0", ";", "FieldBinding", "visibleField", "=", "null", ";", "boolean", "keepLooking", "=", "true", ";", "FieldBinding", "notVisibleField", "=", "null", ";", "while", "(", "keepLooking", ")", "{", "ReferenceBinding", "[", "]", "itsInterfaces", "=", "currentType", ".", "superInterfaces", "(", ")", ";", "if", "(", "itsInterfaces", "!=", "null", "&&", "itsInterfaces", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "if", "(", "interfacesToVisit", "==", "null", ")", "{", "interfacesToVisit", "=", "itsInterfaces", ";", "nextPosition", "=", "interfacesToVisit", ".", "length", ";", "}", "else", "{", "int", "itsLength", "=", "itsInterfaces", ".", "length", ";", "if", "(", "nextPosition", "+", "itsLength", ">=", "interfacesToVisit", ".", "length", ")", "System", ".", "arraycopy", "(", "interfacesToVisit", ",", "0", ",", "interfacesToVisit", "=", "new", "ReferenceBinding", "[", "nextPosition", "+", "itsLength", "+", "5", "]", ",", "0", ",", "nextPosition", ")", ";", "nextInterface", ":", "for", "(", "int", "a", "=", "0", ";", "a", "<", "itsLength", ";", "a", "++", ")", "{", "ReferenceBinding", "next", "=", "itsInterfaces", "[", "a", "]", ";", "for", "(", "int", "b", "=", "0", ";", "b", "<", "nextPosition", ";", "b", "++", ")", "if", "(", "next", "==", "interfacesToVisit", "[", "b", "]", ")", "continue", "nextInterface", ";", "interfacesToVisit", "[", "nextPosition", "++", "]", "=", "next", ";", "}", "}", "}", "if", "(", "(", "currentType", "=", "currentType", ".", "superclass", "(", ")", ")", "==", "null", ")", "break", ";", "unitScope", ".", "recordTypeReference", "(", "currentType", ")", ";", "currentType", ".", "initializeForStaticImports", "(", ")", ";", "currentType", "=", "(", "ReferenceBinding", ")", "currentType", ".", "capture", "(", "this", ",", "invocationSite", "==", "null", "?", "0", ":", "invocationSite", ".", "sourceEnd", "(", ")", ")", ";", "if", "(", "(", "field", "=", "currentType", ".", "getField", "(", "fieldName", ",", "needResolve", ")", ")", "!=", "null", ")", "{", "keepLooking", "=", "false", ";", "if", "(", "field", ".", "canBeSeenBy", "(", "receiverType", ",", "invocationSite", ",", "this", ")", ")", "{", "if", "(", "visibleField", "==", "null", ")", "visibleField", "=", "field", ";", "else", "return", "new", "ProblemFieldBinding", "(", "visibleField", ",", "visibleField", ".", "declaringClass", ",", "fieldName", ",", "ProblemReasons", ".", "Ambiguous", ")", ";", "}", "else", "{", "if", "(", "notVisibleField", "==", "null", ")", "notVisibleField", "=", "field", ";", "}", "}", "}", "if", "(", "interfacesToVisit", "!=", "null", ")", "{", "ProblemFieldBinding", "ambiguous", "=", "null", ";", "done", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "nextPosition", ";", "i", "++", ")", "{", "ReferenceBinding", "anInterface", "=", "interfacesToVisit", "[", "i", "]", ";", "unitScope", ".", "recordTypeReference", "(", "anInterface", ")", ";", "if", "(", "(", "field", "=", "anInterface", ".", "getField", "(", "fieldName", ",", "true", ")", ")", "!=", "null", ")", "{", "if", "(", "visibleField", "==", "null", ")", "{", "visibleField", "=", "field", ";", "}", "else", "{", "ambiguous", "=", "new", "ProblemFieldBinding", "(", "visibleField", ",", "visibleField", ".", "declaringClass", ",", "fieldName", ",", "ProblemReasons", ".", "Ambiguous", ")", ";", "break", "done", ";", "}", "}", "else", "{", "ReferenceBinding", "[", "]", "itsInterfaces", "=", "anInterface", ".", "superInterfaces", "(", ")", ";", "if", "(", "itsInterfaces", "!=", "null", "&&", "itsInterfaces", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "int", "itsLength", "=", "itsInterfaces", ".", "length", ";", "if", "(", "nextPosition", "+", "itsLength", ">=", "interfacesToVisit", ".", "length", ")", "System", ".", "arraycopy", "(", "interfacesToVisit", ",", "0", ",", "interfacesToVisit", "=", "new", "ReferenceBinding", "[", "nextPosition", "+", "itsLength", "+", "5", "]", ",", "0", ",", "nextPosition", ")", ";", "nextInterface", ":", "for", "(", "int", "a", "=", "0", ";", "a", "<", "itsLength", ";", "a", "++", ")", "{", "ReferenceBinding", "next", "=", "itsInterfaces", "[", "a", "]", ";", "for", "(", "int", "b", "=", "0", ";", "b", "<", "nextPosition", ";", "b", "++", ")", "if", "(", "next", "==", "interfacesToVisit", "[", "b", "]", ")", "continue", "nextInterface", ";", "interfacesToVisit", "[", "nextPosition", "++", "]", "=", "next", ";", "}", "}", "}", "}", "if", "(", "ambiguous", "!=", "null", ")", "return", "ambiguous", ";", "}", "if", "(", "visibleField", "!=", "null", ")", "return", "visibleField", ";", "if", "(", "notVisibleField", "!=", "null", ")", "{", "return", "new", "ProblemFieldBinding", "(", "notVisibleField", ",", "currentType", ",", "fieldName", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "}", "return", "null", ";", "}", "public", "ReferenceBinding", "findMemberType", "(", "char", "[", "]", "typeName", ",", "ReferenceBinding", "enclosingType", ")", "{", "if", "(", "(", "enclosingType", ".", "tagBits", "&", "TagBits", ".", "HasNoMemberTypes", ")", "!=", "0", ")", "return", "null", ";", "ReferenceBinding", "enclosingSourceType", "=", "enclosingSourceType", "(", ")", ";", "PackageBinding", "currentPackage", "=", "getCurrentPackage", "(", ")", ";", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordReference", "(", "enclosingType", ",", "typeName", ")", ";", "ReferenceBinding", "memberType", "=", "enclosingType", ".", "getMemberType", "(", "typeName", ")", ";", "if", "(", "memberType", "!=", "null", ")", "{", "unitScope", ".", "recordTypeReference", "(", "memberType", ")", ";", "if", "(", "enclosingSourceType", "==", "null", "||", "(", "this", ".", "parent", "==", "unitScope", "&&", "(", "enclosingSourceType", ".", "tagBits", "&", "TagBits", ".", "TypeVariablesAreConnected", ")", "==", "0", ")", "?", "memberType", ".", "canBeSeenBy", "(", "currentPackage", ")", ":", "memberType", ".", "canBeSeenBy", "(", "enclosingType", ",", "enclosingSourceType", ")", ")", "return", "memberType", ";", "return", "new", "ProblemReferenceBinding", "(", "new", "char", "[", "]", "[", "]", "{", "typeName", "}", ",", "memberType", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "}", "ReferenceBinding", "currentType", "=", "enclosingType", ";", "ReferenceBinding", "[", "]", "interfacesToVisit", "=", "null", ";", "int", "nextPosition", "=", "0", ";", "ReferenceBinding", "visibleMemberType", "=", "null", ";", "boolean", "keepLooking", "=", "true", ";", "ReferenceBinding", "notVisible", "=", "null", ";", "while", "(", "keepLooking", ")", "{", "ReferenceBinding", "[", "]", "itsInterfaces", "=", "currentType", ".", "superInterfaces", "(", ")", ";", "if", "(", "itsInterfaces", "==", "null", ")", "{", "ReferenceBinding", "sourceType", "=", "currentType", ".", "isParameterizedType", "(", ")", "?", "(", "(", "ParameterizedTypeBinding", ")", "currentType", ")", ".", "genericType", "(", ")", ":", "currentType", ";", "if", "(", "sourceType", ".", "isHierarchyBeingConnected", "(", ")", ")", "return", "null", ";", "(", "(", "SourceTypeBinding", ")", "sourceType", ")", ".", "scope", ".", "connectTypeHierarchy", "(", ")", ";", "itsInterfaces", "=", "currentType", ".", "superInterfaces", "(", ")", ";", "}", "if", "(", "itsInterfaces", "!=", "null", "&&", "itsInterfaces", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "if", "(", "interfacesToVisit", "==", "null", ")", "{", "interfacesToVisit", "=", "itsInterfaces", ";", "nextPosition", "=", "interfacesToVisit", ".", "length", ";", "}", "else", "{", "int", "itsLength", "=", "itsInterfaces", ".", "length", ";", "if", "(", "nextPosition", "+", "itsLength", ">=", "interfacesToVisit", ".", "length", ")", "System", ".", "arraycopy", "(", "interfacesToVisit", ",", "0", ",", "interfacesToVisit", "=", "new", "ReferenceBinding", "[", "nextPosition", "+", "itsLength", "+", "5", "]", ",", "0", ",", "nextPosition", ")", ";", "nextInterface", ":", "for", "(", "int", "a", "=", "0", ";", "a", "<", "itsLength", ";", "a", "++", ")", "{", "ReferenceBinding", "next", "=", "itsInterfaces", "[", "a", "]", ";", "for", "(", "int", "b", "=", "0", ";", "b", "<", "nextPosition", ";", "b", "++", ")", "if", "(", "next", "==", "interfacesToVisit", "[", "b", "]", ")", "continue", "nextInterface", ";", "interfacesToVisit", "[", "nextPosition", "++", "]", "=", "next", ";", "}", "}", "}", "if", "(", "(", "currentType", "=", "currentType", ".", "superclass", "(", ")", ")", "==", "null", ")", "break", ";", "unitScope", ".", "recordReference", "(", "currentType", ",", "typeName", ")", ";", "if", "(", "(", "memberType", "=", "currentType", ".", "getMemberType", "(", "typeName", ")", ")", "!=", "null", ")", "{", "unitScope", ".", "recordTypeReference", "(", "memberType", ")", ";", "keepLooking", "=", "false", ";", "if", "(", "enclosingSourceType", "==", "null", "?", "memberType", ".", "canBeSeenBy", "(", "currentPackage", ")", ":", "memberType", ".", "canBeSeenBy", "(", "enclosingType", ",", "enclosingSourceType", ")", ")", "{", "if", "(", "visibleMemberType", "==", "null", ")", "visibleMemberType", "=", "memberType", ";", "else", "return", "new", "ProblemReferenceBinding", "(", "new", "char", "[", "]", "[", "]", "{", "typeName", "}", ",", "visibleMemberType", ",", "ProblemReasons", ".", "Ambiguous", ")", ";", "}", "else", "{", "notVisible", "=", "memberType", ";", "}", "}", "}", "if", "(", "interfacesToVisit", "!=", "null", ")", "{", "ProblemReferenceBinding", "ambiguous", "=", "null", ";", "done", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "nextPosition", ";", "i", "++", ")", "{", "ReferenceBinding", "anInterface", "=", "interfacesToVisit", "[", "i", "]", ";", "unitScope", ".", "recordReference", "(", "anInterface", ",", "typeName", ")", ";", "if", "(", "(", "memberType", "=", "anInterface", ".", "getMemberType", "(", "typeName", ")", ")", "!=", "null", ")", "{", "unitScope", ".", "recordTypeReference", "(", "memberType", ")", ";", "if", "(", "visibleMemberType", "==", "null", ")", "{", "visibleMemberType", "=", "memberType", ";", "}", "else", "{", "ambiguous", "=", "new", "ProblemReferenceBinding", "(", "new", "char", "[", "]", "[", "]", "{", "typeName", "}", ",", "visibleMemberType", ",", "ProblemReasons", ".", "Ambiguous", ")", ";", "break", "done", ";", "}", "}", "else", "{", "ReferenceBinding", "[", "]", "itsInterfaces", "=", "anInterface", ".", "superInterfaces", "(", ")", ";", "if", "(", "itsInterfaces", "!=", "null", "&&", "itsInterfaces", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "int", "itsLength", "=", "itsInterfaces", ".", "length", ";", "if", "(", "nextPosition", "+", "itsLength", ">=", "interfacesToVisit", ".", "length", ")", "System", ".", "arraycopy", "(", "interfacesToVisit", ",", "0", ",", "interfacesToVisit", "=", "new", "ReferenceBinding", "[", "nextPosition", "+", "itsLength", "+", "5", "]", ",", "0", ",", "nextPosition", ")", ";", "nextInterface", ":", "for", "(", "int", "a", "=", "0", ";", "a", "<", "itsLength", ";", "a", "++", ")", "{", "ReferenceBinding", "next", "=", "itsInterfaces", "[", "a", "]", ";", "for", "(", "int", "b", "=", "0", ";", "b", "<", "nextPosition", ";", "b", "++", ")", "if", "(", "next", "==", "interfacesToVisit", "[", "b", "]", ")", "continue", "nextInterface", ";", "interfacesToVisit", "[", "nextPosition", "++", "]", "=", "next", ";", "}", "}", "}", "}", "if", "(", "ambiguous", "!=", "null", ")", "return", "ambiguous", ";", "}", "if", "(", "visibleMemberType", "!=", "null", ")", "return", "visibleMemberType", ";", "if", "(", "notVisible", "!=", "null", ")", "return", "new", "ProblemReferenceBinding", "(", "new", "char", "[", "]", "[", "]", "{", "typeName", "}", ",", "notVisible", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "return", "null", ";", "}", "public", "MethodBinding", "findMethod", "(", "ReferenceBinding", "receiverType", ",", "char", "[", "]", "selector", ",", "TypeBinding", "[", "]", "argumentTypes", ",", "InvocationSite", "invocationSite", ")", "{", "return", "findMethod", "(", "receiverType", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ",", "false", ")", ";", "}", "public", "MethodBinding", "oneLastLook", "(", "ReferenceBinding", "receiverType", ",", "char", "[", "]", "selector", ",", "TypeBinding", "[", "]", "argumentTypes", ",", "InvocationSite", "invocationSite", ")", "{", "MethodBinding", "[", "]", "extraMethods", "=", "receiverType", ".", "getAnyExtraMethods", "(", "selector", ")", ";", "if", "(", "extraMethods", "!=", "null", ")", "{", "return", "extraMethods", "[", "0", "]", ";", "}", "else", "{", "return", "null", ";", "}", "}", "public", "MethodBinding", "findMethod", "(", "ReferenceBinding", "receiverType", ",", "char", "[", "]", "selector", ",", "TypeBinding", "[", "]", "argumentTypes", ",", "InvocationSite", "invocationSite", ",", "boolean", "inStaticContext", ")", "{", "ReferenceBinding", "currentType", "=", "receiverType", ";", "boolean", "receiverTypeIsInterface", "=", "receiverType", ".", "isInterface", "(", ")", ";", "ObjectVector", "found", "=", "new", "ObjectVector", "(", "3", ")", ";", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordTypeReferences", "(", "argumentTypes", ")", ";", "if", "(", "receiverTypeIsInterface", ")", "{", "unitScope", ".", "recordTypeReference", "(", "receiverType", ")", ";", "MethodBinding", "[", "]", "receiverMethods", "=", "receiverType", ".", "getMethods", "(", "selector", ",", "argumentTypes", ".", "length", ")", ";", "if", "(", "receiverMethods", ".", "length", ">", "0", ")", "found", ".", "addAll", "(", "receiverMethods", ")", ";", "findMethodInSuperInterfaces", "(", "receiverType", ",", "selector", ",", "found", ",", "invocationSite", ")", ";", "currentType", "=", "getJavaLangObject", "(", ")", ";", "}", "long", "complianceLevel", "=", "compilerOptions", "(", ")", ".", "complianceLevel", ";", "boolean", "isCompliant14", "=", "complianceLevel", ">=", "ClassFileConstants", ".", "JDK1_4", ";", "boolean", "isCompliant15", "=", "complianceLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ";", "ReferenceBinding", "classHierarchyStart", "=", "currentType", ";", "MethodVerifier", "verifier", "=", "environment", "(", ")", ".", "methodVerifier", "(", ")", ";", "while", "(", "currentType", "!=", "null", ")", "{", "unitScope", ".", "recordTypeReference", "(", "currentType", ")", ";", "currentType", "=", "(", "ReferenceBinding", ")", "currentType", ".", "capture", "(", "this", ",", "invocationSite", "==", "null", "?", "0", ":", "invocationSite", ".", "sourceEnd", "(", ")", ")", ";", "MethodBinding", "[", "]", "currentMethods", "=", "currentType", ".", "getMethods", "(", "selector", ",", "argumentTypes", ".", "length", ")", ";", "int", "currentLength", "=", "currentMethods", ".", "length", ";", "if", "(", "currentLength", ">", "0", ")", "{", "if", "(", "isCompliant14", "&&", "(", "receiverTypeIsInterface", "||", "found", ".", "size", ">", "0", ")", ")", "{", "nextMethod", ":", "for", "(", "int", "i", "=", "0", ",", "l", "=", "currentLength", ";", "i", "<", "l", ";", "i", "++", ")", "{", "MethodBinding", "currentMethod", "=", "currentMethods", "[", "i", "]", ";", "if", "(", "currentMethod", "==", "null", ")", "continue", "nextMethod", ";", "if", "(", "receiverTypeIsInterface", "&&", "!", "currentMethod", ".", "isPublic", "(", ")", ")", "{", "currentLength", "--", ";", "currentMethods", "[", "i", "]", "=", "null", ";", "continue", "nextMethod", ";", "}", "for", "(", "int", "j", "=", "0", ",", "max", "=", "found", ".", "size", ";", "j", "<", "max", ";", "j", "++", ")", "{", "MethodBinding", "matchingMethod", "=", "(", "MethodBinding", ")", "found", ".", "elementAt", "(", "j", ")", ";", "MethodBinding", "matchingOriginal", "=", "matchingMethod", ".", "original", "(", ")", ";", "MethodBinding", "currentOriginal", "=", "matchingOriginal", ".", "findOriginalInheritedMethod", "(", "currentMethod", ")", ";", "if", "(", "currentOriginal", "!=", "null", "&&", "verifier", ".", "isParameterSubsignature", "(", "matchingOriginal", ",", "currentOriginal", ")", ")", "{", "if", "(", "isCompliant15", ")", "{", "if", "(", "matchingMethod", ".", "isBridge", "(", ")", "&&", "!", "currentMethod", ".", "isBridge", "(", ")", ")", "continue", "nextMethod", ";", "}", "currentLength", "--", ";", "currentMethods", "[", "i", "]", "=", "null", ";", "continue", "nextMethod", ";", "}", "}", "}", "}", "if", "(", "currentLength", ">", "0", ")", "{", "if", "(", "currentMethods", ".", "length", "==", "currentLength", ")", "{", "found", ".", "addAll", "(", "currentMethods", ")", ";", "}", "else", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "currentMethods", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "MethodBinding", "currentMethod", "=", "currentMethods", "[", "i", "]", ";", "if", "(", "currentMethod", "!=", "null", ")", "found", ".", "add", "(", "currentMethod", ")", ";", "}", "}", "}", "}", "currentType", "=", "currentType", ".", "superclass", "(", ")", ";", "}", "int", "foundSize", "=", "found", ".", "size", ";", "MethodBinding", "[", "]", "candidates", "=", "null", ";", "int", "candidatesCount", "=", "0", ";", "MethodBinding", "problemMethod", "=", "null", ";", "boolean", "searchForDefaultAbstractMethod", "=", "isCompliant14", "&&", "!", "receiverTypeIsInterface", "&&", "(", "receiverType", ".", "isAbstract", "(", ")", "||", "receiverType", ".", "isTypeVariable", "(", ")", ")", ";", "if", "(", "foundSize", ">", "0", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "foundSize", ";", "i", "++", ")", "{", "MethodBinding", "methodBinding", "=", "(", "MethodBinding", ")", "found", ".", "elementAt", "(", "i", ")", ";", "MethodBinding", "compatibleMethod", "=", "computeCompatibleMethod", "(", "methodBinding", ",", "argumentTypes", ",", "invocationSite", ")", ";", "if", "(", "compatibleMethod", "!=", "null", ")", "{", "if", "(", "compatibleMethod", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "foundSize", "==", "1", "&&", "compatibleMethod", ".", "canBeSeenBy", "(", "receiverType", ",", "invocationSite", ",", "this", ")", ")", "{", "if", "(", "searchForDefaultAbstractMethod", ")", "return", "findDefaultAbstractMethod", "(", "receiverType", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ",", "classHierarchyStart", ",", "found", ",", "compatibleMethod", ")", ";", "unitScope", ".", "recordTypeReferences", "(", "compatibleMethod", ".", "thrownExceptions", ")", ";", "return", "compatibleMethod", ";", "}", "if", "(", "candidatesCount", "==", "0", ")", "candidates", "=", "new", "MethodBinding", "[", "foundSize", "]", ";", "candidates", "[", "candidatesCount", "++", "]", "=", "compatibleMethod", ";", "}", "else", "if", "(", "problemMethod", "==", "null", ")", "{", "problemMethod", "=", "compatibleMethod", ";", "}", "}", "}", "}", "if", "(", "candidatesCount", "==", "0", ")", "{", "if", "(", "problemMethod", "!=", "null", ")", "{", "switch", "(", "problemMethod", ".", "problemId", "(", ")", ")", "{", "case", "ProblemReasons", ".", "TypeArgumentsForRawGenericMethod", ":", "case", "ProblemReasons", ".", "TypeParameterArityMismatch", ":", "return", "problemMethod", ";", "}", "}", "MethodBinding", "interfaceMethod", "=", "findDefaultAbstractMethod", "(", "receiverType", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ",", "classHierarchyStart", ",", "found", ",", "null", ")", ";", "if", "(", "interfaceMethod", "!=", "null", ")", "return", "interfaceMethod", ";", "if", "(", "found", ".", "size", "==", "0", ")", "return", "null", ";", "if", "(", "problemMethod", "!=", "null", ")", "return", "problemMethod", ";", "int", "bestArgMatches", "=", "-", "1", ";", "MethodBinding", "bestGuess", "=", "(", "MethodBinding", ")", "found", ".", "elementAt", "(", "0", ")", ";", "int", "argLength", "=", "argumentTypes", ".", "length", ";", "foundSize", "=", "found", ".", "size", ";", "nextMethod", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "foundSize", ";", "i", "++", ")", "{", "MethodBinding", "methodBinding", "=", "(", "MethodBinding", ")", "found", ".", "elementAt", "(", "i", ")", ";", "TypeBinding", "[", "]", "params", "=", "methodBinding", ".", "parameters", ";", "int", "paramLength", "=", "params", ".", "length", ";", "int", "argMatches", "=", "0", ";", "next", ":", "for", "(", "int", "a", "=", "0", ";", "a", "<", "argLength", ";", "a", "++", ")", "{", "TypeBinding", "arg", "=", "argumentTypes", "[", "a", "]", ";", "for", "(", "int", "p", "=", "a", "==", "0", "?", "0", ":", "a", "-", "1", ";", "p", "<", "paramLength", "&&", "p", "<", "a", "+", "1", ";", "p", "++", ")", "{", "if", "(", "params", "[", "p", "]", "==", "arg", ")", "{", "argMatches", "++", ";", "continue", "next", ";", "}", "}", "}", "if", "(", "argMatches", "<", "bestArgMatches", ")", "continue", "nextMethod", ";", "if", "(", "argMatches", "==", "bestArgMatches", ")", "{", "int", "diff1", "=", "paramLength", "<", "argLength", "?", "2", "*", "(", "argLength", "-", "paramLength", ")", ":", "paramLength", "-", "argLength", ";", "int", "bestLength", "=", "bestGuess", ".", "parameters", ".", "length", ";", "int", "diff2", "=", "bestLength", "<", "argLength", "?", "2", "*", "(", "argLength", "-", "bestLength", ")", ":", "bestLength", "-", "argLength", ";", "if", "(", "diff1", ">=", "diff2", ")", "continue", "nextMethod", ";", "}", "bestArgMatches", "=", "argMatches", ";", "bestGuess", "=", "methodBinding", ";", "}", "return", "new", "ProblemMethodBinding", "(", "bestGuess", ",", "bestGuess", ".", "selector", ",", "argumentTypes", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "int", "visiblesCount", "=", "0", ";", "if", "(", "receiverTypeIsInterface", ")", "{", "if", "(", "candidatesCount", "==", "1", ")", "{", "unitScope", ".", "recordTypeReferences", "(", "candidates", "[", "0", "]", ".", "thrownExceptions", ")", ";", "return", "candidates", "[", "0", "]", ";", "}", "visiblesCount", "=", "candidatesCount", ";", "}", "else", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "candidatesCount", ";", "i", "++", ")", "{", "MethodBinding", "methodBinding", "=", "candidates", "[", "i", "]", ";", "if", "(", "methodBinding", ".", "canBeSeenBy", "(", "receiverType", ",", "invocationSite", ",", "this", ")", ")", "{", "if", "(", "visiblesCount", "!=", "i", ")", "{", "candidates", "[", "i", "]", "=", "null", ";", "candidates", "[", "visiblesCount", "]", "=", "methodBinding", ";", "}", "visiblesCount", "++", ";", "}", "}", "switch", "(", "visiblesCount", ")", "{", "case", "0", ":", "MethodBinding", "interfaceMethod", "=", "findDefaultAbstractMethod", "(", "receiverType", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ",", "classHierarchyStart", ",", "found", ",", "null", ")", ";", "if", "(", "interfaceMethod", "!=", "null", ")", "return", "interfaceMethod", ";", "return", "new", "ProblemMethodBinding", "(", "candidates", "[", "0", "]", ",", "candidates", "[", "0", "]", ".", "selector", ",", "candidates", "[", "0", "]", ".", "parameters", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "case", "1", ":", "if", "(", "searchForDefaultAbstractMethod", ")", "return", "findDefaultAbstractMethod", "(", "receiverType", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ",", "classHierarchyStart", ",", "found", ",", "candidates", "[", "0", "]", ")", ";", "unitScope", ".", "recordTypeReferences", "(", "candidates", "[", "0", "]", ".", "thrownExceptions", ")", ";", "return", "candidates", "[", "0", "]", ";", "default", ":", "break", ";", "}", "}", "if", "(", "complianceLevel", "<=", "ClassFileConstants", ".", "JDK1_3", ")", "{", "ReferenceBinding", "declaringClass", "=", "candidates", "[", "0", "]", ".", "declaringClass", ";", "return", "!", "declaringClass", ".", "isInterface", "(", ")", "?", "mostSpecificClassMethodBinding", "(", "candidates", ",", "visiblesCount", ",", "invocationSite", ")", ":", "mostSpecificInterfaceMethodBinding", "(", "candidates", ",", "visiblesCount", ",", "invocationSite", ")", ";", "}", "if", "(", "compilerOptions", "(", ")", ".", "sourceLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "visiblesCount", ";", "i", "++", ")", "{", "MethodBinding", "candidate", "=", "candidates", "[", "i", "]", ";", "if", "(", "candidate", "instanceof", "ParameterizedGenericMethodBinding", ")", "candidate", "=", "(", "(", "ParameterizedGenericMethodBinding", ")", "candidate", ")", ".", "originalMethod", ";", "if", "(", "candidate", ".", "hasSubstitutedParameters", "(", ")", ")", "{", "for", "(", "int", "j", "=", "i", "+", "1", ";", "j", "<", "visiblesCount", ";", "j", "++", ")", "{", "MethodBinding", "otherCandidate", "=", "candidates", "[", "j", "]", ";", "if", "(", "otherCandidate", ".", "hasSubstitutedParameters", "(", ")", ")", "{", "if", "(", "otherCandidate", "==", "candidate", "||", "(", "candidate", ".", "declaringClass", "==", "otherCandidate", ".", "declaringClass", "&&", "candidate", ".", "areParametersEqual", "(", "otherCandidate", ")", ")", ")", "{", "return", "new", "ProblemMethodBinding", "(", "candidates", "[", "i", "]", ",", "candidates", "[", "i", "]", ".", "selector", ",", "candidates", "[", "i", "]", ".", "parameters", ",", "ProblemReasons", ".", "Ambiguous", ")", ";", "}", "}", "}", "}", "}", "}", "if", "(", "inStaticContext", ")", "{", "MethodBinding", "[", "]", "staticCandidates", "=", "new", "MethodBinding", "[", "visiblesCount", "]", ";", "int", "staticCount", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "visiblesCount", ";", "i", "++", ")", "if", "(", "candidates", "[", "i", "]", ".", "isStatic", "(", ")", ")", "staticCandidates", "[", "staticCount", "++", "]", "=", "candidates", "[", "i", "]", ";", "if", "(", "staticCount", "==", "1", ")", "return", "staticCandidates", "[", "0", "]", ";", "if", "(", "staticCount", ">", "1", ")", "return", "mostSpecificMethodBinding", "(", "staticCandidates", ",", "staticCount", ",", "argumentTypes", ",", "invocationSite", ",", "receiverType", ")", ";", "}", "MethodBinding", "mostSpecificMethod", "=", "mostSpecificMethodBinding", "(", "candidates", ",", "visiblesCount", ",", "argumentTypes", ",", "invocationSite", ",", "receiverType", ")", ";", "if", "(", "searchForDefaultAbstractMethod", ")", "{", "if", "(", "mostSpecificMethod", ".", "isValidBinding", "(", ")", ")", "return", "findDefaultAbstractMethod", "(", "receiverType", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ",", "classHierarchyStart", ",", "found", ",", "mostSpecificMethod", ")", ";", "MethodBinding", "interfaceMethod", "=", "findDefaultAbstractMethod", "(", "receiverType", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ",", "classHierarchyStart", ",", "found", ",", "null", ")", ";", "if", "(", "interfaceMethod", "!=", "null", "&&", "interfaceMethod", ".", "isValidBinding", "(", ")", ")", "return", "interfaceMethod", ";", "}", "return", "mostSpecificMethod", ";", "}", "public", "MethodBinding", "findMethodForArray", "(", "ArrayBinding", "receiverType", ",", "char", "[", "]", "selector", ",", "TypeBinding", "[", "]", "argumentTypes", ",", "InvocationSite", "invocationSite", ")", "{", "TypeBinding", "leafType", "=", "receiverType", ".", "leafComponentType", "(", ")", ";", "if", "(", "leafType", "instanceof", "ReferenceBinding", ")", "{", "if", "(", "!", "(", "(", "ReferenceBinding", ")", "leafType", ")", ".", "canBeSeenBy", "(", "this", ")", ")", "return", "new", "ProblemMethodBinding", "(", "selector", ",", "Binding", ".", "NO_PARAMETERS", ",", "(", "ReferenceBinding", ")", "leafType", ",", "ProblemReasons", ".", "ReceiverTypeNotVisible", ")", ";", "}", "ReferenceBinding", "object", "=", "getJavaLangObject", "(", ")", ";", "MethodBinding", "methodBinding", "=", "object", ".", "getExactMethod", "(", "selector", ",", "argumentTypes", ",", "null", ")", ";", "if", "(", "methodBinding", "!=", "null", ")", "{", "if", "(", "argumentTypes", "==", "Binding", ".", "NO_PARAMETERS", ")", "{", "switch", "(", "selector", "[", "0", "]", ")", "{", "case", "'c'", ":", "if", "(", "CharOperation", ".", "equals", "(", "selector", ",", "TypeConstants", ".", "CLONE", ")", ")", "{", "return", "environment", "(", ")", ".", "computeArrayClone", "(", "methodBinding", ")", ";", "}", "break", ";", "case", "'g'", ":", "if", "(", "CharOperation", ".", "equals", "(", "selector", ",", "TypeConstants", ".", "GETCLASS", ")", "&&", "methodBinding", ".", "returnType", ".", "isParameterizedType", "(", ")", ")", "{", "return", "environment", "(", ")", ".", "createGetClassMethod", "(", "receiverType", ",", "methodBinding", ",", "this", ")", ";", "}", "break", ";", "}", "}", "if", "(", "methodBinding", ".", "canBeSeenBy", "(", "receiverType", ",", "invocationSite", ",", "this", ")", ")", "return", "methodBinding", ";", "}", "methodBinding", "=", "findMethod", "(", "object", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ")", ";", "if", "(", "methodBinding", "==", "null", ")", "return", "new", "ProblemMethodBinding", "(", "selector", ",", "argumentTypes", ",", "ProblemReasons", ".", "NotFound", ")", ";", "return", "methodBinding", ";", "}", "protected", "void", "findMethodInSuperInterfaces", "(", "ReferenceBinding", "currentType", ",", "char", "[", "]", "selector", ",", "ObjectVector", "found", ",", "InvocationSite", "invocationSite", ")", "{", "ReferenceBinding", "[", "]", "itsInterfaces", "=", "currentType", ".", "superInterfaces", "(", ")", ";", "if", "(", "itsInterfaces", "!=", "null", "&&", "itsInterfaces", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "ReferenceBinding", "[", "]", "interfacesToVisit", "=", "itsInterfaces", ";", "int", "nextPosition", "=", "interfacesToVisit", ".", "length", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "nextPosition", ";", "i", "++", ")", "{", "currentType", "=", "interfacesToVisit", "[", "i", "]", ";", "compilationUnitScope", "(", ")", ".", "recordTypeReference", "(", "currentType", ")", ";", "currentType", "=", "(", "ReferenceBinding", ")", "currentType", ".", "capture", "(", "this", ",", "invocationSite", "==", "null", "?", "0", ":", "invocationSite", ".", "sourceEnd", "(", ")", ")", ";", "MethodBinding", "[", "]", "currentMethods", "=", "currentType", ".", "getMethods", "(", "selector", ")", ";", "if", "(", "currentMethods", ".", "length", ">", "0", ")", "{", "int", "foundSize", "=", "found", ".", "size", ";", "if", "(", "foundSize", ">", "0", ")", "{", "next", ":", "for", "(", "int", "c", "=", "0", ",", "l", "=", "currentMethods", ".", "length", ";", "c", "<", "l", ";", "c", "++", ")", "{", "MethodBinding", "current", "=", "currentMethods", "[", "c", "]", ";", "for", "(", "int", "f", "=", "0", ";", "f", "<", "foundSize", ";", "f", "++", ")", "if", "(", "current", "==", "found", ".", "elementAt", "(", "f", ")", ")", "continue", "next", ";", "found", ".", "add", "(", "current", ")", ";", "}", "}", "else", "{", "found", ".", "addAll", "(", "currentMethods", ")", ";", "}", "}", "if", "(", "(", "itsInterfaces", "=", "currentType", ".", "superInterfaces", "(", ")", ")", "!=", "null", "&&", "itsInterfaces", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "int", "itsLength", "=", "itsInterfaces", ".", "length", ";", "if", "(", "nextPosition", "+", "itsLength", ">=", "interfacesToVisit", ".", "length", ")", "System", ".", "arraycopy", "(", "interfacesToVisit", ",", "0", ",", "interfacesToVisit", "=", "new", "ReferenceBinding", "[", "nextPosition", "+", "itsLength", "+", "5", "]", ",", "0", ",", "nextPosition", ")", ";", "nextInterface", ":", "for", "(", "int", "a", "=", "0", ";", "a", "<", "itsLength", ";", "a", "++", ")", "{", "ReferenceBinding", "next", "=", "itsInterfaces", "[", "a", "]", ";", "for", "(", "int", "b", "=", "0", ";", "b", "<", "nextPosition", ";", "b", "++", ")", "if", "(", "next", "==", "interfacesToVisit", "[", "b", "]", ")", "continue", "nextInterface", ";", "interfacesToVisit", "[", "nextPosition", "++", "]", "=", "next", ";", "}", "}", "}", "}", "}", "public", "ReferenceBinding", "findType", "(", "char", "[", "]", "typeName", ",", "PackageBinding", "declarationPackage", ",", "PackageBinding", "invocationPackage", ")", "{", "compilationUnitScope", "(", ")", ".", "recordReference", "(", "declarationPackage", ".", "compoundName", ",", "typeName", ")", ";", "ReferenceBinding", "typeBinding", "=", "declarationPackage", ".", "getType", "(", "typeName", ")", ";", "if", "(", "typeBinding", "==", "null", ")", "return", "null", ";", "if", "(", "typeBinding", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "declarationPackage", "!=", "invocationPackage", "&&", "!", "typeBinding", ".", "canBeSeenBy", "(", "invocationPackage", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "new", "char", "[", "]", "[", "]", "{", "typeName", "}", ",", "typeBinding", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "}", "return", "typeBinding", ";", "}", "public", "LocalVariableBinding", "findVariable", "(", "char", "[", "]", "variable", ")", "{", "return", "null", ";", "}", "public", "Binding", "getBinding", "(", "char", "[", "]", "name", ",", "int", "mask", ",", "InvocationSite", "invocationSite", ",", "boolean", "needResolve", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "LookupEnvironment", "env", "=", "unitScope", ".", "environment", ";", "try", "{", "env", ".", "missingClassFileLocation", "=", "invocationSite", ";", "Binding", "binding", "=", "null", ";", "FieldBinding", "problemField", "=", "null", ";", "if", "(", "(", "mask", "&", "Binding", ".", "VARIABLE", ")", "!=", "0", ")", "{", "boolean", "insideStaticContext", "=", "false", ";", "boolean", "insideConstructorCall", "=", "false", ";", "boolean", "insideTypeAnnotation", "=", "false", ";", "FieldBinding", "foundField", "=", "null", ";", "ProblemFieldBinding", "foundInsideProblem", "=", "null", ";", "Scope", "scope", "=", "this", ";", "int", "depth", "=", "0", ";", "int", "foundDepth", "=", "0", ";", "ReferenceBinding", "foundActualReceiverType", "=", "null", ";", "done", ":", "while", "(", "true", ")", "{", "switch", "(", "scope", ".", "kind", ")", "{", "case", "METHOD_SCOPE", ":", "MethodScope", "methodScope", "=", "(", "MethodScope", ")", "scope", ";", "insideStaticContext", "|=", "methodScope", ".", "isStatic", ";", "insideConstructorCall", "|=", "methodScope", ".", "isConstructorCall", ";", "insideTypeAnnotation", "=", "methodScope", ".", "insideTypeAnnotation", ";", "case", "BLOCK_SCOPE", ":", "LocalVariableBinding", "variableBinding", "=", "scope", ".", "findVariable", "(", "name", ")", ";", "if", "(", "variableBinding", "!=", "null", ")", "{", "if", "(", "foundField", "!=", "null", "&&", "foundField", ".", "isValidBinding", "(", ")", ")", "return", "new", "ProblemFieldBinding", "(", "foundField", ",", "foundField", ".", "declaringClass", ",", "name", ",", "ProblemReasons", ".", "InheritedNameHidesEnclosingName", ")", ";", "if", "(", "depth", ">", "0", ")", "invocationSite", ".", "setDepth", "(", "depth", ")", ";", "return", "variableBinding", ";", "}", "break", ";", "case", "CLASS_SCOPE", ":", "ClassScope", "classScope", "=", "(", "ClassScope", ")", "scope", ";", "ReferenceBinding", "receiverType", "=", "classScope", ".", "enclosingReceiverType", "(", ")", ";", "if", "(", "!", "insideTypeAnnotation", ")", "{", "FieldBinding", "fieldBinding", "=", "classScope", ".", "findField", "(", "receiverType", ",", "name", ",", "invocationSite", ",", "needResolve", ")", ";", "if", "(", "fieldBinding", "!=", "null", ")", "{", "if", "(", "fieldBinding", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "Ambiguous", ")", "{", "if", "(", "foundField", "==", "null", "||", "foundField", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "NotVisible", ")", "return", "fieldBinding", ";", "return", "new", "ProblemFieldBinding", "(", "foundField", ",", "foundField", ".", "declaringClass", ",", "name", ",", "ProblemReasons", ".", "InheritedNameHidesEnclosingName", ")", ";", "}", "ProblemFieldBinding", "insideProblem", "=", "null", ";", "if", "(", "fieldBinding", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "!", "fieldBinding", ".", "isStatic", "(", ")", ")", "{", "if", "(", "insideConstructorCall", ")", "{", "insideProblem", "=", "new", "ProblemFieldBinding", "(", "fieldBinding", ",", "fieldBinding", ".", "declaringClass", ",", "name", ",", "ProblemReasons", ".", "NonStaticReferenceInConstructorInvocation", ")", ";", "}", "else", "if", "(", "insideStaticContext", ")", "{", "insideProblem", "=", "new", "ProblemFieldBinding", "(", "fieldBinding", ",", "fieldBinding", ".", "declaringClass", ",", "name", ",", "ProblemReasons", ".", "NonStaticReferenceInStaticContext", ")", ";", "}", "}", "if", "(", "receiverType", "==", "fieldBinding", ".", "declaringClass", "||", "compilerOptions", "(", ")", ".", "complianceLevel", ">=", "ClassFileConstants", ".", "JDK1_4", ")", "{", "if", "(", "foundField", "==", "null", ")", "{", "if", "(", "depth", ">", "0", ")", "{", "invocationSite", ".", "setDepth", "(", "depth", ")", ";", "invocationSite", ".", "setActualReceiverType", "(", "receiverType", ")", ";", "}", "return", "insideProblem", "==", "null", "?", "fieldBinding", ":", "insideProblem", ";", "}", "if", "(", "foundField", ".", "isValidBinding", "(", ")", ")", "if", "(", "foundField", ".", "declaringClass", "!=", "fieldBinding", ".", "declaringClass", ")", "return", "new", "ProblemFieldBinding", "(", "foundField", ",", "foundField", ".", "declaringClass", ",", "name", ",", "ProblemReasons", ".", "InheritedNameHidesEnclosingName", ")", ";", "}", "}", "if", "(", "foundField", "==", "null", "||", "(", "foundField", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "NotVisible", "&&", "fieldBinding", ".", "problemId", "(", ")", "!=", "ProblemReasons", ".", "NotVisible", ")", ")", "{", "foundDepth", "=", "depth", ";", "foundActualReceiverType", "=", "receiverType", ";", "foundInsideProblem", "=", "insideProblem", ";", "foundField", "=", "fieldBinding", ";", "}", "}", "}", "insideTypeAnnotation", "=", "false", ";", "depth", "++", ";", "insideStaticContext", "|=", "receiverType", ".", "isStatic", "(", ")", ";", "MethodScope", "enclosingMethodScope", "=", "scope", ".", "methodScope", "(", ")", ";", "insideConstructorCall", "=", "enclosingMethodScope", "==", "null", "?", "false", ":", "enclosingMethodScope", ".", "isConstructorCall", ";", "break", ";", "case", "COMPILATION_UNIT_SCOPE", ":", "break", "done", ";", "}", "scope", "=", "scope", ".", "parent", ";", "}", "if", "(", "foundInsideProblem", "!=", "null", ")", "return", "foundInsideProblem", ";", "if", "(", "foundField", "!=", "null", ")", "{", "if", "(", "foundField", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "foundDepth", ">", "0", ")", "{", "invocationSite", ".", "setDepth", "(", "foundDepth", ")", ";", "invocationSite", ".", "setActualReceiverType", "(", "foundActualReceiverType", ")", ";", "}", "return", "foundField", ";", "}", "problemField", "=", "foundField", ";", "foundField", "=", "null", ";", "}", "if", "(", "compilerOptions", "(", ")", ".", "sourceLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "unitScope", ".", "faultInImports", "(", ")", ";", "ImportBinding", "[", "]", "imports", "=", "unitScope", ".", "imports", ";", "if", "(", "imports", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "imports", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "ImportBinding", "importBinding", "=", "imports", "[", "i", "]", ";", "if", "(", "importBinding", ".", "isStatic", "(", ")", "&&", "!", "importBinding", ".", "onDemand", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "importBinding", ".", "compoundName", "[", "importBinding", ".", "compoundName", ".", "length", "-", "1", "]", ",", "name", ")", ")", "{", "if", "(", "unitScope", ".", "resolveSingleImport", "(", "importBinding", ",", "Binding", ".", "TYPE", "|", "Binding", ".", "FIELD", "|", "Binding", ".", "METHOD", ")", "!=", "null", "&&", "importBinding", ".", "resolvedImport", "instanceof", "FieldBinding", ")", "{", "foundField", "=", "(", "FieldBinding", ")", "importBinding", ".", "resolvedImport", ";", "ImportReference", "importReference", "=", "importBinding", ".", "reference", ";", "if", "(", "importReference", "!=", "null", "&&", "needResolve", ")", "{", "importReference", ".", "bits", "|=", "ASTNode", ".", "Used", ";", "}", "invocationSite", ".", "setActualReceiverType", "(", "foundField", ".", "declaringClass", ")", ";", "if", "(", "foundField", ".", "isValidBinding", "(", ")", ")", "{", "return", "foundField", ";", "}", "if", "(", "problemField", "==", "null", ")", "problemField", "=", "foundField", ";", "}", "}", "}", "}", "boolean", "foundInImport", "=", "false", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "imports", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "ImportBinding", "importBinding", "=", "imports", "[", "i", "]", ";", "if", "(", "importBinding", ".", "isStatic", "(", ")", "&&", "importBinding", ".", "onDemand", ")", "{", "Binding", "resolvedImport", "=", "importBinding", ".", "resolvedImport", ";", "if", "(", "resolvedImport", "instanceof", "ReferenceBinding", ")", "{", "FieldBinding", "temp", "=", "findField", "(", "(", "ReferenceBinding", ")", "resolvedImport", ",", "name", ",", "invocationSite", ",", "needResolve", ")", ";", "if", "(", "temp", "!=", "null", ")", "{", "if", "(", "!", "temp", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "problemField", "==", "null", ")", "problemField", "=", "temp", ";", "}", "else", "if", "(", "temp", ".", "isStatic", "(", ")", ")", "{", "if", "(", "foundField", "==", "temp", ")", "continue", ";", "ImportReference", "importReference", "=", "importBinding", ".", "reference", ";", "if", "(", "importReference", "!=", "null", "&&", "needResolve", ")", "{", "importReference", ".", "bits", "|=", "ASTNode", ".", "Used", ";", "}", "if", "(", "foundInImport", ")", "return", "new", "ProblemFieldBinding", "(", "foundField", ",", "foundField", ".", "declaringClass", ",", "name", ",", "ProblemReasons", ".", "Ambiguous", ")", ";", "foundField", "=", "temp", ";", "foundInImport", "=", "true", ";", "}", "}", "}", "}", "}", "if", "(", "foundField", "!=", "null", ")", "{", "invocationSite", ".", "setActualReceiverType", "(", "foundField", ".", "declaringClass", ")", ";", "return", "foundField", ";", "}", "}", "}", "}", "if", "(", "(", "mask", "&", "Binding", ".", "TYPE", ")", "!=", "0", ")", "{", "if", "(", "(", "binding", "=", "getBaseType", "(", "name", ")", ")", "!=", "null", ")", "return", "binding", ";", "binding", "=", "getTypeOrPackage", "(", "name", ",", "(", "mask", "&", "Binding", ".", "PACKAGE", ")", "==", "0", "?", "Binding", ".", "TYPE", ":", "Binding", ".", "TYPE", "|", "Binding", ".", "PACKAGE", ",", "needResolve", ")", ";", "if", "(", "binding", ".", "isValidBinding", "(", ")", "||", "mask", "==", "Binding", ".", "TYPE", ")", "return", "binding", ";", "}", "else", "if", "(", "(", "mask", "&", "Binding", ".", "PACKAGE", ")", "!=", "0", ")", "{", "unitScope", ".", "recordSimpleReference", "(", "name", ")", ";", "if", "(", "(", "binding", "=", "env", ".", "getTopLevelPackage", "(", "name", ")", ")", "!=", "null", ")", "return", "binding", ";", "}", "if", "(", "problemField", "!=", "null", ")", "return", "problemField", ";", "if", "(", "binding", "!=", "null", "&&", "binding", ".", "problemId", "(", ")", "!=", "ProblemReasons", ".", "NotFound", ")", "return", "binding", ";", "return", "new", "ProblemBinding", "(", "name", ",", "enclosingSourceType", "(", ")", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "catch", "(", "AbortCompilation", "e", ")", "{", "e", ".", "updateContext", "(", "invocationSite", ",", "referenceCompilationUnit", "(", ")", ".", "compilationResult", ")", ";", "throw", "e", ";", "}", "finally", "{", "env", ".", "missingClassFileLocation", "=", "null", ";", "}", "}", "public", "MethodBinding", "getConstructor", "(", "ReferenceBinding", "receiverType", ",", "TypeBinding", "[", "]", "argumentTypes", ",", "InvocationSite", "invocationSite", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "LookupEnvironment", "env", "=", "unitScope", ".", "environment", ";", "try", "{", "env", ".", "missingClassFileLocation", "=", "invocationSite", ";", "unitScope", ".", "recordTypeReference", "(", "receiverType", ")", ";", "unitScope", ".", "recordTypeReferences", "(", "argumentTypes", ")", ";", "MethodBinding", "methodBinding", "=", "receiverType", ".", "getExactConstructor", "(", "argumentTypes", ")", ";", "if", "(", "methodBinding", "!=", "null", "&&", "methodBinding", ".", "canBeSeenBy", "(", "invocationSite", ",", "this", ")", ")", "{", "if", "(", "invocationSite", ".", "genericTypeArguments", "(", ")", "!=", "null", ")", "methodBinding", "=", "computeCompatibleMethod", "(", "methodBinding", ",", "argumentTypes", ",", "invocationSite", ")", ";", "return", "methodBinding", ";", "}", "MethodBinding", "[", "]", "methods", "=", "receiverType", ".", "getMethods", "(", "TypeConstants", ".", "INIT", ",", "argumentTypes", ".", "length", ")", ";", "if", "(", "methods", "==", "Binding", ".", "NO_METHODS", ")", "return", "new", "ProblemMethodBinding", "(", "TypeConstants", ".", "INIT", ",", "argumentTypes", ",", "ProblemReasons", ".", "NotFound", ")", ";", "MethodBinding", "[", "]", "compatible", "=", "new", "MethodBinding", "[", "methods", ".", "length", "]", ";", "int", "compatibleIndex", "=", "0", ";", "MethodBinding", "problemMethod", "=", "null", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "methods", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "MethodBinding", "compatibleMethod", "=", "computeCompatibleMethod", "(", "methods", "[", "i", "]", ",", "argumentTypes", ",", "invocationSite", ")", ";", "if", "(", "compatibleMethod", "!=", "null", ")", "{", "if", "(", "compatibleMethod", ".", "isValidBinding", "(", ")", ")", "compatible", "[", "compatibleIndex", "++", "]", "=", "compatibleMethod", ";", "else", "if", "(", "problemMethod", "==", "null", ")", "problemMethod", "=", "compatibleMethod", ";", "}", "}", "if", "(", "compatibleIndex", "==", "0", ")", "{", "if", "(", "problemMethod", "==", "null", ")", "return", "new", "ProblemMethodBinding", "(", "methods", "[", "0", "]", ",", "TypeConstants", ".", "INIT", ",", "argumentTypes", ",", "ProblemReasons", ".", "NotFound", ")", ";", "return", "problemMethod", ";", "}", "MethodBinding", "[", "]", "visible", "=", "new", "MethodBinding", "[", "compatibleIndex", "]", ";", "int", "visibleIndex", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "compatibleIndex", ";", "i", "++", ")", "{", "MethodBinding", "method", "=", "compatible", "[", "i", "]", ";", "if", "(", "method", ".", "canBeSeenBy", "(", "invocationSite", ",", "this", ")", ")", "visible", "[", "visibleIndex", "++", "]", "=", "method", ";", "}", "if", "(", "visibleIndex", "==", "1", ")", "return", "visible", "[", "0", "]", ";", "if", "(", "visibleIndex", "==", "0", ")", "return", "new", "ProblemMethodBinding", "(", "compatible", "[", "0", "]", ",", "TypeConstants", ".", "INIT", ",", "compatible", "[", "0", "]", ".", "parameters", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "return", "mostSpecificMethodBinding", "(", "visible", ",", "visibleIndex", ",", "argumentTypes", ",", "invocationSite", ",", "receiverType", ")", ";", "}", "catch", "(", "AbortCompilation", "e", ")", "{", "e", ".", "updateContext", "(", "invocationSite", ",", "referenceCompilationUnit", "(", ")", ".", "compilationResult", ")", ";", "throw", "e", ";", "}", "finally", "{", "env", ".", "missingClassFileLocation", "=", "null", ";", "}", "}", "public", "final", "PackageBinding", "getCurrentPackage", "(", ")", "{", "Scope", "scope", ",", "unitScope", "=", "this", ";", "while", "(", "(", "scope", "=", "unitScope", ".", "parent", ")", "!=", "null", ")", "unitScope", "=", "scope", ";", "return", "(", "(", "CompilationUnitScope", ")", "unitScope", ")", ".", "fPackage", ";", "}", "public", "int", "getDeclarationModifiers", "(", ")", "{", "switch", "(", "this", ".", "kind", ")", "{", "case", "Scope", ".", "BLOCK_SCOPE", ":", "case", "Scope", ".", "METHOD_SCOPE", ":", "MethodScope", "methodScope", "=", "methodScope", "(", ")", ";", "if", "(", "!", "methodScope", ".", "isInsideInitializer", "(", ")", ")", "{", "MethodBinding", "context", "=", "(", "(", "AbstractMethodDeclaration", ")", "methodScope", ".", "referenceContext", ")", ".", "binding", ";", "if", "(", "context", "!=", "null", ")", "return", "context", ".", "modifiers", ";", "}", "else", "{", "SourceTypeBinding", "type", "=", "(", "(", "BlockScope", ")", "this", ")", ".", "referenceType", "(", ")", ".", "binding", ";", "if", "(", "methodScope", ".", "initializedField", "!=", "null", ")", "return", "methodScope", ".", "initializedField", ".", "modifiers", ";", "if", "(", "type", "!=", "null", ")", "return", "type", ".", "modifiers", ";", "}", "break", ";", "case", "Scope", ".", "CLASS_SCOPE", ":", "ReferenceBinding", "context", "=", "(", "(", "ClassScope", ")", "this", ")", ".", "referenceType", "(", ")", ".", "binding", ";", "if", "(", "context", "!=", "null", ")", "return", "context", ".", "modifiers", ";", "break", ";", "}", "return", "-", "1", ";", "}", "public", "FieldBinding", "getField", "(", "TypeBinding", "receiverType", ",", "char", "[", "]", "fieldName", ",", "InvocationSite", "invocationSite", ")", "{", "LookupEnvironment", "env", "=", "environment", "(", ")", ";", "try", "{", "env", ".", "missingClassFileLocation", "=", "invocationSite", ";", "FieldBinding", "field", "=", "findField", "(", "receiverType", ",", "fieldName", ",", "invocationSite", ",", "true", ")", ";", "if", "(", "field", "!=", "null", ")", "return", "field", ";", "return", "new", "ProblemFieldBinding", "(", "receiverType", "instanceof", "ReferenceBinding", "?", "(", "ReferenceBinding", ")", "receiverType", ":", "null", ",", "fieldName", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "catch", "(", "AbortCompilation", "e", ")", "{", "e", ".", "updateContext", "(", "invocationSite", ",", "referenceCompilationUnit", "(", ")", ".", "compilationResult", ")", ";", "throw", "e", ";", "}", "finally", "{", "env", ".", "missingClassFileLocation", "=", "null", ";", "}", "}", "public", "MethodBinding", "getImplicitMethod", "(", "char", "[", "]", "selector", ",", "TypeBinding", "[", "]", "argumentTypes", ",", "InvocationSite", "invocationSite", ")", "{", "boolean", "insideStaticContext", "=", "false", ";", "boolean", "insideConstructorCall", "=", "false", ";", "boolean", "insideTypeAnnotation", "=", "false", ";", "MethodBinding", "foundMethod", "=", "null", ";", "MethodBinding", "foundProblem", "=", "null", ";", "boolean", "foundProblemVisible", "=", "false", ";", "Scope", "scope", "=", "this", ";", "int", "depth", "=", "0", ";", "CompilerOptions", "options", ";", "boolean", "inheritedHasPrecedence", "=", "(", "options", "=", "compilerOptions", "(", ")", ")", ".", "complianceLevel", ">=", "ClassFileConstants", ".", "JDK1_4", ";", "done", ":", "while", "(", "true", ")", "{", "switch", "(", "scope", ".", "kind", ")", "{", "case", "METHOD_SCOPE", ":", "MethodScope", "methodScope", "=", "(", "MethodScope", ")", "scope", ";", "insideStaticContext", "|=", "methodScope", ".", "isStatic", ";", "insideConstructorCall", "|=", "methodScope", ".", "isConstructorCall", ";", "insideTypeAnnotation", "=", "methodScope", ".", "insideTypeAnnotation", ";", "break", ";", "case", "CLASS_SCOPE", ":", "ClassScope", "classScope", "=", "(", "ClassScope", ")", "scope", ";", "ReferenceBinding", "receiverType", "=", "classScope", ".", "enclosingReceiverType", "(", ")", ";", "if", "(", "!", "insideTypeAnnotation", ")", "{", "MethodBinding", "methodBinding", "=", "classScope", ".", "findExactMethod", "(", "receiverType", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ")", ";", "if", "(", "methodBinding", "==", "null", ")", "methodBinding", "=", "classScope", ".", "findMethod", "(", "receiverType", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ")", ";", "if", "(", "methodBinding", "!=", "null", ")", "{", "if", "(", "foundMethod", "==", "null", ")", "{", "if", "(", "methodBinding", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "!", "methodBinding", ".", "isStatic", "(", ")", "&&", "(", "insideConstructorCall", "||", "insideStaticContext", ")", ")", "{", "if", "(", "foundProblem", "!=", "null", "&&", "foundProblem", ".", "problemId", "(", ")", "!=", "ProblemReasons", ".", "NotVisible", ")", "return", "foundProblem", ";", "return", "new", "ProblemMethodBinding", "(", "methodBinding", ",", "methodBinding", ".", "selector", ",", "methodBinding", ".", "parameters", ",", "insideConstructorCall", "?", "ProblemReasons", ".", "NonStaticReferenceInConstructorInvocation", ":", "ProblemReasons", ".", "NonStaticReferenceInStaticContext", ")", ";", "}", "if", "(", "inheritedHasPrecedence", "||", "receiverType", "==", "methodBinding", ".", "declaringClass", "||", "(", "receiverType", ".", "getMethods", "(", "selector", ")", ")", "!=", "Binding", ".", "NO_METHODS", ")", "{", "if", "(", "foundProblemVisible", ")", "{", "return", "foundProblem", ";", "}", "if", "(", "depth", ">", "0", ")", "{", "invocationSite", ".", "setDepth", "(", "depth", ")", ";", "invocationSite", ".", "setActualReceiverType", "(", "receiverType", ")", ";", "}", "if", "(", "argumentTypes", "==", "Binding", ".", "NO_PARAMETERS", "&&", "CharOperation", ".", "equals", "(", "selector", ",", "TypeConstants", ".", "GETCLASS", ")", "&&", "methodBinding", ".", "returnType", ".", "isParameterizedType", "(", ")", ")", "{", "return", "environment", "(", ")", ".", "createGetClassMethod", "(", "receiverType", ",", "methodBinding", ",", "this", ")", ";", "}", "return", "methodBinding", ";", "}", "if", "(", "foundProblem", "==", "null", "||", "foundProblem", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "NotVisible", ")", "{", "if", "(", "foundProblem", "!=", "null", ")", "foundProblem", "=", "null", ";", "if", "(", "depth", ">", "0", ")", "{", "invocationSite", ".", "setDepth", "(", "depth", ")", ";", "invocationSite", ".", "setActualReceiverType", "(", "receiverType", ")", ";", "}", "foundMethod", "=", "methodBinding", ";", "}", "}", "else", "{", "if", "(", "methodBinding", ".", "problemId", "(", ")", "!=", "ProblemReasons", ".", "NotVisible", "&&", "methodBinding", ".", "problemId", "(", ")", "!=", "ProblemReasons", ".", "NotFound", ")", "return", "methodBinding", ";", "if", "(", "foundProblem", "==", "null", ")", "{", "foundProblem", "=", "methodBinding", ";", "}", "if", "(", "!", "foundProblemVisible", "&&", "methodBinding", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "NotFound", ")", "{", "MethodBinding", "closestMatch", "=", "(", "(", "ProblemMethodBinding", ")", "methodBinding", ")", ".", "closestMatch", ";", "if", "(", "closestMatch", "!=", "null", "&&", "closestMatch", ".", "canBeSeenBy", "(", "receiverType", ",", "invocationSite", ",", "this", ")", ")", "{", "foundProblem", "=", "methodBinding", ";", "foundProblemVisible", "=", "true", ";", "}", "}", "}", "}", "else", "{", "if", "(", "methodBinding", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "Ambiguous", "||", "(", "foundMethod", ".", "declaringClass", "!=", "methodBinding", ".", "declaringClass", "&&", "(", "receiverType", "==", "methodBinding", ".", "declaringClass", "||", "receiverType", ".", "getMethods", "(", "selector", ")", "!=", "Binding", ".", "NO_METHODS", ")", ")", ")", "return", "new", "ProblemMethodBinding", "(", "methodBinding", ",", "selector", ",", "argumentTypes", ",", "ProblemReasons", ".", "InheritedNameHidesEnclosingName", ")", ";", "}", "}", "}", "insideTypeAnnotation", "=", "false", ";", "depth", "++", ";", "insideStaticContext", "|=", "receiverType", ".", "isStatic", "(", ")", ";", "MethodScope", "enclosingMethodScope", "=", "scope", ".", "methodScope", "(", ")", ";", "insideConstructorCall", "=", "enclosingMethodScope", "==", "null", "?", "false", ":", "enclosingMethodScope", ".", "isConstructorCall", ";", "break", ";", "case", "COMPILATION_UNIT_SCOPE", ":", "break", "done", ";", "}", "scope", "=", "scope", ".", "parent", ";", "}", "if", "(", "insideStaticContext", "&&", "options", ".", "sourceLevel", ">=", "ClassFileConstants", ".", "JDK1_5", ")", "{", "if", "(", "foundProblem", "!=", "null", ")", "{", "if", "(", "foundProblem", ".", "declaringClass", "!=", "null", "&&", "foundProblem", ".", "declaringClass", ".", "id", "==", "TypeIds", ".", "T_JavaLangObject", ")", "return", "foundProblem", ";", "if", "(", "foundProblem", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "NotFound", "&&", "foundProblemVisible", ")", "{", "return", "foundProblem", ";", "}", "}", "CompilationUnitScope", "unitScope", "=", "(", "CompilationUnitScope", ")", "scope", ";", "unitScope", ".", "faultInImports", "(", ")", ";", "ImportBinding", "[", "]", "imports", "=", "unitScope", ".", "imports", ";", "if", "(", "imports", "!=", "null", ")", "{", "ObjectVector", "visible", "=", "null", ";", "boolean", "skipOnDemand", "=", "false", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "imports", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "ImportBinding", "importBinding", "=", "imports", "[", "i", "]", ";", "if", "(", "importBinding", ".", "isStatic", "(", ")", ")", "{", "Binding", "resolvedImport", "=", "importBinding", ".", "resolvedImport", ";", "MethodBinding", "possible", "=", "null", ";", "if", "(", "importBinding", ".", "onDemand", ")", "{", "if", "(", "!", "skipOnDemand", "&&", "resolvedImport", "instanceof", "ReferenceBinding", ")", "possible", "=", "findMethod", "(", "(", "ReferenceBinding", ")", "resolvedImport", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ",", "true", ")", ";", "}", "else", "{", "if", "(", "resolvedImport", "instanceof", "MethodBinding", ")", "{", "MethodBinding", "staticMethod", "=", "(", "MethodBinding", ")", "resolvedImport", ";", "if", "(", "CharOperation", ".", "equals", "(", "staticMethod", ".", "selector", ",", "selector", ")", ")", "possible", "=", "findMethod", "(", "staticMethod", ".", "declaringClass", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ",", "true", ")", ";", "}", "else", "if", "(", "resolvedImport", "instanceof", "FieldBinding", ")", "{", "FieldBinding", "staticField", "=", "(", "FieldBinding", ")", "resolvedImport", ";", "if", "(", "CharOperation", ".", "equals", "(", "staticField", ".", "name", ",", "selector", ")", ")", "{", "char", "[", "]", "[", "]", "importName", "=", "importBinding", ".", "reference", ".", "tokens", ";", "TypeBinding", "referencedType", "=", "getType", "(", "importName", ",", "importName", ".", "length", "-", "1", ")", ";", "if", "(", "referencedType", "!=", "null", ")", "possible", "=", "findMethod", "(", "(", "ReferenceBinding", ")", "referencedType", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ",", "true", ")", ";", "}", "}", "}", "if", "(", "possible", "!=", "null", "&&", "possible", "!=", "foundProblem", ")", "{", "if", "(", "!", "possible", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "foundProblem", "==", "null", ")", "foundProblem", "=", "possible", ";", "}", "else", "if", "(", "possible", ".", "isStatic", "(", ")", ")", "{", "MethodBinding", "compatibleMethod", "=", "computeCompatibleMethod", "(", "possible", ",", "argumentTypes", ",", "invocationSite", ")", ";", "if", "(", "compatibleMethod", "!=", "null", ")", "{", "if", "(", "compatibleMethod", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "compatibleMethod", ".", "canBeSeenBy", "(", "unitScope", ".", "fPackage", ")", ")", "{", "if", "(", "visible", "==", "null", "||", "!", "visible", ".", "contains", "(", "compatibleMethod", ")", ")", "{", "ImportReference", "importReference", "=", "importBinding", ".", "reference", ";", "if", "(", "importReference", "!=", "null", ")", "{", "importReference", ".", "bits", "|=", "ASTNode", ".", "Used", ";", "}", "if", "(", "!", "skipOnDemand", "&&", "!", "importBinding", ".", "onDemand", ")", "{", "visible", "=", "null", ";", "skipOnDemand", "=", "true", ";", "}", "if", "(", "visible", "==", "null", ")", "visible", "=", "new", "ObjectVector", "(", "3", ")", ";", "visible", ".", "add", "(", "compatibleMethod", ")", ";", "}", "}", "else", "if", "(", "foundProblem", "==", "null", ")", "{", "foundProblem", "=", "new", "ProblemMethodBinding", "(", "compatibleMethod", ",", "selector", ",", "compatibleMethod", ".", "parameters", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "}", "}", "else", "if", "(", "foundProblem", "==", "null", ")", "{", "foundProblem", "=", "compatibleMethod", ";", "}", "}", "else", "if", "(", "foundProblem", "==", "null", ")", "{", "foundProblem", "=", "new", "ProblemMethodBinding", "(", "possible", ",", "selector", ",", "argumentTypes", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "}", "}", "}", "}", "if", "(", "visible", "!=", "null", ")", "{", "MethodBinding", "[", "]", "temp", "=", "new", "MethodBinding", "[", "visible", ".", "size", "]", ";", "visible", ".", "copyInto", "(", "temp", ")", ";", "foundMethod", "=", "mostSpecificMethodBinding", "(", "temp", ",", "temp", ".", "length", ",", "argumentTypes", ",", "invocationSite", ",", "null", ")", ";", "}", "}", "}", "if", "(", "foundMethod", "!=", "null", ")", "{", "invocationSite", ".", "setActualReceiverType", "(", "foundMethod", ".", "declaringClass", ")", ";", "return", "foundMethod", ";", "}", "if", "(", "foundProblem", "!=", "null", ")", "return", "foundProblem", ";", "return", "new", "ProblemMethodBinding", "(", "selector", ",", "argumentTypes", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "public", "final", "ReferenceBinding", "getJavaIoSerializable", "(", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordQualifiedReference", "(", "TypeConstants", ".", "JAVA_IO_SERIALIZABLE", ")", ";", "return", "unitScope", ".", "environment", ".", "getResolvedType", "(", "TypeConstants", ".", "JAVA_IO_SERIALIZABLE", ",", "this", ")", ";", "}", "public", "final", "ReferenceBinding", "getJavaLangAnnotationAnnotation", "(", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordQualifiedReference", "(", "TypeConstants", ".", "JAVA_LANG_ANNOTATION_ANNOTATION", ")", ";", "return", "unitScope", ".", "environment", ".", "getResolvedType", "(", "TypeConstants", ".", "JAVA_LANG_ANNOTATION_ANNOTATION", ",", "this", ")", ";", "}", "public", "final", "ReferenceBinding", "getJavaLangAssertionError", "(", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordQualifiedReference", "(", "TypeConstants", ".", "JAVA_LANG_ASSERTIONERROR", ")", ";", "return", "unitScope", ".", "environment", ".", "getResolvedType", "(", "TypeConstants", ".", "JAVA_LANG_ASSERTIONERROR", ",", "this", ")", ";", "}", "public", "final", "ReferenceBinding", "getJavaLangClass", "(", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordQualifiedReference", "(", "TypeConstants", ".", "JAVA_LANG_CLASS", ")", ";", "return", "unitScope", ".", "environment", ".", "getResolvedType", "(", "TypeConstants", ".", "JAVA_LANG_CLASS", ",", "this", ")", ";", "}", "public", "final", "ReferenceBinding", "getJavaLangCloneable", "(", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordQualifiedReference", "(", "TypeConstants", ".", "JAVA_LANG_CLONEABLE", ")", ";", "return", "unitScope", ".", "environment", ".", "getResolvedType", "(", "TypeConstants", ".", "JAVA_LANG_CLONEABLE", ",", "this", ")", ";", "}", "public", "final", "ReferenceBinding", "getJavaLangEnum", "(", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordQualifiedReference", "(", "TypeConstants", ".", "JAVA_LANG_ENUM", ")", ";", "return", "unitScope", ".", "environment", ".", "getResolvedType", "(", "TypeConstants", ".", "JAVA_LANG_ENUM", ",", "this", ")", ";", "}", "public", "final", "ReferenceBinding", "getJavaLangIterable", "(", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordQualifiedReference", "(", "TypeConstants", ".", "JAVA_LANG_ITERABLE", ")", ";", "return", "unitScope", ".", "environment", ".", "getResolvedType", "(", "TypeConstants", ".", "JAVA_LANG_ITERABLE", ",", "this", ")", ";", "}", "public", "final", "ReferenceBinding", "getJavaLangObject", "(", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordQualifiedReference", "(", "TypeConstants", ".", "JAVA_LANG_OBJECT", ")", ";", "return", "unitScope", ".", "environment", ".", "getResolvedType", "(", "TypeConstants", ".", "JAVA_LANG_OBJECT", ",", "this", ")", ";", "}", "public", "final", "ReferenceBinding", "getJavaLangString", "(", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordQualifiedReference", "(", "TypeConstants", ".", "JAVA_LANG_STRING", ")", ";", "return", "unitScope", ".", "environment", ".", "getResolvedType", "(", "TypeConstants", ".", "JAVA_LANG_STRING", ",", "this", ")", ";", "}", "public", "final", "ReferenceBinding", "getJavaLangThrowable", "(", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordQualifiedReference", "(", "TypeConstants", ".", "JAVA_LANG_THROWABLE", ")", ";", "return", "unitScope", ".", "environment", ".", "getResolvedType", "(", "TypeConstants", ".", "JAVA_LANG_THROWABLE", ",", "this", ")", ";", "}", "public", "final", "ReferenceBinding", "getJavaUtilIterator", "(", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordQualifiedReference", "(", "TypeConstants", ".", "JAVA_UTIL_ITERATOR", ")", ";", "return", "unitScope", ".", "environment", ".", "getResolvedType", "(", "TypeConstants", ".", "JAVA_UTIL_ITERATOR", ",", "this", ")", ";", "}", "public", "final", "ReferenceBinding", "getMemberType", "(", "char", "[", "]", "typeName", ",", "ReferenceBinding", "enclosingType", ")", "{", "ReferenceBinding", "memberType", "=", "findMemberType", "(", "typeName", ",", "enclosingType", ")", ";", "if", "(", "memberType", "!=", "null", ")", "return", "memberType", ";", "char", "[", "]", "[", "]", "compoundName", "=", "new", "char", "[", "]", "[", "]", "{", "typeName", "}", ";", "return", "new", "ProblemReferenceBinding", "(", "compoundName", ",", "null", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "public", "MethodBinding", "getMethod", "(", "TypeBinding", "receiverType", ",", "char", "[", "]", "selector", ",", "TypeBinding", "[", "]", "argumentTypes", ",", "InvocationSite", "invocationSite", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "LookupEnvironment", "env", "=", "unitScope", ".", "environment", ";", "try", "{", "env", ".", "missingClassFileLocation", "=", "invocationSite", ";", "switch", "(", "receiverType", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "BASE_TYPE", ":", "return", "new", "ProblemMethodBinding", "(", "selector", ",", "argumentTypes", ",", "ProblemReasons", ".", "NotFound", ")", ";", "case", "Binding", ".", "ARRAY_TYPE", ":", "unitScope", ".", "recordTypeReference", "(", "receiverType", ")", ";", "return", "findMethodForArray", "(", "(", "ArrayBinding", ")", "receiverType", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ")", ";", "}", "unitScope", ".", "recordTypeReference", "(", "receiverType", ")", ";", "ReferenceBinding", "currentType", "=", "(", "ReferenceBinding", ")", "receiverType", ";", "if", "(", "!", "currentType", ".", "canBeSeenBy", "(", "this", ")", ")", "return", "new", "ProblemMethodBinding", "(", "selector", ",", "argumentTypes", ",", "ProblemReasons", ".", "ReceiverTypeNotVisible", ")", ";", "MethodBinding", "methodBinding", "=", "findExactMethod", "(", "currentType", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ")", ";", "if", "(", "methodBinding", "!=", "null", ")", "return", "methodBinding", ";", "methodBinding", "=", "findMethod", "(", "currentType", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ")", ";", "if", "(", "methodBinding", "==", "null", ")", "{", "methodBinding", "=", "oneLastLook", "(", "currentType", ",", "selector", ",", "argumentTypes", ",", "invocationSite", ")", ";", "}", "if", "(", "methodBinding", "==", "null", ")", "return", "new", "ProblemMethodBinding", "(", "selector", ",", "argumentTypes", ",", "ProblemReasons", ".", "NotFound", ")", ";", "if", "(", "!", "methodBinding", ".", "isValidBinding", "(", ")", ")", "return", "methodBinding", ";", "if", "(", "argumentTypes", "==", "Binding", ".", "NO_PARAMETERS", "&&", "CharOperation", ".", "equals", "(", "selector", ",", "TypeConstants", ".", "GETCLASS", ")", "&&", "methodBinding", ".", "returnType", ".", "isParameterizedType", "(", ")", ")", "{", "return", "environment", "(", ")", ".", "createGetClassMethod", "(", "receiverType", ",", "methodBinding", ",", "this", ")", ";", "}", "return", "methodBinding", ";", "}", "catch", "(", "AbortCompilation", "e", ")", "{", "e", ".", "updateContext", "(", "invocationSite", ",", "referenceCompilationUnit", "(", ")", ".", "compilationResult", ")", ";", "throw", "e", ";", "}", "finally", "{", "env", ".", "missingClassFileLocation", "=", "null", ";", "}", "}", "public", "final", "Binding", "getPackage", "(", "char", "[", "]", "[", "]", "compoundName", ")", "{", "compilationUnitScope", "(", ")", ".", "recordQualifiedReference", "(", "compoundName", ")", ";", "Binding", "binding", "=", "getTypeOrPackage", "(", "compoundName", "[", "0", "]", ",", "Binding", ".", "TYPE", "|", "Binding", ".", "PACKAGE", ",", "true", ")", ";", "if", "(", "binding", "==", "null", ")", "{", "char", "[", "]", "[", "]", "qName", "=", "new", "char", "[", "]", "[", "]", "{", "compoundName", "[", "0", "]", "}", ";", "return", "new", "ProblemReferenceBinding", "(", "qName", ",", "environment", "(", ")", ".", "createMissingType", "(", "null", ",", "compoundName", ")", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "if", "(", "!", "binding", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "binding", "instanceof", "PackageBinding", ")", "{", "char", "[", "]", "[", "]", "qName", "=", "new", "char", "[", "]", "[", "]", "{", "compoundName", "[", "0", "]", "}", ";", "return", "new", "ProblemReferenceBinding", "(", "qName", ",", "null", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "return", "binding", ";", "}", "if", "(", "!", "(", "binding", "instanceof", "PackageBinding", ")", ")", "return", "null", ";", "int", "currentIndex", "=", "1", ",", "length", "=", "compoundName", ".", "length", ";", "PackageBinding", "packageBinding", "=", "(", "PackageBinding", ")", "binding", ";", "while", "(", "currentIndex", "<", "length", ")", "{", "binding", "=", "packageBinding", ".", "getTypeOrPackage", "(", "compoundName", "[", "currentIndex", "++", "]", ")", ";", "if", "(", "binding", "==", "null", ")", "{", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "null", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "if", "(", "!", "binding", ".", "isValidBinding", "(", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "binding", "instanceof", "ReferenceBinding", "?", "(", "ReferenceBinding", ")", "(", "(", "ReferenceBinding", ")", "binding", ")", ".", "closestMatch", "(", ")", ":", "null", ",", "binding", ".", "problemId", "(", ")", ")", ";", "if", "(", "!", "(", "binding", "instanceof", "PackageBinding", ")", ")", "return", "packageBinding", ";", "packageBinding", "=", "(", "PackageBinding", ")", "binding", ";", "}", "return", "new", "ProblemReferenceBinding", "(", "compoundName", ",", "null", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "public", "final", "TypeBinding", "getType", "(", "char", "[", "]", "name", ")", "{", "TypeBinding", "binding", "=", "getBaseType", "(", "name", ")", ";", "if", "(", "binding", "!=", "null", ")", "return", "binding", ";", "return", "(", "ReferenceBinding", ")", "getTypeOrPackage", "(", "name", ",", "Binding", ".", "TYPE", ",", "true", ")", ";", "}", "public", "final", "TypeBinding", "getType", "(", "char", "[", "]", "name", ",", "PackageBinding", "packageBinding", ")", "{", "if", "(", "packageBinding", "==", "null", ")", "return", "getType", "(", "name", ")", ";", "Binding", "binding", "=", "packageBinding", ".", "getTypeOrPackage", "(", "name", ")", ";", "if", "(", "binding", "==", "null", ")", "{", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "arrayConcat", "(", "packageBinding", ".", "compoundName", ",", "name", ")", ",", "null", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "if", "(", "!", "binding", ".", "isValidBinding", "(", ")", ")", "{", "return", "new", "ProblemReferenceBinding", "(", "binding", "instanceof", "ReferenceBinding", "?", "(", "(", "ReferenceBinding", ")", "binding", ")", ".", "compoundName", ":", "CharOperation", ".", "arrayConcat", "(", "packageBinding", ".", "compoundName", ",", "name", ")", ",", "binding", "instanceof", "ReferenceBinding", "?", "(", "ReferenceBinding", ")", "(", "(", "ReferenceBinding", ")", "binding", ")", ".", "closestMatch", "(", ")", ":", "null", ",", "binding", ".", "problemId", "(", ")", ")", ";", "}", "ReferenceBinding", "typeBinding", "=", "(", "ReferenceBinding", ")", "binding", ";", "if", "(", "!", "typeBinding", ".", "canBeSeenBy", "(", "this", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "typeBinding", ".", "compoundName", ",", "typeBinding", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "return", "typeBinding", ";", "}", "public", "final", "TypeBinding", "getType", "(", "char", "[", "]", "[", "]", "compoundName", ",", "int", "typeNameLength", ")", "{", "if", "(", "typeNameLength", "==", "1", ")", "{", "TypeBinding", "binding", "=", "getBaseType", "(", "compoundName", "[", "0", "]", ")", ";", "if", "(", "binding", "!=", "null", ")", "return", "binding", ";", "}", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordQualifiedReference", "(", "compoundName", ")", ";", "Binding", "binding", "=", "getTypeOrPackage", "(", "compoundName", "[", "0", "]", ",", "typeNameLength", "==", "1", "?", "Binding", ".", "TYPE", ":", "Binding", ".", "TYPE", "|", "Binding", ".", "PACKAGE", ",", "true", ")", ";", "if", "(", "binding", "==", "null", ")", "{", "char", "[", "]", "[", "]", "qName", "=", "new", "char", "[", "]", "[", "]", "{", "compoundName", "[", "0", "]", "}", ";", "return", "new", "ProblemReferenceBinding", "(", "qName", ",", "environment", "(", ")", ".", "createMissingType", "(", "compilationUnitScope", "(", ")", ".", "getCurrentPackage", "(", ")", ",", "qName", ")", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "if", "(", "!", "binding", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "binding", "instanceof", "PackageBinding", ")", "{", "char", "[", "]", "[", "]", "qName", "=", "new", "char", "[", "]", "[", "]", "{", "compoundName", "[", "0", "]", "}", ";", "return", "new", "ProblemReferenceBinding", "(", "qName", ",", "environment", "(", ")", ".", "createMissingType", "(", "null", ",", "qName", ")", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "return", "(", "ReferenceBinding", ")", "binding", ";", "}", "int", "currentIndex", "=", "1", ";", "boolean", "checkVisibility", "=", "false", ";", "if", "(", "binding", "instanceof", "PackageBinding", ")", "{", "PackageBinding", "packageBinding", "=", "(", "PackageBinding", ")", "binding", ";", "while", "(", "currentIndex", "<", "typeNameLength", ")", "{", "binding", "=", "packageBinding", ".", "getTypeOrPackage", "(", "compoundName", "[", "currentIndex", "++", "]", ")", ";", "if", "(", "binding", "==", "null", ")", "{", "char", "[", "]", "[", "]", "qName", "=", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ";", "return", "new", "ProblemReferenceBinding", "(", "qName", ",", "environment", "(", ")", ".", "createMissingType", "(", "packageBinding", ",", "qName", ")", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "if", "(", "!", "binding", ".", "isValidBinding", "(", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "binding", "instanceof", "ReferenceBinding", "?", "(", "ReferenceBinding", ")", "(", "(", "ReferenceBinding", ")", "binding", ")", ".", "closestMatch", "(", ")", ":", "null", ",", "binding", ".", "problemId", "(", ")", ")", ";", "if", "(", "!", "(", "binding", "instanceof", "PackageBinding", ")", ")", "break", ";", "packageBinding", "=", "(", "PackageBinding", ")", "binding", ";", "}", "if", "(", "binding", "instanceof", "PackageBinding", ")", "{", "char", "[", "]", "[", "]", "qName", "=", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ";", "return", "new", "ProblemReferenceBinding", "(", "qName", ",", "environment", "(", ")", ".", "createMissingType", "(", "null", ",", "qName", ")", ",", "ProblemReasons", ".", "NotFound", ")", ";", "}", "checkVisibility", "=", "true", ";", "}", "ReferenceBinding", "typeBinding", "=", "(", "ReferenceBinding", ")", "binding", ";", "unitScope", ".", "recordTypeReference", "(", "typeBinding", ")", ";", "if", "(", "checkVisibility", ")", "if", "(", "!", "typeBinding", ".", "canBeSeenBy", "(", "this", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "typeBinding", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "while", "(", "currentIndex", "<", "typeNameLength", ")", "{", "typeBinding", "=", "getMemberType", "(", "compoundName", "[", "currentIndex", "++", "]", ",", "typeBinding", ")", ";", "if", "(", "!", "typeBinding", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "typeBinding", "instanceof", "ProblemReferenceBinding", ")", "{", "ProblemReferenceBinding", "problemBinding", "=", "(", "ProblemReferenceBinding", ")", "typeBinding", ";", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "problemBinding", ".", "closestReferenceMatch", "(", ")", ",", "typeBinding", ".", "problemId", "(", ")", ")", ";", "}", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "(", "ReferenceBinding", ")", "(", "(", "ReferenceBinding", ")", "binding", ")", ".", "closestMatch", "(", ")", ",", "typeBinding", ".", "problemId", "(", ")", ")", ";", "}", "}", "return", "typeBinding", ";", "}", "final", "Binding", "getTypeOrPackage", "(", "char", "[", "]", "name", ",", "int", "mask", ",", "boolean", "needResolve", ")", "{", "Scope", "scope", "=", "this", ";", "ReferenceBinding", "foundType", "=", "null", ";", "boolean", "insideStaticContext", "=", "false", ";", "boolean", "insideTypeAnnotation", "=", "false", ";", "if", "(", "(", "mask", "&", "Binding", ".", "TYPE", ")", "==", "0", ")", "{", "Scope", "next", "=", "scope", ";", "while", "(", "(", "next", "=", "scope", ".", "parent", ")", "!=", "null", ")", "scope", "=", "next", ";", "}", "else", "{", "boolean", "inheritedHasPrecedence", "=", "compilerOptions", "(", ")", ".", "complianceLevel", ">=", "ClassFileConstants", ".", "JDK1_4", ";", "done", ":", "while", "(", "true", ")", "{", "switch", "(", "scope", ".", "kind", ")", "{", "case", "METHOD_SCOPE", ":", "MethodScope", "methodScope", "=", "(", "MethodScope", ")", "scope", ";", "AbstractMethodDeclaration", "methodDecl", "=", "methodScope", ".", "referenceMethod", "(", ")", ";", "if", "(", "methodDecl", "!=", "null", ")", "{", "if", "(", "methodDecl", ".", "binding", "!=", "null", ")", "{", "TypeVariableBinding", "typeVariable", "=", "methodDecl", ".", "binding", ".", "getTypeVariable", "(", "name", ")", ";", "if", "(", "typeVariable", "!=", "null", ")", "return", "typeVariable", ";", "}", "else", "{", "TypeParameter", "[", "]", "params", "=", "methodDecl", ".", "typeParameters", "(", ")", ";", "for", "(", "int", "i", "=", "params", "==", "null", "?", "0", ":", "params", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "CharOperation", ".", "equals", "(", "params", "[", "i", "]", ".", "name", ",", "name", ")", ")", "if", "(", "params", "[", "i", "]", ".", "binding", "!=", "null", "&&", "params", "[", "i", "]", ".", "binding", ".", "isValidBinding", "(", ")", ")", "return", "params", "[", "i", "]", ".", "binding", ";", "}", "}", "insideStaticContext", "|=", "methodScope", ".", "isStatic", ";", "insideTypeAnnotation", "=", "methodScope", ".", "insideTypeAnnotation", ";", "case", "BLOCK_SCOPE", ":", "ReferenceBinding", "localType", "=", "(", "(", "BlockScope", ")", "scope", ")", ".", "findLocalType", "(", "name", ")", ";", "if", "(", "localType", "!=", "null", ")", "{", "if", "(", "foundType", "!=", "null", "&&", "foundType", "!=", "localType", ")", "return", "new", "ProblemReferenceBinding", "(", "new", "char", "[", "]", "[", "]", "{", "name", "}", ",", "foundType", ",", "ProblemReasons", ".", "InheritedNameHidesEnclosingName", ")", ";", "return", "localType", ";", "}", "break", ";", "case", "CLASS_SCOPE", ":", "SourceTypeBinding", "sourceType", "=", "(", "(", "ClassScope", ")", "scope", ")", ".", "referenceContext", ".", "binding", ";", "if", "(", "scope", "==", "this", "&&", "(", "sourceType", ".", "tagBits", "&", "TagBits", ".", "TypeVariablesAreConnected", ")", "==", "0", ")", "{", "TypeVariableBinding", "typeVariable", "=", "sourceType", ".", "getTypeVariable", "(", "name", ")", ";", "if", "(", "typeVariable", "!=", "null", ")", "return", "typeVariable", ";", "if", "(", "CharOperation", ".", "equals", "(", "name", ",", "sourceType", ".", "sourceName", ")", ")", "return", "sourceType", ";", "insideStaticContext", "|=", "sourceType", ".", "isStatic", "(", ")", ";", "break", ";", "}", "if", "(", "!", "insideTypeAnnotation", ")", "{", "ReferenceBinding", "memberType", "=", "findMemberType", "(", "name", ",", "sourceType", ")", ";", "if", "(", "memberType", "!=", "null", ")", "{", "if", "(", "memberType", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "Ambiguous", ")", "{", "if", "(", "foundType", "==", "null", "||", "foundType", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "NotVisible", ")", "return", "memberType", ";", "return", "new", "ProblemReferenceBinding", "(", "new", "char", "[", "]", "[", "]", "{", "name", "}", ",", "foundType", ",", "ProblemReasons", ".", "InheritedNameHidesEnclosingName", ")", ";", "}", "if", "(", "memberType", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "sourceType", "==", "memberType", ".", "enclosingType", "(", ")", "||", "inheritedHasPrecedence", ")", "{", "if", "(", "insideStaticContext", "&&", "!", "memberType", ".", "isStatic", "(", ")", "&&", "sourceType", ".", "isGenericType", "(", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "new", "char", "[", "]", "[", "]", "{", "name", "}", ",", "memberType", ",", "ProblemReasons", ".", "NonStaticReferenceInStaticContext", ")", ";", "if", "(", "foundType", "==", "null", "||", "(", "inheritedHasPrecedence", "&&", "foundType", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "NotVisible", ")", ")", "return", "memberType", ";", "if", "(", "foundType", ".", "isValidBinding", "(", ")", "&&", "foundType", "!=", "memberType", ")", "return", "new", "ProblemReferenceBinding", "(", "new", "char", "[", "]", "[", "]", "{", "name", "}", ",", "foundType", ",", "ProblemReasons", ".", "InheritedNameHidesEnclosingName", ")", ";", "}", "}", "if", "(", "foundType", "==", "null", "||", "(", "foundType", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "NotVisible", "&&", "memberType", ".", "problemId", "(", ")", "!=", "ProblemReasons", ".", "NotVisible", ")", ")", "foundType", "=", "memberType", ";", "}", "}", "TypeVariableBinding", "typeVariable", "=", "sourceType", ".", "getTypeVariable", "(", "name", ")", ";", "if", "(", "typeVariable", "!=", "null", ")", "{", "if", "(", "insideStaticContext", ")", "return", "new", "ProblemReferenceBinding", "(", "new", "char", "[", "]", "[", "]", "{", "name", "}", ",", "typeVariable", ",", "ProblemReasons", ".", "NonStaticReferenceInStaticContext", ")", ";", "return", "typeVariable", ";", "}", "insideStaticContext", "|=", "sourceType", ".", "isStatic", "(", ")", ";", "insideTypeAnnotation", "=", "false", ";", "if", "(", "CharOperation", ".", "equals", "(", "sourceType", ".", "sourceName", ",", "name", ")", ")", "{", "if", "(", "foundType", "!=", "null", "&&", "foundType", "!=", "sourceType", "&&", "foundType", ".", "problemId", "(", ")", "!=", "ProblemReasons", ".", "NotVisible", ")", "return", "new", "ProblemReferenceBinding", "(", "new", "char", "[", "]", "[", "]", "{", "name", "}", ",", "foundType", ",", "ProblemReasons", ".", "InheritedNameHidesEnclosingName", ")", ";", "return", "sourceType", ";", "}", "break", ";", "case", "COMPILATION_UNIT_SCOPE", ":", "break", "done", ";", "}", "scope", "=", "scope", ".", "parent", ";", "}", "if", "(", "foundType", "!=", "null", "&&", "foundType", ".", "problemId", "(", ")", "!=", "ProblemReasons", ".", "NotVisible", ")", "return", "foundType", ";", "}", "CompilationUnitScope", "unitScope", "=", "(", "CompilationUnitScope", ")", "scope", ";", "HashtableOfObject", "typeOrPackageCache", "=", "unitScope", ".", "typeOrPackageCache", ";", "if", "(", "typeOrPackageCache", "!=", "null", ")", "{", "Binding", "cachedBinding", "=", "(", "Binding", ")", "typeOrPackageCache", ".", "get", "(", "name", ")", ";", "if", "(", "cachedBinding", "!=", "null", ")", "{", "if", "(", "cachedBinding", "instanceof", "ImportBinding", ")", "{", "ImportReference", "importReference", "=", "(", "(", "ImportBinding", ")", "cachedBinding", ")", ".", "reference", ";", "if", "(", "importReference", "!=", "null", ")", "{", "importReference", ".", "bits", "|=", "ASTNode", ".", "Used", ";", "}", "if", "(", "cachedBinding", "instanceof", "ImportConflictBinding", ")", "typeOrPackageCache", ".", "put", "(", "name", ",", "cachedBinding", "=", "(", "(", "ImportConflictBinding", ")", "cachedBinding", ")", ".", "conflictingTypeBinding", ")", ";", "else", "typeOrPackageCache", ".", "put", "(", "name", ",", "cachedBinding", "=", "(", "(", "ImportBinding", ")", "cachedBinding", ")", ".", "resolvedImport", ")", ";", "}", "if", "(", "(", "mask", "&", "Binding", ".", "TYPE", ")", "!=", "0", ")", "{", "if", "(", "foundType", "!=", "null", "&&", "foundType", ".", "problemId", "(", ")", "!=", "ProblemReasons", ".", "NotVisible", "&&", "cachedBinding", ".", "problemId", "(", ")", "!=", "ProblemReasons", ".", "Ambiguous", ")", "return", "foundType", ";", "if", "(", "cachedBinding", "instanceof", "ReferenceBinding", ")", "return", "cachedBinding", ";", "}", "if", "(", "(", "mask", "&", "Binding", ".", "PACKAGE", ")", "!=", "0", "&&", "cachedBinding", "instanceof", "PackageBinding", ")", "return", "cachedBinding", ";", "}", "}", "if", "(", "(", "mask", "&", "Binding", ".", "TYPE", ")", "!=", "0", ")", "{", "ImportBinding", "[", "]", "imports", "=", "unitScope", ".", "imports", ";", "if", "(", "imports", "!=", "null", "&&", "typeOrPackageCache", "==", "null", ")", "{", "nextImport", ":", "for", "(", "int", "i", "=", "0", ",", "length", "=", "imports", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "ImportBinding", "importBinding", "=", "imports", "[", "i", "]", ";", "if", "(", "!", "importBinding", ".", "onDemand", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "getSimpleName", "(", "importBinding", ")", ",", "name", ")", ")", "{", "Binding", "resolvedImport", "=", "unitScope", ".", "resolveSingleImport", "(", "importBinding", ",", "Binding", ".", "TYPE", ")", ";", "if", "(", "resolvedImport", "==", "null", ")", "continue", "nextImport", ";", "if", "(", "resolvedImport", "instanceof", "TypeBinding", ")", "{", "ImportReference", "importReference", "=", "importBinding", ".", "reference", ";", "if", "(", "importReference", "!=", "null", ")", "importReference", ".", "bits", "|=", "ASTNode", ".", "Used", ";", "return", "resolvedImport", ";", "}", "}", "}", "}", "}", "PackageBinding", "currentPackage", "=", "unitScope", ".", "fPackage", ";", "unitScope", ".", "recordReference", "(", "currentPackage", ".", "compoundName", ",", "name", ")", ";", "Binding", "binding", "=", "currentPackage", ".", "getTypeOrPackage", "(", "name", ")", ";", "if", "(", "binding", "instanceof", "ReferenceBinding", ")", "{", "ReferenceBinding", "referenceType", "=", "(", "ReferenceBinding", ")", "binding", ";", "if", "(", "(", "referenceType", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "==", "0", ")", "{", "if", "(", "typeOrPackageCache", "!=", "null", ")", "typeOrPackageCache", ".", "put", "(", "name", ",", "referenceType", ")", ";", "return", "referenceType", ";", "}", "}", "if", "(", "imports", "!=", "null", ")", "{", "boolean", "foundInImport", "=", "false", ";", "ReferenceBinding", "type", "=", "null", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "imports", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "ImportBinding", "someImport", "=", "imports", "[", "i", "]", ";", "if", "(", "someImport", ".", "onDemand", ")", "{", "Binding", "resolvedImport", "=", "someImport", ".", "resolvedImport", ";", "ReferenceBinding", "temp", "=", "null", ";", "if", "(", "resolvedImport", "instanceof", "PackageBinding", ")", "{", "temp", "=", "findType", "(", "name", ",", "(", "PackageBinding", ")", "resolvedImport", ",", "currentPackage", ")", ";", "}", "else", "if", "(", "someImport", ".", "isStatic", "(", ")", ")", "{", "temp", "=", "findMemberType", "(", "name", ",", "(", "ReferenceBinding", ")", "resolvedImport", ")", ";", "if", "(", "temp", "!=", "null", "&&", "!", "temp", ".", "isStatic", "(", ")", ")", "temp", "=", "null", ";", "}", "else", "{", "temp", "=", "findDirectMemberType", "(", "name", ",", "(", "ReferenceBinding", ")", "resolvedImport", ")", ";", "}", "if", "(", "temp", "!=", "type", "&&", "temp", "!=", "null", ")", "{", "if", "(", "temp", ".", "isValidBinding", "(", ")", ")", "{", "boolean", "conflict", "=", "true", ";", "if", "(", "this", ".", "parent", "!=", "null", "&&", "foundInImport", ")", "{", "CompilationUnitScope", "cuScope", "=", "compilationUnitScope", "(", ")", ";", "if", "(", "cuScope", "!=", "null", ")", "{", "ReferenceBinding", "chosenBinding", "=", "cuScope", ".", "selectBinding", "(", "temp", ",", "type", ",", "someImport", ".", "reference", "!=", "null", ")", ";", "if", "(", "chosenBinding", "!=", "null", ")", "{", "conflict", "=", "false", ";", "foundInImport", "=", "true", ";", "type", "=", "chosenBinding", ";", "}", "}", "}", "if", "(", "conflict", ")", "{", "ImportReference", "importReference", "=", "someImport", ".", "reference", ";", "if", "(", "importReference", "!=", "null", ")", "{", "importReference", ".", "bits", "|=", "ASTNode", ".", "Used", ";", "}", "if", "(", "foundInImport", ")", "{", "temp", "=", "new", "ProblemReferenceBinding", "(", "new", "char", "[", "]", "[", "]", "{", "name", "}", ",", "type", ",", "ProblemReasons", ".", "Ambiguous", ")", ";", "if", "(", "typeOrPackageCache", "!=", "null", ")", "typeOrPackageCache", ".", "put", "(", "name", ",", "temp", ")", ";", "return", "temp", ";", "}", "type", "=", "temp", ";", "foundInImport", "=", "true", ";", "}", "}", "else", "if", "(", "foundType", "==", "null", ")", "{", "foundType", "=", "temp", ";", "}", "}", "}", "}", "if", "(", "type", "!=", "null", ")", "{", "if", "(", "typeOrPackageCache", "!=", "null", ")", "typeOrPackageCache", ".", "put", "(", "name", ",", "type", ")", ";", "return", "type", ";", "}", "}", "}", "unitScope", ".", "recordSimpleReference", "(", "name", ")", ";", "if", "(", "(", "mask", "&", "Binding", ".", "PACKAGE", ")", "!=", "0", ")", "{", "PackageBinding", "packageBinding", "=", "unitScope", ".", "environment", ".", "getTopLevelPackage", "(", "name", ")", ";", "if", "(", "packageBinding", "!=", "null", ")", "{", "if", "(", "typeOrPackageCache", "!=", "null", ")", "typeOrPackageCache", ".", "put", "(", "name", ",", "packageBinding", ")", ";", "return", "packageBinding", ";", "}", "}", "if", "(", "foundType", "==", "null", ")", "{", "char", "[", "]", "[", "]", "qName", "=", "new", "char", "[", "]", "[", "]", "{", "name", "}", ";", "ReferenceBinding", "closestMatch", "=", "null", ";", "if", "(", "(", "mask", "&", "Binding", ".", "PACKAGE", ")", "!=", "0", ")", "{", "if", "(", "needResolve", ")", "{", "closestMatch", "=", "environment", "(", ")", ".", "createMissingType", "(", "unitScope", ".", "fPackage", ",", "qName", ")", ";", "}", "}", "else", "{", "PackageBinding", "packageBinding", "=", "unitScope", ".", "environment", ".", "getTopLevelPackage", "(", "name", ")", ";", "if", "(", "packageBinding", "==", "null", "||", "!", "packageBinding", ".", "isValidBinding", "(", ")", ")", "{", "if", "(", "needResolve", ")", "{", "closestMatch", "=", "environment", "(", ")", ".", "createMissingType", "(", "unitScope", ".", "fPackage", ",", "qName", ")", ";", "}", "}", "}", "foundType", "=", "new", "ProblemReferenceBinding", "(", "qName", ",", "closestMatch", ",", "ProblemReasons", ".", "NotFound", ")", ";", "if", "(", "typeOrPackageCache", "!=", "null", "&&", "(", "mask", "&", "Binding", ".", "PACKAGE", ")", "!=", "0", ")", "{", "typeOrPackageCache", ".", "put", "(", "name", ",", "foundType", ")", ";", "}", "}", "else", "if", "(", "(", "foundType", ".", "tagBits", "&", "TagBits", ".", "HasMissingType", ")", "!=", "0", ")", "{", "char", "[", "]", "[", "]", "qName", "=", "new", "char", "[", "]", "[", "]", "{", "name", "}", ";", "foundType", "=", "new", "ProblemReferenceBinding", "(", "qName", ",", "foundType", ",", "ProblemReasons", ".", "NotFound", ")", ";", "if", "(", "typeOrPackageCache", "!=", "null", "&&", "(", "mask", "&", "Binding", ".", "PACKAGE", ")", "!=", "0", ")", "typeOrPackageCache", ".", "put", "(", "name", ",", "foundType", ")", ";", "}", "return", "foundType", ";", "}", "public", "final", "Binding", "getTypeOrPackage", "(", "char", "[", "]", "[", "]", "compoundName", ")", "{", "int", "nameLength", "=", "compoundName", ".", "length", ";", "if", "(", "nameLength", "==", "1", ")", "{", "TypeBinding", "binding", "=", "getBaseType", "(", "compoundName", "[", "0", "]", ")", ";", "if", "(", "binding", "!=", "null", ")", "return", "binding", ";", "}", "Binding", "binding", "=", "getTypeOrPackage", "(", "compoundName", "[", "0", "]", ",", "Binding", ".", "TYPE", "|", "Binding", ".", "PACKAGE", ",", "true", ")", ";", "if", "(", "!", "binding", ".", "isValidBinding", "(", ")", ")", "return", "binding", ";", "int", "currentIndex", "=", "1", ";", "boolean", "checkVisibility", "=", "false", ";", "if", "(", "binding", "instanceof", "PackageBinding", ")", "{", "PackageBinding", "packageBinding", "=", "(", "PackageBinding", ")", "binding", ";", "while", "(", "currentIndex", "<", "nameLength", ")", "{", "binding", "=", "packageBinding", ".", "getTypeOrPackage", "(", "compoundName", "[", "currentIndex", "++", "]", ")", ";", "if", "(", "binding", "==", "null", ")", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "null", ",", "ProblemReasons", ".", "NotFound", ")", ";", "if", "(", "!", "binding", ".", "isValidBinding", "(", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "binding", "instanceof", "ReferenceBinding", "?", "(", "ReferenceBinding", ")", "(", "(", "ReferenceBinding", ")", "binding", ")", ".", "closestMatch", "(", ")", ":", "null", ",", "binding", ".", "problemId", "(", ")", ")", ";", "if", "(", "!", "(", "binding", "instanceof", "PackageBinding", ")", ")", "break", ";", "packageBinding", "=", "(", "PackageBinding", ")", "binding", ";", "}", "if", "(", "binding", "instanceof", "PackageBinding", ")", "return", "binding", ";", "checkVisibility", "=", "true", ";", "}", "ReferenceBinding", "typeBinding", "=", "(", "ReferenceBinding", ")", "binding", ";", "ReferenceBinding", "qualifiedType", "=", "(", "ReferenceBinding", ")", "environment", "(", ")", ".", "convertToRawType", "(", "typeBinding", ",", "false", ")", ";", "if", "(", "checkVisibility", ")", "if", "(", "!", "typeBinding", ".", "canBeSeenBy", "(", "this", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "typeBinding", ",", "ProblemReasons", ".", "NotVisible", ")", ";", "while", "(", "currentIndex", "<", "nameLength", ")", "{", "typeBinding", "=", "getMemberType", "(", "compoundName", "[", "currentIndex", "++", "]", ",", "typeBinding", ")", ";", "if", "(", "!", "typeBinding", ".", "isValidBinding", "(", ")", ")", "return", "new", "ProblemReferenceBinding", "(", "CharOperation", ".", "subarray", "(", "compoundName", ",", "0", ",", "currentIndex", ")", ",", "(", "ReferenceBinding", ")", "typeBinding", ".", "closestMatch", "(", ")", ",", "typeBinding", ".", "problemId", "(", ")", ")", ";", "if", "(", "typeBinding", ".", "isGenericType", "(", ")", ")", "{", "qualifiedType", "=", "environment", "(", ")", ".", "createRawType", "(", "typeBinding", ",", "qualifiedType", ")", ";", "}", "else", "{", "qualifiedType", "=", "(", "qualifiedType", "!=", "null", "&&", "(", "qualifiedType", ".", "isRawType", "(", ")", "||", "qualifiedType", ".", "isParameterizedType", "(", ")", ")", ")", "?", "environment", "(", ")", ".", "createParameterizedType", "(", "typeBinding", ",", "null", ",", "qualifiedType", ")", ":", "typeBinding", ";", "}", "}", "return", "qualifiedType", ";", "}", "protected", "boolean", "hasErasedCandidatesCollisions", "(", "TypeBinding", "one", ",", "TypeBinding", "two", ",", "Map", "invocations", ",", "ReferenceBinding", "type", ",", "ASTNode", "typeRef", ")", "{", "invocations", ".", "clear", "(", ")", ";", "TypeBinding", "[", "]", "mecs", "=", "minimalErasedCandidates", "(", "new", "TypeBinding", "[", "]", "{", "one", ",", "two", "}", ",", "invocations", ")", ";", "if", "(", "mecs", "!=", "null", ")", "{", "nextCandidate", ":", "for", "(", "int", "k", "=", "0", ",", "max", "=", "mecs", ".", "length", ";", "k", "<", "max", ";", "k", "++", ")", "{", "TypeBinding", "mec", "=", "mecs", "[", "k", "]", ";", "if", "(", "mec", "==", "null", ")", "continue", "nextCandidate", ";", "Object", "value", "=", "invocations", ".", "get", "(", "mec", ")", ";", "if", "(", "value", "instanceof", "TypeBinding", "[", "]", ")", "{", "TypeBinding", "[", "]", "invalidInvocations", "=", "(", "TypeBinding", "[", "]", ")", "value", ";", "problemReporter", "(", ")", ".", "superinterfacesCollide", "(", "invalidInvocations", "[", "0", "]", ".", "erasure", "(", ")", ",", "typeRef", ",", "invalidInvocations", "[", "0", "]", ",", "invalidInvocations", "[", "1", "]", ")", ";", "type", ".", "tagBits", "|=", "TagBits", ".", "HierarchyHasProblems", ";", "return", "true", ";", "}", "}", "}", "return", "false", ";", "}", "protected", "char", "[", "]", "getSimpleName", "(", "ImportBinding", "importBinding", ")", "{", "if", "(", "importBinding", ".", "reference", "==", "null", ")", "{", "return", "importBinding", ".", "compoundName", "[", "importBinding", ".", "compoundName", ".", "length", "-", "1", "]", ";", "}", "else", "{", "return", "importBinding", ".", "reference", ".", "getSimpleName", "(", ")", ";", "}", "}", "public", "CaseStatement", "innermostSwitchCase", "(", ")", "{", "Scope", "scope", "=", "this", ";", "do", "{", "if", "(", "scope", "instanceof", "BlockScope", ")", "return", "(", "(", "BlockScope", ")", "scope", ")", ".", "enclosingCase", ";", "scope", "=", "scope", ".", "parent", ";", "}", "while", "(", "scope", "!=", "null", ")", ";", "return", "null", ";", "}", "protected", "boolean", "isAcceptableMethod", "(", "MethodBinding", "one", ",", "MethodBinding", "two", ")", "{", "TypeBinding", "[", "]", "oneParams", "=", "one", ".", "parameters", ";", "TypeBinding", "[", "]", "twoParams", "=", "two", ".", "parameters", ";", "int", "oneParamsLength", "=", "oneParams", ".", "length", ";", "int", "twoParamsLength", "=", "twoParams", ".", "length", ";", "if", "(", "oneParamsLength", "==", "twoParamsLength", ")", "{", "next", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "oneParamsLength", ";", "i", "++", ")", "{", "TypeBinding", "oneParam", "=", "oneParams", "[", "i", "]", ";", "TypeBinding", "twoParam", "=", "twoParams", "[", "i", "]", ";", "if", "(", "oneParam", "==", "twoParam", "||", "oneParam", ".", "isCompatibleWith", "(", "twoParam", ")", ")", "{", "if", "(", "two", ".", "declaringClass", ".", "isRawType", "(", ")", ")", "continue", "next", ";", "TypeBinding", "originalTwoParam", "=", "two", ".", "original", "(", ")", ".", "parameters", "[", "i", "]", ".", "leafComponentType", "(", ")", ";", "switch", "(", "originalTwoParam", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "TYPE_PARAMETER", ":", "if", "(", "(", "(", "TypeVariableBinding", ")", "originalTwoParam", ")", ".", "hasOnlyRawBounds", "(", ")", ")", "continue", "next", ";", "case", "Binding", ".", "WILDCARD_TYPE", ":", "case", "Binding", ".", "INTERSECTION_TYPE", ":", "case", "Binding", ".", "PARAMETERIZED_TYPE", ":", "TypeBinding", "originalOneParam", "=", "one", ".", "original", "(", ")", ".", "parameters", "[", "i", "]", ".", "leafComponentType", "(", ")", ";", "switch", "(", "originalOneParam", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "TYPE", ":", "case", "Binding", ".", "GENERIC_TYPE", ":", "TypeBinding", "inheritedTwoParam", "=", "oneParam", ".", "findSuperTypeOriginatingFrom", "(", "twoParam", ")", ";", "if", "(", "inheritedTwoParam", "==", "null", "||", "!", "inheritedTwoParam", ".", "leafComponentType", "(", ")", ".", "isRawType", "(", ")", ")", "break", ";", "return", "false", ";", "case", "Binding", ".", "TYPE_PARAMETER", ":", "if", "(", "!", "(", "(", "TypeVariableBinding", ")", "originalOneParam", ")", ".", "upperBound", "(", ")", ".", "isRawType", "(", ")", ")", "break", ";", "return", "false", ";", "case", "Binding", ".", "RAW_TYPE", ":", "return", "false", ";", "}", "}", "}", "else", "{", "if", "(", "i", "==", "oneParamsLength", "-", "1", "&&", "one", ".", "isVarargs", "(", ")", "&&", "two", ".", "isVarargs", "(", ")", ")", "{", "TypeBinding", "eType", "=", "(", "(", "ArrayBinding", ")", "twoParam", ")", ".", "elementsType", "(", ")", ";", "if", "(", "oneParam", "==", "eType", "||", "oneParam", ".", "isCompatibleWith", "(", "eType", ")", ")", "return", "true", ";", "}", "return", "false", ";", "}", "}", "return", "true", ";", "}", "if", "(", "one", ".", "isVarargs", "(", ")", "&&", "two", ".", "isVarargs", "(", ")", ")", "{", "if", "(", "oneParamsLength", ">", "twoParamsLength", ")", "{", "if", "(", "(", "(", "ArrayBinding", ")", "twoParams", "[", "twoParamsLength", "-", "1", "]", ")", ".", "elementsType", "(", ")", ".", "id", "!=", "TypeIds", ".", "T_JavaLangObject", ")", "return", "false", ";", "}", "for", "(", "int", "i", "=", "(", "oneParamsLength", ">", "twoParamsLength", "?", "twoParamsLength", ":", "oneParamsLength", ")", "-", "2", ";", "i", ">=", "0", ";", "i", "--", ")", "if", "(", "oneParams", "[", "i", "]", "!=", "twoParams", "[", "i", "]", "&&", "!", "oneParams", "[", "i", "]", ".", "isCompatibleWith", "(", "twoParams", "[", "i", "]", ")", ")", "return", "false", ";", "if", "(", "parameterCompatibilityLevel", "(", "one", ",", "twoParams", ")", "==", "NOT_COMPATIBLE", "&&", "parameterCompatibilityLevel", "(", "two", ",", "oneParams", ")", "==", "VARARGS_COMPATIBLE", ")", "return", "true", ";", "}", "return", "false", ";", "}", "public", "boolean", "isBoxingCompatibleWith", "(", "TypeBinding", "expressionType", ",", "TypeBinding", "targetType", ")", "{", "LookupEnvironment", "environment", "=", "environment", "(", ")", ";", "if", "(", "environment", ".", "globalOptions", ".", "sourceLevel", "<", "ClassFileConstants", ".", "JDK1_5", "||", "expressionType", ".", "isBaseType", "(", ")", "==", "targetType", ".", "isBaseType", "(", ")", ")", "return", "false", ";", "TypeBinding", "convertedType", "=", "environment", ".", "computeBoxingType", "(", "expressionType", ")", ";", "return", "convertedType", "==", "targetType", "||", "convertedType", ".", "isCompatibleWith", "(", "targetType", ")", ";", "}", "public", "final", "boolean", "isDefinedInField", "(", "FieldBinding", "field", ")", "{", "Scope", "scope", "=", "this", ";", "do", "{", "if", "(", "scope", "instanceof", "MethodScope", ")", "{", "MethodScope", "methodScope", "=", "(", "MethodScope", ")", "scope", ";", "if", "(", "methodScope", ".", "initializedField", "==", "field", ")", "return", "true", ";", "}", "scope", "=", "scope", ".", "parent", ";", "}", "while", "(", "scope", "!=", "null", ")", ";", "return", "false", ";", "}", "public", "final", "boolean", "isDefinedInMethod", "(", "MethodBinding", "method", ")", "{", "Scope", "scope", "=", "this", ";", "do", "{", "if", "(", "scope", "instanceof", "MethodScope", ")", "{", "ReferenceContext", "refContext", "=", "(", "(", "MethodScope", ")", "scope", ")", ".", "referenceContext", ";", "if", "(", "refContext", "instanceof", "AbstractMethodDeclaration", ")", "if", "(", "(", "(", "AbstractMethodDeclaration", ")", "refContext", ")", ".", "binding", "==", "method", ")", "return", "true", ";", "}", "scope", "=", "scope", ".", "parent", ";", "}", "while", "(", "scope", "!=", "null", ")", ";", "return", "false", ";", "}", "public", "final", "boolean", "isDefinedInSameUnit", "(", "ReferenceBinding", "type", ")", "{", "ReferenceBinding", "enclosingType", "=", "type", ";", "while", "(", "(", "type", "=", "enclosingType", ".", "enclosingType", "(", ")", ")", "!=", "null", ")", "enclosingType", "=", "type", ";", "Scope", "scope", ",", "unitScope", "=", "this", ";", "while", "(", "(", "scope", "=", "unitScope", ".", "parent", ")", "!=", "null", ")", "unitScope", "=", "scope", ";", "SourceTypeBinding", "[", "]", "topLevelTypes", "=", "(", "(", "CompilationUnitScope", ")", "unitScope", ")", ".", "topLevelTypes", ";", "for", "(", "int", "i", "=", "topLevelTypes", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "topLevelTypes", "[", "i", "]", "==", "enclosingType", ")", "return", "true", ";", "return", "false", ";", "}", "public", "final", "boolean", "isDefinedInType", "(", "ReferenceBinding", "type", ")", "{", "Scope", "scope", "=", "this", ";", "do", "{", "if", "(", "scope", "instanceof", "ClassScope", ")", "if", "(", "(", "(", "ClassScope", ")", "scope", ")", ".", "referenceContext", ".", "binding", "==", "type", ")", "return", "true", ";", "scope", "=", "scope", ".", "parent", ";", "}", "while", "(", "scope", "!=", "null", ")", ";", "return", "false", ";", "}", "public", "boolean", "isInsideCase", "(", "CaseStatement", "caseStatement", ")", "{", "Scope", "scope", "=", "this", ";", "do", "{", "switch", "(", "scope", ".", "kind", ")", "{", "case", "Scope", ".", "BLOCK_SCOPE", ":", "if", "(", "(", "(", "BlockScope", ")", "scope", ")", ".", "enclosingCase", "==", "caseStatement", ")", "{", "return", "true", ";", "}", "}", "scope", "=", "scope", ".", "parent", ";", "}", "while", "(", "scope", "!=", "null", ")", ";", "return", "false", ";", "}", "public", "boolean", "isInsideDeprecatedCode", "(", ")", "{", "switch", "(", "this", ".", "kind", ")", "{", "case", "Scope", ".", "BLOCK_SCOPE", ":", "case", "Scope", ".", "METHOD_SCOPE", ":", "MethodScope", "methodScope", "=", "methodScope", "(", ")", ";", "if", "(", "!", "methodScope", ".", "isInsideInitializer", "(", ")", ")", "{", "MethodBinding", "context", "=", "(", "(", "AbstractMethodDeclaration", ")", "methodScope", ".", "referenceContext", ")", ".", "binding", ";", "if", "(", "context", "!=", "null", "&&", "context", ".", "isViewedAsDeprecated", "(", ")", ")", "return", "true", ";", "}", "else", "if", "(", "methodScope", ".", "initializedField", "!=", "null", "&&", "methodScope", ".", "initializedField", ".", "isViewedAsDeprecated", "(", ")", ")", "{", "return", "true", ";", "}", "SourceTypeBinding", "declaringType", "=", "(", "(", "BlockScope", ")", "this", ")", ".", "referenceType", "(", ")", ".", "binding", ";", "if", "(", "declaringType", "!=", "null", ")", "{", "declaringType", ".", "initializeDeprecatedAnnotationTagBits", "(", ")", ";", "if", "(", "declaringType", ".", "isViewedAsDeprecated", "(", ")", ")", "return", "true", ";", "}", "break", ";", "case", "Scope", ".", "CLASS_SCOPE", ":", "ReferenceBinding", "context", "=", "(", "(", "ClassScope", ")", "this", ")", ".", "referenceType", "(", ")", ".", "binding", ";", "if", "(", "context", "!=", "null", ")", "{", "context", ".", "initializeDeprecatedAnnotationTagBits", "(", ")", ";", "if", "(", "context", ".", "isViewedAsDeprecated", "(", ")", ")", "return", "true", ";", "}", "break", ";", "case", "Scope", ".", "COMPILATION_UNIT_SCOPE", ":", "CompilationUnitDeclaration", "unit", "=", "referenceCompilationUnit", "(", ")", ";", "if", "(", "unit", ".", "types", "!=", "null", "&&", "unit", ".", "types", ".", "length", ">", "0", ")", "{", "SourceTypeBinding", "type", "=", "unit", ".", "types", "[", "0", "]", ".", "binding", ";", "if", "(", "type", "!=", "null", ")", "{", "type", ".", "initializeDeprecatedAnnotationTagBits", "(", ")", ";", "if", "(", "type", ".", "isViewedAsDeprecated", "(", ")", ")", "return", "true", ";", "}", "}", "}", "return", "false", ";", "}", "private", "boolean", "isOverriddenMethodGeneric", "(", "MethodBinding", "method", ")", "{", "MethodVerifier", "verifier", "=", "environment", "(", ")", ".", "methodVerifier", "(", ")", ";", "ReferenceBinding", "currentType", "=", "method", ".", "declaringClass", ".", "superclass", "(", ")", ";", "while", "(", "currentType", "!=", "null", ")", "{", "MethodBinding", "[", "]", "currentMethods", "=", "currentType", ".", "getMethods", "(", "method", ".", "selector", ")", ";", "for", "(", "int", "i", "=", "0", ",", "l", "=", "currentMethods", ".", "length", ";", "i", "<", "l", ";", "i", "++", ")", "{", "MethodBinding", "currentMethod", "=", "currentMethods", "[", "i", "]", ";", "if", "(", "currentMethod", "!=", "null", "&&", "currentMethod", ".", "original", "(", ")", ".", "typeVariables", "!=", "Binding", ".", "NO_TYPE_VARIABLES", ")", "if", "(", "verifier", ".", "doesMethodOverride", "(", "method", ",", "currentMethod", ")", ")", "return", "true", ";", "}", "currentType", "=", "currentType", ".", "superclass", "(", ")", ";", "}", "return", "false", ";", "}", "public", "boolean", "isPossibleSubtypeOfRawType", "(", "TypeBinding", "paramType", ")", "{", "TypeBinding", "t", "=", "paramType", ".", "leafComponentType", "(", ")", ";", "if", "(", "t", ".", "isBaseType", "(", ")", ")", "return", "false", ";", "ReferenceBinding", "currentType", "=", "(", "ReferenceBinding", ")", "t", ";", "ReferenceBinding", "[", "]", "interfacesToVisit", "=", "null", ";", "int", "nextPosition", "=", "0", ";", "do", "{", "if", "(", "currentType", ".", "isRawType", "(", ")", ")", "return", "true", ";", "if", "(", "!", "currentType", ".", "isHierarchyConnected", "(", ")", ")", "return", "true", ";", "ReferenceBinding", "[", "]", "itsInterfaces", "=", "currentType", ".", "superInterfaces", "(", ")", ";", "if", "(", "itsInterfaces", "!=", "null", "&&", "itsInterfaces", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "if", "(", "interfacesToVisit", "==", "null", ")", "{", "interfacesToVisit", "=", "itsInterfaces", ";", "nextPosition", "=", "interfacesToVisit", ".", "length", ";", "}", "else", "{", "int", "itsLength", "=", "itsInterfaces", ".", "length", ";", "if", "(", "nextPosition", "+", "itsLength", ">=", "interfacesToVisit", ".", "length", ")", "System", ".", "arraycopy", "(", "interfacesToVisit", ",", "0", ",", "interfacesToVisit", "=", "new", "ReferenceBinding", "[", "nextPosition", "+", "itsLength", "+", "5", "]", ",", "0", ",", "nextPosition", ")", ";", "nextInterface", ":", "for", "(", "int", "a", "=", "0", ";", "a", "<", "itsLength", ";", "a", "++", ")", "{", "ReferenceBinding", "next", "=", "itsInterfaces", "[", "a", "]", ";", "for", "(", "int", "b", "=", "0", ";", "b", "<", "nextPosition", ";", "b", "++", ")", "if", "(", "next", "==", "interfacesToVisit", "[", "b", "]", ")", "continue", "nextInterface", ";", "interfacesToVisit", "[", "nextPosition", "++", "]", "=", "next", ";", "}", "}", "}", "}", "while", "(", "(", "currentType", "=", "currentType", ".", "superclass", "(", ")", ")", "!=", "null", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "nextPosition", ";", "i", "++", ")", "{", "currentType", "=", "interfacesToVisit", "[", "i", "]", ";", "if", "(", "currentType", ".", "isRawType", "(", ")", ")", "return", "true", ";", "ReferenceBinding", "[", "]", "itsInterfaces", "=", "currentType", ".", "superInterfaces", "(", ")", ";", "if", "(", "itsInterfaces", "!=", "null", "&&", "itsInterfaces", "!=", "Binding", ".", "NO_SUPERINTERFACES", ")", "{", "int", "itsLength", "=", "itsInterfaces", ".", "length", ";", "if", "(", "nextPosition", "+", "itsLength", ">=", "interfacesToVisit", ".", "length", ")", "System", ".", "arraycopy", "(", "interfacesToVisit", ",", "0", ",", "interfacesToVisit", "=", "new", "ReferenceBinding", "[", "nextPosition", "+", "itsLength", "+", "5", "]", ",", "0", ",", "nextPosition", ")", ";", "nextInterface", ":", "for", "(", "int", "a", "=", "0", ";", "a", "<", "itsLength", ";", "a", "++", ")", "{", "ReferenceBinding", "next", "=", "itsInterfaces", "[", "a", "]", ";", "for", "(", "int", "b", "=", "0", ";", "b", "<", "nextPosition", ";", "b", "++", ")", "if", "(", "next", "==", "interfacesToVisit", "[", "b", "]", ")", "continue", "nextInterface", ";", "interfacesToVisit", "[", "nextPosition", "++", "]", "=", "next", ";", "}", "}", "}", "return", "false", ";", "}", "private", "TypeBinding", "leastContainingInvocation", "(", "TypeBinding", "mec", ",", "Object", "invocationData", ",", "List", "lubStack", ")", "{", "if", "(", "invocationData", "==", "null", ")", "return", "mec", ";", "if", "(", "invocationData", "instanceof", "TypeBinding", ")", "{", "return", "(", "TypeBinding", ")", "invocationData", ";", "}", "TypeBinding", "[", "]", "invocations", "=", "(", "TypeBinding", "[", "]", ")", "invocationData", ";", "int", "dim", "=", "mec", ".", "dimensions", "(", ")", ";", "mec", "=", "mec", ".", "leafComponentType", "(", ")", ";", "int", "argLength", "=", "mec", ".", "typeVariables", "(", ")", ".", "length", ";", "if", "(", "argLength", "==", "0", ")", "return", "mec", ";", "TypeBinding", "[", "]", "bestArguments", "=", "new", "TypeBinding", "[", "argLength", "]", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "invocations", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeBinding", "invocation", "=", "invocations", "[", "i", "]", ".", "leafComponentType", "(", ")", ";", "switch", "(", "invocation", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "GENERIC_TYPE", ":", "TypeVariableBinding", "[", "]", "invocationVariables", "=", "invocation", ".", "typeVariables", "(", ")", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "argLength", ";", "j", "++", ")", "{", "TypeBinding", "bestArgument", "=", "leastContainingTypeArgument", "(", "bestArguments", "[", "j", "]", ",", "invocationVariables", "[", "j", "]", ",", "(", "ReferenceBinding", ")", "mec", ",", "j", ",", "lubStack", ")", ";", "if", "(", "bestArgument", "==", "null", ")", "return", "null", ";", "bestArguments", "[", "j", "]", "=", "bestArgument", ";", "}", "break", ";", "case", "Binding", ".", "PARAMETERIZED_TYPE", ":", "ParameterizedTypeBinding", "parameterizedType", "=", "(", "ParameterizedTypeBinding", ")", "invocation", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "argLength", ";", "j", "++", ")", "{", "TypeBinding", "bestArgument", "=", "leastContainingTypeArgument", "(", "bestArguments", "[", "j", "]", ",", "parameterizedType", ".", "arguments", "[", "j", "]", ",", "(", "ReferenceBinding", ")", "mec", ",", "j", ",", "lubStack", ")", ";", "if", "(", "bestArgument", "==", "null", ")", "return", "null", ";", "bestArguments", "[", "j", "]", "=", "bestArgument", ";", "}", "break", ";", "case", "Binding", ".", "RAW_TYPE", ":", "return", "dim", "==", "0", "?", "invocation", ":", "environment", "(", ")", ".", "createArrayType", "(", "invocation", ",", "dim", ")", ";", "}", "}", "TypeBinding", "least", "=", "environment", "(", ")", ".", "createParameterizedType", "(", "(", "ReferenceBinding", ")", "mec", ".", "erasure", "(", ")", ",", "bestArguments", ",", "mec", ".", "enclosingType", "(", ")", ")", ";", "return", "dim", "==", "0", "?", "least", ":", "environment", "(", ")", ".", "createArrayType", "(", "least", ",", "dim", ")", ";", "}", "private", "TypeBinding", "leastContainingTypeArgument", "(", "TypeBinding", "u", ",", "TypeBinding", "v", ",", "ReferenceBinding", "genericType", ",", "int", "rank", ",", "List", "lubStack", ")", "{", "if", "(", "u", "==", "null", ")", "return", "v", ";", "if", "(", "u", "==", "v", ")", "return", "u", ";", "if", "(", "v", ".", "isWildcard", "(", ")", ")", "{", "WildcardBinding", "wildV", "=", "(", "WildcardBinding", ")", "v", ";", "if", "(", "u", ".", "isWildcard", "(", ")", ")", "{", "WildcardBinding", "wildU", "=", "(", "WildcardBinding", ")", "u", ";", "switch", "(", "wildU", ".", "boundKind", ")", "{", "case", "Wildcard", ".", "EXTENDS", ":", "switch", "(", "wildV", ".", "boundKind", ")", "{", "case", "Wildcard", ".", "EXTENDS", ":", "TypeBinding", "lub", "=", "lowerUpperBound", "(", "new", "TypeBinding", "[", "]", "{", "wildU", ".", "bound", ",", "wildV", ".", "bound", "}", ",", "lubStack", ")", ";", "if", "(", "lub", "==", "null", ")", "return", "null", ";", "if", "(", "lub", "==", "TypeBinding", ".", "INT", ")", "return", "environment", "(", ")", ".", "createWildcard", "(", "genericType", ",", "rank", ",", "null", ",", "null", ",", "Wildcard", ".", "UNBOUND", ")", ";", "return", "environment", "(", ")", ".", "createWildcard", "(", "genericType", ",", "rank", ",", "lub", ",", "null", ",", "Wildcard", ".", "EXTENDS", ")", ";", "case", "Wildcard", ".", "SUPER", ":", "if", "(", "wildU", ".", "bound", "==", "wildV", ".", "bound", ")", "return", "wildU", ".", "bound", ";", "return", "environment", "(", ")", ".", "createWildcard", "(", "genericType", ",", "rank", ",", "null", ",", "null", ",", "Wildcard", ".", "UNBOUND", ")", ";", "}", "break", ";", "case", "Wildcard", ".", "SUPER", ":", "if", "(", "wildU", ".", "boundKind", "==", "Wildcard", ".", "SUPER", ")", "{", "TypeBinding", "[", "]", "glb", "=", "greaterLowerBound", "(", "new", "TypeBinding", "[", "]", "{", "wildU", ".", "bound", ",", "wildV", ".", "bound", "}", ")", ";", "if", "(", "glb", "==", "null", ")", "return", "null", ";", "return", "environment", "(", ")", ".", "createWildcard", "(", "genericType", ",", "rank", ",", "glb", "[", "0", "]", ",", "null", ",", "Wildcard", ".", "SUPER", ")", ";", "}", "}", "}", "else", "{", "switch", "(", "wildV", ".", "boundKind", ")", "{", "case", "Wildcard", ".", "EXTENDS", ":", "TypeBinding", "lub", "=", "lowerUpperBound", "(", "new", "TypeBinding", "[", "]", "{", "u", ",", "wildV", ".", "bound", "}", ",", "lubStack", ")", ";", "if", "(", "lub", "==", "null", ")", "return", "null", ";", "if", "(", "lub", "==", "TypeBinding", ".", "INT", ")", "return", "environment", "(", ")", ".", "createWildcard", "(", "genericType", ",", "rank", ",", "null", ",", "null", ",", "Wildcard", ".", "UNBOUND", ")", ";", "return", "environment", "(", ")", ".", "createWildcard", "(", "genericType", ",", "rank", ",", "lub", ",", "null", ",", "Wildcard", ".", "EXTENDS", ")", ";", "case", "Wildcard", ".", "SUPER", ":", "TypeBinding", "[", "]", "glb", "=", "greaterLowerBound", "(", "new", "TypeBinding", "[", "]", "{", "u", ",", "wildV", ".", "bound", "}", ")", ";", "if", "(", "glb", "==", "null", ")", "return", "null", ";", "return", "environment", "(", ")", ".", "createWildcard", "(", "genericType", ",", "rank", ",", "glb", "[", "0", "]", ",", "null", ",", "Wildcard", ".", "SUPER", ")", ";", "case", "Wildcard", ".", "UNBOUND", ":", "}", "}", "}", "else", "if", "(", "u", ".", "isWildcard", "(", ")", ")", "{", "WildcardBinding", "wildU", "=", "(", "WildcardBinding", ")", "u", ";", "switch", "(", "wildU", ".", "boundKind", ")", "{", "case", "Wildcard", ".", "EXTENDS", ":", "TypeBinding", "lub", "=", "lowerUpperBound", "(", "new", "TypeBinding", "[", "]", "{", "wildU", ".", "bound", ",", "v", "}", ",", "lubStack", ")", ";", "if", "(", "lub", "==", "null", ")", "return", "null", ";", "if", "(", "lub", "==", "TypeBinding", ".", "INT", ")", "return", "environment", "(", ")", ".", "createWildcard", "(", "genericType", ",", "rank", ",", "null", ",", "null", ",", "Wildcard", ".", "UNBOUND", ")", ";", "return", "environment", "(", ")", ".", "createWildcard", "(", "genericType", ",", "rank", ",", "lub", ",", "null", ",", "Wildcard", ".", "EXTENDS", ")", ";", "case", "Wildcard", ".", "SUPER", ":", "TypeBinding", "[", "]", "glb", "=", "greaterLowerBound", "(", "new", "TypeBinding", "[", "]", "{", "wildU", ".", "bound", ",", "v", "}", ")", ";", "if", "(", "glb", "==", "null", ")", "return", "null", ";", "return", "environment", "(", ")", ".", "createWildcard", "(", "genericType", ",", "rank", ",", "glb", "[", "0", "]", ",", "null", ",", "Wildcard", ".", "SUPER", ")", ";", "case", "Wildcard", ".", "UNBOUND", ":", "}", "}", "TypeBinding", "lub", "=", "lowerUpperBound", "(", "new", "TypeBinding", "[", "]", "{", "u", ",", "v", "}", ",", "lubStack", ")", ";", "if", "(", "lub", "==", "null", ")", "return", "null", ";", "if", "(", "lub", "==", "TypeBinding", ".", "INT", ")", "return", "environment", "(", ")", ".", "createWildcard", "(", "genericType", ",", "rank", ",", "null", ",", "null", ",", "Wildcard", ".", "UNBOUND", ")", ";", "return", "environment", "(", ")", ".", "createWildcard", "(", "genericType", ",", "rank", ",", "lub", ",", "null", ",", "Wildcard", ".", "EXTENDS", ")", ";", "}", "public", "TypeBinding", "lowerUpperBound", "(", "TypeBinding", "[", "]", "types", ")", "{", "int", "typeLength", "=", "types", ".", "length", ";", "if", "(", "typeLength", "==", "1", ")", "{", "TypeBinding", "type", "=", "types", "[", "0", "]", ";", "return", "type", "==", "null", "?", "TypeBinding", ".", "VOID", ":", "type", ";", "}", "return", "lowerUpperBound", "(", "types", ",", "new", "ArrayList", "(", "1", ")", ")", ";", "}", "private", "TypeBinding", "lowerUpperBound", "(", "TypeBinding", "[", "]", "types", ",", "List", "lubStack", ")", "{", "int", "typeLength", "=", "types", ".", "length", ";", "if", "(", "typeLength", "==", "1", ")", "{", "TypeBinding", "type", "=", "types", "[", "0", "]", ";", "return", "type", "==", "null", "?", "TypeBinding", ".", "VOID", ":", "type", ";", "}", "int", "stackLength", "=", "lubStack", ".", "size", "(", ")", ";", "nextLubCheck", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "stackLength", ";", "i", "++", ")", "{", "TypeBinding", "[", "]", "lubTypes", "=", "(", "TypeBinding", "[", "]", ")", "lubStack", ".", "get", "(", "i", ")", ";", "int", "lubTypeLength", "=", "lubTypes", ".", "length", ";", "if", "(", "lubTypeLength", "<", "typeLength", ")", "continue", "nextLubCheck", ";", "nextTypeCheck", ":", "for", "(", "int", "j", "=", "0", ";", "j", "<", "typeLength", ";", "j", "++", ")", "{", "TypeBinding", "type", "=", "types", "[", "j", "]", ";", "if", "(", "type", "==", "null", ")", "continue", "nextTypeCheck", ";", "for", "(", "int", "k", "=", "0", ";", "k", "<", "lubTypeLength", ";", "k", "++", ")", "{", "TypeBinding", "lubType", "=", "lubTypes", "[", "k", "]", ";", "if", "(", "lubType", "==", "null", ")", "continue", ";", "if", "(", "lubType", "==", "type", "||", "lubType", ".", "isEquivalentTo", "(", "type", ")", ")", "continue", "nextTypeCheck", ";", "}", "continue", "nextLubCheck", ";", "}", "return", "TypeBinding", ".", "INT", ";", "}", "lubStack", ".", "add", "(", "types", ")", ";", "Map", "invocations", "=", "new", "HashMap", "(", "1", ")", ";", "TypeBinding", "[", "]", "mecs", "=", "minimalErasedCandidates", "(", "types", ",", "invocations", ")", ";", "if", "(", "mecs", "==", "null", ")", "return", "null", ";", "int", "length", "=", "mecs", ".", "length", ";", "if", "(", "length", "==", "0", ")", "return", "TypeBinding", ".", "VOID", ";", "int", "count", "=", "0", ";", "TypeBinding", "firstBound", "=", "null", ";", "int", "commonDim", "=", "-", "1", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeBinding", "mec", "=", "mecs", "[", "i", "]", ";", "if", "(", "mec", "==", "null", ")", "continue", ";", "mec", "=", "leastContainingInvocation", "(", "mec", ",", "invocations", ".", "get", "(", "mec", ")", ",", "lubStack", ")", ";", "if", "(", "mec", "==", "null", ")", "return", "null", ";", "int", "dim", "=", "mec", ".", "dimensions", "(", ")", ";", "if", "(", "commonDim", "==", "-", "1", ")", "{", "commonDim", "=", "dim", ";", "}", "else", "if", "(", "dim", "!=", "commonDim", ")", "{", "return", "null", ";", "}", "if", "(", "firstBound", "==", "null", "&&", "!", "mec", ".", "leafComponentType", "(", ")", ".", "isInterface", "(", ")", ")", "firstBound", "=", "mec", ".", "leafComponentType", "(", ")", ";", "mecs", "[", "count", "++", "]", "=", "mec", ";", "}", "switch", "(", "count", ")", "{", "case", "0", ":", "return", "TypeBinding", ".", "VOID", ";", "case", "1", ":", "return", "mecs", "[", "0", "]", ";", "case", "2", ":", "if", "(", "(", "commonDim", "==", "0", "?", "mecs", "[", "1", "]", ".", "id", ":", "mecs", "[", "1", "]", ".", "leafComponentType", "(", ")", ".", "id", ")", "==", "TypeIds", ".", "T_JavaLangObject", ")", "return", "mecs", "[", "0", "]", ";", "if", "(", "(", "commonDim", "==", "0", "?", "mecs", "[", "0", "]", ".", "id", ":", "mecs", "[", "0", "]", ".", "leafComponentType", "(", ")", ".", "id", ")", "==", "TypeIds", ".", "T_JavaLangObject", ")", "return", "mecs", "[", "1", "]", ";", "}", "TypeBinding", "[", "]", "otherBounds", "=", "new", "TypeBinding", "[", "count", "-", "1", "]", ";", "int", "rank", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "count", ";", "i", "++", ")", "{", "TypeBinding", "mec", "=", "commonDim", "==", "0", "?", "mecs", "[", "i", "]", ":", "mecs", "[", "i", "]", ".", "leafComponentType", "(", ")", ";", "if", "(", "mec", ".", "isInterface", "(", ")", ")", "{", "otherBounds", "[", "rank", "++", "]", "=", "mec", ";", "}", "}", "TypeBinding", "intersectionType", "=", "environment", "(", ")", ".", "createWildcard", "(", "null", ",", "0", ",", "firstBound", ",", "otherBounds", ",", "Wildcard", ".", "EXTENDS", ")", ";", "return", "commonDim", "==", "0", "?", "intersectionType", ":", "environment", "(", ")", ".", "createArrayType", "(", "intersectionType", ",", "commonDim", ")", ";", "}", "public", "final", "MethodScope", "methodScope", "(", ")", "{", "Scope", "scope", "=", "this", ";", "do", "{", "if", "(", "scope", "instanceof", "MethodScope", ")", "return", "(", "MethodScope", ")", "scope", ";", "scope", "=", "scope", ".", "parent", ";", "}", "while", "(", "scope", "!=", "null", ")", ";", "return", "null", ";", "}", "protected", "TypeBinding", "[", "]", "minimalErasedCandidates", "(", "TypeBinding", "[", "]", "types", ",", "Map", "allInvocations", ")", "{", "int", "length", "=", "types", ".", "length", ";", "int", "indexOfFirst", "=", "-", "1", ",", "actualLength", "=", "0", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeBinding", "type", "=", "types", "[", "i", "]", ";", "if", "(", "type", "==", "null", ")", "continue", ";", "if", "(", "type", ".", "isBaseType", "(", ")", ")", "return", "null", ";", "if", "(", "indexOfFirst", "<", "0", ")", "indexOfFirst", "=", "i", ";", "actualLength", "++", ";", "}", "switch", "(", "actualLength", ")", "{", "case", "0", ":", "return", "Binding", ".", "NO_TYPES", ";", "case", "1", ":", "return", "types", ";", "}", "TypeBinding", "firstType", "=", "types", "[", "indexOfFirst", "]", ";", "if", "(", "firstType", ".", "isBaseType", "(", ")", ")", "return", "null", ";", "ArrayList", "typesToVisit", "=", "new", "ArrayList", "(", "5", ")", ";", "int", "dim", "=", "firstType", ".", "dimensions", "(", ")", ";", "TypeBinding", "leafType", "=", "firstType", ".", "leafComponentType", "(", ")", ";", "TypeBinding", "firstErasure", ";", "switch", "(", "leafType", ".", "kind", "(", ")", ")", "{", "case", "Binding", ".", "PARAMETERIZED_TYPE", ":", "case", "Binding", ".", "RAW_TYPE", ":", "case", "Binding", ".", "ARRAY_TYPE", ":", "firstErasure", "=", "firstType", ".", "erasure", "(", ")", ";", "break", ";", "default", ":", "firstErasure", "=", "firstType", ";", "break", ";", "}", "if", "(", "firstErasure", "!=", "firstType", ")", "{", "allInvocations", ".", "put", "(", "firstErasure", ",", "firstType", ")", ";", "}", "typesToVisit", ".", "add", "(", "firstType", ")", ";", "int", "max", "=", "1", ";", "ReferenceBinding", "currentType", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "max", ";", "i", "++", ")", "{", "TypeBinding", "typeToVisit", "=", "(", "TypeBinding", ")", "typesToVisit", ".", "get", "(", "i", ")", ";", "dim", "=", "typeToVisit", ".", "dimensions", "(", ")", ";", "if", "(", "dim", ">", "0", ")", "{", "leafType", "=", "typeToVisit", ".", "leafComponentType", "(", ")", ";", "switch", "(", "leafType", ".", "id", ")", "{", "case", "TypeIds", ".", "T_JavaLangObject", ":", "if", "(", "dim", ">", "1", ")", "{", "TypeBinding", "elementType", "=", "(", "(", "ArrayBinding", ")", "typeToVisit", ")", ".", "elementsType", "(", ")", ";", "if", "(", "!", "typesToVisit", ".", "contains", "(", "elementType", ")", ")", "{", "typesToVisit", ".", "add", "(", "elementType", ")", ";", "max", "++", ";", "}", "continue", ";", "}", "case", "TypeIds", ".", "T_byte", ":", "case", "TypeIds", ".", "T_short", ":", "case", "TypeIds", ".", "T_char", ":", "case", "TypeIds", ".", "T_boolean", ":", "case", "TypeIds", ".", "T_int", ":", "case", "TypeIds", ".", "T_long", ":", "case", "TypeIds", ".", "T_float", ":", "case", "TypeIds", ".", "T_double", ":", "TypeBinding", "superType", "=", "getJavaIoSerializable", "(", ")", ";", "if", "(", "!", "typesToVisit", ".", "contains", "(", "superType", ")", ")", "{", "typesToVisit", ".", "add", "(", "superType", ")", ";", "max", "++", ";", "}", "superType", "=", "getJavaLangCloneable", "(", ")", ";", "if", "(", "!", "typesToVisit", ".", "contains", "(", "superType", ")", ")", "{", "typesToVisit", ".", "add", "(", "superType", ")", ";", "max", "++", ";", "}", "superType", "=", "getJavaLangObject", "(", ")", ";", "if", "(", "!", "typesToVisit", ".", "contains", "(", "superType", ")", ")", "{", "typesToVisit", ".", "add", "(", "superType", ")", ";", "max", "++", ";", "}", "continue", ";", "default", ":", "}", "typeToVisit", "=", "leafType", ";", "}", "currentType", "=", "(", "ReferenceBinding", ")", "typeToVisit", ";", "if", "(", "currentType", ".", "isCapture", "(", ")", ")", "{", "TypeBinding", "firstBound", "=", "(", "(", "CaptureBinding", ")", "currentType", ")", ".", "firstBound", ";", "if", "(", "firstBound", "!=", "null", "&&", "firstBound", ".", "isArrayType", "(", ")", ")", "{", "TypeBinding", "superType", "=", "dim", "==", "0", "?", "firstBound", ":", "(", "TypeBinding", ")", "environment", "(", ")", ".", "createArrayType", "(", "firstBound", ",", "dim", ")", ";", "if", "(", "!", "typesToVisit", ".", "contains", "(", "superType", ")", ")", "{", "typesToVisit", ".", "add", "(", "superType", ")", ";", "max", "++", ";", "TypeBinding", "superTypeErasure", "=", "(", "firstBound", ".", "isTypeVariable", "(", ")", "||", "firstBound", ".", "isWildcard", "(", ")", ")", "?", "superType", ":", "superType", ".", "erasure", "(", ")", ";", "if", "(", "superTypeErasure", "!=", "superType", ")", "{", "allInvocations", ".", "put", "(", "superTypeErasure", ",", "superType", ")", ";", "}", "}", "continue", ";", "}", "}", "ReferenceBinding", "[", "]", "itsInterfaces", "=", "currentType", ".", "superInterfaces", "(", ")", ";", "if", "(", "itsInterfaces", "!=", "null", ")", "{", "for", "(", "int", "j", "=", "0", ",", "count", "=", "itsInterfaces", ".", "length", ";", "j", "<", "count", ";", "j", "++", ")", "{", "TypeBinding", "itsInterface", "=", "itsInterfaces", "[", "j", "]", ";", "TypeBinding", "superType", "=", "dim", "==", "0", "?", "itsInterface", ":", "(", "TypeBinding", ")", "environment", "(", ")", ".", "createArrayType", "(", "itsInterface", ",", "dim", ")", ";", "if", "(", "!", "typesToVisit", ".", "contains", "(", "superType", ")", ")", "{", "typesToVisit", ".", "add", "(", "superType", ")", ";", "max", "++", ";", "TypeBinding", "superTypeErasure", "=", "(", "itsInterface", ".", "isTypeVariable", "(", ")", "||", "itsInterface", ".", "isWildcard", "(", ")", ")", "?", "superType", ":", "superType", ".", "erasure", "(", ")", ";", "if", "(", "superTypeErasure", "!=", "superType", ")", "{", "allInvocations", ".", "put", "(", "superTypeErasure", ",", "superType", ")", ";", "}", "}", "}", "}", "TypeBinding", "itsSuperclass", "=", "currentType", ".", "superclass", "(", ")", ";", "if", "(", "itsSuperclass", "!=", "null", ")", "{", "TypeBinding", "superType", "=", "dim", "==", "0", "?", "itsSuperclass", ":", "(", "TypeBinding", ")", "environment", "(", ")", ".", "createArrayType", "(", "itsSuperclass", ",", "dim", ")", ";", "if", "(", "!", "typesToVisit", ".", "contains", "(", "superType", ")", ")", "{", "typesToVisit", ".", "add", "(", "superType", ")", ";", "max", "++", ";", "TypeBinding", "superTypeErasure", "=", "(", "itsSuperclass", ".", "isTypeVariable", "(", ")", "||", "itsSuperclass", ".", "isWildcard", "(", ")", ")", "?", "superType", ":", "superType", ".", "erasure", "(", ")", ";", "if", "(", "superTypeErasure", "!=", "superType", ")", "{", "allInvocations", ".", "put", "(", "superTypeErasure", ",", "superType", ")", ";", "}", "}", "}", "}", "int", "superLength", "=", "typesToVisit", ".", "size", "(", ")", ";", "TypeBinding", "[", "]", "erasedSuperTypes", "=", "new", "TypeBinding", "[", "superLength", "]", ";", "int", "rank", "=", "0", ";", "for", "(", "Iterator", "iter", "=", "typesToVisit", ".", "iterator", "(", ")", ";", "iter", ".", "hasNext", "(", ")", ";", ")", "{", "TypeBinding", "type", "=", "(", "TypeBinding", ")", "iter", ".", "next", "(", ")", ";", "leafType", "=", "type", ".", "leafComponentType", "(", ")", ";", "erasedSuperTypes", "[", "rank", "++", "]", "=", "(", "leafType", ".", "isTypeVariable", "(", ")", "||", "leafType", ".", "isWildcard", "(", ")", ")", "?", "type", ":", "type", ".", "erasure", "(", ")", ";", "}", "int", "remaining", "=", "superLength", ";", "nextOtherType", ":", "for", "(", "int", "i", "=", "indexOfFirst", "+", "1", ";", "i", "<", "length", ";", "i", "++", ")", "{", "TypeBinding", "otherType", "=", "types", "[", "i", "]", ";", "if", "(", "otherType", "==", "null", ")", "continue", "nextOtherType", ";", "if", "(", "otherType", ".", "isArrayType", "(", ")", ")", "{", "nextSuperType", ":", "for", "(", "int", "j", "=", "0", ";", "j", "<", "superLength", ";", "j", "++", ")", "{", "TypeBinding", "erasedSuperType", "=", "erasedSuperTypes", "[", "j", "]", ";", "if", "(", "erasedSuperType", "==", "null", "||", "erasedSuperType", "==", "otherType", ")", "continue", "nextSuperType", ";", "TypeBinding", "match", ";", "if", "(", "(", "match", "=", "otherType", ".", "findSuperTypeOriginatingFrom", "(", "erasedSuperType", ")", ")", "==", "null", ")", "{", "erasedSuperTypes", "[", "j", "]", "=", "null", ";", "if", "(", "--", "remaining", "==", "0", ")", "return", "null", ";", "continue", "nextSuperType", ";", "}", "Object", "invocationData", "=", "allInvocations", ".", "get", "(", "erasedSuperType", ")", ";", "if", "(", "invocationData", "==", "null", ")", "{", "allInvocations", ".", "put", "(", "erasedSuperType", ",", "match", ")", ";", "}", "else", "if", "(", "invocationData", "instanceof", "TypeBinding", ")", "{", "if", "(", "match", "!=", "invocationData", ")", "{", "TypeBinding", "[", "]", "someInvocations", "=", "{", "(", "TypeBinding", ")", "invocationData", ",", "match", ",", "}", ";", "allInvocations", ".", "put", "(", "erasedSuperType", ",", "someInvocations", ")", ";", "}", "}", "else", "{", "TypeBinding", "[", "]", "someInvocations", "=", "(", "TypeBinding", "[", "]", ")", "invocationData", ";", "checkExisting", ":", "{", "int", "invocLength", "=", "someInvocations", ".", "length", ";", "for", "(", "int", "k", "=", "0", ";", "k", "<", "invocLength", ";", "k", "++", ")", "{", "if", "(", "someInvocations", "[", "k", "]", "==", "match", ")", "break", "checkExisting", ";", "}", "System", ".", "arraycopy", "(", "someInvocations", ",", "0", ",", "someInvocations", "=", "new", "TypeBinding", "[", "invocLength", "+", "1", "]", ",", "0", ",", "invocLength", ")", ";", "allInvocations", ".", "put", "(", "erasedSuperType", ",", "someInvocations", ")", ";", "someInvocations", "[", "invocLength", "]", "=", "match", ";", "}", "}", "}", "continue", "nextOtherType", ";", "}", "nextSuperType", ":", "for", "(", "int", "j", "=", "0", ";", "j", "<", "superLength", ";", "j", "++", ")", "{", "TypeBinding", "erasedSuperType", "=", "erasedSuperTypes", "[", "j", "]", ";", "if", "(", "erasedSuperType", "==", "null", ")", "continue", "nextSuperType", ";", "TypeBinding", "match", ";", "if", "(", "erasedSuperType", "==", "otherType", "||", "erasedSuperType", ".", "id", "==", "TypeIds", ".", "T_JavaLangObject", "&&", "otherType", ".", "isInterface", "(", ")", ")", "{", "match", "=", "erasedSuperType", ";", "}", "else", "{", "if", "(", "erasedSuperType", ".", "isArrayType", "(", ")", ")", "{", "match", "=", "null", ";", "}", "else", "{", "match", "=", "otherType", ".", "findSuperTypeOriginatingFrom", "(", "erasedSuperType", ")", ";", "}", "if", "(", "match", "==", "null", ")", "{", "erasedSuperTypes", "[", "j", "]", "=", "null", ";", "if", "(", "--", "remaining", "==", "0", ")", "return", "null", ";", "continue", "nextSuperType", ";", "}", "}", "Object", "invocationData", "=", "allInvocations", ".", "get", "(", "erasedSuperType", ")", ";", "if", "(", "invocationData", "==", "null", ")", "{", "allInvocations", ".", "put", "(", "erasedSuperType", ",", "match", ")", ";", "}", "else", "if", "(", "invocationData", "instanceof", "TypeBinding", ")", "{", "if", "(", "match", "!=", "invocationData", ")", "{", "TypeBinding", "[", "]", "someInvocations", "=", "{", "(", "TypeBinding", ")", "invocationData", ",", "match", ",", "}", ";", "allInvocations", ".", "put", "(", "erasedSuperType", ",", "someInvocations", ")", ";", "}", "}", "else", "{", "TypeBinding", "[", "]", "someInvocations", "=", "(", "TypeBinding", "[", "]", ")", "invocationData", ";", "checkExisting", ":", "{", "int", "invocLength", "=", "someInvocations", ".", "length", ";", "for", "(", "int", "k", "=", "0", ";", "k", "<", "invocLength", ";", "k", "++", ")", "{", "if", "(", "someInvocations", "[", "k", "]", "==", "match", ")", "break", "checkExisting", ";", "}", "System", ".", "arraycopy", "(", "someInvocations", ",", "0", ",", "someInvocations", "=", "new", "TypeBinding", "[", "invocLength", "+", "1", "]", ",", "0", ",", "invocLength", ")", ";", "allInvocations", ".", "put", "(", "erasedSuperType", ",", "someInvocations", ")", ";", "someInvocations", "[", "invocLength", "]", "=", "match", ";", "}", "}", "}", "}", "if", "(", "remaining", ">", "1", ")", "{", "nextType", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "superLength", ";", "i", "++", ")", "{", "TypeBinding", "erasedSuperType", "=", "erasedSuperTypes", "[", "i", "]", ";", "if", "(", "erasedSuperType", "==", "null", ")", "continue", "nextType", ";", "nextOtherType", ":", "for", "(", "int", "j", "=", "0", ";", "j", "<", "superLength", ";", "j", "++", ")", "{", "if", "(", "i", "==", "j", ")", "continue", "nextOtherType", ";", "TypeBinding", "otherType", "=", "erasedSuperTypes", "[", "j", "]", ";", "if", "(", "otherType", "==", "null", ")", "continue", "nextOtherType", ";", "if", "(", "erasedSuperType", "instanceof", "ReferenceBinding", ")", "{", "if", "(", "otherType", ".", "id", "==", "TypeIds", ".", "T_JavaLangObject", "&&", "erasedSuperType", ".", "isInterface", "(", ")", ")", "continue", "nextOtherType", ";", "if", "(", "erasedSuperType", ".", "findSuperTypeOriginatingFrom", "(", "otherType", ")", "!=", "null", ")", "{", "erasedSuperTypes", "[", "j", "]", "=", "null", ";", "remaining", "--", ";", "}", "}", "else", "if", "(", "erasedSuperType", ".", "isArrayType", "(", ")", ")", "{", "if", "(", "otherType", ".", "isArrayType", "(", ")", "&&", "otherType", ".", "leafComponentType", "(", ")", ".", "id", "==", "TypeIds", ".", "T_JavaLangObject", "&&", "otherType", ".", "dimensions", "(", ")", "==", "erasedSuperType", ".", "dimensions", "(", ")", "&&", "erasedSuperType", ".", "leafComponentType", "(", ")", ".", "isInterface", "(", ")", ")", "continue", "nextOtherType", ";", "if", "(", "erasedSuperType", ".", "findSuperTypeOriginatingFrom", "(", "otherType", ")", "!=", "null", ")", "{", "erasedSuperTypes", "[", "j", "]", "=", "null", ";", "remaining", "--", ";", "}", "}", "}", "}", "}", "return", "erasedSuperTypes", ";", "}", "protected", "final", "MethodBinding", "mostSpecificClassMethodBinding", "(", "MethodBinding", "[", "]", "visible", ",", "int", "visibleSize", ",", "InvocationSite", "invocationSite", ")", "{", "MethodBinding", "previous", "=", "null", ";", "nextVisible", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "visibleSize", ";", "i", "++", ")", "{", "MethodBinding", "method", "=", "visible", "[", "i", "]", ";", "if", "(", "previous", "!=", "null", "&&", "method", ".", "declaringClass", "!=", "previous", ".", "declaringClass", ")", "break", ";", "if", "(", "!", "method", ".", "isStatic", "(", ")", ")", "previous", "=", "method", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "visibleSize", ";", "j", "++", ")", "{", "if", "(", "i", "==", "j", ")", "continue", ";", "if", "(", "!", "visible", "[", "j", "]", ".", "areParametersCompatibleWith", "(", "method", ".", "parameters", ")", ")", "continue", "nextVisible", ";", "}", "compilationUnitScope", "(", ")", ".", "recordTypeReferences", "(", "method", ".", "thrownExceptions", ")", ";", "return", "method", ";", "}", "return", "new", "ProblemMethodBinding", "(", "visible", "[", "0", "]", ",", "visible", "[", "0", "]", ".", "selector", ",", "visible", "[", "0", "]", ".", "parameters", ",", "ProblemReasons", ".", "Ambiguous", ")", ";", "}", "protected", "final", "MethodBinding", "mostSpecificInterfaceMethodBinding", "(", "MethodBinding", "[", "]", "visible", ",", "int", "visibleSize", ",", "InvocationSite", "invocationSite", ")", "{", "nextVisible", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "visibleSize", ";", "i", "++", ")", "{", "MethodBinding", "method", "=", "visible", "[", "i", "]", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "visibleSize", ";", "j", "++", ")", "{", "if", "(", "i", "==", "j", ")", "continue", ";", "if", "(", "!", "visible", "[", "j", "]", ".", "areParametersCompatibleWith", "(", "method", ".", "parameters", ")", ")", "continue", "nextVisible", ";", "}", "compilationUnitScope", "(", ")", ".", "recordTypeReferences", "(", "method", ".", "thrownExceptions", ")", ";", "return", "method", ";", "}", "return", "new", "ProblemMethodBinding", "(", "visible", "[", "0", "]", ",", "visible", "[", "0", "]", ".", "selector", ",", "visible", "[", "0", "]", ".", "parameters", ",", "ProblemReasons", ".", "Ambiguous", ")", ";", "}", "protected", "final", "MethodBinding", "mostSpecificMethodBinding", "(", "MethodBinding", "[", "]", "visible", ",", "int", "visibleSize", ",", "TypeBinding", "[", "]", "argumentTypes", ",", "final", "InvocationSite", "invocationSite", ",", "ReferenceBinding", "receiverType", ")", "{", "int", "[", "]", "compatibilityLevels", "=", "new", "int", "[", "visibleSize", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "visibleSize", ";", "i", "++", ")", "compatibilityLevels", "[", "i", "]", "=", "parameterCompatibilityLevel", "(", "visible", "[", "i", "]", ",", "argumentTypes", ")", ";", "InvocationSite", "tieBreakInvocationSite", "=", "new", "InvocationSite", "(", ")", "{", "public", "TypeBinding", "[", "]", "genericTypeArguments", "(", ")", "{", "return", "null", ";", "}", "public", "boolean", "isSuperAccess", "(", ")", "{", "return", "invocationSite", ".", "isSuperAccess", "(", ")", ";", "}", "public", "boolean", "isTypeAccess", "(", ")", "{", "return", "invocationSite", ".", "isTypeAccess", "(", ")", ";", "}", "public", "void", "setActualReceiverType", "(", "ReferenceBinding", "actualReceiverType", ")", "{", "}", "public", "void", "setDepth", "(", "int", "depth", ")", "{", "}", "public", "void", "setFieldIndex", "(", "int", "depth", ")", "{", "}", "public", "int", "sourceStart", "(", ")", "{", "return", "invocationSite", ".", "sourceStart", "(", ")", ";", "}", "public", "int", "sourceEnd", "(", ")", "{", "return", "invocationSite", ".", "sourceStart", "(", ")", ";", "}", "public", "TypeBinding", "expectedType", "(", ")", "{", "return", "invocationSite", ".", "expectedType", "(", ")", ";", "}", "}", ";", "MethodBinding", "[", "]", "moreSpecific", "=", "new", "MethodBinding", "[", "visibleSize", "]", ";", "int", "count", "=", "0", ";", "for", "(", "int", "level", "=", "0", ",", "max", "=", "VARARGS_COMPATIBLE", ";", "level", "<=", "max", ";", "level", "++", ")", "{", "nextVisible", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "visibleSize", ";", "i", "++", ")", "{", "if", "(", "compatibilityLevels", "[", "i", "]", "!=", "level", ")", "continue", "nextVisible", ";", "max", "=", "level", ";", "MethodBinding", "current", "=", "visible", "[", "i", "]", ";", "MethodBinding", "original", "=", "current", ".", "original", "(", ")", ";", "MethodBinding", "tiebreakMethod", "=", "current", ".", "tiebreakMethod", "(", ")", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "visibleSize", ";", "j", "++", ")", "{", "if", "(", "i", "==", "j", "||", "compatibilityLevels", "[", "j", "]", "!=", "level", ")", "continue", ";", "MethodBinding", "next", "=", "visible", "[", "j", "]", ";", "if", "(", "original", "==", "next", ".", "original", "(", ")", ")", "{", "compatibilityLevels", "[", "j", "]", "=", "-", "1", ";", "continue", ";", "}", "MethodBinding", "methodToTest", "=", "next", ";", "if", "(", "next", "instanceof", "ParameterizedGenericMethodBinding", ")", "{", "ParameterizedGenericMethodBinding", "pNext", "=", "(", "ParameterizedGenericMethodBinding", ")", "next", ";", "if", "(", "pNext", ".", "isRaw", "&&", "!", "pNext", ".", "isStatic", "(", ")", ")", "{", "}", "else", "{", "methodToTest", "=", "pNext", ".", "originalMethod", ";", "}", "}", "MethodBinding", "acceptable", "=", "computeCompatibleMethod", "(", "methodToTest", ",", "tiebreakMethod", ".", "parameters", ",", "tieBreakInvocationSite", ")", ";", "if", "(", "acceptable", "==", "null", "||", "!", "acceptable", ".", "isValidBinding", "(", ")", ")", "continue", "nextVisible", ";", "if", "(", "!", "isAcceptableMethod", "(", "tiebreakMethod", ",", "acceptable", ")", ")", "continue", "nextVisible", ";", "if", "(", "current", ".", "isBridge", "(", ")", "&&", "!", "next", ".", "isBridge", "(", ")", ")", "if", "(", "tiebreakMethod", ".", "areParametersEqual", "(", "acceptable", ")", ")", "continue", "nextVisible", ";", "}", "moreSpecific", "[", "i", "]", "=", "current", ";", "count", "++", ";", "}", "}", "if", "(", "count", "==", "1", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "visibleSize", ";", "i", "++", ")", "{", "if", "(", "moreSpecific", "[", "i", "]", "!=", "null", ")", "{", "compilationUnitScope", "(", ")", ".", "recordTypeReferences", "(", "visible", "[", "i", "]", ".", "thrownExceptions", ")", ";", "return", "visible", "[", "i", "]", ";", "}", "}", "}", "else", "if", "(", "count", "==", "0", ")", "{", "return", "new", "ProblemMethodBinding", "(", "visible", "[", "0", "]", ",", "visible", "[", "0", "]", ".", "selector", ",", "visible", "[", "0", "]", ".", "parameters", ",", "ProblemReasons", ".", "Ambiguous", ")", ";", "}", "if", "(", "receiverType", "!=", "null", ")", "receiverType", "=", "receiverType", "instanceof", "CaptureBinding", "?", "receiverType", ":", "(", "ReferenceBinding", ")", "receiverType", ".", "erasure", "(", ")", ";", "nextSpecific", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "visibleSize", ";", "i", "++", ")", "{", "MethodBinding", "current", "=", "moreSpecific", "[", "i", "]", ";", "if", "(", "current", "!=", "null", ")", "{", "ReferenceBinding", "[", "]", "mostSpecificExceptions", "=", "null", ";", "MethodBinding", "original", "=", "current", ".", "original", "(", ")", ";", "boolean", "shouldIntersectExceptions", "=", "original", ".", "declaringClass", ".", "isAbstract", "(", ")", "&&", "original", ".", "thrownExceptions", "!=", "Binding", ".", "NO_EXCEPTIONS", ";", "for", "(", "int", "j", "=", "0", ";", "j", "<", "visibleSize", ";", "j", "++", ")", "{", "MethodBinding", "next", "=", "moreSpecific", "[", "j", "]", ";", "if", "(", "next", "==", "null", "||", "i", "==", "j", ")", "continue", ";", "MethodBinding", "original2", "=", "next", ".", "original", "(", ")", ";", "if", "(", "original", ".", "declaringClass", "==", "original2", ".", "declaringClass", ")", "break", "nextSpecific", ";", "if", "(", "!", "original", ".", "isAbstract", "(", ")", ")", "{", "if", "(", "original2", ".", "isAbstract", "(", ")", ")", "continue", ";", "original2", "=", "original", ".", "findOriginalInheritedMethod", "(", "original2", ")", ";", "if", "(", "original2", "==", "null", ")", "continue", "nextSpecific", ";", "if", "(", "current", ".", "hasSubstitutedParameters", "(", ")", "||", "original", ".", "typeVariables", "!=", "Binding", ".", "NO_TYPE_VARIABLES", ")", "{", "if", "(", "!", "environment", "(", ")", ".", "methodVerifier", "(", ")", ".", "isParameterSubsignature", "(", "original", ",", "original2", ")", ")", "continue", "nextSpecific", ";", "}", "}", "else", "if", "(", "receiverType", "!=", "null", ")", "{", "TypeBinding", "superType", "=", "receiverType", ".", "findSuperTypeOriginatingFrom", "(", "original", ".", "declaringClass", ".", "erasure", "(", ")", ")", ";", "if", "(", "original", ".", "declaringClass", "==", "superType", "||", "!", "(", "superType", "instanceof", "ReferenceBinding", ")", ")", "{", "}", "else", "{", "MethodBinding", "[", "]", "superMethods", "=", "(", "(", "ReferenceBinding", ")", "superType", ")", ".", "getMethods", "(", "original", ".", "selector", ",", "argumentTypes", ".", "length", ")", ";", "for", "(", "int", "m", "=", "0", ",", "l", "=", "superMethods", ".", "length", ";", "m", "<", "l", ";", "m", "++", ")", "{", "if", "(", "superMethods", "[", "m", "]", ".", "original", "(", ")", "==", "original", ")", "{", "original", "=", "superMethods", "[", "m", "]", ";", "break", ";", "}", "}", "}", "superType", "=", "receiverType", ".", "findSuperTypeOriginatingFrom", "(", "original2", ".", "declaringClass", ".", "erasure", "(", ")", ")", ";", "if", "(", "original2", ".", "declaringClass", "==", "superType", "||", "!", "(", "superType", "instanceof", "ReferenceBinding", ")", ")", "{", "}", "else", "{", "MethodBinding", "[", "]", "superMethods", "=", "(", "(", "ReferenceBinding", ")", "superType", ")", ".", "getMethods", "(", "original2", ".", "selector", ",", "argumentTypes", ".", "length", ")", ";", "for", "(", "int", "m", "=", "0", ",", "l", "=", "superMethods", ".", "length", ";", "m", "<", "l", ";", "m", "++", ")", "{", "if", "(", "superMethods", "[", "m", "]", ".", "original", "(", ")", "==", "original2", ")", "{", "original2", "=", "superMethods", "[", "m", "]", ";", "break", ";", "}", "}", "}", "if", "(", "original", ".", "typeVariables", "!=", "Binding", ".", "NO_TYPE_VARIABLES", ")", "original2", "=", "original", ".", "computeSubstitutedMethod", "(", "original2", ",", "environment", "(", ")", ")", ";", "if", "(", "original2", "==", "null", "||", "!", "original", ".", "areParameterErasuresEqual", "(", "original2", ")", ")", "continue", "nextSpecific", ";", "if", "(", "original", ".", "returnType", "!=", "original2", ".", "returnType", ")", "{", "if", "(", "next", ".", "original", "(", ")", ".", "typeVariables", "!=", "Binding", ".", "NO_TYPE_VARIABLES", ")", "{", "if", "(", "original", ".", "returnType", ".", "erasure", "(", ")", ".", "findSuperTypeOriginatingFrom", "(", "original2", ".", "returnType", ".", "erasure", "(", ")", ")", "==", "null", ")", "continue", "nextSpecific", ";", "}", "else", "if", "(", "!", "current", ".", "returnType", ".", "isCompatibleWith", "(", "next", ".", "returnType", ")", ")", "{", "continue", "nextSpecific", ";", "}", "}", "if", "(", "shouldIntersectExceptions", "&&", "original2", ".", "declaringClass", ".", "isInterface", "(", ")", ")", "{", "if", "(", "current", ".", "thrownExceptions", "!=", "next", ".", "thrownExceptions", ")", "{", "if", "(", "next", ".", "thrownExceptions", "==", "Binding", ".", "NO_EXCEPTIONS", ")", "{", "mostSpecificExceptions", "=", "Binding", ".", "NO_EXCEPTIONS", ";", "}", "else", "{", "if", "(", "mostSpecificExceptions", "==", "null", ")", "{", "mostSpecificExceptions", "=", "current", ".", "thrownExceptions", ";", "}", "int", "mostSpecificLength", "=", "mostSpecificExceptions", ".", "length", ";", "int", "nextLength", "=", "next", ".", "thrownExceptions", ".", "length", ";", "SimpleSet", "temp", "=", "new", "SimpleSet", "(", "mostSpecificLength", ")", ";", "boolean", "changed", "=", "false", ";", "nextException", ":", "for", "(", "int", "t", "=", "0", ";", "t", "<", "mostSpecificLength", ";", "t", "++", ")", "{", "ReferenceBinding", "exception", "=", "mostSpecificExceptions", "[", "t", "]", ";", "for", "(", "int", "s", "=", "0", ";", "s", "<", "nextLength", ";", "s", "++", ")", "{", "ReferenceBinding", "nextException", "=", "next", ".", "thrownExceptions", "[", "s", "]", ";", "if", "(", "exception", ".", "isCompatibleWith", "(", "nextException", ")", ")", "{", "temp", ".", "add", "(", "exception", ")", ";", "continue", "nextException", ";", "}", "else", "if", "(", "nextException", ".", "isCompatibleWith", "(", "exception", ")", ")", "{", "temp", ".", "add", "(", "nextException", ")", ";", "changed", "=", "true", ";", "continue", "nextException", ";", "}", "else", "{", "changed", "=", "true", ";", "}", "}", "}", "if", "(", "changed", ")", "{", "mostSpecificExceptions", "=", "temp", ".", "elementSize", "==", "0", "?", "Binding", ".", "NO_EXCEPTIONS", ":", "new", "ReferenceBinding", "[", "temp", ".", "elementSize", "]", ";", "temp", ".", "asArray", "(", "mostSpecificExceptions", ")", ";", "}", "}", "}", "}", "}", "}", "if", "(", "mostSpecificExceptions", "!=", "null", "&&", "mostSpecificExceptions", "!=", "current", ".", "thrownExceptions", ")", "{", "return", "new", "MostSpecificExceptionMethodBinding", "(", "current", ",", "mostSpecificExceptions", ")", ";", "}", "return", "current", ";", "}", "}", "return", "new", "ProblemMethodBinding", "(", "visible", "[", "0", "]", ",", "visible", "[", "0", "]", ".", "selector", ",", "visible", "[", "0", "]", ".", "parameters", ",", "ProblemReasons", ".", "Ambiguous", ")", ";", "}", "public", "final", "ClassScope", "outerMostClassScope", "(", ")", "{", "ClassScope", "lastClassScope", "=", "null", ";", "Scope", "scope", "=", "this", ";", "do", "{", "if", "(", "scope", "instanceof", "ClassScope", ")", "lastClassScope", "=", "(", "ClassScope", ")", "scope", ";", "scope", "=", "scope", ".", "parent", ";", "}", "while", "(", "scope", "!=", "null", ")", ";", "return", "lastClassScope", ";", "}", "public", "final", "MethodScope", "outerMostMethodScope", "(", ")", "{", "MethodScope", "lastMethodScope", "=", "null", ";", "Scope", "scope", "=", "this", ";", "do", "{", "if", "(", "scope", "instanceof", "MethodScope", ")", "lastMethodScope", "=", "(", "MethodScope", ")", "scope", ";", "scope", "=", "scope", ".", "parent", ";", "}", "while", "(", "scope", "!=", "null", ")", ";", "return", "lastMethodScope", ";", "}", "public", "int", "parameterCompatibilityLevel", "(", "MethodBinding", "method", ",", "TypeBinding", "[", "]", "arguments", ")", "{", "TypeBinding", "[", "]", "parameters", "=", "method", ".", "parameters", ";", "int", "paramLength", "=", "parameters", ".", "length", ";", "int", "argLength", "=", "arguments", ".", "length", ";", "if", "(", "compilerOptions", "(", ")", ".", "sourceLevel", "<", "ClassFileConstants", ".", "JDK1_5", ")", "{", "if", "(", "paramLength", "!=", "argLength", ")", "return", "NOT_COMPATIBLE", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "argLength", ";", "i", "++", ")", "{", "TypeBinding", "param", "=", "parameters", "[", "i", "]", ";", "TypeBinding", "arg", "=", "arguments", "[", "i", "]", ";", "if", "(", "arg", "!=", "param", "&&", "!", "arg", ".", "isCompatibleWith", "(", "param", ")", ")", "return", "NOT_COMPATIBLE", ";", "}", "return", "COMPATIBLE", ";", "}", "int", "level", "=", "COMPATIBLE", ";", "int", "lastIndex", "=", "argLength", ";", "LookupEnvironment", "env", "=", "environment", "(", ")", ";", "if", "(", "method", ".", "isVarargs", "(", ")", ")", "{", "lastIndex", "=", "paramLength", "-", "1", ";", "if", "(", "paramLength", "==", "argLength", ")", "{", "TypeBinding", "param", "=", "parameters", "[", "lastIndex", "]", ";", "TypeBinding", "arg", "=", "arguments", "[", "lastIndex", "]", ";", "if", "(", "param", "!=", "arg", ")", "{", "level", "=", "parameterCompatibilityLevel", "(", "arg", ",", "param", ",", "env", ")", ";", "if", "(", "level", "==", "NOT_COMPATIBLE", ")", "{", "param", "=", "(", "(", "ArrayBinding", ")", "param", ")", ".", "elementsType", "(", ")", ";", "if", "(", "parameterCompatibilityLevel", "(", "arg", ",", "param", ",", "env", ")", "==", "NOT_COMPATIBLE", ")", "return", "NOT_COMPATIBLE", ";", "level", "=", "VARARGS_COMPATIBLE", ";", "}", "}", "}", "else", "{", "if", "(", "paramLength", "<", "argLength", ")", "{", "TypeBinding", "param", "=", "(", "(", "ArrayBinding", ")", "parameters", "[", "lastIndex", "]", ")", ".", "elementsType", "(", ")", ";", "for", "(", "int", "i", "=", "lastIndex", ";", "i", "<", "argLength", ";", "i", "++", ")", "{", "TypeBinding", "arg", "=", "arguments", "[", "i", "]", ";", "if", "(", "param", "!=", "arg", "&&", "parameterCompatibilityLevel", "(", "arg", ",", "param", ",", "env", ")", "==", "NOT_COMPATIBLE", ")", "return", "NOT_COMPATIBLE", ";", "}", "}", "else", "if", "(", "lastIndex", "!=", "argLength", ")", "{", "return", "NOT_COMPATIBLE", ";", "}", "level", "=", "VARARGS_COMPATIBLE", ";", "}", "}", "else", "if", "(", "paramLength", "!=", "argLength", ")", "{", "return", "NOT_COMPATIBLE", ";", "}", "for", "(", "int", "i", "=", "0", ";", "i", "<", "lastIndex", ";", "i", "++", ")", "{", "TypeBinding", "param", "=", "parameters", "[", "i", "]", ";", "TypeBinding", "arg", "=", "arguments", "[", "i", "]", ";", "if", "(", "arg", "!=", "param", ")", "{", "int", "newLevel", "=", "parameterCompatibilityLevel", "(", "arg", ",", "param", ",", "env", ")", ";", "if", "(", "newLevel", "==", "NOT_COMPATIBLE", ")", "return", "NOT_COMPATIBLE", ";", "if", "(", "newLevel", ">", "level", ")", "level", "=", "newLevel", ";", "}", "}", "return", "level", ";", "}", "private", "int", "parameterCompatibilityLevel", "(", "TypeBinding", "arg", ",", "TypeBinding", "param", ",", "LookupEnvironment", "env", ")", "{", "if", "(", "arg", ".", "isCompatibleWith", "(", "param", ")", ")", "return", "COMPATIBLE", ";", "if", "(", "arg", ".", "isBaseType", "(", ")", "!=", "param", ".", "isBaseType", "(", ")", ")", "{", "TypeBinding", "convertedType", "=", "env", ".", "computeBoxingType", "(", "arg", ")", ";", "if", "(", "convertedType", "==", "param", "||", "convertedType", ".", "isCompatibleWith", "(", "param", ")", ")", "return", "AUTOBOX_COMPATIBLE", ";", "}", "return", "NOT_COMPATIBLE", ";", "}", "public", "abstract", "ProblemReporter", "problemReporter", "(", ")", ";", "public", "final", "CompilationUnitDeclaration", "referenceCompilationUnit", "(", ")", "{", "Scope", "scope", ",", "unitScope", "=", "this", ";", "while", "(", "(", "scope", "=", "unitScope", ".", "parent", ")", "!=", "null", ")", "unitScope", "=", "scope", ";", "return", "(", "(", "CompilationUnitScope", ")", "unitScope", ")", ".", "referenceContext", ";", "}", "public", "ReferenceContext", "referenceContext", "(", ")", "{", "Scope", "current", "=", "this", ";", "do", "{", "switch", "(", "current", ".", "kind", ")", "{", "case", "METHOD_SCOPE", ":", "return", "(", "(", "MethodScope", ")", "current", ")", ".", "referenceContext", ";", "case", "CLASS_SCOPE", ":", "return", "(", "(", "ClassScope", ")", "current", ")", ".", "referenceContext", ";", "case", "COMPILATION_UNIT_SCOPE", ":", "return", "(", "(", "CompilationUnitScope", ")", "current", ")", ".", "referenceContext", ";", "}", "}", "while", "(", "(", "current", "=", "current", ".", "parent", ")", "!=", "null", ")", ";", "return", "null", ";", "}", "public", "void", "deferBoundCheck", "(", "TypeReference", "typeRef", ")", "{", "if", "(", "this", ".", "kind", "==", "CLASS_SCOPE", ")", "{", "ClassScope", "classScope", "=", "(", "ClassScope", ")", "this", ";", "if", "(", "classScope", ".", "deferredBoundChecks", "==", "null", ")", "{", "classScope", ".", "deferredBoundChecks", "=", "new", "ArrayList", "(", "3", ")", ";", "classScope", ".", "deferredBoundChecks", ".", "add", "(", "typeRef", ")", ";", "}", "else", "if", "(", "!", "classScope", ".", "deferredBoundChecks", ".", "contains", "(", "typeRef", ")", ")", "{", "classScope", ".", "deferredBoundChecks", ".", "add", "(", "typeRef", ")", ";", "}", "}", "}", "int", "startIndex", "(", ")", "{", "return", "0", ";", "}", "}", "</s>" ]
5,596
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "*", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "Constant", ";", "public", "class", "ElementValuePair", "{", "char", "[", "]", "name", ";", "public", "Object", "value", ";", "public", "MethodBinding", "binding", ";", "public", "static", "Object", "getValue", "(", "Expression", "expression", ")", "{", "if", "(", "expression", "==", "null", ")", "return", "null", ";", "Constant", "constant", "=", "expression", ".", "constant", ";", "if", "(", "constant", "!=", "null", "&&", "constant", "!=", "Constant", ".", "NotAConstant", ")", "return", "constant", ";", "if", "(", "expression", "instanceof", "Annotation", ")", "return", "(", "(", "Annotation", ")", "expression", ")", ".", "getCompilerAnnotation", "(", ")", ";", "if", "(", "expression", "instanceof", "ArrayInitializer", ")", "{", "Expression", "[", "]", "exprs", "=", "(", "(", "ArrayInitializer", ")", "expression", ")", ".", "expressions", ";", "int", "length", "=", "exprs", "==", "null", "?", "0", ":", "exprs", ".", "length", ";", "Object", "[", "]", "values", "=", "new", "Object", "[", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "values", "[", "i", "]", "=", "getValue", "(", "exprs", "[", "i", "]", ")", ";", "return", "values", ";", "}", "if", "(", "expression", "instanceof", "ClassLiteralAccess", ")", "return", "(", "(", "ClassLiteralAccess", ")", "expression", ")", ".", "targetType", ";", "if", "(", "expression", "instanceof", "Reference", ")", "{", "FieldBinding", "fieldBinding", "=", "null", ";", "if", "(", "expression", "instanceof", "FieldReference", ")", "{", "fieldBinding", "=", "(", "(", "FieldReference", ")", "expression", ")", ".", "fieldBinding", "(", ")", ";", "}", "else", "if", "(", "expression", "instanceof", "NameReference", ")", "{", "Binding", "binding", "=", "(", "(", "NameReference", ")", "expression", ")", ".", "binding", ";", "if", "(", "binding", "!=", "null", "&&", "binding", ".", "kind", "(", ")", "==", "Binding", ".", "FIELD", ")", "fieldBinding", "=", "(", "FieldBinding", ")", "binding", ";", "}", "if", "(", "fieldBinding", "!=", "null", "&&", "(", "fieldBinding", ".", "modifiers", "&", "ClassFileConstants", ".", "AccEnum", ")", ">", "0", ")", "return", "fieldBinding", ";", "}", "return", "null", ";", "}", "public", "ElementValuePair", "(", "char", "[", "]", "name", ",", "Expression", "expression", ",", "MethodBinding", "binding", ")", "{", "this", "(", "name", ",", "ElementValuePair", ".", "getValue", "(", "expression", ")", ",", "binding", ")", ";", "}", "public", "ElementValuePair", "(", "char", "[", "]", "name", ",", "Object", "value", ",", "MethodBinding", "binding", ")", "{", "this", ".", "name", "=", "name", ";", "this", ".", "value", "=", "value", ";", "this", ".", "binding", "=", "binding", ";", "}", "public", "char", "[", "]", "getName", "(", ")", "{", "return", "this", ".", "name", ";", "}", "public", "MethodBinding", "getMethodBinding", "(", ")", "{", "return", "this", ".", "binding", ";", "}", "public", "Object", "getValue", "(", ")", "{", "return", "this", ".", "value", ";", "}", "void", "setMethodBinding", "(", "MethodBinding", "binding", ")", "{", "this", ".", "binding", "=", "binding", ";", "}", "void", "setValue", "(", "Object", "value", ")", "{", "this", ".", "value", "=", "value", ";", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", "5", ")", ";", "buffer", ".", "append", "(", "this", ".", "name", ")", ".", "append", "(", "\"", "=", "\"", ")", ";", "buffer", ".", "append", "(", "this", ".", "value", ")", ";", "return", "buffer", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
5,597
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "public", "class", "NestedTypeBinding", "extends", "SourceTypeBinding", "{", "public", "SourceTypeBinding", "enclosingType", ";", "public", "SyntheticArgumentBinding", "[", "]", "enclosingInstances", ";", "private", "ReferenceBinding", "[", "]", "enclosingTypes", "=", "Binding", ".", "UNINITIALIZED_REFERENCE_TYPES", ";", "public", "SyntheticArgumentBinding", "[", "]", "outerLocalVariables", ";", "private", "int", "outerLocalVariablesSlotSize", "=", "-", "1", ";", "public", "NestedTypeBinding", "(", "char", "[", "]", "[", "]", "typeName", ",", "ClassScope", "scope", ",", "SourceTypeBinding", "enclosingType", ")", "{", "super", "(", "typeName", ",", "enclosingType", ".", "fPackage", ",", "scope", ")", ";", "this", ".", "tagBits", "|=", "(", "TagBits", ".", "IsNestedType", "|", "TagBits", ".", "ContainsNestedTypeReferences", ")", ";", "this", ".", "enclosingType", "=", "enclosingType", ";", "}", "public", "SyntheticArgumentBinding", "addSyntheticArgument", "(", "LocalVariableBinding", "actualOuterLocalVariable", ")", "{", "SyntheticArgumentBinding", "synthLocal", "=", "null", ";", "if", "(", "this", ".", "outerLocalVariables", "==", "null", ")", "{", "synthLocal", "=", "new", "SyntheticArgumentBinding", "(", "actualOuterLocalVariable", ")", ";", "this", ".", "outerLocalVariables", "=", "new", "SyntheticArgumentBinding", "[", "]", "{", "synthLocal", "}", ";", "}", "else", "{", "int", "size", "=", "this", ".", "outerLocalVariables", ".", "length", ";", "int", "newArgIndex", "=", "size", ";", "for", "(", "int", "i", "=", "size", ";", "--", "i", ">=", "0", ";", ")", "{", "if", "(", "this", ".", "outerLocalVariables", "[", "i", "]", ".", "actualOuterLocalVariable", "==", "actualOuterLocalVariable", ")", "return", "this", ".", "outerLocalVariables", "[", "i", "]", ";", "if", "(", "this", ".", "outerLocalVariables", "[", "i", "]", ".", "id", ">", "actualOuterLocalVariable", ".", "id", ")", "newArgIndex", "=", "i", ";", "}", "SyntheticArgumentBinding", "[", "]", "synthLocals", "=", "new", "SyntheticArgumentBinding", "[", "size", "+", "1", "]", ";", "System", ".", "arraycopy", "(", "this", ".", "outerLocalVariables", ",", "0", ",", "synthLocals", ",", "0", ",", "newArgIndex", ")", ";", "synthLocals", "[", "newArgIndex", "]", "=", "synthLocal", "=", "new", "SyntheticArgumentBinding", "(", "actualOuterLocalVariable", ")", ";", "System", ".", "arraycopy", "(", "this", ".", "outerLocalVariables", ",", "newArgIndex", ",", "synthLocals", ",", "newArgIndex", "+", "1", ",", "size", "-", "newArgIndex", ")", ";", "this", ".", "outerLocalVariables", "=", "synthLocals", ";", "}", "if", "(", "this", ".", "scope", ".", "referenceCompilationUnit", "(", ")", ".", "isPropagatingInnerClassEmulation", ")", "updateInnerEmulationDependents", "(", ")", ";", "return", "synthLocal", ";", "}", "public", "SyntheticArgumentBinding", "addSyntheticArgument", "(", "ReferenceBinding", "targetEnclosingType", ")", "{", "SyntheticArgumentBinding", "synthLocal", "=", "null", ";", "if", "(", "this", ".", "enclosingInstances", "==", "null", ")", "{", "synthLocal", "=", "new", "SyntheticArgumentBinding", "(", "targetEnclosingType", ")", ";", "this", ".", "enclosingInstances", "=", "new", "SyntheticArgumentBinding", "[", "]", "{", "synthLocal", "}", ";", "}", "else", "{", "int", "size", "=", "this", ".", "enclosingInstances", ".", "length", ";", "int", "newArgIndex", "=", "size", ";", "for", "(", "int", "i", "=", "size", ";", "--", "i", ">=", "0", ";", ")", "{", "if", "(", "this", ".", "enclosingInstances", "[", "i", "]", ".", "type", "==", "targetEnclosingType", ")", "return", "this", ".", "enclosingInstances", "[", "i", "]", ";", "if", "(", "enclosingType", "(", ")", "==", "targetEnclosingType", ")", "newArgIndex", "=", "0", ";", "}", "SyntheticArgumentBinding", "[", "]", "newInstances", "=", "new", "SyntheticArgumentBinding", "[", "size", "+", "1", "]", ";", "System", ".", "arraycopy", "(", "this", ".", "enclosingInstances", ",", "0", ",", "newInstances", ",", "newArgIndex", "==", "0", "?", "1", ":", "0", ",", "size", ")", ";", "newInstances", "[", "newArgIndex", "]", "=", "synthLocal", "=", "new", "SyntheticArgumentBinding", "(", "targetEnclosingType", ")", ";", "this", ".", "enclosingInstances", "=", "newInstances", ";", "}", "if", "(", "this", ".", "scope", ".", "referenceCompilationUnit", "(", ")", ".", "isPropagatingInnerClassEmulation", ")", "updateInnerEmulationDependents", "(", ")", ";", "return", "synthLocal", ";", "}", "public", "SyntheticArgumentBinding", "addSyntheticArgumentAndField", "(", "LocalVariableBinding", "actualOuterLocalVariable", ")", "{", "SyntheticArgumentBinding", "synthLocal", "=", "addSyntheticArgument", "(", "actualOuterLocalVariable", ")", ";", "if", "(", "synthLocal", "==", "null", ")", "return", "null", ";", "if", "(", "synthLocal", ".", "matchingField", "==", "null", ")", "synthLocal", ".", "matchingField", "=", "addSyntheticFieldForInnerclass", "(", "actualOuterLocalVariable", ")", ";", "return", "synthLocal", ";", "}", "public", "SyntheticArgumentBinding", "addSyntheticArgumentAndField", "(", "ReferenceBinding", "targetEnclosingType", ")", "{", "SyntheticArgumentBinding", "synthLocal", "=", "addSyntheticArgument", "(", "targetEnclosingType", ")", ";", "if", "(", "synthLocal", "==", "null", ")", "return", "null", ";", "if", "(", "synthLocal", ".", "matchingField", "==", "null", ")", "synthLocal", ".", "matchingField", "=", "addSyntheticFieldForInnerclass", "(", "targetEnclosingType", ")", ";", "return", "synthLocal", ";", "}", "public", "ReferenceBinding", "enclosingType", "(", ")", "{", "return", "this", ".", "enclosingType", ";", "}", "public", "int", "getEnclosingInstancesSlotSize", "(", ")", "{", "return", "this", ".", "enclosingInstances", "==", "null", "?", "0", ":", "this", ".", "enclosingInstances", ".", "length", ";", "}", "public", "int", "getOuterLocalVariablesSlotSize", "(", ")", "{", "if", "(", "this", ".", "outerLocalVariablesSlotSize", "<", "0", ")", "{", "this", ".", "outerLocalVariablesSlotSize", "=", "0", ";", "int", "outerLocalsCount", "=", "this", ".", "outerLocalVariables", "==", "null", "?", "0", ":", "this", ".", "outerLocalVariables", ".", "length", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "outerLocalsCount", ";", "i", "++", ")", "{", "SyntheticArgumentBinding", "argument", "=", "this", ".", "outerLocalVariables", "[", "i", "]", ";", "switch", "(", "argument", ".", "type", ".", "id", ")", "{", "case", "TypeIds", ".", "T_long", ":", "case", "TypeIds", ".", "T_double", ":", "this", ".", "outerLocalVariablesSlotSize", "+=", "2", ";", "break", ";", "default", ":", "this", ".", "outerLocalVariablesSlotSize", "++", ";", "break", ";", "}", "}", "}", "return", "this", ".", "outerLocalVariablesSlotSize", ";", "}", "public", "SyntheticArgumentBinding", "getSyntheticArgument", "(", "LocalVariableBinding", "actualOuterLocalVariable", ")", "{", "if", "(", "this", ".", "outerLocalVariables", "==", "null", ")", "return", "null", ";", "for", "(", "int", "i", "=", "this", ".", "outerLocalVariables", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "this", ".", "outerLocalVariables", "[", "i", "]", ".", "actualOuterLocalVariable", "==", "actualOuterLocalVariable", ")", "return", "this", ".", "outerLocalVariables", "[", "i", "]", ";", "return", "null", ";", "}", "public", "SyntheticArgumentBinding", "getSyntheticArgument", "(", "ReferenceBinding", "targetEnclosingType", ",", "boolean", "onlyExactMatch", ")", "{", "if", "(", "this", ".", "enclosingInstances", "==", "null", ")", "return", "null", ";", "for", "(", "int", "i", "=", "this", ".", "enclosingInstances", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "this", ".", "enclosingInstances", "[", "i", "]", ".", "type", "==", "targetEnclosingType", ")", "if", "(", "this", ".", "enclosingInstances", "[", "i", "]", ".", "actualOuterLocalVariable", "==", "null", ")", "return", "this", ".", "enclosingInstances", "[", "i", "]", ";", "if", "(", "!", "onlyExactMatch", ")", "{", "for", "(", "int", "i", "=", "this", ".", "enclosingInstances", ".", "length", ";", "--", "i", ">=", "0", ";", ")", "if", "(", "this", ".", "enclosingInstances", "[", "i", "]", ".", "actualOuterLocalVariable", "==", "null", ")", "if", "(", "this", ".", "enclosingInstances", "[", "i", "]", ".", "type", ".", "findSuperTypeOriginatingFrom", "(", "targetEnclosingType", ")", "!=", "null", ")", "return", "this", ".", "enclosingInstances", "[", "i", "]", ";", "}", "return", "null", ";", "}", "public", "SyntheticArgumentBinding", "[", "]", "syntheticEnclosingInstances", "(", ")", "{", "return", "this", ".", "enclosingInstances", ";", "}", "public", "ReferenceBinding", "[", "]", "syntheticEnclosingInstanceTypes", "(", ")", "{", "if", "(", "this", ".", "enclosingTypes", "==", "UNINITIALIZED_REFERENCE_TYPES", ")", "{", "if", "(", "this", ".", "enclosingInstances", "==", "null", ")", "{", "this", ".", "enclosingTypes", "=", "null", ";", "}", "else", "{", "int", "length", "=", "this", ".", "enclosingInstances", ".", "length", ";", "this", ".", "enclosingTypes", "=", "new", "ReferenceBinding", "[", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "length", ";", "i", "++", ")", "{", "this", ".", "enclosingTypes", "[", "i", "]", "=", "(", "ReferenceBinding", ")", "this", ".", "enclosingInstances", "[", "i", "]", ".", "type", ";", "}", "}", "}", "return", "this", ".", "enclosingTypes", ";", "}", "public", "SyntheticArgumentBinding", "[", "]", "syntheticOuterLocalVariables", "(", ")", "{", "return", "this", ".", "outerLocalVariables", ";", "}", "public", "void", "updateInnerEmulationDependents", "(", ")", "{", "}", "}", "</s>" ]
5,598
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ASTNode", ";", "public", "abstract", "class", "Binding", "{", "public", "static", "final", "int", "FIELD", "=", "ASTNode", ".", "Bit1", ";", "public", "static", "final", "int", "LOCAL", "=", "ASTNode", ".", "Bit2", ";", "public", "static", "final", "int", "VARIABLE", "=", "FIELD", "|", "LOCAL", ";", "public", "static", "final", "int", "TYPE", "=", "ASTNode", ".", "Bit3", ";", "public", "static", "final", "int", "METHOD", "=", "ASTNode", ".", "Bit4", ";", "public", "static", "final", "int", "PACKAGE", "=", "ASTNode", ".", "Bit5", ";", "public", "static", "final", "int", "IMPORT", "=", "ASTNode", ".", "Bit6", ";", "public", "static", "final", "int", "ARRAY_TYPE", "=", "TYPE", "|", "ASTNode", ".", "Bit7", ";", "public", "static", "final", "int", "BASE_TYPE", "=", "TYPE", "|", "ASTNode", ".", "Bit8", ";", "public", "static", "final", "int", "PARAMETERIZED_TYPE", "=", "TYPE", "|", "ASTNode", ".", "Bit9", ";", "public", "static", "final", "int", "WILDCARD_TYPE", "=", "TYPE", "|", "ASTNode", ".", "Bit10", ";", "public", "static", "final", "int", "RAW_TYPE", "=", "TYPE", "|", "ASTNode", ".", "Bit11", ";", "public", "static", "final", "int", "GENERIC_TYPE", "=", "TYPE", "|", "ASTNode", ".", "Bit12", ";", "public", "static", "final", "int", "TYPE_PARAMETER", "=", "TYPE", "|", "ASTNode", ".", "Bit13", ";", "public", "static", "final", "int", "INTERSECTION_TYPE", "=", "TYPE", "|", "ASTNode", ".", "Bit14", ";", "public", "static", "final", "TypeBinding", "[", "]", "NO_TYPES", "=", "new", "TypeBinding", "[", "0", "]", ";", "public", "static", "final", "TypeBinding", "[", "]", "NO_PARAMETERS", "=", "new", "TypeBinding", "[", "0", "]", ";", "public", "static", "final", "ReferenceBinding", "[", "]", "NO_EXCEPTIONS", "=", "new", "ReferenceBinding", "[", "0", "]", ";", "public", "static", "final", "ReferenceBinding", "[", "]", "ANY_EXCEPTION", "=", "new", "ReferenceBinding", "[", "]", "{", "null", "}", ";", "public", "static", "final", "FieldBinding", "[", "]", "NO_FIELDS", "=", "new", "FieldBinding", "[", "0", "]", ";", "public", "static", "final", "MethodBinding", "[", "]", "NO_METHODS", "=", "new", "MethodBinding", "[", "0", "]", ";", "public", "static", "final", "ReferenceBinding", "[", "]", "NO_SUPERINTERFACES", "=", "new", "ReferenceBinding", "[", "0", "]", ";", "public", "static", "final", "ReferenceBinding", "[", "]", "NO_MEMBER_TYPES", "=", "new", "ReferenceBinding", "[", "0", "]", ";", "public", "static", "final", "TypeVariableBinding", "[", "]", "NO_TYPE_VARIABLES", "=", "new", "TypeVariableBinding", "[", "0", "]", ";", "public", "static", "final", "AnnotationBinding", "[", "]", "NO_ANNOTATIONS", "=", "new", "AnnotationBinding", "[", "0", "]", ";", "public", "static", "final", "ElementValuePair", "[", "]", "NO_ELEMENT_VALUE_PAIRS", "=", "new", "ElementValuePair", "[", "0", "]", ";", "public", "static", "final", "FieldBinding", "[", "]", "UNINITIALIZED_FIELDS", "=", "new", "FieldBinding", "[", "0", "]", ";", "public", "static", "final", "MethodBinding", "[", "]", "UNINITIALIZED_METHODS", "=", "new", "MethodBinding", "[", "0", "]", ";", "public", "static", "final", "ReferenceBinding", "[", "]", "UNINITIALIZED_REFERENCE_TYPES", "=", "new", "ReferenceBinding", "[", "0", "]", ";", "public", "abstract", "int", "kind", "(", ")", ";", "public", "char", "[", "]", "computeUniqueKey", "(", ")", "{", "return", "computeUniqueKey", "(", "true", ")", ";", "}", "public", "char", "[", "]", "computeUniqueKey", "(", "boolean", "isLeaf", ")", "{", "return", "null", ";", "}", "public", "long", "getAnnotationTagBits", "(", ")", "{", "return", "0", ";", "}", "public", "void", "initializeDeprecatedAnnotationTagBits", "(", ")", "{", "}", "public", "final", "boolean", "isValidBinding", "(", ")", "{", "return", "problemId", "(", ")", "==", "ProblemReasons", ".", "NoError", ";", "}", "public", "int", "problemId", "(", ")", "{", "return", "ProblemReasons", ".", "NoError", ";", "}", "public", "abstract", "char", "[", "]", "readableName", "(", ")", ";", "public", "char", "[", "]", "shortReadableName", "(", ")", "{", "return", "readableName", "(", ")", ";", "}", "}", "</s>" ]
5,599
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ";", "public", "class", "MostSpecificExceptionMethodBinding", "extends", "MethodBinding", "{", "private", "MethodBinding", "originalMethod", ";", "public", "MostSpecificExceptionMethodBinding", "(", "MethodBinding", "originalMethod", ",", "ReferenceBinding", "[", "]", "mostSpecificExceptions", ")", "{", "super", "(", "originalMethod", ".", "modifiers", ",", "originalMethod", ".", "selector", ",", "originalMethod", ".", "returnType", ",", "originalMethod", ".", "parameters", ",", "mostSpecificExceptions", ",", "originalMethod", ".", "declaringClass", ")", ";", "this", ".", "originalMethod", "=", "originalMethod", ";", "}", "public", "MethodBinding", "original", "(", ")", "{", "return", "this", ".", "originalMethod", ".", "original", "(", ")", ";", "}", "}", "</s>" ]