View Javadoc
1   /*
2    * Copyright 2005 Ralf Joachim
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  package org.castor.mapping;
17  
18  import org.exolab.castor.util.DTDResolver;
19  import org.xml.sax.InputSource;
20  
21  /**
22   * @author <a href="mailto:ralf DOT joachim AT syscon DOT eu">Ralf Joachim</a>
23   * @version $Revision: 5951 $ $Date: 2006-04-25 16:09:10 -0600 (Tue, 25 Apr 2006) $
24   */
25  public final class MappingSource {
26      /** The input source. */
27      private final InputSource _source;
28      
29      /** The type of the mapping source. */
30      private final String _type;
31      
32      /** The entity resolver to use. May be null. */
33      private final DTDResolver _resolver;
34  
35      public MappingSource(final InputSource source, final String type, final DTDResolver resolver) {
36          _source = source;
37          _type = type;
38          _resolver = resolver;
39      }
40      
41      public InputSource getSource() { return _source; }
42      
43      public String getType() { return _type; }
44      
45      public DTDResolver getResolver() { return _resolver; }
46  }