Package com.pspdfkit.media
Class MediaUri
-
- All Implemented Interfaces:
-
android.os.Parcelable
public class MediaUri implements Parcelable
Representation of the parsed URI used for media links.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public enum
MediaUri.UriType
Type of the media URI.
-
Field Summary
Fields Modifier and Type Field Description public final static Parcelable.Creator<MediaUri>
CREATOR
public final MediaUri.UriType
type
public final String
options
public final String
uri
-
Method Summary
Modifier and Type Method Description MediaUri.UriType
getType()
Type of the media uri. String
getOptions()
Options inside the [] brackets in pspdfkit://
link.String
getUri()
Uri part of the pspdfkit://
link.static MediaUri
parse(@NonNull() String fullUri)
Parse link media URI. boolean
isVideoUri()
Test if media uri is pointing to a video resource. Uri
getParsedUri()
Creates Uri object from the getUri. Uri
getFileUri(@NonNull() Context context)
Returns URI of the media file that will be played. MediaLinkUtils.VideoSettings
getVideoSettingsFromOptions()
Parses video settings from provided options. int
describeContents()
void
writeToParcel(Parcel dest, int flags)
int
hashCode()
boolean
equals(Object obj)
String
toString()
-
-
Method Detail
-
getType
@NonNull() MediaUri.UriType getType()
Type of the media uri.
- Returns:
Media uri type.
-
getOptions
@NonNull() String getOptions()
Options inside the [] brackets in
pspdfkit://
link.- Returns:
Raw string options.
-
parse
@NonNull() static MediaUri parse(@NonNull() String fullUri)
Parse link media URI.
- Parameters:
fullUri
- Full URI of the media file.
-
isVideoUri
boolean isVideoUri()
Test if media uri is pointing to a video resource.
- Returns:
true
if media uri points to video (local or youtube).
-
getParsedUri
@NonNull() Uri getParsedUri()
Creates Uri object from the getUri.
- Returns:
Uri object for the media link.
-
getFileUri
Uri getFileUri(@NonNull() Context context)
Returns URI of the media file that will be played.
- Returns:
File URI of the media content.
-
getVideoSettingsFromOptions
@NonNull() MediaLinkUtils.VideoSettings getVideoSettingsFromOptions()
Parses video settings from provided options. That is the content inside the [] brackets in
pspdfkit://
link.- Returns:
Video settings.
-
describeContents
int describeContents()
-
writeToParcel
void writeToParcel(Parcel dest, int flags)
-
hashCode
int hashCode()
-
-
-
-