You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

PermissionTemplateDto.java 2.6KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101
  1. /*
  2. * SonarQube
  3. * Copyright (C) 2009-2020 SonarSource SA
  4. * mailto:info AT sonarsource DOT com
  5. *
  6. * This program is free software; you can redistribute it and/or
  7. * modify it under the terms of the GNU Lesser General Public
  8. * License as published by the Free Software Foundation; either
  9. * version 3 of the License, or (at your option) any later version.
  10. *
  11. * This program is distributed in the hope that it will be useful,
  12. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  14. * Lesser General Public License for more details.
  15. *
  16. * You should have received a copy of the GNU Lesser General Public License
  17. * along with this program; if not, write to the Free Software Foundation,
  18. * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
  19. */
  20. package org.sonar.db.permission.template;
  21. import java.util.Date;
  22. import javax.annotation.CheckForNull;
  23. import javax.annotation.Nullable;
  24. public class PermissionTemplateDto {
  25. private String organizationUuid;
  26. private String name;
  27. private String uuid;
  28. private String description;
  29. private String keyPattern;
  30. private Date createdAt;
  31. private Date updatedAt;
  32. public String getName() {
  33. return name;
  34. }
  35. public PermissionTemplateDto setName(String name) {
  36. this.name = name;
  37. return this;
  38. }
  39. public PermissionTemplateDto setOrganizationUuid(String uuid) {
  40. this.organizationUuid = uuid;
  41. return this;
  42. }
  43. /**
  44. * @since 5.2 the kee column is a proper uuid. Before that it was build on the name + timestamp
  45. */
  46. public String getUuid() {
  47. return uuid;
  48. }
  49. /**
  50. * @since 5.2 the kee column is a proper uuid. Before it was build on the name + timestamp
  51. */
  52. public PermissionTemplateDto setUuid(String uuid) {
  53. this.uuid = uuid;
  54. return this;
  55. }
  56. @CheckForNull
  57. public String getDescription() {
  58. return description;
  59. }
  60. public PermissionTemplateDto setDescription(@Nullable String description) {
  61. this.description = description;
  62. return this;
  63. }
  64. @CheckForNull
  65. public String getKeyPattern() {
  66. return keyPattern;
  67. }
  68. public PermissionTemplateDto setKeyPattern(@Nullable String regexp) {
  69. this.keyPattern = regexp;
  70. return this;
  71. }
  72. public Date getCreatedAt() {
  73. return createdAt;
  74. }
  75. public PermissionTemplateDto setCreatedAt(Date createdAt) {
  76. this.createdAt = createdAt;
  77. return this;
  78. }
  79. public Date getUpdatedAt() {
  80. return updatedAt;
  81. }
  82. public PermissionTemplateDto setUpdatedAt(Date updatedAt) {
  83. this.updatedAt = updatedAt;
  84. return this;
  85. }
  86. }