Categories:
Audio (13)
Biotech (29)
Bytecode (36)
Database (77)
Framework (7)
Game (7)
General (507)
Graphics (53)
I/O (35)
IDE (2)
JAR Tools (101)
JavaBeans (21)
JDBC (121)
JDK (426)
JSP (20)
Logging (108)
Mail (58)
Messaging (8)
Network (84)
PDF (97)
Report (7)
Scripting (84)
Security (32)
Server (121)
Servlet (26)
SOAP (24)
Testing (54)
Web (15)
XML (309)
Collections:
Other Resources:
JDK 17 jdk.zipfs.jmod - ZIP FS Module
JDK 17 jdk.zipfs.jmod is the JMOD file for JDK 17 ZIP FS module.
JDK 17 ZIP FS module compiled class files are stored in \fyicenter\jdk-17.0.5\jmods\jdk.zipfs.jmod.
JDK 17 ZIP FS module compiled class files are also linked and stored in the \fyicenter\jdk-17.0.5\lib\modules JImage file.
JDK 17 ZIP FS module source code files are stored in \fyicenter\jdk-17.0.5\lib\src.zip\jdk.zipfs.
You can click and view the content of each source code file in the list below.
✍: FYIcenter
⏎ jdk/nio/zipfs/ZipFileAttributeView.java
/* * Copyright (c) 2009, 2019, Oracle and/or its affiliates. All rights reserved. * ORACLE PROPRIETARY/CONFIDENTIAL. Use is subject to license terms. * * * * * * * * * * * * * * * * * * * * */ package jdk.nio.zipfs; import java.io.IOException; import java.nio.file.attribute.BasicFileAttributeView; import java.nio.file.attribute.BasicFileAttributes; import java.nio.file.attribute.FileTime; import java.nio.file.attribute.PosixFilePermission; import java.util.LinkedHashMap; import java.util.Map; import java.util.Set; /** * @author Xueming Shen, Rajendra Gutupalli, Jaya Hangal */ class ZipFileAttributeView implements BasicFileAttributeView { static enum AttrID { size, creationTime, lastAccessTime, lastModifiedTime, isDirectory, isRegularFile, isSymbolicLink, isOther, fileKey, compressedSize, crc, method, owner, group, permissions } final ZipPath path; private final boolean isZipView; ZipFileAttributeView(ZipPath path, boolean isZipView) { this.path = path; this.isZipView = isZipView; } @Override public String name() { return isZipView ? "zip" : "basic"; } @Override public BasicFileAttributes readAttributes() throws IOException { return path.readAttributes(); } @Override public void setTimes(FileTime lastModifiedTime, FileTime lastAccessTime, FileTime createTime) throws IOException { path.setTimes(lastModifiedTime, lastAccessTime, createTime); } public void setPermissions(Set<PosixFilePermission> perms) throws IOException { path.setPermissions(perms); } @SuppressWarnings("unchecked") void setAttribute(String attribute, Object value) throws IOException { try { if (AttrID.valueOf(attribute) == AttrID.lastModifiedTime) setTimes((FileTime)value, null, null); if (AttrID.valueOf(attribute) == AttrID.lastAccessTime) setTimes(null, (FileTime)value, null); if (AttrID.valueOf(attribute) == AttrID.creationTime) setTimes(null, null, (FileTime)value); if (AttrID.valueOf(attribute) == AttrID.permissions) setPermissions((Set<PosixFilePermission>)value); } catch (IllegalArgumentException x) { throw new UnsupportedOperationException("'" + attribute + "' is unknown or read-only attribute"); } } Map<String, Object> readAttributes(String attributes) throws IOException { ZipFileAttributes zfas = (ZipFileAttributes)readAttributes(); LinkedHashMap<String, Object> map = new LinkedHashMap<>(); if ("*".equals(attributes)) { for (AttrID id : AttrID.values()) { try { map.put(id.name(), attribute(id, zfas)); } catch (IllegalArgumentException x) {} } } else { String[] as = attributes.split(","); for (String a : as) { try { map.put(a, attribute(AttrID.valueOf(a), zfas)); } catch (IllegalArgumentException x) {} } } return map; } Object attribute(AttrID id, ZipFileAttributes zfas) { switch (id) { case size: return zfas.size(); case creationTime: return zfas.creationTime(); case lastAccessTime: return zfas.lastAccessTime(); case lastModifiedTime: return zfas.lastModifiedTime(); case isDirectory: return zfas.isDirectory(); case isRegularFile: return zfas.isRegularFile(); case isSymbolicLink: return zfas.isSymbolicLink(); case isOther: return zfas.isOther(); case fileKey: return zfas.fileKey(); case compressedSize: if (isZipView) return zfas.compressedSize(); break; case crc: if (isZipView) return zfas.crc(); break; case method: if (isZipView) return zfas.method(); break; case permissions: if (isZipView) { return zfas.storedPermissions().orElse(null); } break; default: break; } return null; } }
⏎ jdk/nio/zipfs/ZipFileAttributeView.java
Or download all of them as a single archive file:
File name: jdk.zipfs-17.0.5-src.zip File size: 56454 bytes Release date: 2022-09-13 Download
⇒ FAQ for JDK (Java Development Kit) 17
2022-11-07, 757👍, 0💬
Popular Posts:
JDK 11 java.xml.crypto.jmod is the JMOD file for JDK 11 XML (eXtensible Markup Language) Crypto modu...
How to download and install ojdbc7.jar for Oracle 12c R1? ojdbc8.jar for Oracle 12c R1 is a Java 7 a...
pache Derby is an open source relational database implemented entirely in Java and available under t...
How to read XML document with DTD validation from socket connections with the socket\DelayedInput.ja.. .
What Is commons-io-2.11.jar? commons-io-2.11.jar is the JAR file for Commons IO 2.5, which is a libr...