International Sites:





/ PORTUNITY.COM / Support / Portalsuite 2002 / Manual / 9 Introduction to the Portalsuite Object


In the Advanced version and in higher versions the powerful object-oriented library „Portalsuite Objects“ is available in addition to the Portalsuite functions. It is an object-oriented library, which maps almost all data of the Portalsuite data base as well as further useful features from the fields of Content Management and portal applications. With the Portalsuite Objects both is possible, reading and writing access to the Portalsuite data base. If the options of functions and features provided by the Portalsuite „out-of-the-box“ would be insufficient, you could amend and programme your own functions in PHP through this open library. The Portalsuite applications themselves are mainly programmed with the „Portalsuite Objects“. The „Portalsuite Objects“ is a - if not even the most - powerful current object-oriented library in the field of Content Management.

9.1 General Brief Introduction to OOP

Introduction and Preface

We would like to offer a brief introduction to object-oriented programming (OOP) in the programming language PHP4 in this chapter. >> MORE


Difference to Procedural Programming

We like to cater here briefly to classic programming, the so-called „procedural programming“ you already know, maybe not under this name. In „procedural programming“ programme structuring occurs through functional abstraction. >> MORE


Declaration of a Class

In order to transport this theoretical entrance into practice, we use a classic example here: an address. >> MORE


Instantiation of an Object

With this construct you have not declared a variable $address or something similar yet, but rather a kind of new variable type „address“, just a class. >> MORE


Functions within Objects

But this still is not everything you can define in a class and do with an object. In our example and first object we accessed the object elements directly. >> MORE


Abstract Classes

Let’s also assume, our German customers of our product with the address object demand to include the federal state as well. >> MORE


Limitations of Object-oriented Programming in PHP

We indicated already a few times that the implementation of OOP in PHP is actually not a fully-fletched OOP >> MORE


Conclusion

In this chapter we only catered to those object-oriented properties of PHP which are most important in our opinion. >> MORE



9.2 Introduction to Portalsuite Objects

Introduction

This introduction is based on the assumption that you have already some practical experiences with the Portalsuite 2002. >> MORE


Of Getting Children and Inheriting

Do you want to cook up the same story every time you build a website ? Inheritance is the object-oriented alternative ! >> MORE


Hierarchy of Portalsuite Objects

The following illustration shows the pedigree with its most important classes. >> MORE


Abstract Classes

Many classes are defined in OOP only in order to be able to derive other classes from them. Such classes are called „abstract classes". >> MORE


Defining Instances or Deriving Classes

Generally there are two possibilities to use a class: >> MORE


Views and Dummy Objects

Portals built with Portalsuite Objects consist of objects of the type "view" or of the type "dummy objects". >> MORE



9.3 Instancing „Portalsuite Objects“ Objects

You can use and instance all documented objects of the „Portalsuite Objects“ library as objects in your templates and applications, as wonted, in PHP. We would like to demonstrate this in the following with several examples.

Introduction to „Portalsuite Objects“

In the Advanced version and in higher versions the powerful object-oriented library „Portalsuite Objects“ is available in addition to the Portalsuite functions. >> MORE



9.4 Deriving Portalsuite Objects

Deriving Portalsuite Objects

You can derive all documented object of the „Portalsuite Objects“ library in own classes and then again build instances thereof. >> MORE





[Back] - [Bookmark] - [Contact]




Direct links to the new Portalsuite 2002:

- Productinfos
- Download / Updates
- Support overview
- Support forum