private char[] getSourceForRootPath(String currentRootPath, String name) { String newFullName; if (!currentRootPath.equals(IPackageFragmentRoot.DEFAULT_PACKAGEROOT_PATH)) { if (currentRootPath.endsWith("/")) { //$NON-NLS-1$ newFullName = currentRootPath + name; } else { newFullName = currentRootPath + '/' + name; } } else { newFullName = name; } return this.findSource(newFullName); }
private char[] getSourceForRootPath(String currentRootPath, String name) { String newFullName; if (!currentRootPath.equals(IPackageFragmentRoot.DEFAULT_PACKAGEROOT_PATH)) { if (currentRootPath.endsWith("/")) { //$NON-NLS-1$ newFullName = currentRootPath + name; } else { newFullName = currentRootPath + '/' + name; } } else { newFullName = name; } return this.findSource(newFullName); }
private char[] getSourceForRootPath(String currentRootPath, String name) { String newFullName; if (!currentRootPath.equals(IPackageFragmentRoot.DEFAULT_PACKAGEROOT_PATH)) { if (currentRootPath.endsWith("/")) { //$NON-NLS-1$ newFullName = currentRootPath + name; } else { newFullName = currentRootPath + '/' + name; } } else { newFullName = name; } return this.findSource(newFullName); }
private char[] getSourceForRootPath(String currentRootPath, String name) { String newFullName; if (!currentRootPath.equals(IPackageFragmentRoot.DEFAULT_PACKAGEROOT_PATH)) { if (currentRootPath.endsWith("/")) { //$NON-NLS-1$ newFullName = currentRootPath + name; } else { newFullName = currentRootPath + '/' + name; } } else { newFullName = name; } return this.findSource(newFullName); }
private char[] getSourceForRootPath(String currentRootPath, String name) { String newFullName; if (!currentRootPath.equals(IPackageFragmentRoot.DEFAULT_PACKAGEROOT_PATH)) { if (currentRootPath.endsWith("/")) { //$NON-NLS-1$ newFullName = currentRootPath + name; } else { newFullName = currentRootPath + '/' + name; } } else { newFullName = name; } return this.findSource(newFullName); }
private char[] getSourceForRootPath(String currentRootPath, String name) { String newFullName; if (!currentRootPath.equals(IPackageFragmentRoot.DEFAULT_PACKAGEROOT_PATH)) { if (currentRootPath.endsWith("/")) { //$NON-NLS-1$ newFullName = currentRootPath + name; } else { newFullName = currentRootPath + '/' + name; } } else { newFullName = name; } return this.findSource(newFullName); }
/** * Locates and returns source code for the given (binary) type, in this * SourceMapper's ZIP file, or returns <code>null</code> if source * code cannot be found. */ public char[] findSource(IType type, IBinaryType info) { if (!type.isBinary()) { return null; } String simpleSourceFileName = ((BinaryType) type).getSourceFileName(info); if (simpleSourceFileName == null) { return null; } return findSource(type, simpleSourceFileName); }
/** * Locates and returns source code for the given (binary) type, in this * SourceMapper's ZIP file, or returns <code>null</code> if source * code cannot be found. */ public char[] findSource(IType type, IBinaryType info) { if (!type.isBinary()) { return null; } String simpleSourceFileName = ((BinaryType) type).getSourceFileName(info); if (simpleSourceFileName == null) { return null; } return findSource(type, simpleSourceFileName); }
/** * Locates and returns source code for the given (binary) type, in this * SourceMapper's ZIP file, or returns <code>null</code> if source * code cannot be found. */ public char[] findSource(IType type, IBinaryType info) { if (!type.isBinary()) { return null; } String simpleSourceFileName = ((BinaryType) type).getSourceFileName(info); if (simpleSourceFileName == null) { return null; } return findSource(type, simpleSourceFileName); }
/** * Locates and returns source code for the given (binary) type, in this * SourceMapper's ZIP file, or returns <code>null</code> if source * code cannot be found. */ public char[] findSource(IType type, IBinaryType info) { if (!type.isBinary()) { return null; } String simpleSourceFileName = ((BinaryType) type).getSourceFileName(info); if (simpleSourceFileName == null) { return null; } return findSource(type, simpleSourceFileName); }
/** * Locates and returns source code for the given (binary) type, in this * SourceMapper's ZIP file, or returns <code>null</code> if source * code cannot be found. */ public char[] findSource(IType type, IBinaryType info) { if (!type.isBinary()) { return null; } String simpleSourceFileName = ((BinaryType) type).getSourceFileName(info); if (simpleSourceFileName == null) { return null; } return findSource(type, simpleSourceFileName); }
/** * Locates and returns source code for the given (binary) type, in this * SourceMapper's ZIP file, or returns <code>null</code> if source * code cannot be found. */ public char[] findSource(IType type, IBinaryType info) { if (!type.isBinary()) { return null; } String simpleSourceFileName = ((BinaryType) type).getSourceFileName(info); if (simpleSourceFileName == null) { return null; } return findSource(type, simpleSourceFileName); }
public char[] getContents() { char[] contents = (this.source == NO_SOURCE_FILE) ? null : this.source; if (this.source == null) { if (this.openable instanceof ClassFile) { String fileName = getSourceFileName(); if (fileName == NO_SOURCE_FILE_NAME) return CharOperation.NO_CHAR; SourceMapper sourceMapper = this.openable.getSourceMapper(); if (sourceMapper != null) { IType type = ((ClassFile) this.openable).getType(); contents = sourceMapper.findSource(type, fileName); } } else { contents = this.document.getCharContents(); } this.source = (contents == null) ? NO_SOURCE_FILE : contents; } return contents; } /**
public char[] getContents() { char[] contents = (this.source == NO_SOURCE_FILE) ? null : this.source; if (this.source == null) { if (this.openable instanceof ClassFile) { String fileName = getSourceFileName(); if (fileName == NO_SOURCE_FILE_NAME) return CharOperation.NO_CHAR; SourceMapper sourceMapper = this.openable.getSourceMapper(); if (sourceMapper != null) { IType type = ((ClassFile) this.openable).getType(); contents = sourceMapper.findSource(type, fileName); } } else { contents = this.document.getCharContents(); } this.source = (contents == null) ? NO_SOURCE_FILE : contents; } return contents; } /**
public char[] getContents() { char[] contents = (this.source == NO_SOURCE_FILE) ? null : this.source; if (this.source == null) { if (this.openable instanceof ClassFile) { String fileName = getSourceFileName(); if (fileName == NO_SOURCE_FILE_NAME) return CharOperation.NO_CHAR; SourceMapper sourceMapper = this.openable.getSourceMapper(); if (sourceMapper != null) { IType type = ((ClassFile) this.openable).getType(); contents = sourceMapper.findSource(type, fileName); } } else { contents = this.document.getCharContents(); } this.source = (contents == null) ? NO_SOURCE_FILE : contents; } return contents; } /**
public char[] getContents() { char[] contents = (this.source == NO_SOURCE_FILE) ? null : this.source; if (this.source == null) { if (this.openable instanceof ClassFile) { String fileName = getSourceFileName(); if (fileName == NO_SOURCE_FILE_NAME) return CharOperation.NO_CHAR; SourceMapper sourceMapper = this.openable.getSourceMapper(); if (sourceMapper != null) { IType type = ((ClassFile) this.openable).getType(); contents = sourceMapper.findSource(type, fileName); } } else { contents = this.document.getCharContents(); } this.source = (contents == null) ? NO_SOURCE_FILE : contents; } return contents; } /**
protected void reportBinaryMemberDeclaration(IResource resource, IMember binaryMember, Binding binaryMemberBinding, IBinaryType info, int accuracy) throws CoreException { ClassFile classFile = (ClassFile) binaryMember.getClassFile(); ISourceRange range = classFile.isOpen() ? binaryMember.getNameRange() : SourceMapper.UNKNOWN_RANGE; if (range.getOffset() == -1) { BinaryType type = (BinaryType) classFile.getType(); String sourceFileName = type.sourceFileName(info); if (sourceFileName != null) { SourceMapper mapper = classFile.getSourceMapper(); if (mapper != null) { char[] contents = mapper.findSource(type, sourceFileName); if (contents != null) range = mapper.mapSource(type, contents, info, binaryMember); } } } if (resource == null) resource = this.currentPossibleMatch.resource; SearchMatch match = newDeclarationMatch(binaryMember, binaryMemberBinding, accuracy, range.getOffset(), range.getLength(), getParticipant(), resource); report(match); }
protected void reportBinaryMemberDeclaration(IResource resource, IMember binaryMember, Binding binaryMemberBinding, IBinaryType info, int accuracy) throws CoreException { ClassFile classFile = (ClassFile) binaryMember.getClassFile(); ISourceRange range = classFile.isOpen() ? binaryMember.getNameRange() : SourceMapper.UNKNOWN_RANGE; if (range.getOffset() == -1) { BinaryType type = (BinaryType) classFile.getType(); String sourceFileName = type.sourceFileName(info); if (sourceFileName != null) { SourceMapper mapper = classFile.getSourceMapper(); if (mapper != null) { char[] contents = mapper.findSource(type, sourceFileName); if (contents != null) range = mapper.mapSource(type, contents, info, binaryMember); } } } if (resource == null) resource = this.currentPossibleMatch.resource; SearchMatch match = newDeclarationMatch(binaryMember, binaryMemberBinding, accuracy, range.getOffset(), range.getLength(), getParticipant(), resource); report(match); }
protected void reportBinaryMemberDeclaration(IResource resource, IMember binaryMember, Binding binaryMemberBinding, IBinaryType info, int accuracy) throws CoreException { ClassFile classFile = (ClassFile) binaryMember.getClassFile(); ISourceRange range = classFile.isOpen() ? binaryMember.getNameRange() : SourceMapper.UNKNOWN_RANGE; if (range.getOffset() == -1) { BinaryType type = (BinaryType) classFile.getType(); String sourceFileName = type.sourceFileName(info); if (sourceFileName != null) { SourceMapper mapper = classFile.getSourceMapper(); if (mapper != null) { char[] contents = mapper.findSource(type, sourceFileName); if (contents != null) range = mapper.mapSource(type, contents, info, binaryMember); } } } if (resource == null) resource = this.currentPossibleMatch.resource; SearchMatch match = newDeclarationMatch(binaryMember, binaryMemberBinding, accuracy, range.getOffset(), range.getLength(), getParticipant(), resource); report(match); } protected void reportMatching(LambdaExpression lambdaExpression, IJavaElement parent, int accuracy, MatchingNodeSet nodeSet, boolean typeInHierarchy) throws CoreException {
protected void reportBinaryMemberDeclaration(IResource resource, IMember binaryMember, Binding binaryMemberBinding, IBinaryType info, int accuracy) throws CoreException { ClassFile classFile = (ClassFile) binaryMember.getClassFile(); ISourceRange range = classFile.isOpen() ? binaryMember.getNameRange() : SourceMapper.UNKNOWN_RANGE; if (range.getOffset() == -1) { BinaryType type = (BinaryType) classFile.getType(); String sourceFileName = type.sourceFileName(info); if (sourceFileName != null) { SourceMapper mapper = classFile.getSourceMapper(); if (mapper != null) { char[] contents = mapper.findSource(type, sourceFileName); if (contents != null) range = mapper.mapSource(type, contents, info, binaryMember); } } } if (resource == null) resource = this.currentPossibleMatch.resource; SearchMatch match = newDeclarationMatch(binaryMember, binaryMemberBinding, accuracy, range.getOffset(), range.getLength(), getParticipant(), resource); report(match); } protected void reportMatching(LambdaExpression lambdaExpression, IJavaElement parent, int accuracy, MatchingNodeSet nodeSet, boolean typeInHierarchy) throws CoreException {