Package ca.phon.session.check
Class SessionValidator
java.lang.Object
ca.phon.session.check.SessionValidator
- All Implemented Interfaces:
IExtendable
Session validator with plug-in support. This class maintains the
list of available validator plug-ins as well as a set of
validation listeners.
- Author:
- Greg
-
Constructor Summary
ConstructorDescriptionSessionValidator
(SessionCheck[] sessionChecks) SessionValidator
(List<SessionCheck> sessionChecks) -
Method Summary
Modifier and TypeMethodDescriptionvoid
addValidationListener
(ValidationListener listener) void
void
fireValidationEvent
(ValidationEvent.Severity severity, Session session, int record, String message) void
fireValidationEvent
(ValidationEvent.Severity severity, Session session, int record, String tierName, int group, String message) void
fireValidationEvent
(ValidationEvent.Severity severity, Session session, String message) void
fireValidationEvent
(Session session, int record, String message) void
fireValidationEvent
(Session session, int record, String tierName, int group, String message) void
fireValidationEvent
(Session session, String message) <T> T
getExtension
(Class<T> cap) Get the requested extension if available.Return all extension types supported<T> T
putExtension
(Class<T> cap, T impl) Add a new extension.<T> T
removeExtension
(Class<T> cap) Remove a capability.void
removeValidationListener
(ValidationListener listener) boolean
-
Constructor Details
-
SessionValidator
public SessionValidator() -
SessionValidator
-
SessionValidator
-
-
Method Details
-
fireValidationEvent
-
fireValidationEvent
-
fireValidationEvent
public void fireValidationEvent(ValidationEvent.Severity severity, Session session, int record, String message) -
fireValidationEvent
-
fireValidationEvent
public void fireValidationEvent(ValidationEvent.Severity severity, Session session, int record, String tierName, int group, String message) -
fireValidationEvent
-
fireValidationEvent
-
validate
-
addValidationListener
-
removeValidationListener
-
getValidationListeners
-
getValidationEvents
-
getExtensions
Description copied from interface:IExtendable
Return all extension types supported- Specified by:
getExtensions
in interfaceIExtendable
-
getExtension
Description copied from interface:IExtendable
Get the requested extension if available.- Specified by:
getExtension
in interfaceIExtendable
- Returns:
- the capability object or
null
if the cability is not available
-
putExtension
Description copied from interface:IExtendable
Add a new extension.- Specified by:
putExtension
in interfaceIExtendable
- Parameters:
cap
- the extension to add- Returns:
- the added extension implementation
-
removeExtension
Description copied from interface:IExtendable
Remove a capability.- Specified by:
removeExtension
in interfaceIExtendable
- Parameters:
cap
- the capability to remove
-