Changeset 957 for XIOS/trunk/src/node/file.cpp
- Timestamp:
- 09/30/16 15:28:05 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
XIOS/trunk/src/node/file.cpp
r952 r957 26 26 , allDomainEmpty(false), isOpen(false) 27 27 { 28 setVirtualFieldGroup( );29 setVirtualVariableGroup( );28 setVirtualFieldGroup(CFieldGroup::create(getId() + "_virtual_field_group")); 29 setVirtualVariableGroup(CVariableGroup::create(getId() + "_virtual_variable_group")); 30 30 } 31 31 … … 35 35 , allDomainEmpty(false), isOpen(false) 36 36 { 37 setVirtualFieldGroup( );38 setVirtualVariableGroup( );37 setVirtualFieldGroup(CFieldGroup::create(getId() + "_virtual_field_group")); 38 setVirtualVariableGroup(CVariableGroup::create(getId() + "_virtual_variable_group")); 39 39 } 40 40 … … 187 187 { 188 188 this->vVariableGroup = newVVariableGroup; 189 }190 191 //----------------------------------------------------------------192 //! Create virtual field group, which is done normally on initializing file193 void CFile::setVirtualFieldGroup(void)194 {195 this->setVirtualFieldGroup(CFieldGroup::create());196 }197 198 //! Create virtual variable group, which is done normally on initializing file199 void CFile::setVirtualVariableGroup(void)200 {201 this->setVirtualVariableGroup(CVariableGroup::create());202 189 } 203 190 … … 944 931 void CFile::sendAddAllVariables() 945 932 { 946 if (!getAllVariables().empty()) 933 std::vector<CVariable*> allVar = getAllVariables(); 934 std::vector<CVariable*>::const_iterator it = allVar.begin(); 935 std::vector<CVariable*>::const_iterator itE = allVar.end(); 936 937 for (; it != itE; ++it) 947 938 { 948 // Firstly, it's necessary to add virtual variable group 949 sendAddVariableGroup(getVirtualVariableGroup()->getId()); 950 951 // Okie, now we can add to this variable group 952 std::vector<CVariable*> allVar = getAllVariables(); 953 std::vector<CVariable*>::const_iterator it = allVar.begin(); 954 std::vector<CVariable*>::const_iterator itE = allVar.end(); 955 956 for (; it != itE; ++it) 957 { 958 this->sendAddVariable((*it)->getId()); 959 (*it)->sendAllAttributesToServer(); 960 (*it)->sendValue(); 961 } 939 this->sendAddVariable((*it)->getId()); 940 (*it)->sendAllAttributesToServer(); 941 (*it)->sendValue(); 962 942 } 963 943 }
Note: See TracChangeset
for help on using the changeset viewer.