コード例 #1
0
 public virtual void makeValue()
 {
     //
     // Setup the object to store a scalar value
     //
     o_error = sinter_IOError.si_OKAY;
     if (o_type == sinter_IOType.si_DOUBLE)
     {
         o_value   = Convert.ToDouble(0.0);
         o_max     = Convert.ToDouble(0.0);
         o_min     = Convert.ToDouble(0.0);
         o_default = Convert.ToDouble(0.0);
     }
     else if (o_type == sinter_IOType.si_INTEGER)
     {
         o_value   = Convert.ToInt32(0);
         o_max     = Convert.ToInt32(0);
         o_min     = Convert.ToInt32(0);
         o_default = Convert.ToInt32(0);
     }
     else if (o_type == sinter_IOType.si_STRING)
     {
         o_value   = "";
         o_max     = "";
         o_min     = "";
         o_default = "";
     }
     else
     {
         o_error = sinter_IOError.si_NOT_SCALAR;
     }
 }
コード例 #2
0
        //----------------------------------
        //Constuctor
        //----------------------------------

        public sinter_Variable()
            : base()
        {
            // the constructor method
            // set some typlical defaults
            o_error        = sinter_IOError.si_OKAY;
            o_mode         = sinter_IOMode.si_IN;
            o_type         = sinter_IOType.si_DOUBLE;
            o_units        = null;
            o_defaultUnits = null;
        }
コード例 #3
0
 public void clearErr()
 {
     o_error = sinter_IOError.si_OKAY;
 }