ILIAS
release_8 Revision v8.19
◀ ilDoc Overview
Main Page
Related Pages
Modules
+
Namespaces
Namespace List
+
Namespace Members
+
All
$
_
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
r
s
t
u
v
w
x
+
Functions
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
x
+
Variables
$
a
b
c
d
e
f
g
h
j
l
m
p
s
t
u
+
Data Structures
Data Structures
Data Structure Index
Class Hierarchy
+
Data Fields
+
All
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Ö
+
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Variables
$
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Ö
+
Files
File List
+
Globals
+
All
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
x
z
+
Functions
_
a
b
c
d
e
g
h
i
m
n
p
r
s
t
u
v
x
+
Variables
$
a
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
z
Examples
•
All
Data Structures
Namespaces
Files
Functions
Variables
Modules
Pages
class.ilObjFileInfo.php
Go to the documentation of this file.
1
<?php
2
19
use
ILIAS\DI\Container
;
20
use
ILIAS\Filesystem\Stream\FileStream
;
21
use
ILIAS\FileUpload\DTO\UploadResult
;
22
use
ILIAS\FileUpload\FileUpload
;
23
use
ILIAS\ResourceStorage\Manager\Manager
;
24
use
ILIAS\ResourceStorage\Revision\Revision
;
25
use
ILIAS\ResourceStorage\Policy\FileNamePolicyException
;
26
use
ILIAS\Data\DataSize
;
27
31
class
ilObjFileInfo
32
{
33
use
ilObjFileSecureString
;
34
35
private
string
$title
;
36
protected
string
$file_name
;
37
protected
string
$suffix
;
38
protected
bool
$deliver_inline
;
39
protected
bool
$download_directly
;
40
protected
int
$version
;
41
protected
DateTimeImmutable
$creation_date
;
42
protected
bool
$is_zip
;
43
protected
string
$mime_type
;
44
protected
DataSize
$file_size
;
45
protected
?
int
$page_count
;
46
47
public
function
__construct
(
48
string
$title,
49
string
$file_name,
50
string
$suffix,
51
bool
$deliver_inline,
52
bool
$download_directly,
53
int
$version,
54
DateTimeImmutable
$creation_date,
55
bool
$is_zip,
56
string
$mime_type,
57
DataSize
$file_size,
58
?
int
$page_count
59
) {
60
$this->title =
$title
;
61
$this->file_name =
$file_name
;
62
$this->suffix =
$suffix
;
63
$this->deliver_inline =
$deliver_inline
;
64
$this->download_directly =
$download_directly
;
65
$this->version =
$version
;
66
$this->creation_date =
$creation_date
;
67
$this->is_zip =
$is_zip
;
68
$this->mime_type =
$mime_type
;
69
$this->file_size =
$file_size
;
70
$this->page_count =
$page_count
;
71
}
72
73
public
function
getFileName
(): string
74
{
75
return
$this->file_name
;
76
}
77
78
public
function
getListTitle
(): string
79
{
80
return
$this->
stripSuffix
($this->title, $this->
getSuffix
());
81
}
82
83
public
function
getHeaderTitle
(): string
84
{
85
return
$this->
ensureSuffix
($this->title, $this->
getSuffix
());
86
}
87
88
public
function
getSuffix
(): string
89
{
90
return
$this->suffix
;
91
}
92
93
public
function
shouldDeliverInline
(): bool
94
{
95
return
$this->deliver_inline
;
96
}
97
98
public
function
shouldDownloadDirectly
(): bool
99
{
100
return
$this->download_directly
;
101
}
102
103
public
function
getVersion
():
int
104
{
105
return
$this->version
;
106
}
107
108
public
function
getCreationDate
():
DateTimeImmutable
109
{
110
return
$this->creation_date
;
111
}
112
113
public
function
isZip
(): bool
114
{
115
return
$this->is_zip
;
116
}
117
118
public
function
getMimeType
(): string
119
{
120
return
$this->mime_type
;
121
}
122
123
public
function
getFileSize
():
DataSize
124
{
125
return
$this->file_size
;
126
}
127
128
public
function
getPageCount
(): ?
int
129
{
130
return
$this->page_count
;
131
}
132
133
}
ilObjFileInfo\getCreationDate
getCreationDate()
Definition:
class.ilObjFileInfo.php:108
ilObjFileInfo\$suffix
string $suffix
Definition:
class.ilObjFileInfo.php:37
ilObjFileInfo\getFileSize
getFileSize()
Definition:
class.ilObjFileInfo.php:123
DateTimeImmutable
ilObjFileInfo\getSuffix
getSuffix()
Definition:
class.ilObjFileInfo.php:88
ilObjFileInfo\isZip
isZip()
Definition:
class.ilObjFileInfo.php:113
DataSize
ILIAS\Data\DataSize
This class provides the data size with additional information to remove the work to calculate the siz...
Definition:
DataSize.php:30
ilObjFileInfo\$deliver_inline
bool $deliver_inline
Definition:
class.ilObjFileInfo.php:38
Revision
ilObjFileInfo\$creation_date
DateTimeImmutable $creation_date
Definition:
class.ilObjFileInfo.php:41
Container
ilObjFileInfo\$version
int $version
Definition:
class.ilObjFileInfo.php:40
ilObjFileInfo\getVersion
getVersion()
Definition:
class.ilObjFileInfo.php:103
ilObjFileInfo\getMimeType
getMimeType()
Definition:
class.ilObjFileInfo.php:118
FileNamePolicyException
ilObjFileInfo\shouldDeliverInline
shouldDeliverInline()
Definition:
class.ilObjFileInfo.php:93
ilObjFileInfo\getFileName
getFileName()
Definition:
class.ilObjFileInfo.php:73
Manager
ilObjFileInfo\getPageCount
getPageCount()
Definition:
class.ilObjFileInfo.php:128
ilObjFileInfo
Definition:
class.ilObjFileInfo.php:31
stripSuffix
stripSuffix(string $title, ?string $suffix=null)
Definition:
trait.ilObjFileSecureString.php:37
ilObjFileSecureString
trait ilObjFileSecureString
Trait ilObjFileSecureString.
Definition:
trait.ilObjFileSecureString.php:26
ilObjFileInfo\$download_directly
bool $download_directly
Definition:
class.ilObjFileInfo.php:39
ilObjFileInfo\shouldDownloadDirectly
shouldDownloadDirectly()
Definition:
class.ilObjFileInfo.php:98
ilObjFileInfo\$mime_type
string $mime_type
Definition:
class.ilObjFileInfo.php:43
ilObjFileInfo\$title
string $title
Definition:
class.ilObjFileInfo.php:35
ilObjFileInfo\getHeaderTitle
getHeaderTitle()
Definition:
class.ilObjFileInfo.php:83
FileStream
ilObjFileInfo\__construct
__construct(string $title, string $file_name, string $suffix, bool $deliver_inline, bool $download_directly, int $version, DateTimeImmutable $creation_date, bool $is_zip, string $mime_type, DataSize $file_size, ?int $page_count)
Definition:
class.ilObjFileInfo.php:47
ilObjFileInfo\$file_size
DataSize $file_size
Definition:
class.ilObjFileInfo.php:44
ilObjFileInfo\getListTitle
getListTitle()
Definition:
class.ilObjFileInfo.php:78
ilObjFileInfo\$file_name
string $file_name
Definition:
class.ilObjFileInfo.php:36
ilObjFileInfo\$is_zip
bool $is_zip
Definition:
class.ilObjFileInfo.php:42
ILIAS\Repository\int
int(string $key)
Definition:
trait.BaseGUIRequest.php:61
UploadResult
ilObjFileInfo\$page_count
int $page_count
Definition:
class.ilObjFileInfo.php:45
ensureSuffix
ensureSuffix(string $title, ?string $suffix=null)
Definition:
trait.ilObjFileSecureString.php:48
FileUpload
Modules
File
classes
Info
class.ilObjFileInfo.php
Generated on Tue Apr 1 2025 22:01:27 for ILIAS by
1.8.13 (using
Doxyfile
)