Esempio n. 1
0
 public License(WebDaD.Toolkit.Database.Database db, string tablename, string public_key, string private_key)
 {
     this.id = "";
     this.db = db;
     this.tablename = tablename;
     this.publickey_file = public_key;
     this.privatekey_file = private_key;
     enc = new RSAEncryption();
     enc.LoadPrivateFromXml(private_key);
     enc.LoadPublicFromXml(public_key);
 }
Esempio n. 2
0
 public Template(WebDaD.Toolkit.Database.Database db, string basePath)
 {
     this.db = db;
     this.name = "";
     this.beforeContent = "";
     this.afterContent = "";
     this.textBefore = "|";
     this.header = " | | ";
     this.footer = " | | ";
     this.empty = true;
     this.basePath = basePath + Path.DirectorySeparatorChar + NiceID + Path.DirectorySeparatorChar;
 }
Esempio n. 3
0
 public Template(WebDaD.Toolkit.Database.Database db, string id, string basePath)
 {
     this.db = db;
     WebDaD.Toolkit.Database.Result d = this.db.getRow(Template.table, new string[] { "id", "name", "beforeContent", "afterContent", "textBefore", "header", "footer" }, "`id`='" + id + "'", "", 1);
     this.id = d.FirstRow["id"];
     this.name = d.FirstRow["name"];
     this.beforeContent = d.FirstRow["beforeContent"];
     this.afterContent = d.FirstRow["afterContent"];
     this.textBefore = d.FirstRow["textBefore"];
     this.header = d.FirstRow["header"];
     this.footer = d.FirstRow["footer"];
     this.empty = false;
     this.basePath = basePath + Path.DirectorySeparatorChar + NiceID + Path.DirectorySeparatorChar;
 }