org.mobicents.media.server.impl.resource.zap
Class Channel
java.lang.Object
org.mobicents.media.server.impl.resource.zap.Channel
- All Implemented Interfaces:
- org.mobicents.protocols.ss7.mtp.Mtp1
public class Channel
- extends java.lang.Object
- implements org.mobicents.protocols.ss7.mtp.Mtp1
|
Field Summary |
protected int |
fd
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
fd
protected int fd
Channel
public Channel()
setLink
public void setLink(org.mobicents.protocols.ss7.mtp.Mtp2 link)
- Specified by:
setLink in interface org.mobicents.protocols.ss7.mtp.Mtp1
getLink
public org.mobicents.protocols.ss7.mtp.Mtp2 getLink()
- Specified by:
getLink in interface org.mobicents.protocols.ss7.mtp.Mtp1
getSpan
public int getSpan()
setSpan
public void setSpan(int span)
getChannelID
public int getChannelID()
setChannelID
public void setChannelID(int channelID)
setCode
public void setCode(int code)
getCode
public int getCode()
- Specified by:
getCode in interface org.mobicents.protocols.ss7.mtp.Mtp1
setLinkName
public void setLinkName(java.lang.String linkName)
getLinkName
public java.lang.String getLinkName()
open
public void open()
- Specified by:
open in interface org.mobicents.protocols.ss7.mtp.Mtp1
openChannel
public int openChannel(int id)
- Opens this channel and prepares it for reading.
- Parameters:
path - the path to the device.
read
public int read(byte[] buffer)
- Reads data from this pipe.
- Specified by:
read in interface org.mobicents.protocols.ss7.mtp.Mtp1
- Parameters:
buffer - the byte buffer to read data.
- Returns:
- the number of bytes actualy read.
readData
public int readData(int fd,
byte[] buffer)
write
public void write(byte[] buffer,
int len)
- Writes specified data to the pipe.
- Specified by:
write in interface org.mobicents.protocols.ss7.mtp.Mtp1
- Parameters:
buffer - the buffer with data to writelen - the length of the buffer.
writeData
public void writeData(int fd,
byte[] buffer,
int len)
close
public void close()
- Specified by:
close in interface org.mobicents.protocols.ss7.mtp.Mtp1
closeChannel
public void closeChannel(int fd)
- Closes this pipe.
toString
public java.lang.String toString()
- Overrides:
toString in class java.lang.Object
Copyright © 2010. All Rights Reserved.