org.mobicents.media.server.impl
Class PipeImpl

java.lang.Object
  extended by org.mobicents.media.server.impl.PipeImpl
All Implemented Interfaces:
Pipe

public class PipeImpl
extends Object
implements Pipe

Pipe implementation.

Author:
kulikov

Field Summary
protected  MediaSink sink
           
protected  MediaSource source
           
 
Fields inherited from interface org.mobicents.media.server.spi.io.Pipe
INPUT, OUTPUT
 
Constructor Summary
PipeImpl()
           
 
Method Summary
 void connect(MediaSink sink)
          (Non Java-doc.)
 void connect(MediaSource source)
          (Non Java-doc.)
 void disconnect()
          (Non Java-doc.)
 void disconnect(int termination)
          (Non Java-doc.)
 int getRxPackets()
           
 int getTxPackets()
           
protected  Frame read()
          Reads the frame from inner buffer and removes it from inner buffer.
 void setDebug(boolean isDebug)
           
 int size()
          Gets the current size of inner buffer.
 void start()
          (Non Java-doc.)
 void stop()
          (Non Java-doc.)
protected  void write(Frame frame)
          Writes frame into the inner buffer.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

source

protected MediaSource source

sink

protected MediaSink sink
Constructor Detail

PipeImpl

public PipeImpl()
Method Detail

setDebug

public void setDebug(boolean isDebug)

write

protected void write(Frame frame)
Writes frame into the inner buffer.

Parameters:
frame - the frame to write

read

protected Frame read()
Reads the frame from inner buffer and removes it from inner buffer.

Returns:
the packet read.

connect

public void connect(MediaSource source)
(Non Java-doc.)

Specified by:
connect in interface Pipe
See Also:
Pipe.connect(org.mobicents.media.MediaSource)

connect

public void connect(MediaSink sink)
(Non Java-doc.)

Specified by:
connect in interface Pipe
See Also:
Pipe.connect(org.mobicents.media.MediaSink)

disconnect

public void disconnect(int termination)
(Non Java-doc.)

Specified by:
disconnect in interface Pipe
See Also:
Pipe.disconnect(int)

disconnect

public void disconnect()
(Non Java-doc.)

Specified by:
disconnect in interface Pipe
See Also:
Pipe.disconnect()

size

public int size()
Gets the current size of inner buffer.

Returns:
the number of frames inside inner buffer.

start

public void start()
(Non Java-doc.)

Specified by:
start in interface Pipe
See Also:
Pipe.start()

stop

public void stop()
(Non Java-doc.)

Specified by:
stop in interface Pipe
See Also:
Pipe.stop()

getRxPackets

public int getRxPackets()

getTxPackets

public int getTxPackets()


Copyright © 2011. All Rights Reserved.