Package org.miaixz.bus.gitlab.models
Class ProjectFilter
java.lang.Object
org.miaixz.bus.gitlab.models.ProjectFilter
- All Implemented Interfaces:
Serializable
This class is used to filter Projects when getting lists of projects for a specified user.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the query params specified by this filter.getQueryParams(int page, int perPage) Get the query params specified by this filter.toString()withArchived(Boolean archived) Limit by archived status.withCustomAttributes(Boolean withCustomAttributes) Include custom attributes in response (admins only).withIdAfter(Long idAfter) Limit results to projects with IDs greater than the specified projectID.withIdBefore(Long idBefore) Limit results to projects with IDs less than the specified project ID.withImported(Boolean imported) Limit results to projects which were imported from external systems by current user.withIssuesEnabled(Boolean withIssuesEnabled) Limit by enabled issues featurewithLastActivityAfter(Date lastActivityAfter) Limit results to projects with last_activity after specified time.withLastActivityBefore(Date lastActivityBefore) Limit results to projects with last_activity before specified time.withMembership(Boolean membership) Limit by projects that the current user is a member ofwithMergeRequestsEnabled(Boolean withMergeRequestsEnabled) Limit by enabled merge requests featurewithMinAccessLevel(AccessLevel minAccessLevel) Limit by current user minimal access level.withOrderBy(Constants.ProjectOrderBy orderBy) Return projects ordered by id, name, path, created_at, updated_at, or last_activity_at fields.Limit by projects explicitly owned by the current userwithProgrammingLanguage(String withProgrammingLanguage) Limit by projects which use the given programming language.withRepositoryChecksumFailed(Boolean repositoryChecksumFailed) Limit projects where the repository checksum calculation has failed.withRepositoryStorage(String repositoryStorage) Limit results to projects stored on the specified repository_storage.withSearch(String search) Return list of projects matching the search criteria.withSearchNamespaces(Boolean searchNamespaces) Include ancestor namespaces when matching search criteria.withSimple(Boolean simple) Return only limited fields for each project.Return projects sorted in asc or desc order.withStarred(Boolean starred) Limit by projects starred by the current user.withStatistics(Boolean statistics) Include project statistics.Limit results to projects that match all of given topics.withTopicId(Integer topic_id) Limit results to projects with the assigned topic given by the topic ID.withVisibility(Visibility visibility) Limit by visibility public, internal, or private.withWikiChecksumFailed(Boolean wikiChecksumFailed) Limit projects where the wiki checksum calculation has failed.
-
Constructor Details
-
ProjectFilter
public ProjectFilter()
-
-
Method Details
-
withArchived
Limit by archived status.- Parameters:
archived- if true will only return archived projects- Returns:
- the reference to this ProjectFilter instance
-
withVisibility
Limit by visibility public, internal, or private.- Parameters:
visibility- the visibility to match- Returns:
- the reference to this ProjectFilter instance
-
withOrderBy
Return projects ordered by id, name, path, created_at, updated_at, or last_activity_at fields. Default is created_at.- Parameters:
orderBy- specifies what field to order by- Returns:
- the reference to this ProjectFilter instance
-
withSortOder
Return projects sorted in asc or desc order. Default is desc.- Parameters:
sort- sort direction, ASC or DESC- Returns:
- the reference to this ProjectFilter instance
-
withSearch
Return list of projects matching the search criteria.- Parameters:
search- the search criteria- Returns:
- the reference to this ProjectFilter instance
-
withSearchNamespaces
Include ancestor namespaces when matching search criteria. Default is false.- Parameters:
searchNamespaces- if true, include ancestor namespaces when matching search criteria- Returns:
- the reference to this ProjectFilter instance
-
withSimple
Return only limited fields for each project. This is a no-op without authentication as then only simple fields are returned.- Parameters:
simple- if true, return only limited fields for each project- Returns:
- the reference to this ProjectFilter instance
-
withOwned
Limit by projects explicitly owned by the current user- Parameters:
owned- if true, limit to projects explicitly owned by the current user- Returns:
- the reference to this ProjectFilter instance
-
withMembership
Limit by projects that the current user is a member of- Parameters:
membership- if true, limit by projects that the current user is a member of- Returns:
- the reference to this ProjectFilter instance
-
withStarred
Limit by projects starred by the current user.- Parameters:
starred- if true, limit by projects starred by the current user- Returns:
- the reference to this ProjectFilter instance
-
withStatistics
Include project statistics.- Parameters:
statistics- if true, include project statistics- Returns:
- the reference to this ProjectFilter instance
-
withCustomAttributes
Include custom attributes in response (admins only).- Parameters:
withCustomAttributes- if true, include custom attributes in the repsonse- Returns:
- the reference to this ProjectFilter instance
-
withIssuesEnabled
Limit by enabled issues feature- Parameters:
withIssuesEnabled- if true, limit by enabled issues feature- Returns:
- the reference to this ProjectFilter instance
-
withMergeRequestsEnabled
Limit by enabled merge requests feature- Parameters:
withMergeRequestsEnabled- if true, limit by enabled merge requests feature- Returns:
- the reference to this ProjectFilter instance
-
withProgrammingLanguage
Limit by projects which use the given programming language.- Parameters:
withProgrammingLanguage- limit by projects which use the given programming language- Returns:
- the reference to this ProjectFilter instance
-
withWikiChecksumFailed
Limit projects where the wiki checksum calculation has failed.- Parameters:
wikiChecksumFailed- if true, limit projects where the wiki checksum calculation has failed- Returns:
- the reference to this ProjectFilter instance
- Since:
- GitLab 11.2
-
withRepositoryChecksumFailed
Limit projects where the repository checksum calculation has failed.- Parameters:
repositoryChecksumFailed- if true, limit projects where the repository checksum calculation has failed- Returns:
- the reference to this ProjectFilter instance
- Since:
- GitLab 11.2
-
withMinAccessLevel
Limit by current user minimal access level.- Parameters:
minAccessLevel- limit by current user minimal access level- Returns:
- the reference to this ProjectFilter instance
-
withIdAfter
Limit results to projects with IDs greater than the specified projectID.- Parameters:
idAfter- limit results to projects with IDs greater than the specified project ID- Returns:
- the reference to this ProjectFilter instance
-
withIdBefore
Limit results to projects with IDs less than the specified project ID.- Parameters:
idBefore- limit results to projects with IDs less than the specified project ID- Returns:
- the reference to this ProjectFilter instance
-
withLastActivityAfter
Limit results to projects with last_activity after specified time.- Parameters:
lastActivityAfter- limit results to projects with last_activity after specified time- Returns:
- the reference to this ProjectFilter instance
-
withLastActivityBefore
Limit results to projects with last_activity before specified time.- Parameters:
lastActivityBefore- limit results to projects with last_activity before specified time- Returns:
- the reference to this ProjectFilter instance
-
withRepositoryStorage
Limit results to projects stored on the specified repository_storage. Available for admins only.- Parameters:
repositoryStorage- limit results to projects stored on repository_storage- Returns:
- the reference to this ProjectFilter instance
-
withImported
Limit results to projects which were imported from external systems by current user.- Parameters:
imported- limit results to projects imported from external systems by current user- Returns:
- the reference to this ProjectFilter instance
-
withTopic
Limit results to projects that match all of given topics.- Parameters:
topic- Comma-separated topic names.- Returns:
- the reference to this ProjectFilter instance
-
withTopicId
Limit results to projects with the assigned topic given by the topic ID.- Parameters:
topic_id- the topic ID- Returns:
- the reference to this ProjectFilter instance
-
getQueryParams
Get the query params specified by this filter.- Parameters:
page- specifies the page numberperPage- specifies the number of items per page- Returns:
- a GitLabApiForm instance holding the query parameters for this ProjectFilter instance
-
getQueryParams
Get the query params specified by this filter.- Returns:
- a GitLabApiForm instance holding the query parameters for this ProjectFilter instance
-
toString
-