phpDocumentor pivotx
[ class tree: pivotx ] [ index: pivotx ] [ all elements ]

Class: EntriesFlat

Source Location: /modules/entries_flat.php

Class EntriesFlat

Property Summary
mixed   $all_cats  
mixed   $cat_index  
mixed   $date_index  
mixed   $entry  
mixed   $entry_index  
mixed   $entry_index_filename  
mixed   $logname  
mixed   $updated  
mixed   $update_mode  
mixed   $uri_index  

[ Top ]
Method Summary
EntriesFlat   __construct()  
void   allow_write()  
void   checkTimedPublish()   Checks if any entries set to 'timed publish' should be published.
void   check_current_index()  
void   clearIndex()   Clears the index for searching or tags (by deleteing all files whose filename don't starting with 'filtered_words' or 'index.html').
void   delete_comment()   Deletes a comment from the current entry. Also deletes it from the moderation queue and from latest comments.
boolean   delete_entries()   Delete one or more entries
void   delete_entry()   Deletes the current entry (and it's tags and comments).
void   delete_trackback()   Deletes a trackback from the current entry. Also deletes it from the last trackbacks.
boolean   depublish_entries()   Set one or more entries to 'hold'
void   disallow_write()  
boolean   entry_exists()   Tells if the entry exists - flat file implementation.
void   entry_from_index()  
void   generate_index()  
array   getArchiveArray()   Gets an array of archives - flat file implementation.
integer   get_code_from_uri()   Gets a code from a given $uri and $date.
array   get_comment()   Returns a comment from the current entry.
string   get_date()   Gets the date for an entry
int   get_entries_count()   Gets the number of entries
array   get_entry_by_uri()   Get an entry by it's (complete) URI The entry is returned as an associative array.
int   get_next_code()   Gets the code of the next entry - flat file implementation.
int   get_previous_code()   Gets the code of the previous entry - flat file implementation.
array   get_trackback()   Returns a trackback from the current entry.
array   guess_entry()   Tries to guess an entry by it's (incomplete) URI and date (if necessary). The entry is returned as an associative array.
void   index_entries()  
void   intersect()  
void   make_entry_index_filename()  
void   need_index()  
boolean   publish_entries()   Set one or more entries to 'publish'
void   read_date_index()  
array   read_entries()   Read a bunch of entries
array   read_entry()   Retrieves a full entry as an associative array, and returns it. The $code parameter can be a code/uid or an URI. The optional $date parameter helps to narrow it down, if there's more than one option.
void   read_entry_filename()  
void   read_entry_index()  
array   read_lasttrackbacks()   Read the last trackbacks
array   read_latestcomments()   Read the latest comments
void   safestring()  
boolean   save_entry()   Saves the current entry - flat file implementation.
array   set_entry()   Sets the current entry to the contents of $entry - flat file implementation.
void   set_filename()  
void   update_index()  
void   write_date_index()  
void   write_entry_index()  
void   _getSortArray()   Gets the sort array for a given orderby parameter.

[ Top ]
Properties
mixed   $all_cats [line 46]

[ Top ]
mixed   $cat_index [line 35]

[ Top ]
mixed   $date_index [line 34]

[ Top ]
mixed   $entry [line 31]

[ Top ]
mixed   $entry_index [line 42]

[ Top ]
mixed   $entry_index_filename [line 43]

[ Top ]
mixed   $logname [line 28]

[ Top ]
mixed   $updated [line 41]

[ Top ]
mixed   $update_mode [line 40]

[ Top ]
mixed   $uri_index [line 36]

[ Top ]
Methods
Constructor __construct  [line 50]

  EntriesFlat __construct( [ $loadindex = TRUE], [ $allow_write = TRUE]  )

Parameters:
   $loadindex: 
   $allow_write: 


[ Top ]
allow_write  [line 308]

  void allow_write( )



[ Top ]
checkTimedPublish  [line 1185]

  void checkTimedPublish( )

Checks if any entries set to 'timed publish' should be published.



[ Top ]
check_current_index  [line 1415]

  void check_current_index( )



[ Top ]
clearIndex  [line 1827]

  void clearIndex( string $type  )

Clears the index for searching or tags (by deleteing all files whose filename don't starting with 'filtered_words' or 'index.html').

Parameters:
string   $type: 


[ Top ]
delete_comment  [line 1215]

  void delete_comment( int $uid, [boolean $save = true]  )

Deletes a comment from the current entry. Also deletes it from the moderation queue and from latest comments.

Parameters:
int   $uid: 
boolean   $save:  whether the entry should be saved.


[ Top ]
delete_entries  [line 1097]

  boolean delete_entries( array $ids  )

Delete one or more entries

Parameters:
array   $ids: 


[ Top ]
delete_entry  [line 1067]

  void delete_entry( )

Deletes the current entry (and it's tags and comments).



[ Top ]
delete_trackback  [line 1307]

  void delete_trackback( int $uid, [boolean $save = true]  )

Deletes a trackback from the current entry. Also deletes it from the last trackbacks.

Parameters:
int   $uid: 
boolean   $save:  whether the entry should be saved.


[ Top ]
depublish_entries  [line 1155]

  boolean depublish_entries( array $ids  )

Set one or more entries to 'hold'

Parameters:
array   $ids: 


[ Top ]
disallow_write  [line 303]

  void disallow_write( )



[ Top ]
entry_exists  [line 449]

  boolean entry_exists( int $code  )

Tells if the entry exists - flat file implementation.

Parameters:
int   $code:  The code/id of the entry.


[ Top ]
entry_from_index  [line 1492]

  void entry_from_index( )



[ Top ]
generate_index  [line 412]

  void generate_index( )



[ Top ]
getArchiveArray  [line 222]

  array getArchiveArray( [boolean $force = FALSE], [ $unit_para = ''], string $unit  )

Gets an array of archives - flat file implementation.

Reads or creates/updates "ser-archives.php". The file contains 3 arrays - one for each time unit.

Parameters:
boolean   $force:  tells if "ser-archives.php" should be updated
string   $unit:  the unit of the archives
   $unit_para: 


[ Top ]
get_code_from_uri  [line 1566]

  integer get_code_from_uri( $uri, string $date, string $code  )

Gets a code from a given $uri and $date.

Parameters:
string   $code: 
string   $date: 
   $uri: 


[ Top ]
get_comment  [line 1279]

  array get_comment( int $uid  )

Returns a comment from the current entry.

Parameters:
int   $uid: 


[ Top ]
get_date  [line 463]

  string get_date( int $code  )

Gets the date for an entry

Parameters:
int   $code: 


[ Top ]
get_entries_count  [line 318]

  int get_entries_count( [mixed $params = false]  )

Gets the number of entries

Parameters:
mixed   $params:  optional, the same as read_entries


[ Top ]
get_entry_by_uri  [line 877]

  array get_entry_by_uri( string $uri  )

Get an entry by it's (complete) URI The entry is returned as an associative array.

Parameters:
string   $uri: 


[ Top ]
get_next_code  [line 343]

  int get_next_code( int $num  )

Gets the code of the next entry - flat file implementation.

Parameters:
int   $num: 


[ Top ]
get_previous_code  [line 376]

  int get_previous_code( int $num  )

Gets the code of the previous entry - flat file implementation.

Parameters:
int   $num: 


[ Top ]
get_trackback  [line 1358]

  array get_trackback( int $uid  )

Returns a trackback from the current entry.

Parameters:
int   $uid: 


[ Top ]
guess_entry  [line 858]

  array guess_entry( string $uri, string $date  )

Tries to guess an entry by it's (incomplete) URI and date (if necessary). The entry is returned as an associative array.

Parameters:
string   $uri: 
string   $date: 


[ Top ]
index_entries  [line 1596]

  void index_entries( $dirname  )

Parameters:
   $dirname: 


[ Top ]
intersect  [line 1803]

  void intersect( $arr1, $arr2  )

Parameters:
   $arr1: 
   $arr2: 


[ Top ]
make_entry_index_filename  [line 1476]

  void make_entry_index_filename( )



[ Top ]
need_index  [line 404]

  void need_index( )



[ Top ]
publish_entries  [line 1124]

  boolean publish_entries( array $ids  )

Set one or more entries to 'publish'

Parameters:
array   $ids: 


[ Top ]
read_date_index  [line 1392]

  void read_date_index( )



[ Top ]
read_entries  [line 524]

  array read_entries( array $params  )

Read a bunch of entries

Parameters:
array   $params: 


[ Top ]
read_entry  [line 482]

  array read_entry( mixed $code, [string $date = '']  )

Retrieves a full entry as an associative array, and returns it. The $code parameter can be a code/uid or an URI. The optional $date parameter helps to narrow it down, if there's more than one option.

Parameters:
mixed   $code: 
string   $date: 


[ Top ]
read_entry_filename  [line 1639]

  void read_entry_filename( $filename, [ $updateindex = TRUE], [ $force = FALSE]  )

Parameters:
   $filename: 
   $updateindex: 
   $force: 


[ Top ]
read_entry_index  [line 1427]

  void read_entry_index( $filename  )

Parameters:
   $filename: 


[ Top ]
read_lasttrackbacks  [line 923]

  array read_lasttrackbacks( array $params  )

Read the last trackbacks

Parameters:
array   $params: 


[ Top ]
read_latestcomments  [line 895]

  array read_latestcomments( array $params  )

Read the latest comments

Parameters:
array   $params: 


[ Top ]
safestring  [line 1385]

  void safestring( $name  )

Parameters:
   $name: 


[ Top ]
save_entry  [line 991]

  boolean save_entry( [boolean $update_index = TRUE]  )

Saves the current entry - flat file implementation.

Returns true if successfully saved. Current implementation seems to return true no matter what...

Parameters:
boolean   $update_index:  Whether to update the date index.


[ Top ]
set_entry  [line 955]

  array set_entry( array $entry  )

Sets the current entry to the contents of $entry - flat file implementation.

Returns the inserted entry as it got stored in the database with correct code/id.

Parameters:
array   $entry:  The entry to be inserted


[ Top ]
set_filename  [line 1529]

  void set_filename( [ $code = ""]  )

Parameters:
   $code: 


[ Top ]
update_index  [line 1654]

  void update_index( [ $update = TRUE]  )

Parameters:
   $update: 


[ Top ]
write_date_index  [line 1460]

  void write_date_index( )



[ Top ]
write_entry_index  [line 1439]

  void write_entry_index( [ $force = FALSE]  )

Parameters:
   $force: 


[ Top ]
_getSortArray  [line 1855]

  void _getSortArray( &$entries_arr, $orderby  )

Gets the sort array for a given orderby parameter.

It also updates $entries_arr so it contains the full entries. if the orderby parameter is referencing an extrafield.

Parameters:
   &$entries_arr: 
   $orderby: 


[ Top ]

Documentation generated on Tue, 05 Sep 2017 01:06:00 +0200 by phpDocumentor 1.4.3