Rules¶
Proxy¶
-
class
dlkit.proxy.rules.
Proxy
¶ Bases:
dlkit.osid.rules.OsidResult
A
Proxy
is used to transfer external information from an application server into an OSID Provider.-
has_authentication
()¶ Tests if an authentication is available.
Returns: true
if anAuthentication
is available,false
otherwiseReturn type: boolean
compliance: mandatory – This method must be implemented.
-
authentication
¶ Gets the
Authentication
for this proxy.Returns: the authentication Return type: osid.authentication.process.Authentication
Raise: IllegalState
–has_authentication()
isfalse
compliance: mandatory – This method must be implemented.
-
has_effective_agent
()¶ Tests if an effective agent is available.
Returns: true
if an effective agent is available,false
otherwiseReturn type: boolean
compliance: mandatory – This method must be implemented.
-
effective_agent_id
¶ Gets the effective
Agent Id
for this proxy.Returns: the effective agent Id
Return type: osid.id.Id
Raise: IllegalState
–has_effective_agent()
isfalse
compliance: mandatory – This method must be implemented.
-
effective_agent
¶ Gets the effective
Agent
for this proxy.Returns: the effective agent Return type: osid.authentication.Agent
Raise: IllegalState
–has_effective_agent()
isfalse
Raise: OperationFailed
– unable to complete requestcompliance: mandatory – This method must be implemented.
-
has_effective_date
()¶ Tests if an effective date is available.
Returns: true
if an effective date is available,false
otherwiseReturn type: boolean
compliance: mandatory – This method must be implemented.
-
effective_date
¶ Gets the effective date.
Returns: the effective date Return type: timestamp
Raise: IllegalState
–has_effective_date()
isfalse
compliance: mandatory – This method must be implemented.
-
effective_clock_rate
¶ Gets the rate of the clock.
Returns: the rate Return type: decimal
Raise: IllegalState
–has_effective_date()
isfalse
compliance: mandatory – This method must be implemented.
-
locale
¶ Gets the locale.
Returns: a locale Return type: osid.locale.Locale
compliance: mandatory – This method must be implemented.
-
has_format_type
()¶ Tests if a
DisplayText
formatType
is available.Returns: true
if a format type is available,false
otherwiseReturn type: boolean
compliance: mandatory – This method must be implemented.
-
format_type
¶ Gets the
DisplayText
formatType
.Returns: the format Type
Return type: osid.type.Type
Raise: IllegalState
–has_format_type()
isfalse
compliance: mandatory – This method must be implemented.
-
get_proxy_record
(proxy_record_type)¶ Gets the proxy record corresponding to the given
Proxy
recordType
.This method is used to retrieve an object implementing the requested record. The
proxy_record_type
may be theType
returned inget_record_types()
or any of its parents in aType
hierarchy wherehas_record_type(proxy_record_type)
istrue
.Parameters: proxy_record_type ( osid.type.Type
) – the type of proxy record to retrieveReturns: the proxy record Return type: osid.proxy.records.ProxyRecord
Raise: NullArgument
–proxy_record_type
isnull
Raise: OperationFailed
– unable to complete requestRaise: Unsupported
–has_record_type(proxy_record_type)
isfalse
compliance: mandatory – This method must be implemented.
-
Proxy Condition¶
-
class
dlkit.proxy.rules.
ProxyCondition
¶ Bases:
dlkit.osid.rules.OsidCondition
A
ProxyCondition
is used to transfer external information into a proxy.-
effective_agent_id
¶
-
set_effective_date
(date, rate)¶ Sets the effective date.
Parameters: - date (
timestamp
) – a date - rate (
decimal
) – the rate at which the clock should tick from the given effective date. 0 is a clock that is fixed
Raise: NullArgument
–date
isnull
compliance: mandatory – This method must be implemented.
- date (
-
language_type
¶
-
script_type
¶
-
calendar_type
¶
-
time_type
¶
-
currency_type
¶
-
unit_system_type
¶
-
format_type
¶
-
get_proxy_condition_record
(proxy_condition_type)¶ Gets the proxy condition record corresponding to the given
Proxy
recordType
.This method is used to retrieve an object implementing the requested record. The
proxy_record_type
may be theType
returned inget_record_types()
or any of its parents in aType
hierarchy wherehas_record_type(proxy_record_type)
istrue
.Parameters: proxy_condition_type ( osid.type.Type
) – the type of proxy condition record to retrieveReturns: the proxy condition record Return type: osid.proxy.records.ProxyConditionRecord
Raise: NullArgument
–proxy_condition_record_type
isnull
Raise: OperationFailed
– unable to complete requestRaise: Unsupported
–has_record_type(proxy_condition_record_type)
isfalse
compliance: mandatory – This method must be implemented.
-