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.jfr.jmod - JFR Module
JDK 17 jdk.jfr.jmod is the JMOD file for JDK 17 JFR module.
JDK 17 JFR module compiled class files are stored in \fyicenter\jdk-17.0.5\jmods\jdk.jfr.jmod.
JDK 17 JFR module compiled class files are also linked and stored in the \fyicenter\jdk-17.0.5\lib\modules JImage file.
JDK 17 JFR module source code files are stored in \fyicenter\jdk-17.0.5\lib\src.zip\jdk.jfr.
You can click and view the content of each source code file in the list below.
✍: FYIcenter
⏎ jdk/jfr/internal/jfc/model/Utilities.java
/* * Copyright (c) 2021, Oracle and/or its affiliates. All rights reserved. * ORACLE PROPRIETARY/CONFIDENTIAL. Use is subject to license terms. * * * * * * * * * * * * * * * * * * * * */ package jdk.jfr.internal.jfc.model; import java.util.StringJoiner; public final class Utilities { private static final String[] UNITS = new String[] { "ns", "us", "ns", "ms", "s", "m", "h", "d" // order matters }; static XmlElement instantiate(Class<? extends XmlElement> type) { try { return type.getDeclaredConstructor().newInstance(); } catch (Exception e) { throw new InternalError("Unable to instantiate " + type, e); } } static String elementName(Class<? extends XmlElement> type) { String name = type.getSimpleName(); if (name.startsWith("Xml") && name.length() > 3) { return name.substring(3).toLowerCase(); } throw new InternalError("Unexpected class " + type); } static String escapeAll(String text) { StringBuilder s = new StringBuilder(); for (int i = 0; i < text.length(); i++) { addCharacter(s, text.charAt(i)); } return s.toString(); } private static void addCharacter(StringBuilder s, char c) { if (c == 34) { s.append("""); return; } if (c == 38) { s.append("&"); return; } if (c == 39) { s.append("'"); return; } if (c == 60) { s.append("<"); return; } if (c == 62) { s.append(">"); return; } if (c > 0x7F) { s.append("&#"); s.append((int) c); s.append(';'); return; } s.append(c); } static void checkValid(String value, Object... valid) { StringJoiner sj = new StringJoiner(", "); for (Object v : valid) { if (v.equals(value)) { return; } sj.add("'" + v + "'"); } String msg = "Incorrect value '" + value + "'. Valid values are " + sj.toString() + "."; int index = msg.lastIndexOf(","); if (index != -1) { msg = msg.substring(0, index) + " and" + msg.substring(index + 1); } throw new IllegalArgumentException(msg); } static String parseTimespan(String s) { StringBuilder sb = new StringBuilder(); try { for (String unit : UNITS) { if (s.endsWith(unit)) { return parseForUnit(s, unit); } } Long.parseLong(s); sb.append("Timespan '" + s + "' is missing unit."); } catch (NumberFormatException nfe) { sb.append("'" + s + "' is not a valid timespan." + System.lineSeparator()); sb.append("Should be numeric value followed by a unit, i.e. 20 ms."); } sb.append(" Valid units are ns, us, ms, s, m, h and d."); throw new IllegalArgumentException(sb.toString()); } private static String parseForUnit(String s, String unit) { String number = s.trim().substring(0, s.length() - unit.length()); return Long.parseLong(number.trim()) + " " + unit; } }
⏎ jdk/jfr/internal/jfc/model/Utilities.java
Or download all of them as a single archive file:
File name: jdk.jfr-17.0.5-src.zip File size: 363343 bytes Release date: 2022-09-13 Download
⇒ JDK 17 jdk.jlink.jmod - JLink Tool
2023-04-17, 8986👍, 0💬
Popular Posts:
What Is mail.jar of JavaMail 1.4? I got the JAR file from javamail-1_4.zip. mail.jar in javamail-1_4...
itextpdf.jar is a component in iText 5 Java library to provide core functionalities. iText Java libr...
JDK 11 jdk.internal.opt.jmod is the JMOD file for JDK 11 Internal Opt module. JDK 11 Internal Opt mo...
How to merge two JAR files with "jar" commands? I am tired of specifying multiple JAR files in the c...
What Is HttpComponents httpcore-4.4.6.jar? HttpComponents httpcore-4.4.6.jar is the JAR file for Apa...