Packageflash.net
Classpublic class GroupSpecifier
InheritanceGroupSpecifier Inheritance Object

Language version: ActionScript 3.0
Runtime version: AIR 2

The GroupSpecifier class is used to construct the opaque groupspec strings that can be passed to NetStream and NetGroup constructors. A groupspec specifies an RTMFP Peer-to-Peer Group, including the capabilities, restrictions, and authorizations of the member using the groupspec.

By default, all capabilities are disabled, and peer-to-peer connections are allowed.

See also

flash.net.NetGroup
flash.net.NetStream


Public Properties
 PropertyDefined by
 Inheritedconstructor : Object
A reference to the class object or constructor function for a given object instance.
Object
  ipMulticastMemberUpdatesEnabled : Boolean
Specifies whether information about group membership can be exchanged on IP multicast sockets.
GroupSpecifier
  maxSupportedGroupspecVersion : int
[static][read-only] Specifies the maximum groupspec version supported by this runtime.
GroupSpecifier
  minGroupspecVersion : int
Specifies the minimum version number the generated groupspec will have.
GroupSpecifier
  multicastEnabled : Boolean
Specifies whether streaming is enabled for the NetGroup.
GroupSpecifier
  objectReplicationEnabled : Boolean
Specifies whether object replication is enabled for the NetGroup.
GroupSpecifier
  peerToPeerDisabled : Boolean
Specifies whether peer-to-peer connections are disabled for the NetGroup or NetStream.
GroupSpecifier
  postingEnabled : Boolean
Specifies whether posting is enabled for the NetGroup.
GroupSpecifier
 Inheritedprototype : Object
[static] A reference to the prototype object of a class or function object.
Object
  routingEnabled : Boolean
Specifies whether directed routing methods are enabled for the NetGroup.
GroupSpecifier
  serverChannelEnabled : Boolean
Specifies whether members of the NetGroup can open a channel to the server.
GroupSpecifier
Public Methods
 MethodDefined by
  
Creates a new GroupSpecifier object.
GroupSpecifier
  
Causes the associated NetStream or NetGroup to make an initial neighbor connection to the specified peerID.
GroupSpecifier
  
addIPMulticastAddress(address:String, port:* = null, source:String = null):void
Causes the associated NetStream or NetGroup to join the specified IP multicast group and listen to the specified UDP port.
GroupSpecifier
  
Returns a string that represents passwords for IP multicast publishing and for posting.
GroupSpecifier
  
[static] Encodes and returns a string that represents a bootstrap peerID.
GroupSpecifier
  
encodeIPMulticastAddressSpec(address:String, port:* = null, source:String = null):String
[static] Encodes and returns a string that represents an IP multicast socket address.
GroupSpecifier
  
[static] Encodes and returns a string that represents a posting password.
GroupSpecifier
  
[static] Encodes and returns a string that represents a multicast publishing password.
GroupSpecifier
  
Returns the opaque groupspec string, including authorizations, that can be passed to NetStream and NetGroup constructors.
GroupSpecifier
  
Returns the opaque groupspec string, without authorizations, that can be passed to NetStream and NetGroup constructors.
GroupSpecifier
 Inherited
Indicates whether an object has a specified property defined.
Object
 Inherited
Indicates whether an instance of the Object class is in the prototype chain of the object specified as the parameter.
Object
  
Adds a strong pseudorandom tag to the groupspec to make it unique.
GroupSpecifier
 Inherited
Indicates whether the specified property exists and is enumerable.
Object
  
setPostingPassword(password:String = null, salt:String = null):void
Specifies whether a password is required to post in the NetGroup.
GroupSpecifier
 Inherited
Sets the availability of a dynamic property for loop operations.
Object
  
setPublishPassword(password:String = null, salt:String = null):void
Specifies whether a password is required to publish a multicast stream in the NetStream.
GroupSpecifier
 Inherited
Returns the string representation of this object, formatted according to locale-specific conventions.
Object
  
Identical to the groupspecWithAuthorizations() method.
GroupSpecifier
 Inherited
Returns the primitive value of the specified object.
Object
Property detail
ipMulticastMemberUpdatesEnabledproperty
ipMulticastMemberUpdatesEnabled:Boolean  [read-write]

Language version: ActionScript 3.0
Runtime version: AIR 2

Specifies whether information about group membership can be exchanged on IP multicast sockets. IP multicast servers may send group membership updates to help bootstrap P2P meshes or heal partitions. Peers may send membership updates on the LAN to help bootstrap LAN P2P meshes and to inform on-LAN neighbors in global meshes that other on-LAN neighbors exist. These updates can improve P2P performance.

Implementation
    public function get ipMulticastMemberUpdatesEnabled():Boolean
    public function set ipMulticastMemberUpdatesEnabled(value:Boolean):void

See also

maxSupportedGroupspecVersionproperty 
maxSupportedGroupspecVersion:int  [read-only]

Language version: ActionScript 3.0
Runtime version: AIR 3

Specifies the maximum groupspec version supported by this runtime. A groupspec having a version greater than this will fail in this runtime.

Implementation
    public static function get maxSupportedGroupspecVersion():int

See also

minGroupspecVersionproperty 
minGroupspecVersion:int  [read-write]

Language version: ActionScript 3.0
Runtime version: AIR 3

Specifies the minimum version number the generated groupspec will have. The groupspec version number may be higher than this value if an option requiring a higher version number is enabled. A groupspec having a version number lower than the minimum supported will fail.

Implementation
    public function get minGroupspecVersion():int
    public function set minGroupspecVersion(value:int):void

See also

multicastEnabledproperty 
multicastEnabled:Boolean  [read-write]

Language version: ActionScript 3.0
Runtime version: AIR 2

Specifies whether streaming is enabled for the NetGroup. Methods used for streaming are NetStream.publish(), NetStream.play(), and NetStream.play2(). By default, this property is FALSE (streaming is disabled).

Implementation
    public function get multicastEnabled():Boolean
    public function set multicastEnabled(value:Boolean):void

See also

objectReplicationEnabledproperty 
objectReplicationEnabled:Boolean  [read-write]

Language version: ActionScript 3.0
Runtime version: AIR 2

Specifies whether object replication is enabled for the NetGroup. By default, this property is FALSE (object replication is disabled).

Implementation
    public function get objectReplicationEnabled():Boolean
    public function set objectReplicationEnabled(value:Boolean):void

See also

peerToPeerDisabledproperty 
peerToPeerDisabled:Boolean  [read-write]

Language version: ActionScript 3.0
Runtime version: AIR 2

Specifies whether peer-to-peer connections are disabled for the NetGroup or NetStream. By default, this property is FALSE (P2P connections are enabled).

If P2P connections are disabled (you set this property to TRUE), the P2P warning dialog is suppressed. In this situation, no neighbor connections can be made, and no group members use upstream bandwidth. Disabling P2P connections in this way is generally useful only when receiving multicast streams via pure IP multicast.

Implementation
    public function get peerToPeerDisabled():Boolean
    public function set peerToPeerDisabled(value:Boolean):void
postingEnabledproperty 
postingEnabled:Boolean  [read-write]

Language version: ActionScript 3.0
Runtime version: AIR 2

Specifies whether posting is enabled for the NetGroup. By default, this property is FALSE (posting is disabled).

Implementation
    public function get postingEnabled():Boolean
    public function set postingEnabled(value:Boolean):void

See also

routingEnabledproperty 
routingEnabled:Boolean  [read-write]

Language version: ActionScript 3.0
Runtime version: AIR 2

Specifies whether directed routing methods are enabled for the NetGroup. By default, this property is FALSE (directed routing methods are disabled).

Implementation
    public function get routingEnabled():Boolean
    public function set routingEnabled(value:Boolean):void

See also

serverChannelEnabledproperty 
serverChannelEnabled:Boolean  [read-write]

Language version: ActionScript 3.0
Runtime version: AIR 2

Specifies whether members of the NetGroup can open a channel to the server. By default, this property is FALSE.

A channel to the server must be opened before the server can provide supporting functions to group members. Depending on server configuration, supporting functions may or may not be provided over this channel.

Implementation
    public function get serverChannelEnabled():Boolean
    public function set serverChannelEnabled(value:Boolean):void
Constructor detail
GroupSpecifier()constructor
public function GroupSpecifier(name:String)

Language version: ActionScript 3.0
Runtime version: AIR 2

Creates a new GroupSpecifier object. By default, all capabilities are disabled, and peer-to-peer connections are allowed.

Parameters
name:String — A name for the Group on which all members must agree.

Throws
ArgumentError — if name is empty or null.

See also

Method detail
addBootstrapPeer()method
public function addBootstrapPeer(peerID:String):void

Language version: ActionScript 3.0
Runtime version: AIR 2

Causes the associated NetStream or NetGroup to make an initial neighbor connection to the specified peerID.

Parameters
peerID:String — The peerID to which an initial neighbor connection should be made to bootstrap into the peer-to-peer mesh.

See also

addIPMulticastAddress()method 
public function addIPMulticastAddress(address:String, port:* = null, source:String = null):void

Language version: ActionScript 3.0
Runtime version: AIR 2

Causes the associated NetStream or NetGroup to join the specified IP multicast group and listen to the specified UDP port.

Parameters
address:String — A String specifying the address of the IPv4 or IPv6 multicast group to join, optionally followed by a colon (":") and the UDP port number. If specifying an IPv6 address and a port, the IPv6 address must be enclosed in square brackets. Examples: "224.0.0.254", "224.0.0.254:30000", "ff03::ffff", "[ff03::ffff]:30000".
 
port:* (default = null) — The UDP port on which to receive IP multicast datagrams. If port is null, the UDP port must be specified in address. If not null, the UDP port must not be specified in address.
 
source:String (default = null) — If not null, a String specifying the source IP address of a source-specific multicast (SSM).

See also

authorizations()method 
public function authorizations():String

Language version: ActionScript 3.0
Runtime version: AIR 2

Returns a string that represents passwords for IP multicast publishing and for posting. Append the string to an unauthorized groupspec to enable features for which passwords have been set.

Returns
String

See also

encodeBootstrapPeerIDSpec()method 
public static function encodeBootstrapPeerIDSpec(peerID:String):String

Language version: ActionScript 3.0
Runtime version: AIR 2

Encodes and returns a string that represents a bootstrap peerID. If you append the string to a groupspec, the associated NetStream or NetGroup makes an initial neighbor connection to the specified peerID.

Parameters
peerID:String — The peerID to which an initial neighbor connection should be made to bootstrap into the peer-to-peer mesh.

Returns
String

See also

encodeIPMulticastAddressSpec()method 
public static function encodeIPMulticastAddressSpec(address:String, port:* = null, source:String = null):String

Language version: ActionScript 3.0
Runtime version: AIR 2

Encodes and returns a string that represents an IP multicast socket address. If you append the string to a groupspec, the associated NetStream or NetGroup joins the specified IP multicast group and listens to the specified UDP port.

Parameters
address:String — A String indicating the address of the IPv4 or IPv6 multicast group to join, optionally followed by a colon (":") and the UDP port number. If specifying an IPv6 address and a port, the IPv6 address must be enclosed in square brackets. Examples: "224.0.0.254", "224.0.0.254:30000", "ff03::ffff", "[ff03::ffff]:30000".
 
port:* (default = null) — The UDP port on which to receive IP multicast datagrams. If port is null, the UDP port must be specified in address. If not null, the UDP port must not be specified in address.
 
source:String (default = null) — If not null, a String specifying the source IP address of a source-specific multicast (SSM).

Returns
String

See also

encodePostingAuthorization()method 
public static function encodePostingAuthorization(password:String):String

Language version: ActionScript 3.0
Runtime version: AIR 2

Encodes and returns a string that represents a posting password. When posting is password-protected, you can concatenate the string to a groupspec to enable posting.

Parameters
password:String — The password to encode, which must match the posting password (if set) to enable NetGroup.post().

Returns
String

See also

encodePublishAuthorization()method 
public static function encodePublishAuthorization(password:String):String

Language version: ActionScript 3.0
Runtime version: AIR 2

Encodes and returns a string that represents a multicast publishing password. When multicast publishing is password-protected, you can concatenate the string to a groupspec to enable publishing.

Parameters
password:String — The password to encode, which must match the publish password (if set) to enable NetStream.publish().

Returns
String

See also

groupspecWithAuthorizations()method 
public function groupspecWithAuthorizations():String

Language version: ActionScript 3.0
Runtime version: AIR 2

Returns the opaque groupspec string, including authorizations, that can be passed to NetStream and NetGroup constructors.

Returns
String

See also

groupspecWithoutAuthorizations()method 
public function groupspecWithoutAuthorizations():String

Language version: ActionScript 3.0
Runtime version: AIR 2

Returns the opaque groupspec string, without authorizations, that can be passed to NetStream and NetGroup constructors.

Returns
String

See also

makeUnique()method 
public function makeUnique():void

Language version: ActionScript 3.0
Runtime version: AIR 2

Adds a strong pseudorandom tag to the groupspec to make it unique. The opaque groupspec string must then be passed verbatim to other potential members of the Group if they are to successfully join.

setPostingPassword()method 
public function setPostingPassword(password:String = null, salt:String = null):void

Language version: ActionScript 3.0
Runtime version: AIR 2

Specifies whether a password is required to post in the NetGroup.

Parameters
password:String (default = null) — The password that must be given to use NetGroup.post(). If null, no password is required to post.
 
salt:String (default = null) — Modifies the hash of the password to increase the difficulty of guessing it. For best security, this parameter should be set to a random value.

See also

setPublishPassword()method 
public function setPublishPassword(password:String = null, salt:String = null):void

Language version: ActionScript 3.0
Runtime version: AIR 2

Specifies whether a password is required to publish a multicast stream in the NetStream.

Parameters
password:String (default = null) — The password that must be given to use NetStream.publish(). If null, no password is required to publish.
 
salt:String (default = null) — Modifies the hash of the password to increase the difficulty of guessing it. For best security, this parameter should be set to a random value.

See also

toString()method 
public function toString():String

Language version: ActionScript 3.0
Runtime version: AIR 2

Identical to the groupspecWithAuthorizations() method. Convenience method to return the opaque groupspec string, including authorizations, that can be passed to NetStream and NetGroup constructors.

Returns
String

See also