This module defines Package classes.
A Package is a deplyment unit and contains a factories (Node generator) and meta informations (authors, license, doc...)
Abstract class to add a package in the package manager.
Package for dynamical parsing of python file
A Package is a dictionnary of node factory. Each node factory is able to generate node and their widgets.
Meta informations are associated with a package.
Return a meta information. See the standard key in the __init__ function documentation.
Parameters: | key -- todo |
---|
Return the list of python filename of the package. The filename are relative to self.path
New style package. A package is embeded in a unique directory. This directory can not contain more than one package. Thus, you can move, copy or delete a package by acting on the directory without ambiguity.
Return True if the package is embeded in a directory.
Build packages from wralea file Use 'register_package' function
Build a package from a vlab specification file.
Build a package from a __wralea__.py Use module variable
Write a wralea python file
Package user editable and persistent
Add a new user composite node factory to the package and save the package. Returns the cn factory.
This module defines the package manager.
It is able to find installed package and their wralea.py It stores the packages and nodes informations
The PackageManager is a Dictionary of Packages It can locate OpenAlea packages on the system (with wralea).
Add a search path for wralea files
Parameters: |
|
---|
Create a new package in the user space and register it Return the created package :param path : the directory where to create the package
Return all the dependencies of a package or a factory.
Find all wralea on the system and register them If no_cache is True, ignore cache file
Find in a directory vlab specification file.
Search recursivly is recursive is True
Returns: | a list of pkgreader instances |
---|
Find in a directory wralea files, Search recursivly is recursive is True
:return : a list of pkgreader instances
Find on the system all wralea.py files
:return : a list of pkgreader instances
Return all data that match the pattern.
Returns a node instance from the given url.
Parameters: |
---|
It is encoded this way: oa://domain/packageName?fac=*factoryName*&ft=*factoryType* . "oa" means that it is meant to be used by openalea. "domain" MUST BE "local" for now. "packageName" is the name of the package "factoryName" is the of factory "factoryType" is one of {"CompositeNodeFactory", "NodeFactory", "DataFactory"}
Initialize package manager
If dirname is None, find wralea files on the system else load directory If verbose is False, don't print any output
Return all the dependencies of a package or a factory.
Reload one or all packages.
If the package pkg is None reloa all the packages. Else reload only pkg.
Return a list of Factory corresponding to search_str If nb_inputs or nb_outputs is specified, return only node with the same number of (in/out) ports
3 - Then : Number of occurences of search_str in the category name 4 - Finally : presence of search_str in package name and position
in the name (close to the begining = higher score)
Data structure used to separate dotted naming (packages, category)