Exemplo n.º 1
0
        protected override void LoadMap()
        {
            if (_dtMap != null)
            {
                return;
            }

            Debug.Assert(false); // not mapped yet!
            _dtMap = new TwowayMap();
        }
Exemplo n.º 2
0
 static ImageFmtMapper()
 {
     _map = new TwowayMap <ImageFmt, ImageFormat>();
     _map.Add(ImageFmt.Bmp, ImageFormat.Bmp);
     _map.Add(ImageFmt.Emf, ImageFormat.Emf);
     _map.Add(ImageFmt.Exif, ImageFormat.Exif);
     _map.Add(ImageFmt.Gif, ImageFormat.Gif);
     _map.Add(ImageFmt.Icon, ImageFormat.Icon);
     _map.Add(ImageFmt.Jpeg, ImageFormat.Jpeg);
     _map.Add(ImageFmt.Png, ImageFormat.Png);
     _map.Add(ImageFmt.Tiff, ImageFormat.Tiff);
     _map.Add(ImageFmt.Wmf, ImageFormat.Wmf);
 }
Exemplo n.º 3
0
        private void LoadColumnMap()
        {
            if (_colMap != null)
            {
                return;
            }

            _colMap = new TwowayMap <string, int>();
            foreach (DataColumn cl in _dataTbl.Columns)
            {
                _colMap.Add(cl.ColumnName, cl.Ordinal);
            }
        }
Exemplo n.º 4
0
        private void LoadControllers()
        {
            if (_resourceNames != null)
            {
                return;
            }

            string[] resNames = _resourceAssembly.GetManifestResourceNames();
            _resourceNames = new TwowayMap <string, string>();
            int assemblyFullNameLength = (Path.GetFileNameWithoutExtension(_resourceAssembly.ManifestModule.Name)).Length;

            foreach (string res in resNames)
            {
                _resourceNames.Add(res.Substring(assemblyFullNameLength), res);
            }
        }
Exemplo n.º 5
0
        protected override void LoadMap()
        {
            if (_dtMap != null)
            {
                return;
            }

            _dtMap = new TwowayMap();

            _dtMap.Add(DataTypeEnum.Int32, "INT");
            _dtMap.Add(DataTypeEnum.AnsiString, "VARCHAR");
            _dtMap.Add(DataTypeEnum.WideString, "NVARCHAR");
            _dtMap.Add(DataTypeEnum.AnsiCLOB, "TEXT");
            _dtMap.Add(DataTypeEnum.WideCLOB, "NTEXT");
            _dtMap.Add(DataTypeEnum.BLOB, "BINARY");
            _dtMap.Add(DataTypeEnum.Bit, "BIT");
            _dtMap.Add(DataTypeEnum.GUID, "UNIQUEIDENTIFIER");
            _dtMap.Add(DataTypeEnum.DATETIME, "DATETIME");
            _dtMap.Add(DataTypeEnum.NUMERIC, "NUMERIC");
            //_dtMap.Add(DataTypeEnum.MONEY, "MONEY");
        }