nc.connect("rtmp://localhost/gg", 123, 456, 789);

this calls public boolean appConnect(IConnection conn, Object[]
params) method in Application, and params array contains 123, 456, 789
:)

if you want to use your own identifier [received from clients], you
should listen for appConnect, and store that data passed. AFAIK,
IClient.getId() is an internal id given by red5

-kerem

On 6/22/06, Eric C <[EMAIL PROTECTED]> wrote:
>
> Ok... for those who would like it, the code bellow does return a list of
> users.... only thing left is to figure out how to pass the user identifier
> myself.... nc.connect("rtmp://localhost/gg", 123, 456, 789); doesn't
> successfully pass any of those values as our id...
>
>
>
> package gg;
>
> import org.red5.server.adapter.ApplicationAdapter;
> import org.red5.server.api.IClient;
> import java.util.Set;
> import java.util.Iterator;
>
>
> public class Application extends ApplicationAdapter
> {
>  public String getUsers() {
>      StringBuffer users = new StringBuffer();
>      Set allUsers = getClients();
>      users.append(allUsers.size());
>      users.append(" users connected: ");
>
>      for (Iterator userIter = allUsers.iterator(); userIter.hasNext();)
>      {
>         users.append(((IClient)userIter.next()).getId());
>          users.append(" ");
>      }
>      return users.toString();
>  }
> }
>
>
>
>
>
> On 6/21/06, Eric C <[EMAIL PROTECTED]> wrote:
> >
> > Looking in the wrong direction.... seems I'm actually not getting a new
> version of my java lately.... so all the code fixes I've made aren't being
> used... (notticed the add function from the tutorial is still available even
> though I removed it from my code a few itterations ago)
> >
> >
> >
> > On 6/21/06, Eric C <[EMAIL PROTECTED]> wrote:
> > >
> > > Yes... I actually can stream video (great stuff), and my java function
> works fine if I return plain text... I just can't seem to grab the list of
> connections...
> > >
> > > Thanks,
> > >
> > >
> > >  -Eric
> > >
> > >
> > >
> > >
> > > On 6/21/06, Joachim Bauch <[EMAIL PROTECTED]> wrote:
> > > > Hi Eric,
> > > >
> > > > Eric C wrote:
> > > > > Yup...:
> > > > >
> > > > > var nc:NetConnection = new NetConnection();
> > > > > nc.connect("rtmp://localhost/gg");
> > > > > nc.onResult = function(obj)
> > > > >     {
> > > > >     trace (obj)
> > > > >     }
> > > > > nc.call("getUsers", nc);
> > > >
> > > > Is the Red5 application setup correctly?  You should check the
> response
> > > > you receive for the call to "connect".
> > > >
> > > > Joachim
> > > >
> > > > _______________________________________________
> > > > Red5 mailing list
> > > > [email protected]
> > > > http://osflash.org/mailman/listinfo/red5_osflash.org
> > > >
> > >
> > >
> >
> >
>
>
> _______________________________________________
> Red5 mailing list
> [email protected]
> http://osflash.org/mailman/listinfo/red5_osflash.org
>
>
>

_______________________________________________
Red5 mailing list
[email protected]
http://osflash.org/mailman/listinfo/red5_osflash.org

Reply via email to