PARP Research Group University of Murcia, Spain


src/qvcore/qvpropertycontainerchange.cpp

Go to the documentation of this file.
00001 /*
00002  *      Copyright (C) 2007, 2008. PARP Research Group.
00003  *      <http://perception.inf.um.es>
00004  *      University of Murcia, Spain.
00005  *
00006  *      This file is part of the QVision library.
00007  *
00008  *      QVision is free software: you can redistribute it and/or modify
00009  *      it under the terms of the GNU Lesser General Public License as
00010  *      published by the Free Software Foundation, version 3 of the License.
00011  *
00012  *      QVision is distributed in the hope that it will be useful,
00013  *      but WITHOUT ANY WARRANTY; without even the implied warranty of
00014  *      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00015  *      GNU Lesser General Public License for more details.
00016  *
00017  *      You should have received a copy of the GNU Lesser General Public
00018  *      License along with QVision. If not, see <http://www.gnu.org/licenses/>.
00019  */
00020 
00024 
00025 #include <QVPropertyContainerChange>
00026 
00027 
00028 QString QVPropertyContainerChange::toString() const
00029 {
00030         QString result("Change emited from ");
00031         result+= sourceName;
00032         result += ", of type ";
00033 
00034         switch (changeType) {
00035         case Name:
00036                 result += "Name";
00037                 break;
00038 //      case ContainerAdd:
00039 //              result += "ContainerAdd";
00040 //              break;
00041         case ContainerDel:
00042                 result += "ContainerDel";
00043                 break;
00044         case PropertyAdd:
00045                 result += "PropertyAdd: ";
00046                 result += propName;
00047                 break;
00048         case PropertyDel:
00049                 result += "PropertyDel: ";
00050                 result += propName;
00051                 break;
00052         case PropertyValue:
00053                 result += "PropertyValue: ";
00054                 result += propName;
00055                 result += ". New value = ";
00056                 result += value.toString();
00057                 break;
00058         case PropertiesValues:
00059                 result += "PropertiesValues";
00060                 break;
00061         case LinkAdd:
00062                 result += "LinkAdd: ";
00063                 result += origName;
00064                 result += "[";
00065                 result += propName;
00066                 result += "] => ";
00067                 result += destName;
00068                 result += "[";
00069                 result += destPropName;
00070                 result += "]";
00071                 break;
00072         case LinkDel:
00073                 result += "LinkDel: ";
00074                 result += origName;
00075                 result += "[";
00076                 result += propName;
00077                 result += "] => ";
00078                 result += destName;
00079                 result += "[";
00080                 result += destPropName;
00081                 result += "]";
00082                 break;
00083         case All:
00084                 result += "All";
00085                 break;
00086         default:
00087                 result += "None";
00088                 break;
00089         }
00090         result += ".";
00091 
00092         return result;
00093 }
00094 



QVision framework. PARP research group, copyright 2007, 2008.