Go Back   vb.org Archive > Community Central > Community Lounge

Reply
 
Thread Tools Display Modes
  #1  
Old 05-18-2005, 06:26 PM
sabret00the's Avatar
sabret00the sabret00the is offline
 
Join Date: Jan 2003
Location: London
Posts: 5,268
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default OOP + vB

Without pointing to a tutorial or an article anywhere could someone please, atleast try and explain what Object Orientated Programming is? how and why it's gonna be a part of vBulletin? and what are it's benefits over the current methods of programming (procedural)? please, if it's not too much trouble.

examples of OOP are more than welcome, but if you're gonna do something like "hello world" please don't as it don't really help me in how i'm trying to grasp it.
Reply With Quote
  #2  
Old 05-18-2005, 11:13 PM
AN-net's Avatar
AN-net AN-net is offline
 
Join Date: Dec 2003
Location: AnimationTalk.com
Posts: 2,367
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

oop basically creates an organized structure through classes allowing multiple instances of the same class without having to write code multiple times. the benefits besides more organization is beyond me. an example is the $DB_site class which uses some oop
Reply With Quote
  #3  
Old 05-19-2005, 02:13 AM
filburt1 filburt1 is offline
 
Join Date: Feb 2002
Location: Maryland, US
Posts: 6,144
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by AN-net
oop basically creates an organized structure through classes allowing multiple instances of the same class without having to write code multiple times. the benefits besides more organization is beyond me. an example is the $DB_site class which uses some oop
It's a more semantec method of developing code than functional code. It's also far more modular and pluggable.
Reply With Quote
  #4  
Old 05-19-2005, 02:19 AM
Dark Aura Dark Aura is offline
 
Join Date: Jul 2004
Location: Not telling!
Posts: 64
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Heres a tutorial made by Zero Tolerance:

http://gzevolution.net/?type=page&id...tutorial&tut=9
Reply With Quote
  #5  
Old 05-19-2005, 08:51 AM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Just have a look at ImpEx, this has a lot of OOP coding in it.
Reply With Quote
  #6  
Old 05-19-2005, 05:39 PM
Paul M's Avatar
Paul M Paul M is offline
 
Join Date: Sep 2004
Location: Nottingham, UK
Posts: 23,748
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

It just seems to be a long winded way to achieve the same thing. Functions have always existed - where is the advantage ?
Reply With Quote
  #7  
Old 05-19-2005, 06:00 PM
The Geek's Avatar
The Geek The Geek is offline
 
Join Date: Sep 2003
Location: Behind you
Posts: 2,779
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Properties and Functions are a part of OOP. The advantages are far too numerous to put down - but in a nutshell it allows other coders (ie mod/hack writers) to not worry about how a particular function works, or where it is located - they just call a particular function and get what they need.

Say for instance there was a mammouth object called vB and you wanted to get a particular users name, you could do something like vb.users(51).username;
(yes, that isnt php... more like vB... but easier to read IMO ).

Anyhoo... you wouldnt have to worry about a particular query, where the table is, worry about table prefixes, etc... More importantly, you wouldnt have to worry about future changes affecting how you usually get a username as it would all be black boxed.

Thats my 3.8 cents (?.02 at current exchange rate).
Reply With Quote
  #8  
Old 05-19-2005, 06:01 PM
AN-net's Avatar
AN-net AN-net is offline
 
Join Date: Dec 2003
Location: AnimationTalk.com
Posts: 2,367
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

yes it is the same but just a longer way of doing things. it is really only a coding style which allows a program to be easily extended upon because every is a class which can be changed and not have to be changed over several files.
Reply With Quote
  #9  
Old 05-19-2005, 06:24 PM
Corriewf's Avatar
Corriewf Corriewf is offline
 
Join Date: Dec 2004
Location: parse error
Posts: 799
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Also doesnt it make programs easier to be designed by mutiple people instead of one person.
Reply With Quote
  #10  
Old 05-19-2005, 08:18 PM
AN-net's Avatar
AN-net AN-net is offline
 
Join Date: Dec 2003
Location: AnimationTalk.com
Posts: 2,367
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by corriewf
Also doesnt it make programs easier to be designed by mutiple people instead of one person.
yes because its a written standard. so basically as hacks are designed in oop in the future it will become easier for others to port, upgrade, or change. as there will be no need as to "wait what is he doing?"
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 03:39 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05779 seconds
  • Memory Usage 2,250KB
  • Queries Executed 13 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete