Ignore:
Timestamp:
2010-09-15T18:54:18+02:00 (15 years ago)
Author:
stoecker
Message:

remove tabs

Location:
applications/editors/josm/plugins/czechaddress/src/org/openstreetmap/josm/plugins/czechaddress/addressdatabase
Files:
9 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/czechaddress/src/org/openstreetmap/josm/plugins/czechaddress/addressdatabase/AddressElement.java

    r19943 r23190  
    1414 *
    1515 * <p>Every element must have a <i>name</i> and may have a <i>parent</i>.</p>
    16  * 
     16 *
    1717 * @author Radomír Černoch radomir.cernoch@gmail.com
    1818 */
     
    9999            Node node = (Node) prim;
    100100            result += " " + StringUtils.latLonToString(node.getCoor());
    101            
     101
    102102        } else if (prim instanceof Way) {
    103103            Way way = (Way) prim;
     
    135135    /**
    136136     * Compares 2 elements.
    137      * 
     137     *
    138138     * <p>Basic criterion to comparing elements is their <i>name</i> and the
    139139     * </i>parent</i>. Notice that this behaviour might be changed
     
    217217    }
    218218
    219    
     219
    220220    protected int[] getFieldMatchList(OsmPrimitive primitive) {
    221         int[] result = {0};       
     221        int[] result = {0};
    222222        return result;
    223223    }
     
    242242     */
    243243    public int getQ(OsmPrimitive primitive) {
    244        
     244
    245245        // Firstly get integers representing a match of every matchable field.
    246246        int[] fieldMatches = getFieldMatchList(primitive);
    247247        assert fieldMatches.length > 0;
    248        
     248
    249249        // Now find the max and min of this array.
    250250        int minVal = fieldMatches[0];
     
    260260        assert Math.abs(minVal) <= 1;
    261261        assert Math.abs(maxVal) <= 1;
    262        
     262
    263263        // If the best among all fields is 'neutral' match, the given primitive
    264264        // has nothing to do with our field.
    265265        if (maxVal <= 0)
    266266            return Reasoner.MATCH_NOMATCH;
    267        
     267
    268268        // If all fields are 1    --> ROCKSOLID MATCH
    269269        // If some are 1, none -1 --> PARTIAL MATCH
     
    274274            case +1 : return Reasoner.MATCH_ROCKSOLID;
    275275        }
    276        
     276
    277277        return 0; // <-- just to make compilers happy. We cannot get here.
    278278    }
  • applications/editors/josm/plugins/czechaddress/src/org/openstreetmap/josm/plugins/czechaddress/addressdatabase/Database.java

    r15585 r23190  
    99 * <p>Contains the tree of all regions, municipalities, suburbs, streets
    1010 * and houses in the Czech republic.</p>
    11  * 
     11 *
    1212 * @see AddressElement
    1313 * @see DatabaseParser
  • applications/editors/josm/plugins/czechaddress/src/org/openstreetmap/josm/plugins/czechaddress/addressdatabase/ElementWithHouses.java

    r15763 r23190  
    4747    /**
    4848     * Returns all houses directly contained in this element.
    49      * 
     49     *
    5050     * NOTICE: If a subclass element contains other data structured capable
    5151     * of storing houses, they are not included in the returned set.
  • applications/editors/josm/plugins/czechaddress/src/org/openstreetmap/josm/plugins/czechaddress/addressdatabase/ElementWithStreets.java

    r15585 r23190  
    2424    public void addStreet(Street streetToAdd) {
    2525        //if (streetToAdd.getParent() instanceof ElementWithStreets)
    26        
     26
    2727        streetToAdd.setParent(this);
    2828        streets.add(streetToAdd);
     
    7979        // We make an conservative estimate...
    8080        List<House> result = new ArrayList<House>(20 * streets.size());
    81        
     81
    8282        result.addAll(this.houses);
    83        
     83
    8484        for (Street street : streets)
    8585            result.addAll(street.getHouses());
    86        
     86
    8787        return result;
    8888    }
  • applications/editors/josm/plugins/czechaddress/src/org/openstreetmap/josm/plugins/czechaddress/addressdatabase/House.java

    r16743 r23190  
    2020 * {@link ElementWithHouses}. The {@code setParent()} method should
    2121 * be called immediatelly after the constructor.</p>
    22  * 
     22 *
    2323 * @author Radomír Černoch, radomir.cernoch@gmail.com
    2424 */
     
    4444
    4545        assert (co != null) || (cp != null);
    46        
     46
    4747        //... but the the name is overwritten.
    4848        this.name = generateName(this.cp, this.co);
    4949    }
    50    
     50
    5151    /**
    5252     * Returns the number unique in a suburb (číslo popisné)
     
    128128        super.setParent(parent);
    129129    }
    130    
     130
    131131    /**
    132132     * Returns the parent of this house with type-checking.
     
    159159        result[0] = matchField(this.cp, prim.get(PrimUtils.KEY_ADDR_CP));
    160160        result[2] = matchField(name,    prim.get(PrimUtils.KEY_ADDR_HOUSE_N));
    161        
     161
    162162        // Second field is the Housenumber
    163163        if (parent instanceof Street)
     
    178178    }
    179179
    180    
     180
    181181
    182182    /**
     
    188188    @Override
    189189    public List<Proposal> getDiff(OsmPrimitive prim) {
    190        
     190
    191191        List<Proposal> props = new NotNullList<Proposal>();
    192192        ParentResolver resolver = new ParentResolver(this);
  • applications/editors/josm/plugins/czechaddress/src/org/openstreetmap/josm/plugins/czechaddress/addressdatabase/Region.java

    r15585 r23190  
    1010 */
    1111public class Region extends ElementWithStreets {
    12    
     12
    1313    private ArrayList<ViToCi> vitocis
    1414            = new ArrayList<ViToCi>();
    15    
     15
    1616    /**
    1717     * Adds a single municipality into this element.
     
    2121        vitocis.add(municipality);
    2222    }
    23    
     23
    2424    /**
    2525     * Replaces the list of municipalities of this element.
     
    3030            obec.setParent(this);
    3131    }
    32    
     32
    3333    /**
    3434     * Returns the list of all municipalities in this region.
     
    5353    String nuts3name = null;
    5454    String nuts4name = null;
    55    
     55
    5656    /**
    5757     * Default constructor setting the name of this region.
     
    6161        super(name);
    6262    }
    63    
     63
    6464    /**
    6565     * Constructor which sets the region's name together with higher
     
    7171        if (nuts4name != null) this.nuts4name = nuts4name;
    7272    }
    73    
     73
    7474    public String getNuts3Name() {
    7575        return nuts3name;
    7676    }
    77    
     77
    7878    public String getNuts4Name() {
    7979        return nuts4name;
    8080    }
    81    
     81
    8282    /**
    8383     * Returns the name of this region. If the NUTS3 name was entered,
     
    8686    @Override
    8787    public String toString() {
    88        
     88
    8989        String thisString = name;
    90        
     90
    9191        if (nuts3name != null)
    9292            thisString += " (kraj " + nuts3name + ")";
    93        
     93
    9494        return thisString;
    9595    }
  • applications/editors/josm/plugins/czechaddress/src/org/openstreetmap/josm/plugins/czechaddress/addressdatabase/Street.java

    r15582 r23190  
    2525        super.setParent(parent);
    2626    }
    27    
     27
    2828    @Override
    2929    public ElementWithStreets getParent() {
     
    3636        int[] result = {0};
    3737        if (!isMatchable(primitive)) return result;
    38        
     38
    3939        result[0] = matchFieldAbbrev(name, primitive.get("name"));
    4040        return result;
     
    4444    public List<Proposal> getDiff(OsmPrimitive prim) {
    4545        List<Proposal> props = new NotNullList<Proposal>();
    46        
     46
    4747        props.add(getStringFieldDiff(PrimUtils.KEY_NAME, prim.get(PrimUtils.KEY_NAME), getName()));
    4848        return props;
  • applications/editors/josm/plugins/czechaddress/src/org/openstreetmap/josm/plugins/czechaddress/addressdatabase/Suburb.java

    r15582 r23190  
    66/**
    77 * Suburb is a part of a {@link Municipality}.
    8  * 
     8 *
    99 * @author Radomír Černoch radomir.cernoch@gmail.com
    1010 */
  • applications/editors/josm/plugins/czechaddress/src/org/openstreetmap/josm/plugins/czechaddress/addressdatabase/ViToCi.java

    r15582 r23190  
    66/**
    77 * ViToCi is either a village, town or a city.
    8  * 
     8 *
    99 * @author Radomír Černoch radomir.cernoch@gmail.com
    1010 */
Note: See TracChangeset for help on using the changeset viewer.