Class SpatioTemporalDecompositionImpl
java.lang.Object
org.opencastproject.metadata.mpeg7.SpatioTemporalDecompositionImpl
- All Implemented Interfaces:
org.opencastproject.mediapackage.XmlElement,SpatioTemporalDecomposition
Default implementation of a spatio temporal decomposition.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected booleanFlag to indicate whether the elements in this decomposition may exhibit gapsprotected booleanFlag to indicate whether the elements in this decomposition may overlapThe list of videotext elements -
Constructor Summary
ConstructorsConstructorDescriptionSpatioTemporalDecompositionImpl(boolean gap, boolean overlap) Creates a new spatio temporal decomposition. -
Method Summary
Modifier and TypeMethodDescriptionaddVideoText(Textual text, Rectangle boundary, MediaTime time) Adds the specified text as aVideoTextelement to the decomposition.voidaddVideoText(VideoText videoText) Adds theVideoTextelement to the decomposition.Returns all the video text elements from this decomposition.getVideoText(String id) Returns theVideoTextelement with the given identifier ornullif there is no such element.booleanhasGap()Returnstrueif the segment has a gap.booleanReturnstrueif the segment overlaps with another one.voidsetGap(boolean hasGap) Set thehasGapproperty indicating that there may be gaps in between the segments.voidsetOverlapping(boolean isOverlapping) Set theisOverlappingproperty indicating that some segments may be overlapping.
-
Field Details
-
hasGap
protected boolean hasGapFlag to indicate whether the elements in this decomposition may exhibit gaps -
hasOverlap
protected boolean hasOverlapFlag to indicate whether the elements in this decomposition may overlap -
videoTexts
The list of videotext elements
-
-
Constructor Details
-
SpatioTemporalDecompositionImpl
public SpatioTemporalDecompositionImpl(boolean gap, boolean overlap) Creates a new spatio temporal decomposition.- Parameters:
gap-trueif there are gaps in the decompositionoverlap-trueif there are overlapping elements
-
-
Method Details
-
hasGap
public boolean hasGap()Returnstrueif the segment has a gap.- Specified by:
hasGapin interfaceSpatioTemporalDecomposition- Returns:
trueif the segment has a gap- See Also:
-
isOverlapping
public boolean isOverlapping()Returnstrueif the segment overlaps with another one.- Specified by:
isOverlappingin interfaceSpatioTemporalDecomposition- Returns:
trueif the segment overlaps- See Also:
-
setGap
public void setGap(boolean hasGap) Set thehasGapproperty indicating that there may be gaps in between the segments.- Specified by:
setGapin interfaceSpatioTemporalDecomposition- Parameters:
hasGap-trueif there are gaps- See Also:
-
setOverlapping
public void setOverlapping(boolean isOverlapping) Set theisOverlappingproperty indicating that some segments may be overlapping.- Specified by:
setOverlappingin interfaceSpatioTemporalDecomposition- Parameters:
isOverlapping-trueif elements are overlapping- See Also:
-
addVideoText
Adds the specified text as aVideoTextelement to the decomposition.- Specified by:
addVideoTextin interfaceSpatioTemporalDecomposition- Parameters:
text- the textboundary- the text's bounding boxtime- the time and duration- Returns:
- the new video text element
- See Also:
-
addVideoText
Adds theVideoTextelement to the decomposition.- Specified by:
addVideoTextin interfaceSpatioTemporalDecomposition- Parameters:
videoText- the video text- See Also:
-
getVideoText
Returns all the video text elements from this decomposition.- Specified by:
getVideoTextin interfaceSpatioTemporalDecomposition- Returns:
- the video text elements
- See Also:
-
getVideoText
Returns theVideoTextelement with the given identifier ornullif there is no such element.- Specified by:
getVideoTextin interfaceSpatioTemporalDecomposition- Parameters:
id- the video text id- Returns:
- the video text element
- See Also:
-
toXml
- Specified by:
toXmlin interfaceorg.opencastproject.mediapackage.XmlElement- See Also:
-