Packagecom.adobe.rtc.pods
Classpublic class HorizontalRoster
InheritanceHorizontalRoster Inheritance mx.core.UIComponent
ImplementsISessionSubscriber

The HorizontalRoster is a component for displaying the set of users horizontally. It consists of three separate horizontal List controls. It groups users by their role and places each group in a corresponding List. HorizontalRoster uses the UserManager as its model and displays sets of UserDescriptors. The roster allows a menu to be shown when a user item is clicked, thereby presenting choices that correspond to the selected user. The set of choices is either a default set or a custom set created by using useExternalMenuDatamenuData and showMenu().

See also

com.adobe.rtc.sharedManagers.UserManager
com.adobe.rtc.sharedManagers.descriptors.UserDescriptor


Public Properties
 PropertyDefined by
  AudienceIconClass : Class
[Embed(source="horizontalRosterAssets/iconParticipant.png")] Specifies the default user icon to use for users with a viewer role.
HorizontalRoster
  connectSession : IConnectSession
The IConnectSession with which this component is associated.
HorizontalRoster
  HostIconClass : Class
Specifies the default user icon to use for users with an owner role.
HorizontalRoster
  isSynchronized : Boolean
[read-only] Returns true if the model is synchronized; otherwise, false.
HorizontalRoster
  itemLastClicked : IListItemRenderer
[read-only] Returns the last user item clicked on the roster.
HorizontalRoster
  menuData : ArrayCollection
Specifies a custom dataProvider to supply to a menu when a user item is clicked.
HorizontalRoster
  ParticipantIconClass : Class
Specifies the default user icon to use for users with a publisher role.
HorizontalRoster
  useExternalMenuData : Boolean
Determines whether to use the default menu when a user is clicked (false) or allow a custom menu (true).
HorizontalRoster
Public Methods
 MethodDefined by
  
close():void
Disposes all listeners to the network and framework classes.
HorizontalRoster
  
getUserRole(p_userID:String):int
Returns the role of a given user for the room as a whole; it is equivalent to UserManager.getUserRole().
HorizontalRoster
  
setUserRole(p_userID:String, p_userRole:int):void
Sets the role of a given user for the room as a whole; it is equivalent to UserManager.setUserRole().
HorizontalRoster
  
showMenu():void
Causes a menu to appear using the custom menuData.
HorizontalRoster
  
subscribe():void
Tells the component to begin synchronizing with the service.
HorizontalRoster
Events
 EventSummaryDefined by
   Dispatched when a user's menu item is clicked if useExternalMenuData is set to true.HorizontalRoster
   Dispatched when a user's items are synchronized.HorizontalRoster
   Dispatched when a user is clicked if useExternalMenuData is set to true.HorizontalRoster
Property detail
AudienceIconClassproperty
public var AudienceIconClass:Class

[Embed(source="horizontalRosterAssets/iconParticipant.png")] Specifies the default user icon to use for users with a viewer role.

connectSessionproperty 
connectSession:IConnectSession  [read-write]

The IConnectSession with which this component is associated. Note that this may only be set once before subscribe() is called; re-sessioning of components is not supported. Defaults to the first IConnectSession created in the application.

Implementation
    public function get connectSession():IConnectSession
    public function set connectSession(value:IConnectSession):void
HostIconClassproperty 
public var HostIconClass:Class

Specifies the default user icon to use for users with an owner role.

isSynchronizedproperty 
isSynchronized:Boolean  [read-only]

Returns true if the model is synchronized; otherwise, false.

This property can be used as the source for data binding.

Implementation
    public function get isSynchronized():Boolean
itemLastClickedproperty 
itemLastClicked:IListItemRenderer  [read-only]

Returns the last user item clicked on the roster.

Implementation
    public function get itemLastClicked():IListItemRenderer
menuDataproperty 
menuData:ArrayCollection  [read-write]

Specifies a custom dataProvider to supply to a menu when a user item is clicked. This can be set on userItemClick and then followed by a showMenu command. To detect items on the menu being clicked, listen to the itemClick event.

Implementation
    public function get menuData():ArrayCollection
    public function set menuData(value:ArrayCollection):void
ParticipantIconClassproperty 
public var ParticipantIconClass:Class

Specifies the default user icon to use for users with a publisher role.

useExternalMenuDataproperty 
useExternalMenuData:Boolean  [read-write]

Determines whether to use the default menu when a user is clicked (false) or allow a custom menu (true). If set to true, the userItemClick event is fired on click. If a custom menu is used, the developer should supply a custom set of menu data with menuData and call showMenu.

The default value is false.

Implementation
    public function get useExternalMenuData():Boolean
    public function set useExternalMenuData(value:Boolean):void
Method detail
close()method
public function close():void

Disposes all listeners to the network and framework classes. Recommended for proper garbage collection of the component.

getUserRole()method 
public function getUserRole(p_userID:String):int

Returns the role of a given user for the room as a whole; it is equivalent to UserManager.getUserRole().

Parameters
p_userID:String — The user ID for the user being queried.

Returns
int
setUserRole()method 
public function setUserRole(p_userID:String, p_userRole:int):void

Sets the role of a given user for the room as a whole; it is equivalent to UserManager.setUserRole().

Parameters
p_userID:String — The role value to set on the specified user.
 
p_userRole:int — The ID of the user whose role should be set.
showMenu()method 
public function showMenu():void

Causes a menu to appear using the custom menuData. It should be used with useExternalMenuData=true.

subscribe()method 
public function subscribe():void

Tells the component to begin synchronizing with the service. For UIComponent-based components such as this one, subscribe() is called automatically upon being added to the displayList. For "headless" components, this method must be called explicitly.

Event detail
itemClickevent 
Event object type: mx.events.MenuEvent

Dispatched when a user's menu item is clicked if useExternalMenuData is set to true.

synchronizationChangeevent  
Event object type: com.adobe.rtc.events.UserEvent

Dispatched when a user's items are synchronized.

userItemClickevent  
Event object type: flash.events.Event

Dispatched when a user is clicked if useExternalMenuData is set to true.





 

Send me an e-mail when comments are added to this page | Comment Report

Current page: http://livedocs.adobe.com/labs/acrobatcom/com/adobe/rtc/pods/HorizontalRoster.html