Package net.swofty.data.mongodb
Class IslandDatabase
java.lang.Object
net.swofty.data.mongodb.IslandDatabase
- All Implemented Interfaces:
MongoDB
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic com.mongodb.client.MongoClient
static com.mongodb.client.MongoCollection<org.bson.Document>
static com.mongodb.client.MongoDatabase
final String
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
exists()
static org.bson.Document
fetchDocument
(String uniqueId) static UUID
List<org.bson.Document>
getAll()
boolean
getBoolean
(String key, boolean def) org.bson.Document
int
<T> List<T>
long
void
insertOrUpdate
(String key, Object value) boolean
void
-
Field Details
-
GLOBAL_USER_CACHE
-
Document_Cache
-
id
-
client
public static com.mongodb.client.MongoClient client -
database
public static com.mongodb.client.MongoDatabase database -
collection
public static com.mongodb.client.MongoCollection<org.bson.Document> collection
-
-
Constructor Details
-
IslandDatabase
-
-
Method Details
-
connect
-
set
-
get
-
getAll
-
getString
-
getInt
-
getLong
-
getBoolean
- Specified by:
getBoolean
in interfaceMongoDB
-
getList
-
getDocument
public org.bson.Document getDocument() -
remove
-
insertOrUpdate
- Specified by:
insertOrUpdate
in interfaceMongoDB
-
exists
public boolean exists() -
fetchUUID
-
fetchDocument
-