Expand my Community achievements bar.

FilePublisher / FileSubscriber initialization

Avatar

Level 1
Hi,

I was wondering why FilePublisher and FileSubscriber need to
be manually initialized ?

But mostly : why this function isn't documented ?

Thanks



Erick
5 Replies

Avatar

Former Community Member
Hi,



FilePublisher/FileSubscriber like other pub/sub components (
Audio , WebCam etc) are required for uploading and downloading a
file in an afcs applications. You can use
FilePublisher/FileSubscriber instead of the FileShare Pod to have
your own UI built for file upload/download. FileManager is the
model underlying FilePub/Sub components and it is initialized when
you enter a cocomo room. But you need to create the Pub/Subs if you
want to upload/download files.

And which function is not documented ?

Thanks

Hironmay Basu

Avatar

Level 1
Actually i'm talking about the initialize() function in
FilePublisher and FileSubscriber Classes.

For exemples, I saw in the FilePublisher example ( provided
with the AFCS SDK ), that you need to call
filePublisher.initialize() before sending files. I have tried use a
filePublisher without initialize() step, but it throws an
exception. Trying to find some explanations, I looked in the AFCS
doc but found nothing...

Avatar

Former Community Member


Oof, that sounds like a plain old bug. We'll get it for the
next beta drop - thanks for catching it!

Avatar

Former Community Member
Hi,



FilePublisher currently is an UIComponent and needs to be
added to the DisplayList, which automatically calls the initialize
function. The Initialize function creates some component and so you
get an RTE if you don't do it. Is there a way that you put it in
the DisplayList ? We have thought about decoupling this component
from being added to the DisplayList but that will be in some later
drop. But we will definitely look into it.



Thanks

Hironmay Basu

Avatar

Level 1
Thanks for this precisions. It wasn't clear for me in the
FilePublisherExample from the SDK. I even didn't saw it was a
UIComponent :). To be honest, it seems little strange for me, i
don't get what the "view" is for. Personnally, I will continue to
use it invisible, after a initialize() call...

Anyway, thanks for the help