Example #1
0
        public RelationModel(PayolaContext db)
            : base(db)
        {
            foreach (RelationType relationType in Db.RelationTypes)
            {
                AddGenericRelationType(relationType);

                // If the relation type is symmetric, it represents both the relations and inverse relations. Otherwise
                // the inverse relation type is different from the realtion type so it has to be added.
                if (!relationType.IsSymmetric)
                {
                    AddGenericRelationType(relationType.InverseRelationType);
                }
            }
        }
Example #2
0
        public RelationModel(PayolaContext db)
            : base(db)
        {
            foreach (RelationType relationType in Db.RelationTypes)
            {
                AddGenericRelationType (relationType);

                // If the relation type is symmetric, it represents both the relations and inverse relations. Otherwise
                // the inverse relation type is different from the realtion type so it has to be added.
                if (!relationType.IsSymmetric)
                {
                    AddGenericRelationType (relationType.InverseRelationType);
                }
            }
        }
Example #3
0
 public VehicleModel(PayolaContext db)
     : base(db)
 {
     // NOOP
 }
Example #4
0
 public StbDivisionModel(PayolaContext db)
     : base(db)
 {
     // NOOP
 }
Example #5
0
 public InformationModel(PayolaContext db)
     : base(db)
 {
     // NOOP
 }
Example #6
0
 public EmailModel(PayolaContext db)
     : base(db)
 {
     // NOOP
 }
Example #7
0
 public IncidentModel(PayolaContext db)
     : base(db)
 {
     // NOOP
 }
 public InformativeEntityModel(PayolaContext db)
     : base(db)
 {
     // NOOP
 }
Example #9
0
 /// <summary>
 ///     Initializes database connection.
 /// </summary>
 private static void InitializeDatabaseConnection()
 {
     Database.SetInitializer<PayolaContext> (new PayolaContextInitializer ());
     _dbCtx = new PayolaContext ();
 }
Example #10
0
 public PersonModel(PayolaContext db)
     : base(db)
 {
     // NOOP
 }
Example #11
0
 /// <summary>
 ///     The only constructor.
 /// </summary>
 /// <param name="path">String identifying the resource from which to scrape (local path, URL, ...).</param>
 public ScraperBase(PayolaContext ctx, string path)
 {
     _ctx = ctx;
     _path = path;
 }
Example #12
0
 public LinkScraper(PayolaContext ctx, string path)
     : base(ctx, path)
 {
 }
Example #13
0
        public IEntityModel GetEntityModel(Type entityType, PayolaContext db)
        {
            Type modelType = Type.GetType(typeof(EntityModel <>).Namespace + "." + entityType.Name + "Model");

            return((IEntityModel)GetModel(modelType, db));
        }
Example #14
0
 public ModelBase GetModel(Type modelType, PayolaContext db)
 {
     return((ModelBase)modelType.GetConstructor(new Type[] { typeof(PayolaContext) }).Invoke(new object[] { db }));
 }
Example #15
0
 public TModel GetModel <TModel> (PayolaContext db)
     where TModel : ModelBase
 {
     return((TModel)GetModel(typeof(TModel), db));
 }
Example #16
0
 public EntityModel(PayolaContext db)
     : base(db)
 {
     // NOOP
 }
Example #17
0
 public CompanyModel(PayolaContext db)
     : base(db)
 {
     // NOOP
 }
Example #18
0
 public KeywordModel(PayolaContext db)
     : base(db)
 {
     // NOOP
 }
Example #19
0
 public ReportModel(PayolaContext db)
     : base(db)
 {
     // NOOP
 }
Example #20
0
 public AddressModel(PayolaContext db)
     : base(db)
 {
     // NOOP
 }
Example #21
0
 public PhoneModel(PayolaContext db)
     : base(db)
 {
     // NOOP
 }
Example #22
0
 public DirectoryScraper(PayolaContext ctx, string path)
     : base(ctx, path)
 {
 }