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);
Ïà¹ØÎĵµ£º
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 ......
Ëæ×Å»¥ÁªÍøµÄÈÕÒæ׳´ó,ÍøÕ¾µÄpvºÍuv³ÉÏßÐÔ»òÕßÖ¸Êý±¶µÄÔö¼Ó.µ¥·þÎñÆ÷µ¥Êý¾Ý¿âÔçÒѾ²»ÄÜÂú×ãʵ¼ÊÐèÇó.±ÈÈçÏñÊ¢´ó,ÌÔ±¦ÕâÑùµÄ´óÐÍÍøÂ繫˾,¸üÊÇÈç´Ë.
¼¯Èº,Ò²¾ÍÊÇÈÃÒ»×é¼ÆËã»ú·þÎñÆ÷Ðͬ¹¤×÷,´ï½â¾ö´ó²¢·¢,´óÊý¾ÝÁ¿Æ¿¾±ÎÊÌâ.µ«ÊÇÔÚȺ¼¯ÖÐ,sessionÍùÍùÊÇÒ»¸ö±È½ÈÍ·ÌÛµÄÎ ......
×ܹ²Á½¸öÎļþTaxTest.javaÓëTax.java
---------------------------------------------------------------------------------------
TaxTest.java
===========================================
import javax.swing.JOptionPane;
public class TestTax{
public static void main(String[] args){
String yea ......
×î½ü¿ªÊ¼ÔÚ¿´java£¬¶ÔAppletÕâ½Ú±È½Ï¸ÐÐËȤ£¬¸ÄÁ˸ÄÊéÉϵĴúÂ룬Ȩµ±Áô¸öÓ¡¼Ç
import java.awt.*;
import java.applet.*;
public class HelloApplet extends Applet
{
Font f1 = new Font("Times New Roman", Font.PLAIN, 12);
Font f2 = new Font("ËÎÌå", Font.BOLD, 24);
Font f3 = new Font("ºÚÌå", Fon ......
Ò»¡¢JDBCµ÷Óô洢¹ý³Ì
creat proc proc_select
¡¡¡¡@pid varchar(20)
¡¡¡¡@address varchar(20) output
¡¡¡¡as
¡¡¡¡select @address=address from userinfo where pid=@pid
¡¡¡¡go
¡¡¡¡ÓÃjavaµ÷ÓÃ:
¡¡¡¡class.forName(\"sun.jdbc.odbc.JdbcOdbcDriver\"); //¼ÓÔØÇý¶¯
¡¡¡¡Connection con=DriverManager.ge ......