Kaynağa Gözat

Pull in readme commit from 'master' of github.com:Zipcoder/CRUDApplication

David Ginzberg 7 yıl önce
ebeveyn
işleme
96565817d1
1 değiştirilmiş dosya ile 18 ekleme ve 0 silme
  1. 18
    0
      README.md

+ 18
- 0
README.md Dosyayı Görüntüle

@@ -0,0 +1,18 @@
1
+# CRUDApplication
2
+
3
+This repository provides a starter project for a CRUD application using Spring Boot, RestControllers, and H2 for an in memory database.
4
+
5
+## Exercise
6
+
7
+Using this project as a starter, create a Person class as an entity to persist to H2 with an autogenerated id. Provide a RestController for Person with endpoints for HTTP GET, PUT, POST, and DELETE operations mapping to their appropriate CRUD behaviors. endpoints should be at `/person` and `/person/{id}` as appropriate. See the snippet below for setting Person IDs:
8
+
9
+```Java
10
+@Entity
11
+public class Person {
12
+
13
+    @Id
14
+    @GeneratedValue(strategy = GenerationType.AUTO)
15
+    private Integer id;
16
+    ...
17
+}
18
+```