ת×Ô£ºhttp://hi.baidu.com/wosinmaiken/blog/item/ee59f7a8f72604bdca130c24.html
/**ceil ÏòÇ°(ÊýÖáÏòÓÒ)È¡Õû(·µ»ØֵΪNumber)**/
trace(Math.ceil(10.4)); //11
trace(Math.ceil(10.5)); //11
trace(Math.ceil(-10.4)); //-10
trace(Math.ceil(-10.5)); //-10
/**floor Ïòºó(ÊýÖáÏò×ó)È¡Õû(·µ»ØֵΪNumber)**/
trace(Math.floor(300.4)); //300
trace(Math.floor(300.5)); //300
t ......
¡¡¡¡×î½üÔÚ¿ª·¢¹ý³ÌÖз¢ÏÖÒ»¸öÎÊÌ⣺BooleanÀàÐ͵ÄÖµÎÞ·¨ÔÚflexºÍjava¼ä´«µÝ£¬¾¹ýÒ»¶ÎÑо¿·¢ÏÖ£¬ÎÊÌâ³öÏÖÔÚBooleanÀàÐ͵ÄgetterºÍsetter·½·¨ÉÏ¡£
°´ÕÕjavabeanµÄ¹æ·¶£¬Ð¡²¼¶ûÀàÐ͵ÄgetterÊÇÒÔis×öǰ׺µÄ£¬µ«ÊǴ󲼶ûÀàÐ͵Ägetter¾Í³ÉÁËÒÔgetΪǰ׺ÁË£¨´ó²¼¶û×÷ΪÒýÓÃÀàÐÍ£¬ÒѾ±»ÊÓΪÆÕͨµÄObjectÁË£©¡£
ÀýÈ磺
¡¡¡¡¶ÔÓÚ×Ö¶Îprivate boolean enable;ÆägetterºÍsetterÈçÏ£º£¨Ìرð˵Ã÷µÄÊÇ£ºÈç¹ûÕâÀïµÄenable¸Ä³ÉisEnable£¬getterºÍsetter»¹ÊÇÏÂÃæµÄÕâÁ½¸ö£©
public boolean isEnable() {
return enable;
}
public void setEnable(boolean enable) {
this.enable = enable;
}
¡¡¡¡¶ÔÓÚ×Ö¶Îprivate Boolean editable;ÆägetterºÍsetterÈçÏ£º
public Boolean getEditable() {
return editable;
}
public void setEditable(Boolean editable) {
......
¡¡¡¡×î½üÔÚ¿ª·¢¹ý³ÌÖз¢ÏÖÒ»¸öÎÊÌ⣺BooleanÀàÐ͵ÄÖµÎÞ·¨ÔÚflexºÍjava¼ä´«µÝ£¬¾¹ýÒ»¶ÎÑо¿·¢ÏÖ£¬ÎÊÌâ³öÏÖÔÚBooleanÀàÐ͵ÄgetterºÍsetter·½·¨ÉÏ¡£
°´ÕÕjavabeanµÄ¹æ·¶£¬Ð¡²¼¶ûÀàÐ͵ÄgetterÊÇÒÔis×öǰ׺µÄ£¬µ«ÊǴ󲼶ûÀàÐ͵Ägetter¾Í³ÉÁËÒÔgetΪǰ׺ÁË£¨´ó²¼¶û×÷ΪÒýÓÃÀàÐÍ£¬ÒѾ±»ÊÓΪÆÕͨµÄObjectÁË£©¡£
ÀýÈ磺
¡¡¡¡¶ÔÓÚ×Ö¶Îprivate boolean enable;ÆägetterºÍsetterÈçÏ£º£¨Ìرð˵Ã÷µÄÊÇ£ºÈç¹ûÕâÀïµÄenable¸Ä³ÉisEnable£¬getterºÍsetter»¹ÊÇÏÂÃæµÄÕâÁ½¸ö£©
public boolean isEnable() {
return enable;
}
public void setEnable(boolean enable) {
this.enable = enable;
}
¡¡¡¡¶ÔÓÚ×Ö¶Îprivate Boolean editable;ÆägetterºÍsetterÈçÏ£º
public Boolean getEditable() {
return editable;
}
public void setEditable(Boolean editable) {
......
Flex4Öж¯Ì¬¼ÓÔØCSSÎļþµÄ·½Ê½ÒѾºÍFlex3ÓÐÁËÒ»¶¨µÄÇø±ð
Ö÷Òª²½ÖèÈçÏ£º
1.±àд²»Í¬µÄCSSÎļþ
¼ûºóÎÄ
2.½«CSSÎļþ±àÒë³ÉSWFÎļþ
ÔÚFlashBuilderÖÐÓÒ¼üCSSÎļþ£¬Ñ¡ÔñCompile CSS to SWF£¬
Õâʱbin-debugĿ¼ÏµĶÔӦλÖþͻáÉú³ÉÒ»¸öÓëCSSͬÃûµÄSWFÎļþ¡£
Ñ¡Öкó¸ÃÑ¡ÏîÇ°»áÓй´£¬Ö®ºóÖ»ÒªÐÞ¸ÄÁËCSSÎļþ£¬¾Í»á×Ô¶¯±àÒë³ÉSWF
2.ÓÃstyleManager¼ÓÔØSWF
´úÂëÖÐÕâÑùд£º
this.styleManager.loadStyleDeclarations2("MyCss1.swf"); //´úÂëÖÐÌîдÉÏÒ»²½ÓÉCSSÉú³ÉµÄSWFÎļþ·¾¶
CSSд·¨£º
MyCss1.css
/* CSS file */
/*ÃüÃû¿Õ¼ä*/
@namespace s "library://ns.adobe.com/flex/spark";
@namespace mx "library://ns.adobe.com/flex/mx";
/*ʹÓÃskinÀàÀ´¶¨ÒåƤ·ô£¬ËùÒÔÒªÓÃClassReferenceº¯Êý*/
s|List{
skin-class:ClassReference("skins.ListSkin1");
}
/*·ûºÅ#´ú±íÖ¸¶¨µÄID*/
s|Label#labelExamples{
font-size:14;
color:#990099;
}
s|CheckBox{
font-size:9;
color:#FF3300;
}
s|RadioButton{
font-size:92;
color:#990099;
}
s|Button{
font-size:32;
color:#FF3300;
}
×¢£ºCSSÖÐÎÞ·¨ÉèÖÃItemRenderer£¬ ......
×î½üÔÚÑо¿flex¼¼Êõ£¬flexºÍflashµÄ½»»¥£¬flexºÍJavaµÄͨÐÅ¡£Ï±ßÊÇÒ»¸öflex¿ØÖÆswfÎļþÖÐÔª¼þµÄ·¶Àý£¬¸Õ½Ó´¥flex£¬ÈçÓв»¶ÔµÄµØ·½£¬´ó¼Ò¶àÌáÒâ¼û¡£
mxmlÎļþ£º
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
creationComplete="init()"
layout="absolute">
<mx:Script>
<![CDATA[
import mx.core.UIComponent;
import flash.display.Loader;
import flash.display.Sprite;
......
×î½üÔÚÑо¿flex¼¼Êõ£¬flexºÍflashµÄ½»»¥£¬flexºÍJavaµÄͨÐÅ¡£Ï±ßÊÇÒ»¸öflex¿ØÖÆswfÎļþÖÐÔª¼þµÄ·¶Àý£¬¸Õ½Ó´¥flex£¬ÈçÓв»¶ÔµÄµØ·½£¬´ó¼Ò¶àÌáÒâ¼û¡£
mxmlÎļþ£º
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
creationComplete="init()"
layout="absolute">
<mx:Script>
<![CDATA[
import mx.core.UIComponent;
import flash.display.Loader;
import flash.display.Sprite;
......
ÔÎĵØÖ·£ºhttp://blog.163.com/to_yht/blog/static/1227257742009741359326/
µ±³ÌÐò×öÍêºó£¬ÄãÊÇ·ñ»¹ÔÚΪÀÏÌ×µÄflex×é¼þĬÈÏЧ¹û·¢³î£¿ÊÇ·ñ»¹ÔÚΪÔõÑùÉèÖÃ×Ô¼ºµÄƤ·ô浡£ÄÇôÕâЩ¿ÉÄÜÊÇÄãÐèÒªµÄ¡£
Ò» ³¬¿áƤ·ôÖ÷ÌâÍƼö£º
1£® kingnarestyle:
ÏÂÔصØÖ·£ºhttp://code.google.com/p/kingnarestyle/
2£®Carbon£º
ÏÂÔصØÖ·£ºhttp://www.fillcolors.com/post.cfm/carbon
3£®Aqua£º
ÏÂÔصØÖ·£ºhttp://www.fillcolors.com/post.cfm/aqua
4£®Rainbow£º
ÏÂÔصØÖ·£ºhttp://www.fillcolors.com/post.cfm/rainbow
¶þ flexƤ·ôÖ÷ÌâÍøÕ¾ÍƼö£º
http://fleksray.org/Flex_skin.html
http://www.scalenine.com/(ÓÐÎÒϲ»¶µÄÒøÉ«Ö÷Ì⣬ºÚÉ«Ö÷ÌâºÍ½Û×ÓÖ÷Ìâ)
Èý flexƤ·ôÖÆ×÷½Ì³ÌÍƼö£º
ÓÃflash cs3ÃÀ»¯flex3Ö®skin¿ª·¢
ÀûÓÃCreative Suite 3 and Flex Builder 3ÖÆ×÷Flex 3Ó¦ÓõÄƤ·ôºÍÑùʽ
ÀûÓÃCreative Suite 3 and Flex Builder 3ÖÆ×÷Flex 3Ó¦ÓõÄƤ·ôºÍÑùʽ£¨¶þ£©
ÀûÓÃCreative Suite 3 and Flex Builder 3ÖÆ×÷Flex 3Ó¦ÓõÄƤ·ôºÍÑù ......
eclipseÒ»¸öÏîÄ¿ÖÐͬʱ¿ª·¢flexºÍj2eeµÄ»·¾³ÅäÖÃ
ÒòΪ¹¤×÷ÐèÒª£¬Ñ§ÁËÒ»ÖÜflex½ñÌ쿪ʼÑо¿Óë·þÎñÆ÷ͨÐÅ£¬Ñ¡ÔñÁËÃâ·ÑµÄBlazeDS¡£ÓÉÓÚ֮ǰ×öÏîÄ¿ÓõÄÊÇeclipse europa£¬¾Í°Ñflex builder 3 pluginÖ±½Ó°²×°µ½ÔÓеÄeclipseÉÏÁË£¬ÕâÑùÔÙÅäÖõÄʱºò¿Í»§¶Ë±à³ÌÓõÄflexºÍ·þÎñÆ÷¶ËµÄJ2EE¾ÍÄÜÕûºÏµ½Ò»¸ö¹¤³ÌÏÂÁË£¬Ï£Íû¶ÔÓÚÔÝʱÓÉjsp±äflexÏîÄ¿µÄÈËÈÝÒ×ÊìϤºÍµ÷ÊÔ¿ª·¢»·¾³¡£
Ïà¹ØÈí¼þ¼°¹¤¾ß£º
1. Eclipse europa
2. Flex builder 3 (SDK3.3)
3. Tomcat 5.5
4. JDK 1.5
5. Blazeds-turnkey-3.2
Ç°4ÏîµÄ°²×°¾Í²»ÓýéÉÜÁË£¬Í¨¹ýeclipseµÄperformance°ÑÐèÒªµÄserverºÍjre¼°flexµÄ»·¾³²ÎÊý¶¼ÅäÖúþͿÉÒÔÁË¡£ÏÂÃ濪ʼ½øÈëflex+j2eeͬÏîÄ¿µÄ´îÅä²½Öè¡£
Ò»¡¢´´½¨WebÏîÄ¿ File->New->Project->Web->Dynamic Web Project, ¹¤³ÌÃûΪblazeDSApp£¬ÏÂÒ»²½Ö¸¶¨·þÎñÆ÷Ϊtomcat5.5£¬ÏÂÒ»²½…¾ùĬÈϵ½½áÊø£¬ÕâÑùÒ»¸öweb¹¤³Ì´´½¨ºÃÁË¡£
¶þ¡¢½âѹËõBlazeds-turnkey-3.2£¬ÌáÈ¡ÆäÖеÄblazeds.war£¬²¢½âѹµ½Ò»¸öµØ·½±ÈÈçD:\blazeds, ²¢°Ñblazeds.warÒ²·ÅÔÚͬһ¸öĿ¼ÏÂ
Èý¡¢<1>°ÑD:\blazeds\WEB-INFϵÄflexÎļþ¼Ð¸´ÖƵ½blazeDSApp¹¤³ÌµÄWebContent\WEB-INFÏÂ
<2>° ......
×ܼǼÊý:792; ×ÜÒ³Êý:132; ÿҳ6 Ìõ;
Ê×Ò³ ÉÏÒ»Ò³ [1] [2] [3] [4] 5
[6] [7] [8] [9] [10] ÏÂÒ»Ò³ βҳ