updated properties to "public"

removed "var" and set to "public"
This commit is contained in:
William Knauss
2014-05-09 21:30:47 -04:00
parent 0323d5108b
commit ba1d462044

View File

@@ -90,68 +90,68 @@ class parseCSV {
*/ */
# use first line/entry as field names # use first line/entry as field names
var $heading = true; public $heading = true;
# override field names # override field names
var $fields = array(); public $fields = array();
# sort entries by this field # sort entries by this field
var $sort_by = null; public $sort_by = null;
var $sort_reverse = false; public $sort_reverse = false;
# sort behavior passed to ksort/krsort functions # sort behavior passed to ksort/krsort functions
# regular = SORT_REGULAR # regular = SORT_REGULAR
# numeric = SORT_NUMERIC # numeric = SORT_NUMERIC
# string = SORT_STRING # string = SORT_STRING
var $sort_type = null; public $sort_type = null;
# delimiter (comma) and enclosure (double quote) # delimiter (comma) and enclosure (double quote)
var $delimiter = ','; public $delimiter = ',';
var $enclosure = '"'; public $enclosure = '"';
# basic SQL-like conditions for row matching # basic SQL-like conditions for row matching
var $conditions = null; public $conditions = null;
# number of rows to ignore from beginning of data # number of rows to ignore from beginning of data
var $offset = null; public $offset = null;
# limits the number of returned rows to specified amount # limits the number of returned rows to specified amount
var $limit = null; public $limit = null;
# number of rows to analyze when attempting to auto-detect delimiter # number of rows to analyze when attempting to auto-detect delimiter
var $auto_depth = 15; public $auto_depth = 15;
# characters to ignore when attempting to auto-detect delimiter # characters to ignore when attempting to auto-detect delimiter
var $auto_non_chars = "a-zA-Z0-9\n\r"; public $auto_non_chars = "a-zA-Z0-9\n\r";
# preferred delimiter characters, only used when all filtering method # preferred delimiter characters, only used when all filtering method
# returns multiple possible delimiters (happens very rarely) # returns multiple possible delimiters (happens very rarely)
var $auto_preferred = ",;\t.:|"; public $auto_preferred = ",;\t.:|";
# character encoding options # character encoding options
var $convert_encoding = false; public $convert_encoding = false;
var $input_encoding = 'ISO-8859-1'; public $input_encoding = 'ISO-8859-1';
var $output_encoding = 'ISO-8859-1'; public $output_encoding = 'ISO-8859-1';
# used by unparse(), save(), and output() functions # used by unparse(), save(), and output() functions
var $linefeed = "\r\n"; public $linefeed = "\r\n";
# only used by output() function # only used by output() function
var $output_delimiter = ','; public $output_delimiter = ',';
var $output_filename = 'data.csv'; public $output_filename = 'data.csv';
# keep raw file data in memory after successful parsing (useful for debugging) # keep raw file data in memory after successful parsing (useful for debugging)
var $keep_file_data = false; public $keep_file_data = false;
/** /**
* Internal variables * Internal variables
*/ */
# current file # current file
var $file; public $file;
# loaded file contents # loaded file contents
var $file_data; public $file_data;
# error while parsing input data # error while parsing input data
# 0 = No errors found. Everything should be fine :) # 0 = No errors found. Everything should be fine :)
@@ -161,16 +161,16 @@ class parseCSV {
# the file is either corrupt, or does not # the file is either corrupt, or does not
# standard CSV formatting. Please validate # standard CSV formatting. Please validate
# the parsed data yourself. # the parsed data yourself.
var $error = 0; public $error = 0;
# detailed error info # detailed error info
var $error_info = array(); public $error_info = array();
# array of field values in data parsed # array of field values in data parsed
var $titles = array(); public $titles = array();
# two dimentional array of CSV data # two dimentional array of CSV data
var $data = array(); public $data = array();
/** /**