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 11 java.desktop.jmod - Desktop Module
JDK 11 java.desktop.jmod is the JMOD file for JDK 11 Desktop module.
JDK 11 Desktop module compiled class files are stored in \fyicenter\jdk-11.0.1\jmods\java.desktop.jmod.
JDK 11 Desktop module compiled class files are also linked and stored in the \fyicenter\jdk-11.0.1\lib\modules JImage file.
JDK 11 Desktop module source code files are stored in \fyicenter\jdk-11.0.1\lib\src.zip\java.desktop.
You can click and view the content of each source code file in the list below.
✍: FYIcenter
⏎ com/sun/media/sound/AiffFileReader.java
/* * Copyright (c) 1999, 2016, Oracle and/or its affiliates. All rights reserved. * ORACLE PROPRIETARY/CONFIDENTIAL. Use is subject to license terms. * * * * * * * * * * * * * * * * * * * * */ package com.sun.media.sound; import java.io.DataInputStream; import java.io.IOException; import java.io.InputStream; import javax.sound.sampled.AudioFileFormat.Type; import javax.sound.sampled.AudioFormat; import javax.sound.sampled.AudioSystem; import javax.sound.sampled.UnsupportedAudioFileException; /** * AIFF file reader and writer. * * @author Kara Kytle * @author Jan Borgersen * @author Florian Bomers */ public final class AiffFileReader extends SunFileReader { @Override StandardFileFormat getAudioFileFormatImpl(final InputStream stream) throws UnsupportedAudioFileException, IOException { DataInputStream dis = new DataInputStream(stream); AudioFormat format = null; // Read the magic number int magic = dis.readInt(); // $$fb: fix for 4369044: javax.sound.sampled.AudioSystem.getAudioInputStream() works wrong with Cp037 if (magic != AiffFileFormat.AIFF_MAGIC) { // not AIFF, throw exception throw new UnsupportedAudioFileException("not an AIFF file"); } long /* unsigned 32bit */ frameLength = 0; int length = dis.readInt(); int iffType = dis.readInt(); final long totallength; if(length <= 0 ) { length = AudioSystem.NOT_SPECIFIED; totallength = AudioSystem.NOT_SPECIFIED; } else { totallength = length + 8; } // Is this an AIFC or just plain AIFF file. boolean aifc = false; // $$fb: fix for 4369044: javax.sound.sampled.AudioSystem.getAudioInputStream() works wrong with Cp037 if (iffType == AiffFileFormat.AIFC_MAGIC) { aifc = true; } // Loop through the AIFF chunks until // we get to the SSND chunk. boolean ssndFound = false; while (!ssndFound) { // Read the chunk name int chunkName = dis.readInt(); int chunkLen = dis.readInt(); int chunkRead = 0; // Switch on the chunk name. switch (chunkName) { case AiffFileFormat.FVER_MAGIC: // Ignore format version for now. break; case AiffFileFormat.COMM_MAGIC: // AIFF vs. AIFC // $$fb: fix for 4399551: Repost of bug candidate: cannot replay aif file (Review ID: 108108) if ((!aifc && chunkLen < 18) || (aifc && chunkLen < 22)) { throw new UnsupportedAudioFileException("Invalid AIFF/COMM chunksize"); } // Read header info. int channels = dis.readUnsignedShort(); if (channels <= 0) { throw new UnsupportedAudioFileException("Invalid number of channels"); } frameLength = dis.readInt() & 0xffffffffL; // numSampleFrames int sampleSizeInBits = dis.readUnsignedShort(); if (sampleSizeInBits < 1 || sampleSizeInBits > 32) { throw new UnsupportedAudioFileException("Invalid AIFF/COMM sampleSize"); } float sampleRate = (float) read_ieee_extended(dis); chunkRead += (2 + 4 + 2 + 10); // If this is not AIFC then we assume it's // a linearly encoded file. AudioFormat.Encoding encoding = AudioFormat.Encoding.PCM_SIGNED; if (aifc) { int enc = dis.readInt(); chunkRead += 4; switch (enc) { case AiffFileFormat.AIFC_PCM: encoding = AudioFormat.Encoding.PCM_SIGNED; break; case AiffFileFormat.AIFC_ULAW: encoding = AudioFormat.Encoding.ULAW; sampleSizeInBits = 8; // Java Sound convention break; default: throw new UnsupportedAudioFileException("Invalid AIFF encoding"); } } int frameSize = calculatePCMFrameSize(sampleSizeInBits, channels); //$fb what's that ?? //if (sampleSizeInBits == 8) { // encoding = AudioFormat.Encoding.PCM_SIGNED; //} format = new AudioFormat(encoding, sampleRate, sampleSizeInBits, channels, frameSize, sampleRate, true); break; case AiffFileFormat.SSND_MAGIC: // Data chunk. int dataOffset = dis.readInt(); // for now unused in javasound int blocksize = dis.readInt(); // for now unused in javasound chunkRead += 8; ssndFound = true; break; } // switch // skip the remainder of this chunk if (!ssndFound) { int toSkip = chunkLen - chunkRead; if (toSkip > 0) { dis.skipBytes(toSkip); } } } // while if (format == null) { throw new UnsupportedAudioFileException("missing COMM chunk"); } Type type = aifc ? Type.AIFC : Type.AIFF; return new AiffFileFormat(type, totallength, format, frameLength); } // HELPER METHODS /** * read_ieee_extended * Extended precision IEEE floating-point conversion routine. * @argument DataInputStream * @return double * @exception IOException */ private double read_ieee_extended(DataInputStream dis) throws IOException { double f = 0; int expon = 0; long hiMant = 0, loMant = 0; long t1, t2; double HUGE = 3.40282346638528860e+38; expon = dis.readUnsignedShort(); t1 = (long)dis.readUnsignedShort(); t2 = (long)dis.readUnsignedShort(); hiMant = t1 << 16 | t2; t1 = (long)dis.readUnsignedShort(); t2 = (long)dis.readUnsignedShort(); loMant = t1 << 16 | t2; if (expon == 0 && hiMant == 0 && loMant == 0) { f = 0; } else { if (expon == 0x7FFF) f = HUGE; else { expon -= 16383; expon -= 31; f = (hiMant * Math.pow(2, expon)); expon -= 32; f += (loMant * Math.pow(2, expon)); } } return f; } }
⏎ com/sun/media/sound/AiffFileReader.java
Or download all of them as a single archive file:
File name: java.desktop-11.0.1-src.zip File size: 7974380 bytes Release date: 2018-11-04 Download
⇒ JDK 11 java.instrument.jmod - Instrument Module
2022-08-06, 159688👍, 5💬
Popular Posts:
JDK 11 jdk.scripting.nashorn.jm odis the JMOD file for JDK 11 Scripting Nashorn module. JDK 11 Scrip...
Provides support for the runtime platform, core utility methods and the extension registry. JAR File...
Saxon-HE (home edition) is an open source product available under the Mozilla Public License. It pro...
JDK 11 jdk.compiler.jmod is the JMOD file for JDK 11 Compiler tool, which can be invoked by the "jav...
What Is mail.jar of JavaMail 1.3? I got the JAR file from javamail-1_3.zip. mail.jar in javamail-1_3...