Download the PHP package statonlab/fields_generator without Composer

On this page you can find all versions of the php package statonlab/fields_generator. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package fields_generator

Build Status DOI

Tripal Fields Generator

This is a CLI tool to help automate the generation of Tripal fields for use in Tripal 3 development. We highly recommend you read the developer handbook before attempting to use this tool. It supports creating both Tripal and Chado fields.

Documentation

Installation

Using Composer

The easiest way to install Tripal Fields Generator is using Composer.

Install command

Update command

Note: make sure you export the composer bin directory by running the following command:

Manual installation

You can download this tool using the "Clone or download" button above or cloning the repository using Git.

Usage

Generate a new field by running the following command and answering a few questions. By default, Tripal Fields Generator will generate a Chado field, but it can also generate Tripal fields.

The generator will ask you for both the DB name and the CV name: these names correspond to the chado.db and chado.cv tables. If you aren't sure what these values are, you can use the EBI Ontology lookup Service CVterm entry as a guide: the DB name is the value in the orange box, and the CV name is the value in the teal box. For a full explanation, please read the CV guide.

Alternatively, the below table shows the DB and CV values for commonly used ontologies in Tripal 3.

FULL NAME DB CV
DCMI metadata terms dc dc
Eagle-I Research Ontology ERO ero
EDAM data data EDAM
EDAM format format EDAM
EDAM operation operation EDAM
EDAM topic topic EDAM
Friend of a Friend foaf foaf
Gene ontology biological process GO biological_process
Gene ontology cellular component GO cellular_component
Gene ontology molecular function GO molecular_function
hydra hydra hydra
Information Artifact Ontology IAO IAO
local local local
Ontology for Biomedical Investigation OBI OBI
Ontology for genetic interval OGI ogi
Ontology of Biological and Clinical Statistics OBCS OBCS
Relationship ontology (legacy) RO ro
Resource Description Framework Schema rdfs rdfs
schema schema schema
Semanticscience Integrated Ontology SIO SIO
Sequence ontology SO sequence
Software Ontology SWO swo
Systems Biology SBO sbo
Taxonomic Rank TAXRANK taxonomic_rank

In order for Drupal to recognize your fields, you must...

Options

Option default description example
--output (-o) Current working directory The path to the module responsible for the field. makefield -o="/var/www/html/sites/all/modules/my_module"
--type (-t) chado The type of field to generate. Choose between Chado which would extend ChadoField or Tripal to extend TripalField makefield -t=tripal

Output

Tripal Fields Generator will create four files that define your field. For the custom controlled vocabulary (CV) term example defined in the local CV, the field is defined in three files:

Additionally, a fields file stub describing the fields declared in your module is generated: for this example module, the file might be tripal_example_module.fields.inc. Note that all of the fields in your module are described here: running Tripal Fields Generator multiple times will require you to combine this file for each field. The final structure of your fields should look like the example below, with a given field CV__CVTERM in module/includes/TripalFields/CV_CVterm, and the module.fields.inc located in module/includes. For a full example of a field please visit the Tripal Example Module repository by @laceysanderson.

Output file structure

By default, the module-level field file (moduleName.fields.inc) will be placed in CV__CVterm_output, and the classes defining your field will be in the field folder CV__CVterm_output/CV__CVterm. Note that the value of CV corresponds to what you enter for the DB, not the CV table!

You will need to move these files to conform to the pattern in the previous section. Alternatively, you may specify a different output path using the output flag, -o="/path/to/module" or --output="/path/to/module". This will automatically define your fields in the correct place. In either case, your final module field structure should look like the example below.

Terms

The below terms must be provided for each field you generate.

Examples

Contributing

Contributions are highly welcomed and recommended.

License

This tool is licensed under GNU GPLv2. Copyright 2017 University of Tennessee. All rights reserved.

The Tripal Fields Generator "logo" is derived from the collectible card game Hearthstone, copyright © Blizzard Entertainment, Inc. Hearthstone® is a registered trademark of Blizzard Entertainment, Inc. Tripal Fields Generator is not affiliated or associated with or endorsed by Hearthstone® or Blizzard Entertainment, Inc.


All versions of fields_generator with dependencies

PHP Build Version
Package Version
Requires phpunit/phpunit Version ^5 || ^6 || ^7.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package statonlab/fields_generator contains the following files

Loading the files please wait ....