パッケージ、リポジトリ、アプリカテゴリを検索

pdf_merger のカバー
パッケージ詳細v0.0.6

pdf_merger

PDFファイルのリストをマージするための新しいFlutterプラグインです。AndroidおよびiOSの両方をサポートしています。このパッケージを使用する前に、権限とファイルピッカーの許可を確認してください(例を参照)。

AndroidiOS
30日間ダウンロード
325
いいね数
27
Pub ポイント
130

パッケージをインストール

flutter pub add pdf_merger

パッケージ概要

公開情報に基づく選定ガイドです。参考としてご利用ください。

pdf_merger は、Android および iOS プラットフォーム上で複数の PDF ファイルを単一のドキュメントにマージするための Flutter プラグインです。PDF をプログラム的に結合するための簡単な API を提供しており、ドキュメントの統合が必要なアプリケーションに最適です。例に記載されているように、ユーザーはプラグインを使用する前にファイル権限を付与し、ファイルピッカーを統合する必要があります。このパッケージは軽量であり、既存の Flutter プロジェクトとのシームレスな統合を目的としています。

用途

  • ユーザー選択から複数のPDFをマージする
  • レポートまたはフォームを1つのファイルに統合する
  • ドキュメント処理ワークフローをサポートする
  • 共有用に統合されたPDFを作成する
  • アプリケーションでPDFの集約を自動化する
  • オフラインPDF管理を有効にする

主な機能

  • クロスプラットフォーム対応(Android および iOS)
  • シンプルなマージ API
  • ファイルピッカー統合に対応
  • 軽量かつ効率的
  • PDFファイルのリストをサポートしています
  • 明確なドキュメントによる簡単なセットアップ

適している対象

  • ドキュメント管理アプリ
  • 教育ツール
  • ビジネスレポートアプリ
  • フォームおよび提出システム
  • PDF処理ユーティリティ
  • PDFの集約を必要とするモバイルアプリ

注意事項

  • ファイル権限の処理が必要です
  • 外部ファイルピッカーの統合が必要です
  • PDFの編集はできません。マージのみ可能です。
  • 組み込みのプレビュー機能なし
  • 例のコードにおける正しい設定に依存しています
  • 大規模なPDF操作には適していません

元の README

関連するソースリポジトリの README 原文のスナップショットです。最新の内容はリポジトリをご覧ください。

pdf_merger

A new Flutter plugin for merge List of PDF files. It supports both android and IOS. Before call this package make sure you allow permission and file picker see example. Also check file_picker and permission handle to implement before calling the plugin.

PDF merger method

Merge Multiple PDF


  //paths is a list of paths, example List<String> allSelectedFilePath. 
  //outputDirPath is output path with filename, exmaple /user/android/download/ABC.pdf
  
 MergeMultiplePDFResponse response  = await PdfMerger.mergeMultiplePDF(paths: filesPath, outputDirPath: outputDirPath);
 
  if(response.status == "success") {
  //response.response for output path  in String
  //response.message for success message  in String
  }
  
  

Create PDF From Multiple Image


  //paths is a list of paths, example List<String> allSelectedFilePath. 
  //outputDirPath is output path with filename, exmaple /user/android/download/ABC.pdf
  //Optional params maxWidth : defalut set to 360, maxHeight : defalut set to 360, needImageCompressor : default set to true.
  
 CreatePDFFromMultipleImageResponse response  = PdfMerger.createPDFFromMultipleImage(paths: filesPath, outputDirPath: outputDirPath);
 
  if(response.status == "success") {
   //response.response for output path in String
  //response.message for success message  in String
  }
  

Create Image From PDF


  //paths selected file path (String). Example user/android.downlaod/MYPDF.pdf
  //outputDirPath is output path with filename, exmaple /user/android/download/ABC.pdf
 //Optional params maxWidth : defalut set to 360, maxHeight : defalut set to 360, createOneImage : default set to true.
 
 CreateImageFromPDFResponse response  = await PdfMerger.createImageFromPDF(path: singleFile, outputDirPath: outputDirPath);
 
  if(response.status == "success") {
   //response.response for output path in List<String>
  //response.message for success message  in String
  }
  

Get File Size


  //paths selected file path (String). Example user/android.downlaod/MYPDF.pdf
  
 SizeFormPathResponse response  = await PdfMerger.sizeFormPath(path: singleFile);
 
  if(response.status == "success") {
   //response.response for size of file
  //response.message for success message  in String
  }
  

Build Info


 BuildInfoResponse response  = await PdfMerger.buildInfo();
 
 Get.snackbar("Info", "App Name : " + response.appName + "\n" +
            "Build Number : " + response.buildDate + "\n" +
            "Build Number with Time : " + response.buildDateWithTime + "\n" +
            "Package Name : " + response.packageName + "\n" +
            "Version Number : " + response.versionNumber + "\n" +
            "Build Number : " + response.buildNumber.toString() );
  

Android & IOS

ios_1

ios_2

android

Usage

See Example. Use with file picker and add permission handler before calling pdf_merger. Make sure to call permission handler for write permission before call pdf_merger.

file_picker

https://pub.dev/packages/file_picker

permission_handler

https://pub.dev/packages/permission_handler

Support

Android & IOS

For Android

Add these lines in your progaurd

//required to prevent errors from the spongycastle libraries
-keep class org.spongycastle.** { *; }
-dontwarn org.spongycastle.**

For IOS

All set

カテゴリー

依存関係

依存関係一覧 1 件

ソースリポジトリ

このパッケージを使用しているプロジェクト

データはまだありません。