1 /*
   2  * reserved comment block
   3  * DO NOT REMOVE OR ALTER!
   4  */
   5 /*
   6  * Copyright 2003,2004 The Apache Software Foundation.
   7  *
   8  * Licensed under the Apache License, Version 2.0 (the "License");
   9  * you may not use this file except in compliance with the License.
  10  * You may obtain a copy of the License at
  11  *
  12  *      http://www.apache.org/licenses/LICENSE-2.0
  13  *
  14  * Unless required by applicable law or agreed to in writing, software
  15  * distributed under the License is distributed on an "AS IS" BASIS,
  16  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  17  * See the License for the specific language governing permissions and
  18  * limitations under the License.
  19  */
  20 
  21 package com.sun.org.apache.xerces.internal.xs;
  22 
  23 /**
  24  * This interface represents the Wildcard schema component.
  25  */
  26 public interface XSWildcard extends XSTerm {
  27     // Namespace Constraint
  28     /**
  29      * Namespace Constraint: any namespace is allowed.
  30      */
  31     public static final short NSCONSTRAINT_ANY          = 1;
  32     /**
  33      * Namespace Constraint: namespaces in the list are not allowed.
  34      */
  35     public static final short NSCONSTRAINT_NOT          = 2;
  36     /**
  37      * Namespace Constraint: namespaces in the list are allowed.
  38      */
  39     public static final short NSCONSTRAINT_LIST         = 3;
  40 
  41     // Process contents
  42     /**
  43      * There must be a top-level declaration for the item available, or the
  44      * item must have an xsi:type, and the item must be valid as appropriate.
  45      */
  46     public static final short PC_STRICT                 = 1;
  47     /**
  48      * No constraints at all: the item must simply be well-formed XML.
  49      */
  50     public static final short PC_SKIP                   = 2;
  51     /**
  52      * If the item, or any items among its [children] is an element
  53      * information item, has a uniquely determined declaration available, it
  54      * must be valid with respect to that definition, that is, validate
  55      * where you can and do not worry when you cannot.
  56      */
  57     public static final short PC_LAX                    = 3;
  58 
  59     /**
  60      * Namespace constraint: A constraint type: any, not, list.
  61      */
  62     public short getConstraintType();
  63 
  64     /**
  65      * Namespace constraint: For <code>constraintType</code>
  66      * <code>NSCONSTRAINT_LIST</code>, the list contains allowed namespaces.
  67      * For <code>constraintType</code> <code>NSCONSTRAINT_NOT</code>, the
  68      * list contains disallowed namespaces. For <code>constraintType</code>
  69      * <code>NSCONSTRAINT_ANY</code>, the <code>StringList</code> is empty.
  70      */
  71     public StringList getNsConstraintList();
  72 
  73     /**
  74      * [process contents]: one of skip, lax or strict. Valid constants values
  75      * are: <code>PC_LAX</code>, <code>PC_SKIP</code> and
  76      * <code>PC_STRICT</code>.
  77      */
  78     public short getProcessContents();
  79 
  80     /**
  81      * An annotation if it exists, otherwise <code>null</code>. If not null
  82      * then the first [annotation] from the sequence of annotations.
  83      */
  84     public XSAnnotation getAnnotation();
  85 
  86     /**
  87      * A sequence of [annotations] or an empty <code>XSObjectList</code>.
  88      */
  89     public XSObjectList getAnnotations();
  90 }