Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
CTF
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Grzegorz
CTF
Commits
d229ba40
Commit
d229ba40
authored
Feb 08, 2017
by
Grzegorz Pietrusza
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
stub of repository
parent
f7dca165
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
284 additions
and
10 deletions
+284
-10
ctf-db.iml
ctf-db/ctf-db.iml
+106
-0
pom.xml
ctf-db/pom.xml
+143
-0
Repository.java
ctf-db/src/main/java/com/jifwin/ctf/db/Repository.java
+0
-10
Repository.java
...rc/main/java/com/jifwin/ctf/db/repository/Repository.java
+35
-0
No files found.
ctf-db/ctf-db.iml
View file @
d229ba40
This diff is collapsed.
Click to expand it.
ctf-db/pom.xml
View file @
d229ba40
...
@@ -8,6 +8,149 @@
...
@@ -8,6 +8,149 @@
<groupId>
ctf-group
</groupId>
<groupId>
ctf-group
</groupId>
<artifactId>
ctf-db
</artifactId>
<artifactId>
ctf-db
</artifactId>
<version>
1.0-SNAPSHOT
</version>
<version>
1.0-SNAPSHOT
</version>
<dependencies>
<dependency>
<groupId>
org.mongodb.morphia
</groupId>
<artifactId>
morphia
</artifactId>
<version>
1.0.0-rc0
</version>
</dependency>
<dependency>
<groupId>
io.dropwizard
</groupId>
<artifactId>
dropwizard-core
</artifactId>
<version>
0.9.0
</version>
</dependency>
<dependency>
<groupId>
io.dropwizard
</groupId>
<artifactId>
dropwizard-auth
</artifactId>
<version>
0.9.0-rc3
</version>
</dependency>
<dependency>
<groupId>
org.mongodb
</groupId>
<artifactId>
mongo-java-driver
</artifactId>
<version>
3.1.0
</version>
</dependency>
<dependency>
<groupId>
com.google.inject
</groupId>
<artifactId>
guice
</artifactId>
<version>
4.0
</version>
<exclusions>
<exclusion>
<artifactId>
guava
</artifactId>
<groupId>
com.google.guava
</groupId>
</exclusion>
<exclusion>
<groupId>
javax.inject
</groupId>
<artifactId>
javax.inject
</artifactId>
</exclusion>
<exclusion>
<groupId>
aopalliance
</groupId>
<artifactId>
aopalliance
</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>
org.apache.httpcomponents
</groupId>
<artifactId>
httpclient
</artifactId>
<version>
4.5.1
</version>
</dependency>
<dependency>
<groupId>
io.dropwizard
</groupId>
<artifactId>
dropwizard-assets
</artifactId>
<version>
0.9.0
</version>
</dependency>
<dependency>
<groupId>
org.webjars
</groupId>
<artifactId>
jquery
</artifactId>
<version>
2.1.4
</version>
</dependency>
<dependency>
<groupId>
org.webjars
</groupId>
<artifactId>
materializecss
</artifactId>
<version>
0.97.5
</version>
</dependency>
<dependency>
<groupId>
org.webjars
</groupId>
<artifactId>
angularjs
</artifactId>
<version>
1.4.7
</version>
</dependency>
<dependency>
<groupId>
org.webjars
</groupId>
<artifactId>
angular-ui-router
</artifactId>
<version>
0.2.17
</version>
</dependency>
<dependency>
<groupId>
org.webjars
</groupId>
<artifactId>
font-awesome
</artifactId>
<version>
4.5.0
</version>
</dependency>
<dependency>
<groupId>
org.webjars.bower
</groupId>
<artifactId>
angular-cookies
</artifactId>
<version>
1.4.5
</version>
</dependency>
<dependency>
<groupId>
commons-collections
</groupId>
<artifactId>
commons-collections
</artifactId>
<version>
3.2.1
</version>
</dependency>
<dependency>
<groupId>
com.bazaarvoice.dropwizard
</groupId>
<artifactId>
dropwizard-webjars-bundle
</artifactId>
<version>
0.2.1
</version>
<exclusions>
<exclusion>
<artifactId>
io.dropwizard
</artifactId>
<groupId>
dropwizard-core
</groupId>
</exclusion>
<exclusion>
<artifactId>
guava
</artifactId>
<groupId>
com.google.guava
</groupId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>
commons-io
</groupId>
<artifactId>
commons-io
</artifactId>
<version>
2.4
</version>
</dependency>
<dependency>
<groupId>
org.immutables
</groupId>
<artifactId>
value
</artifactId>
<version>
2.4.3
</version>
<scope>
provided
</scope>
</dependency>
<dependency>
<groupId>
org.lightcouch
</groupId>
<artifactId>
lightcouch
</artifactId>
<version>
0.1.8
</version>
</dependency>
<dependency>
<groupId>
junit
</groupId>
<artifactId>
junit
</artifactId>
<scope>
test
</scope>
</dependency>
<dependency>
<groupId>
org.mockito
</groupId>
<artifactId>
mockito-core
</artifactId>
<scope>
test
</scope>
</dependency>
<dependency>
<groupId>
org.assertj
</groupId>
<artifactId>
assertj-core
</artifactId>
<scope>
test
</scope>
</dependency>
<dependency>
<groupId>
org.awaitility
</groupId>
<artifactId>
awaitility
</artifactId>
<scope>
test
</scope>
</dependency>
<dependency>
<groupId>
junit
</groupId>
<artifactId>
junit
</artifactId>
<version>
4.12
</version>
<scope>
test
</scope>
</dependency>
</dependencies>
</project>
</project>
\ No newline at end of file
ctf-db/src/main/java/com/jifwin/ctf/db/Repository.java
deleted
100644 → 0
View file @
f7dca165
package
com
.
jifwin
.
ctf
.
db
;
public
interface
Repository
<
T
>
{
public
void
add
(
T
t
);
public
void
delete
(
final
String
id
);
public
void
update
(
T
t
);
}
ctf-db/src/main/java/com/jifwin/ctf/db/repository/Repository.java
0 → 100644
View file @
d229ba40
package
com
.
jifwin
.
ctf
.
db
.
repository
;
import
com.google.inject.Inject
;
import
com.google.inject.Singleton
;
import
org.lightcouch.CouchDbClient
;
import
static
com
.
google
.
common
.
base
.
Preconditions
.
checkNotNull
;
@Singleton
public
abstract
class
Repository
<
T
>
{
private
final
CouchDbClient
dbClient
;
@Inject
public
Repository
(
final
CouchDbClient
dbClient
)
{
this
.
dbClient
=
checkNotNull
(
dbClient
);
}
public
void
add
(
T
t
)
{
dbClient
.
save
(
t
);
}
public
void
delete
(
final
String
id
)
{
//todo: revision
// dbClient.remove(id, );
}
public
void
update
(
T
t
)
{
dbClient
.
update
(
t
);
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment