@Transactional public class ServerDao extends Object implements IDataProviderDao<Server>
Server
Modifier and Type | Field and Description |
---|---|
static String[] |
searchFields |
Constructor and Description |
---|
ServerDao() |
Modifier and Type | Method and Description |
---|---|
long |
count()
Count the number of instances of
T |
long |
count(String search)
Count the number of instances of
T |
void |
delete(Server entity,
Long userId)
Delete an instance of
T |
List<Server> |
get(int start,
int max)
Get a list of instances of
T |
Server |
get(Long id)
Get an instance of an
T |
List<Server> |
get(String search,
int start,
int count,
String order)
Get a list of instances of
T |
List<Server> |
getActiveServers()
get the list of all servers in the cluster that are ready to receive a
ping (active = true)
|
Server |
getServerByAddress(String address)
Get server by its address
|
List<Server> |
getServerList()
Get a list of all available servers
|
List<Server> |
getServersByName(String name)
get
Server by name |
Server |
update(Server entity,
Long userId)
Update an instance of
T |
public static final String[] searchFields
public List<Server> get(int start, int max)
IDataProviderDao
T
get
in interface IDataProviderDao<Server>
start
- - the start to range to retrievemax
- - maximum instance count to retrievepublic List<Server> get(String search, int start, int count, String order)
IDataProviderDao
T
get
in interface IDataProviderDao<Server>
search
- - string search criteria to filter entitiesstart
- - the start to range to retrievecount
- - maximum instance count to retrieveorder
- - column and sort orderpublic List<Server> getActiveServers()
public long count()
IDataProviderDao
T
count
in interface IDataProviderDao<Server>
public long count(String search)
IDataProviderDao
T
count
in interface IDataProviderDao<Server>
search
- - string search criteria to filter entitiespublic Server get(Long id)
IDataProviderDao
T
get
in interface IDataProviderDao<Server>
id
- - id of instance to retrievepublic Server getServerByAddress(String address)
address
- public Server update(Server entity, Long userId)
IDataProviderDao
T
update
in interface IDataProviderDao<Server>
entity
- - entity to be updateduserId
- - user performed updatepublic void delete(Server entity, Long userId)
IDataProviderDao
T
delete
in interface IDataProviderDao<Server>
entity
- - entity to be deleteduserId
- - user performed deleteCopyright © 2012–2016 Apache Software Foundation. All rights reserved.