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

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

Overview

Student submission for course work. StudentSubmission items are generated when a CourseWork item is created. Student submissions 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

Constructor Details

#initialize(**args) ⇒ StudentSubmission

Returns a new instance of StudentSubmission.



2930
2931
2932
# File 'lib/google/apis/classroom_v1/classes.rb', line 2930

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)


2821
2822
2823
# File 'lib/google/apis/classroom_v1/classes.rb', line 2821

def alternate_link
  @alternate_link
end

#assigned_gradeFloat

Optional grade. If unset, no grade was set. This value must be non-negative. Decimal (that is, non-integer) values are allowed, but are rounded to two decimal places. This may be modified only by course teachers. Corresponds to the JSON property assignedGrade

Returns:

  • (Float)


2828
2829
2830
# File 'lib/google/apis/classroom_v1/classes.rb', line 2828

def assigned_grade
  @assigned_grade
end

#assigned_rubric_gradesHash<String,Google::Apis::ClassroomV1::RubricGrade>

Assigned rubric grades based on the rubric's Criteria. This map is empty if there is no rubric attached to this course work or if a rubric is attached, but no grades have been set on any Criteria. Entries are only populated for grades that have been set. Key: The rubric's criterion ID. Read-only. Corresponds to the JSON property assignedRubricGrades

Returns:



2836
2837
2838
# File 'lib/google/apis/classroom_v1/classes.rb', line 2836

def assigned_rubric_grades
  @assigned_rubric_grades
end

#assignment_submissionGoogle::Apis::ClassroomV1::AssignmentSubmission

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



2841
2842
2843
# File 'lib/google/apis/classroom_v1/classes.rb', line 2841

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 CreateCourseWork for more details. Read-only. Corresponds to the JSON property associatedWithDeveloper

Returns:

  • (Boolean)


2847
2848
2849
# File 'lib/google/apis/classroom_v1/classes.rb', line 2847

def associated_with_developer
  @associated_with_developer
end

#course_idString

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

Returns:

  • (String)


2853
2854
2855
# File 'lib/google/apis/classroom_v1/classes.rb', line 2853

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)


2858
2859
2860
# File 'lib/google/apis/classroom_v1/classes.rb', line 2858

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)


2863
2864
2865
# File 'lib/google/apis/classroom_v1/classes.rb', line 2863

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)


2869
2870
2871
# File 'lib/google/apis/classroom_v1/classes.rb', line 2869

def creation_time
  @creation_time
end

#draft_gradeFloat

Optional pending grade. If unset, no grade was set. This value must be non- negative. Decimal (that is, non-integer) values are allowed, but are rounded to two decimal places. This is only visible to and modifiable by course teachers. Corresponds to the JSON property draftGrade

Returns:

  • (Float)


2877
2878
2879
# File 'lib/google/apis/classroom_v1/classes.rb', line 2877

def draft_grade
  @draft_grade
end

#draft_rubric_gradesHash<String,Google::Apis::ClassroomV1::RubricGrade>

Pending rubric grades based on the rubric's criteria. This map is empty if there is no rubric attached to this course work or if a rubric is attached, but no grades have been set on any criteria. Entries are only populated for grades that have been set. Key: The rubric's criterion ID. Read-only. Corresponds to the JSON property draftRubricGrades

Returns:



2885
2886
2887
# File 'lib/google/apis/classroom_v1/classes.rb', line 2885

def draft_rubric_grades
  @draft_rubric_grades
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)


2891
2892
2893
# File 'lib/google/apis/classroom_v1/classes.rb', line 2891

def id
  @id
end

#lateBoolean Also known as: late?

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

Returns:

  • (Boolean)


2896
2897
2898
# File 'lib/google/apis/classroom_v1/classes.rb', line 2896

def late
  @late
end

#multiple_choice_submissionGoogle::Apis::ClassroomV1::MultipleChoiceSubmission

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



2902
2903
2904
# File 'lib/google/apis/classroom_v1/classes.rb', line 2902

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



2907
2908
2909
# File 'lib/google/apis/classroom_v1/classes.rb', line 2907

def short_answer_submission
  @short_answer_submission
end

#stateString

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

Returns:

  • (String)


2912
2913
2914
# File 'lib/google/apis/classroom_v1/classes.rb', line 2912

def state
  @state
end

#submission_historyArray<Google::Apis::ClassroomV1::SubmissionHistory>

The history of the submission (includes state and grade histories). Read-only. Corresponds to the JSON property submissionHistory



2917
2918
2919
# File 'lib/google/apis/classroom_v1/classes.rb', line 2917

def submission_history
  @submission_history
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)


2923
2924
2925
# File 'lib/google/apis/classroom_v1/classes.rb', line 2923

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)


2928
2929
2930
# File 'lib/google/apis/classroom_v1/classes.rb', line 2928

def user_id
  @user_id
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2935
2936
2937
2938
2939
2940
2941
2942
2943
2944
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
# File 'lib/google/apis/classroom_v1/classes.rb', line 2935

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