SubjectTo.hpp
Go to the documentation of this file.
00001 /*
00002  *      This file is part of qpOASES.
00003  *
00004  *      qpOASES -- An Implementation of the Online Active Set Strategy.
00005  *      Copyright (C) 2007-2011 by Hans Joachim Ferreau, Andreas Potschka,
00006  *      Christian Kirches et al. All rights reserved.
00007  *
00008  *      qpOASES is free software; you can redistribute it and/or
00009  *      modify it under the terms of the GNU Lesser General Public
00010  *      License as published by the Free Software Foundation; either
00011  *      version 2.1 of the License, or (at your option) any later version.
00012  *
00013  *      qpOASES is distributed in the hope that it will be useful,
00014  *      but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  *      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
00016  *      See the GNU Lesser General Public License for more details.
00017  *
00018  *      You should have received a copy of the GNU Lesser General Public
00019  *      License along with qpOASES; if not, write to the Free Software
00020  *      Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
00021  *
00022  */
00023 
00024 
00036 #ifndef QPOASES_SUBJECTTO_HPP
00037 #define QPOASES_SUBJECTTO_HPP
00038 
00039 
00040 #include <qpOASES/Indexlist.hpp>
00041 
00042 
00043 BEGIN_NAMESPACE_QPOASES
00044 
00045 
00056 class SubjectTo
00057 {
00058         /*
00059          *      PUBLIC MEMBER FUNCTIONS
00060          */
00061         public:
00063                 SubjectTo( );
00064 
00066                 SubjectTo(      int _n                                                          
00067                                         );
00068 
00070                 SubjectTo(      const SubjectTo& rhs                            
00071                                         );
00072 
00074                 virtual ~SubjectTo( );
00075 
00077                 SubjectTo& operator=(   const SubjectTo& rhs    
00078                                                                 );
00079 
00080 
00084                 returnValue init(       int _n = 0                                      
00085                                                         );
00086 
00087 
00090                 inline int getNumberOfType(     SubjectToType _type     
00091                                                                         ) const;
00092 
00093 
00097                 inline SubjectToType getType(   int i                   
00098                                                                                 ) const;
00099 
00103                 inline SubjectToStatus getStatus(       int i           
00104                                                                                         ) const;
00105 
00106 
00110                 inline returnValue setType(     int i,                          
00111                                                                         SubjectToType value     
00112                                                                         );
00113 
00117                 inline returnValue setStatus(   int i,                                  
00118                                                                                 SubjectToStatus value   
00119                                                                                 );
00120 
00121 
00123                 inline void setNoLower( BooleanType _status             
00124                                                                 );
00125 
00127                 inline void setNoUpper( BooleanType _status             
00128                                                                 );
00129 
00130 
00133                 inline BooleanType hasNoLower( ) const;
00134 
00137                 inline BooleanType hasNoUpper( ) const;
00138 
00139 
00151                 virtual returnValue shift(      int offset              
00152                                                                         ) = 0;
00153 
00161                 virtual returnValue rotate(     int offset              
00162                                                                         ) = 0;
00163 
00164 
00165         /*
00166          *      PROTECTED MEMBER FUNCTIONS
00167          */
00168         protected:
00171                 returnValue clear( );
00172                 
00175                 returnValue copy(       const SubjectTo& rhs    
00176                                                         );
00177 
00178 
00183                 returnValue addIndex(   Indexlist* const indexlist,     
00184                                                                 int newnumber,                          
00185                                                                 SubjectToStatus newstatus       
00186                                                                 );
00187 
00192                 returnValue removeIndex(        Indexlist* const indexlist,     
00193                                                                         int removenumber                        
00194                                                                         );
00195 
00200                 returnValue swapIndex(  Indexlist* const indexlist,     
00201                                                                 int number1,                            
00202                                                                 int number2                                     
00203                                                                 );
00204 
00205 
00206         /*
00207          *      PROTECTED MEMBER VARIABLES
00208          */
00209         protected:
00210                 int n;                                          
00212                 SubjectToType* type;            
00213                 SubjectToStatus* status;        
00215                 BooleanType noLower;            
00216                 BooleanType noUpper;            
00217 };
00218 
00219 
00220 END_NAMESPACE_QPOASES
00221 
00222 #include <qpOASES/SubjectTo.ipp>
00223 
00224 #endif  /* QPOASES_SUBJECTTO_HPP */
00225 
00226 
00227 /*
00228  *      end of file
00229  */


acado
Author(s): Milan Vukov, Rien Quirynen
autogenerated on Thu Aug 27 2015 12:00:57