/** * Returns a hash code value for this object. * * @return a hash code value for this object. */ public final int hashCode() { return this.getName().hashCode() + ( this.getVersion() == null ? 0 : this.getVersion().hashCode() ); }
/** * Indicates whether some other object is equal to this one by comparing * properties {@code name} and {@code version}. * * @param o the reference object with which to compare. * * @return {@code true} if this object is the same as {@code o}; * {@code false} otherwise. */ public final boolean equals( final Object o ) { boolean equal = this == o; if ( !equal && o instanceof Module ) { final Module that = (Module) o; equal = this.getName().equals( that.getName() ) && ( this.getVersion() == null ? that.getVersion() == null : this.getVersion().equals( that.getVersion() ) ); } return equal; }
this.transformMessage( modelVersion, module.getName(), namespace, (Element) l.item( i ) ) );
final Implementation impl = this.getImplementation( identifier ); impl.setModelVersion( modelVersion ); impl.setModuleName( module.getName() ); impl.setName( xml.getAttributeNS( namespace, "name" ) ); impl.setVendor( xml.getAttributeNS( namespace, "vendor" ) );
if ( PLATFORM_MODULE_NAME.equals( module.getName() ) )
moduleInfo.append('\t').append(modules.getModule(i).getName()). append(' ').append(modules.getModule(i).getVersion()). append('\n');
this.getPlatformModule().getName() );
private void updateSpecificationReferences() { for ( int m = this.modules.size() - 1; m >= 0; m-- ) { final Module module = this.modules.getModule( m ); for ( int s = module.getSpecifications().size() - 1; s >= 0; s-- ) { final Specification spec = module.getSpecifications(). getSpecification( s ); final Collection references = (Collection) this.specifications.get( spec.getIdentifier() ); assert references != null : "Expected specification meta-data."; for ( final Iterator it = references.iterator(); it.hasNext(); ) { final Specification reference = (Specification) it.next(); reference.setModuleName( module.getName() ); if ( !reference.equals( spec ) ) { reference.setDocumentation( spec.getDocumentation() ); reference.setMultiplicity( spec.getMultiplicity() ); reference.setProperties( spec.getProperties() ); reference.setScope( spec.getScope() ); reference.setStateless( spec.isStateless() ); reference.setVendor( spec.getVendor() ); reference.setModelVersion( spec.getModelVersion() ); } } } } }