| 패키지 | org.osmf.media |
| 클래스 | public class DefaultMediaFactory |
| 상속 | DefaultMediaFactory MediaFactory EventDispatcher Object |
| 언어 버전: | ActionScript 3.0 |
| 제품 버전: | OSMF 1.0 |
| 런타임 버전: | Flash Player 10, AIR 1.5 |
The default media factory can construct media elements of the following types:
-
VideoElement, using either:
- NetLoader (streaming or progressive)
- RTMPDynamicStreamingNetLoader (MBR streaming)
- HTTPStreamingNetLoader (HTTP streaming), if the CONFIG::FLASH_10_1 compiler flag is set to true
- F4MLoader (Flash Media Manifest files)
- DVRCastNetLoader (DVRCast)
-
SoundElement, using either:
- SoundLoader (progressive)
- NetLoader (streaming)
- ImageElement
- SWFElement
공용 속성
공용 메서드
| 메서드 | 정의 주체 | ||
|---|---|---|---|
Constructor. | DefaultMediaFactory | ||
![]() | addEventListener(type:String, listener:Function, useCapture:Boolean = false, priority:int = 0, useWeakReference:Boolean = false):void
리스너에서 이벤트 알림을 받을 수 있도록 EventDispatcher 객체에 이벤트 리스너 객체를 등록합니다. | EventDispatcher | |
![]() |
Adds the specified MediaFactoryItem to the factory. | MediaFactory | |
![]() |
Returns a MediaElement that can be created based on the specified
MediaResourceBase. | MediaFactory | |
![]() |
이벤트를 이벤트 흐름으로 전달합니다. | EventDispatcher | |
![]() |
Gets the MediaFactoryItem at the specified index. | MediaFactory | |
![]() |
Returns the MediaFactoryItem with the specified ID or null if the
specified MediaFactoryItem does not exist in this factory. | MediaFactory | |
![]() |
EventDispatcher 객체에 특정 유형의 이벤트에 대한 리스너가 등록되어 있는지 여부를 확인합니다. | EventDispatcher | |
![]() |
지정된 속성이 객체에 정의되어 있는지 여부를 나타냅니다. | Object | |
![]() |
Object 클래스의 인스턴스가 매개 변수로 지정된 객체의 프로토타입 체인에 있는지 여부를 나타냅니다. | Object | |
![]() |
Load a plugin identified by the specified resource. | MediaFactory | |
![]() |
지정된 속성이 존재하고 열거 가능한지 여부를 나타냅니다. | Object | |
![]() |
EventDispatcher 객체에서 리스너를 제거합니다. | EventDispatcher | |
![]() |
Removes the specified MediaFactoryItem from the factory. | MediaFactory | |
![]() |
루프 작업에서 동적 속성을 사용할 수 있는지 여부를 설정합니다. | Object | |
![]() |
로캘별 규칙에 따라 서식이 지정된 이 객체의 문자열 표현을 반환합니다. | Object | |
![]() |
지정된 객체의 문자열 표현을 반환합니다. | Object | |
![]() |
지정된 객체의 프리미티브 값을 반환합니다. | Object | |
![]() |
이 EventDispatcher 객체 또는 조상 객체에 지정한 이벤트 유형에 대한 이벤트 리스너가 등록되어 있는지 여부를 확인합니다. | EventDispatcher | |
보호 메서드
생성자 세부 정보
DefaultMediaFactory | () | 생성자 |
public function DefaultMediaFactory()| 언어 버전: | ActionScript 3.0 |
| 제품 버전: | OSMF 1.0 |
| 런타임 버전: | Flash Player 10, AIR 1.5 |
Constructor.
예제 예제 사용 방법
DefaultMediaFactoryExample.as
This example demonstrates how to manually use the DefaultMediaFactory
class to instantiate a video element.
package org.osmf.media
{
import flash.display.Sprite;
import org.osmf.containers.MediaContainer;
public class DefaultMediaFactoryExample extends Sprite
{
public function DefaultMediaFactoryExample()
{
// Construct a default media factory:
var factory:DefaultMediaFactory = new DefaultMediaFactory();
// Request the factory to create a media element that matches the passed URL:
var media:MediaElement = factory.createMediaElement(new URLResource("http://mediapm.edgesuite.net/strobe/content/test/AFaerysTale_sylviaApostol_640_500_short.flv"));
// Add a media container, and player to have the constructed VideoElement
// play back:
var mediaContainer:MediaContainer = new MediaContainer();
addChild(mediaContainer);
mediaContainer.width = 640;
mediaContainer.height = 500;
mediaContainer.addMediaElement(media);
new MediaPlayer(media);
}
}
}
Tue Jun 12 2018, 03:17 PM Z
상속되는 공용 속성 숨기기
상속되는 공용 속성 표시