Add all layers.

This commit is contained in:
Florian THIERRY
2023-11-28 10:58:22 +01:00
parent 01b1d54cef
commit 025197525c
12 changed files with 226 additions and 1 deletions

30
sportshub-domain/pom.xml Normal file
View File

@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.sportshub</groupId>
<artifactId>sportshub-parent</artifactId>
<version>0.0.1-SNAPSHOT</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>
<artifactId>sportshub-domain</artifactId>
<name>sportshub-domain</name>
<description>Demo project for Spring Boot</description>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>16</source>
<target>16</target>
</configuration>
</plugin>
</plugins>
</build>
<packaging>jar</packaging>
</project>

View File

@@ -0,0 +1,8 @@
package org.sportshub.domain.user.model;
import java.util.UUID;
public record User(
UUID id,
String password
) {}

View File

@@ -0,0 +1,10 @@
package org.sportshub.domain.user.port;
import java.util.Optional;
import java.util.UUID;
import org.sportshub.domain.user.model.User;
public interface UserPort {
Optional<User> findById(UUID userId);
}