GNU
|
Liberty Eiffel
|
Automated Tests
|
Wiki
|
Savannah project
|
Debian packages
|
Documentation
>
libraries
>
CGI_COOKIE
+
Point of view
ANY
ANY
INTERNALS_HANDLER
TYPED_INTERNALS
CGI_COOKIE_JAR
All features
class CGI_COOKIE
Summary
top
Direct parents
Insert list:
CGI_UTILS
Class invariant
top
is_token
(
name
)
value
/= Void implies
is_valid_value
(
value
)
path
/= Void implies
is_valid_cookie_path
(
path
)
domain
/= Void implies
is_valid_domain
(
domain
)
expires
/= Void implies
expires
.item.is_universal_time
expires
/= Void implies
max_age
= Void
max_age
/= Void implies
max_age
.item >= 0
max_age
/= Void implies
expires
= Void
Overview
top
Creation features
make
(a_name:
ABSTRACT_STRING
)
Exported features
name
:
FIXED_STRING
value
:
ABSTRACT_STRING
expires
:
REFERENCE
[
TIME
]
max_age
:
REFERENCE
[
INTEGER_32
]
domain
:
ABSTRACT_STRING
path
:
ABSTRACT_STRING
secure
:
BOOLEAN
http_only
:
BOOLEAN
set_value
(a_value:
ABSTRACT_STRING
) assign
value
set_expires
(a_expires:
TIME
) assign
expires
unset_expires
set_max_age
(a_max_age:
INTEGER_32
) assign
max_age
unset_max_age
set_domain
(a_domain:
ABSTRACT_STRING
) assign
domain
set_path
(a_path:
ABSTRACT_STRING
) assign
path
set_secure
(enable:
BOOLEAN
) assign
secure
set_http_only
(enable:
BOOLEAN
) assign
http_only
is_valid_value
(a_value:
ABSTRACT_STRING
):
BOOLEAN
is_valid_cookie_path
(a_path:
ABSTRACT_STRING
):
BOOLEAN
is_valid_domain
(a_domain:
ABSTRACT_STRING
):
BOOLEAN
checks
is_token
(value:
ABSTRACT_STRING
):
BOOLEAN
is_separators
(value:
ABSTRACT_STRING
):
BOOLEAN
is_valid_path
(a_path:
ABSTRACT_STRING
):
BOOLEAN
constants
crlf
:
FIXED_STRING
CRLF, the standard Web end-of-line
name
:
FIXED_STRING
writable attribute
top
value
:
ABSTRACT_STRING
writable attribute
top
expires
:
REFERENCE
[
TIME
]
writable attribute
top
max_age
:
REFERENCE
[
INTEGER_32
]
writable attribute
top
domain
:
ABSTRACT_STRING
writable attribute
top
path
:
ABSTRACT_STRING
writable attribute
top
secure
:
BOOLEAN
writable attribute
top
http_only
:
BOOLEAN
writable attribute
top
set_value
(a_value:
ABSTRACT_STRING
) assign
value
effective procedure
top
require
a_value /= Void implies
is_valid_value
(a_value)
ensure
value
= a_value
set_expires
(a_expires:
TIME
) assign
expires
effective procedure
top
require
a_expires.is_universal_time
max_age
= Void
ensure
expires
.item.is_equal(a_expires)
unset_expires
effective procedure
top
ensure
expires
= Void
set_max_age
(a_max_age:
INTEGER_32
) assign
max_age
effective procedure
top
require
expires
= Void
a_max_age >= 0
ensure
max_age
.item = a_max_age
unset_max_age
effective procedure
top
ensure
max_age
= Void
set_domain
(a_domain:
ABSTRACT_STRING
) assign
domain
effective procedure
top
require
a_domain /= Void implies
is_valid_domain
(a_domain)
ensure
domain
= a_domain
set_path
(a_path:
ABSTRACT_STRING
) assign
path
effective procedure
top
require
a_path /= Void implies
is_valid_cookie_path
(a_path)
ensure
path
= a_path
set_secure
(enable:
BOOLEAN
) assign
secure
effective procedure
top
ensure
secure
= enable
set_http_only
(enable:
BOOLEAN
) assign
http_only
effective procedure
top
ensure
http_only
= enable
is_valid_value
(a_value:
ABSTRACT_STRING
):
BOOLEAN
effective function
top
require
a_value /= Void
is_valid_cookie_path
(a_path:
ABSTRACT_STRING
):
BOOLEAN
effective function
top
require
a_path /= Void
is_valid_domain
(a_domain:
ABSTRACT_STRING
):
BOOLEAN
effective function
top
require
a_domain /= Void
is_token
(value:
ABSTRACT_STRING
):
BOOLEAN
effective function
top
require
value /= Void
is_separators
(value:
ABSTRACT_STRING
):
BOOLEAN
effective function
top
require
value /= Void
is_valid_path
(a_path:
ABSTRACT_STRING
):
BOOLEAN
effective function
top
crlf
:
FIXED_STRING
effective function
top
CRLF, the standard Web end-of-line