Permalink
Browse files

initial project commit

  • Loading branch information...
1 parent cac2753 commit 3d45e5d7b713100b6cea92ad8d4697aff61fd599 @smalot committed Aug 31, 2013
Showing with 3,900 additions and 0 deletions.
  1. +60 −0 .atoum.php
  2. +17 −0 .bootstrap.atoum.php
  3. +6 −0 .gitignore
  4. +4 −0 .travis.yml
  5. +19 −0 composer.json
  6. +99 −0 composer.lock
  7. BIN doc/PDFReference.pdf
  8. +264 −0 src/Smalot/PdfParser/Document.php
  9. +178 −0 src/Smalot/PdfParser/Element.php
  10. +94 −0 src/Smalot/PdfParser/Element/ElementArray.php
  11. +59 −0 src/Smalot/PdfParser/Element/ElementBoolean.php
  12. +41 −0 src/Smalot/PdfParser/Element/ElementDate.php
  13. +48 −0 src/Smalot/PdfParser/Element/ElementHexa.php
  14. +57 −0 src/Smalot/PdfParser/Element/ElementMissing.php
  15. +51 −0 src/Smalot/PdfParser/Element/ElementName.php
  16. +58 −0 src/Smalot/PdfParser/Element/ElementNull.php
  17. +41 −0 src/Smalot/PdfParser/Element/ElementNumeric.php
  18. +51 −0 src/Smalot/PdfParser/Element/ElementString.php
  19. +44 −0 src/Smalot/PdfParser/Element/ElementStruct.php
  20. +60 −0 src/Smalot/PdfParser/Element/ElementXRef.php
  21. +105 −0 src/Smalot/PdfParser/Encoding.php
  22. +35 −0 src/Smalot/PdfParser/Encoding/ISOLatin1Encoding.php
  23. +35 −0 src/Smalot/PdfParser/Encoding/ISOLatin9Encoding.php
  24. +35 −0 src/Smalot/PdfParser/Encoding/StandardEncoding.php
  25. +35 −0 src/Smalot/PdfParser/Encoding/WinAnsiEncoding.php
  26. +157 −0 src/Smalot/PdfParser/Font.php
  27. +13 −0 src/Smalot/PdfParser/Font/FontCIDFontType2.php
  28. +58 −0 src/Smalot/PdfParser/Font/FontTrueType.php
  29. +13 −0 src/Smalot/PdfParser/Font/FontType0.php
  30. +13 −0 src/Smalot/PdfParser/Font/FontType1.php
  31. +100 −0 src/Smalot/PdfParser/Header.php
  32. +11 −0 src/Smalot/PdfParser/Image.php
  33. +475 −0 src/Smalot/PdfParser/Object.php
  34. +127 −0 src/Smalot/PdfParser/Page.php
  35. +34 −0 src/Smalot/PdfParser/Pages.php
  36. +107 −0 src/Smalot/PdfParser/Parser.php
  37. +158 −0 src/Smalot/PdfParser/Tests/Units/Document.php
  38. +120 −0 src/Smalot/PdfParser/Tests/Units/Element.php
  39. +104 −0 src/Smalot/PdfParser/Tests/Units/Element/ElementArray.php
  40. +102 −0 src/Smalot/PdfParser/Tests/Units/Element/ElementBoolean.php
  41. +85 −0 src/Smalot/PdfParser/Tests/Units/Element/ElementDate.php
  42. +85 −0 src/Smalot/PdfParser/Tests/Units/Element/ElementHexa.php
  43. +38 −0 src/Smalot/PdfParser/Tests/Units/Element/ElementMissing.php
  44. +116 −0 src/Smalot/PdfParser/Tests/Units/Element/ElementName.php
  45. +88 −0 src/Smalot/PdfParser/Tests/Units/Element/ElementNull.php
  46. +151 −0 src/Smalot/PdfParser/Tests/Units/Element/ElementNumeric.php
  47. +101 −0 src/Smalot/PdfParser/Tests/Units/Element/ElementString.php
  48. +55 −0 src/Smalot/PdfParser/Tests/Units/Element/ElementStruct.php
  49. +93 −0 src/Smalot/PdfParser/Tests/Units/Element/ElementXRef.php
View
@@ -0,0 +1,60 @@
+<?php
+
+/*
+This file will automatically be included before EACH run.
+
+Use it to configure atoum or anything that needs to be done before EACH run.
+
+More information on documentation:
+[en] http://docs.atoum.org/en/chapter3.html#Configuration-files
+[fr] http://docs.atoum.org/fr/chapter3.html#Fichier-de-configuration
+*/
+
+use \mageekguy\atoum;
+
+$report = $script->addDefaultReport();
+
+/*
+LOGO
+
+// This will add the atoum logo before each run.
+$report->addField(new atoum\report\fields\runner\atoum\logo());
+
+// This will add a green or red logo after each run depending on its status.
+$report->addField(new atoum\report\fields\runner\result\logo());
+*/
+
+/*
+CODE COVERAGE SETUP
+*/
+// Please replace in next line "Project Name" by your project name and "/path/to/destination/directory" by your destination directory path for html files.
+$coverageField = new atoum\report\fields\runner\coverage\html('PdfParser', 'coverage');
+
+// Please replace in next line http://url/of/web/site by the root url of your code coverage web site.
+$coverageField->setRootUrl('http://test.local');
+
+$report->addField($coverageField);
+/**/
+
+/*
+TEST GENERATOR SETUP
+
+$testGenerator = new atoum\test\generator();
+
+// Please replace in next line "/path/to/your/tests/units/classes/directory" by your unit test's directory.
+$testGenerator->setTestClassesDirectory('path/to/your/tests/units/classes/directory');
+
+// Please replace in next line "your\project\namespace\tests\units" by your unit test's namespace.
+$testGenerator->setTestClassNamespace('your\project\namespace\tests\units');
+
+// Please replace in next line "/path/to/your/classes/directory" by your classes directory.
+$testGenerator->setTestedClassesDirectory('path/to/your/classes/directory');
+
+// Please replace in next line "your\project\namespace" by your project namespace.
+$testGenerator->setTestedClassNamespace('your\project\namespace');
+
+// Please replace in next line "path/to/your/tests/units/runner.php" by path to your unit test's runner.
+$testGenerator->setRunnerPath('path/to/your/tests/units/runner.php');
+
+$script->getRunner()->setTestGenerator($testGenerator);
+*/
View
@@ -0,0 +1,17 @@
+<?php
+
+/*
+This file will automatically be included before EACH test if -bf/--bootstrap-file argument is not used.
+
+Use it to initialize the tested code, add autoloader, require mandatory file, or anything that needs to be done before EACH test.
+
+More information on documentation:
+[en] http://docs.atoum.org/en/chapter3.html#Bootstrap-file
+[fr] http://docs.atoum.org/fr/chapter3.html#Fichier-de-bootstrap
+*/
+
+
+// AUTOLOADER
+
+// composer
+require __DIR__ . '/vendor/autoload.php';
View
@@ -0,0 +1,6 @@
+/.idea/*
+/coverage/*
+/vendor/
+/xdebug/*
+/composer.phar
+/composer
View
@@ -0,0 +1,4 @@
+before_script:
+ - curl -sS https://getcomposer.org/installer | php
+ - ./composer.phar update
+script: ./vendor/bin/atoum -d src/Smalot/PdfParser/Tests/
View
@@ -0,0 +1,19 @@
+{
+ "name": "smalot/pdfparser",
+ "description": "Pdf parser library. Can read and extract informations from pdf file.",
+ "license": "GPL-2.0",
+ "authors": [
+ {
+ "name": "Sebastien Malot",
+ "email": "sebastien@malot.fr"
+ }
+ ],
+ "require": {
+ "atoum/atoum": "dev-master"
+ },
+ "autoload": {
+ "psr-0": {
+ "Smalot\\PdfParser\\": "src/"
+ }
+ }
+}
View
@@ -0,0 +1,99 @@
+{
+ "_readme": [
+ "This file locks the dependencies of your project to a known state",
+ "Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file"
+ ],
+ "hash": "a770ce253988c5313b2e1828ca1044fc",
+ "packages": [
+ {
+ "name": "atoum/atoum",
+ "version": "dev-master",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/atoum/atoum.git",
+ "reference": "89ff5d4d62cc51520247749cf4b3a9d82e07ec77"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/atoum/atoum/zipball/89ff5d4d62cc51520247749cf4b3a9d82e07ec77",
+ "reference": "89ff5d4d62cc51520247749cf4b3a9d82e07ec77",
+ "shasum": ""
+ },
+ "require": {
+ "ext-hash": "*",
+ "ext-json": "*",
+ "ext-session": "*",
+ "ext-tokenizer": "*",
+ "ext-xml": "*",
+ "php": ">=5.3.3"
+ },
+ "replace": {
+ "mageekguy/atoum": "*"
+ },
+ "suggest": {
+ "ext-mbstring": "Provides support for UTF-8 strings"
+ },
+ "bin": [
+ "bin/atoum"
+ ],
+ "type": "library",
+ "autoload": {
+ "classmap": [
+ "classes/"
+ ]
+ },
+ "notification-url": "http://packagist.org/downloads/",
+ "license": [
+ "BSD"
+ ],
+ "authors": [
+ {
+ "name": "Frédéric Hardy",
+ "email": "frederic.hardy@atoum.org",
+ "homepage": "http://blog.mageekbox.net"
+ },
+ {
+ "name": "François Dussert",
+ "email": "francois.dussert@atoum.org"
+ },
+ {
+ "name": "Gérald Croes",
+ "email": "gerald.croes@atoum.org"
+ },
+ {
+ "name": "Julien Bianchi",
+ "email": "julien.bianchi@atoum.org"
+ },
+ {
+ "name": "Ludovic Fleury",
+ "email": "ludovic.fleury@atoum.org"
+ }
+ ],
+ "description": "Simple modern and intuitive unit testing framework for PHP 5.3+",
+ "homepage": "http://www.atoum.org",
+ "keywords": [
+ "TDD",
+ "atoum",
+ "test",
+ "unit testing"
+ ],
+ "time": "2013-08-16 11:37:39"
+ }
+ ],
+ "packages-dev": [
+
+ ],
+ "aliases": [
+
+ ],
+ "minimum-stability": "stable",
+ "stability-flags": {
+ "atoum/atoum": 20
+ },
+ "platform": [
+
+ ],
+ "platform-dev": [
+
+ ]
+}
View
Binary file not shown.
Oops, something went wrong.

0 comments on commit 3d45e5d

Please sign in to comment.