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

Class: Community_BlogComment

Source Location: /community_classes/blogcomment.class.php

Class Overview




Variables

Methods



Class Details

[line 38]


[ Top ]


Class Variables

static $instance =  null

[line 45]

Singleton



Tags:

access:  public

Type:   object


[ Top ]

$base =  null

[line 52]

Reference to base class



Tags:

access:  public

Type:   object


[ Top ]



Class Methods


constructor __construct [line 59]

Community_BlogComment __construct( )

Start instance of base class, load configuration and establish database connection. Please don't call the constructor direcly, use the singleton pattern instead.



Tags:

access:  public


[ Top ]

method addBlogComment [line 85]

int addBlogComment( array $sqlData)

Adds blog comment. Takes a field=>value array with blog comment data as first argument. Returns insert id.



Tags:

return:  User id
throws:  Community_BlogCommentException
access:  public


Parameters:

array   $sqlData   Row data

[ Top ]

method countBlogComments [line 492]

int countBlogComments( [array $params = array()])

Method to count amount of saved blog postings. Takes key=>value array with select params as first argument. Returns int.

List of supported params:

  • page, int, optional: Page id
  • status, int, optional: Blog comment status id
  • posting, int, optional: Posting id




Tags:

throws:  Community_BlogCommentException
access:  public


Parameters:

array   $params   Select params

[ Top ]

method deleteBlogComment [line 142]

int deleteBlogComment( int $id)

Removes blog comment from the blog comment table. Takes the blog comment id as first argument. Returns amount of affected rows.



Tags:

return:  Amount of affected rows
throws:  Community_BlogCommentException
access:  public


Parameters:

int   $id   Blog comment id

[ Top ]

method selectBlogComment [line 178]

array selectBlogComment( int $id)

Selects one blog comment. Takes the blog comment id as first argument. Returns array with blog comment information.



Tags:

throws:  Community_BlogCommentException
access:  public


Parameters:

int   $id   Blog comment id

[ Top ]

method selectBlogComments [line 306]

array selectBlogComments( [array $params = array()])

Method to select one or more blog comments. Takes key=>value array with select params as first argument. Returns array.

List of supported params:

  • page, int, optional: Page id
  • status, int, optional: Blog comment status id
  • posting, int, optional: Posting id
  • order_macro, string, optional: Sorting instruction
  • start, int, optional: row offset
  • limit, int, optional: amount of rows to return




Tags:

throws:  Community_BlogCommentException
access:  public


Parameters:

array   $params   Select params

[ Top ]

method updateBlogComment [line 110]

int updateBlogComment( int $id, array $sqlData)

Updates blog comment. Takes the blog comment id as first argument, a field=>value array with the new blog comment data as second argument.

Returns amount of affected rows.




Tags:

return:  Affected rows
throws:  Community_BlogCommentException
access:  public


Parameters:

int   $id   Blog comment id
array   $sqlData   Row data

[ Top ]

method updateBlogCommentCount [line 566]

int updateBlogCommentCount( int $posting_id)

Updates blog comment comment. Takes the posting id as first argument. Returns amount of affected rows.



Tags:

return:  Affected rows
throws:  Community_BlogCommentException
access:  public


Parameters:

int   $posting_id   Blog posting id

[ Top ]


Documentation generated on Sun, 08 Jan 2012 17:51:41 +0100 by phpDocumentor 1.4.3