public FixString ( string DirtyString ) : string | ||
DirtyString | string | |
Résultat | string |
public void Save() { if (this.ID == "") { this.ID = db.GetNewID("images"); db.ExecuteCommand("insert into images (img_id, img_glyph_id, img_path, img_status) values (" + this.ID + ", " + this.GlyphID + ", '" + db.FixString(this.Path) + "', '" + db.FixString(this.Status) + "')"); } else { db.ExecuteCommand("update images set img_glyph_id = " + this.GlyphID + ", " + "img_path = '" + db.FixString(this.Path) + "', " + "img_status = '" + db.FixString(this.Status) + "' " + "where img_id = " + this.ID); } }
public void Save(bool IncludeChildren) { if (this.ID == "") { this.ID = db.GetNewID("glyphs"); db.ExecuteCommand("insert into glyphs (glyph_id, glyph_font_id, glyph_unicode, glyph_frequency, glyph_x_offset, glyph_y_offset) values (" + this.ID + ", " + this.FontID + ", '" + db.FixString(this.Unicode) + "', " + this.Frequency + ", " + this.XOffset + ", " + this.YOffset + ")"); } else { db.ExecuteCommand("update glyphs set glyph_font_id = " + this.FontID + ", " + "glyph_unicode = '" + db.FixString(this.Unicode) + "', " + "glyph_frequency = " + this.Frequency + ", " + "glyph_x_offset = " + this.XOffset + ", " + "glyph_y_offset = " + this.YOffset + " " + "where glyph_id = " + this.ID); if (this.Images != null && IncludeChildren) { for (int x = 0; x < this.Images.Count; x++) { this.Images[x].Save(); } } } }
public void Save(bool IncludeChildren) { if (this.ID == "") { this.ID = db.GetNewID("fonts"); db.ExecuteCommand("insert into fonts (font_id, font_lang_id, font_name, font_italic, font_bold, font_fixed, font_serif, font_fraktur, font_line_height) values (" + this.ID + ", " + this.LangID + ", '" + db.FixString(this.Name) + "', " + this.Italic + ", " + this.Bold + ", " + this.Fixed + ", " + this.Serif + ", " + this.Fraktur + ", " + this.LineHeight + ")"); } else { db.ExecuteCommand("update fonts set font_name = '" + db.FixString(this.Name) + "', " + "font_lang_id = " + this.LangID + ", " + "font_italic = " + this.Italic + ", " + "font_bold = " + this.Bold + ", " + "font_fixed = " + this.Fixed + ", " + "font_serif = " + this.Serif + ", " + "font_fraktur = " + this.Fraktur + ", " + "font_line_height = " + this.LineHeight + " " + "where font_id = " + this.ID); if (this.Glyphs != null && IncludeChildren) { for (int x = 0; x < this.Glyphs.Count; x++) { this.Glyphs[x].Save(IncludeChildren); } } } }
public void Save() { if (ID == "") { ID = db.GetNewID("languages"); db.ExecuteCommand("insert into languages (lang_id, lang_name) values (" + this.ID + ", '" + db.FixString(this.Name) + "')"); } else { db.ExecuteCommand("update languages set lang_name = '" + db.FixString(this.Name) + "' where lang_id = " + this.ID); } }