Package com.atlassian.bamboo.project
Class DefaultProject
- java.lang.Object
-
- com.atlassian.core.bean.EntityObject
-
- com.atlassian.bamboo.core.BambooEntityObject
-
- com.atlassian.bamboo.core.BambooEntityWithOid
-
- com.atlassian.bamboo.hibernate.HibernateBambooEntityWithOid
-
- com.atlassian.bamboo.project.DefaultProject
-
- All Implemented Interfaces:
BambooIdProvider,BambooObject,BambooObjectWithOid,EntityWithOid,ImmutableEntityWithOid,Deletable,Describable,ImmutableDeletable,Project,ProjectIdentifier,DescriptionProvider,NameProvider,Cloneable
@Entity public class DefaultProject extends HibernateBambooEntityWithOid implements Project
-
-
Field Summary
Fields Modifier and Type Field Description protected Stringdescriptionprotected Stringname
-
Constructor Summary
Constructors Constructor Description DefaultProject()DefaultProject(@NotNull String key, @NotNull String name, @NotNull String description)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description intcompareTo(Object obj)booleanequals(Object o)StringgetCurrentStatus()Returns the string representation the current status of a build.static StringgetCurrentStatusFromPlans(Collection<? extends ImmutableTopLevelPlan> plans)@Nullable StringgetDescription()@NotNull StringgetKey()Returns key of the project.List<Labelling>getLabellings()@NotNull StringgetName()List<Labelling>getRelatedLabellings()@Nullable VcsBambooSpecsSourceImplgetVcsBambooSpecsSource()inthashCode()booleanisMarkedForDeletion()voidsetDescription(@Nullable String description)voidsetKey(@NotNull String key)Sets the key for the project.voidsetLabellings(List<Labelling> labellings)voidsetMarkedForDeletion(boolean markedForDeletion)voidsetName(@NotNull String name)voidsetVcsBambooSpecsSource(VcsBambooSpecsSource vcsBambooSpecsSource)Sets the specs source for the project.-
Methods inherited from class com.atlassian.bamboo.hibernate.HibernateBambooEntityWithOid
getId, getOid, setId, setOid
-
Methods inherited from class com.atlassian.core.bean.EntityObject
clone, getCreationDate, getCurrentDate, getLastModificationDate, setClock, setCreationDate, setLastModificationDate
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.atlassian.bamboo.core.BambooObject
setId
-
Methods inherited from interface com.atlassian.bamboo.core.EntityWithOid
setOid
-
Methods inherited from interface com.atlassian.bamboo.core.ImmutableEntityWithOid
getOid
-
Methods inherited from interface com.atlassian.bamboo.project.Project
getEntityType
-
Methods inherited from interface com.atlassian.bamboo.project.ProjectIdentifier
getId
-
-
-
-
Method Detail
-
getKey
@NotNull public @NotNull String getKey()
Description copied from interface:ProjectIdentifierReturns key of the project. Keys are capital, alphanumeric strings.- Specified by:
getKeyin interfaceProjectIdentifier- Returns:
- key of project. Must not be null.
-
setKey
public void setKey(@NotNull @NotNull String key)Description copied from interface:ProjectSets the key for the project. Must not be null
-
getName
@NotNull public @NotNull String getName()
- Specified by:
getNamein interfaceDescriptionProvider- Specified by:
getNamein interfaceNameProvider- Specified by:
getNamein interfaceProjectIdentifier- Returns:
- the name of the project.
-
setName
public void setName(@NotNull @NotNull String name)- Specified by:
setNamein interfaceDescribable- Specified by:
setNamein interfaceProject
-
getDescription
@Nullable public @Nullable String getDescription()
- Specified by:
getDescriptionin interfaceDescriptionProvider
-
setDescription
public void setDescription(@Nullable @Nullable String description)- Specified by:
setDescriptionin interfaceDescribable
-
isMarkedForDeletion
public boolean isMarkedForDeletion()
- Specified by:
isMarkedForDeletionin interfaceImmutableDeletable- Returns:
- Whether or not the Object has been marked for deletion
-
setMarkedForDeletion
public void setMarkedForDeletion(boolean markedForDeletion)
- Specified by:
setMarkedForDeletionin interfaceDeletable
-
getCurrentStatus
public String getCurrentStatus()
Description copied from interface:ProjectReturns the string representation the current status of a build. MirrorsImmutablePlan.getCurrentStatus(). It will return "current" if any plan is building, and "fail" if any plan is failing.- Specified by:
getCurrentStatusin interfaceProject- Returns:
- a String
-
getCurrentStatusFromPlans
public static String getCurrentStatusFromPlans(Collection<? extends ImmutableTopLevelPlan> plans)
-
getLabellings
public List<Labelling> getLabellings()
- Specified by:
getLabellingsin interfaceProject
-
getRelatedLabellings
public List<Labelling> getRelatedLabellings()
- Specified by:
getRelatedLabellingsin interfaceProject
-
setLabellings
public void setLabellings(List<Labelling> labellings)
- Specified by:
setLabellingsin interfaceProject
-
getVcsBambooSpecsSource
@Nullable public @Nullable VcsBambooSpecsSourceImpl getVcsBambooSpecsSource()
- Specified by:
getVcsBambooSpecsSourcein interfaceProject- Returns:
- specs source used to manage a project or null if the project is not managed by RSS
-
setVcsBambooSpecsSource
public void setVcsBambooSpecsSource(VcsBambooSpecsSource vcsBambooSpecsSource)
Description copied from interface:ProjectSets the specs source for the project.- Specified by:
setVcsBambooSpecsSourcein interfaceProject- Parameters:
vcsBambooSpecsSource- specs source
-
hashCode
public int hashCode()
- Overrides:
hashCodein classcom.atlassian.core.bean.EntityObject
-
equals
public boolean equals(Object o)
- Overrides:
equalsin classcom.atlassian.core.bean.EntityObject
-
compareTo
public int compareTo(Object obj)
-
-