Class: Google::Apis::ClassroomV1::StudentSubmission

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
generated/google/apis/classroom_v1/classes.rb,
generated/google/apis/classroom_v1/representations.rb,
generated/google/apis/classroom_v1/representations.rb

Overview

Student submission for course work. StudentSubmission items are generated when a CourseWork item is created. StudentSubmissions that have never been accessed (i.e. with state = NEW) may not have a creation time or update time.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Google::Apis::Core::JsonObjectSupport

#to_json

Methods included from Google::Apis::Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ StudentSubmission

Returns a new instance of StudentSubmission.



1362
1363
1364
# File 'generated/google/apis/classroom_v1/classes.rb', line 1362

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

Absolute link to the submission in the Classroom web UI. Read-only. Corresponds to the JSON property alternateLink

Returns:

  • (String)


1332
1333
1334
# File 'generated/google/apis/classroom_v1/classes.rb', line 1332

def alternate_link
  @alternate_link
end

#assigned_gradeFloat

Optional grade. If unset, no grade was set. This must be a non-negative integer value. This may be modified only by course teachers. Corresponds to the JSON property assignedGrade

Returns:

  • (Float)


1327
1328
1329
# File 'generated/google/apis/classroom_v1/classes.rb', line 1327

def assigned_grade
  @assigned_grade
end

#assignment_submissionGoogle::Apis::ClassroomV1::AssignmentSubmission

Student work for an assignment. Corresponds to the JSON property assignmentSubmission



1350
1351
1352
# File 'generated/google/apis/classroom_v1/classes.rb', line 1350

def assignment_submission
  @assignment_submission
end

#associated_with_developerBoolean Also known as: associated_with_developer?

Whether this student submission is associated with the Developer Console project making the request. See google.classroom.Work.CreateCourseWork for more details. Read-only. Corresponds to the JSON property associatedWithDeveloper

Returns:

  • (Boolean)


1344
1345
1346
# File 'generated/google/apis/classroom_v1/classes.rb', line 1344

def associated_with_developer
  @associated_with_developer
end

#course_idString

Identifier of the course. Read-only. Corresponds to the JSON property courseId

Returns:

  • (String)


1275
1276
1277
# File 'generated/google/apis/classroom_v1/classes.rb', line 1275

def course_id
  @course_id
end

#course_work_idString

Identifier for the course work this corresponds to. Read-only. Corresponds to the JSON property courseWorkId

Returns:

  • (String)


1280
1281
1282
# File 'generated/google/apis/classroom_v1/classes.rb', line 1280

def course_work_id
  @course_work_id
end

#course_work_typeString

Type of course work this submission is for. Read-only. Corresponds to the JSON property courseWorkType

Returns:

  • (String)


1337
1338
1339
# File 'generated/google/apis/classroom_v1/classes.rb', line 1337

def course_work_type
  @course_work_type
end

#creation_timeString

Creation time of this submission. This may be unset if the student has not accessed this item. Read-only. Corresponds to the JSON property creationTime

Returns:

  • (String)


1297
1298
1299
# File 'generated/google/apis/classroom_v1/classes.rb', line 1297

def creation_time
  @creation_time
end

#draft_gradeFloat

Optional pending grade. If unset, no grade was set. This must be a non- negative integer value. This is only visible to and modifiable by course teachers. Corresponds to the JSON property draftGrade

Returns:

  • (Float)


1321
1322
1323
# File 'generated/google/apis/classroom_v1/classes.rb', line 1321

def draft_grade
  @draft_grade
end

#idString

Classroom-assigned Identifier for the student submission. This is unique among submissions for the relevant course work. Read-only. Corresponds to the JSON property id

Returns:

  • (String)


1286
1287
1288
# File 'generated/google/apis/classroom_v1/classes.rb', line 1286

def id
  @id
end

#lateBoolean Also known as: late?

Whether this submission is late. Read-only. Corresponds to the JSON property late

Returns:

  • (Boolean)


1313
1314
1315
# File 'generated/google/apis/classroom_v1/classes.rb', line 1313

def late
  @late
end

#multiple_choice_submissionGoogle::Apis::ClassroomV1::MultipleChoiceSubmission

Student work for a multiple-choice question. Corresponds to the JSON property multipleChoiceSubmission



1360
1361
1362
# File 'generated/google/apis/classroom_v1/classes.rb', line 1360

def multiple_choice_submission
  @multiple_choice_submission
end

#short_answer_submissionGoogle::Apis::ClassroomV1::ShortAnswerSubmission

Student work for a short answer question. Corresponds to the JSON property shortAnswerSubmission



1355
1356
1357
# File 'generated/google/apis/classroom_v1/classes.rb', line 1355

def short_answer_submission
  @short_answer_submission
end

#stateString

State of this submission. Read-only. Corresponds to the JSON property state

Returns:

  • (String)


1308
1309
1310
# File 'generated/google/apis/classroom_v1/classes.rb', line 1308

def state
  @state
end

#update_timeString

Last update time of this submission. This may be unset if the student has not accessed this item. Read-only. Corresponds to the JSON property updateTime

Returns:

  • (String)


1303
1304
1305
# File 'generated/google/apis/classroom_v1/classes.rb', line 1303

def update_time
  @update_time
end

#user_idString

Identifier for the student that owns this submission. Read-only. Corresponds to the JSON property userId

Returns:

  • (String)


1291
1292
1293
# File 'generated/google/apis/classroom_v1/classes.rb', line 1291

def user_id
  @user_id
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
# File 'generated/google/apis/classroom_v1/classes.rb', line 1367

def update!(**args)
  @course_id = args[:course_id] if args.key?(:course_id)
  @course_work_id = args[:course_work_id] if args.key?(:course_work_id)
  @id = args[:id] if args.key?(:id)
  @user_id = args[:user_id] if args.key?(:user_id)
  @creation_time = args[:creation_time] if args.key?(:creation_time)
  @update_time = args[:update_time] if args.key?(:update_time)
  @state = args[:state] if args.key?(:state)
  @late = args[:late] if args.key?(:late)
  @draft_grade = args[:draft_grade] if args.key?(:draft_grade)
  @assigned_grade = args[:assigned_grade] if args.key?(:assigned_grade)
  @alternate_link = args[:alternate_link] if args.key?(:alternate_link)
  @course_work_type = args[:course_work_type] if args.key?(:course_work_type)
  @associated_with_developer = args[:associated_with_developer] if args.key?(:associated_with_developer)
  @assignment_submission = args[:assignment_submission] if args.key?(:assignment_submission)
  @short_answer_submission = args[:short_answer_submission] if args.key?(:short_answer_submission)
  @multiple_choice_submission = args[:multiple_choice_submission] if args.key?(:multiple_choice_submission)
end