Skip to content

Commit

Permalink
feat: CreatePatronResponse, CreatePatronRequest, GetPatronsResponse c…
Browse files Browse the repository at this point in the history
…lasses outline
  • Loading branch information
VicenteVigueras committed Apr 8, 2024
1 parent a535115 commit 7eb5a3d
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
package com.codedifferently.lesson16.web;

import jakarta.validation.Valid;
import jakarta.validation.constraints.NotNull;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@AllArgsConstructor
@NoArgsConstructor
@Builder
public class CreatePatronRequest {
@NotNull(message = "patron is required") @Valid
private PatronsRequest patron;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
package com.codedifferently.lesson16.web;

import lombok.Builder;
import lombok.Data;

@Data
@Builder
public class CreatePatronResponse {
private PatronsResponse patron;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
package com.codedifferently.lesson16.web;

import java.util.List;
import lombok.Builder;
import lombok.Data;
import lombok.Singular;

@Data
@Builder
public class GetPatronsResponse {
@Singular private List<PatronsResponse> patrons;
}

0 comments on commit 7eb5a3d

Please sign in to comment.