public interface

Project

com.atlassian.stash.project.Project
Known Indirect Subclasses

Class Overview

Describes a project in the system.

Summary

Constants
String KEY_REGEXP
int MAX_KEY_LENGTH The maximum length of a project key.
Public Methods
<T> T accept(ProjectVisitor<T> visitor)
@OptionalString String getDescription()
Integer getId()
@Pattern @RequiredString String getKey()
@RequiredString String getName()
@Nonnull ProjectType getType()
Retrieves the project's type.
boolean isPublic()
Retrieves a flag indicating whether this project is public.

Constants

public static final String KEY_REGEXP

Constant Value: "[a-zA-Z][a-zA-Z0-9_\-]*"

public static final int MAX_KEY_LENGTH

The maximum length of a project key.

Constant Value: 128 (0x00000080)

Public Methods

public T accept (ProjectVisitor<T> visitor)

Parameters
visitor the visitor to process the project instance

@OptionalString public String getDescription ()

public Integer getId ()

@Pattern @RequiredString public String getKey ()

@RequiredString public String getName ()

@Nonnull public ProjectType getType ()

Retrieves the project's type. See the documentation for the various types to determine what interfaces each implements.

Returns
  • the type for this project

public boolean isPublic ()

Retrieves a flag indicating whether this project is public.

Note, this flag is taken into account when calculating whether this project is accessible to unauthenticated users but is not the definitive answer. For a definitive answer, use isPubliclyAccessible.

Returns
  • true if the project has been marked as public, false otherwise