搜尋套件、儲存庫與 APP 分類

套件詳情v1.0.0

mod97

計算模 97。

AndroidiOSWebmacOSWindowsLinux
近 30 天下載
2.7萬
喜歡數
0
Pub 分數
150

安裝套件

flutter pub add mod97

套件介紹

根據套件公開資料產生的選型評估,僅供參考。

mod97 套件為 Dart 應用程式提供了一種簡單且高效的方式來計算數字的模 97。它專為需要模 97 的數學運算而設計,例如在檢查碼演算法或金融識別碼驗證中使用。該套件輕量級、平台無關,並與所有主要 Flutter 平台(包括 Android、iOS、Web、macOS、Windows 和 Linux)相容。它提供一個直觀的 API,可無縫整合至現有程式碼庫中,無需額外依賴。

適用情境

  • 校驗和驗證
  • 金融標識符處理
  • 資料完整性檢查
  • 演算法計算
  • 數值驗證

主要特色

  • 輕量級實作
  • 跨平台支援
  • 簡單 API
  • 高效能
  • 精確的模 97 計算

適合對象

  • 需要取模 97 邏輯的開發者
  • 需要資料驗證的應用程式
  • 計算密集型 Flutter 項目
  • 金融或銀行軟體
  • 後端或演算法工具

使用建議

  • 僅限模 97
  • 不支援其他模數
  • 最小錯誤處理
  • 不適合複數理論

原始 README

以下為關聯原始碼儲存庫的 README 原文快照,最新內容請造訪原始碼儲存庫。

mod97

Calculates the MOD 97 10 of the passed number as specified in ISO7064.

Only positive numbers are allowed.

I have copied this code from iban.js

Build Status

Usage

A simple usage example:

import 'package:mod97/mod97.dart';

main() {
  int m = mod97('1234567');
  
  int m2 = mod97('-123', onError: (_) => 5);
  // m2 will be 5
}

The input must be a String. Returned value is an integer.

Invalid characters throw a FormatException unless an onError function is provided.

所屬分類

原始碼儲存庫

使用此套件的專案