/// <summary> /// Save a template to a file /// </summary> /// <param name="filename">the name of the template file</param> /// <param name="style">the instance to be saved</param> public static void ExportTemplate(string filename, NFOStyle style) { try { SerializationUtil.BinarySerialize(filename, style); } catch (Exception e) { throw new Exception("[Export Template Error]: Error when saving template ' " + filename + " '", e); } }
/// <summary> /// Load a template from a file /// </summary> /// <param name="filename">the name of the template file</param> /// <returns>loaded instance</returns> public static NFOStyle ImportTemplate(string filename) { NFOStyle ns = null; try { ns = (NFOStyle)SerializationUtil.BinaryDerialize(filename); return(ns); } catch (Exception e) { throw new Exception("[Import Template Error]: Error when loading template ' " + filename + " '", e); } }
public NFODocument(NFOInfo nfoInfo, NFOStyle nfoStyle) { this.nfoInfo = nfoInfo; this.nfoStyle = nfoStyle; }
public NFOTemplate(NFOInfo nfoInfo, NFOStyle nfoStyle) { this.nfoInfo = nfoInfo; this.nfoStyle = nfoStyle; }