Interface Ranked
In addition, an implementation may be designated as an alternate, which may affect the interpretation of the implementation's rank, usually by conferring a rank that cannot be outranked by any other.
Given a series of Ranked implementations sorted by rank, the first element of the
series will bear the highest, or greatest, rank.
- Author:
- Laird Nelson
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intDeprecated, for removal: This API element is subject to removal in a future version.The default rank (0) when returned by an implementation of therank()method. -
Method Summary
Modifier and TypeMethodDescriptiondefault booleanDeprecated, for removal: This API element is subject to removal in a future version.default booleanoutranks(int j) Deprecated, for removal: This API element is subject to removal in a future version.Returnstrueif thisRankedbears a rank that outranks the rank represented byjaccording to the rules described in the specification for theoutranks(int, int)method.static booleanoutranks(int i, int j) Deprecated, for removal: This API element is subject to removal in a future version.Returnstrueif and only if a rank represented byioutranks a rank represented byj.default booleanDeprecated, for removal: This API element is subject to removal in a future version.Returnstrueif thisRankedoutranks the suppliedRankedaccording to the rules described in the specification for theoutranks(int, int)method.static booleanDeprecated, for removal: This API element is subject to removal in a future version.default intrank()Deprecated, for removal: This API element is subject to removal in a future version.Returns the rank of thisRankedimplementation.
-
Field Details
-
DEFAULT_RANK
Deprecated, for removal: This API element is subject to removal in a future version.The default rank (0) when returned by an implementation of therank()method.- See Also:
-
-
Method Details
-
rank
Deprecated, for removal: This API element is subject to removal in a future version.Returns the rank of thisRankedimplementation.Implementations of this method may return any integer: positive, zero, or negative.
The default implementation of this method returns the value of the
DEFAULT_RANKfield (0).Overrides of this method must return a determinate value.
- Returns:
- the rank of this
Rankedimplementation - See Also:
-
alternate
Deprecated, for removal: This API element is subject to removal in a future version.Returnstrueif thisRankedis to be considered an alternate, which may have an effect on how the return value of therank()method is interpreted in some situations.The default implementation of this method returns
false.Overrides of this method must be idempotent and return a determinate value.
- Returns:
trueif thisRankedis to be considered an alternate
-
outranks
Deprecated, for removal: This API element is subject to removal in a future version.Returnstrueif thisRankedoutranks the suppliedRankedaccording to the rules described in the specification for theoutranks(int, int)method.Overriding this method, while possible and permitted, is discouraged.
-
outranks
Deprecated, for removal: This API element is subject to removal in a future version.Returnstrueif thisRankedbears a rank that outranks the rank represented byjaccording to the rules described in the specification for theoutranks(int, int)method.Overriding this method, while possible and permitted, is discouraged.
-
outranks
Deprecated, for removal: This API element is subject to removal in a future version. -
outranks
Deprecated, for removal: This API element is subject to removal in a future version.Returnstrueif and only if a rank represented byioutranks a rank represented byj.Given two ranks, i and j, i outranks j if and only if i is greater than (
>) j.- Parameters:
i- anintrepresenting a rankj- anintrepresenting a rank- Returns:
trueif and only ifioutranksj- Idempotency:
- This method is idempotent and deterministic.
- Thread Safety:
- This method is safe for concurrent use by multiple threads.
-