Class SimpleMinimalRef
java.lang.Object
com.atlassian.bitbucket.repository.SimpleMinimalRef
- All Implemented Interfaces:
MinimalRef
- Direct Known Subclasses:
SimpleMinimalRepositoryRef
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static classSimpleMinimalRef.AbstractMinimalRefBuilder<B extends SimpleMinimalRef.AbstractMinimalRefBuilder<B,R>, R extends MinimalRef> static class -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedSimpleMinimalRef(SimpleMinimalRef.AbstractMinimalRefBuilder<?, ?> builder, RefType type) -
Method Summary
Modifier and TypeMethodDescriptionbooleanprotected StringOverride this to add additional sub-class specific information totoString().An identifier for this reference suitable for display to end users.getId()The absolute identifier of this reference, which should never be ambiguous within the backingRepository.getType()inthashCode()toString()
-
Constructor Details
-
SimpleMinimalRef
protected SimpleMinimalRef(@Nonnull SimpleMinimalRef.AbstractMinimalRefBuilder<?, ?> builder, @Nonnull RefType type)
-
-
Method Details
-
getDisplayId
Description copied from interface:MinimalRefAn identifier for this reference suitable for display to end users.No guarantees are made as to how this identifier differs from
MinimalRef.getId()--they may be identical or not, at the whim of the underlying SCM implementation. In practise, however, the returned identifier should be sensible for users familiar with the underlying SCM.- Specified by:
getDisplayIdin interfaceMinimalRef- Returns:
- the reference's display identifier
-
getId
Description copied from interface:MinimalRefThe absolute identifier of this reference, which should never be ambiguous within the backingRepository.When performing operations which accept a commit ID, this is the value that should be used to ensure there are no ambiguities. Using
MinimalRef.getDisplayId()may result in unexpected behaviour.- Specified by:
getIdin interfaceMinimalRef- Returns:
- the reference's absolute identifier
-
getType
- Specified by:
getTypein interfaceMinimalRef- Returns:
- the type of ref
-
equals
-
hashCode
public int hashCode() -
toString
-
fieldsToString
Override this to add additional sub-class specific information totoString().- Returns:
- String that will be used in this object's
toString(). The format is expected to be"field1=value1, field2=value2", the caller takes care of surrounding it with a class name and braces.
-