Exemplo n.º 1
0
        public void ReadXml(XmlReader reader)
        {
            try
            {
                if (reader.Name.Equals("CustomConfig"))
                {
                    string strType = reader.GetAttribute("type");
                    Type   type    = LoadType(strType);
                    if (type != null)
                    {
                        while (true)
                        {
                            if (reader.Name.Equals(type.Name))
                            {
                                XmlSerializer serializer = new XmlSerializer(type);
                                CustomConfig = (ICustomConfig)serializer.Deserialize(reader);
                            }

                            if (reader.Name.Equals("CustomConfig") && !reader.IsStartElement())
                            {
                                reader.Read();
                                break;
                            }
                            reader.Read();
                        }
                    }
                }
            } catch (Exception e)
            {
                Trace.WriteLine(e.ToString());
            }
        }
Exemplo n.º 2
0
 public NHibernateHelper(ICustomConfig customConfig)
 {
     _customConfig   = customConfig;
     _configuration  = BasicNHibernateConfiguration();
     _sessionFactory = _configuration.BuildSessionFactory();
 }
Exemplo n.º 3
0
 public ArvenaDbContext(ICustomConfig customConfig) : base()
 {
     _customConfig = customConfig;
 }
Exemplo n.º 4
0
 protected BaseDao(ICustomConfig customConfig)
 {
     _customConfig = customConfig;
 }
Exemplo n.º 5
0
 public SklepDao(ICustomConfig customConfig) : base(customConfig)
 {
 }