Changeset 9246 in josm for trunk


Ignore:
Timestamp:
2016-01-01T22:21:21+01:00 (9 years ago)
Author:
Don-vip
Message:

javadoc update

Location:
trunk
Files:
29 edited

Legend:

Unmodified
Added
Removed
  • trunk/.settings/org.eclipse.jdt.core.prefs

    r8935 r9246  
    5454org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=return_tag
    5555org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
    56 org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
     56org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=enabled
    5757org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
    5858org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=private
    59 org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=ignore
     59org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=warning
    6060org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
    6161org.eclipse.jdt.core.compiler.problem.missingSerialVersion=ignore
     
    7777org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
    7878org.eclipse.jdt.core.compiler.problem.redundantNullCheck=warning
    79 org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=ignore
     79org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=warning
    8080org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
    8181org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
  • trunk/src/org/openstreetmap/josm/actions/mapmode/SelectAction.java

    r9231 r9246  
    12641264    /**
    12651265     * Returns {@code o} as collection of {@code o}'s type.
     1266     * @param <T> object type
    12661267     * @param o any object
    12671268     * @return {@code o} as collection of {@code o}'s type.
  • trunk/src/org/openstreetmap/josm/data/Preferences.java

    r9243 r9246  
    13381338     * Default constructor is used to initialize the struct objects, properties
    13391339     * then override some of these default values.
     1340     * @param <T> klass type
    13401341     * @param key main preference key
    13411342     * @param klass The struct class
     
    13521353    /**
    13531354     * same as above, but returns def if nothing was found
     1355     * @param <T> klass type
    13541356     * @param key main preference key
    13551357     * @param def default value
  • trunk/src/org/openstreetmap/josm/data/cache/JCSCacheManager.java

    r9142 r9246  
    124124    /**
    125125     * Returns configured cache object for named cache region
     126     * @param <K> key type
     127     * @param <V> value type
    126128     * @param cacheName region name
    127129     * @return cache access object
     
    134136    /**
    135137     * Returns configured cache object with defined limits of memory cache and disk cache
     138     * @param <K> key type
     139     * @param <V> value type
    136140     * @param cacheName         region name
    137141     * @param maxMemoryObjects  number of objects to keep in memory
  • trunk/src/org/openstreetmap/josm/data/gpx/IWithAttributes.java

    r7518 r9246  
    3131     * Returns the Collection value to which the specified key is mapped,
    3232     * or {@code null} if this map contains no Collection mapping for the key.
     33     * @param <T> type of items
    3334     *
    3435     * @param key the key whose associated value is to be returned
  • trunk/src/org/openstreetmap/josm/data/osm/Storage.java

    r9243 r9246  
    277277    /**
    278278     * Finds a bucket for given key.
     279     * @param <K> type for hashCode and first equals parameter
    279280     * @param ha hash function
    280281     *
     
    350351    /**
    351352     * A factory for default hash implementation.
    352      * @return a hash implementation that just delegates to object's own
    353      * hashCode and equals.
     353     * @param <O> type for hash
     354     * @return a hash implementation that just delegates to object's own hashCode and equals.
    354355     */
    355356    public static <O> Hash<O, O> defaultHash() {
  • trunk/src/org/openstreetmap/josm/data/validation/OsmValidator.java

    r8882 r9246  
    229229    /**
    230230     * Returns the instance of the given test class.
     231     * @param <T> testClass type
    231232     * @param testClass The class of test to retrieve
    232233     * @return the instance of the given test class, if any, or {@code null}
  • trunk/src/org/openstreetmap/josm/gui/MainMenu.java

    r9243 r9246  
    535535     * This method handles all the shortcut handling. It also makes sure that actions that are
    536536     * handled by the OS are not duplicated on the menu.
     537     * @param <E> group item enum type
    537538     * @param menu to add the action to
    538539     * @param action the action that should get a menu item
     
    556557     * Add a JosmAction to a menu and automatically prints accelerator if available.
    557558     * Also adds a checkbox that may be toggled.
     559     * @param <E> group enum item type
    558560     * @param menu to add the action to
    559561     * @param action the action that should get a menu item
     
    622624    /**
    623625     * Adds the given menu on the given position to the main menu.
     626     * @param <T> menu type
    624627     *
    625628     * @param menu              the menu to add
  • trunk/src/org/openstreetmap/josm/gui/MapFrame.java

    r9243 r9246  
    648648    /**
    649649     * Find panel on top of MapView by class
     650     * @param <T> type
    650651     * @param type type of panel
    651652     * @return found panel
  • trunk/src/org/openstreetmap/josm/gui/MapView.java

    r9243 r9246  
    838838     *     List&lt;WMSLayer&gt; wmsLayers = getLayersOfType(WMSLayer.class);
    839839     * </pre>
     840     * @param <T> layer type
    840841     *
    841842     * @param ofType The layer type.
  • trunk/src/org/openstreetmap/josm/gui/dialogs/CommandStackDialog.java

    r9243 r9246  
    197197    /**
    198198     * Wires updater for enabled state to the events. Also updates dialog title if needed.
     199     * @param updater updater
     200     * @param tree tree on which wire updater
    199201     */
    200202    protected void wireUpdateEnabledStateUpdater(final IEnabledStateUpdating updater, JTree tree) {
  • trunk/src/org/openstreetmap/josm/gui/dialogs/LayerListDialog.java

    r9224 r9246  
    160160    /**
    161161     * Creates a layer list and attach it to the given mapView.
     162     * @param mapFrame map frame
    162163     */
    163164    protected LayerListDialog(MapFrame mapFrame) {
     
    831832        /**
    832833         * Constructs a new {@code MergeAction}.
     834         * @param layer the layer (null if layer list if specified)
     835         * @param layers the layer list (null if a single layer is specified)
    833836         */
    834837        private MergeAction(Layer layer, List<Layer> layers) {
  • trunk/src/org/openstreetmap/josm/gui/dialogs/relation/MemberTableModel.java

    r9195 r9246  
    6464    /**
    6565     * constructor
     66     * @param layer data layer
     67     * @param presetHandler tagging preset handler
    6668     */
    6769    public MemberTableModel(OsmDataLayer layer, TaggingPresetHandler presetHandler) {
     
    7375    }
    7476
     77    /**
     78     * Returns the data layer.
     79     * @return the data layer
     80     */
    7581    public OsmDataLayer getLayer() {
    7682        return layer;
     
    525531    /**
    526532     * Replies the set of selected referers. Never null, but may be empty.
     533     * @param referenceSet reference set
    527534     *
    528535     * @return the set of selected referers
  • trunk/src/org/openstreetmap/josm/gui/dialogs/relation/RelationDialogManager.java

    r9059 r9246  
    231231     * upper left corner is close to <code>p</code>.
    232232     *
    233      * @param p  the reference point to check
     233     * @param p the reference point to check
     234     * @param thisEditor the current editor
    234235     * @return true, if there is another open {@link RelationEditor} whose
    235236     * upper left corner is close to <code>p</code>.
  • trunk/src/org/openstreetmap/josm/gui/dialogs/relation/sort/RelationNodeMap.java

    r9059 r9246  
    2727 *
    2828 * @author Christiaan Welvaart &lt;cjw@time4t.net&gt;
    29  *
     29 * @since 1785
    3030 */
    3131public class RelationNodeMap {
     
    173173
    174174    /**
    175      * Return a relation member that is linked to the
    176      * member 'i', but has not been popped yet.
     175     * Return a relation member that is linked to the member 'i', but has not been popped yet.
    177176     * Return null if there is no such member left.
     177     * @param way way key
     178     * @return a relation member that is linked to the member 'i', but has not been popped yet
    178179     */
    179180    public Integer popAdjacent(Integer way) {
     
    295296
    296297    /**
    297      * Returns some remaining member or null if
    298      * every sortable member has been processed.
     298     * Returns some remaining member or null if every sortable member has been processed.
     299     * @return member key
    299300     */
    300301    public Integer pop() {
     
    306307
    307308        if (remainingOneway.isEmpty()) return null;
    308         for (Integer i :remainingOneway.keySet()) { //find oneway, which is connected to more than one way (is between two oneway loops)
     309        for (Integer i : remainingOneway.keySet()) { //find oneway, which is connected to more than one way (is between two oneway loops)
    309310            for (Node n : onewayReverseMap.ways.get(i)) {
    310311                if (onewayReverseMap.nodes.containsKey(n) && onewayReverseMap.nodes.get(n).size() > 1) {
     
    324325     * This relation member has been processed.
    325326     * Remove references in the map.nodes.
     327     * @param i member key
    326328     */
    327329    private void doneOneway(Integer i) {
  • trunk/src/org/openstreetmap/josm/gui/dialogs/relation/sort/RelationSortUtils.java

    r8549 r9246  
    1919    /**
    2020     * determine, if the way i is a roundabout and if yes, what type of roundabout
     21     * @param member relation member
     22     * @return roundabout type
    2123     */
    2224    static Direction roundaboutType(RelationMember member) {
    2325        if (member == null || !member.isWay()) return NONE;
    24         Way w = member.getWay();
    25         return roundaboutType(w);
     26        return roundaboutType(member.getWay());
    2627    }
    2728
  • trunk/src/org/openstreetmap/josm/gui/dialogs/relation/sort/WayConnectionTypeCalculator.java

    r9087 r9246  
    2222    /**
    2323     * refresh the cache of member WayConnectionTypes
     24     * @param members relation members
     25     * @return way connections
    2426     */
    2527    public List<WayConnectionType> updateLinks(List<RelationMember> members) {
     
    215217
    216218    /**
    217      * Determines the direction of way k with respect to the way ref_i.
    218      * The way ref_i is assumed to have the direction ref_direction and
    219      * to be the predecessor of k.
     219     * Determines the direction of way {@code k} with respect to the way {@code ref_i}.
     220     * The way {@code ref_i} is assumed to have the direction {@code ref_direction} and to be the predecessor of {@code k}.
    220221     *
    221222     * If both ways are not linked in any way, NONE is returned.
     
    224225     * Let the relation be a route of oneway streets, and someone travels them in the given order.
    225226     * Direction is FORWARD if it is legal and BACKWARD if it is illegal to do so for the given way.
    226      *
    227      **/
     227     * @param ref_i way key
     228     * @param ref_direction direction of ref_i
     229     * @param k successor of ref_i
     230     * @param reversed if {@code true} determine reverse direction
     231     * @return direction of way {@code k}
     232     */
    228233    private Direction determineDirection(int ref_i, final Direction ref_direction, int k, boolean reversed) {
    229234        if (ref_i < 0 || k < 0 || ref_i >= members.size() || k >= members.size())
  • trunk/src/org/openstreetmap/josm/gui/help/HelpContentReader.java

    r9168 r9246  
    3535     *
    3636     * @param helpTopicUrl  the absolute help topic URL
     37     * @param dotest
    3738     * @return the content, filtered and transformed for being displayed in the internal help browser
    3839     * @throws HelpContentReaderException if problem occurs
     
    6869     *
    6970     * @param in the input stream
     71     * @param dotest if {@code true}, checks if help content is empty
     72     * @param url help topic URL
    7073     * @return the content
    7174     * @throws HelpContentReaderException if an exception occurs
  • trunk/src/org/openstreetmap/josm/gui/history/TwoColumnDiff.java

    r9078 r9246  
    9191     * The result from the diff algorithm is a "script" (a compressed description of the changes)
    9292     * This method expands this script into a full two column description.
     93     * @param script diff script
     94     * @param a reference version
     95     * @param b current version
     96     * @param reversed if {@code true} use {@link DiffItemType#REVERSED} instead of {@link DiffItemType#SAME}
    9397     */
    9498    private void twoColumnDiffFromScript(Diff.Change script, Object[] a, Object[] b, final boolean reversed) {
  • trunk/src/org/openstreetmap/josm/gui/io/AbstractUploadTask.java

    r8540 r9246  
    5353     * Synchronizes the local state of an {@link OsmPrimitive} with its state on the
    5454     * server. The method uses an individual GET for the primitive.
    55      *
     55     * @param type the primitive type
    5656     * @param id the primitive ID
    5757     */
     
    192192     * Handles the case that a conflict was detected while uploading where we don't
    193193     * know what {@link OsmPrimitive} actually caused the conflict (for whatever reason)
    194      *
     194     * @param changesetId changeset ID
     195     * @param d changeset date
    195196     */
    196197    protected void handleUploadConflictForClosedChangeset(long changesetId, Date d) {
     
    211212     * Handles the case where deleting a node failed because it is still in use in
    212213     * a non-deleted way on the server.
     214     * @param e exception
     215     * @param conflict conflict
    213216     */
    214217    protected void handleUploadPreconditionFailedConflict(OsmApiException e, Pair<OsmPrimitive, Collection<OsmPrimitive>> conflict) {
  • trunk/src/org/openstreetmap/josm/gui/io/LayerNameAndFilePathTableCell.java

    r8846 r9246  
    121121    }
    122122
    123     /** adds layer name label to (this) using the given info. Returns tooltip that
    124      * should be added to the panel **/
     123    /**
     124     * Adds layer name label to (this) using the given info. Returns tooltip that should be added to the panel
     125     * @param info information, user preferences and save/upload states of the layer
     126     * @return tooltip that should be added to the panel
     127     */
    125128    private String addLblLayerName(SaveLayerInfo info) {
    126129        lblLayerName.setIcon(info.getLayer().getIcon());
     
    130133    }
    131134
    132     /** adds filename label to (this) using the given info. Returns tooltip that
    133      * should be added to the panel */
     135    /**
     136     * Adds filename label to (this) using the given info. Returns tooltip that should be added to the panel
     137     * @param info information, user preferences and save/upload states of the layer
     138     * @return tooltip that should be added to the panel
     139     */
    134140    private String addLblFilename(SaveLayerInfo info) {
    135141        String tooltip = "";
     
    157163    }
    158164
    159     /** makes the given path fit lblFilename, appends ellipsis on the left if it doesn’t fit.
    160      * Idea: /home/user/josm → …/user/josm → …/josm; and take the first one that fits */
     165    /**
     166     * Makes the given path fit lblFilename, appends ellipsis on the left if it doesn’t fit.
     167     * Idea: /home/user/josm → …/user/josm → …/josm; and take the first one that fits
     168     * @param t complete path
     169     * @return shorter path
     170     */
    161171    private String makePathFit(String t) {
    162172        boolean hasEllipsis = false;
  • trunk/src/org/openstreetmap/josm/gui/io/TagSettingsPanel.java

    r8846 r9246  
    8080    }
    8181
     82    /**
     83     * Initialize panel from changeset.
     84     * @param cs changeset
     85     */
    8286    public void initFromChangeset(Changeset cs) {
    8387        Map<String, String> tags = getDefaultTags();
     
    103107    /**
    104108     * Replies the map with the current tags in the tag editor model.
    105      *
     109     * @param keepEmpty {@code true} to keep empty tags
    106110     * @return the map with the current tags in the tag editor model.
    107111     */
     
    110114    }
    111115
     116    /**
     117     * Replies the map with the default tags.
     118     * @return the map with the default tags
     119     */
    112120    public Map<String, String> getDefaultTags() {
    113121        Map<String, String> tags = new HashMap<>();
     
    116124    }
    117125
     126    /**
     127     * Sets the map with the default tags.
     128     * @param tags the map with the default tags
     129     */
    118130    public void setDefaultTags(Map<String, String> tags) {
    119131        defaultTags.clear();
  • trunk/src/org/openstreetmap/josm/gui/tagging/TagEditorModel.java

    r9231 r9246  
    436436    }
    437437
     438    /**
     439     * Returns tags, without empty ones.
     440     * @return not-empty tags
     441     */
    438442    public Map<String, String> getTags() {
    439443        return getTags(false);
    440444    }
    441445
     446    /**
     447     * Returns tags.
     448     * @param keepEmpty {@code true} to keep empty tags
     449     * @return tags
     450     */
    442451    public Map<String, String> getTags(boolean keepEmpty) {
    443452        return applyToTags(keepEmpty);
  • trunk/src/org/openstreetmap/josm/gui/util/GuiHelper.java

    r9231 r9246  
    122122     * <a href="http://docs.oracle.com/javase/tutorial/uiswing/concurrency/dispatch.html">Event Dispatch Thread</a>
    123123     * and return a value.
     124     * @param <V> the result type of method <tt>call</tt>
    124125     * @param callable The callable to execute
    125126     * @return The computed result
  • trunk/src/org/openstreetmap/josm/tools/Pair.java

    r8846 r9246  
    6969    /**
    7070     * Convenient constructor method
     71     * @param <U> type of first item
     72     * @param <V> type of second item
    7173     * @param u The first item
    7274     * @param v The second item
  • trunk/src/org/openstreetmap/josm/tools/Predicates.java

    r8928 r9246  
    1818    /**
    1919     * Returns the negation of {@code predicate}.
     20     * @param <T> type of items
    2021     * @param predicate the predicate to negate
    2122     * @return the negation of {@code predicate}
     
    3233    /**
    3334     * Returns a {@link Predicate} executing {@link Objects#equals}.
     35     * @param <T> type of items
    3436     * @param ref the reference object
    3537     * @return a {@link Predicate} executing {@link Objects#equals}
     
    117119    /**
    118120     * Returns a {@link Predicate} executing {@link Collection#contains(Object)}.
     121     * @param <T> type of items
    119122     * @param target collection
    120123     * @return a {@link Predicate} executing {@link Collection#contains(Object)}
     
    131134    /**
    132135     * Returns a {@link Predicate} testing whether objects are {@code null}.
     136     * @param <T> type of items
    133137     * @return a {@link Predicate} testing whether objects are {@code null}
    134138     */
  • trunk/src/org/openstreetmap/josm/tools/Utils.java

    r9231 r9246  
    9595    /**
    9696     * Tests whether {@code predicate} applies to at least one element from {@code collection}.
     97     * @param <T> type of items
    9798     * @param collection the collection
    9899     * @param predicate the predicate
     
    109110    /**
    110111     * Tests whether {@code predicate} applies to all elements from {@code collection}.
     112     * @param <T> type of items
    111113     * @param collection the collection
    112114     * @param predicate the predicate
     
    149151    /**
    150152     * Returns the first element from {@code items} which is non-null, or null if all elements are null.
     153     * @param <T> type of items
    151154     * @param items the items to look for
    152155     * @return first non-null item if there is one
     
    165168     * Filter a collection by (sub)class.
    166169     * This is an efficient read-only implementation.
     170     * @param <S> Super type of items
     171     * @param <T> type of items
    167172     * @param collection the collection
    168173     * @param klass the (sub)class
     
    349354    /**
    350355     * Copies the given array. Unlike {@link Arrays#copyOf}, this method is null-safe.
     356     * @param <T> type of items
    351357     * @param array The array to copy
    352358     * @return A copy of the original array, or {@code null} if {@code array} is null
     
    657663    /**
    658664     * Topological sort.
     665     * @param <T> type of items
    659666     *
    660667     * @param dependencies contains mappings (key -&gt; value). In the final list of sorted objects, the key will come
     
    12251232    /**
    12261233     * Adds the given item at the end of a new copy of given array.
     1234     * @param <T> type of items
    12271235     * @param array The source array
    12281236     * @param item The item to add
  • trunk/test/unit/org/CustomMatchers.java

    r8857 r9246  
    2626    /**
    2727     * Matcher for a predicate.
     28     * @param <T> type of elements
    2829     * @param predicate the predicate
    2930     * @return matcher for a predicate
  • trunk/test/unit/org/openstreetmap/josm/TestUtils.java

    r9202 r9246  
    5050    /**
    5151     * Checks that the given Comparator respects its contract on the given table.
     52     * @param <T> type of elements
    5253     * @param comparator The comparator to test
    5354     * @param array The array sorted for test purpose
Note: See TracChangeset for help on using the changeset viewer.