|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface VHostRepository
Implementation of this interface is responsible for loading and storing virtual hosts for the server installation. Configuration based storage is normally read-only. Database storage is read-write. Created: Nov 27, 2008 1:52:25 PM
| Method Summary | |
|---|---|
void |
addVHost(VHostItem vhost)
The method adds a new or updates existing virtual hosts in the repository. |
boolean |
contains(java.lang.String domain)
The method checks whether the given domain is stored in the repository. |
void |
getDefaults(java.util.Map<java.lang.String,java.lang.Object> defs,
java.util.Map<java.lang.String,java.lang.Object> params)
The method is called to obtain defualt configuration settings if there are any for this repository implementation The configuration settings are implementation dependent and there are no defaults set by the server. |
VHostItem |
getVHost(java.lang.String domain)
The method returns all domain configuration parameters for a given domain or null if the domain does not exist in the repository. |
void |
reload()
This method is called to reload virtual hosts from the database or other permanent storage. |
void |
removeVHost(java.lang.String vh)
The method is called to remove given VHost from the memory cache and permanent storage. |
void |
setProperties(java.util.Map<java.lang.String,java.lang.Object> properties)
The method is called to set configuration for this repository implementation. |
int |
size()
The method returns number of virtual domains in the repository. |
| Method Detail |
|---|
void removeVHost(java.lang.String vh)
vh - a String with domain name to remove.void addVHost(VHostItem vhost)
VHostItem has all fields set to "enabled". After this method
call is finished a new added virtual domain must be available as a local
domain for the server installation.
The method adds the vhosts to memory cache and permamnent storage.
vhost - a VHostItem with virtual domain and all it's
configuration parameters.VHostItem getVHost(java.lang.String domain)
null if the domain does not exist in the repository. In
other words it returns null if given domain is not local.
domain - a String with domain name to search for.
VHostItem for a given domain or null
if the domain is not in the repository.boolean contains(java.lang.String domain)
domain - a String with domain name to search for.
boolean value true if domain exist in
the repository or false of domain does not exist.void setProperties(java.util.Map<java.lang.String,java.lang.Object> properties)
properties - a Map with configuration settings. Content
of this Map must not be modified. This read-only collection.
void getDefaults(java.util.Map<java.lang.String,java.lang.Object> defs,
java.util.Map<java.lang.String,java.lang.Object> params)
defs - is a Map collection where all repository
configuration defaults must be put.params - is a Map collection with some preset properties
for the server. These settings can be used to adjust repository defaults,
for example they can contain database connection URL or initial list of
virtual domains.void reload()
int size()
int value with number of virtual hosts in the
repository.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||