From: Regina Obe Date: Sun, 3 May 2009 03:16:42 +0000 (+0000) Subject: change commenting style to javadoc style X-Git-Tag: 1.4.0b1~68 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=abf5606427b47ceaee3a3e764b5a74d3d6f1754c;p=postgis change commenting style to javadoc style git-svn-id: http://svn.osgeo.org/postgis/trunk@4057 b70326c6-7e19-0410-871a-916f4a2858ee --- diff --git a/liblwgeom/lwalgorithm.c b/liblwgeom/lwalgorithm.c index dd10e0097..313af85e2 100644 --- a/liblwgeom/lwalgorithm.c +++ b/liblwgeom/lwalgorithm.c @@ -46,13 +46,13 @@ int lw_segment_envelope_intersects(POINT2D p1, POINT2D p2, POINT2D q1, POINT2D q return LW_TRUE; } -/*! -** \brief returns the kind of #CG_SEGMENT_INTERSECTION_TYPE behavior of lineseg 1 (constructed from p1 and p2) and lineseg 2 (constructed from q1 and q2) -** \param p1 start point of first straight linesegment -** \param p2 end point of first straight linesegment -** \param q1 start point of second line segment -** \param q2 end point of second line segment -** \return a #CG_SEGMENT_INTERSECTION_TYPE +/** +** @brief returns the kind of #CG_SEGMENT_INTERSECTION_TYPE behavior of lineseg 1 (constructed from p1 and p2) and lineseg 2 (constructed from q1 and q2) +** @param p1 start point of first straight linesegment +** @param p2 end point of first straight linesegment +** @param q1 start point of second line segment +** @param q2 end point of second line segment +** @return a #CG_SEGMENT_INTERSECTION_TYPE ** Returns one of ** SEG_ERROR = -1, ** SEG_NO_INTERSECTION = 0, @@ -125,11 +125,11 @@ int lw_segment_intersects(POINT2D *p1, POINT2D *p2, POINT2D *q1, POINT2D *q2) } -/*! -** \brief lwline_crossing_direction: returns the kind of #CG_LINE_CROSS_TYPE behavior of 2 linestrings -** \param l1 first line string -** \param l2 second line string -** \return a #CG_LINE_CROSS_TYPE +/** +** @brief lwline_crossing_direction: returns the kind of #CG_LINE_CROSS_TYPE behavior of 2 linestrings +** @param l1 first line string +** @param l2 second line string +** @return a #CG_LINE_CROSS_TYPE ** LINE_NO_CROSS = 0 ** LINE_CROSS_LEFT = -1 ** LINE_CROSS_RIGHT = 1 diff --git a/liblwgeom/lwcollection.c b/liblwgeom/lwcollection.c index 5eb662f9a..867fa98cf 100644 --- a/liblwgeom/lwcollection.c +++ b/liblwgeom/lwcollection.c @@ -137,9 +137,9 @@ lwcollection_getsubgeom(LWCOLLECTION *col, int gnum) return (LWGEOM *)col->geoms[gnum]; } -/*! - * \brief find serialized size of this collection - * \param col #LWCOLLECTION to find serialized size of +/** + * @brief find serialized size of this collection + * @param col #LWCOLLECTION to find serialized size of */ size_t lwcollection_serialize_size(LWCOLLECTION *col) @@ -165,7 +165,7 @@ lwcollection_serialize_size(LWCOLLECTION *col) return size; } -/*! \brief convert an #LWCOLLECTION into its serialized form writing it into +/** @brief convert an #LWCOLLECTION into its serialized form writing it into * the given buffer, and returning number of bytes written into * the given int pointer. */ @@ -239,8 +239,8 @@ lwcollection_compute_box2d_p(LWCOLLECTION *col, BOX2DFLOAT4 *box) return 1; } -/*! - * \brief Clone #LWCOLLECTION object. #POINTARRAY are not copied. +/** + * @brief Clone #LWCOLLECTION object. #POINTARRAY are not copied. * Bbox is cloned if present in input. */ LWCOLLECTION * @@ -266,7 +266,7 @@ lwcollection_clone(const LWCOLLECTION *g) return ret; } -/*! \brief Add 'what' to this to #LWCOLLECTION at position 'where'. +/** @brief Add 'what' to this to #LWCOLLECTION at position 'where'. * where=0 then prepend * where=-1 then append * Returns a GEOMETRYCOLLECTION @@ -330,7 +330,7 @@ lwcollection_segmentize2d(LWCOLLECTION *col, double dist) col->ngeoms, newgeoms); } -/*! \brief check for same geometry composition +/** @brief check for same geometry composition * */ char diff --git a/liblwgeom/ptarray.c b/liblwgeom/ptarray.c index 7e9f642b8..1850f7251 100644 --- a/liblwgeom/ptarray.c +++ b/liblwgeom/ptarray.c @@ -39,7 +39,7 @@ ptarray_construct(char hasz, char hasm, unsigned int npoints) void ptarray_free(POINTARRAY *pa) { - /*! + /** * TODO: \todo Turn this on after retrofitting all calls to lwfree_ in /lwgeom * if( pa->serialized_pointlist ) * lwfree(pa->serialized_pointlist); @@ -69,8 +69,8 @@ ptarray_reverse(POINTARRAY *pa) } -/*! - * \brief calculate the 2d bounding box of a set of points +/** + * @brief calculate the 2d bounding box of a set of points * write result to the provided BOX2DFLOAT4 * Return 0 if bounding box is NULL (empty geom) */ @@ -104,9 +104,9 @@ ptarray_compute_box2d_p(const POINTARRAY *pa, BOX2DFLOAT4 *result) return 1; } -/*! - * \brief Calculate the 2d bounding box of a set of points. - * \return allocated #BOX2DFLOAT4 or NULL (for empty array). +/** + * @brief Calculate the 2d bounding box of a set of points. + * @return allocated #BOX2DFLOAT4 or NULL (for empty array). */ BOX2DFLOAT4 * ptarray_compute_box2d(const POINTARRAY *pa) @@ -138,8 +138,8 @@ ptarray_compute_box2d(const POINTARRAY *pa) return result; } -/*! - * \brief Returns a modified #POINTARRAY so that no segment is +/** + * @brief Returns a modified #POINTARRAY so that no segment is * longer than the given distance (computed using 2d). * * Every input point is kept. @@ -241,8 +241,8 @@ ptarray_same(const POINTARRAY *pa1, const POINTARRAY *pa2) return 1; } -/*! - * \brief Add a point in a pointarray. +/** + * @brief Add a point in a pointarray. * 'where' is the offset (starting at 0) * if 'where' == -1 append is required. */ @@ -299,10 +299,10 @@ ptarray_addPoint(POINTARRAY *pa, uchar *p, size_t pdims, unsigned int where) return ret; } -/*! - * \brief Remove a point from a pointarray. - * \param which - is the offset (starting at 0) - * \return #POINTARRAY is newly allocated +/** + * @brief Remove a point from a pointarray. + * @param which - is the offset (starting at 0) + * @return #POINTARRAY is newly allocated */ POINTARRAY * ptarray_removePoint(POINTARRAY *pa, unsigned int which) @@ -345,8 +345,8 @@ ptarray_removePoint(POINTARRAY *pa, unsigned int which) return ret; } -/*! - * \brief Clone a pointarray +/** + * @brief Clone a pointarray */ POINTARRAY * ptarray_clone(const POINTARRAY *in) @@ -373,9 +373,9 @@ ptarray_isclosed2d(const POINTARRAY *in) return 1; } -/*! - * \brief calculate the #BOX3D bounding box of a set of points - * \return a lwalloced #BOX3D, or NULL on empty array. +/** + * @brief calculate the #BOX3D bounding box of a set of points + * @return a lwalloced #BOX3D, or NULL on empty array. * #zmin / #zmax values are set to #NO_Z_VALUE if not available. */ BOX3D * @@ -392,11 +392,11 @@ ptarray_compute_box3d(const POINTARRAY *pa) return result; } -/*! - * \brief calculate the #BOX3D bounding box of a set of points +/** + * @brief calculate the #BOX3D bounding box of a set of points * zmin/zmax values are set to #NO_Z_VALUE if not available. * write result to the provided #BOX3D - * \return 0 if bounding box is NULL (empty geom) and 1 otherwise + * @return 0 if bounding box is NULL (empty geom) and 1 otherwise */ int ptarray_compute_box3d_p(const POINTARRAY *pa, BOX3D *result) @@ -446,7 +446,7 @@ ptarray_compute_box3d_p(const POINTARRAY *pa, BOX3D *result) return 1; } -/*! +/** * TODO: \todo implement point interpolation */ POINTARRAY * @@ -759,8 +759,8 @@ ptarray_locate_point(POINTARRAY *pa, POINT2D *p) return plen/tlen; } -/*! - * \brief Longitude shift for a pointarray. +/** + * @brief Longitude shift for a pointarray. * Y remains the same * X is converted: * from -180..180 to 0..360 @@ -801,8 +801,8 @@ dynptarray_create(size_t initial_capacity, int dims) return ret; } -/*! - * \brief Add a #POINT4D to the dynamic pointarray. +/** + * @brief Add a #POINT4D to the dynamic pointarray. * * The dynamic pointarray may be of any dimension, only * accepted dimensions will be copied. diff --git a/loader/pgsql2shp.c b/loader/pgsql2shp.c index 9c233cba1..80ba024b4 100644 --- a/loader/pgsql2shp.c +++ b/loader/pgsql2shp.c @@ -105,14 +105,14 @@ static void parse_table(char *spec); static int create_usrquerytable(void); static const char *nullDBFValue(char fieldType); int projFileCreate(const char * pszFilename, char *schema, char *table, char *geo_col_name); -/*! - * \brief Make appropriate formatting of a DBF value based on type. +/** + * @brief Make appropriate formatting of a DBF value based on type. * Might return untouched input or pointer to static private * buffer: use return value right away. */ static const char * goodDBFValue(const char *in, char fieldType); -/*! \brief Binary to hexewkb conversion function */ +/** @brief Binary to hexewkb conversion function */ char *convert_bytes_to_hex(uchar *ewkb, size_t size); @@ -944,8 +944,8 @@ addRecord(PGresult *res, int residx, int row) return 1; } -/*! - * \brief Return allocate memory. Free after use. +/** + * @brief Return allocate memory. Free after use. */ char * getTableOID(char *schema, char *table) @@ -987,8 +987,8 @@ getTableOID(char *schema, char *table) return ret; } -/*! \brief Return geometry type as defined at top file. - * \return -1 on error. +/** @brief Return geometry type as defined at top file. + * @return -1 on error. * 0 on unknown or unsupported geometry type. * Set outtype to 'm' or 'z' depending on input type. */ @@ -1112,12 +1112,12 @@ getGeometryType(char *schema, char *table, char *geo_col_name) } -/*! - * \brief Set global outtype variable to: +/** + * @brief Set global outtype variable to: * 'm' for 3dm input * 'z' for 3dz or 4d input * 's' for 2d - * \return -1 on error, 0 on success. + * @return -1 on error, 0 on success. * Call only on postgis >= 1.0.0 */ int @@ -1203,7 +1203,7 @@ usage(char* me, int status, FILE* out) exit (status); } -/*! \brief Parse command line parameters */ +/** @brief Parse command line parameters */ int parse_commandline(int ARGC, char **ARGV) { @@ -1298,8 +1298,8 @@ get_postgis_major_version(void) return ver; } -/*! - * \brief Initialize shapefile files, main scan query, +/** + * @brief Initialize shapefile files, main scan query, * type array. */ int @@ -1923,8 +1923,8 @@ shapetypename(int num) } } -/*! - * \brief Either get a table (and optionally a schema) +/** + * @brief Either get a table (and optionally a schema) * or a query. * A query starts with a "select" or "SELECT" string. */ @@ -2007,8 +2007,8 @@ nullDBFValue(char fieldType) } } -/*! - * \brief Make appropriate formatting of a DBF value based on type. +/** + * @brief Make appropriate formatting of a DBF value based on type. * Might return untouched input or pointer to static private * buffer: use return value right away. */ @@ -2058,11 +2058,11 @@ char *convert_bytes_to_hex(uchar *ewkb, size_t size) return hexewkb; } -/*! - * \brief Creates ESRI .prj file for this shp output +/** + * @brief Creates ESRI .prj file for this shp output * It looks in the spatial_ref_sys table and outputs the srtext field for this data * If data is a table will use geometry_columns, if a query or view will read SRID from query output. - * \warning Will give warning and not output a .prj file if SRID is -1, Unknown, mixed SRIDS or not found in spatial_ref_sys. The dbf and shp will still be output. + * @warning Will give warning and not output a .prj file if SRID is -1, Unknown, mixed SRIDS or not found in spatial_ref_sys. The dbf and shp will still be output. */ int projFileCreate(const char * pszFilename, char *schema, char *table, char *geo_col_name) { diff --git a/loader/shp2pgsql.c b/loader/shp2pgsql.c index e20a3f221..594d3edff 100644 --- a/loader/shp2pgsql.c +++ b/loader/shp2pgsql.c @@ -10,7 +10,7 @@ * / - /*! ********************************************************************* + /** ********************************************************************* * \file Using shapelib 1.2.8, this program reads in shape files and * processes it's contents into a Insert statements which can be * easily piped into a database frontend. @@ -62,7 +62,7 @@ typedef struct Ring { unsigned int linked; /* number of "next" rings */ } Ring; -/*! \brief Values for null_policy global */ +/** @brief Values for null_policy global */ enum { insert_null, skip_null, @@ -154,8 +154,8 @@ void *safe_malloc(size_t size) #define malloc(x) safe_malloc(x) -/*! - * \brief Escape input string suitable for COPY +/** + * @brief Escape input string suitable for COPY */ char * @@ -273,11 +273,11 @@ escape_insert_string(char *str) -/*! - * \brief PIP(): crossing number test for a point in a polygon +/** + * @brief PIP(): crossing number test for a point in a polygon * input: P = a point, * V[] = vertex points of a polygon V[n+1] with V[n]=V[0] - * \return 0 = outside, 1 = inside + * @return 0 = outside, 1 = inside */ int PIP( Point P, Point* V, int n ) @@ -299,8 +299,8 @@ PIP( Point P, Point* V, int n ) } -/*! - * \brief Insert the attributes from the correct row of dbf file +/** + * @brief Insert the attributes from the correct row of dbf file */ int @@ -391,9 +391,9 @@ Insert_attributes(DBFHandle hDBFHandle, int row) -/*! +/** * main() - * \brief see description at the top of this file + * @brief see description at the top of this file */ int main (int ARGC, char **ARGV) @@ -1071,7 +1071,7 @@ ReleasePolygons(Ring **polys, int npolys) free(polys); } -/*! \brief This function basically deals with the polygon case. */ +/** @brief This function basically deals with the polygon case. */ /* it sorts the polys in order of outer,inner,inner, so that inners */ /* always come after outers they are within */ void @@ -1215,8 +1215,8 @@ InsertPolygon(void) lwfree(lwcollection); } -/*! - * \brief Insert either a POINT or MULTIPOINT into the output stream +/** + * @brief Insert either a POINT or MULTIPOINT into the output stream */ void InsertPoint(void) @@ -1621,7 +1621,7 @@ dump_ring(Ring *ring) void DropTable(char *schema, char *table, char *geom) { - /*!---------------Drop the table-------------------------- + /**---------------Drop the table-------------------------- * TODO: \todo if the table has more then one geometry column * the DROP TABLE call will leave spurious records in * geometry_columns.