Changeset 927 for library/bdm/base

Show
Ignore:
Timestamp:
05/06/10 17:42:05 (14 years ago)
Author:
smidl
Message:

traffic agents -- pro BDM > r904

Location:
library/bdm/base
Files:
5 modified

Legend:

Unmodified
Added
Removed
  • library/bdm/base/bdmbase.cpp

    r915 r927  
    532532        } 
    533533        if( log_level[logut] ) {  
    534                 bdm_warning("We are sorry, but DS::log_write() is not able to log \"ut\" at the moment, would you be so kind and code this functionality?"); 
     534                // NOT_IMPLEMENTED 
    535535        } 
    536536} 
  • library/bdm/base/bdmbase.h

    r923 r927  
    307307        //! this method adds new id to its proper position and return the name of this position 
    308308        string store_id_and_give_name( enum T::log_level_enums const log_level_enum,  int enum_subindex, int id ) { 
    309                 int ids_len = ids(log_level_enum).length(); 
     309//              int ids_len = ids(log_level_enum).length(); <== compiler suggest to remove 
    310310                if( ids(log_level_enum).length() <= enum_subindex ) 
    311311                        ids(log_level_enum).set_size( enum_subindex+1, true ); 
  • library/bdm/base/datasources.cpp

    r924 r927  
    7373 
    7474        string orientation; 
    75         if( UI::get ( orientation, set, "orientation", UI::optional ) & orientation == "BY_ROW" )  
     75        if( UI::get ( orientation, set, "orientation", UI::optional ) & (orientation == "BY_ROW") )  
    7676                transpose ( Data, Data ); 
    7777} 
  • library/bdm/base/participants.h

    r819 r927  
    5757        virtual void broadcast(Setting& queue){} 
    5858        //! Receive one message from the queue 
    59         virtual void receive(const Setting& msg){} 
     59        virtual void receive(const Setting& msg){ 
     60                bdm_warning("unhandled message"); 
     61        } 
    6062        //! Design control strategy 
    6163        virtual void act(vec &glob_ut){} 
  • library/bdm/base/user_info.h

    r907 r927  
    380380                        from_setting ( array_to_load ( i ), link.result[i] ); 
    381381        } 
    382  
     382/* 
    383383        //! This is dummy version of the from_setting method for other, unsupported types. It just throws an exception. 
    384384        //! 
    385385        //! At the moment, this is the only way how to compile the library without obtaining the compiler error c2665. 
    386386        //! The exception can help to find the place where the template is misused and also to correct it. 
    387 //      template<class T> static void from_setting ( T &variable_to_load, const Setting &element ) { 
    388 //              std::string msg = "UIException: from_setting is not implemented for type "; 
    389 //              try{ 
    390 //                      variable_to_load.from_setting(element); 
    391 /*              } catch (...){ 
    392                 msg += typeid ( T ).name(); 
    393                 msg += '.'; 
    394                 throw UISettingException ( msg, element ); 
    395                 }*/ 
    396 //      } 
    397  
     387        template<class T> static void from_setting ( T &variable_to_load, const Setting &element ) { 
     388                std::string msg = "UIException: from_setting is not implemented for type "; 
     389                try{ 
     390                        variable_to_load.from_setting(element); 
     391                } catch (...){ 
     392                        msg += typeid ( T ).name(); 
     393                        msg += '.'; 
     394                        throw UISettingException ( msg, element ); 
     395                } 
     396        } 
     397*/ 
    398398 
    399399protected: