Class Video.Builder

java.lang.Object
com.attribyte.parser.model.Video.Builder
Enclosing class:
Video

public static class Video.Builder extends Object
Builds an immutable video.
  • Method Details

    • getId

      public String getId()
      Gets the id.
      Returns:
      The id.
    • setId

      public Video.Builder setId(String id)
      Sets the id.
      Parameters:
      id - The id.
      Returns:
      A self-reference.
    • getLink

      public String getLink()
      Gets the link.
      Returns:
      The link.
    • getAltText

      public String getAltText()
      Gets the alternate text.
      Returns:
      The alternate text.
    • setAltText

      public Video.Builder setAltText(String altText)
      Sets the alternate text.
      Parameters:
      altText - The alternate text.
      Returns:
      A self-reference.
    • getTitle

      public String getTitle()
      Gets the title.
      Returns:
      The title.
    • setTitle

      public Video.Builder setTitle(String title)
      Sets the title.
      Parameters:
      title - The title.
      Returns:
      A self-reference.
    • getWidth

      public int getWidth()
      Gets the width.
      Returns:
      The width.
    • setWidth

      public Video.Builder setWidth(int width)
      Sets the width.
      Parameters:
      width - The width.
      Returns:
      A self-reference.
    • getHeight

      public int getHeight()
      Gets the height.
      Returns:
      The height.
    • setHeight

      public Video.Builder setHeight(int height)
      Sets the height.
      Parameters:
      height - The height.
      Returns:
      A self-reference.
    • getMediaType

      public String getMediaType()
      Gets the media type.
      Returns:
      The type.
    • setMediaType

      public Video.Builder setMediaType(String mediaType)
      Sets the type.
      Parameters:
      mediaType - The media type.
      Returns:
      A self-reference.
    • getBitrate

      public int getBitrate()
      Gets the bitrate.
      Returns:
      The bitrate.
    • setBitrate

      public Video.Builder setBitrate(int bitrate)
      Sets the bitrate.
      Parameters:
      bitrate - The bitrate.
      Returns:
      A self-reference.
    • getDurationMillis

      public long getDurationMillis()
      Gets the duration in milliseconds.
      Returns:
      The duration in milliseconds.
    • setDurationMillis

      public Video.Builder setDurationMillis(long durationMillis)
      Sets the duration in milliseconds.
      Parameters:
      durationMillis - The duration in milliseconds.
      Returns:
      A self-reference.
    • getAspect

      public Aspect getAspect()
      Gets the aspect.
      Returns:
      The aspect or null.
    • setAspect

      public Video.Builder setAspect(Aspect aspect)
      Sets the aspect.
      Parameters:
      aspect - The aspect.
      Returns:
      A self-reference.
    • getVariants

      public com.google.common.collect.ImmutableList<Video> getVariants()
      Gets the variants.
      Returns:
      The variants.
    • addVariant

      public Video.Builder addVariant(Video variant)
      Adds a variant.
      Parameters:
      variant - The variant.
      Returns:
      A self-reference.
    • setVariants

      public Video.Builder setVariants(Collection<Video> variants)
      Sets/replaces all the variants.
      Parameters:
      variants - The variants.
      Returns:
      A self-reference.
    • getImage

      public Image getImage()
      Gets the image.
      Returns:
      The image.
    • setImage

      public Video.Builder setImage(Image image)
      Sets the image.
      Parameters:
      image - The image.
      Returns:
      A self-reference.
    • build

      public Video build()
      Builds an immutable video.
      Returns:
      The video.