-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
cleanup logs, add unit tests for connections, properly load file for …
…saved state
- Loading branch information
Showing
22 changed files
with
364 additions
and
179 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
30 changes: 30 additions & 0 deletions
30
src/integrationTest/java/com/nucleodb/library/models/Book.java
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
package com.nucleodb.library.models; | ||
|
||
import com.nucleodb.library.database.index.TrieIndex; | ||
import com.nucleodb.library.database.index.annotation.Index; | ||
import com.nucleodb.library.database.tables.annotation.Table; | ||
|
||
import java.io.Serializable; | ||
|
||
@Table(tableName = "bookIT", dataEntryClass = BookDE.class) | ||
public class Book implements Serializable { | ||
private static final long serialVersionUID = 1; | ||
@Index(type = TrieIndex.class) | ||
String name; | ||
|
||
public Book() { | ||
} | ||
|
||
public Book(String name) { | ||
this.name = name; | ||
} | ||
|
||
public String getName() { | ||
return name; | ||
} | ||
|
||
public void setName(String name) { | ||
this.name = name; | ||
} | ||
|
||
} |
22 changes: 22 additions & 0 deletions
22
src/integrationTest/java/com/nucleodb/library/models/BookDE.java
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package com.nucleodb.library.models; | ||
|
||
import com.fasterxml.jackson.core.JsonProcessingException; | ||
import com.nucleodb.library.database.modifications.Create; | ||
import com.nucleodb.library.database.tables.table.DataEntry; | ||
|
||
public class BookDE extends DataEntry<Book> { | ||
public BookDE(Book obj) { | ||
super(obj); | ||
} | ||
|
||
public BookDE(Create create) throws ClassNotFoundException, JsonProcessingException { | ||
super(create); | ||
} | ||
|
||
public BookDE() { | ||
} | ||
|
||
public BookDE(String key) { | ||
super(key); | ||
} | ||
} |
21 changes: 21 additions & 0 deletions
21
src/integrationTest/java/com/nucleodb/library/models/WroteConnection.java
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
package com.nucleodb.library.models; | ||
|
||
import com.nucleodb.library.database.tables.annotation.Conn; | ||
import com.nucleodb.library.database.tables.connection.Connection; | ||
|
||
import java.util.Map; | ||
|
||
@Conn("IT-WROTE") | ||
public class WroteConnection extends Connection<AuthorDE, BookDE> { | ||
public WroteConnection() { | ||
} | ||
|
||
public WroteConnection(AuthorDE from, BookDE to) { | ||
super(from, to); | ||
} | ||
|
||
public WroteConnection(AuthorDE from, BookDE to, Map<String, String> metadata) { | ||
super(from, to, metadata); | ||
} | ||
} | ||
|
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.