Class MediaUtil

java.lang.Object
se.datadosen.util.MediaUtil

public class MediaUtil
extends java.lang.Object
Load a Media object from passed File or URI string
Since:
28
  • Method Summary

    Modifier and Type Method Description
    static TimeCode getDuration​(java.io.File mediaFile)
    Convenience version of loadMedia
    static javafx.scene.media.Media loadMedia​(java.io.File mediaFile)  
    static javafx.scene.media.Media loadMedia​(java.lang.String mediaURI)  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • loadMedia

      public static javafx.scene.media.Media loadMedia​(java.lang.String mediaURI) throws javafx.scene.media.MediaException, java.io.IOException
      Throws:
      javafx.scene.media.MediaException
      java.io.IOException
    • loadMedia

      public static javafx.scene.media.Media loadMedia​(java.io.File mediaFile) throws javafx.scene.media.MediaException, java.io.IOException
      Throws:
      javafx.scene.media.MediaException
      java.io.IOException
    • getDuration

      public static TimeCode getDuration​(java.io.File mediaFile)
      Convenience version of loadMedia
      Parameters:
      mediaFile -
      Returns:
      jAlbum TimeCode object representing media duration or null if not able to retrieve duration