Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

PoC TBCPÏûÏ¢½âÎöºÍ¹¹ÔìµÄJAVAʵÏÖ

TBCPMessageFactory.java
/**
* ÎļþÃû: TBCPMessageFactory.java
*/
package tbcpstack;
import java.text.MessageFormat;
import org.apache.log4j.Logger;
import TBCPException;
/**
*
* TODO TBCPÏûÏ¢¹¹½¨¹¤³§
*/
public class TBCPMessageFactory {
/**
* Logger for this class
*/
private static final Logger logger = Logger.getLogger(TBCPMessageFactory.class);
private static final String POCNAME = "PoC1";
/**
* °´ÕÕOMA PoC UserPlaneÀï¹æ¶¨µÄTBCP Talk Burst RequestÏûÏ¢¸ñʽ½øÐй¹Ôì¡£
*
* @param ssrc
* SSRC of PoC Client requesting permission to send a talk burst
* @param priority
* Ö»ÄÜΪ1¡¢2¡¢3¡£ 1 - normal priority£»2 - high priority£»3 -
* pre-emptivepriority
* @return bytes of TalkBurstRequest
* @throws TBCPException
*/
public static byte[] createTBCPTalkBurstRequest(long ssrc, int priority) throws TBCPException {
if ((1 <= priority) && (priority <= 3)) {
byte[] data = new byte[16];
data[0] = 102;// TB-priority-level
data[1] = 2;// TB-priority-length
byte[] priorityValueBytes = ByteConversion.uIntIntToByteWord(priority);// TB-priority
// value
data[2] = priorityValueBytes[0];
data[3] = priorityValueBytes[1];
data[4] = 103;// Time-stamp
data[5] = 8;// Time-stamp-length
// Timestamp value
byte[] timeStampValueBytes = ByteConversion.longToByte(TimeStamp.getCurrentTime().ntpValue());
for (int i = 0; i < 8; i++) {
data[i + 6] = timeStampValueBytes[i];
}
data[14] = 0;// ºóÁ½Î»Òª²¹Îª0
data[15] = 0;
byte[] name = POCNAME.getBytes();
return prepareRTCPAppPacket(ssrc, TBCPMessageType.TBCP_REQUEST, name, data);


Ïà¹ØÎĵµ£º

javaÈëÃÅ

 Javaѧϰ´ÓÈëÃŵ½¾«Í¨ 
Ò»¡¢ JDK (Java Development Kit) 
JDKÊÇÕû¸öJavaµÄºËÐÄ£¬°üÀ¨ÁËJavaÔËÐл·¾³£¨Java Runtime Envirnment£©£¬Ò»¶ÑJava¹¤¾ßºÍJava»ù´¡µÄÀà¿â(rt.jar)¡£²»ÂÛʲôJavaÓ¦Ó÷þÎñÆ÷ʵÖʶ¼ÊÇÄÚÖÃÁËij¸ö°æ±¾µÄJDK¡£Òò´ËÕÆÎÕJDKÊÇѧºÃJavaµÄµÚÒ»²½¡£×îÖ÷Á÷µÄJ ......

java¼¯ºÏ¿ò¼Üͼ¼°½éÉÜ

 
java¼¯ºÏ¿ò¼Üͼ¼°½éÉÜ
ת×Ô:http://hi.baidu.com/%C9%AE_%CC%C6/blog/item/9e2a8b0887008a8ad0581b3d.html
¼ò»¯Í¼£º
Javaƽ̨ÌṩÁËÒ»¸öȫеļ¯ºÏ¿ò¼Ü¡£“¼¯ºÏ¿ò¼Ü”Ö÷ÒªÓÉÒ»×éÓÃÀ´²Ù×÷¶ÔÏóµÄ½Ó¿Ú×é³É¡£²»Í¬½Ó¿ÚÃèÊöÒ»×鲻ͬÊý¾ÝÀàÐÍ¡£
Java 2¼¯ºÏ¿ò¼Üͼ
¼¯ºÏ½Ó¿Ú£º6¸ö½Ó¿Ú£¨¶ÌÐéÏß±íʾ£©£¬±íʾ²»Í ......

JavaÏòÉÏתÐÍ

ͨË×Àí½âÏòÉÏתÐÍ£º
¾ÍÊÇ×ÓÀàתÐͳɸ¸Àà¡£
class A{}
class B extends A { }
A b = new B();
Õâ¸ö¾ÍÊÇÏòÉÏתÐÍ¡£
ÏòÉÏתÐÍ¿ÉÒÔÏñÏÂÃæÕâÌõÓï¾äÕâô¼òµ¥:
      Shape s =new Circle();
      ÕâÀ´´½¨Ò»¸öCircle¶ÔÏ ......

Javaµ÷ÓÃ.NETµÄWebService

1£®  »ù±¾¿â
cxf-2.2.4.jar
XmlSchema-1.4.5.jar
Wsdl4j-1.6.2.java
2£®  ÔÚ.NETÖбàд·þÎñ£¬Ä¬ÈϲÎÊý¼´¿É£¬È磺
namespace TestService2Java
{
    [WebService(Namespace = "http://temp2java.org/")]    //½ö´Ë´¦ÉÔ¼ÓÐ޸ģ¬²»¸ÄÒ²¿É
    [WebServiceBin ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ