~ubuntu-branches/debian/wheezy/jing-trang/wheezy

« back to all changes in this revision

Viewing changes to mod/rng-schema/src/main/com/thaiopensource/relaxng/translate/util/NCNameParam.java

  • Committer: Bazaar Package Importer
  • Author(s): Samuel Thibault
  • Date: 2009-09-01 15:53:03 UTC
  • Revision ID: james.westby@ubuntu.com-20090901155303-2kweef05h5v9j3ni
Tags: upstream-20090818
ImportĀ upstreamĀ versionĀ 20090818

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
package com.thaiopensource.relaxng.translate.util;
 
2
 
 
3
import com.thaiopensource.xml.util.Naming;
 
4
 
 
5
public abstract class NCNameParam extends AbstractParam {
 
6
  public void set(String value) throws InvalidParamValueException {
 
7
    if (!Naming.isNcname(value))
 
8
      throw new ParamProcessor.LocalizedInvalidValueException("invalid_ncname");
 
9
    setNCName(value);
 
10
  }
 
11
 
 
12
  protected abstract void setNCName(String value) throws InvalidParamValueException;
 
13
}