8000 [AstGenerator] [WIP] New Component, add normalizer generator by joelwurtz · Pull Request #17516 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[AstGenerator] [WIP] New Component, add normalizer generator #17516

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Closed
Next Next commit
Init AstGenerator Component
  • Loading branch information
joelwurtz committed Aug 5, 2016
commit 36b89e2e7d9c8bd719c5ff456b8ebf436f5a7df4
3 changes: 3 additions & 0 deletions src/Symfony/Component/AstGenerator/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
vendor/
composer.lock
phpunit.xml
24 changes: 24 additions & 0 deletions src/Symfony/Component/AstGenerator/AstGeneratorInterface.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<?php

/*
* This file is part of the Symfony package.
*
* (c) Fabien Potencier <fabien@symfony.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/

namespace Symfony\Component\AstGenerator;

/**
* An AstGeneratorInterface is a contract to transform an object into an AST
*
* @author Joel Wurtz <joel.wurtz@gmail.com>
*/
interface AstGeneratorInterface
{
public function generate();

public function supportsGeneration();
}
8 changes: 8 additions & 0 deletions src/Symfony/Component/AstGenerator/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
AstGenerator Component
======================

AstGenerator allows to generate PHP AST for several Component:

* Transform class, properties and types extracted from the PropertyInfo Component into POPO objects ans Normalizers
compatible with Serializer Component

34 changes: 34 additions & 0 deletions src/Symfony/Component/AstGenerator/composer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
{
"name": "symfony/ast-generator",
"type": "library",
"description": "Symfony component to generate AST from and to various others components",
"keywords": ["symfony", "ast", "generator"],
"homepage": "https://symfony.com",
"license": "MIT",
"authors": [
{
"name": "Joel Wurtz",
"email": "joel.wurtz@gmail.com"
},
{
"name": "Symfony Community",
"homepage": "https://symfony.com/contributors"
}
],
"require": {
"php": ">=5.5.9",
"nikic/php-parser": "~2.0"
},
"autoload": {
"psr-4": { "Symfony\\Component\\AstGenerator\\": "" },
"exclude-from-classmap": [
"/Tests/"
]
},
"minimum-stability": "dev",
"extra": {
"branch-alias": {
"dev-master": "3.1-dev"
}
}
}
0