org.apache.batik.xml.XMLUtilities.isXMLNameFirstCharacter()方法的使用及代码示例

x33g5p2x  于2022-02-03 转载在 其他  
字(6.0k)|赞(0)|评价(0)|浏览(142)

本文整理了Java中org.apache.batik.xml.XMLUtilities.isXMLNameFirstCharacter()方法的一些代码示例,展示了XMLUtilities.isXMLNameFirstCharacter()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XMLUtilities.isXMLNameFirstCharacter()方法的具体详情如下:
包路径:org.apache.batik.xml.XMLUtilities
类名称:XMLUtilities
方法名:isXMLNameFirstCharacter

XMLUtilities.isXMLNameFirstCharacter介绍

[英]Tests whether the given character is usable as the first character of an XML name.
[中]测试给定字符是否可用作XML名称的第一个字符。

代码示例

代码示例来源:origin: org.apache.xmlgraphics/batik-xml

if (!isXMLNameFirstCharacter(c)) {
  return 0;

代码示例来源:origin: fr.avianey.apache-xmlgraphics/batik

if (!isXMLNameFirstCharacter(c)) {
  return 0;

代码示例来源:origin: apache/batik

if (!isXMLNameFirstCharacter(c)) {
  return 0;

代码示例来源:origin: org.apache.xmlgraphics/batik-xml

/**
 * Reads a name. The current character must be the first character.
 * @param type The lexical unit type to set.
 * @return type.
 */
protected int readName(int type) throws IOException, XMLException {
  if (current == -1) {
    throw createXMLException("unexpected.eof");
  }
  if (!XMLUtilities.isXMLNameFirstCharacter((char)current)) {
    throw createXMLException("invalid.name");
  }
  do {
    nextChar();
  } while (current != -1 &&
       XMLUtilities.isXMLNameCharacter((char)current));
  return type;
}

代码示例来源:origin: fr.avianey.apache-xmlgraphics/batik

float offset = parseOffset();
  ret = new Object[] { new Integer(TIME_OFFSET), new Float(offset) };
} else if (XMLUtilities.isXMLNameFirstCharacter((char) current)) {
  ret = parseIDValue(escaped);
} else {

代码示例来源:origin: fr.avianey.apache-xmlgraphics/batik

/**
 * Reads a name. The current character must be the first character.
 * @param type The lexical unit type to set.
 * @return type.
 */
protected int readName(int type) throws IOException, XMLException {
  if (current == -1) {
    throw createXMLException("unexpected.eof");
  }
  if (!XMLUtilities.isXMLNameFirstCharacter((char)current)) {
    throw createXMLException("invalid.name");
  }
  do {
    nextChar();
  } while (current != -1 &&
       XMLUtilities.isXMLNameCharacter((char)current));
  return type;
}

代码示例来源:origin: apache/batik

/**
 * Reads a name. The current character must be the first character.
 * @param type The lexical unit type to set.
 * @return type.
 */
protected int readName(int type) throws IOException, XMLException {
  if (current == -1) {
    throw createXMLException("unexpected.eof");
  }
  if (!XMLUtilities.isXMLNameFirstCharacter((char)current)) {
    throw createXMLException("invalid.name");
  }
  do {
    nextChar();
  } while (current != -1 &&
       XMLUtilities.isXMLNameCharacter((char)current));
  return type;
}

代码示例来源:origin: apache/batik

float offset = parseOffset();
  ret = new Object[] {TIME_OFFSET, offset};
} else if (XMLUtilities.isXMLNameFirstCharacter((char) current)) {
  ret = parseIDValue(escaped);
} else {

代码示例来源:origin: org.apache.xmlgraphics/batik-parser

float offset = parseOffset();
  ret = new Object[] {TIME_OFFSET, offset};
} else if (XMLUtilities.isXMLNameFirstCharacter((char) current)) {
  ret = parseIDValue(escaped);
} else {

代码示例来源:origin: org.apache.xmlgraphics/batik-xml

/**
 * Reads a parameter entity reference. The current character must be '%'.
 * @return type.
 */
protected int readPEReference() throws IOException, XMLException {
  nextChar();
  if (current == -1) {
    throw createXMLException("unexpected.eof");
  }
  if (!XMLUtilities.isXMLNameFirstCharacter((char)current)) {
    throw createXMLException("invalid.parameter.entity");
  }
  do {
    nextChar();
  } while (current != -1 &&
       XMLUtilities.isXMLNameCharacter((char)current));
  if (current != ';') {
    throw createXMLException("invalid.parameter.entity");
  }
  nextChar();
  return LexicalUnits.PARAMETER_ENTITY_REFERENCE;
}

代码示例来源:origin: apache/batik

/**
 * Reads a parameter entity reference. The current character must be '%'.
 * @return type.
 */
protected int readPEReference() throws IOException, XMLException {
  nextChar();
  if (current == -1) {
    throw createXMLException("unexpected.eof");
  }
  if (!XMLUtilities.isXMLNameFirstCharacter((char)current)) {
    throw createXMLException("invalid.parameter.entity");
  }
  do {
    nextChar();
  } while (current != -1 &&
       XMLUtilities.isXMLNameCharacter((char)current));
  if (current != ';') {
    throw createXMLException("invalid.parameter.entity");
  }
  nextChar();
  return LexicalUnits.PARAMETER_ENTITY_REFERENCE;
}

代码示例来源:origin: fr.avianey.apache-xmlgraphics/batik

/**
 * Reads a parameter entity reference. The current character must be '%'.
 * @return type.
 */
protected int readPEReference() throws IOException, XMLException {
  nextChar();
  if (current == -1) {
    throw createXMLException("unexpected.eof");
  }
  if (!XMLUtilities.isXMLNameFirstCharacter((char)current)) {
    throw createXMLException("invalid.parameter.entity");
  }
  do {
    nextChar();
  } while (current != -1 &&
       XMLUtilities.isXMLNameCharacter((char)current));
  if (current != ';') {
    throw createXMLException("invalid.parameter.entity");
  }
  nextChar();
  return LexicalUnits.PARAMETER_ENTITY_REFERENCE;
}

代码示例来源:origin: fr.avianey.apache-xmlgraphics/batik

throw createXMLException("unexpected.eof");
if (!XMLUtilities.isXMLNameFirstCharacter((char)current)) {
  throw createXMLException("malformed.pi.target");

代码示例来源:origin: org.apache.xmlgraphics/batik-xml

throw createXMLException("unexpected.eof");
if (!XMLUtilities.isXMLNameFirstCharacter((char)current)) {
  throw createXMLException("malformed.pi.target");

代码示例来源:origin: apache/batik

throw createXMLException("unexpected.eof");
if (!XMLUtilities.isXMLNameFirstCharacter((char)current)) {
  throw createXMLException("malformed.pi.target");

代码示例来源:origin: fr.avianey.apache-xmlgraphics/batik

return;
default:
  if (XMLUtilities.isXMLNameFirstCharacter((char) current)) {
    do {
      nextChar();

代码示例来源:origin: org.apache.xmlgraphics/batik-bridge

return;
default:
  if (XMLUtilities.isXMLNameFirstCharacter((char) current)) {
    do {
      nextChar();

代码示例来源:origin: org.apache.xmlgraphics/batik-xml

int c1 = nextChar();
if (c1 == -1 ||
  !XMLUtilities.isXMLNameFirstCharacter((char)c1)) {
  throw createXMLException("invalid.pi.target");

代码示例来源:origin: fr.avianey.apache-xmlgraphics/batik

int c1 = nextChar();
if (c1 == -1 ||
  !XMLUtilities.isXMLNameFirstCharacter((char)c1)) {
  throw createXMLException("invalid.pi.target");

代码示例来源:origin: apache/batik

int c1 = nextChar();
if (c1 == -1 ||
  !XMLUtilities.isXMLNameFirstCharacter((char)c1)) {
  throw createXMLException("invalid.pi.target");

相关文章