Changeset 166

Show
Ignore:
Timestamp:
08/19/09 17:47:05 (2 years ago)
Author:
jgao
Message:

checkstyle fix

Location:
trunk/corelib/src/org/bridgedb/webservice/biomart
Files:
3 modified

Legend:

Unmodified
Added
Removed
  • trunk/corelib/src/org/bridgedb/webservice/biomart/BiomartStub.java

    r161 r166  
    2323import java.util.HashMap; 
    2424import java.util.HashSet; 
    25 import java.util.Iterator; 
    2625import java.util.Map; 
    2726import java.util.Set; 
    28 import java.util.Vector; 
    2927 
    3028import javax.xml.parsers.ParserConfigurationException; 
    3129 
    32 import org.bridgedb.DataSource; 
    3330import org.bridgedb.IDMapperException; 
    34 import org.bridgedb.Xref; 
    35 import org.bridgedb.file.IDMappingReaderFromDelimitedReader; 
    3631import org.bridgedb.webservice.biomart.util.Attribute; 
    3732import org.bridgedb.webservice.biomart.util.BiomartClient; 
     
    4439 
    4540/** 
    46  * Cache for SynergizerClient 
     41 * Wrapp-up for BiomartClient. 
    4742 * @author gjj 
    4843 */ 
    49 public class BiomartStub { 
     44public final class BiomartStub { 
    5045    public static final String defaultBaseURL 
    5146            = BiomartClient.defaultBaseURL; 
    5247 
    53     // cache data 
    54 //    private Map<String,Map<String,Map<String,Set<String>>>> 
    55 //            mapAuthSpeciesDomainRange = null; 
    56  
    5748    // one instance per url 
    5849    private static Map<String, BiomartStub> instances = new HashMap(); 
     
    6051    /** 
    6152     * 
    62      * @return SynergizerStub with the default server url 
     53     * @return BiomartStub with the default server url 
    6354     * @throws IOException if failed to connect 
    6455     */ 
     
    7061     * 
    7162     * @param baseUrl server url 
    72      * @return SynergizerStub from the server 
     63     * @return BiomartStub from the server 
    7364     * @throws IOException if failed to connect 
    7465     */ 
     
    129120     * @param mart mart name 
    130121     * @return mart display name or null if not exist 
    131      * @throws IDMapperException if failed to connect 
    132122     */ 
    133123    public String martDisplayName(String mart) { 
     
    142132    /** 
    143133     * 
    144      * @param authority mart name 
     134     * @param mart mart name 
    145135     * @return available datasets from this mart 
    146      * @throws IDMapperException if failed 
    147136     */ 
    148137    public Set<String> availableDatasets(String mart) 
     
    170159     * @param dataset dataset name 
    171160     * @return dataset display name or null if not exist 
    172      * @throws IDMapperException if failed to connect 
    173161     */ 
    174162    public String datasetDisplayName(String dataset) { 
     
    211199    /** 
    212200     * 
    213      * @param mart mart name 
    214      * @param dataset dataset name 
     201     * @param mart mart name. 
     202     * @param dataset dataset name. 
     203     * @param idOnly filter the attributes ending with "ID" or "Accession" 
     204     *        if true; no filter otherwise. 
    215205     * @return attribute names / target id types of the dataset from this 
    216      *         mart 
     206     *         mart. 
    217207     * @throws IDMapperException if failed. 
    218208     */ 
     
    239229            result = new HashSet(); 
    240230            for (String name : attributes.keySet()) { 
    241                 String displayName = client.getAttribute(dataset, name).getDisplayName(); 
     231                String displayName = client.getAttribute(dataset, name) 
     232                        .getDisplayName(); 
    242233                if (displayName.endsWith("ID") 
    243234                        || displayName.endsWith("Accession") 
     
    264255     *         key: source id 
    265256     *         value: corresponding target ids 
    266      * @throws IDMapperException 
     257     * @throws IDMapperException if failed to connect 
    267258     */ 
    268259    public Map<String,Set<String>[]> translate(final String mart, 
  • trunk/corelib/src/org/bridgedb/webservice/biomart/IDMapperBiomart.java

    r161 r166  
    140140     * @param idOnlyForTgtDataSource id-only option, filter data source ends 
    141141     *        with 'ID' or 'Accession'. 
    142      * @param transitivity transitivity option 
    143142     * @throws IDMapperException if failed to link to the dataset 
    144143     */ 
     
    168167     * @param idOnlyForTgtDataSource id-only option, filter data source ends 
    169168     *        with 'ID' or 'Accession'. 
    170      * @param transitivity transitivity option 
    171169     * @throws IDMapperException if failed to link to the dataset 
    172170     */ 
     
    335333 
    336334    /** 
    337      * Get supported source data sources 
     335     * Get supported source data sources. 
    338336     * @return supported source data sources 
    339      * @throws IOException if failed to read the filters 
     337     * @throws IDMapperException if failed to read the filters 
    340338     */ 
    341339    protected Set<DataSource> getSupportedSrcDataSources() 
     
    353351 
    354352    /** 
    355      * Get supported target data sources 
     353     * Get supported target data sources. 
    356354     * @return supported target data sources 
    357      * @throws IOException if failed to read the filters 
     355     * @throws IDMapperException if failed to read the filters 
    358356     */ 
    359357    protected Set<DataSource> getSupportedTgtDataSources()  
  • trunk/corelib/src/org/bridgedb/webservice/biomart/util/BiomartClient.java

    r161 r166  
    127127    /** 
    128128     * 
    129      * @param dataset 
    130      * @param filter 
    131      * @return 
     129     * @param dataset dataset name 
     130     * @param filter filter name 
     131     * @return Attribute converted from filter 
    132132     */ 
    133133    public Attribute filterToAttribute(String dataset, String filter) {