Skip to content

Instantly share code, notes, and snippets.

@zanematthew
Created April 13, 2012 14:22
Show Gist options
  • Save zanematthew/2377230 to your computer and use it in GitHub Desktop.
Save zanematthew/2377230 to your computer and use it in GitHub Desktop.
temp
<?php
/**
* Contains all the methods for manipluating Events "directly", this should extend the db class
*/
Class Event {
/**
* Gets the title to an Event
*
* @param int $event_id
*/
public function title(){}
/**
* Gets the Event description
*
* @param $event_id
* @return string $description of event
*/
public function description(){}
/**
* Gets Events by Type.
*
* @param array $type 'national', 'redlinecup', 'state'
* @param int $event_id
* @return
*/
public function listByType(){}
/**
* Prints share tools, either all of them or only the ones specified
*
* @param array $params facebook=true, twitter=true
* @return markup containing share buttons
*/
public function share(){}
/**
* Inserts a new Event into the db.
*
* @param array $params = title, description, date, track, (array) tags
* @return false on failure
*/
public function create(){}
/**
* Updates an Event
*
* @param int $event_id
* @param array $params = title, description, date, track, (array) tags
* @return false on failure
*/
public function update(){}
/**
* Deletes an Event and ALL its attributes from the data base.
*
* @return (int) $event_id, (string) $event_title
*/
public function remove(){}
/**
* Returns the tags for all Events or a single Event based on
* Event id.
*
* @param int $event_id
* @return array of tag(s)
*/
public function tags(){}
/**
* Gets all the comments for a single Event.
*
* @param int $event_id
* @return array avatar, time, author, comment
*/
public function comments(){}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment