Things stay like this:
I made a new application to my Red5 server. It's a class named App1 and it
has this function named unu(). I finally managed to call it from my Flex
application. I created a new NetConnection and used the call() method. unu()
runs on the server and i'm not interested in returning anything. Let me tell
you what unu() does: It creates a new JFrame with a JButton in it.
I want to invoke a method from my flex application(client side) when the
JButton is clicked.So i tried this:
public void actionPerformed(ActionEvent evt){
IConnection conn = Red5.getConnectionLocal();
if (conn instanceof IServiceCapableConnection) {
IServiceCapableConnection sc = (IServiceCapableConnection) conn;
sc.invoke(fnc);
}
}
But doesn`t work. If i do that invoke thing in unu() where i create the
JFrame and JButton it works fine. I checked and function actionPerformed()
is launched. I assume that something happens to the connection or something.
Though the client is still connected. But the client tells my server to
launch unu() and now ... when i press the button i want my server to tell
the client(THE SAME CLIENT) to launch another function(Flex function) ...
Any ideea how i can do that? Or why this algorithm isn't working? It
shouldn't be a hard thing to do. It's like in a chat application when user A
sends a message to user B. the message gets to the server first and then the
server has to pass it to user B. So ... the same thing: the server has to
send something to the client.
I really don't understand very well how these classes work .. Red5 classes
... IClient, IConnection ... i found that documentation
http://dl.fancycode.com/red5/api/ but... without any examples ... and short
explanation ...
I am a beginner with Java too ... Though it's very much like ActionScript 3
...
_______________________________________________
osflash mailing list
[email protected]
http://osflash.org/mailman/listinfo/osflash_osflash.org