Completed
Push — master ( 50fc26...8a9369 )
by Paul
04:36
created

absences_RightExportCsv   A

Complexity

Total Complexity 6

Size/Duplication

Total Lines 74
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 1
Bugs 0 Features 1
Metric Value
wmc 6
c 1
b 0
f 1
lcom 0
cbo 1
dl 0
loc 74
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 19 4
A selectAgents() 0 4 1
A download() 0 4 1
1
<?php
2
/************************************************************************
3
 * OVIDENTIA http://www.ovidentia.org                                   *
4
 ************************************************************************
5
 * Copyright (c) 2003 by CANTICO ( http://www.cantico.fr )              *
6
 *                                                                      *
7
 * This file is part of Ovidentia.                                      *
8
 *                                                                      *
9
 * Ovidentia is free software; you can redistribute it and/or modify    *
10
 * it under the terms of the GNU General Public License as published by *
11
 * the Free Software Foundation; either version 2, or (at your option)  *
12
 * any later version.													*
13
 *																		*
14
 * This program is distributed in the hope that it will be useful, but  *
15
 * WITHOUT ANY WARRANTY; without even the implied warranty of			*
16
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.					*
17
 * See the  GNU General Public License for more details.				*
18
 *																		*
19
 * You should have received a copy of the GNU General Public License	*
20
 * along with this program; if not, write to the Free Software			*
21
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,*
22
 * USA.																	*
23
************************************************************************/
24
25
26
27
/**
28
 * Export all rights or year rights for each agents on a list of agents
29
 *
30
 */
31
class absences_RightExportCsv
32
{
33
    
34
    /**
35
     * 
36
     * @var int
37
     */
38
    protected $org;
39
    
40
    /**
41
     * 
42
     * @var int
43
     */
44
    protected $year;
45
    
46
    
47
    /**
48
     * 
49
     * @var string
50
     */
51
    protected $separator = ',';
52
    
53
    /**
54
     * 
55
     * @var string
56
     */
57
    protected $decsep = '.';
58
    
59
    /**
60
     * 
61
     * @var string
62
     */
63
    protected $outputCharset = null;
64
    
65
    /**
66
     * @param int    $org
67
     * @param int    $year
68
     * 
69
     */
70
    public function __construct($org, $year, $separator = null, $decsep = null, $outputCharset = null)
71
    {
72
        $this->org = $org;
73
        $this->year = $year;
74
        
75
        if (isset($separator)) {
76
            $this->separator = $separator;
77
        }
78
        
79
        if (isset($decsep)) {
80
            $this->decsep = $decsep;
81
        }
82
        
83
        $this->outputCharset = bab_Charset::getIso();
84
        
85
        if (isset($outputCharset)) {
86
            $this->outputCharset = $outputCharset;
87
        }
88
    }
89
    
90
    
91
    /**
92
     * @return absences_
93
     */
94
    protected function selectAgents()
95
    {
96
        
97
    }
98
    
99
    
100
    public function download()
101
    {
102
        
103
    }
104
}