PdfSharp.Xps.Rendering.PdfContentWriter.Close C# (CSharp) Méthode

Close() public méthode

Closes the underlying content stream.
public Close ( ) : void
Résultat void
    void Close()
    {
      if (this.page != null)
      {
        PdfContent content = page.RenderContent;
        content.CreateStream(PdfEncoders.RawEncoding.GetBytes(GetContent()));

        //this.gfx = null;
        this.page.RenderContent.pdfRenderer = null;
        this.page.RenderContent = null;
        this.page = null;
      }
      else if (this.form != null)
      {
        this.form.pdfForm.CreateStream(PdfEncoders.RawEncoding.GetBytes(GetContent()));
        this.form.pdfRenderer = null;
        this.form = null;
      }
      else if (this.contentDictionary != null)
      {
        this.contentDictionary.CreateStream(PdfEncoders.RawEncoding.GetBytes(GetContent()));
        this.contentDictionary = null;
      }
      else
        Debug.Assert(false, "Undefined content target.");
    }