chameleon.playlist.Media.<init>()方法的使用及代码示例

x33g5p2x  于2022-01-25 转载在 其他  
字(7.7k)|赞(0)|评价(0)|浏览(121)

本文整理了Java中chameleon.playlist.Media.<init>()方法的一些代码示例,展示了Media.<init>()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Media.<init>()方法的具体详情如下:
包路径:chameleon.playlist.Media
类名称:Media
方法名:<init>

Media.<init>介绍

暂无

代码示例

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-plp

@Override
public Playlist toPlaylist()
{
  final Playlist ret = new Playlist();
  for (String filename : _filenames)
  {
    final Media media = new Media(); // NOPMD Avoid instantiating new objects inside loops
    final Content content = new Content(filename); // NOPMD Avoid instantiating new objects inside loops
    media.setSource(content);
    ret.getRootSequence().addComponent(media);
  }
  ret.normalize();
  return ret;
}

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-pla

@Override
public Playlist toPlaylist()
{
  final Playlist ret = new Playlist();
  for (String filename : _filenames)
  {
    final Media media = new Media(); // NOPMD Avoid instantiating new objects inside loops
    final Content content = new Content(filename); // NOPMD Avoid instantiating new objects inside loops
    media.setSource(content);
    ret.getRootSequence().addComponent(media);
  }
  ret.normalize();
  return ret;
}

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-rmp

final Media media = new Media(); // NOPMD Avoid instantiating new objects inside loops
final Content content = new Content(url); // NOPMD Avoid instantiating new objects inside loops

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-kpl

@Override
public Playlist toPlaylist()
{
  final Playlist ret = new Playlist();
  for (Entry entry : _entries)
  {
    if (entry.getFilename() != null)
    {
      final Media media = new Media(); // NOPMD Avoid instantiating new objects inside loops
      final Content content = new Content(entry.getFilename()); // NOPMD Avoid instantiating new objects inside loops
      media.setSource(content);
      ret.getRootSequence().addComponent(media);
    }
  }
  // We don't really need it.
  ret.normalize();
  return ret;
}

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-mpcpl

@Override
public Playlist toPlaylist()
{
  final Playlist ret = new Playlist();
  for (Resource resource : _resources)
  {
    if (resource.getFilename() != null)
    {
      final Media media = new Media(); // NOPMD Avoid instantiating new objects inside loops
      final Content content = new Content(resource.getFilename()); // NOPMD Avoid instantiating new objects inside loops
      media.setSource(content);
      ret.getRootSequence().addComponent(media);
    }
  }
  ret.normalize();
  return ret;
}

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-hypetape

@Override
public chameleon.playlist.Playlist toPlaylist()
{
  final chameleon.playlist.Playlist ret = new chameleon.playlist.Playlist();
  for (Track track : _tracks)
  {
    if (track.getMP3() != null)
    {
      final Media media = new Media(); // NOPMD Avoid instantiating new objects inside loops
      final Content content = new Content(track.getMP3()); // NOPMD Avoid instantiating new objects inside loops
      media.setSource(content);
      ret.getRootSequence().addComponent(media);
    }
  }
  // We don't really need it.
  ret.normalize();
  return ret;
}

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-b4s

@Override
public chameleon.playlist.Playlist toPlaylist()
{
  final chameleon.playlist.Playlist ret = new chameleon.playlist.Playlist();
  for (Entry entry : _playlist.getEntries())
  {
    if (entry.getPlaystring() != null)
    {
      final Media media = new Media(); // NOPMD Avoid instantiating new objects inside loops
      final Content content = new Content(entry.getPlaystring()); // NOPMD Avoid instantiating new objects inside loops
      if (entry.getLength() != null)
      {
        content.setLength(entry.getLength().longValue());
      }
      media.setSource(content);
      ret.getRootSequence().addComponent(media);
    }
  }
  // We don't really need it.
  ret.normalize();
  return ret;
}

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-xspf

@Override
public chameleon.playlist.Playlist toPlaylist()
{
  final chameleon.playlist.Playlist ret = new chameleon.playlist.Playlist();
  for (Track track : _tracks)
  {
    for (StringContainer stringContainer : track.getStringContainers())
    {
      if ((stringContainer instanceof Location) && (stringContainer.getText() != null))
      {
        final Media media = new Media(); // NOPMD Avoid instantiating new objects inside loops
        final Content content = new Content(stringContainer.getText()); // NOPMD Avoid instantiating new objects inside loops
        media.setSource(content);
        if (track.getDuration() != null)
        {
          content.setDuration(track.getDuration().longValue());
        }
        ret.getRootSequence().addComponent(media);
      }
    }
  }
  // We don't really need it.
  ret.normalize();
  return ret;
}

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-atom

@Override
public Playlist toPlaylist()
{
  final Playlist ret = new Playlist();
  for (Entry entry : _feed.getEntries())
  {
    for (Link link : entry.getLinks())
    {
      if ((link.getHref() != null) && "enclosure".equals(link.getRel()))
      {
        final Media media = new Media(); // NOPMD Avoid instantiating new objects inside loops
        final chameleon.content.Content content = new chameleon.content.Content(link.getHref()); // NOPMD Avoid instantiating new objects inside loops
        content.setType(link.getType());
        if (link.getLength() != null)
        {
          content.setLength(link.getLength().longValue());
        }
        media.setSource(content);
        ret.getRootSequence().addComponent(media);
      }
    }
  }
  // We don't really need it.
  ret.normalize();
  return ret;
}

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-pls

@Override
public Playlist toPlaylist()
{
  final Playlist ret = new Playlist();
  for (Resource resource : _resources)
  {
    if (resource.getLocation() != null)
    {
      final Media media = new Media(); // NOPMD Avoid instantiating new objects inside loops
      final Content content = new Content(resource.getLocation()); // NOPMD Avoid instantiating new objects inside loops
      media.setSource(content);
      content.setDuration(resource.getLength() * 1000L);
      ret.getRootSequence().addComponent(media);
    }
  }
  ret.normalize();
  return ret;
}

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-m3u

@Override
public Playlist toPlaylist()
{
  final Playlist ret = new Playlist();
  for (Resource resource : _resources)
  {
    if (resource.getLocation() != null)
    {
      final Media media = new Media(); // NOPMD Avoid instantiating new objects inside loops
      final Content content = new Content(resource.getLocation()); // NOPMD Avoid instantiating new objects inside loops
      media.setSource(content);
      content.setDuration(resource.getLength() * 1000L);
      ret.getRootSequence().addComponent(media);
    }
  }
  ret.normalize();
  return ret;
}

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-wpl

@Override
public Playlist toPlaylist()
{
  final Playlist ret = new Playlist();
  if (_body != null)
  {
    for (Media wplMedia : _body.getSeq().getMedias())
    {
      if (wplMedia.getSource() != null)
      {
        final chameleon.playlist.Media media = new chameleon.playlist.Media(); // NOPMD Avoid instantiating new objects inside loops
        media.setSource(new Content(wplMedia.getSource())); // NOPMD Avoid instantiating new objects inside loops
        ret.getRootSequence().addComponent(media);
      }
    }
    ret.normalize();
  }
  return ret;
}

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-rss

final Media media = new Media();
final chameleon.content.Content content = new chameleon.content.Content(mediaContent.getURL());
final Media media = new Media();
final chameleon.content.Content content = new chameleon.content.Content(mediaContent.getMediaPlayer().getURL());

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-smil

final Media media = new Media();
final Content content = new Content(smilRef.getSource());

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-asx

final Media media = new Media(); // NOPMD Avoid instantiating new objects inside loops
    media.setSource(new Content(reference.getHref())); // NOPMD Avoid instantiating new objects inside loops
final Media media = new Media();
media.setSource(new Content(entryRef.getHref()));
currentSequence.addComponent(media);

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-plist

final Media media = new Media(); // NOPMD Avoid instantiating new objects inside loops
final Content content = new Content(location); // NOPMD Avoid instantiating new objects inside loops
media.setSource(content);

代码示例来源:origin: com.github.muff1nman.chameleon/playlist-rss

final Media media = new Media(); // NOPMD Avoid instantiating new objects inside loops
final chameleon.content.Content content = new chameleon.content.Content(enclosure.getURL()); // NOPMD Avoid instantiating new objects inside loops
content.setLength(enclosure.getLength());

相关文章