📄 mp3file.html
字号:
</DD>
</DL>
<HR>
<A NAME="getParent()"><!-- --></A><H3>
getParent</H3>
<PRE>
public java.lang.String <B>getParent</B>()</PRE>
<DL>
<DD>Returns the parent directory of this MP3File.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the parent directory of this MP3File</DL>
</DD>
</DL>
<HR>
<A NAME="getFileName()"><!-- --></A><H3>
getFileName</H3>
<PRE>
public java.lang.String <B>getFileName</B>()</PRE>
<DL>
<DD>Returns the filename of this MP3File.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the filename of this MP3File</DL>
</DD>
</DL>
<HR>
<A NAME="getFileSize()"><!-- --></A><H3>
getFileSize</H3>
<PRE>
public long <B>getFileSize</B>()</PRE>
<DL>
<DD>Return the filesize of this MP3File (in bytes).<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the filesize of this MP3File (in bytes)</DL>
</DD>
</DL>
<HR>
<A NAME="id3v2Exists()"><!-- --></A><H3>
id3v2Exists</H3>
<PRE>
public boolean <B>id3v2Exists</B>()</PRE>
<DL>
<DD>Returns true if an id3v2 tag currently exists.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>true if an id3v2 tag currently exists</DL>
</DD>
</DL>
<HR>
<A NAME="id3v1Exists()"><!-- --></A><H3>
id3v1Exists</H3>
<PRE>
public boolean <B>id3v1Exists</B>()</PRE>
<DL>
<DD>Returns true if an id3v1 tag currently exists.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>true if an id3v1 tag currently exists</DL>
</DD>
</DL>
<HR>
<A NAME="isMP3()"><!-- --></A><H3>
isMP3</H3>
<PRE>
public boolean <B>isMP3</B>()</PRE>
<DL>
<DD>Returns true if this file is an mp3. This means simply that an MPEGAudioFrameHeader was found and the layer is 3.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>true if this file is an mp3</DL>
</DD>
</DL>
<HR>
<A NAME="getBitRate()"><!-- --></A><H3>
getBitRate</H3>
<PRE>
public int <B>getBitRate</B>()</PRE>
<DL>
<DD>Returns the bit rate of this mp3 in kbps.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the bit rate of this mp3 in kbps</DL>
</DD>
</DL>
<HR>
<A NAME="getSampleRate()"><!-- --></A><H3>
getSampleRate</H3>
<PRE>
public int <B>getSampleRate</B>()</PRE>
<DL>
<DD>Returns the sample rate of this mp3 in Hz.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the sample reate of this mp3 in Hz</DL>
</DD>
</DL>
<HR>
<A NAME="getMPEGEmphasis()"><!-- --></A><H3>
getMPEGEmphasis</H3>
<PRE>
public java.lang.String <B>getMPEGEmphasis</B>()</PRE>
<DL>
<DD>Returns the emphasis of this mp3.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the emphasis of this mp3</DL>
</DD>
</DL>
<HR>
<A NAME="getMPEGLayer()"><!-- --></A><H3>
getMPEGLayer</H3>
<PRE>
public java.lang.String <B>getMPEGLayer</B>()</PRE>
<DL>
<DD>Returns a string specifying the layer of the mpeg. Ex: Layer III<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>a string specifying the layer of the mpeg</DL>
</DD>
</DL>
<HR>
<A NAME="getMPEGVersion()"><!-- --></A><H3>
getMPEGVersion</H3>
<PRE>
public java.lang.String <B>getMPEGVersion</B>()</PRE>
<DL>
<DD>Returns a string specifying the version of the mpeg. This can either be 1.0, 2.0, or 2.5.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>a string specifying the version of the mpeg</DL>
</DD>
</DL>
<HR>
<A NAME="getMPEGChannelMode()"><!-- --></A><H3>
getMPEGChannelMode</H3>
<PRE>
public java.lang.String <B>getMPEGChannelMode</B>()</PRE>
<DL>
<DD>Return the channel mode of the mpeg. Ex: Stereo<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the channel mode of the mpeg</DL>
</DD>
</DL>
<HR>
<A NAME="isMPEGCopyrighted()"><!-- --></A><H3>
isMPEGCopyrighted</H3>
<PRE>
public boolean <B>isMPEGCopyrighted</B>()</PRE>
<DL>
<DD>Returns true if this mpeg is copyrighted.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>true if this mpeg is copyrighted</DL>
</DD>
</DL>
<HR>
<A NAME="isMPEGOriginal()"><!-- --></A><H3>
isMPEGOriginal</H3>
<PRE>
public boolean <B>isMPEGOriginal</B>()</PRE>
<DL>
<DD>Returns true if this mpeg is the original.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>true if this mpeg is the original</DL>
</DD>
</DL>
<HR>
<A NAME="isMPEGProtected()"><!-- --></A><H3>
isMPEGProtected</H3>
<PRE>
public boolean <B>isMPEGProtected</B>()</PRE>
<DL>
<DD>Returns true if this mpeg is protected by CRC.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>true if this mpeg is protected by CRC</DL>
</DD>
</DL>
<HR>
<A NAME="removeTags(int)"><!-- --></A><H3>
removeTags</H3>
<PRE>
public void <B>removeTags</B>(int type) throws java.io.FileNotFoundException, java.io.IOException</PRE>
<DL>
<DD>Removes id3 tags from the file. The argument specifies which tags to remove. This can either be BOTH_TAGS, ID3V1_ONLY, ID3V2_ONLY, or EXISTING_TAGS_ONLY.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>type</CODE> - specifies what tag(s) to remove<DT><B>Throws:</B><DD><CODE>java.io.FileNotFoundException</CODE> - if an error occurs<DD><CODE>java.io.IOException</CODE> - if an error occurs</DL>
</DD>
</DL>
<HR>
<A NAME="writeTags()"><!-- --></A><H3>
writeTags</H3>
<PRE>
public void <B>writeTags</B>() throws java.io.FileNotFoundException, java.io.IOException</PRE>
<DL>
<DD>Writes the current state of the id3 tags to the file. What tags are written depends upon the tagType passed to the constructor.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Throws:</B><DD><CODE>java.io.FileNotFoundException</CODE> - if an error occurs<DD><CODE>java.io.IOException</CODE> - if an error occurs</DL>
</DD>
</DL>
<HR>
<A NAME="setTitle(java.lang.String)"><!-- --></A><H3>
setTitle</H3>
<PRE>
public void <B>setTitle</B>(java.lang.String title)</PRE>
<DL>
<DD>Set the title of this mp3.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>title</CODE> - the title of the mp3</DL>
</DD>
</DL>
<HR>
<A NAME="setAlbum(java.lang.String)"><!-- --></A><H3>
setAlbum</H3>
<PRE>
public void <B>setAlbum</B>(java.lang.String album)</PRE>
<DL>
<DD>Set the album of this mp3.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>album</CODE> - the album of the mp3</DL>
</DD>
</DL>
<HR>
<A NAME="setArtist(java.lang.String)"><!-- --></A><H3>
setArtist</H3>
<PRE>
public void <B>setArtist</B>(java.lang.String artist)</PRE>
<DL>
<DD>Set the artist of this mp3.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>artist</CODE> - the artist of the mp3</DL>
</DD>
</DL>
<HR>
<A NAME="setComment(java.lang.String)"><!-- --></A><H3>
setComment</H3>
<PRE>
public void <B>setComment</B>(java.lang.String comment)</PRE>
<DL>
<DD>Add a comment to this mp3.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>comment</CODE> - a comment to add to the mp3</DL>
</DD>
</DL>
<HR>
<A NAME="setGenre(java.lang.String)"><!-- --></A><H3>
setGenre</H3>
<PRE>
public void <B>setGenre</B>(java.lang.String genre)</PRE>
<DL>
<DD>Set the genre of this mp3.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>genre</CODE> - the genre of the mp3</DL>
</DD>
</DL>
<HR>
<A NAME="setYear(java.lang.String)"><!-- --></A><H3>
setYear</H3>
<PRE>
public void <B>setYear</B>(java.lang.String year)</PRE>
<DL>
<DD>Set the year of this mp3.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>year</CODE> - of the mp3</DL>
</DD>
</DL>
<HR>
<A NAME="setTrack(int)"><!-- --></A><H3>
setTrack</H3>
<PRE>
public void <B>setTrack</B>(int track)</PRE>
<DL>
<DD>Set the track number of this mp3.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>track</CODE> - the track number of this mp3</DL>
</DD>
</DL>
<HR>
<A NAME="setComposer(java.lang.String)"><!-- --></A><H3>
setComposer</H3>
<PRE>
public void <B>setComposer</B>(java.lang.String composer)</PRE>
<DL>
<DD>Set the composer of this mp3 (id3v2 only).<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>composer</CODE> - the composer of this mp3</DL>
</DD>
</DL>
<HR>
<A NAME="setOriginalArtist(java.lang.String)"><!-- --></A><H3>
setOriginalArtist</H3>
<PRE>
public void <B>setOriginalArtist</B>(java.lang.String artist)</PRE>
<DL>
<DD>Set the original artist of this mp3 (id3v2 only).<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>artist</CODE> - the original artist of this mp3</DL>
</DD>
</DL>
<HR>
<A NAME="setCopyrightInfo(java.lang.String)"><!-- --></A><H3>
setCopyrightInfo</H3>
<PRE>
public void <B>setCopyrightInfo</B>(java.lang.String copyright)</PRE>
<DL>
<DD>Add some copyright information to this mp3 (id3v2 only).<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>copyright</CODE> - copyright information related to this mp3</DL>
</DD>
</DL>
<HR>
<A NAME="setUserDefinedURL(java.lang.String, java.lang.String)"><!-- --></A><H3>
setUserDefinedURL</H3>
<PRE>
public void <B>setUserDefinedURL</B>(java.lang.String desc, java.lang.String url)</PRE>
<DL>
<DD>Add a link to this mp3 (id3v2 only). This includes a description of the url and the url itself.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>desc</CODE> - a description of the url<DD><CODE>url</CODE> - the url itself</DL>
</DD>
</DL>
<HR>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -