本文整理了Java中java.lang.Package.getSpecificationTitle()
方法的一些代码示例,展示了Package.getSpecificationTitle()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Package.getSpecificationTitle()
方法的具体详情如下:
包路径:java.lang.Package
类名称:Package
方法名:getSpecificationTitle
[英]Returns the title of the specification this package implements, or null if this is unknown.
[中]返回此包实现的规范的标题,如果未知,则返回null。
代码示例来源:origin: robovm/robovm
/**
* <p>Get state of XInclude processing.</p>
*
* @return current state of XInclude processing
*
* @throws UnsupportedOperationException
* For backward compatibility, when implementations for
* earlier versions of JAXP is used, this exception will be
* thrown.
*
* @since 1.5
*/
public boolean isXIncludeAware() {
throw new UnsupportedOperationException(
"This parser does not support specification \""
+ this.getClass().getPackage().getSpecificationTitle()
+ "\" version \""
+ this.getClass().getPackage().getSpecificationVersion()
+ "\""
);
}
}
代码示例来源:origin: robovm/robovm
/**
* <p>Get state of XInclude processing.</p>
*
* @return current state of XInclude processing
*
* @throws UnsupportedOperationException
* For backward compatibility, when implementations for
* earlier versions of JAXP is used, this exception will be
* thrown.
*
* @since 1.5
*/
public boolean isXIncludeAware() {
throw new UnsupportedOperationException(
"This parser does not support specification \""
+ this.getClass().getPackage().getSpecificationTitle()
+ "\" version \""
+ this.getClass().getPackage().getSpecificationVersion()
+ "\""
);
}
}
代码示例来源:origin: robovm/robovm
/**
* <p>Reset this <code>DocumentBuilder</code> to its original configuration.</p>
*
* <p><code>DocumentBuilder</code> is reset to the same state as when it was created with
* {@link DocumentBuilderFactory#newDocumentBuilder()}.
* <code>reset()</code> is designed to allow the reuse of existing <code>DocumentBuilder</code>s
* thus saving resources associated with the creation of new <code>DocumentBuilder</code>s.</p>
*
* <p>The reset <code>DocumentBuilder</code> is not guaranteed to have the same {@link EntityResolver} or {@link ErrorHandler}
* <code>Object</code>s, e.g. {@link Object#equals(Object obj)}. It is guaranteed to have a functionally equal
* <code>EntityResolver</code> and <code>ErrorHandler</code>.</p>
*
* @since 1.5
*/
public void reset() {
// implementors should override this method
throw new UnsupportedOperationException(
"This DocumentBuilder, \"" + this.getClass().getName() + "\", does not support the reset functionality."
+ " Specification \"" + this.getClass().getPackage().getSpecificationTitle() + "\""
+ " version \"" + this.getClass().getPackage().getSpecificationVersion() + "\""
);
}
代码示例来源:origin: robovm/robovm
/**
* <p>Reset this <code>SAXParser</code> to its original configuration.</p>
*
* <p><code>SAXParser</code> is reset to the same state as when it was created with
* {@link SAXParserFactory#newSAXParser()}.
* <code>reset()</code> is designed to allow the reuse of existing <code>SAXParser</code>s
* thus saving resources associated with the creation of new <code>SAXParser</code>s.</p>
*
* <p>The reset <code>SAXParser</code> is not guaranteed to have the same {@link Schema}
* <code>Object</code>, e.g. {@link Object#equals(Object obj)}. It is guaranteed to have a functionally equal
* <code>Schema</code>.</p>
*
* @since 1.5
*/
public void reset() {
// implementors should override this method
throw new UnsupportedOperationException(
"This SAXParser, \"" + this.getClass().getName() + "\", does not support the reset functionality."
+ " Specification \"" + this.getClass().getPackage().getSpecificationTitle() + "\""
+ " version \"" + this.getClass().getPackage().getSpecificationVersion() + "\""
);
}
代码示例来源:origin: robovm/robovm
/** <p>Get a reference to the the {@link Schema} being used by
* the XML processor.</p>
*
* <p>If no schema is being used, <code>null</code> is returned.</p>
*
* @return {@link Schema} being used or <code>null</code>
* if none in use
*
* @throws UnsupportedOperationException
* For backward compatibility, when implementations for
* earlier versions of JAXP is used, this exception will be
* thrown.
*
* @since 1.5
*/
public Schema getSchema() {
throw new UnsupportedOperationException(
"This parser does not support specification \""
+ this.getClass().getPackage().getSpecificationTitle()
+ "\" version \""
+ this.getClass().getPackage().getSpecificationVersion()
+ "\""
);
}
代码示例来源:origin: robovm/robovm
/** <p>Get a reference to the the {@link Schema} being used by
* the XML processor.</p>
*
* <p>If no schema is being used, <code>null</code> is returned.</p>
*
* @return {@link Schema} being used or <code>null</code>
* if none in use
*
* @throws UnsupportedOperationException
* For backward compatibility, when implementations for
* earlier versions of JAXP is used, this exception will be
* thrown.
*
* @since 1.5
*/
public Schema getSchema() {
throw new UnsupportedOperationException(
"This parser does not support specification \""
+ this.getClass().getPackage().getSpecificationTitle()
+ "\" version \""
+ this.getClass().getPackage().getSpecificationVersion()
+ "\""
);
}
代码示例来源:origin: robovm/robovm
/**
* <p>Set state of XInclude processing.</p>
*
* <p>If XInclude markup is found in the document instance, should it be
* processed as specified in <a href="http://www.w3.org/TR/xinclude/">
* XML Inclusions (XInclude) Version 1.0</a>.</p>
*
* <p>XInclude processing defaults to <code>false</code>.</p>
*
* @param state Set XInclude processing to <code>true</code> or
* <code>false</code>
*
* @throws UnsupportedOperationException
* For backward compatibility, when implementations for
* earlier versions of JAXP is used, this exception will be
* thrown.
*
* @since 1.5
*/
public void setXIncludeAware(final boolean state) {
throw new UnsupportedOperationException(
"This parser does not support specification \""
+ this.getClass().getPackage().getSpecificationTitle()
+ "\" version \""
+ this.getClass().getPackage().getSpecificationVersion()
+ "\""
);
}
代码示例来源:origin: robovm/robovm
/**
* Gets the {@link Schema} object specified through
* the {@link #setSchema(Schema schema)} method.
*
*
* @throws UnsupportedOperationException
* For backward compatibility, when implementations for
* earlier versions of JAXP is used, this exception will be
* thrown.
*
* @return
* the {@link Schema} object that was last set through
* the {@link #setSchema(Schema)} method, or null
* if the method was not invoked since a {@link SAXParserFactory}
* is created.
*
* @since 1.5
*/
public Schema getSchema() {
throw new UnsupportedOperationException(
"This parser does not support specification \""
+ this.getClass().getPackage().getSpecificationTitle()
+ "\" version \""
+ this.getClass().getPackage().getSpecificationVersion()
+ "\""
);
}
代码示例来源:origin: robovm/robovm
/**
* <p>Reset this <code>Transformer</code> to its original configuration.</p>
*
* <p><code>Transformer</code> is reset to the same state as when it was created with
* {@link TransformerFactory#newTransformer()},
* {@link TransformerFactory#newTransformer(Source source)} or
* {@link Templates#newTransformer()}.
* <code>reset()</code> is designed to allow the reuse of existing <code>Transformer</code>s
* thus saving resources associated with the creation of new <code>Transformer</code>s.</p>
*
* <p>The reset <code>Transformer</code> is not guaranteed to have the same {@link URIResolver}
* or {@link ErrorListener} <code>Object</code>s, e.g. {@link Object#equals(Object obj)}.
* It is guaranteed to have a functionally equal <code>URIResolver</code>
* and <code>ErrorListener</code>.</p>
*
* @since 1.5
*/
public void reset() {
// implementors should override this method
throw new UnsupportedOperationException(
"This Transformer, \"" + this.getClass().getName() + "\", does not support the reset functionality."
+ " Specification \"" + this.getClass().getPackage().getSpecificationTitle() + "\""
+ " version \"" + this.getClass().getPackage().getSpecificationVersion() + "\""
);
}
代码示例来源:origin: robovm/robovm
/**
* <p>Get the XInclude processing mode for this parser.</p>
*
* @return
* the return value of
* the {@link SAXParserFactory#isXIncludeAware()}
* when this parser was created from factory.
*
* @throws UnsupportedOperationException
* For backward compatibility, when implementations for
* earlier versions of JAXP is used, this exception will be
* thrown.
*
* @since 1.5
*
* @see SAXParserFactory#setXIncludeAware(boolean)
*/
public boolean isXIncludeAware() {
throw new UnsupportedOperationException(
"This parser does not support specification \""
+ this.getClass().getPackage().getSpecificationTitle()
+ "\" version \""
+ this.getClass().getPackage().getSpecificationVersion()
+ "\""
);
}
}
代码示例来源:origin: robovm/robovm
/**
* <p>Get the XInclude processing mode for this parser.</p>
*
* @return
* the return value of
* the {@link DocumentBuilderFactory#isXIncludeAware()}
* when this parser was created from factory.
*
* @throws UnsupportedOperationException
* For backward compatibility, when implementations for
* earlier versions of JAXP is used, this exception will be
* thrown.
*
* @since 1.5
*
* @see DocumentBuilderFactory#setXIncludeAware(boolean)
*/
public boolean isXIncludeAware() {
throw new UnsupportedOperationException(
"This parser does not support specification \""
+ this.getClass().getPackage().getSpecificationTitle()
+ "\" version \""
+ this.getClass().getPackage().getSpecificationVersion()
+ "\""
);
}
}
代码示例来源:origin: robovm/robovm
/**
* Gets the {@link Schema} object specified through
* the {@link #setSchema(Schema schema)} method.
*
*
* @throws UnsupportedOperationException
* For backward compatibility, when implementations for
* earlier versions of JAXP is used, this exception will be
* thrown.
*
* @return
* the {@link Schema} object that was last set through
* the {@link #setSchema(Schema)} method, or null
* if the method was not invoked since a {@link DocumentBuilderFactory}
* is created.
*
* @since 1.5
*/
public Schema getSchema() {
throw new UnsupportedOperationException(
"This parser does not support specification \""
+ this.getClass().getPackage().getSpecificationTitle()
+ "\" version \""
+ this.getClass().getPackage().getSpecificationVersion()
+ "\""
);
}
代码示例来源:origin: robovm/robovm
/**
* <p>Set state of XInclude processing.</p>
*
* <p>If XInclude markup is found in the document instance, should it be
* processed as specified in <a href="http://www.w3.org/TR/xinclude/">
* XML Inclusions (XInclude) Version 1.0</a>.</p>
*
* <p>XInclude processing defaults to <code>false</code>.</p>
*
* @param state Set XInclude processing to <code>true</code> or
* <code>false</code>
*
* @throws UnsupportedOperationException
* For backward compatibility, when implementations for
* earlier versions of JAXP is used, this exception will be
* thrown.
*
* @since 1.5
*/
public void setXIncludeAware(final boolean state) {
throw new UnsupportedOperationException(
"This parser does not support specification \""
+ this.getClass().getPackage().getSpecificationTitle()
+ "\" version \""
+ this.getClass().getPackage().getSpecificationVersion()
+ "\""
);
}
代码示例来源:origin: robovm/robovm
throw new UnsupportedOperationException(
"This parser does not support specification \""
+ this.getClass().getPackage().getSpecificationTitle()
+ "\" version \""
+ this.getClass().getPackage().getSpecificationVersion()
代码示例来源:origin: robovm/robovm
throw new UnsupportedOperationException(
"This parser does not support specification \""
+ this.getClass().getPackage().getSpecificationTitle()
+ "\" version \""
+ this.getClass().getPackage().getSpecificationVersion()
代码示例来源:origin: net.java.dev.jna/jna
/** Prints JNA library details to the console. */
public static void main(String[] args) {
final String DEFAULT_TITLE = "Java Native Access (JNA)";
final String DEFAULT_VERSION = VERSION;
final String DEFAULT_BUILD = VERSION + " (package information missing)";
Package pkg = Native.class.getPackage();
String title = pkg != null
? pkg.getSpecificationTitle() : DEFAULT_TITLE;
if (title == null) title = DEFAULT_TITLE;
String version = pkg != null
? pkg.getSpecificationVersion() : DEFAULT_VERSION;
if (version == null) version = DEFAULT_VERSION;
title += " API Version " + version;
System.out.println(title);
version = pkg != null
? pkg.getImplementationVersion() : DEFAULT_BUILD;
if (version == null) version = DEFAULT_BUILD;
System.out.println("Version: " + version);
System.out.println(" Native: " + getNativeVersion() + " ("
+ getAPIChecksum() + ")");
System.out.println(" Prefix: " + Platform.RESOURCE_PREFIX);
}
代码示例来源:origin: zeromq/jzmq
public static void main(final String[] args) throws Exception {
final String appname = p.getSpecificationTitle();
final String versionMaven = p.getSpecificationVersion();
String[] version = new String[] { "", "" };
代码示例来源:origin: openscoring/openscoring
static
private String discoverNameAndVersion(){
Package _package = ModelResource.class.getPackage();
String result = (_package.getSpecificationTitle() + "/" + _package.getSpecificationVersion());
logger.info("Application name and version: {}", result);
return result;
}
代码示例来源:origin: apache/karaf
public boolean isXIncludeAware() {
throw new UnsupportedOperationException(
"This parser does not support specification \""
+ this.getClass().getPackage().getSpecificationTitle()
+ "\" version \""
+ this.getClass().getPackage().getSpecificationVersion()
+ "\""
);
}
代码示例来源:origin: apache/karaf
public Schema getSchema() {
throw new UnsupportedOperationException(
"This parser does not support specification \""
+ this.getClass().getPackage().getSpecificationTitle()
+ "\" version \""
+ this.getClass().getPackage().getSpecificationVersion()
+ "\""
);
}
内容来源于网络,如有侵权,请联系作者删除!