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

flexͨ¹ýblazedsÓëjavaͨÐŵÄСÀý×Ó

ºÜ¼òµ¥µÄСÀý×Ó£¬ÊʺϳõѧÕßÀí½â
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.RemotingService">
<adapters>
<adapter-definition id="java-object"
class="flex.messaging.services.remoting.adapters.JavaAdapter"
default="true" />
</adapters>
<default-channels>
<channel ref="my-amf" />
</default-channels>
<destination id="firstJavaFlex">
<properties>
<source>flex.JavaFlex
</source>
</properties>
</destination>
</service>
3£¬testflex.mxml
<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx" minWidth="955" minHeight="600">
<fx:Declarations>
<!-- ½«·Ç¿ÉÊÓÔªËØ£¨ÀýÈç·þÎñ¡¢Öµ¶ÔÏ󣩷ÅÔÚ´Ë´¦ -->
<s:RemoteObject id="selectHello" destination="firstJavaFlex" fault="error(event)"/>
</fx:Declarations>
<fx:Script>
<!--[CDATA[
import mx.collections.ArrayCollection;
import mx.controls.Alert;
import mx.events.ResizeEvent;
import mx.rpc.events.FaultEvent;
import mx.rpc.events.ResultEvent;

[Bindable]
private var arraylist:ArrayCollection = new ArrayCollection([
{name:"ÄãºÃ",data:"ÄãºÃ£¡"},
{name:"ÄãÃǺÃ",data:"ÄãÃǺã¡"},
{name:"´ó¼ÒºÃ",data:"´ó¼ÒºÃ£¡"},
]);
private function changehandler(event:Event):void{
selectHello.helloJavaFlex(selected.selectedItem.data);
selectHello.addEventListener(ResultEvent.RESULT,remoteResult);
}
private function remoteResult(event:ResultEvent):void{
Alert.show(event.result.toString());
resultmess.text = event.result.toString();
}
priv


Ïà¹ØÎĵµ£º

´«ÖDz¥¿ÍJAVAÅàѵ2010 4 26SVN/CVS×ܽá

      ½ñÌìÎÒÔÚ×ö·É»ú¡£ÎªÊ²Ã´ËµÎÒÔÚ×ö·É»úÄØ£¡ÒòΪÕâÊÇÎÒ½ø´«ÖDz¥¿ÍÒÔÀ´£¬¸öÈ˸оõ·Ç³£ÖØÒªµÄÒ»ÌÿΣ¬µ«ÊÇÎÒ²»ÄÜÒ»ÏÂ×Ó¼ÇסËùËùÓеĶ«Î÷£¬×òÌìÍíÉÏ£¬¿´ÊÓƵ¿´µ½ÍíÉÏÈýµã£¬½ñÌìÉϿκÜÏ뼯ÖÐ×¢ÒâÁ¦£¬µ«ÊÇ×îÖÕ»¹ÊÇÈ̲»×¡´òÁËî§Ë¯£¬µ«½ñÌìµÄµÄ¿Î¸øÎҵĸоõÊǷdz£¾ßÓÐÁ¬¹áÐÔ£¬Ç°ÃæµÄ¿ÎÈç¹ûÌýµÃ²»ÊǺÜÇ ......

Flex Óë Asp.Net ͨ¹ý Remoting ·½Ê½½øÐÐͨѶ

Flex
Óë Asp.Net ͨ¹ý Remoting ·½Ê½½øÐÐͨѶ
Flex Óë Asp.Net ͨ¹ý Remoting ·½Ê½½øÐÐͨѶ (Ò»)http://hi.baidu.com/tsengyuen/blog/item/644e98a3353f7287471064ef.html
Flex Óë Asp.Net ͨ¹ý Remoting ·½Ê½½øÐÐͨѶ (¶þ)http://hi.baidu.com/tsengyuen/blog/item/af02730d58d6d7266059f3e8.html
Flex Óë Asp.Net ͨ ......

Java¾«µäÃæÊÔÌâÍƼö¶þ(´ó¼Ò¿ÉÒÔ°Ñ×Ô¼ºµÄ´ð°¸¸½ÉÏ)

***´ËÌâÒÔ¿¼²ì»ù´¡Îª×¼,±±¾©µÄ±ÊÊÔÌâ,¿ÉÄÜÓÐÈË×ö¹ý
Ìâ:дһ¸ö³ÌÐò£¬½âÎöÈçϸñʽµÄ×Ö·û´®£¬²¢½«½âÎöµÄÊý×ÖÐòÁдòÓ¡³öÀ´¡£
   ×Ö·û´®¸ñʽ¾ÙÀý£º -1~2, 3~3, 5~10, 7~15x3
   ~ ´ú±íÊý×ֵķ¶Î§£¬ -1~2 ´ú±í´Ó-1¿ªÊ¼µ½2Ö®¼äµÄËùÓÐÊý×Ö¡£ 3~3 ´ú±í´Ó3¿ªÊ¼µ½3µÄËùÓÐÊý×Ö£¬Ò²¾ÍÊÇ3
   7~15x3´ú ......

Java¶þ·Ö·¨

Ìù¶Î´úÂë,ÓÐÉÙÐí×¢ÊÍ:
package ibees;
import java.util.Arrays;
public class BinarySearch {

/**
* @param args
*/
public static void main(String[] args) {
double[] src = new double[]{1.3,9.9,10.89,12.89,89.0};
System.out.println(new BinarySearch().binarySearch(src, 89.0));
}

......

java ½øÖÆת»»

public class Test { 
      public static void main(String args[]) {  
        System.out.println(Integer.toBinaryString(20));   //Ê®½øÖÆ-->2½øÖÆ  
        System ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ