OSID Logo
OSID Specifications
resource demographic package
Version 3.0.0
Release Candidate Preview
Interfaceosid.resource.demographic.DemographicEnablerRuleApplicationSession
Implementsosid.OsidSession
Description

This session provides methods to apply DemographicEnablers to Demographics. A Demographic with multiple DemographicEnablers means any positive rule evaluation across the enablers result in an effective Demographic.

MethodgetBinId
Description

Gets the Bin Id associated with this session.

Returnosid.id.Idthe Bin Id associated with this session
CompliancemandatoryThis method must be implemented.
MethodgetBin
Description

Gets the Bin associated with this session.

Returnosid.resource.Binthe bin
ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodcanAssignDemographicEnablers
Description

Tests if this user can alter demographic enabler/demographic mappings. A return of true does not guarantee successful authorization. A return of false indicates that it is known mapping methods in this session will result in a PERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer lookup operations to unauthorized users.

Returnboolean false if mapping is not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethodassignDemographicEnablerToDemographic
Description

Adds an existing DemographicEnabler to a Demographic.

Parametersosid.id.IddemographicEnablerIdthe Id of the DemographicEnabler
osid.id.IddemographicIdthe Id of the Demographic
ErrorsALREADY_EXISTS demographicEnablerId is already assigned to demographicId
NOT_FOUND demographicEnablerId or demographicId not found
NULL_ARGUMENT demographicEnablerId or demographicId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodunassignDemographicEnablerFromDemographic
Description

Removes a DemographicEnabler from a Demographic.

Parametersosid.id.IddemographicEnablerIdthe Id of the DemographicEnabler
osid.id.IddemographicIdthe Id of the Demographic
ErrorsNOT_FOUND demographicEnablerId or demographicId not found or not mapped
NULL_ARGUMENT demographicEnablerId or demographicId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.