本文整理汇总了Java中com.mpatric.mp3agic.NotSupportedException类的典型用法代码示例。如果您正苦于以下问题:Java NotSupportedException类的具体用法?Java NotSupportedException怎么用?Java NotSupportedException使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
NotSupportedException类属于com.mpatric.mp3agic包,在下文中一共展示了NotSupportedException类的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: save
import com.mpatric.mp3agic.NotSupportedException; //导入依赖的package包/类
public void save(String newFilename) throws IOException, NotSupportedException {
/*if (file.compareTo(new File(newFilename)) == 0) {
throw new IllegalArgumentException("Save filename same as source filename");
}*/
RandomAccessFile saveFile = new RandomAccessFile(newFilename, "rw");
try {
if (hasId3v2Tag()) {
saveFile.write(id3v2Tag.toBytes());
}
saveMpegFrames(saveFile);
if (hasCustomTag()) {
saveFile.write(customTag);
}
if (hasId3v1Tag()) {
saveFile.write(id3v1Tag.toBytes());
}
} finally {
saveFile.close();
}
}
开发者ID:dimattiami,项目名称:ytdl,代码行数:21,代码来源:MyMp3FileOverride.java
示例2: writeAudioFiles
import com.mpatric.mp3agic.NotSupportedException; //导入依赖的package包/类
/**
* writes the given audio file to the harddisk
*
* @param indices
* given audio file
* @param pb
* the progressbar which will be updated for each changed audio
* file
*
* @throws NotSupportedException
* thrown if ID3Tag couldn't be generated
* @throws IOException
* thrown if new audio file couldn't be written
* @throws AudioFileException
* thrown if new audio file couldn't be reread
*/
public void writeAudioFiles(int[] indices, IProgressBar pb) throws NotSupportedException, IOException, AudioFileException {
for (int i = 0; i < indices.length; i++) {
if (this.stopFlag)
return;
logger.log(Level.FINER, "analyse audioFiles: " + indices[i] + " changed: " + audioFiles.get(indices[i]).hasChanged());
if (audioFiles.get(indices[i]).hasChanged()) {
if (!audioFiles.get(indices[i]).isWriteable())
throw new IOException("Couldn't write file: " + audioFiles.get(indices[i]).getFilePath());
audioFiles.get(indices[i]).save();
audioFiles.get(indices[i]).resetAudioFile();
pb.nextStep();
}
}
}
开发者ID:cf86,项目名称:MP3ToolKit,代码行数:34,代码来源:ID3TagModel.java
示例3: toBytes
import com.mpatric.mp3agic.NotSupportedException; //导入依赖的package包/类
@Override
public byte[] toBytes() throws NotSupportedException {
return this.tag.toBytes();
}
开发者ID:driver733,项目名称:VKMusicUploader,代码行数:5,代码来源:ID3v1AnnotatedSafe.java
示例4: writeAudioFile
import com.mpatric.mp3agic.NotSupportedException; //导入依赖的package包/类
@Override
public void writeAudioFile(String filepath) throws NotSupportedException, IOException {
this.mp3.save(filepath);
}
开发者ID:cf86,项目名称:MP3ToolKit,代码行数:5,代码来源:MP3.java
示例5: retag
import com.mpatric.mp3agic.NotSupportedException; //导入依赖的package包/类
private void retag() throws IOException, NotSupportedException {
updateId3Tags();
updateCustomTag();
mp3file.save(mp3file.getFilename() + RETAG_EXTENSION);
renameFiles();
}
开发者ID:mpatric,项目名称:mp3agic-examples,代码行数:7,代码来源:Mp3Retag.java
示例6: writeAudioFile
import com.mpatric.mp3agic.NotSupportedException; //导入依赖的package包/类
/**
* saves the modified audio file
*
* @param filepath
* path where to save the modified audio file
*
* @throws NotSupportedException
* thrown if an error occured while writing
* @throws IOException
* thrown if file couldn't be written
*/
public void writeAudioFile(String filepath) throws NotSupportedException, IOException;
开发者ID:cf86,项目名称:MP3ToolKit,代码行数:13,代码来源:IAudioFile.java
示例7: save
import com.mpatric.mp3agic.NotSupportedException; //导入依赖的package包/类
/**
* saves all made changes to this audio files tag
*
* @throws NotSupportedException
* thrown if file couldn't be saved
*/
public void save() throws NotSupportedException, IOException;
开发者ID:cf86,项目名称:MP3ToolKit,代码行数:8,代码来源:IAudioFile.java
注:本文中的com.mpatric.mp3agic.NotSupportedException类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论