Changeset 49:9a556af88710 in lemon-main for lemon/dim2.h
- Timestamp:
- 01/08/08 02:53:42 (17 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
lemon/dim2.h
r42 r49 28 28 /// 29 29 /// The class \ref lemon::dim2::Point "dim2::Point" implements 30 ///a two dimensional vector with the usual 31 /// operations. 30 /// a two dimensional vector with the usual operations. 32 31 /// 33 32 /// The class \ref lemon::dim2::BoundingBox "dim2::BoundingBox" … … 50 49 51 50 /// A simple two dimensional vector (plainvector) implementation 52 ///with the usual vector 53 /// operators. 54 /// 51 /// with the usual vector operations. 55 52 template<typename T> 56 53 class Point { … … 71 68 Point(T a, T b) : x(a), y(b) { } 72 69 73 /// The dimension of the vector.70 ///Returns the dimension of the vector (i.e. returns 2). 74 71 75 72 ///The dimension of the vector. … … 97 94 } 98 95 99 ///Increment the left hand side by u96 ///Increment the left hand side by \c u 100 97 Point<T>& operator +=(const Point<T>& u) { 101 98 x += u.x; … … 104 101 } 105 102 106 ///Decrement the left hand side by u103 ///Decrement the left hand side by \c u 107 104 Point<T>& operator -=(const Point<T>& u) { 108 105 x -= u.x; … … 316 313 ///if at least one point was added to the box or the coordinates of 317 314 ///the box were set). 315 /// 318 316 ///The coordinates of an empty bounding box are not defined. 319 317 bool empty() const { … … 326 324 } 327 325 328 ///Give back the bottom left corner 329 330 ///Give back the bottom left corner .326 ///Give back the bottom left corner of the box 327 328 ///Give back the bottom left corner of the box. 331 329 ///If the bounding box is empty, then the return value is not defined. 332 330 Point<T> bottomLeft() const { … … 334 332 } 335 333 336 ///Set the bottom left corner 337 338 ///Set the bottom left corner .334 ///Set the bottom left corner of the box 335 336 ///Set the bottom left corner of the box. 339 337 ///It should only be used for non-empty box. 340 338 void bottomLeft(Point<T> p) { … … 342 340 } 343 341 344 ///Give back the top right corner 345 346 ///Give back the top right corner .342 ///Give back the top right corner of the box 343 344 ///Give back the top right corner of the box. 347 345 ///If the bounding box is empty, then the return value is not defined. 348 346 Point<T> topRight() const { … … 350 348 } 351 349 352 ///Set the top right corner 353 354 ///Set the top right corner .350 ///Set the top right corner of the box 351 352 ///Set the top right corner of the box. 355 353 ///It should only be used for non-empty box. 356 354 void topRight(Point<T> p) { … … 358 356 } 359 357 360 ///Give back the bottom right corner 361 362 ///Give back the bottom right corner .358 ///Give back the bottom right corner of the box 359 360 ///Give back the bottom right corner of the box. 363 361 ///If the bounding box is empty, then the return value is not defined. 364 362 Point<T> bottomRight() const { … … 366 364 } 367 365 368 ///Set the bottom right corner 369 370 ///Set the bottom right corner .366 ///Set the bottom right corner of the box 367 368 ///Set the bottom right corner of the box. 371 369 ///It should only be used for non-empty box. 372 370 void bottomRight(Point<T> p) { … … 375 373 } 376 374 377 ///Give back the top left corner 378 379 ///Give back the top left corner .375 ///Give back the top left corner of the box 376 377 ///Give back the top left corner of the box. 380 378 ///If the bounding box is empty, then the return value is not defined. 381 379 Point<T> topLeft() const { … … 383 381 } 384 382 385 ///Set the top left corner 386 387 ///Set the top left corner .383 ///Set the top left corner of the box 384 385 ///Set the top left corner of the box. 388 386 ///It should only be used for non-empty box. 389 387 void topLeft(Point<T> p) { … … 534 532 535 533 536 ///Map of x-coordinates of a Pointmap537 538 ///\ingroup maps 539 ///Map of x-coordinates of a \ref dim2::Point "Point"-map.534 ///Map of x-coordinates of a \ref Point "Point"-map 535 536 ///\ingroup maps 537 ///Map of x-coordinates of a \ref Point "Point"-map. 540 538 /// 541 539 template<class M> … … 571 569 } 572 570 573 ///Constant (read only) version of XMap571 ///Constant (read only) version of \ref XMap 574 572 575 573 ///\ingroup maps … … 601 599 } 602 600 603 ///Map of y-coordinates of a Pointmap601 ///Map of y-coordinates of a \ref Point "Point"-map 604 602 605 603 ///\ingroup maps … … 638 636 } 639 637 640 ///Constant (read only) version of YMap638 ///Constant (read only) version of \ref YMap 641 639 642 640 ///\ingroup maps … … 669 667 670 668 671 ///\brief Map of the normSquare() 672 ///of a Point map 673 /// 674 ///Map of the \ref Point::normSquare() "normSquare()" 675 ///of a \ref Point "Point"-map. 676 ///\ingroup maps 677 /// 669 ///\brief Map of the \ref Point::normSquare() "normSquare()" 670 ///of a \ref Point "Point"-map 671 /// 672 ///Map of the \ref Point::normSquare() "normSquare()" 673 ///of a \ref Point "Point"-map. 674 ///\ingroup maps 678 675 template<class M> 679 676 class NormSquareMap
Note: See TracChangeset
for help on using the changeset viewer.