Fields Summary |
---|
private String | extensionNameThe name of the optional package being made available, or required. |
private DeweyDecimal | specificationVersionThe version number (dotted decimal notation) of the specification
to which this optional package conforms. |
private String | specificationVendorThe name of the company or organization that originated the
specification to which this optional package conforms. |
private String | implementationVendorIDThe unique identifier of the company that produced the optional
package contained in this JAR file. |
private String | implementationVendorThe name of the company or organization that produced this
implementation of this optional package. |
private DeweyDecimal | implementationVersionThe version number (dotted decimal notation) for this implementation
of the optional package. |
private String | implementationURLThe URL from which the most recent version of this optional package
can be obtained if it is not already installed. |
Methods Summary |
---|
public void | setExtensionName(java.lang.String extensionName)Set the name of extension.
verifyNotAReference();
this.extensionName = extensionName;
|
public void | setImplementationUrl(java.lang.String implementationURL)Set the implementationURL of extension.
verifyNotAReference();
this.implementationURL = implementationURL;
|
public void | setImplementationVendor(java.lang.String implementationVendor)Set the implementationVendor of extension.
verifyNotAReference();
this.implementationVendor = implementationVendor;
|
public void | setImplementationVendorId(java.lang.String implementationVendorID)Set the implementationVendorID of extension.
verifyNotAReference();
this.implementationVendorID = implementationVendorID;
|
public void | setImplementationVersion(java.lang.String implementationVersion)Set the implementationVersion of extension.
verifyNotAReference();
this.implementationVersion = new DeweyDecimal(implementationVersion);
|
public void | setRefid(org.apache.tools.ant.types.Reference reference)Makes this instance in effect a reference to another ExtensionAdapter
instance.
You must not set another attribute or nest elements inside
this element if you make it a reference.
if (null != extensionName
|| null != specificationVersion
|| null != specificationVendor
|| null != implementationVersion
|| null != implementationVendorID
|| null != implementationVendor
|| null != implementationURL) {
throw tooManyAttributes();
}
// change this to get the objects from the other reference
Object o = reference.getReferencedObject(getProject());
if (o instanceof ExtensionAdapter) {
final ExtensionAdapter other = (ExtensionAdapter) o;
extensionName = other.extensionName;
specificationVersion = other.specificationVersion;
specificationVendor = other.specificationVendor;
implementationVersion = other.implementationVersion;
implementationVendorID = other.implementationVendorID;
implementationVendor = other.implementationVendor;
implementationURL = other.implementationURL;
} else {
final String message =
reference.getRefId() + " doesn\'t refer to a Extension";
throw new BuildException(message);
}
super.setRefid(reference);
|
public void | setSpecificationVendor(java.lang.String specificationVendor)Set the specificationVendor of extension.
verifyNotAReference();
this.specificationVendor = specificationVendor;
|
public void | setSpecificationVersion(java.lang.String specificationVersion)Set the specificationVersion of extension.
verifyNotAReference();
this.specificationVersion = new DeweyDecimal(specificationVersion);
|
Extension | toExtension()Convert this adpater object into an extension object.
if (null == extensionName) {
final String message = "Extension is missing name.";
throw new BuildException(message);
}
String specificationVersionString = null;
if (null != specificationVersion) {
specificationVersionString = specificationVersion.toString();
}
String implementationVersionString = null;
if (null != implementationVersion) {
implementationVersionString = implementationVersion.toString();
}
return new Extension(extensionName,
specificationVersionString,
specificationVendor,
implementationVersionString,
implementationVendor,
implementationVendorID,
implementationURL);
|
public java.lang.String | toString()a debug toString method.
return "{" + toExtension().toString() + "}";
|
private void | verifyNotAReference()
if (isReference()) {
throw tooManyAttributes();
}
|