I am using Java to write a media application.
Given a file, how can I know is it a audio file or video file?
By the开发者_运维问答 way, I use vlcj library.
In Java 7 you will be able to use java.nio.file.probeContentType
to do this.
In the meantime, there are a number of other options for doing this kind of thing.
精彩评论