Running a pattern: execution flow

In this section we will detail the execution flow using a basic pattern that can be found in the submodule patterns_examples: node.yaml. This file will be used as an example for the rest of the pages as well.

info: 
  title: Example Article creation
  description: Creates an example article node
  author: QSCience
  version: 1.0
  category: Content
  core: 7.x
  author_website: http://qlectives.eu

actions:
  - create:
      tag: node
      type: article
      title: Test Article
      body: lorem ipsum ...

  • We can start taking a look at the hook_menu() in the file patterns.module, where we will find the association between the paths and the main functions: enable a pattern, remove a pattern, publish it, the main settings, etc.
  • The first function we will detail is patterns_list() (implemented also in patterns.module), since this is the first function to be called. This function returns the main form in
    which all the operations related to patterns are performed. In this function, the following operations are carried on:
    • Check if there is any parser to use.
Subscribe with RSS Subscribe to RSS - running