コード例 #1
0
 private void getBoxModuleProperties(IBoxModule boxModule)
 {
     Debug.WriteLine("enterint test get properties ...");
     PropertyInfo[] properties = boxModule.MadeInCreator.Properties;
     foreach (PropertyInfo property in properties)
     {
         string propertyName = property.name;
         Debug.WriteLine("try to get property " + propertyName);
         switch (property.typeClassIceId)
         {
             case "::Ferda::Modules::BoolT":
                 boxModule.GetPropertyBool(propertyName);
                 break;
             case "::Ferda::Modules::DateT":
                 boxModule.GetPropertyDate(propertyName);
                 break;
             case "::Ferda::Modules::DateTimeT":
                 boxModule.GetPropertyDateTime(propertyName);
                 break;
             case "::Ferda::Modules::DoubleT":
                 boxModule.GetPropertyDouble(propertyName);
                 break;
             case "::Ferda::Modules::FloatT":
                 boxModule.GetPropertyFloat(propertyName);
                 break;
             case "::Ferda::Modules::IntT":
                 boxModule.GetPropertyInt(propertyName);
                 break;
             case "::Ferda::Modules::LongT":
                 boxModule.GetPropertyLong(propertyName);
                 break;
             case "::Ferda::Modules::ShortT":
                 boxModule.GetPropertyShort(propertyName);
                 break;
             case "::Ferda::Modules::StringT":
                 boxModule.GetPropertyString(propertyName);
                 if (property.selectBoxParams != null && property.selectBoxParams.Length > 0)
                     boxModule.GetPropertyOptions(propertyName);
                 break;
             case "::Ferda::Modules::TimeT":
                 boxModule.GetPropertyTime(propertyName);
                 break;
             case "::Ferda::Modules::OtherT":
                 //TODO
                 break;
         }
     }
     Debug.WriteLine("leaving test get properties ...");
 }