2단계 - Proxy - #125
Open
yangseungin wants to merge 5 commits into
Open
Conversation
jongmin4943
requested changes
Nov 22, 2024
Comment on lines
+89
to
+92
| assertThat(selectResult.get(0).getProduct()).isEqualTo("감자"); | ||
| assertThat(selectResult.get(0).getQuantity()).isEqualTo(3); | ||
| assertThat(selectResult.get(1).getProduct()).isEqualTo("고구마"); | ||
| assertThat(selectResult.get(1).getQuantity()).isEqualTo(1); |
Comment on lines
+42
to
46
| private List<Field> findOneToManyFields(Class<?> clazz) { | ||
| return Arrays.stream(clazz.getDeclaredFields()) | ||
| .filter(field -> field.isAnnotationPresent(OneToMany.class)) | ||
| .findFirst() | ||
| .orElseThrow(() -> new RuntimeException("OneToMany 필드를 찾을 수 없습니다.")); | ||
| .collect(Collectors.toList()); | ||
| } |
Member
There was a problem hiding this comment.
여전히 이 행위는 QueryBuilder 가 하기에는 과한 책임 같아요 😢
ParentEntity 의 metadata 로 가져와 볼 수 있지 않을까요?
| columns.add(oneToManyColumn.getForeignKeyColumnName()); | ||
| List<Field> oneToManyFields = findOneToManyFields(parentEntity.getClass()); | ||
| for (Field oneToManyField : oneToManyFields) { | ||
| EntityColumn oneToManyColumn = EntityColumn.from(oneToManyField); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
안녕하세요 종민님.
그전단계에서 해결못한 부분만 우선 수정해서 PR올렸습니다.
#105 (comment)
이부분은 아직 반영하지 못하였습니다