OutlineGroup.h

Go to the documentation of this file.
00001 #ifndef __OTULINE_GROUP__
00002 #define __OTULINE_GROUP__
00003 
00004 
00005 //------------------------------------------------------------------------------------------------------------
00006 // Includes
00007 //------------------------------------------------------------------------------------------------------------
00008 #include <iostream>
00009 #include <vector>
00010 
00011 class OutlineGroup{
00012 
00013 //------------------------------------------------------------------------------------------------------------
00014 // Constructors & Destructors
00015 //------------------------------------------------------------------------------------------------------------
00016 public:
00017 
00018         /*
00019         * Constructs an outline group with the given name
00020         * @param theName Is the name for the group
00021         * @param theGroupType Is the type for the group corresponding to one of the constants of this class
00022         */ 
00023         OutlineGroup(std::string theName, int theGroupType);
00024         
00025         /*
00026         * Destroyes the outline and its dependencies
00027         */
00028         ~ OutlineGroup();
00029 
00030 //------------------------------------------------------------------------------------------------------------
00031 // Methods definition
00032 //------------------------------------------------------------------------------------------------------------
00033 
00034         /*
00035         * Indicates if a given name of an outline is member of the group or not
00036         * @param aKeyName Is the name of an outline to search for
00037         */
00038         bool isMemberOfGroup(std::string aKeyName);
00039 
00040         /*
00041         * Removes an outline with the given name from the group 
00042         * @param theNameToRemove Is the name to remove from member name list
00043         * @param allOcurrencies Indicates to errase all ocurrences
00044         */
00045         void removeOutline(std::string theNameToRemove,  bool allOcurrencies = true);
00046         
00047         /*
00048         * Adds an outline with the given name to the group members list
00049         * @param theNameNw Is the name to add to the group
00050         */
00051         void addOutline(std::string theNameNw);
00052 
00053         /*
00054         * Gets the name of the group
00055         * @return name Is the name of the group
00056         */ 
00057         std::string getName();
00058 
00059         /*
00060         * Sets the name of the group as the given one 
00061         * @param name Is the new name of the group
00062         */ 
00063         void setName(std::string theNwName);
00064 
00065         /*
00066         * Gets the state of visiblility (true:visible) or not of the group
00067         * @return visibleGroup Is the corresponding state
00068         */ 
00069         bool getIfVisibleGroup();
00070 
00071         /*
00072         * Sets state of visible (true) or not of the with the given one 
00073         * @param theNwVisiblity Is the corresponding state
00074         */ 
00075         void setIfVisibleGroup(bool theNwVisiblity);
00076 
00077         /*
00078         * Gets the state of static (true:static) or not of the group
00079         * @return staticGroup Is the corresponding state
00080         */ 
00081         bool getIfStaticGroup();
00082 
00083         /*
00084         * Sets state of static (true) or not of the with the given one 
00085         * @param theNwStatic Is the corresponding state
00086         */ 
00087         void setIfStaticGroup(bool theNwStatic);
00088 
00089         /*
00090         * Gets the state of selection (true:selected) or not of the group
00091         * @return selecetedGroup Is the corresponding state
00092         */ 
00093         bool getIfSelectedGroup();
00094 
00095         /*
00096         * Sets state of visible (true) or not of the with the given one 
00097         * @param theNwSelected Is the corresponding state
00098         */ 
00099         void setIfSelectedGroup(bool theNwSelected);
00100 
00101         /*
00102         * Gets the state of edition (true:editing) or not of the group
00103         * @return editingGroup Is the corresponding state
00104         */ 
00105         bool getIfEditingGroup();
00106 
00107         /*
00108         * Sets state of editing (true) or not of the with the given one 
00109         * @param theNwEditing Is the corresponding state
00110         */ 
00111         void setIfEditingGroup(bool theNwEditing);
00112 
00113         /*
00114         * Gets the total count of outlines in the group
00115         * @return totalCount Is the corresponding number of elements
00116         */ 
00117         int getGroupType();
00118 
00119         /*
00120         * Sets the group type 
00121         * @param theType Is the corresponding new type to assign 
00122         */ 
00123         void setGroupType(int theType);
00124 
00125         /*
00126         * Gets the group type 
00127         * @return type Is the corresponding number of elements
00128         */ 
00129         int getOutlinesCount();
00130 
00131         /*
00132         * Sets the total count of outlines in the group
00133         * @param theNwVisiblity Is the corresponding state
00134         */ 
00135         void setIfEditingGroup(int theTotal);
00136 
00137         /*
00138         * Adds an outline to the group as propagation type
00139         * @param theOutlineKeyName Is the name used as identifier of the outline        
00140         */
00141         void addOutline_PropagationType(std::string theOutlineKeyName);
00142 
00143         /*
00144         * Adds an outline to the group as plane section type
00145         * @param theOutlineKeyName Is the name used as identifier of the outline        
00146         */
00147         void addOutline_PlaneSectionType(std::string theOutlineKeyName);
00148 
00149         /*
00150         * Adds an outline to the group as overlaped type
00151         * @param theOutlineKeyName Is the name used as identifier of the outline        
00152         */
00153         void addOutline_OverlapedType(std::string theOutlineKeyName);
00154         
00155         /*
00156         * Adds an outline to the group as strip type
00157         * @param theOutlineKeyName Is the name used as identifier of the outline        
00158         */
00159         void addOutline_StripType(std::string theOutlineKeyName);
00160 
00161         /*
00162         * Adds an outline to the group as manual type
00163         * @param theOutlineKeyName Is the name used as identifier of the outline        
00164         */
00165         void addOutline_ManualType(std::string theOutlineKeyName);
00166 
00167 
00168         /*
00169         * Gets the outlines of the group
00170         * @return Returns the names of the outlines that belong to the group
00171         */
00172          std::vector< std::string >  getGroupOutlinesNames ( );
00173 
00174 //------------------------------------------------------------------------------------------------------------
00175 // Attributes
00176 //------------------------------------------------------------------------------------------------------------
00177 
00178 private:        
00179 
00180         bool acceptsRepetedOutlines;
00181 
00182         /*
00183         * Represents the name of the group
00184         */
00185         std::string name;
00186 
00187         /*
00188         * Represents the state of visible for the outlines in the group
00189         */
00190         bool visibleGroup;
00191 
00192         /*
00193         * Represents the state of selection for the outlines in the group
00194         */
00195         bool selectedGroup;
00196 
00197         /*
00198         * Represents the state of edition for the outlines in the group
00199         */
00200         bool editingGroup;
00201 
00202         /*
00203         * Represents the state of static for the outlines in the group
00204         */
00205         bool staticGroup;
00206 
00207         /*
00208         * Represents the type of the group
00209         */
00210         int groupType;
00211 
00212         /*
00213         * Represents the total elements count of the group
00214         */
00215         int totalCount;
00216 
00217         /*
00218         * Represents the outlines of the group
00219         */
00220         std::vector< std::string > outlines_keyNames;
00221 
00222         //------------------------------------------------------------------------------------------------------------
00223         // Constants
00224         //------------------------------------------------------------------------------------------------------------
00225         
00226 public :
00227         enum
00228                 {
00229                         PROPAGATION = 0,
00230                         PLANE_SECTION = 1,
00231                         OVERLAPED = 2,
00232                         STRIP = 3,              
00233                         MANUAL_GROUP = 4,               
00234                 };
00235                 
00236 
00237 };
00238 #endif

Generated on Wed Jun 27 23:28:33 2012 for creaContours_lib by  doxygen 1.5.7.1