Enhance the plantUML plugin.

I’ve just committed (6dd4933) an improvement in the plantUML plugin. Class diagram display now class constants.

Run the command below
$ php bin/reflect --profile --plantUML:run --alias SFinder --class="Symfony\Component\Finder\Finder"
Requires that your reflect.json configuration file declare the source Symfony/Finder.

You will get such output.

set namespaceSeparator none

namespace Symfony.Component.Finder {
class Finder{
    +IGNORE_VCS_FILES
    +IGNORE_DOT_FILES
    ..
    -mode
    -names
    -notNames
    -exclude
    -filters
    -depths
    -sizes
    -followLinks
    -sort
    -ignore
    -dirs
    -dates
    -iterators
    -contains
    -notContains
    -adapters
    -paths
    -notPaths
    -ignoreUnreadableDirs
    -vcsPatterns
    --
    +__construct()
    +create()
    +addAdapter()
    +useBestAdapter()
    +setAdapter()
    +removeAdapters()
    +getAdapters()
    +directories()
    +files()
    +depth()
    +date()
    +name()
    +notName()
    +contains()
    +notContains()
    +path()
    +notPath()
    +size()
    +exclude()
    +ignoreDotFiles()
    +ignoreVCS()
    +addVCSPattern()
    +sort()
    +sortByName()
    +sortByType()
    +sortByAccessedTime()
    +sortByChangedTime()
    +sortByModifiedTime()
    +filter()
    +followLinks()
    +ignoreUnreadableDirs()
    +in()
    +getIterator()
    +append()
    +count()
    -sortAdapters()
    -searchInDirectory()
    -buildAdapter()
    -resetAdapterSelection()
}
}
interface IteratorAggregate
IteratorAggregate <|.. Finder
interface Countable
Countable <|.. Finder

Put in in a file , e.g classDiagram.plantuml, and send the result to plantUML

$ java -jar plantuml.jar classDiagram.plantuml

That should give something like :

symfony_finder.classdiagram.png
Published by Laurent Laville on 2014-04-10

Reflect 2.0.0 has just been released.

After three releases candidate, here is the final stable version.

Features summary :

  • Implement Event Driven Architecture powered by the Symfony EventDispatcher component.

  • More data source can be parse than API 1.0. Implement a new source provider powered by the Symfony Finder component.

  • Each element found during parsing can be exploited by an API almost equivalent to PHP5 Reflection.

  • A plugin architecture to extend features as you want without to modify core code.

  • Three plugins are bundled with stable version : Analyser, PlantUML (and Cache).

What is planned for the next version 2.1.0:
  • Implement the third cache plugin to speed up later uses.

Alternatively, you may use Composer and install it via Packagist.

Published by Laurent Laville on 2014-04-04