Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members

BuildForm Class Reference

#include <BuildForm.h>

Inheritance diagram for BuildForm:

Inheritance graph
[legend]
Collaboration diagram for BuildForm:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 BuildForm (SimpleWeb &)
 ~BuildForm ()
void Process ()
void Display (long)

Constructor & Destructor Documentation

BuildForm::BuildForm SimpleWeb  ) 
 

Definition at line 8 of file BuildForm.cpp.

References BuildForm().

Referenced by BuildForm().

00009 :BaseForm(www, "BuildForm") 00010 { 00011 }

BuildForm::~BuildForm  ) 
 

Definition at line 14 of file BuildForm.cpp.

00015 { 00016 }


Member Function Documentation

void BuildForm::Display long   ) 
 

Definition at line 39 of file BuildForm.cpp.

References Display(), SimpleWeb::GetDatabase(), and BaseForm::GetWeb().

Referenced by Display(), and SimpleWeb::GenerateDocument().

00040 { 00041 Database& db = GetWeb().GetDatabase(); 00042 Query q(db); 00043 db::Account acct(db, GetWeb().GetAccount()); 00044 db::Player pl(db, GetWeb().GetPlayer()); 00045 db::Location loc(db, pl.location); 00046 char sql[1000]; 00047 00048 // ... 00049 Header(db, q, acct, pl, loc, sql); 00050 00051 }

void BuildForm::Process  ) 
 

Definition at line 19 of file BuildForm.cpp.

References SimpleWeb::GetBuilding(), SimpleWeb::GetDatabase(), SimpleWeb::GetSkill(), BaseForm::GetWeb(), and SimpleWeb::SetBuild().

00020 { 00021 Database& db = GetWeb().GetDatabase(); 00022 Query q(db); 00023 std::string action = GetForm() -> getvalue(GetFormName()); 00024 long skill = GetWeb().GetSkill(); 00025 long building = GetWeb().GetBuilding(); 00026 char sql[1000]; 00027 00028 if (action == "try_build") 00029 { 00030 GetWeb().SetBuild(1); 00031 } 00032 else 00033 { 00034 GetWeb().SetBuild(0); 00035 } 00036 }


The documentation for this class was generated from the following files:
Generated for simple by doxygen 1.3.7