Class: Recipe_Model

Source Location: /tinymvc/myapp/models/recipe_model.php

Class Overview [line 9]

AbstractModel
   |
   --Recipe_Model

Data model for recipes. Handles retrieving recipes based on various criteria.

Author(s):

  • Monte Ohrt

Version:

Copyright:

Variables

Constants

Methods


Inherited Variables

Inherited Constants

Inherited Methods

Class: AbstractModel

AbstractModel::__construct()
class constructor


Class Details

Data model for recipes. Handles retrieving recipes based on various criteria.

Tags:

[ Top ]


Class Variables


Class Methods

getRecipeById

array getRecipeById( int $id)

[line 56]

Retrieves a recipe using its id.

Tags:

  • return - An associate array with all the recipe data.

Parameters:

  • int $id - The Recipe Id

[ Top ]

getRecipesByIngredient

array getRecipesByIngredient( string $query)

[line 33]

Retrieves a list of recipes that match $query (uses recipe ingredients to compare).

Parameters:

  • string $query - The query with which to find matches.

[ Top ]

getRecipesByName

array getRecipesByName( string $query)

[line 17]

Retrieves a list of all recipes that match $query (uses recipe name to compare).

Parameters:

  • string $query - The query with which to find matches.

[ Top ]

getRecipesForSpecial

array getRecipesForSpecial( int $specialId)

[line 73]

Retrieves a list of recipes which match the given special id.

Parameters:

  • int $specialId - The special id for which to get associated recipes.

[ Top ]


Class Constants


Documentation generated on Tue, 26 May 2009 14:50:37 -0700 by phpDocumentor 1.4.1