terralib:exemplo2
Diferenças
Aqui você vê as diferenças entre duas revisões dessa página.
| Ambos lados da revisão anteriorRevisão anteriorPróxima revisão | Revisão anterior | ||
| terralib:exemplo2 [2008/04/02 16:01] – 150.163.3.123 | terralib:exemplo2 [2008/04/16 19:06] (atual) – 150.163.2.103 | ||
|---|---|---|---|
| Linha 1: | Linha 1: | ||
| <code cpp> | <code cpp> | ||
| - | |||
| - | / | ||
| - | Commun header | ||
| - | **********************/ | ||
| - | |||
| - | /*! | ||
| - | \file | ||
| - | \brief | ||
| - | |||
| - | This file can be used as reference for TerraLib programmers. | ||
| - | |||
| - | \author Karine | ||
| - | \author Laércio (laercio@dpi.inpe.br) | ||
| - | */ | ||
| - | |||
| - | |||
| - | #ifndef TE_TEMPLATE_H | ||
| - | #define TE_TEMPLATE_H | ||
| - | |||
| - | #define TE_MY_DEFINE 1 | ||
| - | |||
| - | // C includes | ||
| - | #include <c.h> | ||
| - | |||
| // Local module includes | // Local module includes | ||
| #include " | #include " | ||
| Linha 32: | Linha 8: | ||
| // STL includes | // STL includes | ||
| #include < | #include < | ||
| - | + | ||
| - | // Foward declarations of external classes | + | |
| - | class Foward; | + | |
| - | + | ||
| - | //! TerraLib namespace | + | |
| - | /*! | + | |
| - | This namespace contains all TerraLib kernel definitions. | + | |
| - | */ | + | |
| - | + | ||
| namespace TerraLib | namespace TerraLib | ||
| { | { | ||
| - | // Foward declarations of namespace classes | ||
| - | class TeFoward; | ||
| - | + | TeTemplate:: | |
| - | //! A example of TerraLib programming style | + | { |
| - | /*! | + | |
| - | This class is an example of TerraLib programming style. | + | |
| - | + | void | |
| - | \version | + | |
| - | | + | { |
| - | \sa | + | } |
| - | */ | + | |
| - | class TeTemplate | + | int& |
| - | { | + | TeTemplate:: |
| - | | + | { |
| - | + | } | |
| - | //! Empty contructor | + | |
| - | | + | bool& |
| - | + | | |
| - | //! Set the value of member myInt_ | + | |
| - | /*! | + | } |
| - | \param myInt the value to be assigned to myInt_ member | + | |
| - | */ | + | |
| - | void setMyInt(const int& myInt); | + | |
| - | + | ||
| - | //! Get the value of member myInt_ | + | |
| - | / | + | |
| - | | + | |
| - | */ | + | |
| - | const int& getMyInt(void) | + | |
| - | + | ||
| - | //! Verify if the object is valid | + | |
| - | / | + | |
| - | | + | |
| - | */ | + | |
| - | const bool& | + | |
| - | + | ||
| - | | + | |
| - | + | ||
| - | private: | + | |
| - | + | ||
| - | | + | |
| - | //! My protected int member | + | |
| - | int myProtectedInt_; | + | |
| - | + | ||
| - | | + | |
| - | //! My private int member | + | |
| - | int myInt_; | + | |
| - | //! My private double member | + | |
| - | double myDouble_; | + | |
| - | //! My private string member | + | |
| - | std::string myString_; | + | |
| - | //! My private boolen member | + | |
| - | bool valid_; | + | |
| - | //! My private class pointer member | + | |
| - | TeClass* myClassPointer_; | + | |
| - | }; | + | |
| - | + | ||
| - | } // End namespace TerraLib | + | |
| - | + | ||
| - | # | + | |
| + | } | ||
| </ | </ | ||
terralib/exemplo2.1207152090.txt.gz · Última modificação: 2008/04/02 16:01 por 150.163.3.123
