Interface MediaObject
- All Superinterfaces:
KurentoObject
- All Known Subinterfaces:
AlphaBlending, BaseRtpEndpoint, Composite, Dispatcher, DispatcherOneToMany, Endpoint, FaceOverlayFilter, Filter, GenericMediaElement, GStreamerFilter, HttpEndpoint, HttpPostEndpoint, Hub, HubPort, ImageOverlayFilter, MediaElement, MediaPipeline, Mixer, OpenCVFilter, PassThrough, PlayerEndpoint, RecorderEndpoint, RtpEndpoint, SdpEndpoint, ServerManager, SessionEndpoint, UriEndpoint, WebRtcEndpoint, ZBarFilter
Properties
-
id: unique identifier assigned to this
MediaObjectat instantiation time.MediaPipelineIDs are generated with a GUID followed by suffix_kurento.MediaPipeline.MediaElementIDs are also a GUID with suffix_kurento.{ElementType}and prefixed by parent's ID.- MediaPipeline ID example
-
907cac3a-809a-4bbe-a93e-ae7e944c5cae_kurento.MediaPipeline - MediaElement ID example
-
907cac3a-809a-4bbe-a93e-ae7e944c5cae_kurento.MediaPipeline/403da25a-805b-4cf1-8c55-f190588e6c9b_kurento.WebRtcEndpoint
-
name: free text intended to provide a friendly name for this
MediaObject. Its default value is the same as the ID. -
tags: key-value pairs intended for applications to associate metadata
to this
MediaObjectinstance.
Events
-
ErrorEvent: reports asynchronous error events. It is recommended to always subscribe a listener to this event, as regular error from the pipeline will be notified through it, instead of through an exception when invoking a method.
-
Method Summary
Modifier and TypeMethodDescriptionaddErrorListener(EventListener<ErrorEvent> listener) Add aEventListenerfor eventErrorEvent.voidaddErrorListener(EventListener<ErrorEvent> listener, Continuation<ListenerSubscription> cont) Add aEventListenerfor eventErrorEvent.voidAdds a new tag to thisMediaObject.voidaddTag(String key, String value, Continuation<Void> cont) Asynchronous version of addTag:Continuation.onSuccess(F)is called when the action is done.voidaddTag(Transaction tx, String key, String value) Adds a new tag to thisMediaObject.Get Children of thisMediaObject.voidgetChildren(Continuation<List<MediaObject>> cont) Get Children of thisMediaObject.Get Children of thisMediaObject.intGetMediaObjectcreation time in seconds since Epoch.voidgetCreationTime(Continuation<Integer> cont) GetMediaObjectcreation time in seconds since Epoch.GetMediaObjectcreation time in seconds since Epoch.getId()Get Unique identifier of thisMediaObject.voidgetId(Continuation<String> cont) Get Unique identifier of thisMediaObject.getId(Transaction tx) Get Unique identifier of thisMediaObject.GetMediaPipelineto which thisMediaObjectbelongs.voidGetMediaPipelineto which thisMediaObjectbelongs.GetMediaPipelineto which thisMediaObjectbelongs.getName()Get ThisMediaObject's name.voidgetName(Continuation<String> cont) Get ThisMediaObject's name.getName(Transaction tx) Get ThisMediaObject's name.Get Parent of thisMediaObject.voidgetParent(Continuation<MediaObject> cont) Get Parent of thisMediaObject.getParent(Transaction tx) Get Parent of thisMediaObject.booleanGet Flag activating or deactivating sending the element's tags in fired events.voidGet Flag activating or deactivating sending the element's tags in fired events.Get Flag activating or deactivating sending the element's tags in fired events.Returns the value of given tag, or MEDIA_OBJECT_TAG_KEY_NOT_FOUND if tag is not defined.voidgetTag(String key, Continuation<String> cont) Asynchronous version of getTag:Continuation.onSuccess(F)is called when the action is done.getTag(Transaction tx, String key) Returns the value of given tag, or MEDIA_OBJECT_TAG_KEY_NOT_FOUND if tag is not defined.getTags()Returns all tags attached to thisMediaObject.voidgetTags(Continuation<List<Tag>> cont) Asynchronous version of getTags:Continuation.onSuccess(F)is called when the action is done.getTags(Transaction tx) Returns all tags attached to thisMediaObject.voidremoveErrorListener(ListenerSubscription listenerSubscription) Remove aListenerSubscriptionfor eventErrorEvent.voidremoveErrorListener(ListenerSubscription listenerSubscription, Continuation<Void> cont) Remove aListenerSubscriptionfor eventErrorEvent.voidRemoves an existing tag.voidremoveTag(String key, Continuation<Void> cont) Asynchronous version of removeTag:Continuation.onSuccess(F)is called when the action is done.voidremoveTag(Transaction tx, String key) Removes an existing tag.voidSet ThisMediaObject's name.voidsetName(String name, Continuation<Void> cont) Set ThisMediaObject's name.voidsetName(String name, Transaction tx) Set ThisMediaObject's name.voidsetSendTagsInEvents(boolean sendTagsInEvents) Set Flag activating or deactivating sending the element's tags in fired events.voidsetSendTagsInEvents(boolean sendTagsInEvents, Continuation<Void> cont) Set Flag activating or deactivating sending the element's tags in fired events.voidsetSendTagsInEvents(boolean sendTagsInEvents, Transaction tx) Set Flag activating or deactivating sending the element's tags in fired events.Methods inherited from interface KurentoObject
addEventListener, invoke, isCommited, release, release, release, removeEventListener, waitCommited, whenCommited, whenCommited
-
Method Details
-
getMediaPipeline
MediaPipeline getMediaPipeline()GetMediaPipelineto which thisMediaObjectbelongs. It returns itself when invoked for a pipeline object. -
getMediaPipeline
GetMediaPipelineto which thisMediaObjectbelongs. It returns itself when invoked for a pipeline object. -
getMediaPipeline
GetMediaPipelineto which thisMediaObjectbelongs. It returns itself when invoked for a pipeline object. -
getParent
MediaObject getParent()Get Parent of thisMediaObject.The parent of a
Hubor aMediaElementis itsMediaPipeline. AMediaPipelinehas no parent, so this property will be null. -
getParent
Get Parent of thisMediaObject.The parent of a
Hubor aMediaElementis itsMediaPipeline. AMediaPipelinehas no parent, so this property will be null. -
getParent
Get Parent of thisMediaObject.The parent of a
Hubor aMediaElementis itsMediaPipeline. AMediaPipelinehas no parent, so this property will be null. -
getId
String getId()Get Unique identifier of thisMediaObject.It's a synthetic identifier composed by a GUID and
MediaObjecttype. The ID is prefixed with the parent ID when the object has parent: ID_parent/ID_media-object.- Specified by:
getIdin interfaceKurentoObject
-
getId
Get Unique identifier of thisMediaObject.It's a synthetic identifier composed by a GUID and
MediaObjecttype. The ID is prefixed with the parent ID when the object has parent: ID_parent/ID_media-object. -
getId
Get Unique identifier of thisMediaObject.It's a synthetic identifier composed by a GUID and
MediaObjecttype. The ID is prefixed with the parent ID when the object has parent: ID_parent/ID_media-object. -
getChildren
List<MediaObject> getChildren()Get Children of thisMediaObject. -
getChildren
Get Children of thisMediaObject. -
getChildren
Get Children of thisMediaObject. -
getName
String getName()Get ThisMediaObject's name.This is just sugar to simplify developers' life debugging, it is not used internally for indexing nor identifying the objects. By default, it's the object's ID.
-
getName
Get ThisMediaObject's name.This is just sugar to simplify developers' life debugging, it is not used internally for indexing nor identifying the objects. By default, it's the object's ID.
-
getName
Get ThisMediaObject's name.This is just sugar to simplify developers' life debugging, it is not used internally for indexing nor identifying the objects. By default, it's the object's ID.
-
setName
Set ThisMediaObject's name.This is just sugar to simplify developers' life debugging, it is not used internally for indexing nor identifying the objects. By default, it's the object's ID.
-
setName
Set ThisMediaObject's name.This is just sugar to simplify developers' life debugging, it is not used internally for indexing nor identifying the objects. By default, it's the object's ID.
-
setName
Set ThisMediaObject's name.This is just sugar to simplify developers' life debugging, it is not used internally for indexing nor identifying the objects. By default, it's the object's ID.
-
getSendTagsInEvents
boolean getSendTagsInEvents()Get Flag activating or deactivating sending the element's tags in fired events. -
getSendTagsInEvents
Get Flag activating or deactivating sending the element's tags in fired events. -
getSendTagsInEvents
Get Flag activating or deactivating sending the element's tags in fired events. -
setSendTagsInEvents
void setSendTagsInEvents(boolean sendTagsInEvents) Set Flag activating or deactivating sending the element's tags in fired events. -
setSendTagsInEvents
Set Flag activating or deactivating sending the element's tags in fired events. -
setSendTagsInEvents
Set Flag activating or deactivating sending the element's tags in fired events. -
getCreationTime
int getCreationTime()GetMediaObjectcreation time in seconds since Epoch. -
getCreationTime
GetMediaObjectcreation time in seconds since Epoch. -
getCreationTime
GetMediaObjectcreation time in seconds since Epoch. -
addTag
-
addTag
Asynchronous version of addTag:Continuation.onSuccess(F)is called when the action is done. If an error occurs,Continuation.onError(Throwable)is called.- Parameters:
key- Tag name.value- Value associated to this tag.- See Also:
-
addTag
Adds a new tag to thisMediaObject. If the tag is already present, it changes the value.- Parameters:
key- Tag name.value- Value associated to this tag.
-
removeTag
Removes an existing tag. Exists silently with no error if tag is not defined.- Parameters:
key- Tag name to be removed
-
removeTag
Asynchronous version of removeTag:Continuation.onSuccess(F)is called when the action is done. If an error occurs,Continuation.onError(Throwable)is called.- Parameters:
key- Tag name to be removed- See Also:
-
removeTag
Removes an existing tag. Exists silently with no error if tag is not defined.- Parameters:
key- Tag name to be removed
-
getTag
-
getTag
Asynchronous version of getTag:Continuation.onSuccess(F)is called when the action is done. If an error occurs,Continuation.onError(Throwable)is called.- Parameters:
key- Tag key.- See Also:
-
getTag
Returns the value of given tag, or MEDIA_OBJECT_TAG_KEY_NOT_FOUND if tag is not defined.- Parameters:
key- Tag key.- Returns:
- The value associated to the given key. *
-
getTags
-
getTags
Asynchronous version of getTags:Continuation.onSuccess(F)is called when the action is done. If an error occurs,Continuation.onError(Throwable)is called.- See Also:
-
getTags
Returns all tags attached to thisMediaObject.- Returns:
- An array containing all key-value pairs associated with this
MediaObject. *
-
addErrorListener
Add aEventListenerfor eventErrorEvent. Synchronous call.- Parameters:
listener- Listener to be called on ErrorEvent- Returns:
- ListenerSubscription for the given Listener
-
addErrorListener
Add aEventListenerfor eventErrorEvent. Asynchronous call. Calls Continuation<ListenerSubscription> when it has been added.- Parameters:
listener- Listener to be called on ErrorEventcont- Continuation to be called when the listener is registered
-
removeErrorListener
Remove aListenerSubscriptionfor eventErrorEvent. Synchronous call.- Parameters:
listenerSubscription- Listener subscription to be removed
-
removeErrorListener
Remove aListenerSubscriptionfor eventErrorEvent. Asynchronous call. Calls Continuation<Void> when it has been removed.- Parameters:
listenerSubscription- Listener subscription to be removedcont- Continuation to be called when the listener is removed
-