public MasterForm() { _image = null; _attributes = new FormRecognitionAttributes(); _properties = FormRecognitionProperties.Empty; _processingPages = null; }
public MasterForm(string name) { _image = null; _attributes = new FormRecognitionAttributes(); _properties = new FormRecognitionProperties(); _properties.Name = name; _processingPages = null; _isDirty = false; }
public MasterForm(string name, RasterImage image, FormRecognitionAttributes attr, FormRecognitionEngine engine) { _image = image; _attributes = attr; attr.Image = Image; _properties = engine.GetFormProperties(attr); _properties.Name = name; _processingPages = null; _isDirty = false; }
public MasterFormProperties(FormRecognitionProperties masterFormProps, string workingDir) { InitializeComponent(); this.Text = "\"" + masterFormProps.Name + "\"" + DemosGlobalization.GetResxString(GetType(), "Resx_Properties"); _txtName.Text = masterFormProps.Name; _txtCreated.Text = masterFormProps.CreationTime.ToLongDateString(); _txtModified.Text = masterFormProps.LastModificationTime.ToLongDateString(); _txtAccessed.Text = masterFormProps.LastAccessTime.ToLongDateString(); string fName = Path.Combine(workingDir, masterFormProps.Name + ".bin"); _txtFormAttributes.Text = fName; fName = Path.Combine(workingDir, masterFormProps.Name + ".xml"); _txtFields.Text = File.Exists(fName) ? fName : "NA"; fName = Path.Combine(workingDir, masterFormProps.Name + ".tif"); _txtImage.Text = File.Exists(fName) ? fName : "NA"; }
public IMasterForm AddMasterForm(FormRecognitionAttributes attributes, FormPages fields, Uri url) { if (attributes == null) { throw new ArgumentException(string.Format("Master Form attributes should be available"), "attributes"); } // Create the file(s) FormRecognitionProperties properties = _recognitionEngine.GetFormProperties(attributes); DiskMasterFormExample masterForm = new DiskMasterFormExample(_repository, properties.Name, System.IO.Path.Combine(_path, properties.Name), this); // Create the file masterForm.WriteAttributes(attributes); if (fields != null) { masterForm.WriteFields(fields); } if (url != null) { masterForm.WriteForm(_repository.RasterCodecsInstance.Load(url, 1, CodecsLoadByteOrder.Bgr, 1, -1)); } _masterForms.AddMasterForm(masterForm); return(masterForm); }