ILIAS
Release_4_0_x_branch Revision 61816
◀ ilDoc Overview
Main Page
Related Pages
Modules
Namespaces
Data Structures
Files
Examples
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Groups
Pages
SeqRollupRule.php
Go to the documentation of this file.
1
<?php
2
/*
3
+-----------------------------------------------------------------------------+
4
| ILIAS open source |
5
+-----------------------------------------------------------------------------+
6
| Copyright (c) 1998-2007 ILIAS open source, University of Cologne |
7
| |
8
| This program is free software; you can redistribute it and/or |
9
| modify it under the terms of the GNU General Public License |
10
| as published by the Free Software Foundation; either version 2 |
11
| of the License, or (at your option) any later version. |
12
| |
13
| This program is distributed in the hope that it will be useful, |
14
| but WITHOUT ANY WARRANTY; without even the implied warranty of |
15
| MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
16
| GNU General Public License for more details. |
17
| |
18
| You should have received a copy of the GNU General Public License |
19
| along with this program; if not, write to the Free Software |
20
| Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
21
+-----------------------------------------------------------------------------+
22
*/
23
/*
24
PHP port of ADL SeqRollupRule.java
25
@author Hendrik Holtmann <holtmann@mac.com>
26
27
This .php file is GPL licensed (see above) but based on
28
SeqRollupRule.java by ADL Co-Lab, which is licensed as:
29
30
Advanced Distributed Learning Co-Laboratory (ADL Co-Lab) Hub grants you
31
("Licensee") a non-exclusive, royalty free, license to use, modify and
32
redistribute this software in source and binary code form, provided that
33
i) this copyright notice and license appear on all copies of the software;
34
and ii) Licensee does not utilize the software in a manner which is
35
disparaging to ADL Co-Lab Hub.
36
37
This software is provided "AS IS," without a warranty of any kind. ALL
38
EXPRESS OR IMPLIED CONDITIONS, REPRESENTATIONS AND WARRANTIES, INCLUDING
39
ANY IMPLIED WARRANTY OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE
40
OR NON-INFRINGEMENT, ARE HEREBY EXCLUDED. ADL Co-Lab Hub AND ITS LICENSORS
41
SHALL NOT BE LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE AS A RESULT OF
42
USING, MODIFYING OR DISTRIBUTING THE SOFTWARE OR ITS DERIVATIVES. IN NO
43
EVENT WILL ADL Co-Lab Hub OR ITS LICENSORS BE LIABLE FOR ANY LOST REVENUE,
44
PROFIT OR DATA, OR FOR DIRECT, INDIRECT, SPECIAL, CONSEQUENTIAL,
45
INCIDENTAL OR PUNITIVE DAMAGES, HOWEVER CAUSED AND REGARDLESS OF THE
46
THEORY OF LIABILITY, ARISING OUT OF THE USE OF OR INABILITY TO USE
47
SOFTWARE, EVEN IF ADL Co-Lab Hub HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
48
DAMAGES.
49
*/
50
51
52
define(
"ROLLUP_ACTION_NOCHANGE"
,0);
53
define(
"ROLLUP_ACTION_SATISFIED"
,1);
54
define(
"ROLLUP_ACTION_NOTSATISFIED"
,2);
55
define(
"ROLLUP_ACTION_COMPLETED"
,3);
56
define(
"ROLLUP_ACTION_INCOMPLETE"
,4);
57
58
define(
"ROLLUP_CONSIDER_ALWAYS"
,
"always"
);
59
define(
"ROLLUP_CONSIDER_ATTEMPTED"
,
"ifAttempted"
);
60
define(
"ROLLUP_CONSIDER_NOTSKIPPED"
,
"ifNotSkipped"
);
61
define(
"ROLLUP_CONSIDER_NOTSUSPENDED"
,
"ifNotSuspended"
);
62
63
define(
"ROLLUP_SET_ALL"
,
"all"
);
64
define(
"ROLLUP_SET_ANY"
,
"any"
);
65
define(
"ROLLUP_SET_NONE"
,
"none"
);
66
define(
"ROLLUP_SET_ATLEASTCOUNT"
,
"atLeastCount"
);
67
define(
"ROLLUP_SET_ATLEASTPERCENT"
,
"atLeastPercent"
);
68
69
class
SeqRollupRule
{
70
71
public
$mAction
=
ROLLUP_ACTION_SATISFIED
;
72
73
public
$mChildActivitySet
=
ROLLUP_SET_ALL
;
74
75
public
$mMinCount
= 0;
76
77
public
$mMinPercent
= 0.0;
78
79
public
$mConditions
= null;
80
81
public
function
__construct
() {
82
//$this->mRules=$iRules;
83
}
84
85
public
function
setRollupAction
($iAction) {
86
if
( $iAction ==
"satisfied"
)
87
{
88
$this->mAction =
ROLLUP_ACTION_SATISFIED
;
89
}
90
else
if
( $iAction==
"notSatisfied"
)
91
{
92
$this->mAction =
ROLLUP_ACTION_NOTSATISFIED
;
93
}
94
else
if
( $iAction==
"completed"
)
95
{
96
$this->mAction =
ROLLUP_ACTION_COMPLETED
;
97
}
98
else
if
( $iAction==
"incomplete"
)
99
{
100
$this->mAction =
ROLLUP_ACTION_INCOMPLETE
;
101
}
102
}
103
104
}
105
106
?>
Modules
Scorm2004
classes
adlparser
SeqRollupRule.php
Generated on Wed Apr 27 2016 19:01:22 for ILIAS by
1.8.1.2 (using
Doxyfile
)