Class TenantRepositoryImpl
java.lang.Object
org.craftercms.commons.mongo.AbstractJongoRepository<Tenant>
org.craftercms.profile.repositories.impl.TenantRepositoryImpl
- All Implemented Interfaces:
org.craftercms.commons.mongo.CrudRepository<Tenant>
,TenantRepository
public class TenantRepositoryImpl
extends org.craftercms.commons.mongo.AbstractJongoRepository<Tenant>
implements TenantRepository
Default implementation of
TenantRepository
.- Author:
- avasquez
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
static final String
static final String
static final String
Fields inherited from class org.craftercms.commons.mongo.AbstractJongoRepository
clazz, collectionName, gridfs, jongo, queries
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionfindByName
(String name) Returns the tenant for the given name.void
init()
void
removeByName
(String name) Removes the tenant for the given name.Methods inherited from class org.craftercms.commons.mongo.AbstractJongoRepository
count, count, count, createSortQuery, deleteFile, deleteFile, find, find, findAll, findById, findByStringId, findOne, findOne, getCollection, getFileInfo, getFileInfo, getQueryFor, insert, insert, listFilesByName, readFile, readFile, remove, remove, removeById, removeByStringId, returnList, returnSimple, save, save, saveFile, saveFile, setJongo, setQueries, update, update, update, update, updateFile, updateFile, updateFile, validateObject, validateObject
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.craftercms.commons.mongo.CrudRepository
count, count, count, deleteFile, deleteFile, find, find, findAll, findById, findByStringId, findOne, findOne, getFileInfo, getFileInfo, insert, insert, listFilesByName, readFile, readFile, remove, remove, removeById, removeByStringId, save, save, saveFile, saveFile, update, update, update, update, updateFile, updateFile, updateFile
-
Field Details
-
KEY_INDEX_KEYS
- See Also:
-
KEY_INDEX_OPTIONS
- See Also:
-
KEY_FIND_BY_NAME_QUERY
- See Also:
-
KEY_REMOVE_BY_NAME_QUERY
- See Also:
-
-
Constructor Details
-
TenantRepositoryImpl
public TenantRepositoryImpl()
-
-
Method Details
-
init
-
findByName
Description copied from interface:TenantRepository
Returns the tenant for the given name.- Specified by:
findByName
in interfaceTenantRepository
- Parameters:
name
- the tenant's name- Returns:
- the tenant, or null if not found.
- Throws:
org.craftercms.commons.mongo.MongoDataException
-
removeByName
Description copied from interface:TenantRepository
Removes the tenant for the given name.- Specified by:
removeByName
in interfaceTenantRepository
- Parameters:
name
- the tenant's name- Throws:
org.craftercms.commons.mongo.MongoDataException
-