PHPackages                             imanaging-document/check-format-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. imanaging-document/check-format-bundle

ActiveSymfony-bundle[Utility &amp; Helpers](/categories/utility)

imanaging-document/check-format-bundle
======================================

This bundle allows you to check format, and provide mapping file system

v2.0(3y ago)19.2k↓33.3%MITPHPPHP ^7.1.3CI failing

Since Apr 2Pushed 2mo ago2 watchersCompare

[ Source](https://github.com/imanaging-document/check-format-bundle)[ Packagist](https://packagist.org/packages/imanaging-document/check-format-bundle)[ RSS](/packages/imanaging-document-check-format-bundle/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)Dependencies (3)Versions (4)Used By (0)

ImanagingCheckFormatBundle
==========================

[](#imanagingcheckformatbundle)

This bundle is a tool that allows you to check arrays format.

You have to provide a structure, which describe the format you want to check, and the datas you want to check. It can be simple array, or array of array.

A mapping function is available inside this bundle, you have to implement some required interfaces to make it works. You will find more information about how to use it in this readme.

This bundle should be used inside an imanaging-document application.

Install the bundle with:

```
$ composer require imanaging-document/check-format-bundle
```

Configuration
-------------

[](#configuration)

You have to create a `config/packages/imanaging_check_format.yaml` file:

```
imanaging_check_format:
    bar: ~
```

This configuration is optionnal.

Check Format
------------

[](#check-format)

### Usage

[](#usage)

You can access two statics methods named `checkFormatFile` and `getObjLine` where you need it in your project juste like this :

```
use Imanaging\CheckFormatBundle\CheckFormatFile;

class MyBeautifulService
{
  /**
   * ...
   */
  public function myBeautifulFunction(...){
    ...
    $result = CheckFormatFile::checkFormatLine($structureDescription, $myLineToCheckFormat));
    ...
  }
  ...
}
```

### Examples

[](#examples)

Checking a line structure

```
$structure = [
  // Type, Column Name, Nullable
  new FieldCheckFormat("string", "Name", false),
  new FieldCheckFormat("integer", "Age", true),
  new FieldCheckFormat("integer", "Height", true),
  new FieldCheckFormat("string", "City", true),
];

$myLine = ['Rémi', '26', '170', 'San Francisco'];
$result = CheckFormatFile::checkFormatLine($structure, $myLine));

// In this case, error equals false and the errors list is empty because there is no error
// $result['error'] = false;
// $result['errors_list'] = [];
```

Checking a file structure

```
$structure = [
  // Type, Column Name, Nullable
  new FieldCheckFormat("string", "Name", false),
  new FieldCheckFormat("integer", "Age", true),
  new FieldCheckFormat("integer", "Height", true),
  new FieldCheckFormat("string", "City", true),
];

$lines = [
  ['Rémi', '26', '170', 'San Francisco'],
  ['Antonin', '26', '181', 'Miami'],
];
$result = CheckFormatFile::checkFormatFile($structure, $lines));

// In this case, error equals false and the errors list is empty because there is no error
// $result['error'] = false;
// $result['errors_list'] = [];
```

Mapping
-------

[](#mapping)

#### Requirements

[](#requirements)

- Symfony 4
- JQuery
- Bootstrap 4
- FontAwesome

#### Configuration

[](#configuration-1)

#### Interfaces

[](#interfaces)

You have to implements the following interfaces in your `config/packages/doctrine.yaml` file :

```
Imanaging\CheckFormatBundle\Interfaces\MappingConfigurationInterface: App\Entity\MappingConfiguration
    Imanaging\CheckFormatBundle\Interfaces\MappingConfigurationTypeInterface: App\Entity\MappingConfigurationType
    Imanaging\CheckFormatBundle\Interfaces\MappingChampPossibleInterface: App\Entity\MappingChampPossible
    Imanaging\CheckFormatBundle\Interfaces\MappingConfigurationValueAvanceFileInterface: App\Entity\MappingConfigurationValueAvanceFile
    Imanaging\CheckFormatBundle\Interfaces\MappingConfigurationValueAvanceInterface: App\Entity\MappingConfigurationValueAvance
    Imanaging\CheckFormatBundle\Interfaces\MappingConfigurationValueAvanceTextInterface: App\Entity\MappingConfigurationValueAvanceText
    Imanaging\CheckFormatBundle\Interfaces\MappingConfigurationValueAvanceTypeInterface: App\Entity\MappingConfigurationValueAvanceType
    Imanaging\CheckFormatBundle\Interfaces\MappingConfigurationValueInterface: App\Entity\MappingConfigurationValue
    Imanaging\CheckFormatBundle\Interfaces\MappingConfigurationValueTransformationInterface: App\Entity\MappingConfigurationValueTransformation
    Imanaging\CheckFormatBundle\Interfaces\MappingConfigurationValueTranslationInterface: App\Entity\MappingConfigurationValueTranslation
```

#### Usage and examples

[](#usage-and-examples)

You can call a mapping page with an ajax call :

```

      Chargement en cours ...

```

```
let data = {files_directory: '/public/database/attestation/fichier_client*.csv', next_step_route: 'hephaistos_administration_import_fichier_client',
  mapping_configuration_type: 'integration_client'};
$.ajax({
  url: "{{ path('check_format_mapping_page') }}",
  type: 'POST',
  data: data,
  success: function (data) {
    $("#mappingDiv").html(data);
  },
  error: function () {
    Toast.fire({type: 'error', title: 'Error'});
  }
});
```

###  Health Score

39

—

LowBetter than 86% of packages

Maintenance56

Moderate activity, may be stable

Popularity24

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity53

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 59.6% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~399 days

Total

3

Last Release

1441d ago

Major Versions

v1.1 → v2.02022-06-08

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/48522350?v=4)[Imanaging Document](/maintainers/imanaging-document)[@imanaging-document](https://github.com/imanaging-document)

---

Top Contributors

[![n1n1du44](https://avatars.githubusercontent.com/u/3704587?v=4)](https://github.com/n1n1du44 "n1n1du44 (56 commits)")[![FqKeR3m1](https://avatars.githubusercontent.com/u/15010244?v=4)](https://github.com/FqKeR3m1 "FqKeR3m1 (33 commits)")[![ImanagingServiceTechnique](https://avatars.githubusercontent.com/u/80259906?v=4)](https://github.com/ImanagingServiceTechnique "ImanagingServiceTechnique (4 commits)")[![MathisR35](https://avatars.githubusercontent.com/u/79480737?v=4)](https://github.com/MathisR35 "MathisR35 (1 commits)")

### Embed Badge

![Health badge](/badges/imanaging-document-check-format-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/imanaging-document-check-format-bundle/health.svg)](https://phpackages.com/packages/imanaging-document-check-format-bundle)
```

###  Alternatives

[wallabag/wallabag

open source self hostable read-it-later web application

12.6k2.2k](/packages/wallabag-wallabag)[stfalcon/tinymce-bundle

This Bundle integrates TinyMCE WYSIWYG editor into a Symfony2 project.

2692.9M24](/packages/stfalcon-tinymce-bundle)[maba/webpack-bundle

Bundle to Integrate Webpack to Symfony

123268.2k4](/packages/maba-webpack-bundle)[mapbender/mapbender

Mapbender library

10117.4k5](/packages/mapbender-mapbender)[spomky-labs/pwa-bundle

Progressive Web App Manifest Generator Bundle for Symfony.

6144.4k1](/packages/spomky-labs-pwa-bundle)[leapt/core-bundle

Symfony LeaptCoreBundle

2529.1k4](/packages/leapt-core-bundle)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
