001package usecase.post; 002 003import lombok.Builder; 004import lombok.Getter; 005 006import java.time.Instant; 007 008@Builder 009@Getter 010public class PostSearchForm { 011 public enum SortCriteria {OLDEST, NEWEST, MOSTVOTED}; 012 private final String content; 013 private final String sectionName; 014 private final String authorName; 015 private final Instant postedAfter; 016 private final Instant postedBefore; 017 @Builder.Default private final SortCriteria orderBy = SortCriteria.NEWEST; 018 @Builder.Default private final int page = 1; 019 @Builder.Default private final boolean onlyFollow = false; 020 @Builder.Default private final boolean includeBody = false; 021}