Skip to content

Commit

Permalink
Issue #273: Fixed issues based on review remarks
Browse files Browse the repository at this point in the history
  • Loading branch information
waisuan committed Nov 1, 2015
1 parent 37cfa4b commit 6418a6c
Show file tree
Hide file tree
Showing 8 changed files with 29 additions and 12 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package main.java.com.wssia.caching;
package com.iluwatar.caching;

/**
*
Expand Down Expand Up @@ -37,6 +37,23 @@
*/
public class App {

/**
* Program entry point
*
* @param args command line args
*/
public static void main(String[] args) {
AppManager.initDB(false); // VirtualDB (instead of MongoDB) was used in running the JUnit tests
// and the App class to avoid Maven compilation errors. Set flag to
// true to run the tests with MongoDB (provided that MongoDB is
// installed and socket connection is open).
AppManager.initCacheCapacity(3);
App app = new App();
app.useReadAndWriteThroughStrategy();
app.useReadThroughAndWriteAroundStrategy();
app.useReadThroughAndWriteBehindStrategy();
}

/**
* Read-through and write-through
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package main.java.com.wssia.caching;
package com.iluwatar.caching;

import java.text.ParseException;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package main.java.com.wssia.caching;
package com.iluwatar.caching;

import java.util.ArrayList;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package main.java.com.wssia.caching;
package com.iluwatar.caching;

/**
*
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package main.java.com.wssia.caching;
package com.iluwatar.caching;

import java.text.ParseException;
import java.util.HashMap;
Expand All @@ -12,13 +12,16 @@

/**
*
* <p>
* DBManager handles the communication with the underlying data store i.e. Database. It contains the
* implemented methods for querying, inserting, and updating data. MongoDB was used as the database
* for the application.
*
* </p>
* <p>
* Developer/Tester is able to choose whether the application should use MongoDB as its underlying
* data storage (connect()) or a simple Java data structure to (temporarily) store the data/objects
* during runtime (createVirtualDB()).
* </p>
*/
public class DBManager {

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package main.java.com.wssia.caching;
package com.iluwatar.caching;

import java.util.ArrayList;
import java.util.HashMap;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package main.java.com.wssia.caching;
package com.iluwatar.caching;

/**
*
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
package test.java.com.wssia.caching;

import main.java.com.wssia.caching.App;
import main.java.com.wssia.caching.AppManager;
package com.iluwatar.caching;

import org.junit.Before;
import org.junit.Test;
Expand Down

0 comments on commit 6418a6c

Please sign in to comment.