| <?xml version='1.0' encoding='UTF-8'?> |
| <!-- Schema file written by PDE --> |
| <schema targetNamespace="org.eclipse.wst.validation" xmlns="http://www.w3.org/2001/XMLSchema"> |
| <annotation> |
| <appinfo> |
| <meta.schema plugin="org.eclipse.wst.validation" id="validatorGroup" name="Validator Group"/> |
| </appinfo> |
| <documentation> |
| Defines a grouping for validators with listeners notified of group members' activites. Useful for pre-caching common information used by multiple validators and disposing of that information when they're all done. |
| </documentation> |
| </annotation> |
| |
| <element name="extension"> |
| <annotation> |
| <appinfo> |
| <meta.element /> |
| </appinfo> |
| </annotation> |
| <complexType> |
| <sequence> |
| <element ref="group" minOccurs="1" maxOccurs="unbounded"/> |
| </sequence> |
| <attribute name="point" type="string" use="required"> |
| <annotation> |
| <documentation> |
| |
| </documentation> |
| </annotation> |
| </attribute> |
| <attribute name="id" type="identifier"> |
| <annotation> |
| <documentation> |
| A unique identifier for this extension |
| </documentation> |
| </annotation> |
| </attribute> |
| <attribute name="name" type="string"> |
| <annotation> |
| <documentation> |
| A name for this extension |
| </documentation> |
| <appinfo> |
| <meta.attribute translatable="true"/> |
| </appinfo> |
| </annotation> |
| </attribute> |
| </complexType> |
| </element> |
| |
| <element name="listener"> |
| <annotation> |
| <documentation> |
| A listener for activities in this group. |
| </documentation> |
| </annotation> |
| <complexType> |
| <attribute name="class" type="string" use="required"> |
| <annotation> |
| <documentation> |
| The listener's class. |
| </documentation> |
| <appinfo> |
| <meta.attribute kind="java" basedOn=":org.eclipse.wst.validation.IValidatorGroupListener"/> |
| </appinfo> |
| </annotation> |
| </attribute> |
| </complexType> |
| </element> |
| |
| <element name="group"> |
| <annotation> |
| <documentation> |
| Declares a validator group. A group may have multiple listeners. |
| </documentation> |
| </annotation> |
| <complexType> |
| <choice> |
| <element ref="listener" minOccurs="1" maxOccurs="unbounded"/> |
| </choice> |
| <attribute name="id" type="string" use="required"> |
| <annotation> |
| <documentation> |
| |
| </documentation> |
| <appinfo> |
| <meta.attribute kind="identifier"/> |
| </appinfo> |
| </annotation> |
| </attribute> |
| </complexType> |
| </element> |
| |
| <annotation> |
| <appinfo> |
| <meta.section type="since"/> |
| </appinfo> |
| <documentation> |
| WebTools 3.0 |
| </documentation> |
| </annotation> |
| |
| <annotation> |
| <appinfo> |
| <meta.section type="examples"/> |
| </appinfo> |
| <documentation> |
| Define a listener that simply prints that it has been called. |
| <pre> |
| <extension point="org.eclipse.wst.validation.validatorGroup"> |
| <group id="validatorGroup"> |
| <listener class="org.eclipse.wst.validation.example.ValidatorGroupListener"/> |
| </group> |
| </extension> |
| |
| public class org.eclipse.wst.validation.example.ValidatorGroupListener implements IValidatorGroupListener { |
| |
| public ValidatorGroupListener() { |
| } |
| |
| public void validationFinishing(IResource resource, IProgressMonitor monitor, ValType valType, ValOperation operation) { |
| System.out.println("Finishing:" + resource.getFullPath()); |
| } |
| |
| public void validationStarting(IResource resource, IProgressMonitor monitor, ValType valType, ValOperation operation) { |
| System.out.println("Starting:" + resource.getFullPath()); |
| } |
| } |
| |
| <extension id="id" name="name" point="org.eclipse.wst.validation.validatorV2"> |
| <validator class="org.eclipse.wst.validation.example.Validator"> |
| <group id="org.eclipse.wst.validation.example.validatorGroup"/> |
| </validator> |
| </extension> |
| </pre> |
| </documentation> |
| </annotation> |
| |
| <annotation> |
| <appinfo> |
| <meta.section type="apiinfo"/> |
| </appinfo> |
| <documentation> |
| Provisional API. |
| </documentation> |
| </annotation> |
| |
| |
| <annotation> |
| <appinfo> |
| <meta.section type="copyright"/> |
| </appinfo> |
| <documentation> |
| Copyright (c) 2008 IBM Corporation and others.<br> |
| All rights reserved. This program and the accompanying materials are made |
| available under the terms of the Eclipse Public License v1.0 which accompanies |
| this distribution, and is available at <a |
| href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a> |
| </documentation> |
| </annotation> |
| |
| </schema> |