RealEstates
[ class tree: RealEstates ] [ index: RealEstates ] [ all elements ]

Class: Estate_Goods

Source Location: /Estate_Goods.php

Class Overview

PHP_Objects
   |
   --Estate_Goods

Created on 04 may 09


Author(s):

Version:

  • 1.2

Variables

Methods


Inherited Variables

Inherited Methods

Class: PHP_Objects

PHP_Objects::__construct()
Construction function
PHP_Objects::getDB()
Database obtention function
PHP_Objects::getTable()
Table obtention function
PHP_Objects::setDebug()
Debug setting function

Class Details

[line 19]
Created on 04 may 09

This class manages Real Estate Goods objects.

CHANGES: 1.1 -> 1.2: 08 may 09 Added GoodAdd() function Added debug value 1.0 -> 1.1: 06 may 09 Added to RealEstates package




Tags:

author:  Pierre-Dominique Vienne <pvienne@me.com>
version:  1.2
license:  GNU Public License


[ Top ]


Class Variables

$altitude =

[line 109]

Variable that contains altitude



Tags:

access:  protected

Type:   int


[ Top ]

$availabilityID =

[line 127]

Variable that contains availability ID



Tags:

access:  protected

Type:   int


[ Top ]

$cityID =

[line 91]

Variable that contains location city ID



Tags:

access:  protected

Type:   int


[ Top ]

$database =  "estates"

[line 25]

Variable that contains database name



Tags:

access:  protected

Type:   string


[ Top ]

$diverse =

[line 55]

Variable that contains diverse data



Tags:

access:  protected

Type:   string


[ Top ]

$gooddescr =

[line 49]

Variable that contains good description



Tags:

access:  protected

Type:   string


[ Top ]

$goodID =

[line 37]

Variable that contains good ID



Tags:

access:  protected

Type:   int


[ Top ]

$goodlegalformID =

[line 133]

Variable that contains legal form ID



Tags:

access:  protected

Type:   int


[ Top ]

$goodname =

[line 43]

Variable that contains good name



Tags:

access:  protected

Type:   string


[ Top ]

$goodprice =

[line 121]

Variable that contains value of the good



Tags:

access:  protected

Type:   int


[ Top ]

$goodpricetypeID =

[line 115]

Variable that contains type ID of the good price



Tags:

access:  protected

Type:   int


[ Top ]

$goodsurface =

[line 67]

Variable that contains good surface



Tags:

access:  protected

Type:   int


[ Top ]

$goodsurface_living =

[line 73]

Variable that contains good surface living



Tags:

access:  protected

Type:   int


[ Top ]

$goodvolume =

[line 61]

Variable that contains good volume



Tags:

access:  protected

Type:   int


[ Top ]

$gps_lat =

[line 97]

Variable that contains gps latitude



Tags:

access:  protected

Type:   float


[ Top ]

$gps_long =

[line 103]

Variable that contains gps longitude



Tags:

access:  protected

Type:   float


[ Top ]

$inserted_ts =

[line 139]

Variable that contains row insertion timestamp



Tags:

access:  protected

Type:   int


[ Top ]

$roomsqty =

[line 79]

Variable that contains rooms quantity



Tags:

access:  protected

Type:   float


[ Top ]

$table =  "estate_goods"

[line 31]

Variable that contains table name



Tags:

access:  protected

Type:   string


[ Top ]

$taxrate =

[line 85]

Variable that contains tax rate



Tags:

access:  protected

Type:   float


[ Top ]

$updated_ts =

[line 145]

Variable that contains row modification timestamp



Tags:

access:  protected

Type:   int


[ Top ]



Class Methods


method GoodAdd [line 340]

object fetched GoodAdd( string $goodname, string $gooddescr, string $diverse, int $goodvolume, int $goodsurface, int $goodsurface_living, float $roomsqty, float $taxrate, int $cityID, float $gps_lat, float $gps_long, int $altitude, int $goodpricetypeID, int $goodprice, int $availabilityID, int $goodlegalformID, string $this->database, string $this->table)

Good add function

This function is used to add a good to database. Result is stored in $this and returned

  1.  <?php
  2.  $oGood            new Estate_Goods();
  3.  $oGood->GoodAdd($goodname,$gooddescr,$diverse,$goodvolume,$goodsurface,$goodsurface_living,$roomsqty,$taxrate,$cityID,$gps_lat,$gps_long,$altitude,$goodpricetypeID,$goodprice,$availabilityID,$goodlegalformID);
  4.  ?>




Tags:

return:  good object
since:  Version 1.2


Parameters:

string   $this->database   database name
string   $this->table   table name
string   $goodname   name of the good
string   $gooddescr   description of the good
string   $diverse   diverse informations
int   $goodvolume   volume of the good
int   $goodsurface   total surface of the good
int   $goodsurface_living   living surface of the good
float   $roomsqty   quantity of rooms
float   $taxrate   tax rate
int   $cityID   ID of the city
float   $gps_lat   GPS latitude
float   $gps_long   GPS longitude
int   $altitude   Altitude of the good
int   $goodpricetypeID   ID of the type of the price
int   $goodprice   price of the good
int   $availabilityID   ID of the availability
int   $goodlegalformID   ID of the legal form

[ Top ]

method GoodbyID [line 173]

object fetched GoodbyID( int $goodID, string $this->database, string $this->table)

Good by ID obtention function

This function is used to get good object by its ID from database. Result is stored in $this and returned

  1.  <?php
  2.  $oGood            new Estate_Goods();
  3.  print_r($oGood->GoodbyID(2));
  4.  // goodobject
  5.  ?>




Tags:

return:  good object
since:  Version 1.0


Parameters:

string   $this->database   database name
string   $this->table   table name
int   $goodID   ID of the good to be fetched

[ Top ]

method GoodsList [line 259]

object fetched GoodsList( [string $orderrow = "goodname"], [string $order = "ASC"], string $this->database, string $this->table)

Goods list obtention function

This function is used to get goods list from database. Result is stored in $this and returned

  1.  <?php
  2.  $oGood            new Estate_Goods();
  3.  $oGood->GoodsList();
  4.  print_r($oGood->result);
  5.  // array of goods
  6.  ?>




Tags:

return:  good object
since:  Version 1.0


Parameters:

string   $this->database   database name
string   $this->table   table name
string   $orderrow   row to use to order results
string   $order   order to use (ASC DESC)

[ Top ]


Documentation generated on Wed, 26 Aug 2009 12:30:04 +0200 by phpDocumentor 1.4.1