KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > thaiopensource > relaxng > impl > CombineSchema


1 package com.thaiopensource.relaxng.impl;
2
3 import com.thaiopensource.util.PropertyMap;
4 import com.thaiopensource.validate.AbstractSchema;
5 import com.thaiopensource.validate.Schema;
6 import com.thaiopensource.validate.Validator;
7
8 public class CombineSchema extends AbstractSchema {
9   private final Schema schema1;
10   private final Schema schema2;
11
12   public CombineSchema(Schema schema1, Schema schema2, PropertyMap properties) {
13     super(properties);
14     this.schema1 = schema1;
15     this.schema2 = schema2;
16   }
17
18   public Validator createValidator(PropertyMap properties) {
19     return new CombineValidator(schema1.createValidator(properties),
20                                 schema2.createValidator(properties));
21   }
22 }
23
Popular Tags