De-duplicate Cue.Builder detailed javadoc

The details are available on the public fields, which are referenced with @see

PiperOrigin-RevId: 317092269
This commit is contained in:
ibaker 2020-06-18 14:43:42 +01:00 committed by Andrew Lewis
parent 685061431c
commit 590aade74b

View File

@ -587,39 +587,6 @@ public final class Cue {
* Sets the position of the {@code lineAnchor} of the cue box within the viewport in the
* direction orthogonal to the writing direction.
*
* <p>The interpretation of the {@code line} depends on the value of {@code lineType}.
*
* <ul>
* <li>{@link #LINE_TYPE_FRACTION} indicates that {@code line} is a fractional position within
* the viewport.
* <li>{@link #LINE_TYPE_NUMBER} indicates that {@code line} is a line number, where the size
* of each line is taken to be the size of the first line of the cue.
* <ul>
* <li>When {@code line} is greater than or equal to 0 lines count from the start of the
* viewport, with 0 indicating zero offset from the start edge.
* <li>When {@code line} is negative lines count from the end of the viewport, with -1
* indicating zero offset from the end edge.
* <li>For horizontal text the line spacing is the height of the first line of the cue,
* and the start and end of the viewport are the top and bottom respectively.
* </ul>
* </ul>
*
* <p>Note that it's particularly important to consider the effect of {@link #setLineAnchor(int)
* lineAnchor} when using {@link #LINE_TYPE_NUMBER}.
*
* <ul>
* <li>{@code (line == 0 && lineAnchor == ANCHOR_TYPE_START)} positions a (potentially
* multi-line) cue at the very start of the viewport.
* <li>{@code (line == -1 && lineAnchor == ANCHOR_TYPE_END)} positions a (potentially
* multi-line) cue at the very end of the viewport.
* <li>{@code (line == 0 && lineAnchor == ANCHOR_TYPE_END)} and {@code (line == -1 &&
* lineAnchor == ANCHOR_TYPE_START)} position cues entirely outside of the viewport.
* <li>{@code (line == 1 && lineAnchor == ANCHOR_TYPE_END)} positions a cue so that only the
* last line is visible at the start of the viewport.
* <li>{@code (line == -2 && lineAnchor == ANCHOR_TYPE_START)} position a cue so that only its
* first line is visible at the end of the viewport.
* </ul>
*
* @see Cue#line
* @see Cue#lineType
*/
@ -652,10 +619,6 @@ public final class Cue {
/**
* Sets the cue box anchor positioned by {@link #setLine(float, int) line}.
*
* <p>For the normal case of horizontal text, {@link #ANCHOR_TYPE_START}, {@link
* #ANCHOR_TYPE_MIDDLE} and {@link #ANCHOR_TYPE_END} correspond to the top, middle and bottom of
* the cue box respectively.
*
* @see Cue#lineAnchor
*/
public Builder setLineAnchor(@AnchorType int lineAnchor) {
@ -677,10 +640,6 @@ public final class Cue {
* Sets the fractional position of the {@link #setPositionAnchor(int) positionAnchor} of the cue
* box within the viewport in the direction orthogonal to {@link #setLine(float, int) line}.
*
* <p>For horizontal text, this is the horizontal position relative to the left of the viewport.
* Note that positioning is relative to the left of the viewport even in the case of
* right-to-left text.
*
* @see Cue#position
*/
public Builder setPosition(float position) {
@ -701,10 +660,6 @@ public final class Cue {
/**
* Sets the cue box anchor positioned by {@link #setPosition(float) position}.
*
* <p>For the normal case of horizontal text, {@link #ANCHOR_TYPE_START}, {@link
* #ANCHOR_TYPE_MIDDLE} and {@link #ANCHOR_TYPE_END} correspond to the left, middle and right of
* the cue box respectively.
*
* @see Cue#positionAnchor
*/
public Builder setPositionAnchor(@AnchorType int positionAnchor) {