1 /*
2 * Copyright (C) 2012 Atlassian
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17 package com.atlassian.jira.rest.client;
18
19 import javax.annotation.Nullable;
20
21 /**
22 * Set of optional parameters for {@link IssueRestClient#getCreateIssueMetadata(GetCreateIssueMetadataOptions, ProgressMonitor)}.
23 * {@link GetCreateIssueMetadataOptionsBuilder} is very useful for building objects of this class.
24 *
25 * @since v1.0
26 */
27 public class GetCreateIssueMetadataOptions {
28
29 public static final String EXPAND_PROJECTS_ISSUETYPES_FIELDS = "projects.issuetypes.fields";
30
31 @Nullable
32 public final Iterable<Long> projectIds;
33 @Nullable
34 public final Iterable<String> projectKeys;
35 @Nullable
36 public final Iterable<Long> issueTypeIds;
37 @Nullable
38 public final Iterable<String> issueTypeNames;
39 @Nullable
40 public final Iterable<String> expandos;
41
42 /**
43 *
44 * @param expandos List of fields that should be expanded. See constants with prefix EXPAND_ in this class. Pass <code>null</code> to ignore.
45 * @param issueTypeNames List of issue types names to filter results. Pass <code>null</code> to ignore.
46 * @param issueTypeIds List of issue types Ids to filter results. Pass <code>null</code> to ignore.
47 * @param projectKeys List of projects keys used to filter results. Pass <code>null</code> to ignore.
48 * @param projectIds List of projects Ids used to filter results. Pass <code>null</code> to ignore.
49 */
50 public GetCreateIssueMetadataOptions(@Nullable Iterable<String> expandos, @Nullable Iterable<String> issueTypeNames,
51 @Nullable Iterable<Long> issueTypeIds, @Nullable Iterable<String> projectKeys,
52 @Nullable Iterable<Long> projectIds) {
53 this.expandos = expandos;
54 this.issueTypeNames = issueTypeNames;
55 this.issueTypeIds = issueTypeIds;
56 this.projectKeys = projectKeys;
57 this.projectIds = projectIds;
58 }
59 }