Package org.opennms.web.rest.v1.config
Class EmailNorthbounderConfigurationResource
- java.lang.Object
-
- org.opennms.web.rest.v1.OnmsRestService
-
- org.opennms.web.rest.v1.config.EmailNorthbounderConfigurationResource
-
- All Implemented Interfaces:
org.springframework.beans.factory.InitializingBean
@Component public class EmailNorthbounderConfigurationResource extends OnmsRestService implements org.springframework.beans.factory.InitializingBean
The Class EmailNorthbounderConfigurationResource.- Author:
- Alejandro Galue
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classEmailNorthbounderConfigurationResource.EmailDestinationListThe Class EmailDestinationList.-
Nested classes/interfaces inherited from class org.opennms.web.rest.v1.OnmsRestService
OnmsRestService.ComparisonOperation
-
-
Field Summary
-
Fields inherited from class org.opennms.web.rest.v1.OnmsRestService
DEFAULT_LIMIT
-
-
Constructor Summary
Constructors Constructor Description EmailNorthbounderConfigurationResource()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidafterPropertiesSet()javax.ws.rs.core.ResponsegetConfiguration()Gets the configuration.EmailDestinationgetEmailDestination(String destinationName)Gets an email destination.javax.ws.rs.core.ResponsegetEmailDestinations()Gets all the email destinations.javax.ws.rs.core.ResponsegetStatus()Gets the status.javax.ws.rs.core.ResponsegetStatus(Boolean enabled)Gets the status.javax.ws.rs.core.ResponseremoveEmailDestination(String destinationName)Removes a specific email destination.javax.ws.rs.core.ResponsesetConfiguration(EmailNorthbounderConfig config)Sets the configuration.javax.ws.rs.core.ResponsesetEmailDestination(EmailDestination destination)Sets an email destination.javax.ws.rs.core.ResponseupdateEmailDestination(String destinationName, MultivaluedMapImpl params)Updates a specific email destination.-
Methods inherited from class org.opennms.web.rest.v1.OnmsRestService
applyQueryFilters, applyQueryFilters, getBadRequestResponse, getBeanWrapperForClass, getException, getException, getNumericValue, getRedirectUri, readLock, readUnlock, removeParameter, removeParameter, setProperties, writeLock, writeUnlock
-
-
-
-
Method Detail
-
afterPropertiesSet
public void afterPropertiesSet() throws Exception- Specified by:
afterPropertiesSetin interfaceorg.springframework.beans.factory.InitializingBean- Throws:
Exception
-
getConfiguration
public javax.ws.rs.core.Response getConfiguration()
Gets the configuration.- Returns:
- the configuration
-
setConfiguration
public javax.ws.rs.core.Response setConfiguration(EmailNorthbounderConfig config)
Sets the configuration.- Parameters:
config- the full configuration object- Returns:
- the response
-
getStatus
public javax.ws.rs.core.Response getStatus()
Gets the status.- Returns:
- the status
-
getStatus
public javax.ws.rs.core.Response getStatus(Boolean enabled) throws javax.ws.rs.WebApplicationException
Gets the status.- Parameters:
enabled- the enabled- Returns:
- the status
- Throws:
javax.ws.rs.WebApplicationException- the web application exception
-
getEmailDestinations
public javax.ws.rs.core.Response getEmailDestinations()
Gets all the email destinations.- Returns:
- the email destinations
-
getEmailDestination
public EmailDestination getEmailDestination(String destinationName)
Gets an email destination.- Parameters:
destinationName- the destination name- Returns:
- the email destination
-
setEmailDestination
public javax.ws.rs.core.Response setEmailDestination(EmailDestination destination)
Sets an email destination.If there is a destination with the same name, the existing one will be overridden.
- Parameters:
destination- the destination- Returns:
- the response
-
updateEmailDestination
public javax.ws.rs.core.Response updateEmailDestination(String destinationName, MultivaluedMapImpl params)
Updates a specific email destination.- Parameters:
destinationName- the destination nameparams- the parameters map- Returns:
- the response
-
removeEmailDestination
public javax.ws.rs.core.Response removeEmailDestination(String destinationName)
Removes a specific email destination.- Parameters:
destinationName- the destination name- Returns:
- the response
-
-