com.xuggle.mediatool
Class AMediaCoderMixin

Package class diagram package AMediaCoderMixin
java.lang.Object
  extended by com.xuggle.mediatool.AMediaGeneratorMixin
      extended by com.xuggle.mediatool.AMediaToolMixin
          extended by com.xuggle.mediatool.AMediaCoderMixin

public abstract class AMediaCoderMixin
extends AMediaToolMixin

An abstract implementation of all IMediaCoder methods, but does not declare IMediaCoder.

Mixin classes can be extended by anyone, but the extending class gets to decide which, if any, of the interfaces they actually want to support.


Constructor Summary
AMediaCoderMixin(String url, IContainer container)
          Construct an AMediaCoderMixin.
 
Method Summary
 IContainer getContainer()
          Get the underlying media IContainer that the IMediaCoder is reading from or writing to.
 boolean getShouldCloseContainer()
          Should this IMediaCoder call IContainer.close() when IMediaCoder.close() is called.
 String getUrl()
          The URL from which the IContainer is being read or written to.
 boolean isOpen()
          Test if this IMediaCoder is open.
 void setShouldCloseContainer(boolean value)
          Should this IMediaCoder call IContainer.close() when IMediaCoder.close() is called.
 
Methods inherited from class com.xuggle.mediatool.AMediaToolMixin
onAddStream, onAudioSamples, onClose, onCloseCoder, onFlush, onOpen, onOpenCoder, onReadPacket, onVideoPicture, onWriteHeader, onWritePacket, onWriteTrailer
 
Methods inherited from class com.xuggle.mediatool.AMediaGeneratorMixin
addListener, getListeners, removeListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AMediaCoderMixin

public AMediaCoderMixin(String url,
                        IContainer container)
Construct an AMediaCoderMixin.

Parameters:
url - the URL which will be read or written to
container - the container which be read from or written to
Method Detail

getUrl

public String getUrl()
The URL from which the IContainer is being read or written to.

Returns:
the source or destination URL.

getContainer

public IContainer getContainer()
Get the underlying media IContainer that the IMediaCoder is reading from or writing to. The returned IContainer can be further interrogated for media stream details.

Returns:
the media container.

isOpen

public boolean isOpen()
Test if this IMediaCoder is open.

Returns:
true if the media tool is open.

setShouldCloseContainer

public void setShouldCloseContainer(boolean value)
Should this IMediaCoder call IContainer.close() when IMediaCoder.close() is called.

Parameters:
value - should we close the container

getShouldCloseContainer

public boolean getShouldCloseContainer()
Should this IMediaCoder call IContainer.close() when IMediaCoder.close() is called.

Returns:
should we close the container


Copyright © 2008, 2010 Xuggle