From 7bbb74b985c2153a46723b20fdfa81a5c11e6fa7 Mon Sep 17 00:00:00 2001 From: Hannes Janetzek Date: Sat, 8 Feb 2014 02:51:35 +0100 Subject: [PATCH] fix docs --- vtm/src/org/oscim/event/EventDispatcher.java | 2 +- vtm/src/org/oscim/layers/MapEventLayer.java | 9 +------- .../oscim/layers/marker/ItemizedLayer.java | 11 ++++----- vtm/src/org/oscim/map/Map.java | 2 +- vtm/src/org/oscim/renderer/LayerRenderer.java | 2 +- .../org/oscim/theme/RenderThemeHandler.java | 4 ---- vtm/src/org/oscim/tiling/TileManager.java | 5 +--- .../oscim/tiling/source/common/LwHttp.java | 6 ----- .../tiling/source/common/UrlTileSource.java | 6 ++--- vtm/src/org/oscim/utils/LineClipper.java | 2 -- vtm/src/org/oscim/utils/ScanBox.java | 6 +---- vtm/src/org/oscim/utils/Tessellator.java | 23 ------------------- .../org/oscim/utils/async/AsyncExecutor.java | 2 +- .../org/oscim/utils/async/AsyncResult.java | 2 +- 14 files changed, 16 insertions(+), 66 deletions(-) diff --git a/vtm/src/org/oscim/event/EventDispatcher.java b/vtm/src/org/oscim/event/EventDispatcher.java index 5576e1e9..87605920 100644 --- a/vtm/src/org/oscim/event/EventDispatcher.java +++ b/vtm/src/org/oscim/event/EventDispatcher.java @@ -26,7 +26,7 @@ public class EventDispatcher { * * @param source the event source * @param event the event object/type - * @param data, some object involved in this event + * @param data some object involved in this event */ public void onEvent(Object source, Event event, E data); } diff --git a/vtm/src/org/oscim/layers/MapEventLayer.java b/vtm/src/org/oscim/layers/MapEventLayer.java index 1d459cba..4a10b65c 100644 --- a/vtm/src/org/oscim/layers/MapEventLayer.java +++ b/vtm/src/org/oscim/layers/MapEventLayer.java @@ -28,15 +28,8 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; /** - * Changes Viewport for scroll, fling, scale, rotation and tilt gestures - * - * @TODO: - * - better recognition of tilt/rotate/scale state - * one could check change of rotation / scale within a - * given time to estimate if the mode should be changed: - * http://en.wikipedia.org/wiki/Viterbi_algorithm + * Changes Viewport for move, fling, scale, rotation and tilt gestures. */ - public class MapEventLayer extends Layer implements Map.InputListener, GestureListener { static final Logger log = LoggerFactory.getLogger(MapEventLayer.class); diff --git a/vtm/src/org/oscim/layers/marker/ItemizedLayer.java b/vtm/src/org/oscim/layers/marker/ItemizedLayer.java index 154eef61..e7bebbe2 100644 --- a/vtm/src/org/oscim/layers/marker/ItemizedLayer.java +++ b/vtm/src/org/oscim/layers/marker/ItemizedLayer.java @@ -277,15 +277,14 @@ public abstract class ItemizedLayer extends MarkerLayer } /** + * TODO * If the given Item is found in the overlay, force it to be the current - * focus-bearer. Any registered {@@link - * ItemizedOverlay#OnFocusChangeListener} will be notified. This does not - * move the map, so if the Item isn't already centered, the user may get - * confused. If the Item is not found, this is a no-op. You can also pass - * null to remove focus. + * focus-bearer. Any registered {link ItemizedLayer#OnFocusChangeListener} + * will be notified. This does not move the map, so if the Item isn't + * already centered, the user may get confused. If the Item is not found, + * this is a no-op. You can also pass null to remove focus. * * @param item - * ... */ public void setFocus(final Item item) { mFocusedItem = item; diff --git a/vtm/src/org/oscim/map/Map.java b/vtm/src/org/oscim/map/Map.java index 6ae50d1e..3230c80a 100644 --- a/vtm/src/org/oscim/map/Map.java +++ b/vtm/src/org/oscim/map/Map.java @@ -209,7 +209,7 @@ public abstract class Map { /** * Get current {@link MapPosition}. * - * @param mapPosition + * @return true when MapPosition was updated (has changed) */ public boolean getMapPosition(MapPosition mapPosition) { return mViewport.getMapPosition(mapPosition); diff --git a/vtm/src/org/oscim/renderer/LayerRenderer.java b/vtm/src/org/oscim/renderer/LayerRenderer.java index c2a16940..588f99df 100644 --- a/vtm/src/org/oscim/renderer/LayerRenderer.java +++ b/vtm/src/org/oscim/renderer/LayerRenderer.java @@ -37,7 +37,7 @@ public abstract class LayerRenderer { /** * Set 'ready for render' state when layer data is ready for rendering. * - * @param true if render() should be called, false otherwise. + * @param ready true if render() should be called, false otherwise. */ protected void setReady(boolean ready) { isReady = ready; diff --git a/vtm/src/org/oscim/theme/RenderThemeHandler.java b/vtm/src/org/oscim/theme/RenderThemeHandler.java index f37ae653..bd665d1f 100644 --- a/vtm/src/org/oscim/theme/RenderThemeHandler.java +++ b/vtm/src/org/oscim/theme/RenderThemeHandler.java @@ -23,8 +23,6 @@ import java.util.ArrayList; import java.util.HashMap; import java.util.Stack; -import javax.xml.parsers.ParserConfigurationException; - import org.oscim.backend.CanvasAdapter; import org.oscim.backend.XMLReaderAdapter; import org.oscim.backend.canvas.Bitmap; @@ -84,8 +82,6 @@ public class RenderThemeHandler extends DefaultHandler { * the input stream. * @throws SAXException * if an error occurs while parsing the render theme XML. - * @throws ParserConfigurationException - * if an error occurs while creating the XML parser. * @throws IOException * if an I/O error occurs while reading from the input stream. */ diff --git a/vtm/src/org/oscim/tiling/TileManager.java b/vtm/src/org/oscim/tiling/TileManager.java index 3721af7e..0a39b6c6 100644 --- a/vtm/src/org/oscim/tiling/TileManager.java +++ b/vtm/src/org/oscim/tiling/TileManager.java @@ -333,9 +333,7 @@ public class TileManager { } /** - * Unlock tiles and clear all item references. - * - * @param tiles + * Unlock TileSet and clear all item references. */ public void releaseTiles(TileSet tileSet) { tileSet.releaseTiles(); @@ -508,7 +506,6 @@ public class TileManager { * * @param tile * Tile ready for upload in TileRenderLayer - * @return caller does not care */ public void jobCompleted(final MapTile tile, final boolean success) { mMap.post(new Runnable() { diff --git a/vtm/src/org/oscim/tiling/source/common/LwHttp.java b/vtm/src/org/oscim/tiling/source/common/LwHttp.java index e0b7a6dc..01d6955c 100644 --- a/vtm/src/org/oscim/tiling/source/common/LwHttp.java +++ b/vtm/src/org/oscim/tiling/source/common/LwHttp.java @@ -67,12 +67,6 @@ public class LwHttp { /** * @param url * Base url for tiles - * @param contentType - * Expected Content-Type - * @param extension - * 'file' extension, usually .png - * @param deflate - * true when content uses gzip compression */ public LwHttp(URL url) { diff --git a/vtm/src/org/oscim/tiling/source/common/UrlTileSource.java b/vtm/src/org/oscim/tiling/source/common/UrlTileSource.java index 956ecc16..3fb7adb8 100644 --- a/vtm/src/org/oscim/tiling/source/common/UrlTileSource.java +++ b/vtm/src/org/oscim/tiling/source/common/UrlTileSource.java @@ -78,9 +78,9 @@ public abstract class UrlTileSource extends TileSource { * override getTileUrl() for custom url formatting using * Strings * - * @param tile Tile - * @param path to write url string - * @param curPos current position + * @param tile the Tile + * @param buf to write url string + * @param pos current position * @return new position */ protected int formatTilePath(Tile tile, byte[] buf, int pos) { diff --git a/vtm/src/org/oscim/utils/LineClipper.java b/vtm/src/org/oscim/utils/LineClipper.java index 422e39bb..2d6cf034 100644 --- a/vtm/src/org/oscim/utils/LineClipper.java +++ b/vtm/src/org/oscim/utils/LineClipper.java @@ -19,8 +19,6 @@ package org.oscim.utils; /** * from http://en.wikipedia.org/wiki/Cohen%E2%80%93 * Sutherland_algorithm - * - * @adapted by Hannes Janetzek */ public class LineClipper { diff --git a/vtm/src/org/oscim/utils/ScanBox.java b/vtm/src/org/oscim/utils/ScanBox.java index bc95956e..821798ac 100644 --- a/vtm/src/org/oscim/utils/ScanBox.java +++ b/vtm/src/org/oscim/utils/ScanBox.java @@ -29,12 +29,10 @@ import org.oscim.core.Tile; *
  * Viewport.getMapViewProjection(box)
  * 	ScanBox sb = new ScanBox(){
- * 		@Override
  *          protected void setVisible(int y, int x1, int x2) {
  *          }
  * 	};
  * sb.scan(pos.x, pos.y, pos.scale, * zoomLevel, coords);
- * 
  * 
* * where zoomLevel is the zoom-level for which tile coordinates should be @@ -60,9 +58,7 @@ public abstract class ScanBox { return mBox; } - /* - * ported from Polymaps: Layer.js - */ + /* ported from Polymaps: Layer.js */ static class Edge { float x0, y0, x1, y1, dx, dy; diff --git a/vtm/src/org/oscim/utils/Tessellator.java b/vtm/src/org/oscim/utils/Tessellator.java index 9f066b07..4adba9ea 100644 --- a/vtm/src/org/oscim/utils/Tessellator.java +++ b/vtm/src/org/oscim/utils/Tessellator.java @@ -32,16 +32,6 @@ public class Tessellator { /** * Special version for ExtrusionLayer to match indices with vertex * positions. - * - * @param points - * @param ppos - * @param plen - * @param index - * @param ipos - * @param rings - * @param vertexOffset - * @param outTris - * @return */ public static int tessellate(float[] points, int ppos, int plen, short[] index, int ipos, int rings, int vertexOffset, VertexItem outTris) { @@ -116,10 +106,6 @@ public class Tessellator { /** * Untested! - * - * @param geom - * @param out - * @return */ public static int tessellate(GeometryBuffer geom, GeometryBuffer out) { @@ -171,15 +157,6 @@ public class Tessellator { return 1; } - /** - * - * @param geom - * @param scale - * @param outPoints - * @param outTris - * @param vertexOffset - * @return - */ public static int tessellate(GeometryBuffer geom, float scale, VertexItem outPoints, VertexItem outTris, int vertexOffset) { diff --git a/vtm/src/org/oscim/utils/async/AsyncExecutor.java b/vtm/src/org/oscim/utils/async/AsyncExecutor.java index a3344833..e3373051 100644 --- a/vtm/src/org/oscim/utils/async/AsyncExecutor.java +++ b/vtm/src/org/oscim/utils/async/AsyncExecutor.java @@ -42,7 +42,7 @@ public class AsyncExecutor { * Creates a new AsynchExecutor that allows maxConcurrent {@link Runnable} * instances to run in parallel. * - * @param maxConcurrent + * @param maxConcurrent number of threads. */ public AsyncExecutor(int maxConcurrent) { executor = Executors.newFixedThreadPool(maxConcurrent, new ThreadFactory() { diff --git a/vtm/src/org/oscim/utils/async/AsyncResult.java b/vtm/src/org/oscim/utils/async/AsyncResult.java index fa7cc0fb..210d2003 100644 --- a/vtm/src/org/oscim/utils/async/AsyncResult.java +++ b/vtm/src/org/oscim/utils/async/AsyncResult.java @@ -40,7 +40,7 @@ public class AsyncResult { /** * @return waits if necessary for the computation to complete and then * returns the result - * @throws GdxRuntimeException if there was an error + * @throws RuntimeException if there was an error */ public T get() { try {