패키지 | org.osmf.net.httpstreaming |
클래스 | public class DefaultHTTPStreamingSwitchManager |
상속 | DefaultHTTPStreamingSwitchManager RuleSwitchManagerBase NetStreamSwitchManagerBase EventDispatcher Object |
언어 버전: | ActionScript 3.0 |
제품 버전: | OSMF 2.0 |
런타임 버전: | Flash Player 10, AIR 1.5 |
관련 API 요소
org.osmf.net.abr.RuleBase
속성 | 정의 주체 | ||
---|---|---|---|
actualIndex : int [읽기 전용]
The index of the currently downloading quality level
| RuleSwitchManagerBase | ||
autoSwitch : Boolean [재정의] | RuleSwitchManagerBase | ||
climbFactor : Number
A factor to be applied when switching up. | DefaultHTTPStreamingSwitchManager | ||
constructor : Object
지정된 객체 인스턴스의 클래스 객체 또는 생성자 함수에 대한 참조입니다. | Object | ||
currentIndex : uint [재정의] [읽기 전용] | RuleSwitchManagerBase | ||
emergencyRules : Vector.<RuleBase> [읽기 전용]
Array of normal rules to be used in the algorithm. | RuleSwitchManagerBase | ||
maxAllowedIndex : int
The highest stream index that the switching manager is
allowed to switch to. | NetStreamSwitchManagerBase | ||
maxDownSwitchLimit : int
The maximum difference between the indices of the old
and new quality level when switching down. | DefaultHTTPStreamingSwitchManager | ||
maxReliabilityRecordSize : uint
The maximum length of the reliability record (how many switches to remember)
| DefaultHTTPStreamingSwitchManager | ||
maxUpSwitchLimit : int
The maximum difference between the indices of the old
and new quality level when switching up. | DefaultHTTPStreamingSwitchManager | ||
metricRepository : MetricRepository [읽기 전용]
The metric repository responsible with providing the metrics
| RuleSwitchManagerBase | ||
minReliability : Number
The minimum reliability for a quality level to be used. | DefaultHTTPStreamingSwitchManager | ||
minReliabilityRecordSize : uint
The minimum length of the reliability record below which reliability is not an issue
| DefaultHTTPStreamingSwitchManager | ||
normalRules : Vector.<RuleBase> [읽기 전용]
Array of normal rules to be used in the algorithm. | DefaultHTTPStreamingSwitchManager | ||
normalRuleWeights : Vector.<Number>
The weights of the normal rules (their importance in the algorithm).
Valid values must obey the following rules:
same number of weights as there are rules
all rules must be equal or greater than zero
at least one weight must be non-zero
| DefaultHTTPStreamingSwitchManager |
메서드 | 정의 주체 | ||
---|---|---|---|
DefaultHTTPStreamingSwitchManager(notifier:EventDispatcher, switcher:NetStreamSwitcher, metricRepository:MetricRepository, emergencyRules:Vector.<RuleBase> = null, autoSwitch:Boolean = true, normalRules:Vector.<RuleBase> = null, normalRuleWeights:Vector.<Number> = null, minReliability:Number = 0.85, minReliabilityRecordSize:uint = 5, maxReliabilityRecordSize:uint = 30, climbFactor:Number = 0.9, maxUpSwitchLimit:int = 1, maxDownSwitchLimit:int = 2)
Constructor. | DefaultHTTPStreamingSwitchManager | ||
addEventListener(type:String, listener:Function, useCapture:Boolean = false, priority:int = 0, useWeakReference:Boolean = false):void
리스너에서 이벤트 알림을 받을 수 있도록 EventDispatcher 객체에 이벤트 리스너 객체를 등록합니다. | EventDispatcher | ||
이벤트를 이벤트 흐름으로 전달합니다. | EventDispatcher | ||
The current reliability of the specified index. | DefaultHTTPStreamingSwitchManager | ||
[재정의]
Returns an index that satisfies the maxBitrate constraint
| DefaultHTTPStreamingSwitchManager | ||
[재정의]
Computes the necessary rules and metrics and determines the index to switch to. | DefaultHTTPStreamingSwitchManager | ||
EventDispatcher 객체에 특정 유형의 이벤트에 대한 리스너가 등록되어 있는지 여부를 확인합니다. | EventDispatcher | ||
지정된 속성이 객체에 정의되어 있는지 여부를 나타냅니다. | Object | ||
Object 클래스의 인스턴스가 매개 변수로 지정된 객체의 프로토타입 체인에 있는지 여부를 나타냅니다. | Object | ||
지정된 속성이 존재하고 열거 가능한지 여부를 나타냅니다. | Object | ||
EventDispatcher 객체에서 리스너를 제거합니다. | EventDispatcher | ||
루프 작업에서 동적 속성을 사용할 수 있는지 여부를 설정합니다. | Object | ||
[재정의] | RuleSwitchManagerBase | ||
로캘별 규칙에 따라 서식이 지정된 이 객체의 문자열 표현을 반환합니다. | Object | ||
지정된 객체의 문자열 표현을 반환합니다. | Object | ||
지정된 객체의 프리미티브 값을 반환합니다. | Object | ||
이 EventDispatcher 객체 또는 조상 객체에 지정한 이벤트 유형에 대한 이벤트 리스너가 등록되어 있는지 여부를 확인합니다. | EventDispatcher |
메서드 | 정의 주체 | ||
---|---|---|---|
Determines maximum available index whose declared bitrate is smaller than maxBitrate. | DefaultHTTPStreamingSwitchManager | ||
Determines whether an index is reliable.
This is achieved by comparing the index's reliability with the minimumReliability
| DefaultHTTPStreamingSwitchManager | ||
Array of normal rules to be used in the algorithm. | DefaultHTTPStreamingSwitchManager |
climbFactor | 속성 |
climbFactor:Number
언어 버전: | ActionScript 3.0 |
제품 버전: | OSMF 2.0 |
런타임 버전: | Flash Player 10, AIR 1.5 |
A factor to be applied when switching up. For example: currently playing 300kbps; new ideal bitrate = 1000kbps This means that: max bitrate = 300 + climbFactor x (1000 - 300)
It must be equal or greater than 0
구현
public function get climbFactor():Number
public function set climbFactor(value:Number):void
오류
ArgumentError — If it is set to a negative value
|
maxDownSwitchLimit | 속성 |
maxDownSwitchLimit:int
언어 버전: | ActionScript 3.0 |
제품 버전: | OSMF 2.0 |
런타임 버전: | Flash Player 10, AIR 1.5 |
The maximum difference between the indices of the old and new quality level when switching down. Set this to a -1 to disable the constraint.
This works in conjunction with the reliability constraint. If no reliable stream is available inside the maxDownSwitchLimit, no switch will be performed. The maxDownSwitchLimit constraint does not apply to emergency switches.
구현
public function get maxDownSwitchLimit():int
public function set maxDownSwitchLimit(value:int):void
maxReliabilityRecordSize | 속성 |
maxUpSwitchLimit | 속성 |
maxUpSwitchLimit:int
언어 버전: | ActionScript 3.0 |
제품 버전: | OSMF 2.0 |
런타임 버전: | Flash Player 10, AIR 1.5 |
The maximum difference between the indices of the old and new quality level when switching up. Set this to a -1 to disable the constraint.
This works in conjunction with the reliability constraint. If no reliable stream is available inside the maxUpSwitchLlimit, no switch will be performed.
구현
public function get maxUpSwitchLimit():int
public function set maxUpSwitchLimit(value:int):void
minReliability | 속성 |
minReliability:Number
언어 버전: | ActionScript 3.0 |
제품 버전: | OSMF 2.0 |
런타임 버전: | Flash Player 10, AIR 1.5 |
The minimum reliability for a quality level to be used. This value must be a number in the [0-1] interval (inclusive)
구현
public function get minReliability():Number
public function set minReliability(value:Number):void
오류
ArgumentError — If it is set to an invalid value
|
minReliabilityRecordSize | 속성 |
minReliabilityRecordSize:uint
언어 버전: | ActionScript 3.0 |
제품 버전: | OSMF 2.0 |
런타임 버전: | Flash Player 10, AIR 1.5 |
The minimum length of the reliability record below which reliability is not an issue
구현
public function get minReliabilityRecordSize():uint
public function set minReliabilityRecordSize(value:uint):void
normalRules | 속성 |
normalRuleWeights | 속성 |
normalRuleWeights:Vector.<Number>
언어 버전: | ActionScript 3.0 |
제품 버전: | OSMF 2.0 |
런타임 버전: | Flash Player 10, AIR 1.5 |
The weights of the normal rules (their importance in the algorithm). Valid values must obey the following rules:
- same number of weights as there are rules
- all rules must be equal or greater than zero
- at least one weight must be non-zero
구현
public function get normalRuleWeights():Vector.<Number>
public function set normalRuleWeights(value:Vector.<Number>):void
오류
ArgumentError — If the weights are not valid,
by breaking at least one of the above criteria
|
DefaultHTTPStreamingSwitchManager | () | 생성자 |
public function DefaultHTTPStreamingSwitchManager(notifier:EventDispatcher, switcher:NetStreamSwitcher, metricRepository:MetricRepository, emergencyRules:Vector.<RuleBase> = null, autoSwitch:Boolean = true, normalRules:Vector.<RuleBase> = null, normalRuleWeights:Vector.<Number> = null, minReliability:Number = 0.85, minReliabilityRecordSize:uint = 5, maxReliabilityRecordSize:uint = 30, climbFactor:Number = 0.9, maxUpSwitchLimit:int = 1, maxDownSwitchLimit:int = 2)
언어 버전: | ActionScript 3.0 |
제품 버전: | OSMF 2.0 |
런타임 버전: | Flash Player 10, AIR 1.5 |
Constructor.
매개 변수notifier:EventDispatcher — An object that dispatches the HTTPStreamingEvent.RUN_ALGORITHM event
| |
switcher:NetStreamSwitcher — The NetStreamSwitcher to use for switching
| |
metricRepository:MetricRepository — The repository responsible with providing metrics
| |
emergencyRules:Vector.<RuleBase> (default = null ) — Array of rules to be used in the algorithm.
An emergency rule can only recommend lower bitrates than the current one.
| |
autoSwitch:Boolean (default = true ) — Flag deciding whether autoSwitch should be enabled
| |
normalRules:Vector.<RuleBase> (default = null ) — Array of normal rules to be used in the algorithm.
A normal rule can recommend both lower and higher bitrates than the current one.
| |
normalRuleWeights:Vector.<Number> (default = null ) — The weights of the normal rules (their importance in the algorithm)
| |
minReliability:Number (default = 0.85 ) — The minimum reliability for a quality level to be used
| |
minReliabilityRecordSize:uint (default = 5 ) — The maximum length of the reliability record (how many switches to remember)
| |
maxReliabilityRecordSize:uint (default = 30 ) — The minimum length of the reliability record below which reliability is not an issue
| |
climbFactor:Number (default = 0.9 ) — A factor to be applied when switching up. For example:
currently playing 300kbps; new ideal bitrate = 1000kbps
This means that: max bitrate = 300 + climbFactor x (1000 - 300)
| |
maxUpSwitchLimit:int (default = 1 ) — The maximum difference between the indices of the old and new quality level when switching up.
Set this to -1 to disable the constraint.
This works in conjunction with the reliability constraint. If no reliable stream is available inside the
maxUpSwitchLimit, no switch will be performed.
| |
maxDownSwitchLimit:int (default = 2 ) — The maximum difference between the indices of the old and new quality level when switching down.
Set this to -1 value to disable the constraint.
This works in conjunction with the reliability constraint. If no reliable stream is available inside the
maxDownSwitchLimit, no switch will be performed. The maxDownSwitchLimit constraint does not apply to
emergency switches.
|
getCurrentReliability | () | 메서드 |
getMaxIndex | () | 메서드 |
protected function getMaxIndex(maxBitrate:Number, emergencyFlag:Boolean = false):uint
언어 버전: | ActionScript 3.0 |
제품 버전: | OSMF 2.0 |
런타임 버전: | Flash Player 10, AIR 1.5 |
Determines maximum available index whose declared bitrate is smaller than maxBitrate.
Only reliable indices (indices that pass the isReliable()
function) are taken into consideration.
매개 변수
maxBitrate:Number — The maximum bitrate to which the index must comply
| |
emergencyFlag:Boolean (default = false )
|
uint — The index satisfying the aforementioned condition
|
관련 API 요소
getNewEmergencyIndex | () | 메서드 |
getNewIndex | () | 메서드 |
isReliable | () | 메서드 |
setNormalRules | () | 메서드 |
protected function setNormalRules(value:Vector.<RuleBase>):void
언어 버전: | ActionScript 3.0 |
제품 버전: | OSMF 2.0 |
런타임 버전: | Flash Player 10, AIR 1.5 |
Array of normal rules to be used in the algorithm. A normal rule can recommend both lower and higher bitrates than the current one.
매개 변수
value:Vector.<RuleBase> |
관련 API 요소
Tue Jun 12 2018, 03:17 PM Z