Class: Google::Apis::ClassroomV1::CourseWork
- Inherits:
-
Object
- Object
- Google::Apis::ClassroomV1::CourseWork
- 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
Course work created by a teacher for students of the course.
Instance Attribute Summary collapse
-
#alternate_link ⇒ String
Absolute link to this course work in the Classroom web UI.
-
#assignee_mode ⇒ String
Assignee mode of the coursework.
-
#assignment ⇒ Google::Apis::ClassroomV1::Assignment
Additional details for assignments.
-
#associated_with_developer ⇒ Boolean
(also: #associated_with_developer?)
Whether this course work item is associated with the Developer Console project making the request.
-
#course_id ⇒ String
Identifier of the course.
-
#creation_time ⇒ String
Timestamp when this course work was created.
-
#creator_user_id ⇒ String
Identifier for the user that created the coursework.
-
#description ⇒ String
Optional description of this course work.
-
#due_date ⇒ Google::Apis::ClassroomV1::Date
Represents a whole or partial calendar date, such as a birthday.
-
#due_time ⇒ Google::Apis::ClassroomV1::TimeOfDay
Represents a time of day.
-
#grade_category ⇒ Google::Apis::ClassroomV1::GradeCategory
Details for a grade category in a course.
-
#id ⇒ String
Classroom-assigned identifier of this course work, unique per course.
-
#individual_students_options ⇒ Google::Apis::ClassroomV1::IndividualStudentsOptions
Assignee details about a coursework/announcement.
-
#materials ⇒ Array<Google::Apis::ClassroomV1::Material>
Additional materials.
-
#max_points ⇒ Float
Maximum grade for this course work.
-
#multiple_choice_question ⇒ Google::Apis::ClassroomV1::MultipleChoiceQuestion
Additional details for multiple-choice questions.
-
#scheduled_time ⇒ String
Optional timestamp when this course work is scheduled to be published.
-
#state ⇒ String
Status of this course work.
-
#submission_modification_mode ⇒ String
Setting to determine when students are allowed to modify submissions.
-
#title ⇒ String
Title of this course work.
-
#topic_id ⇒ String
Identifier for the topic that this coursework is associated with.
-
#update_time ⇒ String
Timestamp of the most recent change to this course work.
-
#work_type ⇒ String
Type of this course work.
Instance Method Summary collapse
-
#initialize(**args) ⇒ CourseWork
constructor
A new instance of CourseWork.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ CourseWork
Returns a new instance of CourseWork.
630 631 632 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 630 def initialize(**args) update!(**args) end |
Instance Attribute Details
#alternate_link ⇒ String
Absolute link to this course work in the Classroom web UI. This is only
populated if state is PUBLISHED. Read-only.
Corresponds to the JSON property alternateLink
495 496 497 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 495 def alternate_link @alternate_link end |
#assignee_mode ⇒ String
Assignee mode of the coursework. If unspecified, the default value is
ALL_STUDENTS.
Corresponds to the JSON property assigneeMode
501 502 503 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 501 def assignee_mode @assignee_mode end |
#assignment ⇒ Google::Apis::ClassroomV1::Assignment
Additional details for assignments.
Corresponds to the JSON property assignment
506 507 508 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 506 def assignment @assignment end |
#associated_with_developer ⇒ Boolean Also known as: associated_with_developer?
Whether this course work item is associated with the Developer Console project
making the request. See CreateCourseWork for more details. Read-only.
Corresponds to the JSON property associatedWithDeveloper
512 513 514 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 512 def associated_with_developer @associated_with_developer end |
#course_id ⇒ String
Identifier of the course. Read-only.
Corresponds to the JSON property courseId
518 519 520 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 518 def course_id @course_id end |
#creation_time ⇒ String
Timestamp when this course work was created. Read-only.
Corresponds to the JSON property creationTime
523 524 525 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 523 def creation_time @creation_time end |
#creator_user_id ⇒ String
Identifier for the user that created the coursework. Read-only.
Corresponds to the JSON property creatorUserId
528 529 530 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 528 def creator_user_id @creator_user_id end |
#description ⇒ String
Optional description of this course work. If set, the description must be a
valid UTF-8 string containing no more than 30,000 characters.
Corresponds to the JSON property description
534 535 536 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 534 def description @description end |
#due_date ⇒ Google::Apis::ClassroomV1::Date
Represents a whole or partial calendar date, such as a birthday. The time of
day and time zone are either specified elsewhere or are insignificant. The
date is relative to the Gregorian Calendar. This can represent one of the
following: * A full date, with non-zero year, month, and day values * A month
and day, with a zero year (e.g., an anniversary) * A year on its own, with a
zero month and a zero day * A year and month, with a zero day (e.g., a credit
card expiration date) Related types: * google.type.TimeOfDay * google.type.
DateTime * google.protobuf.Timestamp
Corresponds to the JSON property dueDate
546 547 548 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 546 def due_date @due_date end |
#due_time ⇒ Google::Apis::ClassroomV1::TimeOfDay
Represents a time of day. The date and time zone are either not significant or
are specified elsewhere. An API may choose to allow leap seconds. Related
types are google.type.Date and google.protobuf.Timestamp.
Corresponds to the JSON property dueTime
553 554 555 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 553 def due_time @due_time end |
#grade_category ⇒ Google::Apis::ClassroomV1::GradeCategory
Details for a grade category in a course. Coursework may have zero or one
grade category, and the category may be used in computing the overall grade.
See the help center article for details.
Corresponds to the JSON property gradeCategory
561 562 563 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 561 def grade_category @grade_category end |
#id ⇒ String
Classroom-assigned identifier of this course work, unique per course. Read-
only.
Corresponds to the JSON property id
567 568 569 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 567 def id @id end |
#individual_students_options ⇒ Google::Apis::ClassroomV1::IndividualStudentsOptions
Assignee details about a coursework/announcement. This field is set if and
only if assigneeMode is INDIVIDUAL_STUDENTS.
Corresponds to the JSON property individualStudentsOptions
573 574 575 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 573 def @individual_students_options end |
#materials ⇒ Array<Google::Apis::ClassroomV1::Material>
Additional materials. CourseWork must have no more than 20 material items.
Corresponds to the JSON property materials
578 579 580 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 578 def materials @materials end |
#max_points ⇒ Float
Maximum grade for this course work. If zero or unspecified, this assignment is
considered ungraded. This must be a non-negative integer value.
Corresponds to the JSON property maxPoints
584 585 586 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 584 def max_points @max_points end |
#multiple_choice_question ⇒ Google::Apis::ClassroomV1::MultipleChoiceQuestion
Additional details for multiple-choice questions.
Corresponds to the JSON property multipleChoiceQuestion
589 590 591 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 589 def multiple_choice_question @multiple_choice_question end |
#scheduled_time ⇒ String
Optional timestamp when this course work is scheduled to be published.
Corresponds to the JSON property scheduledTime
594 595 596 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 594 def scheduled_time @scheduled_time end |
#state ⇒ String
Status of this course work. If unspecified, the default state is DRAFT.
Corresponds to the JSON property state
599 600 601 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 599 def state @state end |
#submission_modification_mode ⇒ String
Setting to determine when students are allowed to modify submissions. If
unspecified, the default value is MODIFIABLE_UNTIL_TURNED_IN.
Corresponds to the JSON property submissionModificationMode
605 606 607 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 605 def submission_modification_mode @submission_modification_mode end |
#title ⇒ String
Title of this course work. The title must be a valid UTF-8 string containing
between 1 and 3000 characters.
Corresponds to the JSON property title
611 612 613 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 611 def title @title end |
#topic_id ⇒ String
Identifier for the topic that this coursework is associated with. Must match
an existing topic in the course.
Corresponds to the JSON property topicId
617 618 619 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 617 def topic_id @topic_id end |
#update_time ⇒ String
Timestamp of the most recent change to this course work. Read-only.
Corresponds to the JSON property updateTime
622 623 624 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 622 def update_time @update_time end |
#work_type ⇒ String
Type of this course work. The type is set when the course work is created and
cannot be changed.
Corresponds to the JSON property workType
628 629 630 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 628 def work_type @work_type end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 |
# File 'lib/google/apis/classroom_v1/classes.rb', line 635 def update!(**args) @alternate_link = args[:alternate_link] if args.key?(:alternate_link) @assignee_mode = args[:assignee_mode] if args.key?(:assignee_mode) @assignment = args[:assignment] if args.key?(:assignment) @associated_with_developer = args[:associated_with_developer] if args.key?(:associated_with_developer) @course_id = args[:course_id] if args.key?(:course_id) @creation_time = args[:creation_time] if args.key?(:creation_time) @creator_user_id = args[:creator_user_id] if args.key?(:creator_user_id) @description = args[:description] if args.key?(:description) @due_date = args[:due_date] if args.key?(:due_date) @due_time = args[:due_time] if args.key?(:due_time) @grade_category = args[:grade_category] if args.key?(:grade_category) @id = args[:id] if args.key?(:id) @individual_students_options = args[:individual_students_options] if args.key?(:individual_students_options) @materials = args[:materials] if args.key?(:materials) @max_points = args[:max_points] if args.key?(:max_points) @multiple_choice_question = args[:multiple_choice_question] if args.key?(:multiple_choice_question) @scheduled_time = args[:scheduled_time] if args.key?(:scheduled_time) @state = args[:state] if args.key?(:state) @submission_modification_mode = args[:submission_modification_mode] if args.key?(:submission_modification_mode) @title = args[:title] if args.key?(:title) @topic_id = args[:topic_id] if args.key?(:topic_id) @update_time = args[:update_time] if args.key?(:update_time) @work_type = args[:work_type] if args.key?(:work_type) end |