KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > ws > jaxme > ValidationEvents


1 /*
2  * Copyright 2003,2004 The Apache Software Foundation
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15
16  */

17 package org.apache.ws.jaxme;
18
19 /** <p>List of error codes, being used in validation events.</p>
20  *
21  * @author <a HREF="mailto:joe@ispsoft.de">Jochen Wiedmann</a>
22  * @version $Id: ValidationEvents.java,v 1.4 2005/03/04 10:41:52 jochen Exp $
23  */

24 public interface ValidationEvents {
25     /** More than one alternative in a choice group have
26      * been used.
27      */

28     public static final String JavaDoc EVENT_CHOICE_GROUP_REUSE = "JM_EVENT_CHOICE_GROUP_REUSE";
29
30 /** <p>A processing instruction was found. JaxMe doesn't know
31    * how to handle processing instruction, thus they are treated
32    * as a validation event, possibly throwing an exception.</p>
33    * <p>This behaviour is questionable. It may very well be changed
34    * at a later time, if another way of handling processing
35    * instructions is defined. However, if we throw an event now,
36    * the possible change is upwards compatible.</p>
37    */

38   public static final String JavaDoc EVENT_PROCESSING_INSTRUCTION = "JM_EVENT_PROCESSING_INSTRUCTION";
39
40   /** <p>A skipped entity was found. JaxMe doesn't know
41    * how to handle skipped entities, thus they are treated
42    * as a validation event, possibly throwing an exception.</p>
43    * <p>This behaviour is questionable. It may very well be changed
44    * at a later time, if another way of handling skipped
45    * entities is defined. However, if we throw an event now,
46    * the possible change is upwards compatible.</p>
47    */

48   public static final String JavaDoc EVENT_SKIPPED_ENTITY = "JM_EVENT_SKIPPED_ENTITY";
49
50   /** <p>Unexpected textual contents have been found. For example,
51    * a sequence must not have embedded text, because it would have
52    * mixed content otherwise. Textual content is ignored, if it
53    * consists of whitespace characters only.</p>
54    */

55   public static final String JavaDoc EVENT_UNEXPECTED_TEXTUAL_CONTENTS = "JM_EVENT_UNEXPECTED_TEXTUAL_CONTENTS";
56
57   /** <p>An unexpected child was found in an atomic element or in a
58    * complex element with simple content.</p>
59    */

60   public static final String JavaDoc EVENT_UNEXPECTED_CHILD_ELEMENT = "JM_EVENT_UNEXPECTED_CHILD_ELEMENT";
61
62   /**A childs of an all group was used more than once.
63    */

64   public static final String JavaDoc EVENT_ALL_GROUP_REUSE = "JM_EVENT_ALL_GROUP_REUSE";
65
66   /** <p>A child element was not expected at this place. For example,
67    * in the case of a choice, this may indicate that more than one
68    * of the possible elements have been found. In the case of a
69    * sequence, this can indicate a mismatch in the order of the
70    * child elements.</p>
71    */

72   public static final String JavaDoc EVENT_UNEXPECTED_CHILD_STATE = "JM_EVENT_UNEXPECTED_CHILD_STATE";
73
74   /** <p>A complex elements child is unknown. A possible reason
75    * is an error in the child elements name.</p>
76    */

77   public static final String JavaDoc EVENT_ADDITIONAL_CHILD_ELEMENT = "JM_EVENT_ADDITIONAL_CHILD_ELEMENT";
78
79   /** <p>An element occurred more than expected. In other words,
80    * the elements <code>maxOccurs</code> facet was violated.</p>
81    */

82   public static final String JavaDoc EVENT_MULTIPLE_OCCURRENCIES = "JM_EVENT_MULTIPLE_OCCURRENCIES";
83
84   /** <p>The root elements type was wrong.</p>
85    */

86   public static final String JavaDoc EVENT_WRONG_ROOT_ELEMENT = "JM_EVENT_WRONG_ROOT_ELEMENT";
87
88   /** <p>An element or attribute value was invalid. For example, in the
89    * case of a dateTime instance, this may indicate an unparseable date.</p>
90    */

91   public static final String JavaDoc EVENT_ILLEGAL_VALUE = "JM_EVENT_ILLEGAL_VALUE";
92
93   /** <p>An attribute was unknown.</p>
94    */

95   public static final String JavaDoc EVENT_UNKNOWN_ATTRIBUTE = "JM_EVENT_UNKNOWN_ATTRIBUTE";
96
97   /** <p>An attribute with an invalid namespace was detected in an
98    * element with an "anyAttribute" declaration.</p>
99    */

100   public static final String JavaDoc EVENT_UNKNOWN_ANY_ATTRIBUTE = "JM_EVENT_UNKNOWN_ANY_ATTRIBUTE";
101
102   /** Some of an elements child are missing.
103    */

104   public static final String JavaDoc EVENT_PREMATURE_END_ELEMENT = null;
105 }
106
Popular Tags