Skip to content

Instantly share code, notes, and snippets.

@sohangp
Last active December 8, 2019 12:40
Show Gist options
  • Save sohangp/6521afc4ecf9132ea6ef289cec36ec91 to your computer and use it in GitHub Desktop.
Save sohangp/6521afc4ecf9132ea6ef289cec36ec91 to your computer and use it in GitHub Desktop.
Projection DTO for Customer Details
public interface CustomerDetailsDTO {
Integer getCustomerId();
@Value("#{target.firstName + ' ' + target.lastName}")
String getCustomerName();
String getCity();
String getCountry();
@Value("#{@mapperUtility.buildOrderDTO(target.orderNumber, target.totalAmount)}")
OrderDTO getOrder();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment