public ArchiveFileObject getArchiveFileObject(String entryName, Charset charset) { return new ArchiveFileObject(this.file, entryName, charset); }
@Override public CharSequence getCharContent(boolean ignoreEncodingErrors) throws IOException { if (getKind() == Kind.SOURCE) { try (ZipFile zipFile2 = new ZipFile(this.file)) { ZipEntry zipEntry = zipFile2.getEntry(this.entryName); return Util.getCharContents(this, ignoreEncodingErrors, org.eclipse.jdt.internal.compiler.util.Util.getZipEntryByteContent(zipEntry, zipFile2), this.charset.name()); } } return null; }
@Override public Modifier getAccessLevel() { // cannot express multiple modifier if (getKind() != Kind.CLASS) { return null; } ClassFileReader reader = getClassReader(); if (reader == null) { return null; } final int accessFlags = reader.accessFlags(); if ((accessFlags & ClassFileConstants.AccPublic) != 0) { return Modifier.PUBLIC; } if ((accessFlags & ClassFileConstants.AccAbstract) != 0) { return Modifier.ABSTRACT; } if ((accessFlags & ClassFileConstants.AccFinal) != 0) { return Modifier.FINAL; } return null; }
@Override public CharSequence getCharContent(boolean ignoreEncodingErrors) throws IOException { if (getKind() == Kind.SOURCE) { try (ZipFile zipFile2 = new ZipFile(this.file)) { ZipEntry zipEntry = zipFile2.getEntry(this.entryName); return Util.getCharContents(this, ignoreEncodingErrors, org.eclipse.jdt.internal.compiler.util.Util.getZipEntryByteContent(zipEntry, zipFile2), this.charset.name()); } } return null; }
@Override public NestingKind getNestingKind() { switch(getKind()) { case SOURCE : return NestingKind.TOP_LEVEL; case CLASS : ClassFileReader reader = getClassReader(); if (reader == null) { return null; } if (reader.isAnonymous()) { return NestingKind.ANONYMOUS; } if (reader.isLocal()) { return NestingKind.LOCAL; } if (reader.isMember()) { return NestingKind.MEMBER; } return NestingKind.TOP_LEVEL; default: return null; } }
@Override public CharSequence getCharContent(boolean ignoreEncodingErrors) throws IOException { if (getKind() == Kind.SOURCE) { try (ZipFile zipFile2 = new ZipFile(this.file)) { ZipEntry zipEntry = zipFile2.getEntry(this.entryName); return Util.getCharContents(this, ignoreEncodingErrors, org.eclipse.jdt.internal.compiler.util.Util.getZipEntryByteContent(zipEntry, zipFile2), this.charset.name()); } } return null; }
public ArchiveFileObject getArchiveFileObject(String fileName, String module, Charset charset) { return new ArchiveFileObject(this.file, fileName, charset); }
public CharSequence getCharContent(boolean ignoreEncodingErrors) throws IOException { if (getKind() == Kind.SOURCE) { return Util.getCharContents(this, ignoreEncodingErrors, org.eclipse.jdt.internal.compiler.util.Util.getZipEntryByteContent(this.zipEntry, this.zipFile), this.charset.name()); } return null; }
public ArchiveFileObject getArchiveFileObject(String entryName, Charset charset) { return new ArchiveFileObject(this.file, this.zipFile, entryName, charset); }
public CharSequence getCharContent(boolean ignoreEncodingErrors) throws IOException { if (getKind() == Kind.SOURCE) { return Util.getCharContents(this, ignoreEncodingErrors, org.eclipse.jdt.internal.compiler.util.Util.getZipEntryByteContent(this.zipEntry, this.zipFile), this.charset.name()); } return null; }
public ArchiveFileObject getArchiveFileObject(String entryName, Charset charset) { return new ArchiveFileObject(this.file, entryName, charset); }
public CharSequence getCharContent(boolean ignoreEncodingErrors) throws IOException { if (getKind() == Kind.SOURCE) { return Util.getCharContents(this, ignoreEncodingErrors, org.eclipse.jdt.internal.compiler.util.Util.getZipEntryByteContent(this.zipEntry, this.zipFile), this.charset.toString()); } return null; }
public ArchiveFileObject getArchiveFileObject(String entryName, Charset charset) { return new ArchiveFileObject(this.file, this.zipFile, entryName, charset); }
@Override public Modifier getAccessLevel() { if (getKind() != Kind.CLASS) { return null;