Stud.IP  2.0 Revision 48548
 All Data Structures Namespaces Files Functions Variables Pages
FoafDisplay Class Reference
Collaboration diagram for FoafDisplay:
Collaboration graph

Public Member Functions

 FoafDisplay ($user_id, $target_id, $target_username)
 calculate ()
 doCalculate ($depth=0)
 show ($open="close")
 user_info ($user_id, $ignore_ok)
 info_text ()

Data Fields

 $db
 $user_id
 $target_id
 $foaf_list
 $target_username
 $depth = 4
 $dont_show_anonymous = true

Detailed Description

Calculate and display "Friend of a friend lists"

for a given user the current user can see how many "steps" (in terms of buddy list entry hops) are neccessary to connect himself with the user at hand (whose homepage is currently viewed).

Author
Tobias Thelen tthel.nosp@m.en@u.nosp@m.ni-os.nosp@m.nabr.nosp@m.ueck..nosp@m.de
Michael Riehemann micha.nosp@m.el.r.nosp@m.iehem.nosp@m.ann@.nosp@m.uni-o.nosp@m.lden.nosp@m.burg..nosp@m.de

Member Function Documentation

calculate ( )

Calculate foaf list.

Uses smart DB joins to find connections. Thanks to Manuel Wortmann (post@.nosp@m.manu.nosp@m.el-wo.nosp@m.rtma.nosp@m.nn.de) for the code!

private

Here is the call graph for this function:

Here is the caller graph for this function:

doCalculate (   $depth = 0)

Here is the caller graph for this function:

FoafDisplay (   $user_id,
  $target_id,
  $target_username 
)

Initialise FoafDisplay object and calculate list.

Parameters
user_idWatching user
user_idWatched user
stringWatched user's username (performance saver)

Here is the call graph for this function:

info_text ( )

Return info text for foaf-feature

Here is the call graph for this function:

Here is the caller graph for this function:

show (   $open = "close")

Show Topic bar and header/content for foaf display.

Prints a topic bar and a printhead line (with active link for opening/closing content) and content, if opened.

public

Parameters
stringopen/close indication (passed by about.php)

Here is the call graph for this function:

user_info (   $user_id,
  $ignore_ok 
)

Gather and format info on user.

Parameters
user_idA user's id
boolShould user data be created even if user doesn't want to appear in foaf lists? (true if head or tail of list)
Returns
array "uname"=>username, "fullname"=>Full name, "link"=>(clickable) Name, "pic"=>HTMl code for picture

Here is the call graph for this function:

Here is the caller graph for this function:

Field Documentation

$db
$depth = 4
$dont_show_anonymous = true
$foaf_list
$target_username
$user_id

The documentation for this class was generated from the following file: