private void Merge(DocumentReferenceCollection destination, List <DocumentReference> source)
 {
     if (source != null && destination != null)
     {
         foreach (DocumentReference o in source)
         {
             destination.Add(o);
         }
     }
 }
예제 #2
0
        public string GetOutputDocuments(HttpListenerContext ct, ActionInfo hi)
        {
            var  inputData  = hi.GetParameterList(ct.Request.RawUrl);
            long CustomerId = inputData["customerId"];

            DocumentReferenceCollection drc = new DocumentReferenceCollection();
            DocumentReference           dr  = new DocumentReference();

            dr.CustomerId     = "1";
            dr.DocumentId     = "23";
            dr.ImagePageCount = 1;
            dr.BuyerId        = "3";
            dr.BatchId        = "34";
            dr.DocumentUri    = new Uri("http://localhost:9090/test22.pdf");
            // dr.OutputOperation = OutputOperationType.Export;

            drc.Add(dr);

            return(GetResponseString <DocumentReferenceCollection>(drc, ct));
        }
예제 #3
0
        public string GetOutputDocumentsByCurrentCustomer(HttpListenerContext ct, ActionInfo hi)
        {
            DocumentReferenceCollection drc = new DocumentReferenceCollection();
            DocumentReference           dr  = new DocumentReference();

            dr.CustomerId  = "1";
            dr.DocumentId  = "1";
            dr.BuyerId     = "1";
            dr.DocumentUri = new Uri("File://test.pdf");
            dr.ImageUri    = new Uri("File://Test.jpg");
            DocumentReference dr2 = new DocumentReference();

            dr2.CustomerId  = "2";
            dr2.DocumentId  = "1";
            dr2.BuyerId     = "1";
            dr2.DocumentUri = new Uri("File://test.pdf");
            dr2.ImageUri    = new Uri("File://Test.jpg");
            drc.Add(dr2);

            return(GetResponseString <DocumentReferenceCollection>(drc, ct));
        }
        //--------------------------------------------------------------------
        //
        // Private Methods
        //
        //---------------------------------------------------------------------

        #region Private Methods

        private void _Init()
        {
            _paginator = new FixedDocumentSequencePaginator(this);
            _references = new DocumentReferenceCollection();
            _references.CollectionChanged += new NotifyCollectionChangedEventHandler(_OnCollectionChanged);
            _asyncOps   = new Dictionary<Object,GetPageAsyncRequest>();
            _pendingPages  =  new List<RequestedPage>();
            _pageSize = new Size(8.5d * 96d, 11.0d * 96d);
            this.Initialized += new EventHandler(OnInitialized);
        }