ʹÓÃCairngorm¿ª·¢Flex£¨¶þ£©£ºÒ»¸öºÃÓѹÜÀíÀý×Ó
ÐèҪ׼±¸£º
ÔÚ¿´Õâ¸öÀý×Ó֮ǰ£¬È·±£¾ß±¸ÒÔÏÂÌõ¼þ£º
¶Á¶®ÁËʹÓÃCairngorm¿ª·¢Flex£¨Ò»£©£¬Àí½âCairngormµÄ¹¹¼ÜÊÇÔõÑùµÄ¡£
¾ßÓÐÒ»¶¨µÄjava֪ʶ¡£
ÖªµÀflex sdk4¡£
Àý×ӵĻ·¾³ºÍ¹¤¾ß£º
Flex builder 4¡£ÏÂÔغÜÈÝÒ×ÕÒµ½¡£Õâ¸öÀý×ÓÒ²ÊÇÎÒÓÃfb4дµÄµÚÒ»¸öÀý×Ó£¬·¢ÏÖ¸úfb3ºÜ¶à²»Í¬£¬ÒªÖØÐÂѧϰ£¬Í´¿àµÄתÐÍ°¡£¬Àá±¼~¡£
MysqlÊý¾Ý¿â¡£
tomcat¡£
blazeds¡£
²»ÖªµÀÔõôÅäÖõĿÉÒÔ¿´ÎÒµÄÎÄÕ£ºhttp://blog.csdn.net/duran1986/archive/2010/03/29/5430329.aspx
Àý×Ó¹¦ÄÜÃèÊö£º
¹¦Äܼܺòµ¥£¬ÔÚÇ°¶ËÌí¼ÓºÃÓÑ£¨Ãû×Ö£¬µç»°£©£¬½«ºÃÓÑÐÅÏ¢·¢Ë͵½java±àдµÄºǫ́£¬´æ´¢µ½Êý¾Ý¿â£¬³É¹¦µÄ»°·µ»ØËùÓкÃÓѵ½¿Í»§¶ËÏÔʾ¡£
Êý¾Ý¿âsql£º
н¨Ò»¸ömysqlÊý¾Ý¿â£¬Ãû×ֽУºCairngormDemo¡£ÔÚÊý¾Ý¿âÏÂÖ´ÐÐÏÂÃæsql½¨±í£º
CREATE TABLE `cairngormdemo`.`T_FriendInfo` (
`fid` INTEGER UNSIGNED NOT NULL AUTO_INCREMENT,
`fname` VARCHAR(45) NOT NULL,
`ftel` VARCHAR(45) NOT NULL,
PRIMARY KEY (`fid`)
)
ENGINE = InnoDB;
ºǫ́java£º
ÏîÄ¿½á¹¹£º
MysqlConnection.java:
package com.gy.demo;
//µ¼ÈësqlÀà
import java.sql.Connection;
import java.sql.DriverManager;
public class MysqlConnection {
//¶¨Ò徲̬µÄʵÀý£¬¸ÃʵÀýÊdzÌÐòÔËÐÐʱµÄΨһʵÀý
private static MysqlConnection instance;
private MysqlConnection() {
//µ÷ÓÃÊý¾Ý¿âÇý¶¯
try {
Class.forName("com.mysql.jdbc.Driver");
}catch(ClassNotFoundException e) {
e.printStackTrace();
}
}
//¶ÔÍâ½Ó¿Ú£¬»ñµÃΨһʵÀý
public static MysqlConnection GetInstance() {
if(instance == null) {
instance = new MysqlConnection();
}
return instance;
}
//»ñµÃÊý¾Ý¿âÁ¬½Ó
public Connection GetConnection() throws java.sql.SQLException {
//¶¨ÒåÊý¾Ý¿âÐÅÏ¢
String dbServer = "localhost";
String dbName = "CairngormDemo";
String dbUser = "root";
String dbPass = "860116";
//¹¹ÔìÁ¬½Ó×Ö·û´®£¬ÉèÖñàÂë
String connStr = "jdbc:mysql://"+dbServer+"/"+dbName+"?user="+dbUser+"&password="+dbPass+"&useUnicode=true&characterEncoding=utf8";
//·µ»ØÁ¬½Ó
return DriverManager.getConnection(connStr);
}
}
DemoService.java
package
Ïà¹ØÎĵµ£º
ºÜ¼òµ¥µÄСÀý×Ó£¬ÊʺϳõѧÕßÀí½â
1£¬JavaFlex.java
package flex;
public class JavaFlex {
public String helloJavaFlex(String name) {
return name;
}
}
2£¬remoting-config.xml
<?xml version="1.0" encoding="UTF-8"?>
<service id="remoting-service" class="flex.messaging.services.Remo ......
Ê×ÏȽéÉÜÁ½¸öFlexƤ·ôÍøÕ¾£º
1. Skins and Themes For Flex and AIR
2.Free Skin and Themes For Adobe Flex
ÒÔÉÏÁ½¸öÍøÕ¾¶¼ÌṩÁËƤ·ôÏÂÔØ¡£ÏÈ¿´Ò»¸öÆäÖеÄЧ¹û£º
µ±È»Õâ¿îƤ·ôBrownie²¢²»Ö§³ÖÖÐÎÄ£¬ÔÒòÊÇËüÀïÃæµÄ×Ô¼ºÃ»ÓÐÖÐÎĵġ£ÐèÒª×ÔÐÐÌí¼Ó£¬ÎÒÕâÀïʹÓõÄÊÇ΢ÈíÑźڡ£
ÐèÒªÔÚassets/css/Main.cssÖÐÐ޸ģº
Ì ......
×î½ü×öflexÏîÄ¿µÄʱºò£¬·¢ÏÖÍ˳öµÇ½ʱURLÉÏ»á×Ô¶¯¼ÓÉÏÒ»¸ö“#”×Ö·û£¬ºÜÆæ¹Ö£¬Google+BaiduÎÞÊý´Î¶¼Ã»ÓÐÕÒµ½´ð°¸¡£½ñÌìÎÞÒâ¼ä¿´µ½¼¸¸öȺÓÑÔÚ ËµÍ¨¹ý“BrowserManager”»ñÈ¡URL£¬ÓÚÊÇ×Ðϸ²é¿´ÁËAPI£¬ÓÖ·¢ÏÖÁË“HistoryManager”£¬Õâ¸öÎÊÌâÖÕÓÚÃ÷°×ÁË¡£ ÎÒ ÃÇͨ³£¿´µÄWebÒ³Ãæ ¿ÉÒÔͨ¹ýä¯ÀÀÆ÷µ ......
Application×é¼þÑùʽÊôÐÔ
backgroundImage ±³¾°Í¼ ʹÓÃEmbed(source=" ");À´Ó¦ÓÃ
& ......