public class ErrorPageModel extends ElementModel<org.ops4j.pax.web.service.whiteboard.ErrorPageMapping,ErrorPageEventData>
| Modifier and Type | Field and Description |
|---|---|
static org.slf4j.Logger |
LOG |
contextModels, contextModelsInfo, dtoFailureCode, isValid| Constructor and Description |
|---|
ErrorPageModel(String[] errorPages)
Constructor used for unregistration purposes.
|
ErrorPageModel(String[] errorPages,
String location) |
| Modifier and Type | Method and Description |
|---|---|
ErrorPageEventData |
asEventData()
When sending events related to
ElementModel we can't use the same instance which is kept in
ServerModel, we have to copy relevant
information to lightweight object. |
List<Integer> |
getErrorCodes() |
String[] |
getErrorPages() |
List<String> |
getExceptionClassNames() |
String |
getLocation() |
boolean |
isXx4() |
boolean |
isXx5() |
Boolean |
performValidation()
Perform element-specific validation and throws different exceptions for all element-specific validation
problems.
|
void |
register(WhiteboardWebContainerView view)
Each
ElementModel can register itself as Whiteboard element. |
void |
setLocation(String location) |
org.osgi.service.http.runtime.dto.ErrorPageDTO |
toDTO(ServletModel sm) |
org.osgi.service.http.runtime.dto.FailedErrorPageDTO |
toFailedDTO(ServletModel sm,
int dtoFailureCode) |
String |
toString() |
void |
unregister(WhiteboardWebContainerView view)
Each
ElementModel can unregister itself as Whiteboard element. |
addContextModel, changeContextModels, compareTo, equals, getContextFilter, getContextModels, getContextModelsInfo, getContextSelector, getDtoFailureCode, getElementReference, getElementSupplier, getRegisteringBundle, getServiceId, getServiceRank, getTimestamp, hasContextModels, hashCode, isAsynchronusRegistration, isPrototype, isValid, resetContextModels, setAsynchronusRegistration, setCommonEventProperties, setContextSelectFilter, setContextSelector, setDtoFailureCode, setElementReference, setElementSupplier, setRegisteringBundle, setServiceId, setServiceRank, setTimestampgetId, getIdPrefix, getNumericIdpublic ErrorPageModel(String[] errorPages)
errorPages - public void register(WhiteboardWebContainerView view)
ElementModelElementModel can register itself as Whiteboard element.register in class ElementModel<org.ops4j.pax.web.service.whiteboard.ErrorPageMapping,ErrorPageEventData>public void unregister(WhiteboardWebContainerView view)
ElementModelElementModel can unregister itself as Whiteboard element.unregister in class ElementModel<org.ops4j.pax.web.service.whiteboard.ErrorPageMapping,ErrorPageEventData>public ErrorPageEventData asEventData()
ElementModelElementModel we can't use the same instance which is kept in
ServerModel, we have to copy relevant
information to lightweight object.asEventData in class ElementModel<org.ops4j.pax.web.service.whiteboard.ErrorPageMapping,ErrorPageEventData>public String[] getErrorPages()
public String getLocation()
public void setLocation(String location)
public org.osgi.service.http.runtime.dto.FailedErrorPageDTO toFailedDTO(ServletModel sm, int dtoFailureCode)
public org.osgi.service.http.runtime.dto.ErrorPageDTO toDTO(ServletModel sm)
public String toString()
toString in class ElementModel<org.ops4j.pax.web.service.whiteboard.ErrorPageMapping,ErrorPageEventData>public Boolean performValidation()
ElementModelPerform element-specific validation and throws different exceptions for all element-specific validation problems. This method should not be called for Whiteboard purposes, where "failure DTO" has to be configured.
This method should be called in Http Service scenario where we immediately need strong feedback - with exceptions thrown for all validation problems. In Whiteboard scenario, the exception is caught, logged and it's the tracker that prevents further registration.
This method may alter the state of the model when (which is possible during validation) some extra information is obtained/compiled/processed.
performValidation in class ElementModel<org.ops4j.pax.web.service.whiteboard.ErrorPageMapping,ErrorPageEventData>public boolean isXx4()
public boolean isXx5()
Copyright © 2006–2024 OPS4J - Open Participation Software for Java. All rights reserved.