| 1 | |
package org.kuali.student.enrollment.class2.courseregistration.service.decorators; |
| 2 | |
|
| 3 | |
import java.util.List; |
| 4 | |
|
| 5 | |
import org.kuali.rice.core.api.criteria.QueryByCriteria; |
| 6 | |
|
| 7 | |
import org.kuali.rice.kim.api.permission.PermissionService; |
| 8 | |
import org.kuali.student.enrollment.courseoffering.dto.RegistrationGroupInfo; |
| 9 | |
import org.kuali.student.enrollment.courseregistration.dto.ActivityRegistrationInfo; |
| 10 | |
import org.kuali.student.enrollment.courseregistration.dto.CourseRegistrationInfo; |
| 11 | |
import org.kuali.student.enrollment.courseregistration.dto.RegGroupRegistrationInfo; |
| 12 | |
import org.kuali.student.enrollment.courseregistration.dto.RegRequestInfo; |
| 13 | |
import org.kuali.student.enrollment.courseregistration.dto.RegResponseInfo; |
| 14 | |
import org.kuali.student.enrollment.courseregistration.service.CourseRegistrationServiceDecorator; |
| 15 | |
import org.kuali.student.enrollment.coursewaitlist.dto.CourseWaitlistEntryInfo; |
| 16 | |
import org.kuali.student.enrollment.grading.dto.LoadInfo; |
| 17 | |
import org.kuali.student.r2.common.dto.ContextInfo; |
| 18 | |
import org.kuali.student.r2.common.dto.DateRangeInfo; |
| 19 | |
import org.kuali.student.r2.common.dto.StatusInfo; |
| 20 | |
import org.kuali.student.r2.common.dto.ValidationResultInfo; |
| 21 | |
import org.kuali.student.r2.common.exceptions.AlreadyExistsException; |
| 22 | |
import org.kuali.student.r2.common.exceptions.DataValidationErrorException; |
| 23 | |
import org.kuali.student.r2.common.exceptions.DisabledIdentifierException; |
| 24 | |
import org.kuali.student.r2.common.exceptions.DoesNotExistException; |
| 25 | |
import org.kuali.student.r2.common.exceptions.InvalidParameterException; |
| 26 | |
import org.kuali.student.r2.common.exceptions.MissingParameterException; |
| 27 | |
import org.kuali.student.r2.common.exceptions.OperationFailedException; |
| 28 | |
import org.kuali.student.r2.common.exceptions.PermissionDeniedException; |
| 29 | |
import org.kuali.student.r2.common.exceptions.VersionMismatchException; |
| 30 | |
import org.kuali.student.r2.common.infc.HoldsPermissionService; |
| 31 | |
|
| 32 | 0 | public class CourseRegistrationServiceAuthorizationDecorator extends CourseRegistrationServiceDecorator implements HoldsPermissionService{ |
| 33 | |
public static final String ENRLLMENT_NAMESPACE = "KS-ENROLL"; |
| 34 | |
public static final String SERVICE_NAME = "CourseRegistrationService."; |
| 35 | |
|
| 36 | |
private PermissionService permissionService; |
| 37 | |
|
| 38 | |
@Override |
| 39 | |
public PermissionService getPermissionService() { |
| 40 | 0 | return permissionService; |
| 41 | |
} |
| 42 | |
|
| 43 | |
@Override |
| 44 | |
public void setPermissionService(PermissionService permissionService) { |
| 45 | 0 | this.permissionService = permissionService; |
| 46 | 0 | } |
| 47 | |
|
| 48 | |
@Override |
| 49 | |
public List<ValidationResultInfo> checkStudentEligibility(String studentId, ContextInfo context) |
| 50 | |
throws DoesNotExistException, InvalidParameterException, |
| 51 | |
MissingParameterException, OperationFailedException, |
| 52 | |
PermissionDeniedException { |
| 53 | 0 | if (null == context) { |
| 54 | 0 | throw new MissingParameterException(); |
| 55 | |
} |
| 56 | |
|
| 57 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "checkStudentEligibility", null)) { |
| 58 | 0 | return getNextDecorator().checkStudentEligibility(studentId, context); |
| 59 | |
} |
| 60 | |
else { |
| 61 | 0 | throw new PermissionDeniedException(); |
| 62 | |
} |
| 63 | |
} |
| 64 | |
|
| 65 | |
@Override |
| 66 | |
public List<ValidationResultInfo> checkStudentEligibilityForTerm( |
| 67 | |
String studentId, String termId, ContextInfo context) |
| 68 | |
throws InvalidParameterException, MissingParameterException, |
| 69 | |
OperationFailedException, PermissionDeniedException { |
| 70 | 0 | if (null == context) { |
| 71 | 0 | throw new MissingParameterException(); |
| 72 | |
} |
| 73 | |
|
| 74 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "checkStudentEligibilityForTerm", null)) { |
| 75 | 0 | return getNextDecorator().checkStudentEligibilityForTerm(studentId, termId, context); |
| 76 | |
} |
| 77 | |
else { |
| 78 | 0 | throw new PermissionDeniedException(); |
| 79 | |
} |
| 80 | |
} |
| 81 | |
|
| 82 | |
@Override |
| 83 | |
public List<DateRangeInfo> getAppointmentWindows(String studentId, |
| 84 | |
String termId, ContextInfo context) |
| 85 | |
throws InvalidParameterException, MissingParameterException, |
| 86 | |
OperationFailedException, PermissionDeniedException { |
| 87 | 0 | if (null == context) { |
| 88 | 0 | throw new MissingParameterException(); |
| 89 | |
} |
| 90 | |
|
| 91 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getAppointmentWindows", null)) { |
| 92 | 0 | return getNextDecorator().getAppointmentWindows(studentId, termId, context); |
| 93 | |
} |
| 94 | |
else { |
| 95 | 0 | throw new PermissionDeniedException(); |
| 96 | |
} |
| 97 | |
} |
| 98 | |
|
| 99 | |
@Override |
| 100 | |
public List<ValidationResultInfo> checkStudentEligibiltyForCourseOffering( |
| 101 | |
String studentId, String courseOfferingId, ContextInfo context) |
| 102 | |
throws InvalidParameterException, MissingParameterException, |
| 103 | |
OperationFailedException, PermissionDeniedException { |
| 104 | 0 | if (null == context) { |
| 105 | 0 | throw new MissingParameterException(); |
| 106 | |
} |
| 107 | |
|
| 108 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "checkStudentEligibiltyForCourseOffering", null)) { |
| 109 | 0 | return getNextDecorator().checkStudentEligibiltyForCourseOffering(studentId, courseOfferingId, context); |
| 110 | |
} |
| 111 | |
else { |
| 112 | 0 | throw new PermissionDeniedException(); |
| 113 | |
} |
| 114 | |
} |
| 115 | |
|
| 116 | |
@Override |
| 117 | |
public List<ValidationResultInfo> checkStudentEligibiltyForRegGroup( |
| 118 | |
String studentId, String regGroupId, ContextInfo context) |
| 119 | |
throws InvalidParameterException, MissingParameterException, |
| 120 | |
OperationFailedException, PermissionDeniedException { |
| 121 | 0 | if (null == context) { |
| 122 | 0 | throw new MissingParameterException(); |
| 123 | |
} |
| 124 | |
|
| 125 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "checkStudentEligibiltyForRegGroup", null)) { |
| 126 | 0 | return getNextDecorator().checkStudentEligibiltyForRegGroup(studentId, regGroupId, context); |
| 127 | |
} |
| 128 | |
else { |
| 129 | 0 | throw new PermissionDeniedException(); |
| 130 | |
} |
| 131 | |
} |
| 132 | |
|
| 133 | |
@Override |
| 134 | |
public List<RegistrationGroupInfo> getEligibleRegGroupsForStudentInCourseOffering( |
| 135 | |
String studentId, String courseOfferingId, ContextInfo context) |
| 136 | |
throws InvalidParameterException, MissingParameterException, |
| 137 | |
OperationFailedException, PermissionDeniedException { |
| 138 | 0 | if (null == context) { |
| 139 | 0 | throw new MissingParameterException(); |
| 140 | |
} |
| 141 | |
|
| 142 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getEligibleRegGroupsForStudentInCourseOffering", null)) { |
| 143 | 0 | return getNextDecorator().getEligibleRegGroupsForStudentInCourseOffering(studentId, courseOfferingId, context); |
| 144 | |
} |
| 145 | |
else { |
| 146 | 0 | throw new PermissionDeniedException(); |
| 147 | |
} |
| 148 | |
} |
| 149 | |
|
| 150 | |
@Override |
| 151 | |
public LoadInfo calculateCreditLoadForTerm(String studentId, |
| 152 | |
String termId, ContextInfo context) |
| 153 | |
throws InvalidParameterException, MissingParameterException, |
| 154 | |
OperationFailedException, PermissionDeniedException { |
| 155 | 0 | if (null == context) { |
| 156 | 0 | throw new MissingParameterException(); |
| 157 | |
} |
| 158 | |
|
| 159 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "calculateCreditLoadForTerm", null)) { |
| 160 | 0 | return getNextDecorator().calculateCreditLoadForTerm(studentId, termId, context); |
| 161 | |
} |
| 162 | |
else { |
| 163 | 0 | throw new PermissionDeniedException(); |
| 164 | |
} |
| 165 | |
} |
| 166 | |
|
| 167 | |
@Override |
| 168 | |
public LoadInfo calculateCreditLoadForRegRequest(String studentId, |
| 169 | |
RegRequestInfo regRequestInfo, ContextInfo context) |
| 170 | |
throws InvalidParameterException, MissingParameterException, |
| 171 | |
OperationFailedException, PermissionDeniedException { |
| 172 | 0 | if (null == context) { |
| 173 | 0 | throw new MissingParameterException(); |
| 174 | |
} |
| 175 | |
|
| 176 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "calculateCreditLoadForRegRequest", null)) { |
| 177 | 0 | return getNextDecorator().calculateCreditLoadForRegRequest(studentId, regRequestInfo, context); |
| 178 | |
} |
| 179 | |
else { |
| 180 | 0 | throw new PermissionDeniedException(); |
| 181 | |
} |
| 182 | |
} |
| 183 | |
|
| 184 | |
@Override |
| 185 | |
public Integer getAvailableSeatsForCourseOffering(String courseOfferingId, |
| 186 | |
ContextInfo context) throws InvalidParameterException, |
| 187 | |
MissingParameterException, OperationFailedException, |
| 188 | |
PermissionDeniedException { |
| 189 | 0 | if (null == context) { |
| 190 | 0 | throw new MissingParameterException(); |
| 191 | |
} |
| 192 | |
|
| 193 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getAvailableSeatsForCourseOffering", null)) { |
| 194 | 0 | return getNextDecorator().getAvailableSeatsForCourseOffering(courseOfferingId, context); |
| 195 | |
} |
| 196 | |
else { |
| 197 | 0 | throw new PermissionDeniedException(); |
| 198 | |
} |
| 199 | |
} |
| 200 | |
|
| 201 | |
@Override |
| 202 | |
public Integer getAvailableSeatsForRegGroup(String regGroupId, |
| 203 | |
ContextInfo context) throws InvalidParameterException, |
| 204 | |
MissingParameterException, OperationFailedException, |
| 205 | |
PermissionDeniedException { |
| 206 | 0 | if (null == context) { |
| 207 | 0 | throw new MissingParameterException(); |
| 208 | |
} |
| 209 | |
|
| 210 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getAvailableSeatsForRegGroup", null)) { |
| 211 | 0 | return getNextDecorator().getAvailableSeatsForRegGroup(regGroupId, context); |
| 212 | |
} |
| 213 | |
else { |
| 214 | 0 | throw new PermissionDeniedException(); |
| 215 | |
} |
| 216 | |
} |
| 217 | |
|
| 218 | |
@Override |
| 219 | |
public Integer getAvailableSeatsForStudentInRegGroup(String studentId, |
| 220 | |
String regGroupId, ContextInfo context) |
| 221 | |
throws InvalidParameterException, MissingParameterException, |
| 222 | |
OperationFailedException, PermissionDeniedException { |
| 223 | 0 | if (null == context) { |
| 224 | 0 | throw new MissingParameterException(); |
| 225 | |
} |
| 226 | |
|
| 227 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getAvailableSeatsForStudentInRegGroup", null)) { |
| 228 | 0 | return getNextDecorator().getAvailableSeatsForStudentInRegGroup(studentId, regGroupId, context); |
| 229 | |
} |
| 230 | |
else { |
| 231 | 0 | throw new PermissionDeniedException(); |
| 232 | |
} |
| 233 | |
} |
| 234 | |
|
| 235 | |
@Override |
| 236 | |
public Integer getAvailableSeatsInSeatpool(String seatpoolId, |
| 237 | |
ContextInfo context) throws InvalidParameterException, |
| 238 | |
MissingParameterException, OperationFailedException, |
| 239 | |
PermissionDeniedException { |
| 240 | 0 | if (null == context) { |
| 241 | 0 | throw new MissingParameterException(); |
| 242 | |
} |
| 243 | |
|
| 244 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getAvailableSeatsInSeatpool", null)) { |
| 245 | 0 | return getNextDecorator().getAvailableSeatsInSeatpool(seatpoolId, context); |
| 246 | |
} |
| 247 | |
else { |
| 248 | 0 | throw new PermissionDeniedException(); |
| 249 | |
} |
| 250 | |
} |
| 251 | |
|
| 252 | |
@Override |
| 253 | |
public RegRequestInfo createRegRequest(RegRequestInfo regRequestInfo, |
| 254 | |
ContextInfo context) throws AlreadyExistsException, |
| 255 | |
DataValidationErrorException, InvalidParameterException, |
| 256 | |
MissingParameterException, OperationFailedException, |
| 257 | |
PermissionDeniedException { |
| 258 | 0 | if (null == context) { |
| 259 | 0 | throw new MissingParameterException(); |
| 260 | |
} |
| 261 | |
|
| 262 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "createRegRequest", null)) { |
| 263 | 0 | return getNextDecorator().createRegRequest(regRequestInfo, context); |
| 264 | |
} |
| 265 | |
else { |
| 266 | 0 | throw new PermissionDeniedException(); |
| 267 | |
} |
| 268 | |
} |
| 269 | |
|
| 270 | |
@Override |
| 271 | |
public RegRequestInfo updateRegRequest(String regRequestId, |
| 272 | |
RegRequestInfo regRequestInfo, ContextInfo context) |
| 273 | |
throws DataValidationErrorException, DoesNotExistException, |
| 274 | |
InvalidParameterException, MissingParameterException, |
| 275 | |
OperationFailedException, PermissionDeniedException, |
| 276 | |
VersionMismatchException { |
| 277 | 0 | if (null == context) { |
| 278 | 0 | throw new MissingParameterException(); |
| 279 | |
} |
| 280 | |
|
| 281 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "updateRegRequest", null)) { |
| 282 | 0 | return getNextDecorator().updateRegRequest(regRequestId, regRequestInfo, context); |
| 283 | |
} |
| 284 | |
else { |
| 285 | 0 | throw new PermissionDeniedException(); |
| 286 | |
} |
| 287 | |
} |
| 288 | |
|
| 289 | |
@Override |
| 290 | |
public StatusInfo deleteRegRequest(String regRequestId, ContextInfo context) |
| 291 | |
throws InvalidParameterException, MissingParameterException, |
| 292 | |
OperationFailedException, PermissionDeniedException, |
| 293 | |
DoesNotExistException { |
| 294 | 0 | if (null == context) { |
| 295 | 0 | throw new MissingParameterException(); |
| 296 | |
} |
| 297 | |
|
| 298 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "deleteRegRequest", null)) { |
| 299 | 0 | return getNextDecorator().deleteRegRequest(regRequestId, context); |
| 300 | |
} |
| 301 | |
else { |
| 302 | 0 | throw new PermissionDeniedException(); |
| 303 | |
} |
| 304 | |
} |
| 305 | |
|
| 306 | |
@Override |
| 307 | |
public List<ValidationResultInfo> validateRegRequest( |
| 308 | |
RegRequestInfo regRequestInfo, ContextInfo context) |
| 309 | |
throws DataValidationErrorException, InvalidParameterException, |
| 310 | |
MissingParameterException, OperationFailedException, |
| 311 | |
PermissionDeniedException { |
| 312 | 0 | if (null == context) { |
| 313 | 0 | throw new MissingParameterException(); |
| 314 | |
} |
| 315 | |
|
| 316 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "validateRegRequest", null)) { |
| 317 | 0 | return getNextDecorator().validateRegRequest(regRequestInfo, context); |
| 318 | |
} |
| 319 | |
else { |
| 320 | 0 | throw new PermissionDeniedException(); |
| 321 | |
} |
| 322 | |
} |
| 323 | |
|
| 324 | |
@Override |
| 325 | |
public List<ValidationResultInfo> verifyRegRequest( |
| 326 | |
RegRequestInfo regRequestInfo, ContextInfo context) |
| 327 | |
throws DataValidationErrorException, InvalidParameterException, |
| 328 | |
MissingParameterException, OperationFailedException, |
| 329 | |
PermissionDeniedException { |
| 330 | 0 | if (null == context) { |
| 331 | 0 | throw new MissingParameterException(); |
| 332 | |
} |
| 333 | |
|
| 334 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "verifyRegRequest", null)) { |
| 335 | 0 | return getNextDecorator().verifyRegRequest(regRequestInfo, context); |
| 336 | |
} |
| 337 | |
else { |
| 338 | 0 | throw new PermissionDeniedException(); |
| 339 | |
} |
| 340 | |
} |
| 341 | |
|
| 342 | |
@Override |
| 343 | |
public RegResponseInfo verifySavedReqRequest(String regRequestId, |
| 344 | |
ContextInfo context) throws DataValidationErrorException, |
| 345 | |
InvalidParameterException, MissingParameterException, |
| 346 | |
OperationFailedException, PermissionDeniedException { |
| 347 | 0 | if (null == context) { |
| 348 | 0 | throw new MissingParameterException(); |
| 349 | |
} |
| 350 | |
|
| 351 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "verifySavedReqRequest", null)) { |
| 352 | 0 | return getNextDecorator().verifySavedReqRequest(regRequestId, context); |
| 353 | |
} |
| 354 | |
else { |
| 355 | 0 | throw new PermissionDeniedException(); |
| 356 | |
} |
| 357 | |
} |
| 358 | |
|
| 359 | |
@Override |
| 360 | |
public RegRequestInfo createRegRequestFromExisting( |
| 361 | |
String existingRegRequestId, ContextInfo context) |
| 362 | |
throws InvalidParameterException, MissingParameterException, |
| 363 | |
OperationFailedException, PermissionDeniedException, |
| 364 | |
DoesNotExistException { |
| 365 | 0 | if (null == context) { |
| 366 | 0 | throw new MissingParameterException(); |
| 367 | |
} |
| 368 | |
|
| 369 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "createRegRequestFromExisting", null)) { |
| 370 | 0 | return getNextDecorator().createRegRequestFromExisting(existingRegRequestId, context); |
| 371 | |
} |
| 372 | |
else { |
| 373 | 0 | throw new PermissionDeniedException(); |
| 374 | |
} |
| 375 | |
} |
| 376 | |
|
| 377 | |
@Override |
| 378 | |
public RegResponseInfo submitRegRequest(String regRequestId, |
| 379 | |
ContextInfo context) throws DoesNotExistException, |
| 380 | |
InvalidParameterException, MissingParameterException, |
| 381 | |
OperationFailedException, PermissionDeniedException, |
| 382 | |
DataValidationErrorException, AlreadyExistsException { |
| 383 | 0 | if (null == context) { |
| 384 | 0 | throw new MissingParameterException(); |
| 385 | |
} |
| 386 | |
|
| 387 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "submitRegRequest", null)) { |
| 388 | 0 | return getNextDecorator().submitRegRequest(regRequestId, context); |
| 389 | |
} |
| 390 | |
else { |
| 391 | 0 | throw new PermissionDeniedException(); |
| 392 | |
} |
| 393 | |
} |
| 394 | |
|
| 395 | |
@Override |
| 396 | |
public RegResponseInfo dropStudentsFromRegGroups( |
| 397 | |
List<String> regGroupIds, ContextInfo context) |
| 398 | |
throws DoesNotExistException, InvalidParameterException, |
| 399 | |
MissingParameterException, OperationFailedException, |
| 400 | |
PermissionDeniedException { |
| 401 | 0 | if (null == context) { |
| 402 | 0 | throw new MissingParameterException(); |
| 403 | |
} |
| 404 | |
|
| 405 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "dropStudentsFromRegGroups", null)) { |
| 406 | 0 | return getNextDecorator().dropStudentsFromRegGroups(regGroupIds, context); |
| 407 | |
} |
| 408 | |
else { |
| 409 | 0 | throw new PermissionDeniedException(); |
| 410 | |
} |
| 411 | |
} |
| 412 | |
|
| 413 | |
@Override |
| 414 | |
public RegResponseInfo moveStudentsBetweenRegGroups( |
| 415 | |
String sourceRegGroupId, String destinationRegGroupId, |
| 416 | |
ContextInfo context) throws DoesNotExistException, |
| 417 | |
InvalidParameterException, MissingParameterException, |
| 418 | |
OperationFailedException, PermissionDeniedException { |
| 419 | 0 | if (null == context) { |
| 420 | 0 | throw new MissingParameterException(); |
| 421 | |
} |
| 422 | |
|
| 423 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "moveStudentsBetweenRegGroups", null)) { |
| 424 | 0 | return getNextDecorator().moveStudentsBetweenRegGroups(sourceRegGroupId, destinationRegGroupId, context); |
| 425 | |
} |
| 426 | |
else { |
| 427 | 0 | throw new PermissionDeniedException(); |
| 428 | |
} |
| 429 | |
} |
| 430 | |
|
| 431 | |
@Override |
| 432 | |
public StatusInfo cancelRegRequest(String regRequestId, ContextInfo context) |
| 433 | |
throws DataValidationErrorException, InvalidParameterException, |
| 434 | |
MissingParameterException, OperationFailedException, |
| 435 | |
PermissionDeniedException { |
| 436 | 0 | if (null == context) { |
| 437 | 0 | throw new MissingParameterException(); |
| 438 | |
} |
| 439 | |
|
| 440 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "cancelRegRequest", null)) { |
| 441 | 0 | return getNextDecorator().cancelRegRequest(regRequestId, context); |
| 442 | |
} |
| 443 | |
else { |
| 444 | 0 | throw new PermissionDeniedException(); |
| 445 | |
} |
| 446 | |
} |
| 447 | |
|
| 448 | |
@Override |
| 449 | |
public RegRequestInfo getRegRequest(String regRequestId, ContextInfo context) |
| 450 | |
throws DoesNotExistException, InvalidParameterException, |
| 451 | |
MissingParameterException, OperationFailedException, |
| 452 | |
PermissionDeniedException { |
| 453 | 0 | if (null == context) { |
| 454 | 0 | throw new MissingParameterException(); |
| 455 | |
} |
| 456 | |
|
| 457 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getRegRequest", null)) { |
| 458 | 0 | return getNextDecorator().getRegRequest(regRequestId, context); |
| 459 | |
} |
| 460 | |
else { |
| 461 | 0 | throw new PermissionDeniedException(); |
| 462 | |
} |
| 463 | |
} |
| 464 | |
|
| 465 | |
@Override |
| 466 | |
public List<RegRequestInfo> getRegRequestsByIds( |
| 467 | |
List<String> regRequestIds, ContextInfo context) |
| 468 | |
throws DoesNotExistException, InvalidParameterException, |
| 469 | |
MissingParameterException, OperationFailedException, |
| 470 | |
PermissionDeniedException { |
| 471 | 0 | if (null == context) { |
| 472 | 0 | throw new MissingParameterException(); |
| 473 | |
} |
| 474 | |
|
| 475 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getRegRequestsByIdList", null)) { |
| 476 | 0 | return getNextDecorator().getRegRequestsByIds(regRequestIds, context); |
| 477 | |
} |
| 478 | |
else { |
| 479 | 0 | throw new PermissionDeniedException(); |
| 480 | |
} |
| 481 | |
} |
| 482 | |
|
| 483 | |
@Override |
| 484 | |
public List<RegRequestInfo> getRegRequestsForStudentByTerm( |
| 485 | |
String studentId, String termId, List<String> requestStates, |
| 486 | |
ContextInfo context) throws DoesNotExistException, |
| 487 | |
InvalidParameterException, MissingParameterException, |
| 488 | |
OperationFailedException, PermissionDeniedException { |
| 489 | 0 | if (null == context) { |
| 490 | 0 | throw new MissingParameterException(); |
| 491 | |
} |
| 492 | |
|
| 493 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getRegRequestsForStudentByTerm", null)) { |
| 494 | 0 | return getNextDecorator().getRegRequestsForStudentByTerm(studentId, termId, requestStates, context); |
| 495 | |
} |
| 496 | |
else { |
| 497 | 0 | throw new PermissionDeniedException(); |
| 498 | |
} |
| 499 | |
} |
| 500 | |
|
| 501 | |
@Override |
| 502 | |
public CourseWaitlistEntryInfo getCourseWaitlistEntry( |
| 503 | |
String courseWaitlistEntryId, ContextInfo context) |
| 504 | |
throws DoesNotExistException, InvalidParameterException, |
| 505 | |
MissingParameterException, OperationFailedException, |
| 506 | |
PermissionDeniedException { |
| 507 | 0 | if (null == context) { |
| 508 | 0 | throw new MissingParameterException(); |
| 509 | |
} |
| 510 | |
|
| 511 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getCourseWaitlistEntry", null)) { |
| 512 | 0 | return getNextDecorator().getCourseWaitlistEntry(courseWaitlistEntryId, context); |
| 513 | |
} |
| 514 | |
else { |
| 515 | 0 | throw new PermissionDeniedException(); |
| 516 | |
} |
| 517 | |
} |
| 518 | |
|
| 519 | |
@Override |
| 520 | |
public StatusInfo updateCourseWaitlistEntry(String courseWaitlistEntryId, |
| 521 | |
CourseWaitlistEntryInfo courseWaitlistEntryInfo, ContextInfo context) |
| 522 | |
throws DoesNotExistException, DataValidationErrorException, |
| 523 | |
InvalidParameterException, MissingParameterException, |
| 524 | |
OperationFailedException, PermissionDeniedException { |
| 525 | 0 | if (null == context) { |
| 526 | 0 | throw new MissingParameterException(); |
| 527 | |
} |
| 528 | |
|
| 529 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "updateCourseWaitlistEntry", null)) { |
| 530 | 0 | return getNextDecorator().updateCourseWaitlistEntry(courseWaitlistEntryId, courseWaitlistEntryInfo, context); |
| 531 | |
} |
| 532 | |
else { |
| 533 | 0 | throw new PermissionDeniedException(); |
| 534 | |
} |
| 535 | |
} |
| 536 | |
|
| 537 | |
@Override |
| 538 | |
public StatusInfo reorderCourseWaitlistEntries( |
| 539 | |
List<String> courseWaitlistEntryIds, ContextInfo context) |
| 540 | |
throws DoesNotExistException, InvalidParameterException, |
| 541 | |
MissingParameterException, OperationFailedException, |
| 542 | |
PermissionDeniedException { |
| 543 | 0 | if (null == context) { |
| 544 | 0 | throw new MissingParameterException(); |
| 545 | |
} |
| 546 | |
|
| 547 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "reorderCourseWaitlistEntries", null)) { |
| 548 | 0 | return getNextDecorator().reorderCourseWaitlistEntries(courseWaitlistEntryIds, context); |
| 549 | |
} |
| 550 | |
else { |
| 551 | 0 | throw new PermissionDeniedException(); |
| 552 | |
} |
| 553 | |
} |
| 554 | |
|
| 555 | |
@Override |
| 556 | |
public StatusInfo insertCourseWaitlistEntryAtPosition( |
| 557 | |
String courseWaitlistEntryId, Integer position, ContextInfo context) |
| 558 | |
throws DoesNotExistException, InvalidParameterException, |
| 559 | |
MissingParameterException, OperationFailedException, |
| 560 | |
PermissionDeniedException { |
| 561 | 0 | if (null == context) { |
| 562 | 0 | throw new MissingParameterException(); |
| 563 | |
} |
| 564 | |
|
| 565 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "insertCourseWaitlistEntryAtPosition", null)) { |
| 566 | 0 | return getNextDecorator().insertCourseWaitlistEntryAtPosition(courseWaitlistEntryId, position, context); |
| 567 | |
} |
| 568 | |
else { |
| 569 | 0 | throw new PermissionDeniedException(); |
| 570 | |
} |
| 571 | |
} |
| 572 | |
|
| 573 | |
@Override |
| 574 | |
public StatusInfo removeCourseWaitlistEntry(String courseWaitlistEntryId, |
| 575 | |
ContextInfo context) throws DoesNotExistException, |
| 576 | |
InvalidParameterException, MissingParameterException, |
| 577 | |
OperationFailedException, PermissionDeniedException { |
| 578 | 0 | if (null == context) { |
| 579 | 0 | throw new MissingParameterException(); |
| 580 | |
} |
| 581 | |
|
| 582 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "removeCourseWaitlistEntry", null)) { |
| 583 | 0 | return getNextDecorator().removeCourseWaitlistEntry(courseWaitlistEntryId, context); |
| 584 | |
} |
| 585 | |
else { |
| 586 | 0 | throw new PermissionDeniedException(); |
| 587 | |
} |
| 588 | |
} |
| 589 | |
|
| 590 | |
@Override |
| 591 | |
public StatusInfo deleteCourseWaitlistEntry(String courseWaitlistEntryId, |
| 592 | |
ContextInfo context) throws InvalidParameterException, |
| 593 | |
MissingParameterException, OperationFailedException, |
| 594 | |
PermissionDeniedException { |
| 595 | 0 | if (null == context) { |
| 596 | 0 | throw new MissingParameterException(); |
| 597 | |
} |
| 598 | |
|
| 599 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "deleteCourseWaitlistEntry", null)) { |
| 600 | 0 | return getNextDecorator().deleteCourseWaitlistEntry(courseWaitlistEntryId, context); |
| 601 | |
} |
| 602 | |
else { |
| 603 | 0 | throw new PermissionDeniedException(); |
| 604 | |
} |
| 605 | |
} |
| 606 | |
|
| 607 | |
@Override |
| 608 | |
public StatusInfo validateCourseWaitlistEntry(String validateTypeKey, |
| 609 | |
CourseWaitlistEntryInfo courseWaitlistEntryInfo, ContextInfo context) |
| 610 | |
throws DataValidationErrorException, InvalidParameterException, |
| 611 | |
MissingParameterException, OperationFailedException, |
| 612 | |
PermissionDeniedException { |
| 613 | 0 | if (null == context) { |
| 614 | 0 | throw new MissingParameterException(); |
| 615 | |
} |
| 616 | |
|
| 617 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "validateCourseWaitlistEntry", null)) { |
| 618 | 0 | return getNextDecorator().validateCourseWaitlistEntry(validateTypeKey, courseWaitlistEntryInfo, context); |
| 619 | |
} |
| 620 | |
else { |
| 621 | 0 | throw new PermissionDeniedException(); |
| 622 | |
} |
| 623 | |
} |
| 624 | |
|
| 625 | |
@Override |
| 626 | |
public RegResponseInfo registerStudentFromWaitlist( |
| 627 | |
String courseWaitlistEntryId, ContextInfo context) |
| 628 | |
throws AlreadyExistsException, DataValidationErrorException, |
| 629 | |
InvalidParameterException, MissingParameterException, |
| 630 | |
OperationFailedException, PermissionDeniedException { |
| 631 | 0 | if (null == context) { |
| 632 | 0 | throw new MissingParameterException(); |
| 633 | |
} |
| 634 | |
|
| 635 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "registerStudentFromWaitlist", null)) { |
| 636 | 0 | return getNextDecorator().registerStudentFromWaitlist(courseWaitlistEntryId, context); |
| 637 | |
} |
| 638 | |
else { |
| 639 | 0 | throw new PermissionDeniedException(); |
| 640 | |
} |
| 641 | |
} |
| 642 | |
|
| 643 | |
@Override |
| 644 | |
public List<CourseWaitlistEntryInfo> getCourseWaitlistEntriesForCourseOffering( |
| 645 | |
String courseOfferingId, ContextInfo context) |
| 646 | |
throws DoesNotExistException, InvalidParameterException, |
| 647 | |
MissingParameterException, OperationFailedException, |
| 648 | |
PermissionDeniedException { |
| 649 | 0 | if (null == context) { |
| 650 | 0 | throw new MissingParameterException(); |
| 651 | |
} |
| 652 | |
|
| 653 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getCourseWaitlistEntriesForCourseOffering", null)) { |
| 654 | 0 | return getNextDecorator().getCourseWaitlistEntriesForCourseOffering(courseOfferingId, context); |
| 655 | |
} |
| 656 | |
else { |
| 657 | 0 | throw new PermissionDeniedException(); |
| 658 | |
} |
| 659 | |
} |
| 660 | |
|
| 661 | |
@Override |
| 662 | |
public List<CourseWaitlistEntryInfo> getCourseWaitlistEntriesForRegGroup( |
| 663 | |
String regGroupId, ContextInfo context) |
| 664 | |
throws DoesNotExistException, InvalidParameterException, |
| 665 | |
MissingParameterException, OperationFailedException, |
| 666 | |
PermissionDeniedException { |
| 667 | 0 | if (null == context) { |
| 668 | 0 | throw new MissingParameterException(); |
| 669 | |
} |
| 670 | |
|
| 671 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getCourseWaitlistEntriesForRegGroup", null)) { |
| 672 | 0 | return getNextDecorator().getCourseWaitlistEntriesForRegGroup(regGroupId, context); |
| 673 | |
} |
| 674 | |
else { |
| 675 | 0 | throw new PermissionDeniedException(); |
| 676 | |
} |
| 677 | |
} |
| 678 | |
|
| 679 | |
@Override |
| 680 | |
public List<CourseWaitlistEntryInfo> getCourseWaitlistEntriesForStudentInCourseOffering( |
| 681 | |
String courseOfferingId, String studentId, ContextInfo context) |
| 682 | |
throws DoesNotExistException, InvalidParameterException, |
| 683 | |
MissingParameterException, OperationFailedException, |
| 684 | |
PermissionDeniedException { |
| 685 | 0 | if (null == context) { |
| 686 | 0 | throw new MissingParameterException(); |
| 687 | |
} |
| 688 | |
|
| 689 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getCourseWaitlistEntriesForStudentInCourseOffering", null)) { |
| 690 | 0 | return getNextDecorator().getCourseWaitlistEntriesForStudentInCourseOffering(courseOfferingId, studentId, context); |
| 691 | |
} |
| 692 | |
else { |
| 693 | 0 | throw new PermissionDeniedException(); |
| 694 | |
} |
| 695 | |
} |
| 696 | |
|
| 697 | |
@Override |
| 698 | |
public CourseWaitlistEntryInfo getCourseWaitlistEntryForStudentInRegGroup( |
| 699 | |
String regGroupId, String studentId, ContextInfo context) |
| 700 | |
throws DoesNotExistException, InvalidParameterException, |
| 701 | |
MissingParameterException, OperationFailedException, |
| 702 | |
PermissionDeniedException { |
| 703 | 0 | if (null == context) { |
| 704 | 0 | throw new MissingParameterException(); |
| 705 | |
} |
| 706 | |
|
| 707 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getCourseWaitlistEntryForStudentInRegGroup", null)) { |
| 708 | 0 | return getNextDecorator().getCourseWaitlistEntryForStudentInRegGroup(regGroupId, studentId, context); |
| 709 | |
} |
| 710 | |
else { |
| 711 | 0 | throw new PermissionDeniedException(); |
| 712 | |
} |
| 713 | |
} |
| 714 | |
|
| 715 | |
@Override |
| 716 | |
public List<CourseWaitlistEntryInfo> getCourseWaitlistEntriesForStudentByTerm( |
| 717 | |
String studentId, String termId, ContextInfo context) |
| 718 | |
throws DoesNotExistException, InvalidParameterException, |
| 719 | |
MissingParameterException, OperationFailedException, |
| 720 | |
PermissionDeniedException { |
| 721 | 0 | if (null == context) { |
| 722 | 0 | throw new MissingParameterException(); |
| 723 | |
} |
| 724 | |
|
| 725 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getCourseWaitlistEntriesForStudentByTerm", null)) { |
| 726 | 0 | return getNextDecorator().getCourseWaitlistEntriesForStudentByTerm(studentId, termId, context); |
| 727 | |
} |
| 728 | |
else { |
| 729 | 0 | throw new PermissionDeniedException(); |
| 730 | |
} |
| 731 | |
} |
| 732 | |
|
| 733 | |
@Override |
| 734 | |
public CourseRegistrationInfo getCourseRegistration( |
| 735 | |
String courseRegistrationId, ContextInfo context) |
| 736 | |
throws DoesNotExistException, InvalidParameterException, |
| 737 | |
MissingParameterException, OperationFailedException, |
| 738 | |
PermissionDeniedException { |
| 739 | 0 | if (null == context) { |
| 740 | 0 | throw new MissingParameterException(); |
| 741 | |
} |
| 742 | |
|
| 743 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getCourseRegistration", null)) { |
| 744 | 0 | return getNextDecorator().getCourseRegistration(courseRegistrationId, context); |
| 745 | |
} |
| 746 | |
else { |
| 747 | 0 | throw new PermissionDeniedException(); |
| 748 | |
} |
| 749 | |
} |
| 750 | |
|
| 751 | |
@Override |
| 752 | |
public List<CourseRegistrationInfo> getCourseRegistrationsByIds( |
| 753 | |
List<String> courseRegistrationIds, ContextInfo context) |
| 754 | |
throws DoesNotExistException, InvalidParameterException, |
| 755 | |
MissingParameterException, OperationFailedException, |
| 756 | |
PermissionDeniedException { |
| 757 | 0 | if (null == context) { |
| 758 | 0 | throw new MissingParameterException(); |
| 759 | |
} |
| 760 | |
|
| 761 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getCourseRegistrationsByIdList", null)) { |
| 762 | 0 | return getNextDecorator().getCourseRegistrationsByIds(courseRegistrationIds, context); |
| 763 | |
} |
| 764 | |
else { |
| 765 | 0 | throw new PermissionDeniedException(); |
| 766 | |
} |
| 767 | |
} |
| 768 | |
|
| 769 | |
@Override |
| 770 | |
public CourseRegistrationInfo getActiveCourseRegistrationForStudentByCourseOffering( |
| 771 | |
String studentId, String courseOfferingId, ContextInfo context) |
| 772 | |
throws DoesNotExistException, InvalidParameterException, |
| 773 | |
MissingParameterException, OperationFailedException, |
| 774 | |
PermissionDeniedException, DisabledIdentifierException { |
| 775 | 0 | if (null == context) { |
| 776 | 0 | throw new MissingParameterException(); |
| 777 | |
} |
| 778 | |
|
| 779 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getActiveCourseRegistrationForStudentByCourseOffering", null)) { |
| 780 | 0 | return getNextDecorator().getActiveCourseRegistrationForStudentByCourseOffering(studentId, courseOfferingId, context); |
| 781 | |
} |
| 782 | |
else { |
| 783 | 0 | throw new PermissionDeniedException(); |
| 784 | |
} |
| 785 | |
} |
| 786 | |
|
| 787 | |
@Override |
| 788 | |
public List<CourseRegistrationInfo> getCourseRegistrationsForStudent( |
| 789 | |
String studentId, ContextInfo context) |
| 790 | |
throws DoesNotExistException, InvalidParameterException, |
| 791 | |
MissingParameterException, OperationFailedException, |
| 792 | |
PermissionDeniedException, DisabledIdentifierException { |
| 793 | 0 | if (null == context) { |
| 794 | 0 | throw new MissingParameterException(); |
| 795 | |
} |
| 796 | |
|
| 797 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getCourseRegistrationsForStudent", null)) { |
| 798 | 0 | return getNextDecorator().getCourseRegistrationsForStudent(studentId, context); |
| 799 | |
} |
| 800 | |
else { |
| 801 | 0 | throw new PermissionDeniedException(); |
| 802 | |
} |
| 803 | |
} |
| 804 | |
|
| 805 | |
@Override |
| 806 | |
public List<CourseRegistrationInfo> getCourseRegistrationsForStudentByCourseOffering( |
| 807 | |
String studentId, String courseOfferingId, ContextInfo context) |
| 808 | |
throws DoesNotExistException, InvalidParameterException, |
| 809 | |
MissingParameterException, OperationFailedException, |
| 810 | |
PermissionDeniedException, DisabledIdentifierException { |
| 811 | 0 | if (null == context) { |
| 812 | 0 | throw new MissingParameterException(); |
| 813 | |
} |
| 814 | |
|
| 815 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getCourseRegistrationsForStudentByCourseOffering", null)) { |
| 816 | 0 | return getNextDecorator().getCourseRegistrationsForStudentByCourseOffering(studentId, courseOfferingId, context); |
| 817 | |
} |
| 818 | |
else { |
| 819 | 0 | throw new PermissionDeniedException(); |
| 820 | |
} |
| 821 | |
} |
| 822 | |
|
| 823 | |
@Override |
| 824 | |
public List<CourseRegistrationInfo> getCourseRegistrationsForStudentByTerm( |
| 825 | |
String studentId, String termId, ContextInfo context) |
| 826 | |
throws DoesNotExistException, InvalidParameterException, |
| 827 | |
MissingParameterException, OperationFailedException, |
| 828 | |
PermissionDeniedException, DisabledIdentifierException { |
| 829 | 0 | if (null == context) { |
| 830 | 0 | throw new MissingParameterException(); |
| 831 | |
} |
| 832 | |
|
| 833 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getCourseRegistrationsForStudentByTerm", null)) { |
| 834 | 0 | return getNextDecorator().getCourseRegistrationsForStudentByTerm(studentId, termId, context); |
| 835 | |
} |
| 836 | |
else { |
| 837 | 0 | throw new PermissionDeniedException(); |
| 838 | |
} |
| 839 | |
} |
| 840 | |
|
| 841 | |
@Override |
| 842 | |
public List<CourseRegistrationInfo> getActiveCourseRegistrationsByCourseOfferingId( |
| 843 | |
String courseOfferingId, ContextInfo context) |
| 844 | |
throws DoesNotExistException, InvalidParameterException, |
| 845 | |
MissingParameterException, OperationFailedException, |
| 846 | |
PermissionDeniedException { |
| 847 | 0 | if (null == context) { |
| 848 | 0 | throw new MissingParameterException(); |
| 849 | |
} |
| 850 | |
|
| 851 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getActiveCourseRegistrationsByCourseOfferingId", null)) { |
| 852 | 0 | return getNextDecorator().getActiveCourseRegistrationsByCourseOfferingId(courseOfferingId, context); |
| 853 | |
} |
| 854 | |
else { |
| 855 | 0 | throw new PermissionDeniedException(); |
| 856 | |
} |
| 857 | |
} |
| 858 | |
|
| 859 | |
@Override |
| 860 | |
public List<CourseRegistrationInfo> getDroppedCourseRegistrationsByCourseOfferingId( |
| 861 | |
String courseOfferingId, ContextInfo context) |
| 862 | |
throws DoesNotExistException, InvalidParameterException, |
| 863 | |
MissingParameterException, OperationFailedException, |
| 864 | |
PermissionDeniedException { |
| 865 | 0 | if (null == context) { |
| 866 | 0 | throw new MissingParameterException(); |
| 867 | |
} |
| 868 | |
|
| 869 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getDroppedCourseRegistrationsByCourseOfferingId", null)) { |
| 870 | 0 | return getNextDecorator().getDroppedCourseRegistrationsByCourseOfferingId(courseOfferingId, context); |
| 871 | |
} |
| 872 | |
else { |
| 873 | 0 | throw new PermissionDeniedException(); |
| 874 | |
} |
| 875 | |
} |
| 876 | |
|
| 877 | |
@Override |
| 878 | |
public List<RegRequestInfo> getRegRequestsForCourseRegistration( |
| 879 | |
String courseRegistrationId, ContextInfo context) |
| 880 | |
throws DoesNotExistException, InvalidParameterException, |
| 881 | |
MissingParameterException, OperationFailedException, |
| 882 | |
PermissionDeniedException { |
| 883 | 0 | if (null == context) { |
| 884 | 0 | throw new MissingParameterException(); |
| 885 | |
} |
| 886 | |
|
| 887 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getRegRequestsForCourseRegistration", null)) { |
| 888 | 0 | return getNextDecorator().getRegRequestsForCourseRegistration(courseRegistrationId, context); |
| 889 | |
} |
| 890 | |
else { |
| 891 | 0 | throw new PermissionDeniedException(); |
| 892 | |
} |
| 893 | |
} |
| 894 | |
|
| 895 | |
@Override |
| 896 | |
public List<RegRequestInfo> getRegRequestsForCourseOffering( |
| 897 | |
String courseOfferingId, ContextInfo context) |
| 898 | |
throws DoesNotExistException, InvalidParameterException, |
| 899 | |
MissingParameterException, OperationFailedException, |
| 900 | |
PermissionDeniedException { |
| 901 | 0 | if (null == context) { |
| 902 | 0 | throw new MissingParameterException(); |
| 903 | |
} |
| 904 | |
|
| 905 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getRegRequestsForCourseOffering", null)) { |
| 906 | 0 | return getNextDecorator().getRegRequestsForCourseOffering(courseOfferingId, context); |
| 907 | |
} |
| 908 | |
else { |
| 909 | 0 | throw new PermissionDeniedException(); |
| 910 | |
} |
| 911 | |
} |
| 912 | |
|
| 913 | |
@Override |
| 914 | |
public List<RegRequestInfo> getRegRequestsForCourseOfferingByStudent( |
| 915 | |
String courseOfferingId, String studentId, ContextInfo context) |
| 916 | |
throws DoesNotExistException, InvalidParameterException, |
| 917 | |
MissingParameterException, OperationFailedException, |
| 918 | |
PermissionDeniedException { |
| 919 | 0 | if (null == context) { |
| 920 | 0 | throw new MissingParameterException(); |
| 921 | |
} |
| 922 | |
|
| 923 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "getRegRequestsForCourseOfferingByStudent", null)) { |
| 924 | 0 | return getNextDecorator().getRegRequestsForCourseOfferingByStudent(courseOfferingId, studentId, context); |
| 925 | |
} |
| 926 | |
else { |
| 927 | 0 | throw new PermissionDeniedException(); |
| 928 | |
} |
| 929 | |
} |
| 930 | |
|
| 931 | |
@Override |
| 932 | |
public List<CourseRegistrationInfo> searchForCourseRegistrations( |
| 933 | |
QueryByCriteria criteria, ContextInfo context) |
| 934 | |
throws InvalidParameterException, MissingParameterException, |
| 935 | |
OperationFailedException, PermissionDeniedException { |
| 936 | 0 | if (null == context) { |
| 937 | 0 | throw new MissingParameterException(); |
| 938 | |
} |
| 939 | |
|
| 940 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "searchForCourseRegistrations", null)) { |
| 941 | 0 | return getNextDecorator().searchForCourseRegistrations(criteria, context); |
| 942 | |
} |
| 943 | |
else { |
| 944 | 0 | throw new PermissionDeniedException(); |
| 945 | |
} |
| 946 | |
} |
| 947 | |
|
| 948 | |
@Override |
| 949 | |
public List<String> searchForCourseOfferingRegistrationIds( |
| 950 | |
QueryByCriteria criteria, ContextInfo context) |
| 951 | |
throws InvalidParameterException, MissingParameterException, |
| 952 | |
OperationFailedException, PermissionDeniedException { |
| 953 | 0 | if (null == context) { |
| 954 | 0 | throw new MissingParameterException(); |
| 955 | |
} |
| 956 | |
|
| 957 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "searchForCourseOfferingRegistrationIds", null)) { |
| 958 | 0 | return getNextDecorator().searchForCourseOfferingRegistrationIds(criteria, context); |
| 959 | |
} |
| 960 | |
else { |
| 961 | 0 | throw new PermissionDeniedException(); |
| 962 | |
} |
| 963 | |
} |
| 964 | |
|
| 965 | |
@Override |
| 966 | |
public List<ActivityRegistrationInfo> searchForActivityRegistrations( |
| 967 | |
QueryByCriteria criteria, ContextInfo context) |
| 968 | |
throws InvalidParameterException, MissingParameterException, |
| 969 | |
OperationFailedException, PermissionDeniedException { |
| 970 | 0 | if (null == context) { |
| 971 | 0 | throw new MissingParameterException(); |
| 972 | |
} |
| 973 | |
|
| 974 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "searchForActivityRegistrations", null)) { |
| 975 | 0 | return getNextDecorator().searchForActivityRegistrations(criteria, context); |
| 976 | |
} |
| 977 | |
else { |
| 978 | 0 | throw new PermissionDeniedException(); |
| 979 | |
} |
| 980 | |
} |
| 981 | |
|
| 982 | |
@Override |
| 983 | |
public List<String> searchForActivityRegistrationIds( |
| 984 | |
QueryByCriteria criteria, ContextInfo context) |
| 985 | |
throws InvalidParameterException, MissingParameterException, |
| 986 | |
OperationFailedException, PermissionDeniedException { |
| 987 | 0 | if (null == context) { |
| 988 | 0 | throw new MissingParameterException(); |
| 989 | |
} |
| 990 | |
|
| 991 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "searchForActivityRegistrationIds", null)) { |
| 992 | 0 | return getNextDecorator().searchForActivityRegistrationIds(criteria, context); |
| 993 | |
} |
| 994 | |
else { |
| 995 | 0 | throw new PermissionDeniedException(); |
| 996 | |
} |
| 997 | |
} |
| 998 | |
|
| 999 | |
@Override |
| 1000 | |
public List<RegGroupRegistrationInfo> searchForRegGroupRegistrations( |
| 1001 | |
QueryByCriteria criteria, ContextInfo context) |
| 1002 | |
throws InvalidParameterException, MissingParameterException, |
| 1003 | |
OperationFailedException, PermissionDeniedException { |
| 1004 | 0 | if (null == context) { |
| 1005 | 0 | throw new MissingParameterException(); |
| 1006 | |
} |
| 1007 | |
|
| 1008 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "searchForRegGroupRegistrations", null)) { |
| 1009 | 0 | return getNextDecorator().searchForRegGroupRegistrations(criteria, context); |
| 1010 | |
} |
| 1011 | |
else { |
| 1012 | 0 | throw new PermissionDeniedException(); |
| 1013 | |
} |
| 1014 | |
} |
| 1015 | |
|
| 1016 | |
@Override |
| 1017 | |
public List<String> searchForRegGroupRegistrationIds( |
| 1018 | |
QueryByCriteria criteria, ContextInfo context) |
| 1019 | |
throws InvalidParameterException, MissingParameterException, |
| 1020 | |
OperationFailedException, PermissionDeniedException { |
| 1021 | 0 | if (null == context) { |
| 1022 | 0 | throw new MissingParameterException(); |
| 1023 | |
} |
| 1024 | |
|
| 1025 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "searchForRegGroupRegistrationIds", null)) { |
| 1026 | 0 | return getNextDecorator().searchForRegGroupRegistrationIds(criteria, context); |
| 1027 | |
} |
| 1028 | |
else { |
| 1029 | 0 | throw new PermissionDeniedException(); |
| 1030 | |
} |
| 1031 | |
} |
| 1032 | |
|
| 1033 | |
@Override |
| 1034 | |
public List<CourseWaitlistEntryInfo> searchForCourseWaitlistEntries( |
| 1035 | |
QueryByCriteria criteria, ContextInfo context) |
| 1036 | |
throws InvalidParameterException, MissingParameterException, |
| 1037 | |
OperationFailedException, PermissionDeniedException { |
| 1038 | 0 | if (null == context) { |
| 1039 | 0 | throw new MissingParameterException(); |
| 1040 | |
} |
| 1041 | |
|
| 1042 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "searchForCourseWaitlistEntries", null)) { |
| 1043 | 0 | return getNextDecorator().searchForCourseWaitlistEntries(criteria, context); |
| 1044 | |
} |
| 1045 | |
else { |
| 1046 | 0 | throw new PermissionDeniedException(); |
| 1047 | |
} |
| 1048 | |
} |
| 1049 | |
|
| 1050 | |
@Override |
| 1051 | |
public List<String> searchForCourseWaitlistEntryIds( |
| 1052 | |
QueryByCriteria criteria, ContextInfo context) |
| 1053 | |
throws InvalidParameterException, MissingParameterException, |
| 1054 | |
OperationFailedException, PermissionDeniedException { |
| 1055 | 0 | if (null == context) { |
| 1056 | 0 | throw new MissingParameterException(); |
| 1057 | |
} |
| 1058 | |
|
| 1059 | 0 | if (permissionService.isAuthorized(context.getPrincipalId(), ENRLLMENT_NAMESPACE, SERVICE_NAME + "searchForCourseWaitlistEntryIds", null)) { |
| 1060 | 0 | return getNextDecorator().searchForCourseWaitlistEntryIds(criteria, context); |
| 1061 | |
} |
| 1062 | |
else { |
| 1063 | 0 | throw new PermissionDeniedException(); |
| 1064 | |
} |
| 1065 | |
} |
| 1066 | |
|
| 1067 | |
} |