FileDocCategorySizeDatePackage
ConstructorAPI.javaAPI DocAndroid 1.5 API1969Wed May 06 22:41:22 BST 2009jdiff

ConstructorAPI

public class ConstructorAPI extends Object implements Comparable
Class to represent a constructor, analogous to ConstructorDoc in the Javadoc doclet API. The method used for Collection comparison (compareTo) must make its comparison based upon everything that is known about this constructor. See the file LICENSE.txt for copyright details.
author
Matthew Doar, mdoar@pobox.com

Fields Summary
public String
type_
The type of the constructor, being all the parameter types separated by commas.
public String
exceptions_
The exceptions thrown by this constructor, being all the exception types separated by commas. "no exceptions" if no exceptions are thrown.
public Modifiers
modifiers_
Modifiers for this class.
public String
doc_
The doc block, default is null.
Constructors Summary
public ConstructorAPI(String type, Modifiers modifiers)
Constructor.


      
         
        type_ = type;
        modifiers_ = modifiers;
    
Methods Summary
public intcompareTo(java.lang.Object o)
Compare two ConstructorAPI objects by type and modifiers.

        ConstructorAPI constructorAPI = (ConstructorAPI)o;
        int comp = type_.compareTo(constructorAPI.type_);
        if (comp != 0)
            return comp;
        comp = exceptions_.compareTo(constructorAPI.exceptions_);
        if (comp != 0)
            return comp;
        comp = modifiers_.compareTo(constructorAPI.modifiers_);
        if (comp != 0)
            return comp;
        if (APIComparator.docChanged(doc_, constructorAPI.doc_))
            return -1;
        return 0;
    
public booleanequals(java.lang.Object o)
Tests two constructors, using just the type, used by indexOf().

        if (type_.compareTo(((ConstructorAPI)o).type_) == 0)
            return true;
        return false;