Esempio n. 1
0
        public UInt32 GetSortKey(byte[] rec, byte[] SortKey, Int32 maxlen)
        {
            //const char* fr = rec + offset;
            byte[] fr = new byte[rec.Length];
            Array.Copy(rec, Offset, fr, 0, rec.Length);

            if (Null_exists)
            {
                if (fr[0] == 0)
                {
                    //*(SortKey++) = 0;
                    //SortKey[1] = 0;
                    //memcpy(SortKey, (void*)null_index, len);
                    Array.Copy(Null_index, 0, SortKey, 0, Len);
                    return(0);
                }
                //*(SortKey++) = 1;
                SortKey[1] = 1; // Пока не очень понятно чем заменить

                //fr++;
                // пока не очень понятно чем заменить
            }

            try
            {
                return(Type_manager.GetSortKey(fr, SortKey, maxlen));
            }
            catch
            {
                throw new Exception($"Таблица {Parent.Name}, поле {Name}");
            }
        }
Esempio n. 2
0
 public String Get_XML_presentation(byte[] rec, bool ignore_showGUID = false)
 {
     //const char* fr = rec + offset;
     byte[] fr = new byte[rec.Length];
     Array.Copy(rec, Offset, fr, 0, rec.Length);
     if (Null_exists)
     {
         if (fr[0] == 0)
         {
             return("");
         }
         //fr++; // пока не очень понятно что с этим делать
     }
     byte[] fr_char = new byte[fr.Length];
     return(Type_manager.Get_XML_presentation(fr_char, Parent, ignore_showGUID));
 }
Esempio n. 3
0
        public bool Get_binary_value(byte[] binary_value, bool NULL, String value)
        {
            //memset(binary_value, 0, len);
            Array.Clear(binary_value, 0, Len);

            if (Null_exists)
            {
                if (NULL)
                {
                    return(true);
                }
                //*binary_value = 1;
                binary_value[0] = 1;
                //binary_value++; // пока не очень понятно что с этим делать
            }
            return(Type_manager.Get_binary_value(binary_value, value));
        }
Esempio n. 4
0
 public TypeFields Gettype()
 {
     return(Type_manager.Gettype());
 }
Esempio n. 5
0
 /// <summary>
 /// возвращает длину поля в байтах
 /// </summary>
 /// <returns></returns>
 public Int32 GetLen()
 {
     return((Null_exists ? 1 : 0) + Type_manager.Getlen());
 }
Esempio n. 6
0
 public String Get_presentation_type()
 {
     return(Type_manager.Get_presentation_type());
 }
Esempio n. 7
0
 public bool Getcase_sensitive()
 {
     return(Type_manager.Getcase_sensitive());
 }
Esempio n. 8
0
 public Int32 Getprecision()
 {
     return(Type_manager.Getprecision());
 }
Esempio n. 9
0
 public Int32 Getlength()
 {
     return(Type_manager.Getlength());
 }