Package com.atlassian.bitbucket.content
Enum Class DiffFileType
- All Implemented Interfaces:
Serializable,Comparable<DiffFileType>,Constable
An enumeration of file types in a diff.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum Constants -
Method Summary
Modifier and TypeMethodDescriptionstatic DiffFileTypeforSegmentType(DiffSegmentType segmentType) Returns the default file type for a givensegmentType.static DiffFileTypefromId(int id) intgetId()static DiffFileTypeReturns the enum constant of this class with the specified name.static DiffFileType[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
FROM
The source ('from') file of the diff. -
TO
The destination ('to') file of the diff,
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
forSegmentType
Returns the default file type for a givensegmentType.- Parameters:
segmentType- segment type to match- Returns:
- the default matching file type for the provided segment type
- Throws:
IllegalArgumentException- if there is no file type currently associated withsegmentType.
-
fromId
-
getId
public int getId()
-