Skip to content

Commit

Permalink
refactor: 디렉토리 구조 수정 (#251)
Browse files Browse the repository at this point in the history
- domains 계층 추가
- 테스트 코드 계층 수정
- 불필요해진 import문 삭제
  • Loading branch information
7zrv authored Dec 18, 2024
1 parent 955ee86 commit c2d013a
Show file tree
Hide file tree
Showing 380 changed files with 1,961 additions and 1,943 deletions.
2 changes: 0 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,6 @@ def jacocoExcludePatterns = [
'**/jwt/**',
'**/auth/**',
'**/domain/*',
'**/domains/*',
'**/fixture/*',
'**/controller/**',
'**/fixture/*',
Expand All @@ -139,7 +138,6 @@ def jacocoExcludePatternsForVerify = [
'*.jwt.*',
'*.auth.*',
'*.domain.*',
'*.domains.*',
'*.fixture.*',
'*.controller.*',
'*.fixture.*',
Expand Down

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.somemore.center.controller;
package com.somemore.domains.center.controller;

import com.somemore.domains.center.dto.request.CenterProfileUpdateRequestDto;
import com.somemore.domains.center.usecase.command.UpdateCenterProfileUseCase;
import com.somemore.global.auth.annotation.CurrentUser;
import com.somemore.center.dto.request.CenterProfileUpdateRequestDto;
import com.somemore.center.usecase.command.UpdateCenterProfileUseCase;
import com.somemore.global.common.response.ApiResponse;
import com.somemore.global.imageupload.dto.ImageUploadRequestDto;
import com.somemore.global.imageupload.usecase.ImageUploadUseCase;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.somemore.center.controller;
package com.somemore.domains.center.controller;

import com.somemore.center.dto.response.CenterProfileResponseDto;
import com.somemore.center.usecase.query.CenterQueryUseCase;
import com.somemore.domains.center.dto.response.CenterProfileResponseDto;
import com.somemore.domains.center.usecase.query.CenterQueryUseCase;
import com.somemore.global.common.response.ApiResponse;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.somemore.center.controller;
package com.somemore.domains.center.controller;

import com.somemore.domains.center.dto.request.CenterSignRequestDto;
import com.somemore.global.auth.signout.usecase.SignOutUseCase;
import com.somemore.center.dto.request.CenterSignRequestDto;
import com.somemore.global.common.response.ApiResponse;
import io.swagger.v3.oas.annotations.tags.Tag;
import jakarta.servlet.http.HttpServletResponse;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
package com.somemore.center.controller;
package com.somemore.domains.center.controller;

import com.somemore.domains.center.dto.request.PreferItemCreateRequestDto;
import com.somemore.domains.center.dto.response.PreferItemCreateResponseDto;
import com.somemore.domains.center.usecase.command.CreatePreferItemUseCase;
import com.somemore.domains.center.usecase.command.DeletePreferItemUseCase;
import com.somemore.global.auth.annotation.CurrentUser;
import com.somemore.center.dto.request.PreferItemCreateRequestDto;
import com.somemore.center.dto.response.PreferItemCreateResponseDto;
import com.somemore.center.usecase.command.CreatePreferItemUseCase;
import com.somemore.center.usecase.command.DeletePreferItemUseCase;
import com.somemore.global.common.response.ApiResponse;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.somemore.center.domain;
package com.somemore.domains.center.domain;

import com.somemore.center.dto.request.CenterProfileUpdateRequestDto;
import com.somemore.domains.center.dto.request.CenterProfileUpdateRequestDto;
import com.somemore.global.common.entity.BaseEntity;
import jakarta.persistence.*;
import lombok.*;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.somemore.center.domain;
package com.somemore.domains.center.domain;

import jakarta.persistence.*;
import lombok.AccessLevel;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.somemore.center.dto.request;
package com.somemore.domains.center.dto.request;

import com.fasterxml.jackson.databind.PropertyNamingStrategies;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.somemore.center.dto.request;
package com.somemore.domains.center.dto.request;

import com.fasterxml.jackson.databind.PropertyNamingStrategies.SnakeCaseStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.somemore.center.dto.request;
package com.somemore.domains.center.dto.request;

import com.fasterxml.jackson.databind.PropertyNamingStrategies;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.somemore.center.domain.PreferItem;
import com.somemore.domains.center.domain.PreferItem;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotNull;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
package com.somemore.center.dto.response;
package com.somemore.domains.center.dto.response;

import com.fasterxml.jackson.databind.PropertyNamingStrategies;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.somemore.center.domain.Center;
import com.somemore.center.domain.PreferItem;
import com.somemore.domains.center.domain.Center;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Builder;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.somemore.center.dto.response;
package com.somemore.domains.center.dto.response;

import com.fasterxml.jackson.databind.PropertyNamingStrategies.SnakeCaseStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.somemore.center.domain.Center;
import com.somemore.domains.center.domain.Center;
import io.swagger.v3.oas.annotations.media.Schema;
import java.util.UUID;
import lombok.Builder;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.somemore.center.dto.response;
package com.somemore.domains.center.dto.response;

import com.fasterxml.jackson.databind.PropertyNamingStrategies;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.somemore.center.domain.PreferItem;
import com.somemore.domains.center.domain.PreferItem;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Builder;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.somemore.center.dto.response;
package com.somemore.domains.center.dto.response;

import com.somemore.center.domain.PreferItem;
import com.somemore.domains.center.domain.PreferItem;
import lombok.Builder;

import java.util.UUID;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.somemore.center.repository.center;
package com.somemore.domains.center.repository.center;

import com.somemore.center.domain.Center;
import com.somemore.domains.center.domain.Center;
import org.springframework.data.jpa.repository.JpaRepository;

import java.util.Optional;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.somemore.center.repository.center;
package com.somemore.domains.center.repository.center;

import com.somemore.center.domain.Center;
import com.somemore.center.repository.mapper.CenterOverviewInfo;
import com.somemore.domains.center.domain.Center;
import com.somemore.domains.center.repository.mapper.CenterOverviewInfo;
import org.springframework.stereotype.Repository;

import java.util.List;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
package com.somemore.center.repository.center;
package com.somemore.domains.center.repository.center;

import com.querydsl.core.types.Projections;
import com.querydsl.core.types.dsl.BooleanExpression;
import com.querydsl.jpa.impl.JPAQueryFactory;
import com.somemore.center.domain.Center;
import com.somemore.center.domain.QCenter;
import com.somemore.center.repository.mapper.CenterOverviewInfo;
import com.somemore.domains.center.domain.Center;
import com.somemore.domains.center.domain.QCenter;
import com.somemore.domains.center.repository.mapper.CenterOverviewInfo;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Repository;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.somemore.center.repository.mapper;
package com.somemore.domains.center.repository.mapper;


import java.util.UUID;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.somemore.center.repository.preferitem;
package com.somemore.domains.center.repository.preferitem;

import com.somemore.center.domain.PreferItem;
import com.somemore.domains.center.domain.PreferItem;
import org.springframework.data.jpa.repository.JpaRepository;

import java.util.List;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.somemore.center.repository.preferitem;
package com.somemore.domains.center.repository.preferitem;

import com.somemore.center.domain.PreferItem;
import com.somemore.domains.center.domain.PreferItem;
import org.springframework.stereotype.Repository;

import java.util.List;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.somemore.center.repository.preferitem;
package com.somemore.domains.center.repository.preferitem;

import com.somemore.center.domain.PreferItem;
import com.somemore.domains.center.domain.PreferItem;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Repository;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
package com.somemore.center.service.command;

import com.somemore.center.domain.PreferItem;
import com.somemore.center.dto.request.PreferItemCreateRequestDto;
import com.somemore.center.dto.response.PreferItemCreateResponseDto;
import com.somemore.center.repository.preferitem.PreferItemRepository;
import com.somemore.center.usecase.command.CreatePreferItemUseCase;
import com.somemore.center.usecase.query.CenterQueryUseCase;
package com.somemore.domains.center.service.command;

import com.somemore.domains.center.domain.PreferItem;
import com.somemore.domains.center.dto.request.PreferItemCreateRequestDto;
import com.somemore.domains.center.dto.response.PreferItemCreateResponseDto;
import com.somemore.domains.center.repository.preferitem.PreferItemRepository;
import com.somemore.domains.center.usecase.command.CreatePreferItemUseCase;
import com.somemore.domains.center.usecase.query.CenterQueryUseCase;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.somemore.center.service.command;
package com.somemore.domains.center.service.command;

import com.somemore.center.domain.PreferItem;
import com.somemore.center.repository.preferitem.PreferItemRepository;
import com.somemore.center.usecase.command.DeletePreferItemUseCase;
import com.somemore.domains.center.domain.PreferItem;
import com.somemore.domains.center.repository.preferitem.PreferItemRepository;
import com.somemore.domains.center.usecase.command.DeletePreferItemUseCase;
import com.somemore.global.exception.BadRequestException;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package com.somemore.center.service.command;
package com.somemore.domains.center.service.command;

import com.somemore.center.domain.Center;
import com.somemore.center.dto.request.CenterProfileUpdateRequestDto;
import com.somemore.center.repository.center.CenterRepository;
import com.somemore.center.usecase.command.UpdateCenterProfileUseCase;
import com.somemore.domains.center.domain.Center;
import com.somemore.domains.center.dto.request.CenterProfileUpdateRequestDto;
import com.somemore.domains.center.repository.center.CenterRepository;
import com.somemore.domains.center.usecase.command.UpdateCenterProfileUseCase;
import com.somemore.global.exception.BadRequestException;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
package com.somemore.center.service.query;

import com.somemore.center.domain.Center;
import com.somemore.center.repository.mapper.CenterOverviewInfo;
import com.somemore.center.dto.response.CenterProfileResponseDto;
import com.somemore.center.dto.response.PreferItemResponseDto;
import com.somemore.center.repository.center.CenterRepository;
import com.somemore.center.usecase.query.CenterQueryUseCase;
import com.somemore.center.usecase.query.PreferItemQueryUseCase;
package com.somemore.domains.center.service.query;

import com.somemore.domains.center.domain.Center;
import com.somemore.domains.center.repository.mapper.CenterOverviewInfo;
import com.somemore.domains.center.dto.response.CenterProfileResponseDto;
import com.somemore.domains.center.dto.response.PreferItemResponseDto;
import com.somemore.domains.center.repository.center.CenterRepository;
import com.somemore.domains.center.usecase.query.CenterQueryUseCase;
import com.somemore.domains.center.usecase.query.PreferItemQueryUseCase;
import com.somemore.global.exception.BadRequestException;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.somemore.center.service.query;
package com.somemore.domains.center.service.query;

import com.somemore.center.repository.center.CenterRepository;
import com.somemore.center.usecase.query.CenterSignUseCase;
import com.somemore.domains.center.repository.center.CenterRepository;
import com.somemore.domains.center.usecase.query.CenterSignUseCase;
import com.somemore.global.exception.BadRequestException;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package com.somemore.center.service.query;
package com.somemore.domains.center.service.query;

import com.somemore.center.domain.PreferItem;
import com.somemore.center.dto.response.PreferItemResponseDto;
import com.somemore.center.repository.preferitem.PreferItemRepository;
import com.somemore.center.usecase.query.PreferItemQueryUseCase;
import com.somemore.domains.center.domain.PreferItem;
import com.somemore.domains.center.dto.response.PreferItemResponseDto;
import com.somemore.domains.center.repository.preferitem.PreferItemRepository;
import com.somemore.domains.center.usecase.query.PreferItemQueryUseCase;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package com.somemore.domains.center.usecase.command;

import com.somemore.domains.center.dto.request.PreferItemCreateRequestDto;
import com.somemore.domains.center.dto.response.PreferItemCreateResponseDto;

import java.util.UUID;

public interface CreatePreferItemUseCase {

PreferItemCreateResponseDto createPreferItem(UUID userId, PreferItemCreateRequestDto requestDto);
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.somemore.center.usecase.command;
package com.somemore.domains.center.usecase.command;

import java.util.UUID;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.somemore.center.usecase.command;
package com.somemore.domains.center.usecase.command;

import com.somemore.center.dto.request.CenterProfileUpdateRequestDto;
import com.somemore.domains.center.dto.request.CenterProfileUpdateRequestDto;

import java.util.UUID;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.somemore.center.usecase.query;
package com.somemore.domains.center.usecase.query;

import com.somemore.center.repository.mapper.CenterOverviewInfo;
import com.somemore.center.dto.response.CenterProfileResponseDto;
import com.somemore.domains.center.repository.mapper.CenterOverviewInfo;
import com.somemore.domains.center.dto.response.CenterProfileResponseDto;

import java.util.List;
import java.util.UUID;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.somemore.center.usecase.query;
package com.somemore.domains.center.usecase.query;

import java.util.UUID;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.somemore.center.usecase.query;
package com.somemore.domains.center.usecase.query;

import com.somemore.center.domain.PreferItem;
import com.somemore.center.dto.response.PreferItemResponseDto;
import com.somemore.domains.center.domain.PreferItem;
import com.somemore.domains.center.dto.response.PreferItemResponseDto;

import java.util.List;
import java.util.UUID;
Expand Down
Loading

0 comments on commit c2d013a

Please sign in to comment.